/*
Theme Name: WP Fixes — WordPress Solutions
Theme URI: https://wpfixes.demo.sbarron.com
Author: Shane Barron
Description: A professional WordPress solutions portfolio and capability showcase theme.
Version: 1.0.0
Requires at least: 6.0
Tested up to: 6.9
Requires PHP: 8.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: wpfixes
*/

/* === Reset & Base === */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --green: #16a34a;
  --green-dark: #15803d;
  --green-light: #22c55e;
  --dark: #0f172a;
  --dark-mid: #1e293b;
  --dark-light: #334155;
  --slate: #64748b;
  --slate-light: #94a3b8;
  --amber: #f59e0b;
  --amber-dark: #d97706;
  --red: #ef4444;
  --white: #ffffff;
  --off-white: #f8fafc;
  --border: #e2e8f0;
}

html { scroll-behavior: smooth; }

body {
  font-family: "Inter", -apple-system, BlinkMacSystemFont, sans-serif;
  color: var(--dark);
  line-height: 1.6;
  background: var(--white);
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
ul, ol { list-style: none; }

/* === Typography === */
h1, h2, h3, h4, h5, h6 {
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.02em;
}

h1 { font-size: clamp(2rem, 5vw, 3.5rem); }
h2 { font-size: clamp(1.5rem, 3.5vw, 2.5rem); }
h3 { font-size: clamp(1.125rem, 2.5vw, 1.5rem); }

p { color: var(--slate); line-height: 1.7; }

/* === Layout === */
.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

.section {
  padding: 5rem 0;
}

.section--dark {
  background: var(--dark);
  color: var(--white);
}

.section--dark p { color: var(--slate-light); }

.section--alt {
  background: var(--off-white);
}

/* === Header === */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: rgba(15, 23, 42, 0.95);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(255,255,255,0.08);
  transition: all 0.3s ease;
}

.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
}

.site-logo {
  display: flex;
  align-items: center;
  gap: 0.625rem;
  font-weight: 800;
  font-size: 1.25rem;
  color: var(--white);
  letter-spacing: -0.03em;
}

.site-logo .logo-icon {
  width: 36px;
  height: 36px;
  background: var(--green);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
}

.site-logo span { color: var(--green); }

/* Nav */
.main-nav { display: flex; align-items: center; gap: 2rem; }
.main-nav a {
  color: var(--slate-light);
  font-size: 0.875rem;
  font-weight: 500;
  transition: color 0.2s;
  position: relative;
}
.main-nav a:hover,
.main-nav a.current { color: var(--white); }

.main-nav a.current::after {
  content: "";
  position: absolute;
  bottom: -4px;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--green);
  border-radius: 1px;
}

.nav-cta {
  background: var(--green) !important;
  color: var(--white) !important;
  padding: 0.5rem 1.25rem;
  border-radius: 6px;
  font-weight: 600 !important;
  transition: background 0.2s !important;
}
.nav-cta:hover { background: var(--green-dark) !important; }

/* Mobile nav */
.nav-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--white);
  font-size: 1.5rem;
  cursor: pointer;
  padding: 0.5rem;
}

@media (max-width: 768px) {
  .nav-toggle { display: block; }
  .main-nav {
    position: fixed;
    top: 72px;
    left: 0;
    right: 0;
    background: var(--dark);
    flex-direction: column;
    padding: 2rem;
    gap: 1.5rem;
    transform: translateY(-100%);
    opacity: 0;
    pointer-events: none;
    transition: all 0.3s;
    border-bottom: 1px solid rgba(255,255,255,0.08);
  }
  .main-nav.is-open {
    transform: translateY(0);
    opacity: 1;
    pointer-events: all;
  }
}

/* === Buttons === */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1.75rem;
  border-radius: 8px;
  font-weight: 600;
  font-size: 0.9375rem;
  transition: all 0.2s;
  border: none;
  cursor: pointer;
  font-family: inherit;
}

.btn--primary {
  background: var(--green);
  color: var(--white);
}
.btn--primary:hover { background: var(--green-dark); transform: translateY(-1px); box-shadow: 0 4px 12px rgba(22,163,74,0.3); }

.btn--secondary {
  background: transparent;
  color: var(--white);
  border: 1px solid rgba(255,255,255,0.2);
}
.btn--secondary:hover { border-color: rgba(255,255,255,0.4); background: rgba(255,255,255,0.05); }

.btn--outline {
  background: transparent;
  color: var(--green);
  border: 2px solid var(--green);
}
.btn--outline:hover { background: var(--green); color: var(--white); }

.btn--dark {
  background: var(--dark);
  color: var(--white);
}
.btn--dark:hover { background: var(--dark-mid); }

/* === Hero === */
.hero {
  padding: 10rem 0 6rem;
  background: var(--dark);
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: "";
  position: absolute;
  top: -50%;
  right: -20%;
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(22,163,74,0.15) 0%, transparent 70%);
  border-radius: 50%;
}

.hero::after {
  content: "";
  position: absolute;
  bottom: -30%;
  left: -10%;
  width: 400px;
  height: 400px;
  background: radial-gradient(circle, rgba(245,158,11,0.08) 0%, transparent 70%);
  border-radius: 50%;
}

.hero .container { position: relative; z-index: 1; }

.hero__badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: rgba(22,163,74,0.15);
  color: var(--green-light);
  padding: 0.375rem 1rem;
  border-radius: 100px;
  font-size: 0.8125rem;
  font-weight: 600;
  margin-bottom: 1.5rem;
  border: 1px solid rgba(22,163,74,0.2);
}

.hero__badge .pulse {
  width: 8px;
  height: 8px;
  background: var(--green-light);
  border-radius: 50%;
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.4; }
}

.hero h1 {
  color: var(--white);
  max-width: 720px;
  margin-bottom: 1.5rem;
}

.hero h1 .highlight {
  color: var(--green);
}

.hero__subtitle {
  font-size: 1.125rem;
  color: var(--slate-light);
  max-width: 560px;
  margin-bottom: 2.5rem;
  line-height: 1.7;
}

.hero__actions {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

.hero__stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5rem;
  margin-top: 4rem;
  padding-top: 3rem;
  border-top: 1px solid rgba(255,255,255,0.08);
}

.hero__stat {
  text-align: center;
}

.hero__stat-value {
  font-size: 2.25rem;
  font-weight: 800;
  color: var(--white);
  letter-spacing: -0.03em;
}

.hero__stat-value .accent { color: var(--green); }

.hero__stat-label {
  font-size: 0.8125rem;
  color: var(--slate);
  margin-top: 0.25rem;
  font-weight: 500;
}

@media (max-width: 768px) {
  .hero__stats { grid-template-columns: repeat(2, 1fr); gap: 1.5rem; }
}

/* === Services Grid === */
.services-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

@media (max-width: 960px) { .services-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 600px) { .services-grid { grid-template-columns: 1fr; } }

.service-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 2rem;
  transition: all 0.3s;
  position: relative;
  overflow: hidden;
}

.service-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--green);
  transform: scaleX(0);
  transition: transform 0.3s;
}

.service-card:hover {
  border-color: var(--green);
  box-shadow: 0 8px 30px rgba(0,0,0,0.08);
  transform: translateY(-2px);
}

.service-card:hover::before { transform: scaleX(1); }

.service-card__icon {
  width: 48px;
  height: 48px;
  background: rgba(22,163,74,0.1);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
  margin-bottom: 1.25rem;
  color: var(--green);
}

.service-card h3 {
  margin-bottom: 0.75rem;
  font-size: 1.125rem;
}

.service-card p {
  font-size: 0.9375rem;
  line-height: 1.6;
}

.service-card__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 1.25rem;
}

.service-card__tag {
  font-size: 0.75rem;
  font-weight: 500;
  padding: 0.25rem 0.625rem;
  border-radius: 100px;
  background: var(--off-white);
  color: var(--slate);
}

/* === Case Studies === */
.case-studies-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.5rem;
}

@media (max-width: 768px) { .case-studies-grid { grid-template-columns: 1fr; } }

.case-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
  transition: all 0.3s;
}

.case-card:hover {
  box-shadow: 0 8px 30px rgba(0,0,0,0.08);
  transform: translateY(-2px);
}

.case-card__header {
  padding: 1.5rem 1.75rem;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
}

.case-card__severity {
  font-size: 0.6875rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 0.25rem 0.75rem;
  border-radius: 100px;
  white-space: nowrap;
}

.case-card__severity--critical {
  background: rgba(239,68,68,0.1);
  color: var(--red);
}

.case-card__severity--high {
  background: rgba(245,158,11,0.1);
  color: var(--amber-dark);
}

.case-card__severity--medium {
  background: rgba(22,163,74,0.1);
  color: var(--green);
}

.case-card__body {
  padding: 0 1.75rem 1.75rem;
}

.case-card__meta {
  display: flex;
  gap: 1.5rem;
  margin-top: 1.25rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--border);
}

.case-card__meta-item {
  font-size: 0.8125rem;
}

.case-card__meta-item strong {
  display: block;
  font-size: 0.6875rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--slate);
  font-weight: 600;
  margin-bottom: 0.125rem;
}

.case-card__meta-item span {
  color: var(--dark);
  font-weight: 600;
}

/* === Process === */
.process-steps {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 0;
  position: relative;
}

.process-steps::before {
  content: "";
  position: absolute;
  top: 32px;
  left: 10%;
  right: 10%;
  height: 2px;
  background: var(--border);
}

@media (max-width: 768px) {
  .process-steps {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
  .process-steps::before {
    top: 0;
    bottom: 0;
    left: 32px;
    right: auto;
    width: 2px;
    height: auto;
  }
}

.process-step {
  text-align: center;
  position: relative;
}

.process-step__number {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: var(--white);
  border: 2px solid var(--green);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 1.25rem;
  color: var(--green);
  margin: 0 auto 1rem;
  position: relative;
  z-index: 1;
}

.process-step h4 {
  font-size: 1rem;
  margin-bottom: 0.5rem;
}

.process-step p {
  font-size: 0.8125rem;
  max-width: 160px;
  margin: 0 auto;
}

/* === Site Health Widget === */
.health-widget {
  background: var(--dark);
  border-radius: 16px;
  padding: 2.5rem;
  border: 1px solid rgba(255,255,255,0.08);
}

.health-widget__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 2rem;
}

.health-widget__title {
  color: var(--white);
  font-size: 1.125rem;
  font-weight: 700;
}

.health-widget__status {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.8125rem;
  color: var(--green-light);
  font-weight: 600;
}

.health-widget__status .dot {
  width: 8px;
  height: 8px;
  background: var(--green-light);
  border-radius: 50%;
  animation: pulse 2s infinite;
}

.health-metrics {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5rem;
}

@media (max-width: 768px) { .health-metrics { grid-template-columns: repeat(2, 1fr); } }

.health-metric {
  text-align: center;
  padding: 1.25rem;
  background: rgba(255,255,255,0.03);
  border-radius: 10px;
  border: 1px solid rgba(255,255,255,0.06);
}

.health-metric__value {
  font-size: 1.75rem;
  font-weight: 800;
  color: var(--white);
  letter-spacing: -0.03em;
}

.health-metric__value.good { color: var(--green-light); }
.health-metric__value.warn { color: var(--amber); }
.health-metric__value.bad { color: var(--red); }

.health-metric__label {
  font-size: 0.75rem;
  color: var(--slate);
  margin-top: 0.25rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-weight: 600;
}

.health-metric__bar {
  height: 4px;
  background: rgba(255,255,255,0.08);
  border-radius: 2px;
  margin-top: 0.75rem;
  overflow: hidden;
}

.health-metric__bar-fill {
  height: 100%;
  border-radius: 2px;
  transition: width 1.5s ease;
}

/* === Expertise === */
.expertise-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
}

@media (max-width: 768px) { .expertise-grid { grid-template-columns: repeat(2, 1fr); } }

.expertise-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 1rem 1.25rem;
  background: rgba(255,255,255,0.04);
  border-radius: 8px;
  border: 1px solid rgba(255,255,255,0.06);
  color: var(--slate-light);
  font-size: 0.875rem;
  font-weight: 500;
}

.expertise-item .check {
  color: var(--green);
  font-weight: 700;
}

/* === CTA Section === */
.cta-section {
  background: linear-gradient(135deg, var(--green) 0%, var(--green-dark) 100%);
  padding: 5rem 0;
  text-align: center;
}

.cta-section h2 { color: var(--white); margin-bottom: 1rem; }
.cta-section p { color: rgba(255,255,255,0.8); max-width: 560px; margin: 0 auto 2rem; font-size: 1.125rem; }

/* === Footer === */
.site-footer {
  background: var(--dark);
  padding: 3rem 0;
  border-top: 1px solid rgba(255,255,255,0.06);
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: var(--slate);
  font-size: 0.875rem;
}

.footer-links { display: flex; gap: 1.5rem; }
.footer-links a { color: var(--slate-light); transition: color 0.2s; }
.footer-links a:hover { color: var(--white); }

/* === Single Case Study === */
.case-hero {
  padding: 8rem 0 3rem;
  background: var(--dark);
}

.case-hero h1 { color: var(--white); max-width: 700px; }

.case-meta-bar {
  display: flex;
  gap: 2rem;
  margin-top: 1.5rem;
  flex-wrap: wrap;
}

.case-meta-item {
  font-size: 0.875rem;
}

.case-meta-item strong {
  color: var(--slate);
  font-weight: 600;
  text-transform: uppercase;
  font-size: 0.6875rem;
  letter-spacing: 0.05em;
  display: block;
  margin-bottom: 0.125rem;
}

.case-meta-item span { color: var(--white); font-weight: 600; }

.case-content {
  padding: 3rem 0;
}

.case-content .container {
  max-width: 800px;
}

.case-section {
  margin-bottom: 3rem;
}

.case-section__label {
  font-size: 0.6875rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--green);
  font-weight: 700;
  margin-bottom: 0.75rem;
}

.case-section h2 {
  font-size: 1.5rem;
  margin-bottom: 1rem;
}

.case-section p {
  font-size: 1rem;
  line-height: 1.8;
}

.case-section ul {
  list-style: none;
  padding: 0;
}

.case-section ul li {
  padding: 0.5rem 0 0.5rem 1.75rem;
  position: relative;
  color: var(--slate);
  font-size: 0.9375rem;
}

.case-section ul li::before {
  content: "✓";
  position: absolute;
  left: 0;
  color: var(--green);
  font-weight: 700;
}

.result-box {
  background: rgba(22,163,74,0.06);
  border: 1px solid rgba(22,163,74,0.15);
  border-radius: 12px;
  padding: 2rem;
}

.result-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  margin-top: 1.5rem;
}

@media (max-width: 600px) { .result-stats { grid-template-columns: 1fr; } }

.result-stat {
  text-align: center;
}

.result-stat__value {
  font-size: 2rem;
  font-weight: 800;
  color: var(--green);
}

.result-stat__label {
  font-size: 0.8125rem;
  color: var(--slate);
  margin-top: 0.25rem;
}

/* === Contact Form === */
.contact-form {
  max-width: 640px;
}

.form-group {
  margin-bottom: 1.25rem;
}

.form-group label {
  display: block;
  font-size: 0.875rem;
  font-weight: 600;
  margin-bottom: 0.375rem;
  color: var(--dark);
}

.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  padding: 0.75rem 1rem;
  border: 1px solid var(--border);
  border-radius: 8px;
  font-family: inherit;
  font-size: 0.9375rem;
  transition: border-color 0.2s;
  background: var(--white);
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--green);
  box-shadow: 0 0 0 3px rgba(22,163,74,0.1);
}

.form-group textarea { min-height: 120px; resize: vertical; }

.urgent-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: rgba(239,68,68,0.08);
  color: var(--red);
  padding: 0.75rem 1.25rem;
  border-radius: 8px;
  font-size: 0.875rem;
  font-weight: 600;
  margin-bottom: 1.5rem;
  border: 1px solid rgba(239,68,68,0.15);
}

/* === Page Headers === */
.page-hero {
  padding: 8rem 0 3rem;
  background: var(--dark);
}

.page-hero h1 { color: var(--white); margin-bottom: 0.75rem; }
.page-hero p { color: var(--slate-light); font-size: 1.125rem; max-width: 600px; }

/* === About === */
.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
}

@media (max-width: 768px) { .about-grid { grid-template-columns: 1fr; gap: 2rem; } }

.about-values {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.5rem;
  margin-top: 2rem;
}

.about-value {
  padding: 1.5rem;
  border: 1px solid var(--border);
  border-radius: 10px;
}

.about-value h4 {
  font-size: 0.9375rem;
  margin-bottom: 0.375rem;
}

.about-value p {
  font-size: 0.8125rem;
}

/* === Archive === */
.archive-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.5rem;
}

@media (max-width: 768px) { .archive-grid { grid-template-columns: 1fr; } }

/* === Section Headers === */
.section__header {
  text-align: center;
  max-width: 600px;
  margin: 0 auto 3rem;
}

.section__header p {
  margin-top: 0.75rem;
  font-size: 1rem;
}

.section__label {
  font-size: 0.6875rem;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--green);
  font-weight: 700;
  margin-bottom: 0.75rem;
}

/* === GSAP Visibility === */
.gsap-reveal { visibility: hidden; }
body.gsap-ready .gsap-reveal { visibility: hidden; }

/* === Code block styling === */
.code-block {
  background: var(--dark-mid);
  border-radius: 8px;
  padding: 1.25rem 1.5rem;
  font-family: "JetBrains Mono", "Fira Code", monospace;
  font-size: 0.8125rem;
  color: var(--slate-light);
  overflow-x: auto;
  border: 1px solid rgba(255,255,255,0.06);
  margin: 1rem 0;
}

.code-block .comment { color: var(--slate); }
.code-block .keyword { color: #c084fc; }
.code-block .string { color: var(--green-light); }
.code-block .function { color: #60a5fa; }

/* === Testimonial === */
.testimonial {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 2rem;
  position: relative;
}

.testimonial::before {
  content: "\201C";
  font-size: 4rem;
  color: var(--green);
  font-family: Georgia, serif;
  line-height: 1;
  position: absolute;
  top: 1rem;
  left: 1.5rem;
  opacity: 0.3;
}

.testimonial p {
  font-size: 1rem;
  font-style: italic;
  line-height: 1.7;
  padding-left: 1rem;
}

.testimonial__author {
  margin-top: 1rem;
  padding-left: 1rem;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--dark);
}
