/* ==========================================================================
   Bravo! Dental — rebuild design prototype
   Design system (Stage 2 / Phase 2). Brand-accurate, WCAG 2.1 AA.
   Contrast note: bright brand green/blue/orange are used as DECOR only.
   Text/links/buttons use AA-verified values (see --ink*, --navy, --green-700).
   ========================================================================== */

:root {
  /* Brand palette (from scrape) */
  --navy:        #27265e;   /* brand wordmark / headings / primary button */
  --navy-800:    #1d1c49;
  --green:       #72bf47;   /* decorative accent */
  --green-700:   #2f7d16;   /* AA text/link on white (7.0:1) */
  --blue:        #0089b7;   /* decorative accent */
  --blue-700:    #00647f;   /* AA text on white */
  --orange:      #f47a21;   /* decorative accent / highlights */
  --orange-700:  #b4530a;   /* AA text on white */

  /* Neutrals */
  --ink:         #1f2430;   /* body text (13.5:1 on white) */
  --ink-soft:    #4a5262;   /* secondary text (7.4:1) */
  --line:        #e2e6ee;
  --bg:          #ffffff;
  --bg-alt:      #f4f7fb;   /* section band */
  --bg-navy:     #27265e;

  /* Type */
  --font-head: "Montserrat", "Avenir Next", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-body: "Open Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;

  --wrap: 1180px;
  --radius: 14px;
  --radius-sm: 9px;
  --shadow: 0 10px 30px rgba(31,36,48,.08);
  --shadow-lg: 0 18px 50px rgba(31,36,48,.14);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.65;
  font-size: 17px;
  -webkit-font-smoothing: antialiased;
}
h1,h2,h3,h4 { font-family: var(--font-head); color: var(--navy); line-height: 1.15; margin: 0 0 .5em; font-weight: 700; }
h1 { font-size: clamp(2.1rem, 4.5vw, 3.3rem); letter-spacing: -.5px; }
h2 { font-size: clamp(1.7rem, 3.2vw, 2.4rem); letter-spacing: -.3px; }
h3 { font-size: 1.25rem; }
p { margin: 0 0 1rem; }
a { color: var(--blue-700); text-underline-offset: 2px; }
a:hover { color: var(--navy); }
img { max-width: 100%; height: auto; display: block; }

.wrap { max-width: var(--wrap); margin-inline: auto; padding-inline: 22px; }
.eyebrow { font-family: var(--font-head); text-transform: uppercase; letter-spacing: 2px; font-size: .78rem; font-weight: 700; color: var(--green-700); margin: 0 0 .6rem; }
.section { padding: 72px 0; }
.section--alt { background: var(--bg-alt); }
.center { text-align: center; }
.lead { font-size: 1.18rem; color: var(--ink-soft); max-width: 60ch; }
.center .lead { margin-inline: auto; }

/* Accessibility helpers */
.skip-link {
  position: absolute; left: 12px; top: -60px; z-index: 1000;
  background: var(--navy); color: #fff; padding: 12px 18px; border-radius: 0 0 8px 8px;
  transition: top .18s ease;
}
.skip-link:focus { top: 0; color: #fff; }
:focus-visible { outline: 3px solid var(--orange); outline-offset: 2px; border-radius: 4px; }
.visually-hidden {
  position:absolute!important;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap;border:0;
}

/* Buttons — all AA-verified (white on navy 11:1, ink on green 6.4:1) */
.btn {
  display: inline-flex; align-items: center; gap: .5rem;
  font-family: var(--font-head); font-weight: 700; font-size: 1rem;
  padding: 14px 26px; border-radius: 40px; border: 2px solid transparent;
  cursor: pointer; text-decoration: none; transition: transform .12s ease, background .15s ease, box-shadow .15s ease;
  line-height: 1;
}
.btn:hover { transform: translateY(-2px); }
.btn--primary { background: var(--navy); color: #fff; box-shadow: 0 8px 20px rgba(39,38,94,.28); }
.btn--primary:hover { background: var(--navy-800); color:#fff; }
.btn--accent { background: var(--green); color: #14330a; }
.btn--accent:hover { background: #63ac3c; color:#14330a; }
.btn--ghost { background: transparent; color: var(--navy); border-color: var(--navy); }
.btn--ghost:hover { background: var(--navy); color: #fff; }
.btn--onnavy { background:#fff; color: var(--navy); }
.btn--lg { font-size: 1.08rem; padding: 17px 32px; }

/* ===== Top announcement bar ===== */
.topbar {
  background: linear-gradient(90deg, var(--blue), var(--navy));
  color: #fff; text-align: center; font-size: .92rem; padding: 9px 16px;
  font-family: var(--font-head); font-weight: 600;
}
.topbar a { color: #fff; text-decoration: underline; }

/* ===== Header / nav ===== */
.site-header { position: sticky; top: 0; z-index: 100; background: rgba(255,255,255,.96); backdrop-filter: blur(8px); border-bottom: 1px solid var(--line); }
.nav { display: flex; align-items: center; gap: 14px; padding: 12px 22px; max-width: var(--wrap); margin-inline: auto; }
.nav__logo { display: flex; align-items: center; gap: 12px; text-decoration: none; flex-shrink: 0; }
.nav__logo img { height: 62px; width: auto; object-fit: contain; }
.nav__logo img.nav__logo-smiles { height: 62px; width: auto; object-fit: contain; }
.nav__logos { display: flex; align-items: center; gap: 10px; }
.nav__menu { display: flex; gap: 2px; margin-left: auto; min-width: 0; list-style: none; padding: 0; margin-block: 0; align-items: center; }
.nav__menu > li { position: relative; }
.nav__menu a { display: block; padding: 9px 8px; color: var(--navy); font-family: var(--font-head); font-weight: 600; font-size: .86rem; text-decoration: none; border-radius: 8px; }
.nav__menu a:hover, .nav__menu a[aria-current="page"] { background: var(--bg-alt); color: var(--navy); }
.nav__menu a[aria-current="page"] { box-shadow: inset 0 -3px 0 var(--green); }
.nav__phone { font-family: var(--font-head); font-weight: 800; color: var(--green-700); text-decoration: none; white-space: nowrap; font-size: 1.02rem; }
.nav__cta { margin-left: 4px; }
.nav__cta .btn { font-size: 1.12rem; padding: 15px 28px; }

/* dropdown */
.has-sub > button { font: inherit; font-family: var(--font-head); font-weight:600; font-size:.86rem; color: var(--navy); background: none; border: 0; padding: 9px 8px; cursor: pointer; border-radius: 8px; display:flex; align-items:center; gap:5px; }
.has-sub > button:hover, .has-sub > button[aria-expanded="true"] { background: var(--bg-alt); }
.submenu { position: absolute; top: 100%; left: 0; min-width: 230px; background: #fff; border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow-lg); padding: 8px; list-style: none; margin: 6px 0 0; display: none; }
.has-sub[data-open="true"] .submenu { display: block; }
.submenu a { padding: 9px 12px; font-weight: 500; font-size: .92rem; }

.nav__toggle { display: none; margin-left: auto; background: var(--navy); color: #fff; border: 0; border-radius: 8px; padding: 10px 14px; font-size: 1.1rem; cursor: pointer; }

/* ===== Hero ===== */
.hero { position: relative; background: linear-gradient(180deg, #eef7f2, #ffffff); overflow: hidden; }
.hero__grid { display: grid; grid-template-columns: 1.05fr .95fr; gap: 24px; align-items: center; min-height: 520px; }
.hero__content { padding: 60px 0; }
.hero__content h1 span { color: var(--green-700); display:block; }
.hero__actions { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 22px; }
.hero__img { position: relative; align-self: stretch; }
.hero__img img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; object-position: bottom right; }
.hero__img img.hero__slide { opacity: 0; animation: heroFade 18s infinite; }
.hero__img img.hero__slide:nth-child(1) { animation-delay: 0s; }
.hero__img img.hero__slide:nth-child(2) { animation-delay: 6s; }
.hero__img img.hero__slide:nth-child(3) { animation-delay: 12s; }
@keyframes heroFade { 0% { opacity: 0; } 4% { opacity: 1; } 33% { opacity: 1; } 37% { opacity: 0; } 100% { opacity: 0; } }
.hero__badges { display:flex; gap: 18px; align-items:center; margin-top: 26px; flex-wrap: wrap; color: var(--ink-soft); font-size:.9rem; }
.hero__badges strong { color: var(--navy); }

/* ===== Service category cards (brand: colored tiles) ===== */
.cards { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.card-cat { border-radius: var(--radius); padding: 26px 22px 24px; color: #fff; min-height: 230px; display: flex; flex-direction: column; box-shadow: var(--shadow); text-decoration: none; transition: transform .14s ease, box-shadow .14s ease; }
.card-cat:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); color:#fff; }
.card-cat h3 { color: #fff; font-size: 1.15rem; margin-bottom: .4rem; }
.card-cat p { font-size: .95rem; margin-bottom: 1rem; color: rgba(255,255,255,.95); }
.card-cat .card-cat__more { margin-top: auto; font-family: var(--font-head); font-weight: 700; font-size: .9rem; }
.card-cat__icon { font-size: 1.8rem; margin-bottom: 10px; }
.cat-orange { background: linear-gradient(160deg, #f0851f, #d5620a); }   /* AA: white on these ≥4.5 */
.cat-navy   { background: linear-gradient(160deg, #34327a, #27265e); }
.cat-green  { background: linear-gradient(160deg, #4a9e2f, #367d1f); }
.cat-blue   { background: linear-gradient(160deg, #0b83aa, #00647f); }

/* ===== Feature strip ===== */
.features { display: grid; grid-template-columns: repeat(3,1fr); gap: 26px; }
.feature { text-align: center; }
.feature__ic { width: 62px; height: 62px; border-radius: 16px; display:grid; place-items:center; margin: 0 auto 14px; background: var(--bg-alt); color: var(--navy); font-size: 1.6rem; }

/* ===== Value / trust band ===== */
.band-navy { background: var(--bg-navy); color: #fff; }
.band-navy h2, .band-navy h3 { color: #fff; }
.band-navy .lead { color: rgba(255,255,255,.85); }
.stats { display:grid; grid-template-columns: repeat(4,1fr); gap: 20px; text-align:center; }
/* #4a9e2f passes AA large-text on BOTH the navy band (4.1:1) and white (3.4:1),
   so the stat pops on-brand and stays AA even where a tool can't composite the band bg. */
.stat__num { font-family: var(--font-head); font-weight: 800; font-size: 2.6rem; color: #4a9e2f; line-height:1; }
.stat__lbl { font-size: .95rem; color: rgba(255,255,255,.85); margin-top: 6px; }

/* ===== Insurance logos row ===== */
.pill-row { display:flex; flex-wrap:wrap; gap:12px; justify-content:center; }
.pill { background:#fff; border:1px solid var(--line); border-radius: 40px; padding: 10px 20px; font-family: var(--font-head); font-weight:600; font-size:.92rem; color: var(--navy); box-shadow: 0 2px 8px rgba(31,36,48,.05); }

/* ===== Steps ===== */
.steps { display:grid; grid-template-columns: repeat(3,1fr); gap: 24px; counter-reset: step; }
.step { background:#fff; border:1px solid var(--line); border-radius: var(--radius); padding: 28px 24px; position:relative; }
.step::before { counter-increment: step; content: counter(step); position:absolute; top:-18px; left:24px; width:44px; height:44px; border-radius:50%; background: var(--green); color:#14330a; font-family:var(--font-head); font-weight:800; display:grid; place-items:center; font-size:1.2rem; box-shadow: var(--shadow); }

/* ===== Testimonials ===== */
.quotes { display:grid; grid-template-columns: repeat(3,1fr); gap: 22px; }
.quote { background:#fff; border:1px solid var(--line); border-radius: var(--radius); padding: 26px; box-shadow: var(--shadow); }
.quote__stars { color: var(--orange-700); letter-spacing:2px; margin-bottom: 8px; }
.quote p { font-style: italic; color: var(--ink); }
.quote__who { font-family:var(--font-head); font-weight:700; color: var(--navy); font-style: normal; margin-top: 8px; }

/* ===== Locations preview ===== */
.locs { display:grid; grid-template-columns: repeat(3,1fr); gap: 18px; }
.loc { background:#fff; border:1px solid var(--line); border-radius: var(--radius-sm); padding: 20px; }
.loc h3 { font-size: 1.05rem; margin-bottom: 4px; }
.loc address { font-style: normal; color: var(--ink-soft); font-size: .95rem; margin-bottom: 8px; }
.loc a { font-family: var(--font-head); font-weight:700; font-size:.92rem; text-decoration:none; }

/* ===== CTA band ===== */
.cta-band { background: linear-gradient(120deg, var(--green-700), var(--blue-700)); color:#fff; border-radius: 20px; padding: 46px; text-align:center; box-shadow: var(--shadow-lg); }
.cta-band h2 { color:#fff; }
.cta-band p { color: rgba(255,255,255,.92); }

/* ===== Footer ===== */
.site-footer { background: var(--navy-800); color: rgba(255,255,255,.82); padding: 56px 0 26px; }
.site-footer h4 { color:#fff; font-size: 1rem; letter-spacing:.5px; margin-bottom: 14px; }
.foot-grid { display:grid; grid-template-columns: 1.4fr 1fr 1fr 1.2fr; gap: 32px; }
.site-footer a { color: rgba(255,255,255,.82); text-decoration:none; display:block; padding: 4px 0; }
.site-footer a:hover { color:#fff; text-decoration: underline; }
.foot-logo img { height: 46px; width: auto; max-width: 160px; object-fit: contain; aspect-ratio: auto; margin-bottom: 14px; filter: brightness(0) invert(1); }
.foot-bottom { border-top: 1px solid rgba(255,255,255,.15); margin-top: 34px; padding-top: 18px; font-size: .86rem; display:flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; }

/* ===== Page hero (interior) ===== */
.page-hero { background: linear-gradient(120deg, var(--navy), #34327a); color:#fff; padding: 54px 0; }
.page-hero h1 { color:#fff; margin-bottom: 6px; }
.breadcrumb { font-size:.88rem; color: rgba(255,255,255,.8); }
.breadcrumb a { color:#fff; }

/* ===== Generic content ===== */
.prose { max-width: 72ch; }
.prose h2 { margin-top: 1.6em; }
.grid-2 { display:grid; grid-template-columns: 1fr 1fr; gap: 34px; align-items:center; }
.tile-list { list-style:none; padding:0; margin:0; display:grid; gap:10px; }
.tile-list li { background:#fff; border:1px solid var(--line); border-radius: var(--radius-sm); padding: 14px 18px; display:flex; gap:12px; align-items:center; }
.tile-list li::before { content:"✓"; color: var(--green-700); font-weight:800; }

/* ===== Form ===== */
.form-card { background:#fff; border:1px solid var(--line); border-radius: var(--radius); padding: 30px; box-shadow: var(--shadow); }
.field { margin-bottom: 18px; }
.field label { display:block; font-family: var(--font-head); font-weight:600; color: var(--navy); margin-bottom: 6px; font-size:.95rem; }
.field .req { color: var(--orange-700); }
.field input, .field select, .field textarea {
  width:100%; padding: 12px 14px; border:1.5px solid var(--line); border-radius: 10px; font: inherit; color: var(--ink); background:#fff;
}
.field input:focus, .field select:focus, .field textarea:focus { border-color: var(--blue-700); outline: 3px solid rgba(0,100,127,.25); outline-offset:0; }
.field .hint { font-size:.85rem; color: var(--ink-soft); margin-top: 5px; }
fieldset { border:1px solid var(--line); border-radius: var(--radius-sm); padding: 18px; margin: 0 0 18px; }
fieldset legend { font-family:var(--font-head); font-weight:700; color: var(--navy); padding: 0 8px; }
.form-row { display:grid; grid-template-columns: 1fr 1fr; gap: 16px; }

/* ===== Utilities ===== */
.mt-0{margin-top:0}.mb-0{margin-bottom:0}
.stack-sm > * + * { margin-top: .6rem; }
.note { background: #fff8ec; border:1px solid #f4d9a6; border-radius: var(--radius-sm); padding: 14px 16px; font-size:.92rem; color: #5c4409; }

/* ===== Responsive ===== */
@media (max-width: 960px) {
  .hero__grid { grid-template-columns: 1fr; min-height: 0; }
  .hero__img { height: 300px; }
  .hero__img img { position: static; height: 100%; object-position: center; }
  .hero__img img.hero__slide { position: absolute; }
  .cards { grid-template-columns: repeat(2, 1fr); }
  .features, .steps, .quotes, .locs, .stats { grid-template-columns: 1fr 1fr; }
  .grid-2, .form-row { grid-template-columns: 1fr; }
  .foot-grid { grid-template-columns: 1fr 1fr; }
  .nav__menu, .nav__phone { display: none; }
  .nav__toggle { display: block; }
  .nav__menu--open { display: flex; position: absolute; top: 100%; left:0; right:0; flex-direction: column; background:#fff; border-bottom:1px solid var(--line); padding: 10px; gap: 2px; box-shadow: var(--shadow-lg); align-items: stretch; }
  .nav__menu--open .has-sub > button { width:100%; justify-content: space-between; }
  .nav__menu--open .submenu { position: static; box-shadow:none; border:0; padding-left: 14px; display:block; }
}
@media (max-width: 560px) {
  .cards, .features, .steps, .quotes, .locs, .stats, .foot-grid { grid-template-columns: 1fr; }
  .section { padding: 52px 0; }
  .cta-band { padding: 32px 22px; }
}
@media (prefers-reduced-motion: reduce) {
  * { scroll-behavior: auto !important; transition: none !important; }
  .hero__img img.hero__slide { animation: none; opacity: 0; }
  .hero__img img.hero__slide:nth-child(1) { opacity: 1; }
  .btn:hover, .card-cat:hover { transform: none; }
}

/* ===== Bravo Smiles brand helpers (2026-09-23 nightly) ===== */
.bravo-smiles-mark { display:flex; flex-wrap:wrap; align-items:center; gap:14px; background:#fff; border:1px solid var(--line); border-radius:var(--radius); padding:16px 22px; }
.bravo-smiles-mark img { height:56px; width:auto; object-fit:contain; }
.free-emphasis { font-size: clamp(1.25rem, 2.4vw, 1.55rem); font-weight: 800; color: #fff; }
.free-emphasis .free-word { color: #b8f08a; text-transform: uppercase; letter-spacing: .5px; font-size: 1.15em; }
.ortho-spotlight { background: var(--bg-alt); border: 1px solid var(--line); border-radius: var(--radius); padding: 28px 24px; margin-bottom: 28px; }
.ortho-spotlight .bravo-smiles-mark { margin-bottom: 14px; }

/* ===== 2026-10-05 nightly ===== */
@media (min-width: 961px) and (max-width: 1240px) {
  .nav { gap: 10px; padding-inline: 14px; }
  .nav__logo img { height: 54px; }
  .nav__logo img.nav__logo-smiles { height: 53px; }
  .nav__menu a, .has-sub > button { font-size: .8rem; padding: 8px 6px; }
  .nav__phone { font-size: .9rem; }
  .nav__cta .btn { font-size: 1rem; padding: 12px 18px; }
}
.page-hero__split { display: flex; align-items: center; justify-content: space-between; gap: 28px; }
.page-hero__text { flex: 1 1 auto; min-width: 0; }
.page-hero__logo { flex: 0 0 auto; background: #fff; border-radius: var(--radius); padding: 14px 20px; box-shadow: var(--shadow-lg); }
.page-hero__logo img { display: block; height: 130px; width: auto; object-fit: contain; }
@media (max-width: 760px) { .page-hero__split { flex-direction: column; align-items: flex-start; } .page-hero__logo img { height: 96px; } }
.smile-photos { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.smile-photos img { width: 100%; height: 300px; object-fit: cover; object-position: center top; border-radius: var(--radius); border: 1px solid var(--line); background: #fff; }
@media (max-width: 560px) { .smile-photos { grid-template-columns: 1fr; } .smile-photos img { height: 240px; } }
.loc-map { margin: 0 0 14px; }
.loc-map img { display: block; width: 100%; height: auto; border: 1px solid var(--line); border-radius: var(--radius); background: #f4f2ee; }
.loc-map figcaption { font-size: .85rem; color: var(--ink-soft); margin-top: 6px; }
.loc-num { display: inline-grid; place-items: center; width: 1.6em; height: 1.6em; margin-right: 8px; border-radius: 50%; background: var(--green); color: #14330a; font-size: .8em; font-weight: 800; vertical-align: middle; }
.loc-num--fw { background: #c2410c; color: #fff; }

/* 2026-10-14: home nav logos as separate links; compact 11-location grid on home */
.nav__logo a { display: flex; align-items: center; text-decoration: none; }
.locs--compact { grid-template-columns: repeat(4,1fr); gap: 12px; }
.locs--compact .loc { padding: 12px 14px; }
.locs--compact .loc h3 { font-size: .95rem; }
.locs--compact .loc address { font-size: .85rem; margin-bottom: 4px; }
.locs--compact .loc a, .locs--compact .loc span { font-size: .85rem; }
@media (max-width: 1000px) { .locs--compact { grid-template-columns: repeat(3,1fr); } }
@media (max-width: 760px) { .locs--compact { grid-template-columns: 1fr 1fr; } }
@media (max-width: 480px) { .locs--compact { grid-template-columns: 1fr; } }
