/* ============================================================
   napervilleflatwork.com — styles.css
   Foundation: reset, design tokens, typography, layout primitives,
   base buttons. Component styles (header, footer, hero, quiz, etc.)
   are added in subsequent build steps.

   Rule that must never be broken:
     BLACK (--color-action) = primary action buttons
     BLUE  (--color-primary) = brand color for headers, links, accents
   Never use blue for action buttons.
   ============================================================ */

/* ------------------------------------------------------------
   Font loading
   The following <link> tags must appear in <head> of every page
   (will be wired into tools/partials/head.html in Step 3a):

   <link rel="preconnect" href="https://fonts.googleapis.com">
   <link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
   <link rel="preload" as="style"
     href="https://fonts.googleapis.com/css2?family=Barlow+Condensed:wght@700;800&family=Inter:wght@400;600&display=swap">
   <link rel="stylesheet"
     href="https://fonts.googleapis.com/css2?family=Barlow+Condensed:wght@700;800&family=Inter:wght@400;600&display=swap">

   display=swap ensures text renders immediately in fallback fonts
   and swaps to the web fonts when loaded (no FOIT, only FOUT).
   ------------------------------------------------------------ */


/* ============================================================
   0. Reduced-motion respect
   Honors OS-level "reduce motion" preference. Animations and
   transitions collapse to near-zero; smooth-scroll falls back
   to instant. JS also reads matchMedia and skips behavior:'smooth'.
   ============================================================ */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}


/* ============================================================
   1. Reset + base
   ============================================================ */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; padding: 0; }

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  /* Header offset: mobile = 48 (phone bar) + 64 (header) = 112px; desktop = 80px (header only). */
  scroll-padding-top: var(--header-offset, 112px);
}

body {
  font-family: var(--font-body);
  font-weight: 400;
  font-size: 1.0625rem;
  line-height: 1.6;
  color: var(--color-text);
  background: var(--color-surface);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  /* Reserve space for sticky phone bar (mobile) + sticky header (top)
     and sticky bottom CTA bar (mobile). All collapse to 0 on tablet+. */
  padding-top: var(--header-offset);
  padding-bottom: var(--bottom-bar-h);
}

/* Lock scroll while the mobile menu is open */
body.is-mobile-nav-open {
  overflow: hidden;
}

img, svg, video, picture {
  display: block;
  max-width: 100%;
  height: auto;
}

button {
  font: inherit;
  cursor: pointer;
  border: none;
  background: none;
  color: inherit;
}

a {
  color: inherit;
  text-decoration: none;
}

input, textarea, select {
  font: inherit;
  color: inherit;
}

:focus-visible {
  outline: 2px solid var(--color-primary);
  outline-offset: 2px;
}


/* ============================================================
   2. Design tokens
   ============================================================ */
:root {
  /* Primary — Cole-approved cobalt shift (2026-05-12) for differentiation
     from npvconcrete.com's #1e3a5f navy. Spec originally specified #1B4D8E. */
  --color-primary: #1453B0;
  --color-primary-dark: #0A3470;     /* footer, hero overlay */
  --color-primary-light: #E6EEFA;    /* tints, hover backgrounds */

  /* Action (CTA) — BLACK. This is the conversion color.
     Buttons with .btn--action use this. Never substitute blue. */
  --color-action: #1A1A1A;
  --color-action-hover: #000000;

  /* Neutrals */
  --color-text: #1A1A1A;
  --color-text-muted: #3D434A;
  --color-border: #8A8F95;
  --color-surface-light: #F4F5F7;
  --color-surface: #FFFFFF;

  /* Functional */
  --color-success: #2D7D5F;          /* Use on LIGHT backgrounds */
  --color-success-light: #4FB28D;    /* Use on DARK backgrounds (footer badge, dark sections) */
  --color-error: #B23A3A;

  /* Spacing scale (spec section 2 — use these only, no arbitrary values) */
  --space-2:  0.5rem;
  --space-3:  0.75rem;
  --space-4:  1rem;
  --space-6:  1.5rem;
  --space-8:  2rem;
  --space-12: 3rem;
  --space-16: 4rem;
  --space-24: 6rem;

  /* Layout */
  --max-width: 1200px;
  --side-padding: 1.25rem;       /* mobile */

  /* Sticky-element heights (component styles in sections 7–12) */
  --phone-bar-h: 48px;            /* mobile sticky top phone bar */
  --header-h: 64px;               /* mobile header */
  --bottom-bar-h: 64px;           /* mobile sticky bottom CTA bar */
  --header-offset: calc(var(--phone-bar-h) + var(--header-h));  /* mobile = 112px */

  /* Typography families */
  --font-headline: 'Barlow Condensed', 'Oswald', Impact, sans-serif;
  --font-body: 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;
}

@media (min-width: 768px) {
  :root {
    --phone-bar-h: 0px;           /* phone bar hidden on tablet+ */
    --header-h: 80px;             /* desktop header is taller */
    --bottom-bar-h: 0px;          /* bottom CTA bar hidden on tablet+ */
    --header-offset: var(--header-h);
  }
}

@media (min-width: 1024px) {
  :root {
    --side-padding: 2rem;         /* desktop */
  }
}


/* ============================================================
   3. Typography
   ============================================================ */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-headline);
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.01em;
  color: var(--color-text);
}

h1 {
  font-size: clamp(2.25rem, 6vw, 4rem);
  text-transform: uppercase;
}

h2 {
  font-size: clamp(1.75rem, 4vw, 2.75rem);
  text-transform: uppercase;
}

h3 {
  font-size: clamp(1.25rem, 2.5vw, 1.5rem);
  font-weight: 700;
}

h4 { font-size: 1.125rem; font-weight: 700; }
h5 { font-size: 1rem;     font-weight: 700; }
h6 { font-size: 0.9375rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.04em; }

p {
  margin: 0 0 var(--space-4);
}

p:last-child {
  margin-bottom: 0;
}

small, .text-small {
  font-size: 0.875rem;
  line-height: 1.5;
}

strong, b {
  font-weight: 600;
}

/* Section H2 thick black underline accent (spec section 2 — visual texture).
   Replaces generic horizontal dividers under major section headings. */
.section-heading {
  position: relative;
  padding-bottom: var(--space-4);
  margin-bottom: var(--space-8);
}

.section-heading::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 60px;
  height: 4px;
  background: var(--color-action);
}

.section-heading--center {
  text-align: center;
}

.section-heading--center::after {
  left: 50%;
  transform: translateX(-50%);
}

/* Brand-colored eyebrow used above hero H1 and section H2s
   (e.g. "NAPERVILLE, IL" above hero headline). */
.eyebrow {
  display: inline-block;
  font-family: var(--font-body);
  font-size: 0.875rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--color-primary);
  margin-bottom: var(--space-3);
}


/* ============================================================
   4. Layout primitives
   ============================================================ */
.container {
  width: 100%;
  max-width: var(--max-width);
  margin-left: auto;
  margin-right: auto;
  padding-left: var(--side-padding);
  padding-right: var(--side-padding);
}

.section {
  padding-top: var(--space-16);
  padding-bottom: var(--space-16);
}

@media (min-width: 1024px) {
  .section {
    padding-top: var(--space-24);
    padding-bottom: var(--space-24);
  }
}

.section--surface {
  background: var(--color-surface-light);
}

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

.section--dark h1,
.section--dark h2,
.section--dark h3,
.section--dark h4 {
  color: var(--color-surface);
}

.section--dark .eyebrow {
  color: var(--color-primary-light);
}

.section--dark .section-heading::after {
  background: var(--color-surface);
}

/* Outline button on a dark section: switch to white border/text */
.section--dark .btn--outline {
  background: transparent;
  color: var(--color-surface);
  border-color: var(--color-surface);
}

.section--dark .btn--outline:hover,
.section--dark .btn--outline:focus-visible {
  background: var(--color-surface);
  color: var(--color-text);
}


/* ============================================================
   5. Base buttons
   BLACK = primary action (conversion). BLUE = brand color (never CTA).
   Sharp corners (2px radius — industrial feel). No drop shadows.
   ============================================================ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  padding: 0.875rem 1.5rem;
  font-family: var(--font-body);
  font-size: 1rem;
  font-weight: 600;
  line-height: 1;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  border: 2px solid transparent;
  border-radius: 2px;
  cursor: pointer;
  transition: background-color 150ms ease,
              border-color 150ms ease,
              color 150ms ease;
  text-decoration: none;
  white-space: nowrap;
  min-height: 48px;            /* mobile tap target */
}

.btn:disabled,
.btn[aria-disabled="true"] {
  opacity: 0.5;
  cursor: not-allowed;
}

/* Primary action — BLACK. The conversion button. */
.btn--action {
  background: var(--color-action);
  color: var(--color-surface);
  border-color: var(--color-action);
}

.btn--action:hover,
.btn--action:focus-visible {
  background: var(--color-action-hover);
  border-color: var(--color-action-hover);
}

/* Outlined — black border, white fill. For secondary CTAs (phone-link
   next to a primary action). */
.btn--outline {
  background: var(--color-surface);
  color: var(--color-action);
  border-color: var(--color-action);
}

.btn--outline:hover,
.btn--outline:focus-visible {
  background: var(--color-action);
  color: var(--color-surface);
}

/* Brand — for non-action elements only (e.g. an accent link styled as
   a chip). Never use as the primary CTA. */
.btn--brand {
  background: var(--color-primary);
  color: var(--color-surface);
  border-color: var(--color-primary);
}

.btn--brand:hover,
.btn--brand:focus-visible {
  background: var(--color-primary-dark);
  border-color: var(--color-primary-dark);
}

/* Ghost — quiz "Back" link style. Minimal, low-emphasis. */
.btn--ghost {
  background: transparent;
  color: var(--color-text-muted);
  border-color: transparent;
  font-weight: 500;
  text-transform: none;
  letter-spacing: 0;
  min-height: auto;
  padding: var(--space-2) var(--space-3);
}

.btn--ghost:hover,
.btn--ghost:focus-visible {
  color: var(--color-text);
}

/* Size modifiers */
.btn--lg {
  padding: 1.125rem 2rem;
  font-size: 1.0625rem;
}

.btn--block {
  display: flex;
  width: 100%;
}


/* ============================================================
   6. Utilities
   ============================================================ */
.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 — keyboard-accessible jump to main content */
.skip-to-content {
  position: absolute;
  top: -9999px;
  left: 0;
  z-index: 100;
  padding: var(--space-3) var(--space-4);
  background: var(--color-action);
  color: var(--color-surface);
  font-weight: 600;
  text-decoration: none;
}

.skip-to-content:focus {
  top: 0;
}

.text-muted    { color: var(--color-text-muted); }
.text-action   { color: var(--color-action); }
.text-primary  { color: var(--color-primary); }
.text-uppercase { text-transform: uppercase; letter-spacing: 0.04em; }

/* Vertical rhythm helper — adds top margin to all children after the first */
.flow > * + * {
  margin-top: var(--space-4);
}


/* ============================================================
   7. Mobile sticky top phone bar
   ============================================================ */
.phone-bar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 200;                  /* above the header */
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  height: var(--phone-bar-h);
  padding: 0 var(--space-4);
  background: var(--color-action);
  color: var(--color-surface);
  text-decoration: none;
  font-family: var(--font-body);
  font-size: 0.9375rem;
  font-weight: 500;
  letter-spacing: 0.01em;
}

.phone-bar:active {
  background: var(--color-action-hover);
}

.phone-bar__icon {
  flex-shrink: 0;
}

.phone-bar__text strong {
  font-weight: 700;
}

/* Hide phone bar on tablet/desktop */
@media (min-width: 768px) {
  .phone-bar {
    display: none;
  }
}


/* ============================================================
   8. Site header
   ============================================================ */
.site-header {
  position: fixed;
  top: var(--phone-bar-h);       /* sits below phone bar on mobile, top:0 on desktop */
  left: 0;
  right: 0;
  z-index: 100;
  height: var(--header-h);
  background: var(--color-primary-dark);
  color: var(--color-surface);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.site-header__inner {
  height: 100%;
  display: flex;
  align-items: center;
  gap: var(--space-4);
}

/* Brand: stacked logo + tagline on the left */
.site-header__brand {
  display: flex;
  flex-direction: column;
  gap: 2px;
  text-decoration: none;
  color: var(--color-surface);
  margin-right: auto;            /* pushes nav + actions right */
  line-height: 1;
}

.site-header__logo {
  font-family: var(--font-headline);
  font-weight: 800;
  font-size: 1.0625rem;
  letter-spacing: -0.005em;
  text-transform: uppercase;
}

.site-header__tagline {
  display: block;                /* visible on mobile + desktop */
  font-family: var(--font-body);
  font-size: 0.625rem;           /* slightly smaller on mobile to fit the 64px header */
  font-weight: 600;
  letter-spacing: 0.06em;
  color: rgba(255, 255, 255, 0.8);
  text-transform: uppercase;
  white-space: nowrap;           /* tagline is short — keep on one line */
}

@media (min-width: 768px) {
  .site-header__logo {
    font-size: 1.25rem;
  }
  .site-header__tagline {
    font-size: 0.75rem;
    font-weight: 500;
    letter-spacing: 0.04em;
  }
}

/* Desktop nav: hidden until ≥1024px */
.site-header__nav {
  display: none;
}

.site-header__nav-list {
  display: flex;
  align-items: center;
  gap: var(--space-6);
  list-style: none;
}

.site-header__nav-list a {
  font-family: var(--font-body);
  font-size: 0.875rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--color-surface);
  padding: var(--space-3) 0;
  border-bottom: 2px solid transparent;
  transition: border-color 150ms ease, color 150ms ease;
}

.site-header__nav-list a:hover,
.site-header__nav-list a:focus-visible {
  color: var(--color-primary-light);
  border-bottom-color: var(--color-primary-light);
}

@media (min-width: 1024px) {
  .site-header__nav {
    display: block;
  }
}

/* Right-side actions: phone + Free Quote button (desktop/tablet only) */
.site-header__actions {
  display: none;
  align-items: center;
  gap: var(--space-4);
}

.site-header__phone {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  color: var(--color-surface);
  font-family: var(--font-body);
  font-size: 0.9375rem;
  font-weight: 600;
  text-decoration: none;
  white-space: nowrap;
}

.site-header__phone:hover,
.site-header__phone:focus-visible {
  color: var(--color-primary-light);
}

.site-header__phone-icon {
  flex-shrink: 0;
}

.site-header__cta {
  /* slightly tighter than default .btn for header use */
  padding: 0.75rem 1.25rem;
  font-size: 0.875rem;
  min-height: 44px;
}

@media (min-width: 768px) {
  .site-header__actions {
    display: inline-flex;
  }
  /* On tablet (768–1023px), hide the inline phone — the Free Quote stays */
  .site-header__phone {
    display: none;
  }
}

@media (min-width: 1024px) {
  .site-header__phone {
    display: inline-flex;
  }
}


/* ============================================================
   9. Mobile menu toggle (hamburger)
   ============================================================ */
.site-header__menu-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  margin-right: calc(var(--space-3) * -1);
  background: transparent;
  border: 0;
  border-radius: 2px;
  cursor: pointer;
  color: var(--color-surface);
}

.site-header__menu-toggle:focus-visible {
  outline: 2px solid var(--color-primary-light);
  outline-offset: 2px;
}

.site-header__menu-icon,
.site-header__menu-icon::before,
.site-header__menu-icon::after {
  display: block;
  width: 22px;
  height: 2px;
  background: currentColor;
  transition: transform 200ms ease,
              opacity 150ms ease,
              top 200ms ease;
}

.site-header__menu-icon {
  position: relative;
}

.site-header__menu-icon::before,
.site-header__menu-icon::after {
  content: "";
  position: absolute;
  left: 0;
}

.site-header__menu-icon::before { top: -7px; }
.site-header__menu-icon::after  { top:  7px; }

/* Open state: rotate to X */
.site-header__menu-toggle[aria-expanded="true"] .site-header__menu-icon {
  background: transparent;
}

.site-header__menu-toggle[aria-expanded="true"] .site-header__menu-icon::before {
  top: 0;
  transform: rotate(45deg);
}

.site-header__menu-toggle[aria-expanded="true"] .site-header__menu-icon::after {
  top: 0;
  transform: rotate(-45deg);
}

@media (min-width: 1024px) {
  .site-header__menu-toggle {
    display: none;
  }
}


/* ============================================================
   10. Mobile navigation overlay
   ============================================================ */
.mobile-nav {
  position: fixed;
  top: var(--header-offset);     /* sits below phone bar + header */
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 90;                   /* below header so X stays clickable */
  background: var(--color-primary-dark);
  color: var(--color-surface);
  padding: var(--space-8) var(--side-padding);
  overflow-y: auto;
  /* Hidden by default — opacity + transform so it can transition */
  opacity: 0;
  transform: translateY(-8px);
  pointer-events: none;
  visibility: hidden;
  transition: opacity 200ms ease,
              transform 200ms ease,
              visibility 0s linear 200ms;
}

.mobile-nav[aria-hidden="false"] {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
  visibility: visible;
  transition: opacity 200ms ease,
              transform 200ms ease,
              visibility 0s linear 0s;
}

.mobile-nav__list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
  margin-bottom: var(--space-8);
}

.mobile-nav__list a {
  display: block;
  font-family: var(--font-headline);
  font-size: 1.5rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: -0.005em;
  color: var(--color-surface);
  padding: var(--space-2) 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  text-decoration: none;
}

.mobile-nav__list a:hover,
.mobile-nav__list a:focus-visible {
  color: var(--color-primary-light);
}

.mobile-nav__actions {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

@media (min-width: 1024px) {
  .mobile-nav {
    display: none;
  }
}


/* ============================================================
   11. Site footer
   ============================================================ */
.site-footer {
  background: var(--color-primary-dark);
  color: var(--color-surface);
  padding-top: var(--space-16);
  padding-bottom: var(--space-8);
}

.site-footer__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-12);
}

@media (min-width: 768px) {
  .site-footer__grid {
    grid-template-columns: 2fr 1fr;
    gap: var(--space-16);
  }
}

.site-footer__col {
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
}

.site-footer__wordmark {
  font-family: var(--font-headline);
  font-size: 1.5rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: -0.005em;
  line-height: 1.1;
  margin: 0;
}

.site-footer__tagline {
  color: rgba(255, 255, 255, 0.72);
  font-size: 0.9375rem;
  margin: 0;
  max-width: 38ch;
}

.site-footer__phone {
  font-family: var(--font-headline);
  font-size: 1.875rem;
  font-weight: 800;
  letter-spacing: -0.005em;
  color: var(--color-surface);
  text-decoration: none;
  line-height: 1;
}

.site-footer__phone:hover,
.site-footer__phone:focus-visible {
  color: var(--color-primary-light);
}

.site-footer__hours {
  display: grid;
  grid-template-columns: max-content 1fr;
  column-gap: var(--space-3);
  row-gap: 2px;
  margin: 0;
  font-size: 0.9375rem;
}

.site-footer__hours dt {
  color: rgba(255, 255, 255, 0.72);
  font-weight: 500;
}

.site-footer__hours dd {
  margin: 0;
  font-weight: 500;
}

.site-footer__service-areas {
  color: rgba(255, 255, 255, 0.72);
  font-size: 0.9375rem;
  line-height: 1.55;
  margin: 0;
  max-width: 56ch;
}

.site-footer__col--links {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-8);
}

@media (min-width: 768px) {
  .site-footer__col--links {
    display: flex;
    flex-direction: column;
    gap: var(--space-8);
  }
}

.site-footer__heading {
  font-family: var(--font-headline);
  font-size: 0.875rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: rgba(255, 255, 255, 0.6);
  margin: 0 0 var(--space-3);
}

.site-footer__links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
  padding: 0;
  margin: 0;
}

.site-footer__links a {
  color: var(--color-surface);
  text-decoration: none;
  font-size: 0.9375rem;
  font-weight: 500;
}

.site-footer__links a:hover,
.site-footer__links a:focus-visible {
  color: var(--color-primary-light);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.site-footer__bottom {
  margin-top: var(--space-12);
  padding-top: var(--space-6);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  align-items: flex-start;
  font-size: 0.8125rem;
}

@media (min-width: 768px) {
  .site-footer__bottom {
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
  }
}

.site-footer__copyright {
  color: rgba(255, 255, 255, 0.6);
  margin: 0;
}

.site-footer__badge {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  margin: 0;
  color: var(--color-success-light);
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  font-size: 0.75rem;
}


/* ============================================================
   12. Mobile sticky bottom CTA bar
   ============================================================ */
.mobile-bottom-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 90;
  display: flex;
  height: var(--bottom-bar-h, 64px);
}

.mobile-bottom-bar__half {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  color: var(--color-surface);
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 0.9375rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  text-decoration: none;
}

.mobile-bottom-bar__call {
  background: var(--color-action);
}

.mobile-bottom-bar__call:active {
  background: var(--color-action-hover);
}

.mobile-bottom-bar__quote {
  background: var(--color-primary);
}

.mobile-bottom-bar__quote:active {
  background: var(--color-primary-dark);
}

/* Hidden on tablet+ */
@media (min-width: 768px) {
  .mobile-bottom-bar {
    display: none;
  }
}


/* ============================================================
   13. Quiz (multi-step lead form) — THE conversion mechanism
   ============================================================ */
.quiz-section__header {
  margin-bottom: var(--space-8);
}

.quiz-section__lede {
  max-width: 60ch;
  color: var(--color-text-muted);
  margin-top: calc(var(--space-2) * -1);
}

.quiz {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  padding: var(--space-8) var(--space-6);
  max-width: 720px;
  margin-left: auto;
  margin-right: auto;
}

@media (min-width: 768px) {
  .quiz {
    padding: var(--space-12);
  }
}

/* Progress bar — 4 equal segments, fills BLACK as user advances */
.quiz__progress {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 4px;
  margin: 0 0 var(--space-8);
  padding: 0;
}

.quiz__progress li {
  height: 4px;
  background: var(--color-border);
  opacity: 0.4;
  transition: background 200ms ease, opacity 200ms ease;
}

.quiz__progress li[data-done],
.quiz__progress li[data-current] {
  background: var(--color-action);
  opacity: 1;
}

/* Step panels: only the active one is visible */
.quiz__step {
  display: none;
  border: 0;
  padding: 0;
  margin: 0;
  min-width: 0;
}

.quiz__form[data-step="1"] .quiz__step[data-step="1"],
.quiz__form[data-step="2"] .quiz__step[data-step="2"],
.quiz__form[data-step="3"] .quiz__step[data-step="3"],
.quiz__form[data-step="4"] .quiz__step[data-step="4"] {
  display: block;
}

.quiz__legend {
  display: block;
  margin-bottom: var(--space-6);
  padding: 0;
  width: 100%;
}

.quiz__step-num {
  display: block;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--color-primary);
  margin-bottom: var(--space-2);
}

.quiz__question {
  display: block;
  font-family: var(--font-headline);
  font-size: clamp(1.5rem, 4vw, 2rem);
  font-weight: 800;
  letter-spacing: -0.01em;
  line-height: 1.15;
  text-transform: uppercase;
  color: var(--color-text);
}

/* Options — radios styled as full-width tap cards */
.quiz__options {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  margin: 0 0 var(--space-6);
  padding: 0;
}

.quiz__option {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  min-height: 56px;       /* spec section 4.5: large tap targets on mobile */
  padding: var(--space-3) var(--space-4);
  border: 2px solid var(--color-border);
  background: var(--color-surface);
  cursor: pointer;
  font-size: 1rem;
  font-weight: 500;
  transition: border-color 150ms ease, background 150ms ease;
}

.quiz__option:hover {
  border-color: var(--color-text);
}

.quiz__option input[type="radio"] {
  appearance: none;
  -webkit-appearance: none;
  width: 22px;
  height: 22px;
  border: 2px solid var(--color-border);
  border-radius: 50%;
  background: var(--color-surface);
  position: relative;
  flex-shrink: 0;
  cursor: pointer;
  margin: 0;
}

.quiz__option input[type="radio"]:checked {
  border-color: var(--color-action);
}

.quiz__option input[type="radio"]:checked::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--color-action);
}

.quiz__option input[type="radio"]:focus-visible {
  outline: 2px solid var(--color-primary);
  outline-offset: 2px;
}

.quiz__option:has(input:checked) {
  border-color: var(--color-action);
  background: var(--color-primary-light);
}

/* Contact fields (step 4) */
.quiz__field {
  margin-bottom: var(--space-4);
}

.quiz__field label {
  display: block;
  font-weight: 600;
  font-size: 0.9375rem;
  margin-bottom: var(--space-2);
}

.quiz__req {
  color: var(--color-error);
}

.quiz__field input,
.quiz__field textarea {
  width: 100%;
  min-height: 48px;
  padding: var(--space-3);
  border: 2px solid var(--color-border);
  background: var(--color-surface);
  font-family: var(--font-body);
  font-size: 1rem;
  color: var(--color-text);
  border-radius: 2px;
  transition: border-color 150ms ease;
}

.quiz__field textarea {
  min-height: 72px;
  resize: vertical;
  font-family: var(--font-body);
}

.quiz__field input:focus,
.quiz__field textarea:focus {
  border-color: var(--color-primary);
  outline: none;
}

.quiz__field[data-invalid] input,
.quiz__field[data-invalid] textarea {
  border-color: var(--color-error);
}

.quiz__error {
  margin-top: var(--space-2);
  margin-bottom: 0;
  color: var(--color-error);
  font-size: 0.875rem;
  font-weight: 500;
}

/* Step navigation */
.quiz__nav {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  margin-top: var(--space-6);
}

/* Back button pushes any siblings to the right */
.quiz__back {
  margin-right: auto;
}

/* Step 4: Back small + Submit full-width below */
.quiz__step[data-step="4"] .quiz__nav {
  flex-direction: column-reverse;
  align-items: stretch;
}

.quiz__step[data-step="4"] .quiz__back {
  margin-right: 0;
  align-self: flex-start;
}

.quiz__step[data-step="4"] .quiz__submit {
  width: 100%;
}

@media (max-width: 480px) {
  .quiz__nav {
    flex-direction: column-reverse;
    align-items: stretch;
  }
  .quiz__back {
    margin-right: 0;
    align-self: flex-start;
  }
  .quiz__next {
    width: 100%;
  }
}

.quiz__legal {
  margin-top: var(--space-4);
  font-size: 0.8125rem;
  line-height: 1.5;
  color: var(--color-text-muted);
  text-align: center;
}

/* Honeypot — visually + accessibly hidden, focusable only by bots */
.quiz__honeypot {
  position: absolute;
  left: -9999px;
  top: -9999px;
  width: 1px;
  height: 1px;
  opacity: 0;
}

/* Server-error panel (revealed on submit failure) */
.quiz__server-error {
  margin-top: var(--space-6);
  padding: var(--space-4);
  border: 2px solid var(--color-error);
  background: #FBEAEA;
  color: var(--color-text);
  font-weight: 500;
}

.quiz__server-error p {
  margin: 0;
}

.quiz__server-error a {
  color: var(--color-action);
  font-weight: 700;
  text-decoration: underline;
}


/* ============================================================
   14. Homepage sections
   ============================================================ */

/* ── 14.1 Hero ── */
.hero {
  background: var(--color-surface);
  padding-top: var(--space-12);
  padding-bottom: var(--space-16);
  /* Subtle concrete-texture noise overlay — pure CSS, no image request */
  background-image:
    radial-gradient(rgba(0, 0, 0, 0.025) 1px, transparent 1px);
  background-size: 4px 4px;
}

@media (min-width: 1024px) {
  .hero {
    padding-top: var(--space-16);
    padding-bottom: var(--space-24);
  }
}

.hero__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-8);
  align-items: center;
}

@media (min-width: 1024px) {
  .hero__grid {
    grid-template-columns: 1.1fr 1fr;
    gap: var(--space-16);
  }
}

.hero__title {
  margin-top: var(--space-2);
  margin-bottom: var(--space-4);
}

.hero__sub {
  font-size: 1.125rem;
  line-height: 1.55;
  color: var(--color-text-muted);
  max-width: 50ch;
  margin-bottom: var(--space-6);
}

.hero__cta {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
  margin-bottom: var(--space-6);
}

.hero__trust {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-4);
  padding: 0;
  margin: 0;
  font-size: 0.875rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--color-text-muted);
}

.hero__trust li {
  position: relative;
  padding-left: 1.25rem;
}

.hero__trust li::before {
  content: "✓";
  position: absolute;
  left: 0;
  top: 0;
  color: var(--color-success);
  font-weight: 700;
}

.hero__media {
  order: -1;
}

@media (min-width: 1024px) {
  .hero__media {
    order: 0;
  }
}

.hero__media img {
  width: 100%;
  height: auto;
  aspect-ratio: 4 / 3;
  object-fit: cover;
}


/* ── 14.2 Services grid ── */
.services__header {
  margin-bottom: var(--space-8);
}

.services__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-4);
}

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

@media (min-width: 1024px) {
  .services__grid {
    grid-template-columns: repeat(3, 1fr);
    /* 5 cards = 3 top row + 2 left-aligned bottom row; empty cell reads as breathing room */
  }
}

.service-card {
  display: flex;
  flex-direction: column;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  color: var(--color-text);
  text-decoration: none;
  transition: border-color 150ms ease, transform 200ms ease;
  overflow: hidden;
}

.service-card:hover,
.service-card:focus-visible {
  border-color: var(--color-action);
  transform: translateY(-2px);
}

.service-card__media {
  aspect-ratio: 3 / 2;
  overflow: hidden;
}

.service-card__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.service-card__title {
  margin: var(--space-6) var(--space-4) var(--space-2);
  font-size: 1.25rem;
}

.service-card__desc {
  margin: 0 var(--space-4) var(--space-4);
  color: var(--color-text-muted);
  font-size: 0.9375rem;
}

.service-card__link {
  margin: auto var(--space-4) var(--space-4);
  font-size: 0.875rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--color-primary);
}


/* ── 14.3 How We Quote ── */
.how-we-quote__header {
  margin-bottom: var(--space-8);
}

.how-we-quote__steps {
  list-style: none;
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-8);
  padding: 0;
  margin: 0;
}

@media (min-width: 768px) {
  .how-we-quote__steps {
    grid-template-columns: repeat(3, 1fr);
    gap: var(--space-12);
  }
}

.how-we-quote__step {
  padding-top: var(--space-2);
}

.how-we-quote__num {
  display: block;
  font-family: var(--font-headline);
  font-size: 4rem;
  font-weight: 800;
  line-height: 1;
  color: var(--color-primary);
  margin-bottom: var(--space-3);
  letter-spacing: -0.02em;
}

.how-we-quote__step h3 {
  text-transform: uppercase;
  font-size: 1.125rem;
  margin-bottom: var(--space-2);
}

.how-we-quote__step p {
  color: var(--color-text-muted);
}


/* ── 14.4 Before/after strip ── */
.before-after__header {
  margin-bottom: var(--space-8);
}

.before-after__grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-3);
}

@media (min-width: 1024px) {
  .before-after__grid {
    grid-template-columns: repeat(4, 1fr);
    gap: var(--space-4);
  }
}

.before-after__item {
  margin: 0;
  overflow: hidden;
}

.before-after__item img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  transition: transform 300ms ease;
}

.before-after__item:hover img {
  transform: scale(1.04);
}

.before-after__item figcaption {
  margin-top: var(--space-2);
  font-size: 0.8125rem;
  color: var(--color-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  font-weight: 600;
}


/* ── 14.5 Why us — 4 blocks ── */
.why-us__header {
  margin-bottom: var(--space-8);
}

.why-us__grid {
  list-style: none;
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-6);
  padding: 0;
  margin: 0;
}

@media (min-width: 768px) {
  .why-us__grid {
    grid-template-columns: repeat(2, 1fr);
    gap: var(--space-8);
  }
}

@media (min-width: 1024px) {
  .why-us__grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

.why-us__item {
  border-left: 4px solid var(--color-action);
  padding-left: var(--space-4);
}

.why-us__item h3 {
  text-transform: uppercase;
  font-size: 1rem;
  letter-spacing: 0.02em;
  margin-bottom: var(--space-2);
}

.why-us__item p {
  color: var(--color-text-muted);
  font-size: 0.9375rem;
}


/* ── 14.6 FAQ — <details>/<summary>, no JS ── */
.faq__header {
  margin-bottom: var(--space-8);
}

.faq__list {
  max-width: 800px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

.faq__item {
  border: 1px solid var(--color-border);
  background: var(--color-surface);
}

.faq__item[open] {
  border-color: var(--color-action);
}

.faq__item summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
  padding: var(--space-4) var(--space-6);
  font-family: var(--font-headline);
  font-size: 1.125rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: -0.005em;
  cursor: pointer;
  list-style: none;
}

.faq__item summary::-webkit-details-marker {
  display: none;
}

.faq__icon {
  width: 16px;
  height: 16px;
  position: relative;
  flex-shrink: 0;
}

.faq__icon::before,
.faq__icon::after {
  content: "";
  position: absolute;
  background: var(--color-action);
  transition: transform 200ms ease, opacity 150ms ease;
}

.faq__icon::before {
  left: 0; right: 0; top: 50%;
  height: 2px;
  transform: translateY(-50%);
}

.faq__icon::after {
  top: 0; bottom: 0; left: 50%;
  width: 2px;
  transform: translateX(-50%);
}

.faq__item[open] .faq__icon::after {
  opacity: 0;
  transform: translateX(-50%) rotate(90deg);
}

.faq__answer {
  padding: 0 var(--space-6) var(--space-6);
  color: var(--color-text-muted);
}


/* ── 14.7 Final CTA (dark section) ── */
.final-cta__inner {
  max-width: 720px;
  margin-left: auto;
  margin-right: auto;
  text-align: center;
}

.final-cta__inner p {
  margin-top: calc(var(--space-2) * -1);
  margin-bottom: var(--space-6);
  font-size: 1.125rem;
  color: rgba(255, 255, 255, 0.85);
}

.final-cta__buttons {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
  justify-content: center;
}


/* ============================================================
   15. Service-page sections
   ============================================================ */

/* ── 15.1 Breadcrumb ── */
.breadcrumb {
  font-size: 0.875rem;
  color: var(--color-text-muted);
  margin-bottom: var(--space-3);
}

.breadcrumb a {
  color: var(--color-primary);
  text-decoration: none;
  font-weight: 600;
}

.breadcrumb a:hover,
.breadcrumb a:focus-visible {
  text-decoration: underline;
  text-underline-offset: 2px;
}

.breadcrumb span[aria-hidden] {
  margin: 0 var(--space-2);
  color: var(--color-border);
}


/* ── 15.2 Hero variant for service pages ── */
.hero--service .hero__title {
  font-size: clamp(1.875rem, 4.5vw, 3.25rem);
}


/* ── 15.3 What we do (long-form content block) ── */
.what-we-do__header {
  margin-bottom: var(--space-6);
}

.what-we-do__body {
  max-width: 65ch;
}

.what-we-do__body p {
  font-size: 1.0625rem;
  line-height: 1.65;
  margin-bottom: var(--space-4);
}

.what-we-do__body p:last-child {
  margin-bottom: 0;
}


/* ── 15.4 Pricing block ── */
.pricing__header {
  margin-bottom: var(--space-6);
}

.pricing__rate {
  font-family: var(--font-headline);
  font-size: clamp(2rem, 5vw, 3rem);
  font-weight: 800;
  letter-spacing: -0.01em;
  line-height: 1.1;
  color: var(--color-action);
  margin: 0 0 var(--space-4);
}

/* Two-up split: used on the patios page to keep the standard vs stamped
   rate bands visually segmented (single combined band would blur the
   anchor and hurt conversion clarity). */
.pricing__split {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-3);
  margin-bottom: var(--space-8);
}

@media (min-width: 600px) {
  .pricing__split {
    grid-template-columns: 1fr 1fr;
  }
}

.pricing__split-card {
  padding: var(--space-6);
  border: 2px solid var(--color-action);
  background: var(--color-surface);
}

.pricing__split-label {
  display: block;
  font-family: var(--font-body);
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--color-text-muted);
  margin-bottom: var(--space-2);
}

.pricing__split-rate {
  font-family: var(--font-headline);
  font-size: clamp(1.5rem, 4vw, 2.25rem);
  font-weight: 800;
  letter-spacing: -0.01em;
  line-height: 1.1;
  color: var(--color-action);
  margin: 0 0 var(--space-3);
}

.pricing__split-note {
  font-size: 0.875rem;
  line-height: 1.5;
  color: var(--color-text-muted);
  margin: 0;
}

.pricing__body {
  max-width: 65ch;
}

.pricing__body > p {
  font-size: 1.0625rem;
  line-height: 1.65;
  margin-bottom: var(--space-6);
}

.pricing__examples {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-4);
}

@media (min-width: 600px) {
  .pricing__examples {
    grid-template-columns: 1fr 1fr;
  }
}

.pricing__example {
  border-left: 4px solid var(--color-primary);
  padding: var(--space-3) var(--space-4);
  background: var(--color-surface);
}

.pricing__example strong {
  display: block;
  font-family: var(--font-headline);
  font-size: 1.0625rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  margin-bottom: var(--space-2);
}

.pricing__example p {
  font-size: 0.9375rem;
  line-height: 1.55;
  color: var(--color-text-muted);
  margin: 0;
}


/* ── 15.5 Other services (cross-link block on service pages) ── */
.other-services__header {
  margin-bottom: var(--space-6);
}

.other-services__grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-3);
}

@media (min-width: 768px) {
  .other-services__grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

.other-services__card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
  padding: var(--space-4);
  border: 1px solid var(--color-border);
  background: var(--color-surface);
  color: var(--color-text);
  text-decoration: none;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  font-size: 0.875rem;
  transition: border-color 150ms ease, background 150ms ease;
}

.other-services__card:hover,
.other-services__card:focus-visible {
  border-color: var(--color-action);
  background: var(--color-primary-light);
}

.other-services__card::after {
  content: "→";
  color: var(--color-primary);
  font-weight: 700;
  flex-shrink: 0;
}


/* ============================================================
   16. Minimal header (thank-you page and other conversion-confirmation pages)
   ============================================================ */
.site-header--minimal .site-header__nav,
.site-header--minimal .site-header__actions,
.site-header--minimal .site-header__menu-toggle {
  display: none;
}

.site-header--minimal .site-header__brand {
  margin-right: 0;
}


/* ============================================================
   17. Thank-you page
   ============================================================ */
.page-thank-you {
  background: var(--color-surface);
}

.thank-you {
  text-align: center;
}

.thank-you__inner {
  max-width: 720px;
}

.thank-you__check-wrap {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-bottom: var(--space-4);
}

.thank-you__check {
  color: var(--color-success);
}

.thank-you__title {
  margin-bottom: var(--space-4);
}

.thank-you__lead {
  font-size: 1.125rem;
  line-height: 1.55;
  color: var(--color-text-muted);
  max-width: 50ch;
  margin-left: auto;
  margin-right: auto;
  margin-bottom: var(--space-6);
}

.thank-you__cta {
  margin-bottom: var(--space-16);
}

.next-steps {
  text-align: left;
  padding-top: var(--space-8);
  border-top: 1px solid var(--color-border);
}

.next-steps__steps {
  text-align: left;
}

.next-steps .how-we-quote__step h3 {
  text-transform: uppercase;
}


/* ============================================================
   18. Legal pages (privacy policy, terms)
   ============================================================ */
.legal-page__inner {
  max-width: 760px;
}

.legal-page__header {
  margin-bottom: var(--space-8);
  padding-bottom: var(--space-6);
  border-bottom: 1px solid var(--color-border);
}

.legal-page__header h1 {
  margin-top: var(--space-2);
  margin-bottom: var(--space-3);
  font-size: clamp(2rem, 5vw, 3rem);
}

.legal-page__date {
  font-size: 0.875rem;
  color: var(--color-text-muted);
  margin: 0;
}

.legal-content h2 {
  text-transform: none;
  letter-spacing: -0.005em;
  font-size: clamp(1.25rem, 3vw, 1.5rem);
  margin-top: var(--space-8);
  margin-bottom: var(--space-3);
}

.legal-content > *:first-child {
  margin-top: 0;
}

.legal-content p {
  font-size: 1.0625rem;
  line-height: 1.65;
  margin-bottom: var(--space-4);
}

.legal-content ul,
.legal-content ol {
  margin-bottom: var(--space-4);
  padding-left: var(--space-6);
}

.legal-content li {
  font-size: 1.0625rem;
  line-height: 1.65;
  margin-bottom: var(--space-2);
}

.legal-content a {
  color: var(--color-primary);
  text-decoration: underline;
  text-underline-offset: 2px;
  font-weight: 500;
}

.legal-content a:hover,
.legal-content a:focus-visible {
  color: var(--color-primary-dark);
}

.legal-content strong {
  font-weight: 600;
}


/* ============================================================
   19. Lightbox (before/after thumbnails)
   ============================================================ */
body.is-lightbox-open {
  overflow: hidden;
}

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 1000;
  background: rgba(10, 13, 20, 0.92);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--space-4);
}

.lightbox[hidden] {
  display: none;
}

.lightbox__figure {
  margin: 0;
  max-width: min(1280px, 100%);
  max-height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.lightbox__img {
  max-width: 100%;
  max-height: 85vh;
  height: auto;
  width: auto;
  object-fit: contain;
  background: #000;
}

.lightbox__caption {
  margin-top: var(--space-3);
  color: rgba(255, 255, 255, 0.85);
  font-size: 0.875rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-weight: 500;
  text-align: center;
}

.lightbox__close,
.lightbox__prev,
.lightbox__next {
  position: absolute;
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.4);
  color: var(--color-surface);
  border: 0;
  border-radius: 50%;
  cursor: pointer;
  font-size: 1.25rem;
  font-weight: 700;
  font-family: var(--font-body);
  transition: background-color 150ms ease;
}

.lightbox__close:hover,
.lightbox__prev:hover,
.lightbox__next:hover,
.lightbox__close:focus-visible,
.lightbox__prev:focus-visible,
.lightbox__next:focus-visible {
  background: rgba(255, 255, 255, 0.2);
  outline: 2px solid var(--color-surface);
  outline-offset: 2px;
}

.lightbox__close { top: var(--space-4); right: var(--space-4); font-size: 1.75rem; line-height: 1; }
.lightbox__prev  { left: var(--space-4); top: 50%; transform: translateY(-50%); }
.lightbox__next  { right: var(--space-4); top: 50%; transform: translateY(-50%); }


/* ============================================================
   20. Error page (404)
   ============================================================ */
.error-page {
  text-align: center;
}

.error-page__inner {
  max-width: 640px;
}

.error-page__code {
  font-family: var(--font-headline);
  font-size: clamp(4rem, 14vw, 8rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1;
  color: var(--color-primary);
  margin: 0 0 var(--space-3);
}

.error-page__title {
  margin-bottom: var(--space-3);
}

.error-page__lead {
  font-size: 1.125rem;
  line-height: 1.55;
  color: var(--color-text-muted);
  max-width: 40ch;
  margin: 0 auto var(--space-6);
}

.error-page__cta {
  margin-bottom: var(--space-12);
}

.error-page__services {
  text-align: left;
  padding-top: var(--space-8);
  border-top: 1px solid var(--color-border);
}

.error-page__services-label {
  font-size: 0.875rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--color-text-muted);
  margin-bottom: var(--space-3);
  text-align: center;
}

.error-page__services ul {
  list-style: none;
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-2);
  padding: 0;
  margin: 0;
}

@media (min-width: 600px) {
  .error-page__services ul {
    grid-template-columns: 1fr 1fr;
  }
}

.error-page__services a {
  display: block;
  padding: var(--space-3) var(--space-4);
  border: 1px solid var(--color-border);
  background: var(--color-surface);
  color: var(--color-text);
  font-weight: 600;
  font-size: 0.9375rem;
  text-decoration: none;
  text-align: center;
  transition: border-color 150ms ease, background 150ms ease;
}

.error-page__services a:hover,
.error-page__services a:focus-visible {
  border-color: var(--color-action);
  background: var(--color-primary-light);
}

/* Single image — hide prev/next when only 1 (lightbox.js leaves them; CSS no-op since
   items.length is always > 1 in practice). */
@media (max-width: 640px) {
  .lightbox__prev,
  .lightbox__next {
    bottom: var(--space-4);
    top: auto;
    transform: none;
  }
  .lightbox__prev { left: var(--space-4); }
  .lightbox__next { right: var(--space-4); }
}
