/* ================================================================
   ALABAMA PAIN PHYSICIANS — SITE DESIGN SYSTEM
   Navy + warm tones. Clinical authority meets warmth.
   ================================================================ */

@import url('https://fonts.googleapis.com/css2?family=Libre+Baskerville:ital,wght@0,400;0,700;1,400&family=Outfit:wght@300;400;500;600;700&display=swap');

:root {
  --navy: #1B2A4A;
  --navy-deep: #0f1a30;
  --slate: #3a4a5c;
  --cream: #f3f1ec;
  --warm-white: #faf9f7;
  --text: #1a1a1a;
  --text-sec: #5a6270;
  --text-dim: #8a9099;
  --accent: #2e7d6f;
  --accent-light: #e8f4f1;
  --accent-hover: #246b5f;
  --copper: #b8784e;
  --white: #ffffff;
  --border: #ddd9d2;
  --border-light: #eae7e1;
  --shadow: 0 4px 20px rgba(0,0,0,0.07);
  --shadow-lg: 0 12px 48px rgba(0,0,0,0.10);
  --radius: 6px;
  --radius-lg: 10px;
  --serif: 'Libre Baskerville', Georgia, serif;
  --sans: 'Outfit', -apple-system, sans-serif;
  --max-w: 1120px;
  --header-h: 72px;
  --ease: cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-font-smoothing: antialiased; }
body { font-family: var(--sans); color: var(--text); background: var(--warm-white); line-height: 1.6; }
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }

/* ============ PHONE STRIP ============ */
.phone-strip {
  background: var(--navy-deep);
  padding: 7px 20px;
  text-align: center;
  font-size: 12.5px;
  color: rgba(255,255,255,0.55);
  letter-spacing: 0.3px;
}
.phone-strip a { color: #fff; font-weight: 600; }
.phone-strip strong { color: #fff; }

/* ============ HEADER ============ */
.header {
  position: sticky; top: 0; z-index: 100;
  background: var(--cream);
  border-bottom: 2px solid var(--navy);
  height: var(--header-h);
}
.header-inner {
  max-width: var(--max-w); margin: 0 auto; padding: 0 24px;
  display: flex; align-items: center; justify-content: space-between;
  height: 100%;
}
.logo-mark { display: flex; align-items: center; gap: 12px; }
.logo-shield {
  width: 36px; height: 42px; background: var(--navy);
  clip-path: polygon(50% 0%, 100% 18%, 100% 78%, 50% 100%, 0% 78%, 0% 18%);
  display: flex; align-items: center; justify-content: center;
  color: #fff; font-size: 16px;
}
.logo-name .pname {
  font-family: var(--serif); font-size: 13.5px; font-weight: 700;
  color: var(--navy); text-transform: uppercase; letter-spacing: 0.4px; line-height: 1.2;
}
.logo-name .tagline {
  font-family: var(--serif); font-size: 10px; font-style: italic; color: var(--slate); margin-top: 1px;
}

.nav { display: flex; align-items: center; gap: 2px; }
.nav a {
  font-size: 13px; font-weight: 500; color: var(--slate);
  padding: 7px 12px; border-radius: var(--radius); transition: all 0.2s;
}
.nav a:hover { background: var(--cream); color: var(--navy); }
.nav a.active { color: var(--navy); font-weight: 600; }
.nav-cta {
  background: var(--navy) !important; color: #fff !important;
  padding: 8px 18px !important; border-radius: var(--radius) !important;
  font-weight: 600 !important; margin-left: 6px;
}
.nav-cta:hover { background: var(--slate) !important; }

.mobile-toggle { display: none; background: none; border: none; padding: 8px; cursor: pointer; }
.mobile-toggle span { display: block; width: 20px; height: 2px; background: var(--navy); margin: 4px 0; transition: 0.3s; border-radius: 1px; }

/* ============ SECTIONS ============ */
section { padding: 56px 24px; }
.section-inner { max-width: var(--max-w); margin: 0 auto; }
section.bg-cream { background: var(--cream); }
section.bg-navy { background: var(--navy); }
section.bg-white { background: var(--white); }

.eyebrow {
  font-size: 11px; font-weight: 700; text-transform: uppercase;
  letter-spacing: 2.5px; color: var(--accent); margin-bottom: 12px;
}
.sec-heading {
  font-family: var(--serif); font-size: 34px; line-height: 1.2;
  color: var(--navy); margin-bottom: 14px; max-width: 600px;
}
.sec-desc {
  font-size: 16px; line-height: 1.7; color: var(--text-sec);
  max-width: 540px; margin-bottom: 44px;
}

/* ============ BUTTONS ============ */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 12px 26px; border-radius: var(--radius); font-weight: 600;
  font-size: 14px; font-family: var(--sans); transition: all 0.2s var(--ease);
  cursor: pointer; border: none; letter-spacing: 0.01em;
}
.btn-white { background: #fff; color: var(--navy); }
.btn-white:hover { background: var(--cream); box-shadow: var(--shadow-lg); transform: translateY(-1px); }
.btn-ghost { background: transparent; color: #fff; border: 1.5px solid rgba(255,255,255,0.3); }
.btn-ghost:hover { border-color: rgba(255,255,255,0.7); background: rgba(255,255,255,0.06); }
.btn-navy { background: var(--navy); color: #fff; }
.btn-navy:hover { background: var(--slate); }
.btn-accent { background: var(--accent); color: #fff; }
.btn-accent:hover { background: var(--accent-hover); }
.btn-outline { background: transparent; color: var(--navy); border: 1.5px solid var(--border); }
.btn-outline:hover { border-color: var(--accent); color: var(--accent); }
.btns { display: flex; gap: 12px; flex-wrap: wrap; }

/* ============ CARDS ============ */
.card {
  background: var(--white); border: 1px solid var(--border-light);
  border-radius: var(--radius-lg); padding: 28px 24px;
  transition: all 0.25s var(--ease);
}
.card:hover { border-color: var(--accent); box-shadow: var(--shadow); transform: translateY(-2px); }
.card h3 { font-size: 17px; font-weight: 700; color: var(--navy); margin-bottom: 8px; }
.card p { font-size: 14px; color: var(--text-sec); line-height: 1.6; }

/* ============ FORMS ============ */
.form-group { margin-bottom: 16px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-bottom: 16px; }
.form-group label { display: block; font-size: 13px; font-weight: 600; margin-bottom: 5px; color: var(--text); }
.form-group input, .form-group select, .form-group textarea {
  width: 100%; padding: 10px 14px; border: 1px solid var(--border); border-radius: var(--radius);
  font-family: var(--sans); font-size: 14px; color: var(--text); background: var(--white);
  transition: border-color 0.2s;
}
.form-group input:focus, .form-group select:focus, .form-group textarea:focus {
  outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px rgba(46,125,111,0.08);
}
.form-group textarea { min-height: 100px; resize: vertical; }

/* ============ STATS BAR ============ */
.stats-bar {
  display: grid; grid-template-columns: repeat(4, 1fr);
  border-top: 1px solid rgba(255,255,255,0.06);
  border-bottom: 1px solid rgba(255,255,255,0.06);
}
.stat { text-align: center; padding: 36px 16px; border-right: 1px solid rgba(255,255,255,0.06); }
.stat:last-child { border-right: none; }
.stat .num { font-family: var(--serif); font-size: 40px; color: #fff; }
.stat .lbl { font-size: 12.5px; color: rgba(255,255,255,0.4); margin-top: 4px; }

/* ============ LOCATIONS ============ */
.loc-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.loc-card { background: var(--white); border: 1px solid var(--border-light); border-radius: var(--radius-lg); padding: 32px 28px; }
.loc-card h3 { font-family: var(--serif); font-size: 20px; color: var(--navy); margin-bottom: 12px; }
.loc-card address { font-style: normal; font-size: 15px; color: var(--text-sec); line-height: 1.6; margin-bottom: 12px; }
.loc-card .phone { font-size: 18px; font-weight: 700; color: var(--navy); }
.loc-card .phone a { color: var(--navy); }
.loc-card .meta { margin-top: 8px; font-size: 12.5px; color: var(--text-dim); }

/* ============ CTA BANNER ============ */
.cta-banner {
  background: var(--navy); padding: 56px 24px; text-align: center;
  position: relative; overflow: hidden;
}
.cta-banner::before {
  content: ''; position: absolute; inset: 0;
  background: radial-gradient(ellipse at 50% 50%, rgba(46,125,111,0.1) 0%, transparent 60%);
}
.cta-banner > * { position: relative; z-index: 1; }
.cta-banner h2 { font-family: var(--serif); font-size: 32px; color: #fff; margin-bottom: 12px; }
.cta-banner p { font-size: 15px; color: rgba(255,255,255,0.55); max-width: 480px; margin: 0 auto 28px; line-height: 1.6; }
.cta-banner .note { margin-top: 18px; font-size: 12.5px; color: rgba(255,255,255,0.3); }
.cta-banner .btns { justify-content: center; }

/* ============ FOOTER ============ */
.footer { background: var(--navy-deep); padding: 56px 24px 24px; }
.footer-grid {
  display: grid; grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 36px; max-width: var(--max-w); margin: 0 auto;
}
.footer-col h4 {
  font-size: 10.5px; font-weight: 700; text-transform: uppercase;
  letter-spacing: 2px; color: rgba(255,255,255,0.3); margin-bottom: 14px;
}
.footer-col a {
  display: block; font-size: 13px; color: rgba(255,255,255,0.55);
  padding: 3px 0; transition: color 0.2s;
}
.footer-col a:hover { color: #fff; }
.footer-brand p { font-size: 13px; color: rgba(255,255,255,0.35); line-height: 1.6; margin-bottom: 12px; }
.footer-brand .phone-big { font-size: 18px; font-weight: 700; color: #fff; }
.footer-brand .phone-big a { color: #fff; }
.footer-bottom {
  max-width: var(--max-w); margin: 32px auto 0; padding-top: 18px;
  border-top: 1px solid rgba(255,255,255,0.05);
  display: flex; justify-content: space-between;
  font-size: 11.5px; color: rgba(255,255,255,0.2);
}

/* ============ MOBILE CALL BAR ============ */
.mobile-bar {
  display: none; position: fixed; bottom: 0; left: 0; right: 0; z-index: 200;
  background: var(--navy); padding: 10px 16px; box-shadow: 0 -2px 16px rgba(0,0,0,0.2);
}
.mobile-bar a {
  display: flex; align-items: center; justify-content: center; gap: 8px;
  color: #fff; font-weight: 700; font-size: 15px;
}

/* ============ RESPONSIVE ============ */
@media (max-width: 960px) {
  .nav { display: none; }
  .mobile-toggle { display: block; }
  .nav.open {
    display: flex; flex-direction: column; position: absolute;
    top: var(--header-h); left: 0; right: 0; background: #fff;
    padding: 16px; box-shadow: var(--shadow-lg); border-top: 1px solid var(--border-light);
  }
  .nav.open a { padding: 10px 16px; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 640px) {
  section { padding: 56px 20px; }
  .sec-heading { font-size: 27px; }
  .stats-bar { grid-template-columns: 1fr 1fr; }
  .loc-grid { grid-template-columns: 1fr; }
  .form-row { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; gap: 24px; }
  .mobile-bar { display: block; }
  body { padding-bottom: 52px; }
  .nav-cta { display: none !important; }
}

/* ============ PAGE-SPECIFIC ============ */

/* Hero */
.hero {
  background: var(--navy); position: relative; overflow: hidden;
  padding: 52px 24px 56px;
}
.hero::before {
  content: ''; position: absolute; inset: 0;
  background: radial-gradient(ellipse at 20% 50%, rgba(46,125,111,0.12) 0%, transparent 50%),
              radial-gradient(ellipse at 80% 20%, rgba(184,120,78,0.06) 0%, transparent 40%);
}
.hero-inner {
  max-width: var(--max-w); margin: 0 auto; position: relative; z-index: 1;
}
.hero h1 {
  font-family: var(--serif); font-size: 40px; line-height: 1.18;
  color: #fff; margin-bottom: 22px; max-width: 620px;
}
.hero h1 em { font-style: italic; color: var(--copper); }
.hero .hero-sub {
  font-size: 16.5px; line-height: 1.7; color: rgba(255,255,255,0.6);
  margin-bottom: 32px; max-width: 520px;
}
.hero .hero-sub strong { color: rgba(255,255,255,0.88); font-weight: 600; }
.hero-trust {
  display: flex; gap: 28px; margin-top: 36px;
  padding-top: 24px; border-top: 1px solid rgba(255,255,255,0.08);
}
.hero-trust .ti { font-size: 12px; color: rgba(255,255,255,0.4); }
.hero-trust .ti strong { display: block; font-size: 20px; color: #fff; font-family: var(--serif); }

/* Condition grid */
.cond-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; }
.cond-card {
  background: var(--white); border: 1.5px solid var(--border);
  border-radius: var(--radius-lg); padding: 24px 20px;
  transition: all 0.25s var(--ease); cursor: pointer; position: relative;
  box-shadow: 0 2px 8px rgba(0,0,0,0.04);
}
.cond-card:hover { border-color: var(--accent); box-shadow: var(--shadow); transform: translateY(-3px); }
.cond-card .icon { font-size: 28px; margin-bottom: 12px; }
.cond-card h3 { font-size: 15.5px; font-weight: 700; color: var(--navy); margin-bottom: 6px; }
.cond-card p { font-size: 13px; color: var(--text-sec); line-height: 1.5; }
.cond-card .root {
  margin-top: 10px; padding-top: 10px; border-top: 1px solid var(--border-light);
  font-size: 10.5px; font-weight: 600; color: var(--accent); text-transform: uppercase; letter-spacing: 0.5px;
}

/* Treatment spectrum */
.spectrum {
  display: flex; border-radius: var(--radius-lg); overflow: hidden; border: 1px solid var(--border);
}
.spectrum-step {
  flex: 1; padding: 24px 16px; text-align: center; background: var(--white);
  border-right: 1px solid var(--border-light); transition: background 0.2s;
}
.spectrum-step:last-child { border-right: none; }
.spectrum-step:hover { background: var(--accent-light); }
.spectrum-step .snum {
  width: 26px; height: 26px; border-radius: 50%; background: var(--navy); color: #fff;
  font-size: 11px; font-weight: 700; display: flex; align-items: center; justify-content: center;
  margin: 0 auto 10px;
}
.spectrum-step h4 { font-size: 12.5px; font-weight: 700; color: var(--navy); margin-bottom: 5px; }
.spectrum-step p { font-size: 11px; color: var(--text-sec); line-height: 1.4; }

/* Testimonials */
.test-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.test-card {
  background: var(--white); border: 1px solid var(--border-light);
  border-radius: var(--radius-lg); padding: 28px 24px;
}
.test-card .stars { color: var(--copper); font-size: 14px; letter-spacing: 2px; margin-bottom: 12px; }
.test-card blockquote {
  font-family: var(--serif); font-size: 14px; font-style: italic;
  color: var(--text); line-height: 1.6; margin-bottom: 14px;
}
.test-card cite { font-size: 12px; color: var(--text-dim); font-style: normal; font-weight: 600; }

/* Provider cards */
.prov-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; }
.prov-card { text-align: center; }
.prov-photo {
  width: 160px; height: 160px; border-radius: 50%; margin: 0 auto 18px;
  background: var(--cream); border: 3px solid var(--border-light);
  display: flex; align-items: center; justify-content: center;
  font-family: var(--serif); font-size: 32px; color: var(--navy);
  overflow: hidden;
}
.prov-photo img { width: 100%; height: 100%; object-fit: cover; }
.prov-card h3 { font-family: var(--serif); font-size: 18px; color: var(--navy); margin-bottom: 3px; }
.prov-card .spec { font-size: 13px; color: var(--accent); font-weight: 600; margin-bottom: 6px; }
.prov-card .bio { font-size: 13px; color: var(--text-sec); line-height: 1.5; }

/* Referral steps */
.steps-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; }
.step-card { text-align: center; padding: 28px 20px; }
.step-num {
  width: 44px; height: 44px; border-radius: 50%; margin: 0 auto 14px;
  background: var(--navy); color: #fff; font-weight: 700; font-size: 18px;
  display: flex; align-items: center; justify-content: center;
}
.step-card h3 { font-size: 16px; font-weight: 700; color: var(--navy); margin-bottom: 6px; }
.step-card p { font-size: 14px; color: var(--text-sec); line-height: 1.5; }

/* FAQ */
.faq-item { border-bottom: 1px solid var(--border); padding: 20px 0; }
.faq-item:last-child { border: none; }
.faq-item h3 { font-size: 16px; font-weight: 700; color: var(--navy); margin-bottom: 8px; cursor: pointer; }
.faq-item p { font-size: 14px; color: var(--text-sec); line-height: 1.6; }

/* Philosophy pillars */
.pillars { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.pillar {
  background: var(--white); border: 1px solid var(--border-light);
  border-radius: var(--radius-lg); padding: 22px; transition: all 0.25s var(--ease);
}
.pillar:hover { border-color: var(--accent); box-shadow: var(--shadow); }
.pillar .pi { font-size: 24px; margin-bottom: 8px; }
.pillar h4 { font-size: 14px; font-weight: 700; color: var(--navy); margin-bottom: 5px; }
.pillar p { font-size: 12.5px; color: var(--text-sec); line-height: 1.5; }

/* Page header (for inner pages) */
.page-header { background: var(--cream); padding: 48px 24px; }
.page-header .section-inner { max-width: var(--max-w); margin: 0 auto; }
.page-header h1 { font-family: var(--serif); font-size: 34px; color: var(--navy); margin-bottom: 12px; }
.page-header .sub { font-size: 16px; color: var(--text-sec); line-height: 1.6; max-width: 560px; }

/* Responsive overrides */
@media (max-width: 960px) {
  .cond-grid { grid-template-columns: repeat(2, 1fr); }
  .spectrum { flex-direction: column; }
  .spectrum-step { border-right: none; border-bottom: 1px solid var(--border-light); }
  .prov-grid { grid-template-columns: repeat(2, 1fr); }
  .test-grid { grid-template-columns: 1fr; }
  .steps-grid { grid-template-columns: 1fr; }
  .pillars { grid-template-columns: 1fr; }
  .hero h1 { font-size: 32px; }
  .hero .hero-inner { grid-template-columns: 1fr !important; }
}
@media (max-width: 640px) {
  section { padding: 40px 16px !important; }
  .sec-heading { font-size: 24px; }
  .cond-grid { grid-template-columns: 1fr; }
  .hero { padding: 36px 16px 44px !important; }
  .hero h1 { font-size: 26px; }
  .hero .hero-sub { font-size: 14.5px; }
  .hero-trust { flex-wrap: wrap; gap: 16px; }
  .hero .hero-inner { grid-template-columns: 1fr !important; gap: 28px !important; }
  .prov-grid { grid-template-columns: 1fr; }
  .loc-grid { grid-template-columns: 1fr; }
  .form-row { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; gap: 20px; }
  .stats-bar { grid-template-columns: 1fr 1fr; }
  .phone-strip { font-size: 11px; padding: 6px 12px; }
  .header-inner { padding: 0 12px; }
  .btn, .btn-white, .btn-ghost { font-size: 13px; padding: 10px 18px; }
  .btns { flex-direction: column; gap: 10px; }
  .btns .btn, .btns .btn-white, .btns .btn-ghost { width: 100%; text-align: center; justify-content: center; }
  .cta-banner h2 { font-size: 24px; }
  .cta-banner p { font-size: 14px; }
  .card { padding: 20px 16px !important; }
  .test-card { padding: 20px 16px; }
  .eyebrow { font-size: 11px; }
  .sec-desc { font-size: 14px; }
}
