/* The v2 design system, shared by every page. Extracted from the
   homepage so the whole estate stays one coherent thing. */

  :root {
    --paper: #F5F3F0; --panel: #FFFFFF; --sunk: #ECE7E0;
    --ink: #16191F; --soft: #464C57; --muted: #72798A;
    --rule: #E2DDD6; --navy: #1E3A5F; --navy-deep: #14293F;
    --gold: #C8A24A;
    --teal: #1E3A5F; --on-teal: #FFFFFF;
    --serif: "Fraunces", Georgia, serif;
    --sans: "Inter", -apple-system, sans-serif;
  }
  * { margin: 0; box-sizing: border-box; }
  html { scroll-behavior: smooth; }
  @media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *::before, *::after { animation: none !important; transition: none !important; }
  }
  body { background: var(--paper); color: var(--ink); font-family: var(--sans); line-height: 1.6; }
  .wrap { max-width: 72rem; margin: 0 auto; padding: 0 1.4rem; }
  h1, h2, h3 { font-family: var(--serif); font-weight: 420; line-height: 1.12; letter-spacing: -0.01em; text-wrap: balance; }
  a { color: var(--navy); }

  /* ---------- masthead over the hero ---------- */
  .masthead { position: static; padding: 1.3rem 0; background: #F5F3F0; }
  .masthead.on-paper .brand { color: var(--ink); }
  .masthead.on-paper .brand svg { fill: var(--navy); }
  .masthead.on-paper .nav a { color: var(--soft); }
  .masthead.on-paper .nav a:hover { color: var(--ink); }
  .masthead .wrap { max-width: 70rem; display: flex; align-items: center; justify-content: space-between; min-height: 46px; }
  .brand { line-height: 1; display: flex; align-items: center; gap: .6rem; color: #fff; text-decoration: none; font-weight: 650; font-size: 1.05rem; letter-spacing: .01em; }
  .brand svg { width: 22px; height: 27px; fill: #fff; }
  .nav { display: flex; align-items: center; gap: 1.6rem; }
  .nav a { color: rgba(255,255,255,.88); text-decoration: none; font-size: .92rem; font-weight: 550; white-space: nowrap; }
  .nav a:hover { color: #fff; }
  .btn { display: inline-block; padding: .78rem 1.5rem; border-radius: 999px; text-decoration: none; font-weight: 650; font-size: .95rem; transition: transform .18s ease, box-shadow .18s ease, background .18s ease; }
  .btn-solid, .nav a.btn-solid { background: #fff; color: var(--ink); }
  .btn-solid:hover { transform: translateY(-2px); box-shadow: 0 12px 28px rgba(0,0,0,.25); }
  .btn-navy, .nav a.btn-navy, .masthead.on-paper .nav a.btn-navy { background: var(--navy); color: #fff; }
  .btn-navy:hover { transform: translateY(-2px); box-shadow: 0 14px 30px rgba(30,58,95,.35); }
  .btn-line { border: 1.5px solid rgba(255,255,255,.55); color: #fff; }
  .btn-line:hover { border-color: #fff; background: rgba(255,255,255,.08); }
  .nav-links { display: contents; }
  .nav-toggle { display: none; background: none; border: 0; padding: 8px 2px 8px 8px; cursor: pointer; }
  .nav-toggle span { display: block; width: 20px; height: 2px; background: var(--ink); margin: 4px 0; border-radius: 2px; transition: transform .18s ease, opacity .18s ease; }
  .masthead.menu-open .nav-toggle span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
  .masthead.menu-open .nav-toggle span:nth-child(2) { opacity: 0; }
  .masthead.menu-open .nav-toggle span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }
  @media (max-width: 720px) {
    .hide-sm { display: none; }
    .masthead { position: relative; }
    .masthead .wrap { padding-left: 1.1rem; padding-right: 1.1rem; }
    .masthead .brand { white-space: nowrap; font-size: .98rem; }
    .nav-toggle { display: block; }
    .nav { gap: .7rem; }
    .nav a.btn-navy { padding: .55rem 1rem; font-size: .88rem; }
    .masthead.menu-open .nav-links { display: flex; flex-direction: column; align-items: stretch;
      position: absolute; top: 100%; left: 0; right: 0; z-index: 60;
      background: var(--paper); border-bottom: 1px solid var(--rule);
      box-shadow: 0 18px 32px rgba(20,26,31,.12); padding: .4rem 1.4rem 1rem; }
    .masthead.menu-open .nav-links a.hide-sm { display: block; padding: .85rem .2rem;
      font-size: 1rem; border-bottom: 1px solid var(--rule); color: var(--ink); }
    .masthead.menu-open .nav-links a.hide-sm:last-child { border-bottom: 0; }
  }

  /* ---------- HERO-03: split editorial on paper ---------- */
  .hero-split { position: relative; padding: 8.5rem 0 4.5rem; background:
    radial-gradient(60rem 40rem at 85% -20%, #E6ECF3 0%, transparent 60%), var(--paper); overflow: hidden; }
  .hero-split .wrap { display: grid; gap: 3rem; align-items: center; }
  @media (min-width: 960px) { .hero-split .wrap { grid-template-columns: 1.05fr 1fr; } }
  .hero-copy .eyebrow2 { color: var(--navy); font-size: .82rem; font-weight: 700; letter-spacing: .2em; text-transform: uppercase; }
  .hero-copy h1 { font-size: clamp(2.6rem, 5.4vw, 4.2rem); margin-top: 1rem; }
  .hero-copy h1 em { font-style: italic; color: var(--navy); }
  .hero-copy .lede2 { color: var(--soft); font-size: clamp(1rem, 1.5vw, 1.15rem); max-width: 34rem; margin-top: 1.3rem; }
  .hero-copy .hero-actions { justify-content: flex-start; margin-top: 2rem; }
  .hero-copy .hero-note2 { color: var(--muted); font-size: .85rem; margin-top: 1.1rem; }
  .hero-device .device-cap { text-align: center; }

  /* ---------- old cinematic kept for reference ---------- */
  .hero { position: relative; min-height: 92vh; display: grid; place-items: center; overflow: hidden; text-align: center; }
  .hero-media { position: absolute; inset: 0; }
  .hero-media img { width: 100%; height: 100%; object-fit: cover; animation: breathe 22s ease-in-out infinite alternate; transform-origin: 50% 40%; }
  @keyframes breathe { from { transform: scale(1); } to { transform: scale(1.08); } }
  .hero-media::after { content: ""; position: absolute; inset: 0;
    background: linear-gradient(180deg, rgba(12,17,26,.55) 0%, rgba(12,17,26,.35) 45%, rgba(12,17,26,.72) 100%); }
  .hero-inner { position: relative; z-index: 2; padding: 7rem 1.4rem 5rem; max-width: 56rem; }
  .hero .eyebrow { color: rgba(255,255,255,.75); font-size: .85rem; font-weight: 650; letter-spacing: .22em; text-transform: uppercase; }
  .hero h1 { color: #fff; font-size: clamp(2.6rem, 6.4vw, 4.6rem); margin-top: 1.1rem; text-shadow: 0 2px 30px rgba(0,0,0,.35); }
  .hero h1 em { font-style: italic; color: var(--gold); }
  .hero .lede { color: rgba(255,255,255,.88); font-size: clamp(1.02rem, 1.6vw, 1.2rem); max-width: 40rem; margin: 1.4rem auto 0; }
  .hero-actions { display: flex; gap: .9rem; justify-content: center; flex-wrap: wrap; margin-top: 2.2rem; }
  .scroll-cue { position: absolute; left: 50%; bottom: 2rem; transform: translateX(-50%); z-index: 2;
    width: 26px; height: 42px; border: 2px solid rgba(255,255,255,.5); border-radius: 14px; }
  .scroll-cue::after { content: ""; position: absolute; left: 50%; top: 8px; width: 4px; height: 8px; margin-left: -2px;
    border-radius: 2px; background: rgba(255,255,255,.8); animation: cue 1.8s ease-in-out infinite; }
  @keyframes cue { 0%,100% { transform: translateY(0); opacity: 1; } 60% { transform: translateY(12px); opacity: 0; } }

  /* ---------- SCR-04: measured numbers, counted up ---------- */
  .proof { background: var(--navy-deep); color: #fff; padding: 3.2rem 0; }
  .proof .wrap { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 2rem; text-align: center; }
  .stat b { display: block; font-family: var(--serif); font-size: clamp(2.4rem, 4.5vw, 3.4rem); font-weight: 480; font-variant-numeric: tabular-nums; }
  .stat b span { color: var(--gold); }
  .stat small { color: rgba(255,255,255,.72); font-size: .9rem; line-height: 1.45; display: block; max-width: 22ch; margin: .4rem auto 0; }

  section { padding: 5.5rem 0; }
  .kicker { color: var(--muted); font-size: .82rem; font-weight: 700; letter-spacing: .2em; text-transform: uppercase; }
  .sec-title { font-size: clamp(1.9rem, 4vw, 2.9rem); margin-top: .7rem; max-width: 24ch; }
  .sec-lede { color: var(--soft); max-width: 60ch; margin-top: 1rem; font-size: 1.04rem; }

  /* ---------- IMG-02: hover editorial work grid ---------- */
  .work-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 1.2rem; margin-top: 2.6rem; }
  .work-card { position: relative; border-radius: 14px; overflow: hidden; aspect-ratio: 4 / 5; display: block; text-decoration: none;
    box-shadow: 0 4px 14px rgba(22,25,31,.08); transition: box-shadow .25s ease; }
  .work-card img { width: 100%; height: 100%; object-fit: cover; transition: transform .8s cubic-bezier(.2,.7,.2,1); }
  .work-card:hover img { transform: scale(1.05); }
  .work-card:hover { box-shadow: 0 24px 48px rgba(22,25,31,.22); }
  .work-card figcaption { position: absolute; inset: auto 0 0 0; padding: 2.4rem 1.1rem 1rem;
    background: linear-gradient(180deg, transparent, rgba(12,17,26,.78)); color: #fff; }
  .work-card figcaption b { font-family: var(--serif); font-weight: 480; font-size: 1.12rem; display: block; }
  .work-card figcaption span { font-size: .82rem; color: rgba(255,255,255,.8); }

  /* ---------- IMG-01: before / after drag slider ---------- */
  .ba-band { background: var(--panel); border-top: 1px solid var(--rule); border-bottom: 1px solid var(--rule); }
  .ba { position: relative; max-width: 54rem; margin: 2.6rem auto 0; border-radius: 16px; overflow: hidden;
    box-shadow: 0 24px 60px rgba(22,25,31,.16); aspect-ratio: 16 / 10; user-select: none; touch-action: none; }
  .ba img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: top; pointer-events: none; }
  .ba .after-img { clip-path: inset(0 0 0 50%); }
  .ba-handle { position: absolute; top: 0; bottom: 0; left: 50%; width: 3px; background: #fff; box-shadow: 0 0 0 1px rgba(0,0,0,.12); }
  .ba-handle::after { content: "◂ ▸"; position: absolute; top: 50%; left: 50%; transform: translate(-50%,-50%);
    background: #fff; color: var(--ink); font-size: .8rem; font-weight: 700; letter-spacing: .1em;
    padding: .55rem .8rem; border-radius: 999px; box-shadow: 0 6px 18px rgba(0,0,0,.25); white-space: nowrap; }
  .ba-tag { position: absolute; top: 1rem; font-size: .78rem; font-weight: 700; letter-spacing: .08em;
    padding: .4rem .85rem; border-radius: 999px; color: #fff; }
  .ba-tag.before { left: 1rem; background: rgba(12,17,26,.75); }
  .ba-tag.after { right: 1rem; background: var(--navy); }

  /* ---------- services ---------- */
  .svc-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 1.2rem; margin-top: 2.6rem; }
  .svc { background: var(--panel); border: 1px solid var(--rule); border-radius: 14px; padding: 1.6rem 1.5rem;
    transition: transform .2s ease, box-shadow .2s ease; }
  .svc:hover { transform: translateY(-4px); box-shadow: 0 18px 40px rgba(22,25,31,.12); }
  .svc h3 { font-size: 1.35rem; }
  .svc p { color: var(--soft); font-size: .95rem; margin-top: .6rem; }
  .svc a { font-weight: 650; font-size: .9rem; text-decoration: none; display: inline-block; margin-top: 1rem; position: relative; }
  .svc a::after { content: ""; position: absolute; left: 0; bottom: -3px; height: 2px; width: 0; background: var(--navy); transition: width .25s ease; }
  .svc:hover a::after { width: 100%; }

  /* ---------- process ---------- */
  .steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 1.4rem; margin-top: 2.6rem; counter-reset: step; }
  .step { border-top: 3px solid var(--navy); padding-top: 1.2rem; }
  .step::before { counter-increment: step; content: "0" counter(step); font-family: var(--serif); font-size: 2rem; color: var(--gold); display: block; }
  .step h3 { font-size: 1.25rem; margin-top: .3rem; }
  .step p { color: var(--soft); font-size: .95rem; margin-top: .5rem; }

  /* ---------- audit CTA band ---------- */
  .cta-band { background: var(--navy); color: #fff; text-align: center; }
  .cta-band h2 { font-size: clamp(2rem, 4.4vw, 3rem); color: #fff; max-width: 26ch; margin: 0 auto; }
  .cta-band p { color: rgba(255,255,255,.82); max-width: 52ch; margin: 1.1rem auto 0; }
  .cta-band .btn { margin-top: 2rem; }
  .cta-note { font-size: .85rem; color: rgba(255,255,255,.6); margin-top: 1rem; }

  /* ---------- footer ---------- */
  footer { background: var(--navy-deep); color: rgba(255,255,255,.75); padding: 3rem 0 2.2rem; font-size: .9rem; }
  footer .wrap { display: flex; flex-wrap: wrap; gap: 2rem; justify-content: space-between; align-items: flex-start; }
  footer a { color: rgba(255,255,255,.85); text-decoration: none; }
  footer a:hover { color: #fff; }
  .foot-links { display: flex; gap: 1.4rem; flex-wrap: wrap; }

  /* ---------- device frames for the scroll videos ---------- */
  .devices { display: grid; grid-template-columns: 1fr; gap: 2.6rem; margin-top: 3rem; align-items: end; }
  @media (min-width: 880px) { .devices { grid-template-columns: 1.7fr 1fr; } }
  .laptop { position: relative; }
  .laptop .screen { border: 10px solid #22262e; border-bottom-width: 22px; border-radius: 18px 18px 6px 6px;
    overflow: hidden; background: #000; box-shadow: 0 34px 70px rgba(22,25,31,.28); }
  .laptop .screen video { display: block; width: 100%; }
  .laptop .base { height: 14px; background: linear-gradient(#d7d3cc, #b9b4ab); border-radius: 0 0 16px 16px;
    margin: 0 -5%; box-shadow: 0 8px 18px rgba(22,25,31,.18); }
  .phone { justify-self: center; width: min(270px, 70vw); border: 9px solid #22262e; border-radius: 34px;
    overflow: hidden; background: #000; position: relative; box-shadow: 0 30px 60px rgba(22,25,31,.3); }
  .phone::before { content: ""; position: absolute; top: 8px; left: 50%; transform: translateX(-50%);
    width: 84px; height: 18px; background: #22262e; border-radius: 999px; z-index: 2; }
  .phone video { display: block; width: 100%; }
  .device-cap { text-align: center; color: var(--muted); font-size: .85rem; margin-top: .9rem; }
  .devices-second { margin-top: 2.6rem; max-width: 46rem; }

  /* ---------- SCR-01: stagger fade-up ---------- */
  .reveal { opacity: 0; transform: translateY(22px); transition: opacity .7s ease, transform .7s ease; }
  .reveal.in { opacity: 1; transform: none; }
  @media (prefers-reduced-motion: reduce) { .reveal { opacity: 1; transform: none; } }
