/* ==========================================================================
   BBM — dark appearance
   A navy-tinted night surface, not an inverted beige. Cream, coral and the
   signature bands keep their identity; paper, ink and hairlines retune.
   Loaded last, scoped to html[data-theme="dark"].
   ========================================================================== */

html[data-theme="dark"] {
  color-scheme: dark;

  --paper: #0b1622;
  --paper-2: #101f2e;
  --canvas: #0e1b28;
  --mist: #132535;

  --ink: #f2ece0;
  --body: #c6d2dd;
  --muted: #9aa9b7;
  --line: #26384a;
  --line-cool: #223445;
  --line-strong: #41566b;

  --harbour: #8fbde6;
  --harbour-deep: #c4dcf2;
  --harbour-soft: #17304a;
  --link: #8dc1f5;
  --link-active: #b9d9fb;

  --coral: #e17a52;
  --coral-deep: #f3a184;
  --coral-soft: #33201a;

  --navy: #071019;
  --navy-2: #0c1a27;

  --tone-mint: #132a2d;
  --tone-peach: #2c1d17;
  --tone-sand: #272318;
  --tone-lilac: #1d2030;

  --shadow-soft: 0 1px 2px rgba(0, 0, 0, .5), 0 12px 30px rgba(0, 0, 0, .35);
  --shadow-lift: 0 2px 6px rgba(0, 0, 0, .55), 0 28px 64px rgba(0, 0, 0, .45);
  --shadow-button: 0 1px 2px rgba(0, 0, 0, .5), 0 6px 18px rgba(0, 0, 0, .3);
}

html[data-theme="dark"] body { background: var(--paper); }

/* Header & utility strip */
html[data-theme="dark"] .app-bar { background: #0c1824; border-bottom-color: var(--line); }
html[data-theme="dark"] .app-bar.is-scrolled { box-shadow: 0 10px 28px rgba(0, 0, 0, .45); }
html[data-theme="dark"] .theme-bar { background: #08121c; border-bottom-color: #1b2b3a; }
html[data-theme="dark"] .theme-toggle { background: #0e1b28; border-color: #33475a; }
html[data-theme="dark"] .theme-toggle__track { background: #33475a; }
html[data-theme="dark"] .theme-toggle__track::after { background: var(--cream); }
html[data-theme="dark"] .app-bar__call { border-color: #2a3c4e; color: var(--ink); }
html[data-theme="dark"] .app-bar__call:hover { background: #101f2e; border-color: #4a6177; }
html[data-theme="dark"] .icon-btn { background: #0e1b28; border-color: #2a3c4e; color: var(--ink); }
html[data-theme="dark"] .icon-btn:hover { background: #142434; border-color: #4a6177; }

/* Nav sheet */
html[data-theme="dark"] .nav-sheet { background: #0c1824; border-left-color: var(--line); }
html[data-theme="dark"] .nav-sheet__phone { background: #101f2e; border-color: var(--line); }
html[data-theme="dark"] .nav-sheet__links a { border-bottom-color: var(--line); }
html[data-theme="dark"] .nav-sheet__head { border-bottom-color: var(--line); }

/* Buttons */
html[data-theme="dark"] .btn--filled,
html[data-theme="dark"] .at-btn--solid { --btn-bg: var(--cream); --btn-ink: #0b1723; --btn-border: var(--cream); }
html[data-theme="dark"] .btn--filled:hover,
html[data-theme="dark"] .at-btn--solid:hover { --btn-bg: #fff6e4; --btn-border: #fff6e4; }
html[data-theme="dark"] .btn--outline,
html[data-theme="dark"] .at-btn--line { --btn-ink: var(--ink); --btn-border: #41566b; }
html[data-theme="dark"] .btn--outline:hover,
html[data-theme="dark"] .at-btn--line:hover { --btn-bg: #132333; --btn-border: var(--ink); }
html[data-theme="dark"] .btn--tonal { --btn-bg: #17304a; --btn-ink: #d5e6f6; }
html[data-theme="dark"] .btn--tonal:hover { --btn-bg: #1c3b58; }
html[data-theme="dark"] .btn--ghost { --btn-ink: var(--link); }

/* Cards & pastel demo surfaces */
html[data-theme="dark"] .card { border-color: var(--line); }
html[data-theme="dark"] .card--mint,
html[data-theme="dark"] .card--peach,
html[data-theme="dark"] .card--sand,
html[data-theme="dark"] .card--lilac { border-color: transparent; }
html[data-theme="dark"] .card__icon { background: var(--cream); color: #0b1723; }
html[data-theme="dark"] .chip { background: #101f2e; border-color: var(--line); }
html[data-theme="dark"] .area-band { background: #0e1b28; border-color: var(--line); }

/* Forms */
html[data-theme="dark"] .quote-card,
html[data-theme="dark"] .at-quote__card { border-color: var(--line); background: #0f1d2b; }
html[data-theme="dark"] .quote-card__head { background: #0f1d2b; border-bottom-color: var(--line); }
html[data-theme="dark"] .field input,
html[data-theme="dark"] .field select,
html[data-theme="dark"] .field textarea { background: #0b1622; border-color: #5a7489; color: var(--ink); }
html[data-theme="dark"] .field input::placeholder { color: #7f90a1; }
html[data-theme="dark"] .field input:focus { border-color: var(--link); box-shadow: 0 0 0 3px rgba(141, 193, 245, .2); }
html[data-theme="dark"] .quote-card__preview,
html[data-theme="dark"] .at-form__preview { background: #101f2e; color: var(--body); border-color: var(--line); border-left-color: var(--coral); }
html[data-theme="dark"] .quote-card__preview code,
html[data-theme="dark"] .at-form__preview code { background: rgba(0, 0, 0, .3); }
html[data-theme="dark"] .quote-card__compare { background: #0b1622; border-top-color: var(--line); }
html[data-theme="dark"] .at-form__head { background: #071019; }
html[data-theme="dark"] .aside-card { background: #0e1b28; border-color: var(--line); }
html[data-theme="dark"] .aside-card--contact { background: #12222f; }

/* Home bands */
html[data-theme="dark"] .at-hero { background: var(--paper); }
html[data-theme="dark"] .at-story { background: #08131d; }
html[data-theme="dark"] .at-story__grid { background: #0a1520; box-shadow: inset 0 0 0 1px #1c2e3f; }
html[data-theme="dark"] .at-index { background: var(--paper); }
html[data-theme="dark"] .at-index__row:hover { background: #122333; }
html[data-theme="dark"] .at-index__art { background: #132333; }
html[data-theme="dark"] .at-fleet { background: #7c2f14; }
html[data-theme="dark"] .at-fleet__item { background: var(--cream); color: #33414f; }
html[data-theme="dark"] .at-fleet__item h3 { color: #101d2b; }
html[data-theme="dark"] .at-fleet__item p { color: #33414f; }
html[data-theme="dark"] .at-fleet__top { color: #5e6c7a; border-bottom-color: rgba(16, 29, 43, .14); }
html[data-theme="dark"] .at-fleet__top span:first-child { color: #852e12; }
html[data-theme="dark"] .at-fleet__item a { color: #16436b; }
html[data-theme="dark"] .at-fleet__item a:hover { color: #a83c1a; }
html[data-theme="dark"] .at-local { background: #0a141e; }
html[data-theme="dark"] .at-local__media { background: #132a3c; }
html[data-theme="dark"] .at-faq { background: var(--paper); }
html[data-theme="dark"] .at-faq__panel { background: #12222f; box-shadow: inset 0 0 0 1px #22384a; }
html[data-theme="dark"] .at-faq__item { border-bottom-color: #2a3d4e; }
html[data-theme="dark"] .at-cta { background: #0f3354; }
html[data-theme="dark"] .at-marquee { background: #8c3315; }
html[data-theme="dark"] .at-marquee__track { color: #fbe9db; }

/* Inner pages */
html[data-theme="dark"] .page-hero { background: var(--paper); border-bottom-color: var(--line); }
html[data-theme="dark"] .page-hero__art { background: #132333; box-shadow: none; }
html[data-theme="dark"] .page-hero__art::after { box-shadow: inset 0 0 0 1px #24384a; }
html[data-theme="dark"] .page-hero__art img { filter: brightness(.9) saturate(.94); }
html[data-theme="dark"] .quote-hero { background: var(--paper); }
html[data-theme="dark"] .service-row { background: #0e1b28; border-color: var(--line); }
html[data-theme="dark"] .service-row__media { background: #132333; }
html[data-theme="dark"] .service-row__num { background: rgba(7, 16, 25, .9); color: var(--cream); }
html[data-theme="dark"] .share-box { background: #12222f; }
html[data-theme="dark"] .section--stage { background: #071019; }
html[data-theme="dark"] .section--low { background: #101f2e; }
html[data-theme="dark"] .cta-band { background: #132a3e; }
html[data-theme="dark"] .pricing-banner { background: #071019; }
html[data-theme="dark"] .metric-card { background: #071019; }
html[data-theme="dark"] .truck-crew-panel { background: #071019; }
html[data-theme="dark"] .guide-phase { background: #0e1b28; border-color: var(--line); }
html[data-theme="dark"] .checklist-toolbar { background: #0e1b28; border-color: var(--line); }
html[data-theme="dark"] .check-item { border-bottom-color: var(--line); }
html[data-theme="dark"] .check-item input[type="checkbox"] { background: #0b1622; border-color: #5a7489; }
html[data-theme="dark"] .check-item input[type="checkbox"]:checked { background: #16436b; border-color: #16436b; }
html[data-theme="dark"] .field-error { color: #ff9d90; }
html[data-theme="dark"] .field input.invalid { border-color: #ff9d90; }
html[data-theme="dark"] .form-status { background: #3a1d19; border-color: #8c3b30; color: #ffb4a8; }
html[data-theme="dark"] .editorial-plate { background: #132333; }
html[data-theme="dark"] .editorial-plate img { filter: brightness(.9) saturate(.95); }
html[data-theme="dark"] .editorial-plate figcaption { background: rgba(12, 24, 36, .92); color: var(--body); }
html[data-theme="dark"] .faq-group { background: #0e1b28; border-color: var(--line); }
html[data-theme="dark"] .still-question { background: #12222f; }
html[data-theme="dark"] .legal-index { background: #0e1b28; border-color: var(--line); }
html[data-theme="dark"] .legal-index a:hover { background: #16293b; }
html[data-theme="dark"] .legal-index a[aria-current="true"] { background: var(--cream); color: #0b1723; }
html[data-theme="dark"] .legal-note { background: #12222f; }
html[data-theme="dark"] .table-wrap { background: #0e1b28; border-color: var(--line); }
html[data-theme="dark"] .compare-table th { background: #101f2e; }
html[data-theme="dark"] .compare-table th,
html[data-theme="dark"] .compare-table td { border-bottom-color: var(--line); }
html[data-theme="dark"] .status-chip,
html[data-theme="dark"] .progress-pill { background: #0e1b28; border-color: var(--line); }
html[data-theme="dark"] .segmented button:hover { background: #16293b; }
html[data-theme="dark"] .segmented button[aria-pressed="true"] { background: var(--cream); color: #0b1723; }
html[data-theme="dark"] .filter-bar { background: #0e1b28; border-color: var(--line); }

/* Footer stays the same deep navy in both appearances, with a clearer edge */
html[data-theme="dark"] .site-footer { background: #060e16; border-top: 1px solid #1b2b3a; }
html[data-theme="dark"] .sf-invite em { color: #f3a184; }
html[data-theme="dark"] .sf-mark__forward-logo { filter: none; }

/* Mobile bottom navigation */
html[data-theme="dark"] .bottom-nav { background: #0c1824; border-top-color: var(--line); box-shadow: 0 -8px 24px rgba(0, 0, 0, .4); }
html[data-theme="dark"] .bottom-nav__quote { color: var(--ink) !important; }
html[data-theme="dark"] .bottom-nav__quote-icon { background: var(--cream); color: #0b1723; }

/* Focus visibility on dark surfaces */
html[data-theme="dark"] :focus-visible { outline-color: #8dc1f5; }
html[data-theme="dark"] .site-footer :focus-visible { outline-color: var(--cream); }
