/* ============================================================================
   NORTHPOINT — One-Page Master Template
   A productized landing-page system. Reskin by editing the TOKENS below.
   No external dependencies. System fonts for speed (Core Web Vitals).
   ----------------------------------------------------------------------------
   HOW TO REBRAND A CLIENT IN ~2 MINUTES:
   1. Change --primary / --cta / --accent in :root (see docs/COLOR-RECIPES.md).
   2. Swap the font stack in --font if the brand needs a custom typeface.
   3. Everything else (shadows, radius, spacing) scales from these tokens.
   ============================================================================ */

/* ---------- DESIGN TOKENS ---------- */
:root {
  /* Brand — the three colors you change per client */
  --primary:      #1b3a6b;   /* trust / structure: header, headings accents */
  --primary-700:  #12294d;   /* darker primary for gradients/footer */
  --cta:          #c2410c;   /* the ONE protected action color (AA on white) */
  --cta-strong:   #9a3412;   /* CTA hover */
  --accent:       #c8911f;   /* small highlights, stars, eyebrows */

  /* Hero photo — drop in a real image in ONE line:
     --hero-image: url("assets/hero.jpg");   (leave as none to keep the placeholder) */
  --hero-image: none;

  /* Neutrals (light theme) */
  --bg:        #ffffff;
  --bg-alt:    #f5f8fc;
  --surface:   #ffffff;
  --border:    #e4e9f2;
  --text:      #14213d;
  --muted:     #51607a;
  --on-primary:#ffffff;
  --on-cta:    #ffffff;

  /* Semantic */
  --success: #15803d;
  --warning: #b45309;
  --error:   #b91c1c;
  --info:    #1d4ed8;

  /* Type */
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial,
          "Apple Color Emoji", "Segoe UI Emoji", sans-serif;
  --h1: clamp(2.1rem, 1.2rem + 3.6vw, 3.6rem);
  --h2: clamp(1.7rem, 1.15rem + 2.1vw, 2.5rem);
  --h3: clamp(1.12rem, 1rem + 0.5vw, 1.28rem);
  --lead: clamp(1.05rem, 0.98rem + 0.45vw, 1.22rem);

  /* Spacing scale (8px base) */
  --s-1: .5rem;  --s-2: .75rem; --s-3: 1rem;   --s-4: 1.5rem;
  --s-5: 2rem;   --s-6: 3rem;   --s-7: 4.5rem; --s-8: 6.5rem;

  /* Shape & depth */
  --radius:   16px;
  --radius-sm:10px;
  --radius-pill: 999px;
  --shadow-sm: 0 1px 2px rgba(16,28,51,.06), 0 1px 3px rgba(16,28,51,.05);
  --shadow:    0 10px 30px -12px rgba(16,28,51,.18);
  --shadow-lg: 0 30px 60px -20px rgba(16,28,51,.28);
  --ring: 0 0 0 3px rgba(27,58,107,.22);

  --container: 1140px;
  --header-h: 70px;
  --ease: cubic-bezier(.16,.84,.44,1);
}
/* ---------- DARK THEME ---------- */
/* Not a raw invert — softened surfaces + borders, no white shadows (playbook). */
[data-theme="dark"] {
  --primary:    #5b8ad6;
  --primary-700:#3f6fbd;
  --cta:        #d4540f;
  --cta-strong: #ec6a23;
  --accent:     #e0b34a;

  --bg:        #0e1726;
  --bg-alt:    #131f33;
  --surface:   #16243c;
  --border:    #25344b;
  --text:      #e9eef7;
  --muted:     #a3b3cd;
  --on-primary:#ffffff;
  --on-cta:    #ffffff;

  --success: #4ade80;
  --warning: #fbbf24;
  --error:   #f87171;
  --info:    #60a5fa;

  --shadow-sm: 0 1px 2px rgba(0,0,0,.4);
  --shadow:    0 14px 36px -16px rgba(0,0,0,.6);
  --shadow-lg: 0 30px 60px -20px rgba(0,0,0,.7);
  --ring: 0 0 0 3px rgba(91,138,214,.4);
}

/* Respect OS preference on first load (overridable by the toggle via JS) */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]):not([data-theme="dark"]) { color-scheme: dark; }
}

/* ---------- RESET / BASE ---------- */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  font-family: var(--font);
  color: var(--text);
  background: var(--bg);
  line-height: 1.6;
  font-size: 1.0625rem;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

h1, h2, h3, h4 { line-height: 1.15; font-weight: 800; letter-spacing: -.02em; color: var(--text); text-wrap: pretty; }
h1 { font-size: var(--h1); }
h2 { font-size: var(--h2); }
h3 { font-size: var(--h3); font-weight: 750; letter-spacing: -.01em; }
h2, h3, h4 { text-wrap: balance; } /* balance headings so no single word wraps onto its own line */
p { color: var(--text); text-wrap: pretty; } /* no lone word dangling on the last line (mainly mobile; desktop unaffected) */
blockquote { text-wrap: pretty; }
a { color: var(--primary); text-decoration: none; }
a:hover { text-decoration: underline; }
img, svg { display: block; max-width: 100%; }
.muted { color: var(--muted); }

/* Visible focus for keyboard users (accessibility) */
:focus-visible { outline: none; box-shadow: var(--ring); border-radius: 6px; }

/* Skip link */
.skip-link {
  position: absolute; left: var(--s-3); top: -100px; z-index: 200;
  background: var(--primary); color: #fff; padding: .6rem 1rem;
  border-radius: var(--radius-sm); transition: top .2s var(--ease);
}
.skip-link:focus { top: var(--s-3); text-decoration: none; }

/* ---------- LAYOUT ---------- */
.container { width: 100%; max-width: var(--container); margin-inline: auto; padding-inline: var(--s-4); }
.container--narrow { max-width: 780px; }
.section { padding-block: var(--s-8); }
.section--alt { background: var(--bg-alt); }
.section__head { max-width: 720px; margin: 0 auto var(--s-6); text-align: center; }
.section__sub { color: var(--muted); font-size: var(--lead); margin-top: var(--s-2); }
.section__cta { text-align: center; margin-top: var(--s-6); }
.lead { font-size: var(--lead); color: var(--muted); margin-top: var(--s-3); }

.eyebrow {
  text-transform: uppercase; letter-spacing: .14em; font-size: .78rem;
  font-weight: 700; color: var(--muted); margin-bottom: var(--s-2);
}
.eyebrow--accent { color: var(--cta); }

/* ---------- BUTTONS ---------- */
.btn {
  --btn-bg: var(--surface); --btn-fg: var(--text);
  display: inline-flex; align-items: center; justify-content: center; gap: .55rem;
  font: inherit; font-weight: 700; font-size: 1rem; line-height: 1;
  padding: .8rem 1.25rem; border-radius: var(--radius-pill);
  background: var(--btn-bg); color: var(--btn-fg);
  border: 1.5px solid transparent; cursor: pointer;
  transition: transform .15s var(--ease), box-shadow .2s var(--ease),
              background-color .2s var(--ease), border-color .2s var(--ease);
  text-decoration: none; white-space: nowrap;
}
.btn:hover { text-decoration: none; transform: translateY(-1px); }
.btn:active { transform: translateY(0); }
.btn--lg { font-size: 1.0625rem; padding: 1rem 1.6rem; }
.btn--block { width: 100%; }

.btn--cta { --btn-bg: var(--cta); --btn-fg: var(--on-cta); box-shadow: var(--shadow-sm); }
.btn--cta:hover { --btn-bg: var(--cta-strong); box-shadow: var(--shadow); }

.btn--ghost {
  --btn-bg: transparent; --btn-fg: var(--text);
  border-color: var(--border); box-shadow: var(--shadow-sm);
}
.btn--ghost:hover { border-color: var(--primary); --btn-fg: var(--primary); }

/* ---------- HEADER ---------- */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: saturate(140%) blur(10px);
  border-bottom: 1px solid transparent;
  transition: border-color .25s var(--ease), box-shadow .25s var(--ease), background-color .25s var(--ease);
}
.site-header.is-elevated { border-bottom-color: var(--border); box-shadow: var(--shadow-sm); }
.header__inner { display: flex; align-items: center; gap: var(--s-3); min-height: var(--header-h); }

.brand { display: inline-flex; align-items: center; gap: .55rem; font-weight: 800; font-size: 1.22rem; color: var(--text); letter-spacing: -.02em; }
.brand:hover { text-decoration: none; }
.brand__mark { color: var(--primary); display: inline-flex; }
.brand__accent { color: var(--cta); }
.brand--footer { color: var(--text); }

.nav { display: flex; gap: var(--s-3); margin-inline: auto; }
.nav a { color: var(--muted); font-weight: 600; font-size: .96rem; padding: .35rem 0; position: relative; white-space: nowrap; }
.nav a:hover { color: var(--text); text-decoration: none; }
.nav a::after { content: ""; position: absolute; left: 0; right: 0; bottom: -2px; height: 2px; background: var(--cta); transform: scaleX(0); transform-origin: left; transition: transform .2s var(--ease); }
.nav a:hover::after { transform: scaleX(1); }

.header__actions { display: flex; align-items: center; gap: var(--s-2); margin-left: auto; }
.header__phone span { display: none; } /* icon-only — number hidden, tap-to-call kept */
.header__phone { width: 42px; height: 42px; padding: 0; gap: 0; display: inline-flex; align-items: center; justify-content: center; border-radius: var(--radius-pill); }
/* keep the busy desktop header on one tidy line */
.header__actions .btn--cta { padding: .68rem 1.05rem; }

.theme-toggle {
  display: inline-grid; place-items: center; width: 42px; height: 42px;
  border-radius: var(--radius-pill); border: 1.5px solid var(--border);
  background: var(--surface); color: var(--text); cursor: pointer;
  transition: border-color .2s var(--ease), color .2s var(--ease);
}
.theme-toggle:hover { border-color: var(--primary); color: var(--primary); }
.theme-toggle__moon { display: none; }
[data-theme="dark"] .theme-toggle__sun { display: none; }
[data-theme="dark"] .theme-toggle__moon { display: block; }

/* Mobile nav toggle (hamburger) — hidden on desktop */
.nav-toggle { display: none; flex-direction: column; gap: 5px; width: 44px; height: 44px; align-items: center; justify-content: center; background: transparent; border: 1.5px solid var(--border); border-radius: var(--radius-sm); cursor: pointer; }
.nav-toggle span { width: 20px; height: 2px; background: var(--text); border-radius: 2px; transition: transform .2s var(--ease), opacity .2s var(--ease); }
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---------- SOCIAL "FOLLOW" MENU (header dropdown) ---------- */
.social-menu { position: relative; display: inline-flex; }
/* icon-only Follow button — matches the theme toggle, keeps the header uncluttered */
.social-btn { width: 42px; height: 42px; padding: 0; gap: 0; display: inline-flex; align-items: center; justify-content: center; }
.social-btn__label, .social-btn__chev { display: none; }
.social-btn[aria-expanded="true"] { border-color: var(--primary); --btn-fg: var(--primary); }
.social-pop {
  position: absolute; top: calc(100% + 10px); right: 0; z-index: 120; min-width: 230px;
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-sm);
  box-shadow: var(--shadow); padding: .4rem;
  opacity: 0; transform: translateY(-8px) scale(.97); transform-origin: top right; visibility: hidden; pointer-events: none;
  transition: opacity .18s var(--ease), transform .18s var(--ease), visibility 0s linear .18s;
}
.social-pop.is-open { opacity: 1; transform: none; visibility: visible; pointer-events: auto;
  transition: opacity .18s var(--ease), transform .18s var(--ease), visibility 0s; }
.social-pop__head { font-size: .7rem; text-transform: uppercase; letter-spacing: .1em; color: var(--muted); font-weight: 700; padding: .4rem .65rem .25rem; }
.social-pop a { display: flex; align-items: center; gap: .7rem; padding: .55rem .65rem; border-radius: 8px; color: var(--text); font-weight: 600; font-size: .95rem; }
.social-pop a:hover { background: var(--bg-alt); color: var(--text); text-decoration: none; }
.social-pop a > svg:first-of-type { width: 18px; height: 18px; flex: none; color: var(--muted); transition: color .15s var(--ease); }
.social-pop a:hover > svg:first-of-type { color: var(--cta); }
.social-pop__go { margin-left: auto; color: var(--muted); opacity: 0; transform: translateX(-5px); transition: opacity .15s var(--ease), transform .15s var(--ease); }
.social-pop a:hover .social-pop__go { opacity: 1; transform: none; }
/* "Share Northpoint" — copies the link to the clipboard */
.social-pop__copy { display: flex; align-items: center; gap: .7rem; width: 100%; margin-top: .3rem; padding: .6rem .65rem; border: 0; border-top: 1px solid var(--border); background: none; color: var(--text); font: inherit; font-weight: 600; font-size: .95rem; cursor: pointer; text-align: left; }
.social-pop__copy > svg { width: 18px; height: 18px; flex: none; color: var(--muted); transition: color .15s var(--ease); }
.social-pop__copy:hover { background: var(--bg-alt); }
.social-pop__copy:hover > svg { color: var(--cta); }
.social-pop__copy .copy-done { display: none; margin-left: auto; color: var(--success); font-size: .82rem; font-weight: 700; }
.social-pop__copy.is-copied .copy-done { display: inline; }
.social-pop__copy.is-copied > svg { color: var(--success); }
@media (prefers-reduced-motion: reduce) { .social-pop { transition: opacity .01s; } .social-pop__go { transition: none; } }

/* ---------- HERO ---------- */
.hero { padding-block: clamp(2.5rem, 1rem + 7vw, 5.5rem); position: relative; overflow: hidden; }
.hero::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background:
    radial-gradient(60% 60% at 85% 0%, color-mix(in srgb, var(--primary) 12%, transparent), transparent 70%),
    radial-gradient(50% 50% at 0% 100%, color-mix(in srgb, var(--cta) 9%, transparent), transparent 70%);
}
.hero__grid { display: grid; grid-template-columns: 1.05fr .95fr; gap: var(--s-7); align-items: center; }
.hero__sub { font-size: var(--lead); color: var(--muted); margin-top: var(--s-3); max-width: 36ch; }
.hero__actions { display: flex; flex-wrap: wrap; gap: var(--s-2); margin-top: var(--s-5); }

.hero__proof { list-style: none; padding: 0; display: flex; flex-wrap: wrap; gap: var(--s-5); margin-top: var(--s-5); }
.hero__proof li { display: flex; flex-direction: column; gap: 2px; font-size: .9rem; }
.hero__proof strong { display: inline-flex; align-items: center; gap: .35rem; font-size: 1.25rem; color: var(--text); letter-spacing: -.02em; line-height: 1.15; }
.hero__proof .stars { font-size: .8rem; letter-spacing: .06em; }
.stars { color: var(--accent); letter-spacing: .05em; }

.hero__media { position: relative; }
.hero__photo { position: relative; border-radius: calc(var(--radius) + 6px); overflow: hidden; box-shadow: var(--shadow-lg); aspect-ratio: 4 / 3.4; }
.hero__art { width: 100%; height: 100%; }
/* Real photo layer: transparent when --hero-image is none, covers the placeholder when set */
.hero__photo-img { position: absolute; inset: 0; z-index: 2; background: var(--hero-image) center / cover no-repeat; }
.hero__photo-tag {
  position: absolute; inset: var(--s-3) var(--s-3) auto auto; z-index: 1;
  background: color-mix(in srgb, var(--bg) 80%, transparent); color: var(--text);
  font-size: .78rem; font-weight: 600; padding: .35rem .7rem; border-radius: var(--radius-pill);
  backdrop-filter: blur(4px); border: 1px solid var(--border);
}
.floatcard {
  position: absolute; left: 16px; bottom: 16px; display: flex; align-items: center; gap: .85rem;
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  padding: .9rem 1.15rem; box-shadow: var(--shadow);
  max-width: min(300px, calc(100% - 28px));
}
.floatcard strong { display: block; font-size: .98rem; line-height: 1.2; }
.floatcard span.muted { display: block; font-size: .83rem; line-height: 1.35; margin-top: 3px; }
.floatcard__icon { display: inline-grid; place-items: center; width: 44px; height: 44px; flex: none; border-radius: 13px; background: color-mix(in srgb, var(--success) 14%, transparent); color: var(--success); }

/* ---------- TRUST STRIP ---------- */
.trust { background: var(--primary); color: var(--on-primary); }
.trust__inner { display: flex; flex-wrap: wrap; justify-content: center; gap: var(--s-2) var(--s-5); padding-block: var(--s-3); }
.trust__item { display: inline-flex; align-items: center; gap: .45rem; font-size: .92rem; font-weight: 600; color: color-mix(in srgb, var(--on-primary) 92%, transparent); }
.trust__item span { color: var(--accent); }

/* ---------- TWO-COL (problem/promise) ---------- */
.two-col { display: grid; grid-template-columns: 1fr 1fr; gap: var(--s-7); align-items: center; }
.promise { list-style: none; padding: 0; display: grid; gap: var(--s-3); }
.promise li { display: flex; gap: var(--s-3); align-items: flex-start; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: var(--s-3) var(--s-4); box-shadow: var(--shadow-sm); }
/* Tiny 3D diamond bullet: a rotated square with a top-lit gradient + a highlight
   edge so it reads as a faceted gem. Same visual footprint as the old dot. */
.promise__dot {
  flex: none; width: 7px; height: 7px; margin-top: .6rem;
  transform: rotate(45deg); border-radius: 1px;
  background: linear-gradient(135deg,
    color-mix(in srgb, var(--primary) 42%, #fff),
    var(--primary) 52%,
    color-mix(in srgb, var(--primary) 70%, #000));
  box-shadow: inset .6px .6px 0 rgba(255,255,255,.5), 0 0 1.5px rgba(0,0,0,.22);
}

/* ---------- CARDS (services) ---------- */
.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--s-4); }
.card {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  padding: var(--s-5); box-shadow: var(--shadow-sm);
  transition: transform .2s var(--ease), box-shadow .2s var(--ease), border-color .2s var(--ease);
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow); border-color: color-mix(in srgb, var(--primary) 35%, var(--border)); }
.card__icon { display: inline-grid; place-items: center; width: 52px; height: 52px; border-radius: 14px; background: color-mix(in srgb, var(--primary) 12%, transparent); color: var(--primary); margin-bottom: var(--s-3); }
.card h3 { margin-bottom: .35rem; }
.card p { color: var(--muted); font-size: .98rem; }

/* ---------- STATS ---------- */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--s-4); margin-bottom: var(--s-6); }
.stat { text-align: center; background: var(--bg-alt); border: 1px solid var(--border); border-radius: var(--radius); padding: var(--s-4) var(--s-2); }
.stat strong { display: block; font-size: clamp(1.6rem, 1.1rem + 1.6vw, 2.2rem); color: var(--primary); letter-spacing: -.03em; }
.stat span { color: var(--muted); font-size: .9rem; }

/* ---------- TESTIMONIALS ---------- */
.testimonials { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--s-4); }
.quote { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: var(--s-5); box-shadow: var(--shadow-sm); display: flex; flex-direction: column; gap: var(--s-3); }
.quote blockquote { font-size: 1.02rem; }
.quote figcaption { display: flex; align-items: center; gap: .7rem; margin-top: auto; }
.quote__avatar { width: 42px; height: 42px; border-radius: 50%; flex: none; display: grid; place-items: center; font-weight: 700; font-size: .85rem; color: var(--on-primary); background: var(--primary); }
.quote figcaption span span { display: block; }
.disclosure { text-align: center; color: var(--muted); font-size: .82rem; margin-top: var(--s-4); font-style: italic; }

/* ---------- STEPS (process) ---------- */
.steps { list-style: none; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--s-5); counter-reset: step; position: relative; }
.step { position: relative; padding-top: var(--s-2); }
.step__num { display: grid; place-items: center; width: 52px; height: 52px; border-radius: 50%; background: var(--cta); color: var(--on-cta); font-weight: 800; font-size: 1.3rem; margin-bottom: var(--s-3); box-shadow: var(--shadow-sm); }
.step h3 { margin-bottom: .3rem; }
.step p { color: var(--muted); }

/* ---------- OFFER ---------- */
.offer {
  display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: var(--s-5);
  background: linear-gradient(120deg, var(--primary), var(--primary-700));
  color: var(--on-primary); border-radius: calc(var(--radius) + 6px);
  padding: var(--s-6); box-shadow: var(--shadow-lg);
}
.offer__icon { color: var(--accent); }
.offer__body h2 { color: #fff; }
.offer__body p { color: color-mix(in srgb, #fff 86%, transparent); margin-top: .4rem; }
.offer__cta { display: flex; flex-direction: column; align-items: stretch; gap: .5rem; text-align: center; }
.offer__fine { color: color-mix(in srgb, #fff 75%, transparent); font-size: .8rem; }

/* ---------- GALLERY ---------- */
.gallery { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--s-4); }
.tile { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow-sm); }
.tile__ph { aspect-ratio: 4 / 3; background: linear-gradient(135deg, color-mix(in srgb, var(--primary) 70%, #000 0%), var(--primary-700)); position: relative; }
.tile__ph[data-ph="2"] { background: linear-gradient(135deg, var(--primary), color-mix(in srgb, var(--cta) 55%, var(--primary))); }
.tile__ph[data-ph="3"] { background: linear-gradient(135deg, color-mix(in srgb, var(--accent) 60%, var(--primary)), var(--primary-700)); }
.tile__ph::after { content: "Add photo"; position: absolute; inset: 0; display: grid; place-items: center; color: rgba(255,255,255,.7); font-size: .85rem; font-weight: 600; letter-spacing: .02em; }
.tile figcaption { padding: var(--s-3) var(--s-4); color: var(--muted); font-size: .92rem; }

/* ---------- VIDEO FEATURE + LIGHTBOX ---------- */
/* Branded band so it reads as a premium "feature" moment and contrasts the sections around it. */
.video-feature { background: linear-gradient(135deg, var(--primary), var(--primary-700)); color: var(--on-primary); }
.video-feature .section__head h2 { color: #fff; }
.video-feature .section__sub { color: color-mix(in srgb, #fff 82%, transparent); }

.video-poster {
  display: block; position: relative; width: 100%; max-width: 860px; margin: 0 auto;
  aspect-ratio: 16 / 9; padding: 0; cursor: pointer;
  border: 1px solid rgba(255,255,255,.14); border-radius: calc(var(--radius) + 6px);
  overflow: hidden; background: var(--primary-700); box-shadow: var(--shadow-lg);
  transition: transform .25s var(--ease), box-shadow .25s var(--ease);
}
.video-poster:hover { transform: translateY(-3px); }
.video-poster:focus-visible { box-shadow: var(--ring), var(--shadow-lg); }
.video-poster__art, .video-poster__img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.video-poster::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 45%, rgba(8,16,30,.45)); }
.video-poster__play {
  position: absolute; top: 50%; left: 50%; transform: translate(-50%,-50%); z-index: 1;
  width: 78px; height: 78px; border-radius: 50%; display: grid; place-items: center;
  background: rgba(255,255,255,.94); color: var(--primary);
  box-shadow: 0 12px 34px rgba(0,0,0,.4);
  transition: transform .25s var(--ease), background-color .2s var(--ease);
}
.video-poster__play svg { margin-left: 4px; } /* optically center the triangle */
.video-poster:hover .video-poster__play { transform: translate(-50%,-50%) scale(1.07); background: #fff; }
.video-poster__play::before {
  content: ""; position: absolute; inset: -10px; border-radius: 50%;
  border: 2px solid rgba(255,255,255,.55); animation: videoPulse 2.4s var(--ease) infinite;
}
@keyframes videoPulse { 0% { transform: scale(.92); opacity: .7; } 70% { transform: scale(1.28); opacity: 0; } 100% { opacity: 0; } }
.video-poster__tag {
  position: absolute; left: 16px; bottom: 14px; z-index: 1;
  background: rgba(8,16,30,.55); color: #fff; font-size: .82rem; font-weight: 600;
  padding: .35rem .7rem; border-radius: var(--radius-pill); backdrop-filter: blur(4px);
}
@media (prefers-reduced-motion: reduce) { .video-poster__play::before { animation: none; } }

.video-modal { position: fixed; inset: 0; z-index: 200; display: grid; place-items: center; padding: var(--s-4); }
.video-modal[hidden] { display: none; }
.video-modal__backdrop { position: absolute; inset: 0; background: rgba(6,12,22,.82); backdrop-filter: blur(6px); animation: vmFade .2s var(--ease); }
.video-modal__dialog { position: relative; width: min(960px, 100%); animation: vmPop .25s var(--ease); }
.video-modal__frame { position: relative; aspect-ratio: 16 / 9; width: 100%; border-radius: var(--radius); overflow: hidden; background: #000; box-shadow: var(--shadow-lg); }
.video-modal__frame iframe, .video-modal__frame video { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.video-modal__placeholder { position: absolute; inset: 0; display: grid; place-content: center; justify-items: center; gap: .4rem; text-align: center; padding: var(--s-5); color: #fff; background: linear-gradient(135deg, var(--primary-700), #0a1322); }
.video-modal__placeholder svg { color: var(--accent); margin-bottom: .5rem; }
.video-modal__placeholder strong { font-size: 1.1rem; }
.video-modal__placeholder span { color: rgba(255,255,255,.72); font-size: .9rem; max-width: 36ch; }
.video-modal__close {
  position: absolute; top: -14px; right: -14px; z-index: 1; width: 44px; height: 44px;
  border-radius: 50%; border: 0; cursor: pointer; display: grid; place-items: center;
  background: #fff; color: var(--primary); box-shadow: var(--shadow);
}
.video-modal__close:hover { color: var(--cta); }
@media (max-width: 600px) { .video-modal__close { top: -10px; right: 2px; } }
@keyframes vmFade { from { opacity: 0; } to { opacity: 1; } }
@keyframes vmPop { from { opacity: 0; transform: translateY(10px) scale(.98); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { .video-modal__backdrop, .video-modal__dialog { animation: none; } }

/* ---------- FAQ ---------- */
.faq { display: grid; gap: var(--s-2); }
.faq__item { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-sm); overflow: hidden; }
.faq__item summary {
  list-style: none; cursor: pointer; padding: var(--s-3) var(--s-4);
  font-weight: 650; font-size: 1.02rem; display: flex; align-items: center; justify-content: space-between; gap: var(--s-3);
}
.faq__item summary::-webkit-details-marker { display: none; }
.faq__chev { width: 12px; height: 12px; border-right: 2px solid var(--muted); border-bottom: 2px solid var(--muted); transform: rotate(45deg); transition: transform .2s var(--ease); flex: none; }
.faq__item[open] .faq__chev { transform: rotate(-135deg); }
.faq__a { padding: 0 var(--s-4) var(--s-4); }
.faq__a p { color: var(--muted); }

/* ---------- CONTACT ---------- */
.section--cta { background: var(--bg-alt); }
.contact { display: grid; grid-template-columns: 1fr 1fr; gap: var(--s-7); align-items: start; }
.contact__details { list-style: none; padding: 0; margin-top: var(--s-5); display: grid; gap: var(--s-3); }
.contact__details li { display: flex; align-items: center; gap: .7rem; font-weight: 600; }
.contact__details a { color: var(--text); }
.contact__details a:hover { color: var(--cta); }
.contact__ic { display: inline-grid; place-items: center; width: 40px; height: 40px; flex: none; border-radius: 12px; background: var(--surface); border: 1px solid var(--border); color: var(--primary); }

.lead-form { background: var(--surface); border: 1px solid var(--border); border-radius: calc(var(--radius) + 4px); padding: var(--s-5); box-shadow: var(--shadow); }
.lead-form__row { display: grid; grid-template-columns: 1fr 1fr; gap: var(--s-3); }
.field { display: flex; flex-direction: column; gap: .35rem; margin-bottom: var(--s-3); }
.field label { font-weight: 650; font-size: .92rem; }
.field input, .field select, .field textarea {
  font: inherit; color: var(--text); background: var(--bg);
  border: 1.5px solid var(--border); border-radius: var(--radius-sm);
  padding: .7rem .85rem; width: 100%; transition: border-color .15s var(--ease), box-shadow .15s var(--ease);
}
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--primary); box-shadow: var(--ring); }
.field textarea { resize: vertical; }
.field input[type="tel"] { font-variant-numeric: tabular-nums; letter-spacing: .04em; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.form-note { font-size: .82rem; color: var(--muted); margin-top: var(--s-3); }
.form-note a { color: var(--primary); text-decoration: underline; }
.form-success { margin-top: var(--s-3); padding: var(--s-3); border-radius: var(--radius-sm); background: color-mix(in srgb, var(--success) 14%, transparent); color: var(--success); font-weight: 650; }

/* ---------- FOOTER ---------- */
.site-footer { background: var(--primary-700); color: color-mix(in srgb, #fff 88%, transparent); padding-top: var(--s-7); }
[data-theme="dark"] .site-footer { background: #0a1220; }
.footer__grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: var(--s-5); padding-bottom: var(--s-6); }
.footer__brand .brand__name, .footer__brand .brand__mark { color: #fff; }
.footer__brand p { margin-top: var(--s-2); color: color-mix(in srgb, #fff 72%, transparent); font-size: .92rem; max-width: 30ch; }
.socials { list-style: none; padding: 0; margin-top: var(--s-3); display: flex; gap: .5rem; flex-wrap: wrap; }
.socials a {
  display: inline-grid; place-items: center; width: 38px; height: 38px; border-radius: 50%;
  color: color-mix(in srgb, #fff 85%, transparent);
  background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.14);
  transition: transform .15s var(--ease), background-color .2s var(--ease), border-color .2s var(--ease), color .2s var(--ease);
}
.socials a:hover { color: #fff; background: var(--cta); border-color: var(--cta); transform: translateY(-2px); text-decoration: none; }
.socials svg { width: 18px; height: 18px; }
.footer__col h4 { font-size: .82rem; text-transform: uppercase; letter-spacing: .1em; color: color-mix(in srgb, #fff 60%, transparent); margin-bottom: var(--s-2); margin-top: var(--s-3); }
.footer__col h4:first-child { margin-top: 0; }
.footer__col a { display: block; color: color-mix(in srgb, #fff 85%, transparent); padding: .2rem 0; font-size: .95rem; }
.footer__col a:hover { color: #fff; }
.footer__col p { color: color-mix(in srgb, #fff 72%, transparent); font-size: .92rem; }
/* Re-assert button styling: the generic `.footer__col a` rule above would otherwise
   strip the button's padding/display and crush the "Free estimate" pill. */
.footer__col a.footer__cta {
  display: inline-flex; width: auto;
  padding: .8rem 1.4rem; margin-top: var(--s-3);
  font-size: 1rem; color: var(--on-cta);
}
.footer__col a.footer__cta:hover { color: var(--on-cta); }
.footer__bottom { display: flex; align-items: center; justify-content: space-between; gap: var(--s-3); flex-wrap: wrap; padding-block: var(--s-4); border-top: 1px solid rgba(255,255,255,.12); }
.footer__bottom .muted { color: color-mix(in srgb, #fff 65%, transparent); }
.footer__legal { display: flex; gap: var(--s-4); flex-wrap: wrap; }
.footer__legal a { color: color-mix(in srgb, #fff 80%, transparent); font-size: .9rem; }
.footer__credit { text-align: center; padding: 0 0 var(--s-4); }
.footer__credit span { font-size: 1rem; color: color-mix(in srgb, #fff 62%, transparent); }
.footer__credit a { font-weight: 700; color: color-mix(in srgb, #fff 82%, transparent); }
.footer__credit a:hover { color: #fff; }
.footer__credit .credit-dot { color: #e8590c; }
.footer__credit .credit-logo { display: inline-block; height: 26px; width: auto; vertical-align: middle; margin-left: .35em; filter: drop-shadow(0 1px 3px rgba(0,0,0,.45)); }

/* ---------- STICKY MOBILE CALL BAR ---------- */
.mobilebar { display: none; }
@media (max-width: 720px) {
  .mobilebar {
    position: fixed; left: 0; right: 0; bottom: 0; z-index: 90;
    display: grid; grid-template-columns: 1fr 1fr; gap: .5rem;
    padding: .5rem .6rem calc(.5rem + env(safe-area-inset-bottom));
    background: color-mix(in srgb, var(--bg) 92%, transparent);
    backdrop-filter: blur(10px); border-top: 1px solid var(--border);
  }
  .mobilebar a { display: inline-flex; align-items: center; justify-content: center; gap: .4rem; font-weight: 700; padding: .85rem; border-radius: var(--radius-pill); }
  .mobilebar__call { background: var(--cta); color: var(--on-cta); }
  .mobilebar__quote { background: var(--surface); color: var(--text); border: 1.5px solid var(--border); }
  .mobilebar a:hover { text-decoration: none; }
  body { padding-bottom: 76px; } /* keep footer clear of the bar */
}

/* ---------- REVEAL ON SCROLL ---------- */
[data-reveal] { opacity: 0; transform: translateY(18px); transition: opacity .6s var(--ease), transform .6s var(--ease); }
[data-reveal].is-in { opacity: 1; transform: none; }
[data-reveal-delay="1"] { transition-delay: .08s; }
[data-reveal-delay="2"] { transition-delay: .16s; }
@media (prefers-reduced-motion: reduce) {
  [data-reveal] { opacity: 1 !important; transform: none !important; transition: none !important; }
}

/* ============================================================================
   RESPONSIVE
   ============================================================================ */
@media (max-width: 960px) {
  .hero__grid { grid-template-columns: 1fr; gap: var(--s-6); }
  .hero__media { order: -1; max-width: 520px; }
  .hero__sub { max-width: none; }
  .two-col { grid-template-columns: 1fr; gap: var(--s-5); }
  .cards, .testimonials, .gallery { grid-template-columns: repeat(2, 1fr); }
  .steps { grid-template-columns: 1fr; gap: var(--s-4); }
  .contact { grid-template-columns: 1fr; }
  .offer { grid-template-columns: 1fr; text-align: center; justify-items: center; }
  .footer__grid { grid-template-columns: 1fr 1fr; }
}

/* Collapse the 5-link nav into the hamburger as soon as the full desktop row
   gets tight, so the header never crowds or wraps. Phone + CTA stay visible
   here (there's room without the nav); they move to the mobile bar at 720px. */
@media (max-width: 1080px) {
  .nav {
    position: fixed; inset: var(--header-h) 0 auto 0; flex-direction: column; gap: 0;
    background: var(--bg); border-bottom: 1px solid var(--border); box-shadow: var(--shadow);
    padding: var(--s-2) var(--s-4) var(--s-4); margin: 0;
    transform: translateY(-12px); opacity: 0; pointer-events: none; visibility: hidden;
    transition: opacity .2s var(--ease), transform .2s var(--ease), visibility .2s;
  }
  .nav.is-open { transform: none; opacity: 1; pointer-events: auto; visibility: visible; }
  .nav a { padding: .8rem 0; border-bottom: 1px solid var(--border); width: 100%; }
  .nav a::after { display: none; }
  .nav-toggle { display: flex; }
}

@media (max-width: 720px) {
  .header__phone, .header__actions .btn--cta { display: none; } /* phone/CTA live in the mobile bar */
  .stats { grid-template-columns: repeat(2, 1fr); }
  .cards, .testimonials, .gallery, .footer__grid, .lead-form__row { grid-template-columns: 1fr; }
  .section { padding-block: var(--s-7); }
}

@media (max-width: 380px) {
  .hero__proof { gap: var(--s-4); }
  .container { padding-inline: var(--s-3); }
}

/* Print: hide interactive chrome */
@media print {
  .site-header, .mobilebar, .theme-toggle, .nav-toggle { display: none !important; }
}
