/* =========================================================================
   PROTERM — design system CSS
   Source: Proterm brand & interface guide v1.0 (Claude Design export, Aug 2026)
   Palette: Proterm Red + Slate-900 + slate ramp + white. Type: Bitter + Figtree.
   ========================================================================= */

:root {
  /* --- Brand color --- */
  --color-red: #E02B20;
  --color-red-dark: #C81E14;   /* paragraph-safe red, 4.5:1 on white; also primary hover */
  --color-red-tint: #FEE9E7;
  --color-red-hairline: #F2A09A;

  /* --- Slate ramp (working greys) --- */
  --color-slate-900: #0F172A;
  --color-slate-800: #1E293B;
  --color-slate-700: #334155;
  --color-slate-600: #475569;
  --color-slate-500: #64748B;
  --color-slate-400: #94A3B8;
  --color-slate-300: #CBD5E1;
  --color-slate-200: #E2E8F0;
  --color-slate-100: #F1F5F9;
  --color-slate-50:  #F8FAFC;

  --color-black: #000000;
  --color-white: #FFFFFF;

  /* --- Role aliases --- */
  --color-bg: var(--color-white);
  --color-bg-alt: var(--color-slate-50);
  --color-text: var(--color-slate-900);
  --color-body: var(--color-slate-600);
  --color-muted: var(--color-slate-500);
  --color-border: var(--color-slate-200);

  /* --- Type --- */
  --font-heading: "Bitter", Georgia, "Times New Roman", serif;
  --font-body: "Figtree", system-ui, -apple-system, "Segoe UI", sans-serif;

  /* --- Radius scale --- */
  --radius-sm: 10px;
  --radius-md: 12px;
  --radius-lg: 14px;
  --radius-pill: 999px;

  /* --- Shadows: two-layer, slate-tinted, never pure black --- */
  --shadow-sm: 0 1px 2px rgba(15, 23, 42, 0.06), 0 1px 1px rgba(15, 23, 42, 0.04);
  --shadow-md: 0 8px 20px -6px rgba(15, 23, 42, 0.16), 0 2px 6px rgba(15, 23, 42, 0.08);
  --shadow-lg: 0 20px 44px -12px rgba(15, 23, 42, 0.24), 0 6px 16px rgba(15, 23, 42, 0.10);

  --container-w: 1240px;
  --header-h: 76px;
}

/* =========================================================================
   RESET
   ========================================================================= */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; overflow-x: hidden; }
body {
  margin: 0;
  background: var(--color-bg);
  color: var(--color-body);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
  /* .mobile-menu is `position:fixed` + `transform:translateX(100%)` to sit
     off-canvas; that combination can get pulled into the document's
     scrollable-overflow box after a reflow (e.g. the wizard's
     scrollIntoView), which would otherwise expose real horizontal scroll. */
}
img { max-width: 100%; display: block; }
/* color/background/border/appearance reset: without this, unstyled-by-class button
   properties fall back to the browser's native button chrome — most notably iOS
   Safari, which tints default buttons with the system accent color (blue), which
   then leaks into any icon inside via currentColor. Components that need their own
   background/border (.nav-toggle, .seg-opt, etc.) already set those explicitly and
   are unaffected. */
button {
  font-family: inherit; color: inherit; background: none; border: none;
  appearance: none; -webkit-appearance: none; cursor: pointer;
}
a { color: inherit; text-decoration: none; }
ul, ol { margin: 0; padding: 0; list-style: none; }
h1, h2, h3, h4, h5, h6 { margin: 0; font-family: var(--font-heading); color: var(--color-text); font-weight: 700; }
p { margin: 0; }
::selection { background: var(--color-red); color: #fff; }

a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
[tabindex]:focus-visible {
  outline: 2px solid var(--color-red);
  outline-offset: 2px;
}

/* =========================================================================
   TYPE SCALE
   ========================================================================= */
h1, .h1 {
  font-weight: 800;
  font-size: clamp(2.1rem, 1.4rem + 3.2vw, 3.75rem);
  line-height: 1.05;
  letter-spacing: -0.015em;
}
h2, .h2 {
  font-weight: 700;
  font-size: clamp(1.6rem, 1.25rem + 1.6vw, 2.375rem);
  line-height: 1.15;
  letter-spacing: -0.015em;
}
h3, .h3 {
  font-weight: 700;
  font-size: 1.375rem;
  line-height: 1.3;
}
.eyebrow {
  display: block;
  font-family: var(--font-body);
  font-weight: 800;
  font-size: 0.75rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--color-red-dark);
  margin-bottom: 10px;
}
.lede {
  font-size: 1.05rem;
  color: var(--color-body);
}
.caption, small, .meta, .muted {
  font-size: 0.875rem;
  color: var(--color-muted);
}
.section-head { max-width: 640px; margin-bottom: 36px; }
.section-head p { margin-top: 14px; }

/* =========================================================================
   LAYOUT
   ========================================================================= */
.container { max-width: var(--container-w); margin: 0 auto; padding: 0 24px; }
.section { padding: 72px 0; }
.section--tight { padding: 48px 0; }
.section--alt { background: var(--color-bg-alt); }
.section--dark { background: var(--color-slate-900); color: var(--color-slate-300); }
.section--dark h2, .section--dark h3 { color: #fff; }

/* Scroll-reveal — .reveal is only ever added by JS (main.js), so a no-JS
   visitor never sees this: every section is simply visible immediately,
   same as before this feature existed. .is-visible is added either right
   away (content already in the viewport on load, e.g. the hero — no
   transition, so nothing "pops" on page load) or when the user scrolls the
   section into view. */
.reveal { opacity: 0; transform: translateY(28px); transition: opacity .7s ease, transform .7s ease; }
.reveal.is-visible { opacity: 1; transform: translateY(0); }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
}
.grid { display: grid; gap: 24px; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
.grid-6 { grid-template-columns: repeat(6, 1fr); }
.two-col { display: grid; grid-template-columns: 1.05fr 0.95fr; gap: 56px; align-items: start; }
.two-col--rev { grid-template-columns: 0.95fr 1.05fr; }
.two-col--rev > *:first-child { order: 2; }
.hr { border: none; border-top: 1px solid var(--color-border); margin: 0; }
.visually-hidden {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0;
}
.skip-link {
  position: absolute; left: 12px; top: -60px; z-index: 200;
  background: var(--color-slate-900); color: #fff; padding: 10px 18px;
  border-radius: var(--radius-sm); transition: top .15s ease;
}
.skip-link:focus { top: 12px; }

@media (max-width: 900px) {
  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
  .grid-6 { grid-template-columns: repeat(2, 1fr); }
  .two-col, .two-col--rev { grid-template-columns: 1fr; gap: 32px; }
  .two-col--rev > *:first-child { order: 0; }
  .section { padding: 52px 0; }
}

/* =========================================================================
   ICONS  (Lucide-style, stroke 2.25, round caps/joins)
   ========================================================================= */
.icon {
  width: 20px; height: 20px; flex: none;
  stroke: currentColor; fill: none;
  stroke-width: 2.25; stroke-linecap: round; stroke-linejoin: round;
}
.icon--sm { width: 16px; height: 16px; }
.icon--lg { width: 26px; height: 26px; }

.icon-tile {
  width: 46px; height: 46px; border-radius: var(--radius-md);
  display: flex; align-items: center; justify-content: center; flex: none;
}
.icon-tile--accent { background: var(--color-red-tint); color: var(--color-red-dark); }
.icon-tile--neutral { background: var(--color-slate-100); color: var(--color-slate-700); }

/* =========================================================================
   BUTTONS
   ========================================================================= */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font-family: var(--font-body); font-weight: 700; font-size: 0.95rem;
  height: 48px; padding: 0 22px; border-radius: var(--radius-md);
  border: none; cursor: pointer; white-space: nowrap;
  transition: background-color .15s ease, color .15s ease, border-color .15s ease, transform .15s ease, box-shadow .15s ease;
  text-align: center;
}
.btn svg { width: 16px; height: 16px; flex: none; }
.btn-primary { background: var(--color-red); color: #fff; box-shadow: var(--shadow-sm); }
.btn-primary:hover { background: var(--color-red-dark); transform: translateY(-1px); box-shadow: var(--shadow-md); }
.btn-secondary { background: #fff; color: var(--color-slate-900); border: 2px solid var(--color-slate-300); }
.btn-secondary:hover { border-color: var(--color-slate-500); }
.btn-ghost { background: transparent; color: var(--color-slate-700); }
.btn-ghost:hover { background: var(--color-slate-100); }
.btn-on-dark { background: #fff; color: var(--color-slate-900); }
.btn-on-dark:hover { background: var(--color-slate-100); }
.btn-lg { height: 56px; padding: 0 28px; border-radius: var(--radius-lg); font-size: 1rem; }
.btn-sm { height: 38px; padding: 0 16px; border-radius: var(--radius-sm); font-size: 0.85rem; }
.btn-block { width: 100%; }
.btn:disabled { opacity: 0.45; cursor: not-allowed; transform: none !important; }

.link {
  color: var(--color-red-dark); font-weight: 700; text-decoration: none;
  border-bottom: 2px solid transparent;
}
.link:hover { border-bottom-color: currentColor; }
.link--ghost-nav { color: var(--color-slate-700); font-weight: 600; }

/* =========================================================================
   TAGS / BADGES / PILLS
   ========================================================================= */
.pill-group { display: flex; flex-wrap: wrap; gap: 10px; }
.tag {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 0.82rem; font-weight: 700; color: var(--color-slate-700);
  background: var(--color-slate-100); border-radius: var(--radius-pill);
  padding: 8px 14px; line-height: 1;
}
.tag--accent { background: var(--color-red-tint); color: var(--color-red-dark); }
.tag--outline { background: transparent; border: 1.5px solid var(--color-slate-300); }
.badge {
  display: inline-flex; align-items: center; font-size: 0.72rem; font-weight: 800;
  text-transform: uppercase; letter-spacing: 0.04em;
  color: #fff; background: var(--color-red); border-radius: var(--radius-pill);
  padding: 5px 11px;
}
.badge--slate { background: var(--color-slate-700); }
.badge--corner { position: absolute; top: 16px; right: 16px; }

/* =========================================================================
   CARDS
   ========================================================================= */
.card {
  position: relative;
  background: #fff; border: 1px solid var(--color-border); border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm); padding: 28px;
}
.card--interactive { transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease; }
.card--interactive:hover, .card--interactive:focus-within {
  transform: translateY(-2px); box-shadow: var(--shadow-md); border-color: var(--color-slate-300);
}
.card--flat { box-shadow: none; }
/* For single-line label cards (e.g. commercial "42 commercial accounts" chips) —
   plain .card left-aligns content at the top of its 28px padding box, which reads
   unevenly once a neighboring card's text wraps to a second line. Centering both
   axes keeps every card in the row balanced regardless of wrap. */
.card--centered { display: flex; align-items: center; justify-content: center; text-align: center; }
/* Utility: vertically center a single grid/flex item within its row — used where a
   lone element (e.g. one CTA button) sits next to taller sibling content and would
   otherwise stick to the top of the row via .two-col's align-items:start. */
.self-center { align-self: center; }
.card--dark {
  background: var(--color-slate-900); color: var(--color-slate-300);
  border: none; box-shadow: var(--shadow-lg);
}
.card--dark h3, .card--dark strong { color: #fff; }
/* .stat-tile strong/span (below) are same specificity as the rules above and defined
   later in the file, so source order let them win and silently overrode the dark-card
   text colors — bump specificity here so dark cards always win regardless of order. */
.card--dark.stat-tile strong { color: #fff; }
.card--dark.stat-tile span { color: var(--color-slate-300); } /* .stat-tile span defaults to slate-500 (--color-muted), which fails contrast on the dark slate-900 card background — brand guide: dark-ground body copy uses Slate 300, never Slate 500 */
.team-avatar {
  width: 84px; height: 84px; border-radius: 999px; background: var(--color-slate-100);
  display: flex; align-items: center; justify-content: center; margin: 0 auto 16px;
  color: var(--color-slate-400); overflow: hidden;
}
.team-avatar img { width: 100%; height: 100%; object-fit: cover; }
.card-kicker { font-size: 0.72rem; font-weight: 800; letter-spacing: 0.1em; text-transform: uppercase; color: var(--color-red-dark); }
.card-title { font-family: var(--font-heading); font-weight: 700; font-size: 1.15rem; margin: 8px 0 8px; color: var(--color-text); }
.card-body { color: var(--color-body); font-size: 0.95rem; }
.card-meta { font-size: 0.82rem; color: var(--color-muted); margin-top: 10px; }

/* Stat tiles */
.stat-tile strong { display: block; font-family: var(--font-heading); font-size: 2rem; color: var(--color-text); }
.stat-tile span { font-size: 0.85rem; color: var(--color-muted); }

/* =========================================================================
   FORMS
   ========================================================================= */
/* Honeypot field for spam bots (see includes/honeypot-field.php) — hidden
   off-screen rather than display:none/visibility:hidden, since some bots
   specifically skip those two and still fill in anything else. */
.hp-field { position: absolute; left: -9999px; top: -9999px; width: 1px; height: 1px; overflow: hidden; }
.field { margin-bottom: 18px; }
/* .field is also used as a <fieldset> around radio/checkbox groups (choice
   grids, segmented controls) so the group's <legend> is announced by screen
   readers when they land on an individual option — a bare <label> with no
   `for` has no such association. Reset the browser's default fieldset/legend
   box model so it matches a plain .field div visually. */
fieldset.field { border: none; padding: 0; margin: 0 0 18px; min-width: 0; }
.field label,
.field legend {
  display: block; font-weight: 700; font-size: 0.8rem; color: var(--color-slate-700);
  margin-bottom: 7px; padding: 0;
}
.field .req { color: var(--color-red-dark); }
.field input,
.field select,
.field textarea {
  width: 100%; height: 48px; padding: 0 14px;
  border: 2px solid var(--color-slate-200); border-radius: var(--radius-md);
  font-family: var(--font-body); font-size: 0.95rem; color: var(--color-text);
  background: #fff; transition: border-color .15s ease;
}
.field textarea { height: auto; min-height: 96px; padding: 12px 14px; resize: vertical; }
.field input::placeholder,
.field textarea::placeholder { color: var(--color-slate-400); }
.field input:focus,
.field select:focus,
.field textarea:focus { border-color: var(--color-red); outline: none; }
.field--error input, .field--error textarea { border-color: var(--color-red); background: var(--color-red-tint); }
.field-error-msg { display: flex; align-items: center; gap: 6px; color: var(--color-red-dark); font-size: 0.82rem; margin-top: 7px; font-weight: 600; }
.field input:disabled, .field textarea:disabled { background: var(--color-slate-100); color: var(--color-muted); cursor: not-allowed; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.checkbox-row { display: flex; align-items: flex-start; gap: 10px; font-size: 0.88rem; color: var(--color-body); margin-bottom: 14px; }
.checkbox-row input[type="checkbox"] {
  width: 20px; height: 20px; flex: none; margin: 1px 0 0; accent-color: var(--color-red);
}
.choice-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.choice-card {
  display: block; border: 2px solid var(--color-slate-200); border-radius: var(--radius-md);
  padding: 14px 16px; cursor: pointer; transition: border-color .15s ease, background-color .15s ease;
}
.choice-card input { position: absolute; opacity: 0; pointer-events: none; }
.choice-card strong { display: block; font-size: 0.92rem; color: var(--color-text); }
.choice-card span.sub { display: block; font-size: 0.8rem; color: var(--color-muted); margin-top: 2px; }
.choice-card:has(input:checked) { border-color: var(--color-red); background: var(--color-red-tint); }
.seg { display: inline-flex; border: 2px solid var(--color-slate-200); border-radius: var(--radius-pill); padding: 3px; gap: 2px; flex-wrap: wrap; }
.seg-opt {
  display: inline-flex; align-items: center;
  border: none; background: transparent; border-radius: var(--radius-pill);
  padding: 8px 16px; font-size: 0.85rem; font-weight: 700; color: var(--color-slate-600); cursor: pointer;
}
.seg-opt input { position: absolute; opacity: 0; width: 0; height: 0; pointer-events: none; }
.seg-opt.is-active { background: var(--color-slate-900); color: #fff; }
.upload-drop {
  border: 2px dashed var(--color-slate-300); border-radius: var(--radius-md);
  padding: 20px; display: flex; align-items: center; gap: 14px; cursor: pointer;
  background: var(--color-slate-50); transition: border-color .15s ease, background-color .15s ease;
}
.upload-drop:hover, .upload-drop.is-dragover { border-color: var(--color-red); background: var(--color-red-tint); }
.upload-drop strong { display: block; font-size: 0.92rem; color: var(--color-text); }
.upload-drop span { font-size: 0.8rem; color: var(--color-muted); }
.upload-thumbs { display: flex; gap: 10px; margin-top: 12px; flex-wrap: wrap; }
.upload-thumb {
  width: 64px; height: 64px; border-radius: var(--radius-sm); overflow: hidden;
  position: relative; background: var(--color-slate-100); border: 1px solid var(--color-border);
}
.upload-thumb img { width: 100%; height: 100%; object-fit: cover; }
.upload-thumb button {
  position: absolute; top: 2px; right: 2px; width: 18px; height: 18px; border-radius: 999px;
  background: rgba(15,23,42,.75); color: #fff; border: none; font-size: 11px; line-height: 1; cursor: pointer;
}

@media (max-width: 640px) {
  .form-row, .choice-grid { grid-template-columns: 1fr; }
}

/* =========================================================================
   PHOTO PLACEHOLDER  (until real photography is supplied)
   ========================================================================= */
.photo-placeholder {
  background: var(--color-slate-100); border: 1.5px dashed var(--color-slate-300);
  border-radius: var(--radius-lg); display: flex; flex-direction: column;
  align-items: center; justify-content: center; gap: 10px; color: var(--color-muted);
  aspect-ratio: 4 / 3; text-align: center; padding: 20px;
}
.photo-placeholder svg { width: 34px; height: 34px; opacity: .55; }
.photo-placeholder span { font-size: 0.85rem; font-weight: 600; }
.service-area-map { width: 100%; height: auto; align-self: center; }

/* =========================================================================
   BEFORE / AFTER SLIDER
   One frame instead of two side-by-side images — drag (or tap/arrow-key) the
   handle to reveal more of the "before" pane. Both panes fill the container
   and the "before" pane is clipped with clip-path (not resized), so the
   underlying image/placeholder never gets visually squeezed as it reveals.
   No-JS fallback: --pos defaults to 50%, so it just renders as a static
   half-and-half split, still readable without any script running.
   ========================================================================= */
.ba-slider {
  --pos: 50%;
  position: relative; aspect-ratio: 4 / 3; border-radius: var(--radius-lg);
  overflow: hidden; user-select: none; touch-action: pan-y; cursor: ew-resize;
  box-shadow: var(--shadow-md);
}
.ba-slider__pane { position: absolute; inset: 0; }
.ba-slider__pane .ba-slider__img {
  width: 100%; height: 100%; aspect-ratio: auto; border-radius: 0; border: none;
  -webkit-user-drag: none; user-drag: none; -webkit-touch-callout: none; pointer-events: none;
}
.ba-slider__pane--before { clip-path: inset(0 calc(100% - var(--pos)) 0 0); }
.ba-slider__tag {
  position: absolute; top: 14px; z-index: 2;
  background: rgba(15, 23, 42, 0.72); color: #fff; font-size: 0.72rem; font-weight: 800;
  letter-spacing: 0.06em; text-transform: uppercase; padding: 5px 12px; border-radius: var(--radius-pill);
}
.ba-slider__tag--before { left: 14px; }
.ba-slider__tag--after { right: 14px; }
.ba-slider__handle {
  position: absolute; top: 0; bottom: 0; left: var(--pos); z-index: 3;
  width: 0; transform: translateX(-50%); pointer-events: none;
}
.ba-slider__handle::before {
  content: ""; position: absolute; top: 0; bottom: 0; left: 50%;
  width: 2px; background: #fff; transform: translateX(-50%); box-shadow: 0 0 0 1px rgba(15, 23, 42, 0.15);
}
.ba-slider__grip {
  position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%);
  width: 40px; height: 40px; border-radius: 50%; background: #fff; box-shadow: var(--shadow-md);
  display: flex; align-items: center; justify-content: center; color: var(--color-slate-900);
}
.ba-slider__grip svg { width: 20px; height: 20px; }
.ba-slider:focus-visible { outline: 3px solid var(--color-red); outline-offset: 2px; }

/* =========================================================================
   HEADER / NAV
   ========================================================================= */
.site-header {
  position: sticky; top: 0; z-index: 100; background: #fff;
  border-bottom: 1px solid var(--color-border);
}
.nav-bar {
  height: var(--header-h); display: grid; grid-template-columns: auto 1fr auto;
  align-items: center; gap: 24px;
}
/* Explicit width alongside height: with only height set, CSS Grid's "auto" column
   sizing for .nav-bar was computing the wrong max-content contribution for this
   replaced element and squishing the logo horizontally instead of preserving its
   aspect ratio. Locking both dimensions (source is 1636x418) fixes it reliably. */
.nav-logo img { height: 30px; width: 117px; }
.primary-nav { justify-self: center; display: none; }
.primary-nav ul { display: flex; align-items: center; gap: 30px; }
.primary-nav a {
  font-weight: 700; font-size: 0.92rem; color: var(--color-slate-700);
  display: flex; align-items: center; gap: 4px; padding: 8px 0;
}
.primary-nav a:hover, .primary-nav a.is-active { color: var(--color-slate-900); }
.primary-nav a.is-active { color: var(--color-red-dark); }
.primary-nav .icon--sm { width: 14px; height: 14px; }
.nav-dropdown { position: relative; }
.nav-dropdown-menu {
  /* top:100% with zero gap (no margin-top) so the mouse never crosses a dead
     zone between the "Services" link and the dropdown — a gap here breaks
     :hover before the cursor reaches the menu, closing it prematurely. The
     8px top padding below keeps the same visual breathing room. */
  position: absolute; top: 100%; left: 50%; transform: translateX(-50%);
  background: #fff; border: 1px solid var(--color-border); border-radius: var(--radius-md);
  box-shadow: var(--shadow-md); padding: 8px; padding-top: 12px; min-width: 220px;
  display: none; z-index: 50;
}
.nav-dropdown:hover .nav-dropdown-menu,
.nav-dropdown:focus-within .nav-dropdown-menu { display: block; }
.nav-dropdown-menu a { display: block; padding: 10px 12px; border-radius: var(--radius-sm); font-weight: 600; font-size: 0.88rem; }
.nav-dropdown-menu a:hover { background: var(--color-slate-100); }
.nav-actions { justify-self: end; display: flex; align-items: center; gap: 10px; }
.nav-phone {
  display: none; align-items: center; gap: 7px; font-weight: 700; font-size: 0.9rem;
  color: var(--color-slate-900);
}
.nav-phone .icon { width: 16px; height: 16px; color: var(--color-red-dark); }
/* "Get a quote" is redundant with the mobile header's call button + hamburger menu
   (which itself ends in a "Get a quote" CTA) — keep the mobile header to logo / call / menu. */
.nav-actions .btn-primary { display: none; }
.nav-toggle {
  display: inline-flex; align-items: center; justify-content: center;
  width: 44px; height: 44px; border-radius: var(--radius-md); border: 1.5px solid var(--color-slate-200);
  background: #fff;
}
.nav-call-mobile {
  display: inline-flex; align-items: center; justify-content: center;
  width: 44px; height: 44px; border-radius: var(--radius-md); background: var(--color-red); color: #fff;
}
@media (min-width: 980px) {
  .primary-nav { display: block; }
  .nav-phone { display: inline-flex; }
  .nav-actions .btn-primary { display: inline-flex; }
  .nav-toggle, .nav-call-mobile { display: none; }
}

.mobile-menu {
  position: fixed; inset: 0; z-index: 150; background: #fff;
  transform: translateX(100%); transition: transform .25s ease;
  display: flex; flex-direction: column; overflow-y: auto;
}
.mobile-menu.is-open { transform: translateX(0); }
.mobile-menu__head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 18px 24px; border-bottom: 1px solid var(--color-border);
}
.mobile-menu__logo { height: 24px; width: 94px; } /* explicit width — see .nav-logo img comment */
.mobile-menu__body { padding: 20px 24px; display: flex; flex-direction: column; gap: 4px; }
.mobile-menu__body a {
  padding: 14px 4px; font-weight: 700; font-size: 1.05rem; color: var(--color-slate-900);
  border-bottom: 1px solid var(--color-border);
}
/* Used to be margin-top:auto (pinned to the very bottom of the screen) —
   that made sense when the services sub-list was always expanded and the
   menu filled the screen either way. Now that it's collapsed by default
   (see .mobile-menu__sub above), pinning to the bottom left a big dead gap
   between the links and the buttons. Following right after the links reads
   much better at any sub-list state. */
.mobile-menu__foot { padding: 20px 24px 24px; margin-top: 8px; border-top: 1px solid var(--color-border); display: grid; gap: 10px; }
.mobile-menu__close { background: none; border: none; width: 40px; height: 40px; }

/* Collapsible "Services" row in the mobile menu — the row itself still
   links straight to /services.php; the chevron button only expands/
   collapses the inline sub-list, so tapping "Services" keeps working as a
   direct link instead of being swallowed by the toggle. Collapsed by
   default so the six service links don't push Resources/FAQ/Contact off
   screen. */
.mobile-menu__row { display: flex; align-items: stretch; border-bottom: 1px solid var(--color-border); }
.mobile-menu__row a { flex: 1; border-bottom: none; }
.mobile-menu__sub-toggle {
  display: flex; align-items: center; justify-content: center;
  width: 44px; flex-shrink: 0; border: none; background: transparent; color: var(--color-slate-500);
}
.mobile-menu__sub-toggle svg { width: 20px; height: 20px; transition: transform .2s ease; }
.mobile-menu__sub-toggle[aria-expanded="true"] svg { transform: rotate(180deg); }
.mobile-menu__sub { max-height: 0; overflow: hidden; transition: max-height .3s ease; display: flex; flex-direction: column; }
.mobile-menu__sub.is-open { max-height: 500px; }
.mobile-menu__sub a { padding-left: 18px; font-size: 0.95rem; font-weight: 600; color: var(--color-slate-600); }

/* Breadcrumb */
.breadcrumb { font-size: 0.82rem; color: var(--color-muted); margin-bottom: 14px; }
.breadcrumb a { color: var(--color-muted); font-weight: 600; }
.breadcrumb a:hover { color: var(--color-red-dark); }
.breadcrumb strong { color: var(--color-slate-700); }

/* =========================================================================
   HERO
   ========================================================================= */
.hero { padding: 56px 0 72px; }
.hero .badges-row { margin-top: 22px; }
.hero h1 { margin-top: 14px; }
.hero .lede { margin-top: 18px; max-width: 46ch; }

/* =========================================================================
   STATS BAND
   ========================================================================= */
.stats-band { border-top: 1px solid var(--color-border); border-bottom: 1px solid var(--color-border); }
.stats-band .grid-3, .stats-band .grid-4 { text-align: left; gap: 16px; }

/* =========================================================================
   TESTIMONIALS
   ========================================================================= */
.stars { color: var(--color-red); letter-spacing: 2px; font-size: 0.95rem; margin-bottom: 12px; }
.testimonial p { font-style: italic; color: var(--color-text); }
.testimonial footer { margin-top: 14px; font-size: 0.85rem; color: var(--color-muted); font-style: normal; }

/* =========================================================================
   DARK CTA BAND
   ========================================================================= */
.cta-band {
  background: var(--color-slate-900); color: #fff; border-radius: var(--radius-lg);
  padding: 44px 40px; display: flex; align-items: center; justify-content: space-between;
  gap: 24px; flex-wrap: wrap;
}
.cta-band .eyebrow { color: var(--color-red-hairline); }
.cta-band h2 { color: #fff; font-size: 1.7rem; }
.cta-band p { color: var(--color-slate-300); margin-top: 6px; }
.cta-band__actions { display: flex; gap: 12px; flex-wrap: wrap; }

/* =========================================================================
   FAQ (native <details>/<summary> — no JS needed, keyboard/AT accessible
   for free)
   ========================================================================= */
.faq-list { display: flex; flex-direction: column; gap: 12px; }
.faq-item {
  background: #fff; border: 1px solid var(--color-border); border-radius: var(--radius-lg);
  padding: 4px 22px;
}
.faq-item summary {
  list-style: none; cursor: pointer; padding: 18px 0; display: flex; align-items: center;
  justify-content: space-between; gap: 16px; font-weight: 700; font-family: var(--font-heading);
  font-size: 1.05rem; color: var(--color-text);
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item .faq-chevron { flex-shrink: 0; transition: transform .2s ease; color: var(--color-muted); }
.faq-item[open] .faq-chevron { transform: rotate(180deg); }
.faq-item[open] summary { color: var(--color-red-dark); }
.faq-answer { padding: 0 0 20px; color: var(--color-slate-600); line-height: 1.6; }
.faq-answer p { margin: 0; }

/* =========================================================================
   ARTICLE BODY (blog.php / article.php)
   ========================================================================= */
.article-body { font-size: 1.02rem; line-height: 1.75; color: var(--color-slate-700); }
.article-body p { margin: 0 0 20px; }
.article-body h2 { font-size: 1.3rem; margin: 36px 0 14px; color: var(--color-text); }
.article-body h2:first-child { margin-top: 0; }
.article-body ul, .article-body ol { margin: 0 0 20px; padding-left: 22px; }
.article-body li { margin-bottom: 8px; }

/* =========================================================================
   FOOTER
   ========================================================================= */
.site-footer { background: var(--color-bg-alt); padding-top: 56px; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 32px; padding-bottom: 40px; }
.footer-brand img { height: 26px; margin-bottom: 14px; }
.footer-brand p { font-size: 0.88rem; color: var(--color-muted); max-width: 32ch; }
.footer-col h4 { font-size: 0.75rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--color-muted); margin-bottom: 14px; }
.footer-col ul { display: flex; flex-direction: column; gap: 10px; }
.footer-col a { font-size: 0.92rem; color: var(--color-slate-700); font-weight: 600; }
.footer-col a:hover { color: var(--color-red-dark); }
.footer-bottom {
  border-top: 1px solid var(--color-border); padding: 20px 0; display: flex;
  justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 10px;
  font-size: 0.82rem; color: var(--color-muted);
}
.footer-bottom .links { display: flex; gap: 18px; }
@media (max-width: 900px) {
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 560px) {
  .footer-grid { grid-template-columns: 1fr; }
}

/* =========================================================================
   WIZARD / STEPPER
   ========================================================================= */
.wizard-card { background: #fff; border: 1px solid var(--color-border); border-radius: var(--radius-lg); box-shadow: var(--shadow-md); padding: 28px; }
.wizard-head { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 14px; }
.wizard-head h3 { font-size: 1.15rem; }
.wizard-step-label { font-size: 0.78rem; font-weight: 700; color: var(--color-muted); text-transform: uppercase; letter-spacing: .05em; }
.wizard-progress { display: flex; gap: 6px; margin-bottom: 24px; }
.wizard-progress span { height: 4px; flex: 1; border-radius: 999px; background: var(--color-slate-200); }
.wizard-progress span.is-done, .wizard-progress span.is-active { background: var(--color-red); }
.wizard-actions { display: flex; justify-content: space-between; align-items: center; margin-top: 20px; gap: 12px; }
.wizard-note { font-size: 0.8rem; color: var(--color-muted); margin-top: 14px; }
.wizard-tabs { display: flex; border-bottom: 1px solid var(--color-border); margin-bottom: 28px; }
.wizard-tab {
  display: inline-block; background: none; border: none; padding: 14px 4px; margin-right: 32px; font-weight: 700;
  color: var(--color-muted); border-bottom: 2px solid transparent; font-size: 0.95rem;
}
.wizard-tab.is-done { color: var(--color-slate-700); }
.wizard-tab.is-active { color: var(--color-slate-900); border-bottom-color: var(--color-red); }
.wizard-panel { display: none; }
.wizard-panel.is-active { display: block; }
.no-js .wizard-panel { display: block; }
.no-js .wizard-tabs, .no-js .wizard-progress, .no-js [data-next], .no-js [data-back] { display: none; }
.no-js .mobile-menu { display: none; }
.no-js .nav-toggle { display: none; }
.no-js .ba-slider { cursor: default; } /* dragging needs JS — static 50/50 split still reads fine */
.no-js .ba-slider__grip { display: none; }
.confirm-check {
  width: 60px; height: 60px; border-radius: 999px; background: var(--color-red-tint);
  color: var(--color-red-dark); display: flex; align-items: center; justify-content: center;
  margin: 0 auto 20px;
}
.confirm-block { text-align: center; padding: 24px 0; }
.timeline-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-top: 28px; }
@media (max-width: 700px) { .timeline-3 { grid-template-columns: 1fr; } }

/* =========================================================================
   SERVICE DETAIL — sticky sidebar layout
   ========================================================================= */
.service-hero { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 48px; align-items: start; }
.service-sidebar { position: sticky; top: calc(var(--header-h) + 24px); }
@media (max-width: 980px) {
  .service-hero { grid-template-columns: 1fr; }
  .service-sidebar { position: static; }
}
.sidebar-phone-row { display: flex; align-items: center; gap: 12px; margin-top: 18px; padding-top: 18px; border-top: 1px solid var(--color-border); }
.sidebar-phone-row .icon-tile { width: 38px; height: 38px; }

/* =========================================================================
   ADMIN
   ========================================================================= */
.admin-shell { display: grid; grid-template-columns: 240px 1fr; min-height: 100vh; }
.admin-sidebar { background: var(--color-slate-900); color: var(--color-slate-300); padding: 24px 18px; display: flex; flex-direction: column; }
.admin-sidebar img { height: 24px; width: auto; align-self: flex-start; margin-bottom: 28px; }
.admin-sidebar nav { display: flex; flex-direction: column; gap: 2px; }
.admin-sidebar a, .admin-sidebar .sidebar-soon {
  display: flex; align-items: center; justify-content: space-between; padding: 11px 12px;
  border-radius: var(--radius-sm); font-weight: 600; font-size: 0.92rem; color: var(--color-slate-300);
}
.admin-sidebar a:hover { background: var(--color-slate-800); color: #fff; }
.admin-sidebar a.is-active { background: var(--color-slate-800); color: #fff; }
.admin-sidebar .sidebar-soon { opacity: .55; cursor: default; }
.admin-sidebar .count { background: var(--color-red); color: #fff; font-size: 0.72rem; font-weight: 700; padding: 2px 8px; border-radius: 999px; }
.admin-sidebar__foot { margin-top: auto; padding-top: 18px; border-top: 1px solid var(--color-slate-800); font-size: 0.85rem; }
.admin-sidebar__foot strong { color: #fff; display: block; }
.admin-main { padding: 28px 32px; background: var(--color-bg-alt); min-height: 100vh; min-width: 0; }
.admin-topbar { display: flex; gap: 12px; align-items: center; justify-content: space-between; margin-bottom: 24px; flex-wrap: wrap; }
.admin-filters { display: flex; gap: 10px; align-items: center; flex: 1; flex-wrap: wrap; }
.admin-search {
  flex: 1; min-width: 220px; height: 44px; border-radius: var(--radius-md); border: 1.5px solid var(--color-border);
  padding: 0 14px; background: #fff; font-family: var(--font-body);
}
.admin-filters select,
.admin-filters input[type="date"] {
  height: 44px; border-radius: var(--radius-md); border: 1.5px solid var(--color-border);
  padding: 0 12px; background: #fff; font-family: var(--font-body); font-size: 0.88rem; color: var(--color-text);
}
.admin-stat-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-bottom: 28px; }
.admin-stat-card { background: #fff; border: 1px solid var(--color-border); border-radius: var(--radius-lg); padding: 18px 20px; }
.admin-stat-card.is-alert { border-color: var(--color-red); }
.admin-stat-card .label { font-size: 0.75rem; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; color: var(--color-muted); }
.admin-stat-card .value { font-family: var(--font-heading); font-size: 2rem; margin-top: 6px; }
.admin-layout { display: grid; grid-template-columns: 1fr 360px; gap: 24px; align-items: start; }
@media (max-width: 1100px) { .admin-layout { grid-template-columns: 1fr; } }
.admin-panel { background: #fff; border: 1px solid var(--color-border); border-radius: var(--radius-lg); overflow: hidden; }
.admin-panel__head { padding: 18px 22px; border-bottom: 1px solid var(--color-border); display: flex; justify-content: space-between; align-items: center; }
.leads-table { width: 100%; border-collapse: collapse; font-size: 0.9rem; }
.leads-table th { text-align: left; font-size: 0.72rem; text-transform: uppercase; letter-spacing: .04em; color: var(--color-muted); padding: 10px 22px; border-bottom: 1px solid var(--color-border); }
.leads-table td { padding: 14px 22px; border-bottom: 1px solid var(--color-border); vertical-align: top; }
.leads-table tr:hover td { background: var(--color-slate-50); }
.leads-table tr.is-urgent td:first-child { box-shadow: inset 3px 0 0 var(--color-red); }
.lead-name { font-weight: 700; color: var(--color-text); }
.lead-addr { color: var(--color-muted); font-size: 0.82rem; }
.status-pill { display: inline-flex; padding: 5px 12px; border-radius: var(--radius-pill); font-size: 0.75rem; font-weight: 700; background: var(--color-slate-100); color: var(--color-slate-700); }
.status-pill--new { background: var(--color-red-tint); color: var(--color-red-dark); }
.status-pill--urgent { background: var(--color-red); color: #fff; }
/* Reports (admin/reports.php) — plain CSS bars, no charting library. */
.report-bars { display: flex; align-items: flex-end; gap: 6px; height: 140px; }
.report-bar { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: flex-end; height: 100%; }
.report-bar__fill { width: 100%; background: var(--color-red); border-radius: 4px 4px 0 0; min-height: 2px; }
.report-bar__value { font-size: 0.7rem; color: var(--color-muted); margin-top: 4px; }
.report-row { display: flex; align-items: center; gap: 12px; padding: 8px 0; }
.report-row__label { width: 150px; flex-shrink: 0; font-size: 0.85rem; color: var(--color-slate-700); }
.report-row__track { flex: 1; height: 10px; background: var(--color-slate-100); border-radius: var(--radius-pill); overflow: hidden; }
.report-row__fill { height: 100%; background: var(--color-red); border-radius: var(--radius-pill); }
.report-row__value { width: 32px; text-align: right; font-weight: 700; font-size: 0.85rem; }

.admin-login {
  min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 24px;
  background-color: var(--color-slate-900);
  /* Faint repeating bug/ant motif (same line-icon paths as includes/icons.php's
     'bug' and 'ant' icons) -- a quiet brand touch behind the login card, subtle
     enough it reads as texture rather than decoration. stroke-opacity is baked
     into the SVG itself (not CSS opacity) since currentColor doesn't resolve
     for background-image data URIs. */
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160' viewBox='0 0 160 160'%3E%3Cg fill='none' stroke='%23ffffff' stroke-opacity='0.05' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cg transform='translate(14,18) scale(1.4) rotate(-14)'%3E%3Cpath d='M9 9V7a3 3 0 0 1 6 0v2'/%3E%3Crect x='6' y='9' width='12' height='10' rx='5'/%3E%3Cpath d='M6 12H3M21 12h-3M6 16H4M20 16h-2M12 9v10M9.5 6.5 8 5M14.5 6.5 16 5'/%3E%3C/g%3E%3Cg transform='translate(88,86) scale(1.2) rotate(20)'%3E%3Cellipse cx='8.2' cy='12' rx='2' ry='2.5'/%3E%3Cellipse cx='12' cy='12' rx='2.5' ry='3'/%3E%3Cellipse cx='16.2' cy='12' rx='2' ry='2.5'/%3E%3Cpath d='M5.5 8 3.2 6M5.5 12 2.5 12M5.5 16 3.2 18M18.5 8 20.8 6M18.5 12 21.5 12M18.5 16 20.8 18'/%3E%3Cpath d='M10.5 9.3 9 6.5M13.5 9.3 15 6.5'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
  background-repeat: repeat;
}
.admin-login-card { background: #fff; border-radius: var(--radius-lg); padding: 40px; width: 100%; max-width: 380px; box-shadow: var(--shadow-lg); }
.admin-login-card img { height: 30px; margin-bottom: 22px; }

/* Mobile topbar / off-canvas sidebar — hidden entirely on desktop, where the
   sidebar is always visible as the left rail (see .admin-shell above). */
.admin-mobile-topbar { display: none; }
.admin-sidebar-backdrop { display: none; }
.admin-sidebar-close { display: none; }

@media (max-width: 900px) {
  .admin-shell { grid-template-columns: 1fr; }

  .admin-mobile-topbar {
    display: flex; align-items: center; justify-content: space-between;
    height: 56px; padding: 0 16px; background: var(--color-slate-900);
    position: sticky; top: 0; z-index: 120;
  }
  .admin-mobile-topbar img { height: 20px; }
  .admin-nav-toggle {
    display: flex; align-items: center; justify-content: center;
    width: 40px; height: 40px; border-radius: var(--radius-sm); border: none;
    background: var(--color-slate-800); color: #fff;
  }

  .admin-sidebar {
    position: fixed; top: 0; left: 0; bottom: 0; width: 270px; max-width: 82vw;
    z-index: 200; transform: translateX(-100%); transition: transform .25s ease;
    overflow-y: auto;
  }
  .admin-sidebar.is-open { transform: translateX(0); }
  .admin-sidebar-close {
    display: flex; align-items: center; justify-content: center;
    width: 36px; height: 36px; border-radius: var(--radius-sm); border: none;
    background: var(--color-slate-800); color: #fff; align-self: flex-end; margin-bottom: 12px;
  }

  .admin-sidebar-backdrop.is-open {
    display: block; position: fixed; inset: 0; background: rgba(15, 23, 42, .5); z-index: 190;
  }

  .admin-main { padding: 18px 16px; }
  .admin-topbar { flex-direction: column; align-items: stretch; }
  .admin-filters { flex-direction: column; align-items: stretch; }
  .admin-filters select,
  .admin-filters input[type="date"] { width: 100%; }
  .admin-topbar > div.flex { flex-direction: column; }
  .admin-topbar > div.flex > a.btn { width: 100%; text-align: center; }
  .admin-stat-grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
}

@media (max-width: 480px) {
  .admin-stat-grid { grid-template-columns: 1fr; }
}

/* =========================================================================
   ALERT / TOAST
   ========================================================================= */
.alert { border-radius: var(--radius-md); padding: 14px 18px; font-size: 0.9rem; margin-bottom: 20px; }
.alert--error { background: var(--color-red-tint); color: var(--color-red-dark); border: 1px solid var(--color-red-hairline); }
.alert--success { background: #EAF6EE; color: #1E7B3B; border: 1px solid #BFE6C8; }

/* =========================================================================
   UTILITIES
   ========================================================================= */
.text-center { text-align: center; }
.mt-0 { margin-top: 0; }
.flex { display: flex; }
.flex-wrap { flex-wrap: wrap; }
.items-center { align-items: center; }
.gap-8 { gap: 8px; }
.gap-12 { gap: 12px; }
.gap-16 { gap: 16px; }
.no-js .js-only { display: none; }

/* Mobile sticky call/quote bar */
.mobile-cta-bar {
  display: none; position: fixed; left: 0; right: 0; bottom: 0; z-index: 90;
  background: #fff; border-top: 1px solid var(--color-border);
  padding: 10px 14px; gap: 10px; box-shadow: 0 -6px 16px rgba(15,23,42,.08);
}
@media (max-width: 720px) {
  .mobile-cta-bar { display: flex; }
  body { padding-bottom: 74px; }
}

/* Cookie consent banner (js/main.js shows/hides; hidden by default so it
   never flashes before JS decides whether a choice has already been made).
   Sits above the mobile sticky call/quote bar on narrow screens rather than
   under it, so neither one hides the other's buttons. */
.cookie-banner {
  display: none; position: fixed; left: 0; right: 0; bottom: 0; z-index: 95;
  background: var(--color-slate-900); color: #fff;
  padding: 16px 20px; box-shadow: 0 -6px 20px rgba(15,23,42,.18);
}
.cookie-banner__inner {
  max-width: 1120px; margin: 0 auto; display: flex; align-items: center;
  justify-content: space-between; gap: 20px; flex-wrap: wrap;
}
.cookie-banner p { font-size: 0.88rem; color: rgba(255,255,255,.85); max-width: 640px; margin: 0; }
.cookie-banner a { color: #fff; text-decoration: underline; }
.cookie-banner__actions { display: flex; gap: 10px; flex-shrink: 0; }
@media (max-width: 720px) {
  .cookie-banner { bottom: 74px; }
}
@media (max-width: 560px) {
  .cookie-banner__inner { flex-direction: column; align-items: stretch; }
  .cookie-banner__actions { justify-content: flex-end; }
}

/* =========================================================================
   ROUTE PLANNER  (admin/route/*.php — merged in 2026-08-18)
   Everything below is scoped under .route-page (set on <main> by
   admin/route/partials/header.php) so it can't leak onto or collide with
   any other page, including the rest of /admin/. Built from the same
   tokens as the rest of the site (color/font/radius/shadow vars up top)
   rather than a separate palette — Route Planner uses Proterm branding,
   not its own.
   ========================================================================= */

/* Plain <label>/<input> pairs outside a .field wrapper (every form in
   Route Planner is written this way) still get the same look as the
   rest of the site's form fields. */
.route-page label { display: block; font-weight: 700; font-size: 0.8rem; color: var(--color-slate-700); margin-bottom: 7px; }
.route-page input[type="text"],
.route-page input[type="email"],
.route-page input[type="search"],
.route-page input[type="date"],
.route-page input[type="file"]:not(.route-page .dropzone input[type="file"]),
.route-page select,
.route-page textarea {
  width: 100%; height: 48px; padding: 0 14px; margin-bottom: 16px;
  border: 2px solid var(--color-slate-200); border-radius: var(--radius-md);
  font-family: var(--font-body); font-size: 0.95rem; color: var(--color-text);
  background: #fff; transition: border-color .15s ease;
}
.route-page textarea { height: auto; min-height: 96px; padding: 12px 14px; resize: vertical; }
.route-page input:focus, .route-page select:focus, .route-page textarea:focus { border-color: var(--color-red); outline: none; }
.route-page input::placeholder, .route-page textarea::placeholder { color: var(--color-slate-400); }
.route-page .row { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 14px; }
@media (max-width: 640px) { .route-page .row { grid-template-columns: 1fr; } }

/* -- Page head + subnav -------------------------------------------------- */
.route-page .route-page-head { margin-bottom: 16px; }
.route-page .route-page-head h2 { font-size: 1.4rem; }

.route-subnav {
  display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 24px;
  padding-bottom: 14px; border-bottom: 1px solid var(--color-border);
}
.route-subnav-link {
  display: inline-flex; align-items: center; gap: 7px;
  padding: 8px 14px; border-radius: var(--radius-pill);
  font-size: 0.85rem; font-weight: 700; color: var(--color-slate-600);
  background: var(--color-slate-100); text-decoration: none;
  transition: background-color .15s ease, color .15s ease;
}
.route-subnav-link .icon { width: 16px; height: 16px; }
.route-subnav-link:hover { background: var(--color-slate-200); color: var(--color-slate-900); }
.route-subnav-link.is-active { background: var(--color-red); color: #fff; }
.route-subnav-badge {
  background: #fff; color: var(--color-red-dark); font-size: 0.7rem; font-weight: 800;
  padding: 1px 7px; border-radius: 999px;
}
.route-subnav-link.is-active .route-subnav-badge { background: rgba(255,255,255,.9); }

.route-inbox-banner { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.alert--info { background: var(--color-slate-100); color: var(--color-slate-700); border: 1px solid var(--color-slate-200); }

/* -- Dashboard ------------------------------------------------------------ */
.dashboard-header-row { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 20px; }
.dashboard-greeting { font-family: var(--font-heading); font-size: 1.3rem; font-weight: 700; color: var(--color-text); margin: 0; }
.dashboard-datetime { color: var(--color-muted); font-size: 0.88rem; margin: 0; }

.route-page .admin-stat-grid { grid-template-columns: repeat(4, 1fr); }
@media (max-width: 900px) { .route-page .admin-stat-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .route-page .admin-stat-grid { grid-template-columns: 1fr; } }
.route-page a.admin-stat-card {
  display: flex; align-items: center; gap: 14px; text-decoration: none; color: inherit;
  transition: transform .15s ease, box-shadow .15s ease, border-color .15s ease;
}
.route-page a.admin-stat-card:hover { transform: translateY(-2px); box-shadow: var(--shadow-md); border-color: var(--color-slate-300); }
.route-page a.admin-stat-card .icon { width: 22px; height: 22px; }

/* -- Buttons: btn-reject + icon-btn + spinner (btn/btn-primary/btn-
   secondary already exist site-wide) ------------------------------------- */
.route-page .btn-reject { background: #fff; color: var(--color-red-dark); border: 2px solid var(--color-red-hairline); }
.route-page .btn-reject:hover { background: var(--color-red-tint); border-color: var(--color-red); }
.route-page .btn-sm { height: 38px; padding: 0 16px; font-size: 0.85rem; }
.route-page .icon-btn {
  display: inline-flex; align-items: center; justify-content: center;
  width: 32px; height: 32px; border-radius: var(--radius-sm); border: 1px solid var(--color-border);
  background: #fff; color: var(--color-slate-600); cursor: pointer; flex: none;
  transition: background-color .15s ease, color .15s ease, border-color .15s ease;
}
.route-page .icon-btn:hover { background: var(--color-red-tint); color: var(--color-red-dark); border-color: var(--color-red-hairline); }
.route-page .icon-btn svg { width: 16px; height: 16px; }
.route-page .spinner {
  display: inline-block; width: 14px; height: 14px; margin-right: 6px;
  border: 2px solid rgba(255,255,255,.4); border-top-color: #fff; border-radius: 50%;
  animation: route-spin .7s linear infinite; vertical-align: -2px;
}
@keyframes route-spin { to { transform: rotate(360deg); } }

/* -- Empty states ---------------------------------------------------------- */
.route-page .empty-state { text-align: center; padding: 40px 20px; color: var(--color-muted); }
.route-page .empty-state-icon {
  width: 56px; height: 56px; margin: 0 auto 14px; border-radius: 999px;
  background: var(--color-slate-100); color: var(--color-slate-400);
  display: flex; align-items: center; justify-content: center;
}
.route-page .empty-state-icon .icon { width: 26px; height: 26px; }
.route-page .empty-state p { margin: 0 0 16px; }

/* -- Badges (status dots — distinct from the leads admin's .status-pill,
   same color family) -------------------------------------------------- */
.route-page .badge {
  display: inline-flex; align-items: center; gap: 6px; padding: 4px 11px;
  border-radius: var(--radius-pill); font-size: 0.72rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: .03em;
  background: var(--color-slate-100); color: var(--color-slate-700);
}
.route-page .badge-dot { width: 6px; height: 6px; border-radius: 50%; background: currentColor; flex: none; }
.route-page .badge-confirmed { background: var(--color-slate-100); color: var(--color-slate-700); }
.route-page .badge-review { background: var(--color-red-tint); color: var(--color-red-dark); }
.route-page .badge-routed { background: #EAF6EE; color: #1E7B3B; }
.route-page .badge-failed { background: var(--color-red); color: #fff; }

/* -- Day tabs (review.php / route.php / complete.php's sent-history filter) */
.route-page .day-tabs { display: flex; gap: 6px; margin-bottom: 18px; flex-wrap: wrap; }
.route-page .day-tab {
  display: inline-flex; align-items: center; gap: 6px; padding: 8px 16px;
  border-radius: var(--radius-pill); font-size: 0.85rem; font-weight: 700;
  color: var(--color-slate-600); background: #fff; border: 2px solid var(--color-slate-200);
  text-decoration: none; transition: border-color .15s ease, background-color .15s ease, color .15s ease;
}
.route-page .day-tab:hover { border-color: var(--color-slate-400); }
.route-page .day-tab.active { background: var(--color-slate-900); border-color: var(--color-slate-900); color: #fff; }
.route-page .day-tab-count {
  background: var(--color-red); color: #fff; font-size: 0.68rem; font-weight: 800;
  padding: 1px 7px; border-radius: 999px;
}
.route-page .day-tab.active .day-tab-count { background: rgba(255,255,255,.25); }

/* -- Job cards (review / route / complete) --------------------------------- */
.route-page .job-card { margin-bottom: 16px; }
.route-page .job-file { font-weight: 700; color: var(--color-text); margin-bottom: 10px; }
.route-page .job-file-list { border: 1px solid var(--color-border); border-radius: var(--radius-md); overflow: hidden; margin-bottom: 12px; }
.route-page .job-file-list-item {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: 9px 14px; font-size: 0.88rem; color: var(--color-slate-700);
  border-bottom: 1px solid var(--color-border); background: var(--color-slate-50);
}
.route-page .job-file-list-item:last-child { border-bottom: none; }
.route-page .stop-card { position: relative; }
.route-page .stop-num {
  display: inline-flex; align-items: center; justify-content: center;
  width: 26px; height: 26px; border-radius: 50%; background: var(--color-slate-900); color: #fff;
  font-size: 0.8rem; font-weight: 800; margin-right: 10px; flex: none;
}
.route-page .stop-in { animation: route-stop-in .35s ease both; animation-delay: calc(var(--i, 0) * 60ms); }
@keyframes route-stop-in { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

/* -- Dropzone (upload.php / complete.php) ---------------------------------- */
.route-page .dropzone {
  position: relative; border: 2px dashed var(--color-slate-300); border-radius: var(--radius-lg);
  padding: 36px 20px; text-align: center; cursor: pointer; background: var(--color-slate-50);
  transition: border-color .15s ease, background-color .15s ease;
}
.route-page .dropzone:hover, .route-page .dropzone.is-dragover { border-color: var(--color-red); background: var(--color-red-tint); }
.route-page .dropzone input[type="file"] { position: absolute; inset: 0; opacity: 0; cursor: pointer; width: 100%; height: 100%; }
.route-page .dropzone-icon {
  width: 52px; height: 52px; margin: 0 auto 12px; border-radius: 999px;
  background: #fff; color: var(--color-slate-500); display: flex; align-items: center; justify-content: center;
  box-shadow: var(--shadow-sm);
}
.route-page .dropzone-icon .icon { width: 24px; height: 24px; }
.route-page .dropzone-title { font-weight: 700; color: var(--color-text); margin: 0 0 4px; }
.route-page .dropzone-hint { font-size: 0.85rem; color: var(--color-muted); margin: 0 0 12px; max-width: 46ch; margin-left: auto; margin-right: auto; }
.route-page .dropzone-divider { font-size: 0.72rem; font-weight: 700; color: var(--color-slate-400); text-transform: uppercase; letter-spacing: .06em; margin: 10px 0; }
.route-page .dropzone-browse {
  display: inline-block; padding: 8px 18px; border-radius: var(--radius-pill);
  background: var(--color-slate-900); color: #fff; font-size: 0.85rem; font-weight: 700; pointer-events: none;
}
.route-page .dropzone-meta { text-align: center; margin: 10px 0 0; }
.route-page .dropzone-meta span { font-size: 0.78rem; color: var(--color-muted); }

/* -- Contacts --------------------------------------------------------------- */
.route-page .contact-list-header,
.route-page .contact-row,
.route-page .contact-row-grouped {
  display: grid; grid-template-columns: 1fr 1fr 1.1fr auto; gap: 12px; align-items: center;
}
.route-page .contact-list-header {
  padding: 0 14px 10px; font-size: 0.72rem; font-weight: 700; text-transform: uppercase;
  letter-spacing: .04em; color: var(--color-muted); border-bottom: 1px solid var(--color-border);
}
.route-page .contact-list { border: 1px solid var(--color-border); border-radius: var(--radius-md); overflow: hidden; }
.route-page .contact-row { padding: 10px 14px; border-bottom: 1px solid var(--color-border); }
.route-page .contact-row:last-child { border-bottom: none; }
.route-page .contact-row input { margin-bottom: 0; height: 42px; }
.route-page .contact-row-actions { display: flex; gap: 6px; }
.route-page .contact-group { border-bottom: 1px solid var(--color-border); background: var(--color-slate-50); }
.route-page .contact-group:last-child { border-bottom: none; }
.route-page .contact-group-label { padding: 10px 14px 0; }
.route-page .contact-row-grouped { padding: 8px 14px; }
@media (max-width: 780px) {
  .route-page .contact-list-header { display: none; }
  .route-page .contact-row, .route-page .contact-row-grouped { grid-template-columns: 1fr; gap: 8px; }
}

/* -- Group-contacts modal ----------------------------------------------------- */
.route-page .modal-overlay {
  display: none; position: fixed; inset: 0; z-index: 200; background: rgba(15,23,42,.55);
  align-items: center; justify-content: center; padding: 20px;
}
.route-page .modal-overlay.open { display: flex; }
.route-page .modal-panel {
  background: #fff; border-radius: var(--radius-lg); box-shadow: var(--shadow-lg);
  padding: 26px; width: 100%; max-width: 460px; max-height: 82vh; overflow-y: auto;
}
.route-page .modal-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 6px; }
.route-page .modal-checklist { margin-top: 12px; max-height: 320px; overflow-y: auto; border: 1px solid var(--color-border); border-radius: var(--radius-md); }
.route-page .modal-checklist-item {
  display: flex; align-items: center; gap: 10px; padding: 10px 12px;
  border-bottom: 1px solid var(--color-border); cursor: pointer; font-weight: 400;
}
.route-page .modal-checklist-item:last-child { border-bottom: none; }
.route-page .modal-checklist-item input[type="checkbox"] { width: 18px; height: 18px; flex: none; accent-color: var(--color-red); margin: 0; }
.route-page .modal-checklist-text { display: flex; flex-direction: column; gap: 2px; flex: 1; }
.route-page .modal-checklist-name { font-size: 0.9rem; font-weight: 700; color: var(--color-text); }
.route-page .modal-checklist-email { font-size: 0.8rem; }

/* -- Notes (two-pane) --------------------------------------------------------- */
.route-page .notes-layout { display: grid; grid-template-columns: 280px 1fr; gap: 20px; align-items: start; }
.route-page .notes-list-pane { background: #fff; border: 1px solid var(--color-border); border-radius: var(--radius-lg); overflow: hidden; }
.route-page .notes-list-header { display: flex; align-items: center; justify-content: space-between; padding: 16px 16px 12px; }
.route-page .notes-list { max-height: 560px; overflow-y: auto; }
.route-page .note-item { display: block; padding: 12px 16px; border-top: 1px solid var(--color-border); text-decoration: none; color: inherit; }
.route-page .note-item.active { background: var(--color-red-tint); }
.route-page .note-item-title { font-weight: 700; color: var(--color-text); font-size: 0.92rem; }
.route-page .note-item-preview { font-size: 0.82rem; color: var(--color-muted); margin-top: 2px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.route-page .note-item-date { font-size: 0.74rem; color: var(--color-slate-400); margin-top: 4px; }
.route-page .notes-editor-pane { min-height: 300px; }
.route-page .notes-back-link { display: none; margin-bottom: 12px; font-weight: 700; color: var(--color-slate-600); text-decoration: none; }
.route-page .notes-editor textarea { min-height: 480px; margin-bottom: 14px; }
@media (max-width: 780px) {
  .route-page .notes-layout { grid-template-columns: 1fr; }
  .route-page .notes-layout.note-selected .notes-list-pane { display: none; }
  .route-page .notes-layout.note-selected .notes-back-link { display: inline-block; }
}

/* -- Date picker (upload.php's "This paperwork is for") ---------------------- */
.route-page .date-picker { position: relative; max-width: 320px; }
.route-page .date-picker-quick { display: flex; gap: 8px; margin-bottom: 10px; }
.route-page .date-chip {
  padding: 7px 14px; border-radius: var(--radius-pill); border: 2px solid var(--color-slate-200);
  background: #fff; font-size: 0.82rem; font-weight: 700; color: var(--color-slate-600); cursor: pointer;
}
.route-page .date-chip:hover, .route-page .date-chip.is-active { border-color: var(--color-red); color: var(--color-red-dark); background: var(--color-red-tint); }
.route-page .date-picker-trigger {
  display: flex; align-items: center; gap: 8px; width: 100%; height: 48px; padding: 0 14px;
  border: 2px solid var(--color-slate-200); border-radius: var(--radius-md); background: #fff;
  font-size: 0.95rem; font-weight: 600; color: var(--color-text); cursor: pointer; margin-bottom: 0;
}
.route-page .date-picker-trigger svg { width: 18px; height: 18px; color: var(--color-slate-500); flex: none; }
.route-page .date-picker-panel {
  position: absolute; top: calc(100% + 6px); left: 0; z-index: 20; width: 280px;
  background: #fff; border: 1px solid var(--color-border); border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg); padding: 14px;
}
.route-page .date-picker-panel-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px; }
.route-page .date-picker-month-label { font-weight: 700; font-size: 0.9rem; color: var(--color-text); }
.route-page .date-picker-weekdays, .route-page .date-picker-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 2px; text-align: center; }
.route-page .date-picker-weekdays span { font-size: 0.7rem; color: var(--color-muted); font-weight: 700; padding: 4px 0; }
.route-page .date-picker-grid button {
  border: none; background: transparent; border-radius: var(--radius-sm); height: 32px; font-size: 0.82rem;
  color: var(--color-text); cursor: pointer;
}
.route-page .date-picker-grid button:hover { background: var(--color-slate-100); }
.route-page .date-picker-grid button.is-selected { background: var(--color-red); color: #fff; font-weight: 700; }
.route-page .date-picker-grid button.is-outside-month { color: var(--color-slate-300); }
.route-page .date-picker-grid button:disabled { color: var(--color-slate-200); cursor: default; }

/* -- Tables (upload.php "Today's uploads", complete.php "Recently sent") ----- */
.route-page table.list { width: 100%; border-collapse: collapse; font-size: 0.88rem; }
.route-page table.list th {
  text-align: left; font-size: 0.72rem; text-transform: uppercase; letter-spacing: .04em;
  color: var(--color-muted); padding: 10px 4px; border-bottom: 1px solid var(--color-border);
}
.route-page table.list td { padding: 12px 4px; border-bottom: 1px solid var(--color-border); vertical-align: middle; }
.route-page table.list tr:last-child td { border-bottom: none; }
