:root {
  --ink: #16133F;
  --ink-soft: #2A2662;
  --paper: #F4F5FB;
  --white: #FFFFFF;
  --blue: #4C5BFF;
  --magenta: #FF3E8A;
  --gold: #FFC23D;
  --muted: #5B5980;
  --line: #D9DAEC;

  --font: "Bricolage Grotesque", system-ui, sans-serif;
  --gutter: clamp(16px, 5vw, 72px);
  --max: 1240px;
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; scroll-padding-top: 80px; }

body {
  margin: 0;
  font-family: var(--font);
  font-size: 1.0625rem;
  line-height: 1.6;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 { margin: 0; line-height: 1.05; font-variation-settings: "opsz" 96; }
p { margin: 0; }
a { color: inherit; }
img, svg { display: block; }

:focus-visible { outline: 3px solid var(--blue); outline-offset: 3px; border-radius: 4px; }

.skip {
  position: absolute; left: 16px; top: -60px; z-index: 100;
  background: var(--gold); color: var(--ink); padding: 10px 16px; font-weight: 600;
}
.skip:focus { top: 16px; }

/* Nav */
.nav {
  position: fixed; inset: 0 0 auto 0; z-index: 50;
  display: flex; align-items: center; justify-content: space-between;
  padding: 18px var(--gutter);
  color: var(--white);
  transition: background .3s, color .3s, padding .3s;
}
.nav.scrolled {
  background: rgba(244, 245, 251, .92);
  backdrop-filter: blur(12px);
  color: var(--ink);
  padding-block: 12px;
  box-shadow: 0 1px 0 var(--line);
}
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; font-weight: 700; font-size: 1.35rem; letter-spacing: -.02em; }
.brand-mark { width: 26px; height: 26px; fill: var(--gold); }
.nav.scrolled .brand-mark { fill: var(--magenta); }

.nav-links { display: flex; align-items: center; gap: 32px; }
.nav-links a { text-decoration: none; font-weight: 500; }
.nav-links a:not(.nav-cta):hover { text-decoration: underline; text-underline-offset: 6px; text-decoration-thickness: 2px; }
.nav-cta {
  padding: 10px 20px; border-radius: 999px;
  border: 1.5px solid currentColor;
}
.nav-cta:hover { background: var(--gold); border-color: var(--gold); color: var(--ink); }
.nav-toggle { display: none; }

/* Hero */
.hero {
  position: relative; overflow: hidden;
  min-height: min(100svh, 1000px);
  display: flex; align-items: flex-end;
  background: var(--ink);
  color: var(--white);
  padding: 140px var(--gutter) clamp(56px, 10vh, 112px);
}
.hero-canvas { position: absolute; inset: 0; width: 100%; height: 100%; }
.hero-inner { position: relative; max-width: var(--max); width: 100%; margin: 0 auto; }
.hero-title {
  font-size: clamp(2.9rem, 8.4vw, 7.6rem);
  font-weight: 750;
  font-variation-settings: "opsz" 96, "wdth" 80;
  letter-spacing: -.025em;
  line-height: .95;
  max-width: 13ch;
}
.hero-lede {
  margin-top: 28px; max-width: 46ch;
  font-size: clamp(1.1rem, 1.6vw, 1.3rem);
  color: #D6D4F5;
}
.hero-actions { margin-top: 40px; display: flex; flex-wrap: wrap; gap: 14px; }

.btn {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 16px 28px; border-radius: 999px;
  font: 600 1.05rem var(--font);
  text-decoration: none; cursor: pointer; border: 0;
  transition: transform .15s, background .2s, color .2s;
}
.btn:active { transform: scale(.97); }
.btn-gold { background: var(--gold); color: var(--ink); }
.btn-gold:hover { background: var(--white); }
.btn-ghost { color: var(--white); box-shadow: inset 0 0 0 1.5px rgba(255,255,255,.45); }
.btn-ghost:hover { box-shadow: inset 0 0 0 1.5px var(--white); }
.btn-ink { background: var(--ink); color: var(--white); }
.btn-ink:hover { background: var(--blue); }
.btn[disabled] { opacity: .6; cursor: progress; }

/* Intro */
.intro { padding: clamp(80px, 12vw, 160px) var(--gutter); }
.intro p {
  max-width: 30ch; margin: 0 auto;
  font-size: clamp(1.6rem, 3.4vw, 2.8rem);
  font-weight: 500; line-height: 1.2; letter-spacing: -.02em;
  font-variation-settings: "opsz" 60;
}
.intro em {
  font-style: normal;
  background: linear-gradient(var(--gold), var(--gold)) no-repeat 0 88% / var(--hl, 100%) 36%;
}

/* Section heads */
.section-head {
  max-width: var(--max); margin: 0 auto 56px;
  display: grid; grid-template-columns: 1fr 1fr; gap: 24px 64px; align-items: end;
}
.section-head h2 { font-size: clamp(2.4rem, 5.6vw, 4.6rem); font-weight: 700; letter-spacing: -.03em; font-variation-settings: "opsz" 96, "wdth" 85; }
.section-head p { color: var(--muted); max-width: 44ch; }

/* Services */
.services { padding: 0 var(--gutter) clamp(80px, 12vw, 160px); }
.service-list {
  list-style: none; margin: 0 auto; padding: 0; max-width: var(--max);
  display: grid; grid-template-columns: repeat(3, 1fr);
  border-top: 2px solid var(--ink);
}
.service {
  padding: 32px 32px 40px 0;
  border-bottom: 1px solid var(--line);
  display: flex; flex-direction: column; gap: 12px;
}
.service:not(:nth-child(3n+1)) { padding-left: 32px; border-left: 1px solid var(--line); }
.service h3 { font-size: 1.6rem; font-weight: 650; letter-spacing: -.015em; }
.service p { color: var(--muted); max-width: 36ch; }
.service-tags { margin-top: auto; padding-top: 12px; font-size: .9rem; font-weight: 500; color: var(--blue); }

/* Process */
.process {
  background: var(--white);
  padding: clamp(80px, 12vw, 160px) var(--gutter);
}
.steps {
  list-style: none; margin: 0 auto; padding: 0; max-width: var(--max);
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 40px;
  counter-reset: step;
}
.steps li { counter-increment: step; }
.steps li::before {
  content: counter(step);
  display: block;
  font-size: clamp(4rem, 8vw, 6.5rem); font-weight: 800; line-height: 1;
  font-variation-settings: "opsz" 96, "wdth" 75;
  color: transparent; -webkit-text-stroke: 1.5px var(--ink);
  margin-bottom: 20px;
}
.steps li::before { transition: color .6s cubic-bezier(.2,.7,.2,1), -webkit-text-stroke-color .6s; }
.steps li.on::before { color: var(--ink); }
.steps li.on:last-child::before { color: var(--magenta); -webkit-text-stroke-color: var(--magenta); }
.steps-track {
  max-width: var(--max); margin: 0 auto 40px; height: 2px;
  background: var(--line); border-radius: 2px; overflow: hidden;
}
.steps-fill {
  height: 100%; width: 100%; transform-origin: left; transform: scaleX(0);
  background: linear-gradient(90deg, var(--blue), var(--magenta) 70%, var(--gold));
}
.no-motion .steps-fill, html:not(.js) .steps-fill { transform: none; }
html:not(.js) .steps li::before, .no-motion .steps li::before { color: var(--ink); }
.steps h3 { font-size: 1.5rem; font-weight: 650; margin-bottom: 10px; }
.steps p { color: var(--muted); }

/* About */
.about {
  max-width: calc(var(--max) + var(--gutter) * 2); margin: 0 auto;
  padding: clamp(80px, 12vw, 160px) var(--gutter);
  display: grid; grid-template-columns: 1.1fr 1fr; gap: 40px 80px;
}
.about h2 { font-size: clamp(2rem, 4.2vw, 3.4rem); font-weight: 700; letter-spacing: -.025em; font-variation-settings: "opsz" 96, "wdth" 85; }
.about-body { display: grid; gap: 20px; font-size: 1.15rem; max-width: 52ch; align-content: start; padding-top: 8px; }

/* Contact */
.contact {
  background: var(--ink); color: var(--white);
  padding: clamp(80px, 12vw, 140px) var(--gutter);
  display: grid; grid-template-columns: 1fr 1.25fr; gap: 56px 96px;
}
.contact > * { min-width: 0; }
.contact-info h2 { font-size: clamp(2.4rem, 5vw, 4.2rem); font-weight: 700; letter-spacing: -.03em; font-variation-settings: "opsz" 96, "wdth" 80; }
.contact-info > p { margin-top: 20px; color: #D6D4F5; max-width: 40ch; }
.contact-details { margin: 48px 0 0; display: grid; gap: 24px; }
.contact-details dt { font-size: .9rem; color: var(--gold); font-weight: 600; margin-bottom: 4px; }
.contact-details dd { margin: 0; font-size: 1.1rem; }
.contact-details a { text-underline-offset: 4px; }

.contact-form {
  background: var(--paper); color: var(--ink);
  border-radius: 28px; padding: clamp(24px, 4vw, 48px);
  display: grid; gap: 22px; align-content: start;
}
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; }
.field { display: grid; gap: 8px; min-width: 0; border: 0; padding: 0; margin: 0; }
.field label, .field legend { font-weight: 600; font-size: .95rem; padding: 0; margin-bottom: 8px; }
.field > label { margin-bottom: 0; }
input, select, textarea {
  width: 100%; font: 400 1rem var(--font); color: var(--ink);
  background: var(--white);
  border: 1.5px solid var(--line); border-radius: 12px;
  padding: 13px 14px;
  transition: border-color .15s;
}
textarea { resize: vertical; min-height: 130px; }
input:hover, select:hover, textarea:hover { border-color: #B4B5D6; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--blue); box-shadow: 0 0 0 3px rgba(76, 91, 255, .2); }
::placeholder { color: #9897B5; }

.chips { display: flex; flex-wrap: wrap; gap: 10px; }
.chips label { position: relative; margin: 0; font-weight: 500; }
.chips input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.chips span {
  display: inline-block; padding: 9px 16px; border-radius: 999px;
  border: 1.5px solid var(--line); background: var(--white); cursor: pointer;
  transition: background .15s, border-color .15s, color .15s;
}
.chips input:checked + span { background: var(--ink); border-color: var(--ink); color: var(--white); }
.chips input:focus-visible + span { outline: 3px solid var(--blue); outline-offset: 2px; }

.contact-form .btn { justify-self: start; }
.form-status:empty { display: none; }
.form-status { font-weight: 500; }
.form-status.error { color: #C4123F; }
.hp { position: absolute; left: -9999px; }

/* Footer */
.footer {
  padding: 40px var(--gutter);
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 20px;
  font-size: .95rem; color: var(--muted);
}
.footer-brand { display: flex; align-items: center; gap: 8px; font-weight: 700; color: var(--ink); font-size: 1.15rem; }
.footer-brand .brand-mark { width: 20px; height: 20px; fill: var(--magenta); }
.footer nav { display: flex; gap: 24px; }
.footer nav a { text-decoration: none; }
.footer nav a:hover { color: var(--ink); text-decoration: underline; }

/* Thanks page */
.thanks {
  min-height: 100svh; display: grid; place-items: center; text-align: center;
  background: var(--ink); color: var(--white); padding: 40px var(--gutter);
}
.thanks .brand-mark { width: 56px; height: 56px; margin: 0 auto 32px; }
.thanks h1 { font-size: clamp(2.4rem, 6vw, 4.4rem); font-weight: 700; letter-spacing: -.03em; font-variation-settings: "opsz" 96, "wdth" 85; }
.thanks p { margin: 20px auto 36px; color: #D6D4F5; max-width: 40ch; font-size: 1.15rem; }

/* Responsive */
@media (max-width: 960px) {
  .service-list { grid-template-columns: 1fr 1fr; }
  .service:not(:nth-child(3n+1)) { padding-left: 0; border-left: 0; }
  .service:nth-child(even) { padding-left: 28px; border-left: 1px solid var(--line); }
  .steps { grid-template-columns: 1fr 1fr; gap: 48px 32px; }
  .about, .contact { grid-template-columns: 1fr; }
  .section-head { grid-template-columns: 1fr; }
}

@media (max-width: 720px) {
  .nav-toggle {
    display: block; font: 600 1rem var(--font); color: inherit;
    background: none; border: 1.5px solid currentColor; border-radius: 999px; padding: 8px 18px; cursor: pointer;
  }
  .nav-links {
    position: absolute; top: 100%; left: 16px; right: 16px;
    flex-direction: column; align-items: stretch; gap: 4px;
    background: var(--white); color: var(--ink);
    border-radius: 20px; padding: 12px;
    box-shadow: 0 20px 50px rgba(22, 19, 63, .25);
    display: none;
  }
  .nav-links.open { display: flex; }
  .nav-links a { padding: 12px 14px; }
  .nav-cta { text-align: center; margin-top: 6px; background: var(--ink); color: var(--white); border-color: var(--ink); }

  .service-list { grid-template-columns: 1fr; }
  .service:nth-child(even) { padding-left: 0; border-left: 0; }
  .service { padding-right: 0; }
  .steps { grid-template-columns: 1fr; }
  .field-row { grid-template-columns: 1fr; }
  .contact-form .btn { justify-self: stretch; }
  .footer { flex-direction: column; align-items: flex-start; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; }
}

/* ---------- Motion layer ---------- */

/* Smooth scroll (Lenis) takes over from native smooth scrolling */
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }
.lenis.lenis-stopped { overflow: hidden; }

/* Hide the hero until the intro sequence plays (only when JS runs) */
.js .hero-inner, .js .nav { visibility: hidden; }

/* Split-word reveals */
.w { display: inline-block; overflow: hidden; vertical-align: top; padding-bottom: .12em; margin-bottom: -.12em; }
.wi { display: inline-block; will-change: transform; }

/* Hero layout additions */
.hero-inner { display: grid; }
.hero-title, .hero-lede, .hero-actions { grid-column: 1; }
.badge {
  position: absolute; right: 0; bottom: 0;
  width: 132px; height: 132px; color: var(--white);
}
.badge svg { width: 100%; height: 100%; overflow: visible; }
.badge text { font: 600 10.5px var(--font); letter-spacing: .14em; fill: currentColor; }
.badge-star { fill: var(--gold); transform-origin: 60px 60px; transition: transform .6s cubic-bezier(.2,.7,.2,1); }
.badge:hover .badge-star { transform: rotate(90deg) scale(1.25); }
.badge text { animation: spin 22s linear infinite; transform-origin: 60px 60px; }
@keyframes spin { to { transform: rotate(360deg); } }
.hero { cursor: crosshair; }
.hero a, .hero button { cursor: pointer; }

/* Marquee */
.marquee {
  overflow: hidden; background: var(--ink); color: var(--white);
  padding: clamp(18px, 2.4vw, 32px) 0;
  border-top: 1px solid rgba(255,255,255,.08);
}
.marquee-track {
  display: flex; align-items: center; gap: clamp(20px, 3vw, 44px); width: max-content;
  font-size: clamp(2.6rem, 7vw, 6.4rem); font-weight: 750; line-height: 1;
  font-variation-settings: "opsz" 96, "wdth" 78; letter-spacing: -.02em;
  white-space: nowrap; will-change: transform;
  padding-right: clamp(20px, 3vw, 44px);
}
.marquee-track .outline { color: transparent; -webkit-text-stroke: 1.5px rgba(255,255,255,.75); }
.marquee-track i { font-style: normal; color: var(--gold); font-size: .5em; }
.marquee-track i:nth-of-type(3n+2) { color: var(--magenta); }
.marquee-track i:nth-of-type(3n) { color: var(--blue); }

/* Services spotlight */
.service { position: relative; isolation: isolate; }
.service::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: radial-gradient(320px circle at var(--mx, 50%) var(--my, 50%), rgba(76, 91, 255, .13), rgba(255, 62, 138, .06) 45%, transparent 70%);
  opacity: 0; transition: opacity .4s;
}
.service:hover::before { opacity: 1; }
.service h3 { transition: transform .5s cubic-bezier(.2,.7,.2,1), color .3s; }
.service:hover h3 { transform: translateX(6px); color: var(--blue); }

/* Giant footer wordmark */
.footer-word {
  overflow: hidden; text-align: center;
  font-size: clamp(5rem, 22vw, 22rem); font-weight: 800; line-height: .82;
  font-variation-settings: "opsz" 96, "wdth" 75; letter-spacing: -.01em;
  color: var(--ink); padding: clamp(48px, 8vw, 120px) 8px 0;
  user-select: none;
}
.footer-word .ch { display: inline-block; will-change: transform; }
.footer-word .ch:nth-child(3n+1):hover { color: var(--magenta); }
.footer-word .ch:nth-child(3n+2):hover { color: var(--blue); }
.footer-word .ch:nth-child(3n):hover { color: var(--gold); }
.footer-word .ch { transition: color .3s; }

/* Cursor ring (fine pointers only) */
.cursor {
  position: fixed; left: 0; top: 0; z-index: 200; pointer-events: none;
  width: 36px; height: 36px; margin: -18px 0 0 -18px; border-radius: 50%;
  border: 1.5px solid #fff; mix-blend-mode: difference;
  opacity: 0; transition: width .35s, height .35s, margin .35s, background .35s, opacity .3s;
}
.cursor.on { opacity: 1; }
.cursor.hover { width: 72px; height: 72px; margin: -36px 0 0 -36px; background: #fff; }
@media (pointer: coarse) { .cursor { display: none; } }

/* Nav hides while scrolling down */
.nav { transition: background .3s, color .3s, padding .3s, transform .5s cubic-bezier(.2,.7,.2,1); }
.nav.hidden { transform: translateY(-110%); }

@media (max-width: 900px) {
  .badge { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  .badge text { animation: none; }
}
