/* ============================================================
   SILKERN — design system v1
   Black silk. Ivory ink. One gold thread.
   The accent is for actions and accents only — never decoration.
   ============================================================ */

:root {
  /* -- palette: black silk ---------------------------------- */
  --bg: #0a0a0b;
  --bg-2: #101013;
  --bg-3: #17171b;
  --ink: #efeae3;
  --ink-2: rgba(239, 234, 227, 0.64);
  --ink-3: rgba(239, 234, 227, 0.55);
  --line: rgba(239, 234, 227, 0.1);
  --line-2: rgba(239, 234, 227, 0.24);
  --accent: #c8a96e;
  --accent-2: #e6d3a7;
  --accent-ink: #16130c;

  /* -- type -------------------------------------------------- */
  --font-display: 'Prata', 'Georgia', serif;
  --font-ui: 'Inter', -apple-system, 'Helvetica Neue', sans-serif;
  --fs-hero: clamp(3.2rem, 8.5vw, 7rem);
  --fs-1: clamp(2.4rem, 5.5vw, 4.2rem);
  --fs-2: clamp(1.7rem, 3.4vw, 2.6rem);
  --fs-3: clamp(1.25rem, 2vw, 1.5rem);
  --fs-lead: clamp(1.06rem, 1.4vw, 1.3rem);
  --fs-body: 1rem;
  --fs-small: 0.875rem;
  --fs-label: 0.72rem;

  /* -- space, shape, depth ----------------------------------- */
  --s-1: 0.25rem;
  --s-2: 0.5rem;
  --s-3: 0.75rem;
  --s-4: 1rem;
  --s-5: 1.5rem;
  --s-6: 2rem;
  --s-7: 3rem;
  --s-8: 4rem;
  --s-9: 6rem;
  --s-10: 9rem;
  --section-pad: clamp(5rem, 14vh, 9rem);
  --r-s: 10px;
  --r-m: 20px;
  --r-pill: 999px;
  --shadow-1: 0 10px 30px rgba(0, 0, 0, 0.35);
  --shadow-2: 0 24px 60px rgba(0, 0, 0, 0.5);

  /* -- motion ------------------------------------------------ */
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-inout: cubic-bezier(0.65, 0, 0.35, 1);
  --t-1: 0.3s;
  --t-2: 0.7s;
  --t-3: 1.2s;

  --container: 1440px;
  --gutter: clamp(1.25rem, 4vw, 3rem);
}

/* -- reset & base --------------------------------------------- */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

/* author display rules must never defeat the hidden attribute */
[hidden] {
  display: none !important;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: fixed;
  top: 10px;
  left: 10px;
  z-index: 2000;
  padding: 0.6em 1.2em;
  background: var(--accent);
  color: var(--accent-ink);
  border-radius: var(--r-pill);
  font-weight: 600;
  transform: translateY(-300%);
}

.skip-link:focus-visible {
  transform: translateY(0);
}

/* anchors must not land under the fixed nav */
[id] {
  scroll-margin-top: 96px;
}

html {
  scroll-behavior: smooth;
}

html.lenis,
html.lenis body {
  height: auto;
}

.lenis.lenis-smooth {
  scroll-behavior: auto;
}

body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-ui);
  font-size: var(--fs-body);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

::selection {
  background: var(--accent);
  color: var(--accent-ink);
}

img,
svg,
video,
canvas {
  display: block;
  max-width: 100%;
}

/* -- typography ------------------------------------------------ */
h1,
h2,
h3,
.display,
.hero-title {
  font-family: var(--font-display);
  font-weight: 400;
  line-height: 1.12;
  letter-spacing: -0.01em;
}

h1 {
  font-size: var(--fs-1);
}

h2 {
  font-size: var(--fs-2);
}

h3 {
  font-size: var(--fs-3);
  line-height: 1.3;
}

.hero-title {
  font-size: var(--fs-hero);
  line-height: 1.04;
}

.lead {
  font-size: var(--fs-lead);
  line-height: 1.6;
  color: var(--ink-2);
  max-width: 38em;
}

.muted {
  color: var(--ink-2);
}

.small {
  font-size: var(--fs-small);
  color: var(--ink-3);
}

.eyebrow {
  display: inline-block;
  font-size: var(--fs-label);
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: var(--s-4);
}

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

.link {
  background-image: linear-gradient(currentColor, currentColor);
  background-repeat: no-repeat;
  background-position: 0 100%;
  background-size: 0% 1px;
  transition: background-size var(--t-2) var(--ease-out);
  padding-bottom: 2px;
}

.link:hover,
.link:focus-visible {
  background-size: 100% 1px;
}

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

/* -- layout ----------------------------------------------------- */
.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

/* visual blocks may breathe wider than reading text */
.container-wide {
  max-width: min(1760px, 96vw);
}

.section {
  padding-block: var(--section-pad);
}

.hairline {
  border: 0;
  border-top: 1px solid var(--line);
}

/* -- navigation (glass on scroll) -------------------------------- */
.nav {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 1000;
  transition: background var(--t-2) var(--ease-out), border-color var(--t-2) var(--ease-out), backdrop-filter var(--t-2) var(--ease-out);
  border-bottom: 1px solid transparent;
}

.nav.is-scrolled {
  background: rgba(10, 10, 11, 0.55);
  -webkit-backdrop-filter: blur(16px) saturate(1.3);
  backdrop-filter: blur(16px) saturate(1.3);
  border-bottom-color: var(--line);
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-6);
  padding-block: var(--s-4);
}

.wordmark {
  font-family: var(--font-display);
  font-size: 1.35rem;
  letter-spacing: 0.02em;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: var(--s-6);
  list-style: none;
  font-size: var(--fs-small);
  color: var(--ink-2);
}

.nav-links a.link[aria-current='page'] {
  color: var(--ink);
}

.nav-burger {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 6px;
  width: 44px;
  height: 44px;
  padding: 10px;
  background: transparent;
  border: 1px solid var(--line-2);
  border-radius: var(--r-pill);
  cursor: pointer;
}

.nav-burger span {
  display: block;
  height: 1.5px;
  background: var(--ink);
  transition: transform var(--t-1) var(--ease-out), opacity var(--t-1) var(--ease-out);
}

.menu-open .nav-burger span:first-child {
  transform: translateY(3.75px) rotate(45deg);
}

.menu-open .nav-burger span:last-child {
  transform: translateY(-3.75px) rotate(-45deg);
}

@media (max-width: 800px) {
  .nav-links li:not(.nav-cta) {
    display: none;
  }

  .nav-burger {
    display: flex;
  }
}

@media (max-width: 420px) {
  .nav-inner,
  .nav-links {
    gap: var(--s-3);
  }

  .wordmark {
    font-size: 1.15rem;
  }

  .nav .btn {
    padding: 0.8em 1.2em;
  }
}

body.menu-open {
  overflow: hidden;
}

.menu-overlay {
  position: fixed;
  inset: 0;
  z-index: 999;
  display: grid;
  place-items: center;
  background: rgba(10, 10, 11, 0.9);
  -webkit-backdrop-filter: blur(20px);
  backdrop-filter: blur(20px);
  opacity: 0;
  visibility: hidden;
  transition: opacity var(--t-2) var(--ease-out), visibility 0s linear var(--t-2);
}

.menu-open .menu-overlay {
  opacity: 1;
  visibility: visible;
  transition: opacity var(--t-2) var(--ease-out);
}

.menu-links {
  list-style: none;
  display: grid;
  gap: var(--s-5);
  text-align: center;
}

.menu-links a {
  font-family: var(--font-display);
  font-size: var(--fs-2);
  transform: translateY(16px);
  opacity: 0;
  display: inline-block;
  transition: transform var(--t-2) var(--ease-out), opacity var(--t-2) var(--ease-out);
}

.menu-open .menu-links a {
  transform: translateY(0);
  opacity: 1;
}

.menu-open .menu-links li:nth-child(2) a { transition-delay: 0.05s; }
.menu-open .menu-links li:nth-child(3) a { transition-delay: 0.1s; }
.menu-open .menu-links li:nth-child(4) a { transition-delay: 0.15s; }
.menu-open .menu-links li:nth-child(5) a { transition-delay: 0.2s; }
.menu-open .menu-links li:nth-child(6) a { transition-delay: 0.25s; }

/* -- buttons ------------------------------------------------------ */
.btn {
  --mx: 0px;
  --my: 0px;
  --press: 1;
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--s-2);
  padding: 0.95em 1.7em;
  border: 0;
  border-radius: var(--r-pill);
  font-family: var(--font-ui);
  font-size: var(--fs-small);
  font-weight: 600;
  letter-spacing: 0.02em;
  cursor: pointer;
  overflow: hidden;
  white-space: nowrap;
  transform: translate(var(--mx), var(--my)) scale(var(--press));
  transition: transform 0.35s var(--ease-out), background var(--t-1) var(--ease-out), border-color var(--t-1) var(--ease-out), color var(--t-1) var(--ease-out);
}

.btn:active {
  --press: 0.96;
}

.btn-primary {
  background: var(--accent);
  color: var(--accent-ink);
}

.btn-primary::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(110deg, transparent 30%, rgba(255, 255, 255, 0.4) 50%, transparent 70%);
  transform: translateX(-130%);
}

.btn-primary:hover::after,
.btn-primary:focus-visible::after {
  transform: translateX(130%);
  transition: transform 0.9s var(--ease-inout);
}

.btn-ghost {
  background: transparent;
  color: var(--ink);
  border: 1px solid var(--line-2);
}

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

/* -- cards ---------------------------------------------------------- */
.card {
  background: var(--bg-2);
  border: 1px solid var(--line);
  border-radius: var(--r-m);
  overflow: hidden;
  transition: transform var(--t-2) var(--ease-out), border-color var(--t-2) var(--ease-out), box-shadow var(--t-2) var(--ease-out);
}

.card:hover {
  transform: translateY(-4px);
  border-color: var(--line-2);
  box-shadow: var(--shadow-2);
}

.card-media {
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: var(--bg-3);
}

.card-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--t-3) var(--ease-out);
}

.card:hover .card-media img {
  transform: scale(1.04);
}

.card-body {
  padding: var(--s-6);
}

.card-tags {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-2);
  margin-top: var(--s-4);
}

.tag {
  font-size: var(--fs-label);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-3);
  border: 1px solid var(--line);
  border-radius: var(--r-pill);
  padding: 0.35em 0.9em;
}

/* -- pricing ---------------------------------------------------------- */
.price-from {
  display: flex;
  align-items: baseline;
  gap: var(--s-2);
  font-family: var(--font-display);
}

.price-from .amount {
  font-size: var(--fs-2);
}

.price-from .from {
  font-family: var(--font-ui);
  font-size: var(--fs-label);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-3);
}

/* -- forms ------------------------------------------------------------- */
.field {
  display: grid;
  gap: var(--s-2);
}

.field label {
  font-size: var(--fs-label);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-3);
}

.field input,
.field select,
.field textarea {
  background: transparent;
  border: 0;
  border-bottom: 1px solid var(--line-2);
  color: var(--ink);
  font-family: var(--font-ui);
  font-size: var(--fs-body);
  padding: 0.7em 0;
  border-radius: 0;
  transition: border-color var(--t-1) var(--ease-out);
}

.field select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='%23efeae3' stroke-opacity='0.55' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 4px center;
  padding-right: 1.8rem;
}

.field input:focus,
.field select:focus,
.field textarea:focus {
  outline: none;
  border-bottom-color: var(--accent);
}

.field input::placeholder,
.field textarea::placeholder {
  color: var(--ink-3);
}

/* -- premium layer ------------------------------------------------------- */
.grain {
  position: fixed;
  inset: -100px;
  z-index: 9999;
  pointer-events: none;
  opacity: 0.05;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='300' height='300'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.6'/%3E%3C/svg%3E");
  animation: grain-shift 1.2s steps(4) infinite;
}

@keyframes grain-shift {
  0% { transform: translate(0, 0); }
  25% { transform: translate(-40px, 30px); }
  50% { transform: translate(30px, -50px); }
  75% { transform: translate(-30px, -20px); }
  100% { transform: translate(0, 0); }
}

.scroll-progress {
  position: fixed;
  inset: 0 0 auto 0;
  height: 2px;
  z-index: 1001;
  background: linear-gradient(90deg, var(--violet), var(--cyan) 45%, var(--accent));
  transform-origin: 0 50%;
  transform: scaleX(0);
}

.scroll-hint {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  gap: var(--s-3);
  color: var(--ink-3);
  font-size: var(--fs-label);
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.scroll-hint::after {
  content: '';
  width: 1px;
  height: 48px;
  background: linear-gradient(var(--ink-2), transparent);
  animation: hint-drop 2.2s var(--ease-inout) infinite;
}

@keyframes hint-drop {
  0% { transform: scaleY(0); transform-origin: top; }
  45% { transform: scaleY(1); transform-origin: top; }
  55% { transform: scaleY(1); transform-origin: bottom; }
  100% { transform: scaleY(0); transform-origin: bottom; }
}

/* SVG line-draw: main.js measures each [data-draw] path and scrubs it.
   NEVER combine with vector-effect non-scaling-stroke on a stretched svg —
   it breaks the dash math. */
.draw-svg {
  width: 100%;
  height: auto;
}

.draw-svg path {
  fill: none;
  stroke: var(--accent);
  stroke-width: 1.5;
  stroke-linecap: round;
}

/* ============================================================
   PAGE COMPONENTS v1 — built from the tokens above only
   ============================================================ */

/* -- icons ------------------------------------------------------------ */
.icon {
  width: 22px;
  height: 22px;
  flex: none;
}

.icon-gold {
  color: var(--accent);
}

.btn .icon {
  width: 17px;
  height: 17px;
}

.service-block > div > .icon-gold {
  width: 26px;
  height: 26px;
  margin-bottom: var(--s-4);
}

/* -- hero (index) ------------------------------------------------------ */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  overflow: hidden;
}

.hero-canvas,
.hero-dust {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

/* colored stage lights sweeping the silk film */
.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background: linear-gradient(115deg, var(--glow-violet) 0%, transparent 38%, transparent 58%, var(--glow-cyan) 100%);
  mix-blend-mode: screen;
  animation: hero-light 16s var(--ease-inout) infinite alternate;
}

@keyframes hero-light {
  to { transform: translateX(-5%) scale(1.08); opacity: 0.8; }
}

.hero::after {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(100deg, rgba(10, 10, 11, 0.8) 0%, rgba(10, 10, 11, 0.35) 45%, transparent 72%),
    radial-gradient(90% 70% at 50% 30%, transparent 55%, rgba(10, 10, 11, 0.75) 100%);
}

.hero-inner {
  position: relative;
  z-index: 1;
  padding-top: var(--s-9);
}

.hero-sub {
  margin-top: var(--s-5);
}

.hero-ctas {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-4);
  margin-top: var(--s-7);
}

.hero-hint {
  position: absolute;
  left: var(--gutter);
  bottom: var(--s-6);
  z-index: 1;
}

.hero-outro {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  z-index: 1;
  width: min(92%, 680px);
  text-align: center;
  display: grid;
  gap: var(--s-6);
  justify-items: center;
  opacity: 0;
  pointer-events: none;
}

.hero-outro h2 {
  font-size: var(--fs-1);
}

/* -- page hero (inner pages) ------------------------------------------- */
.page-hero {
  padding-top: calc(var(--s-10) + var(--s-7));
  padding-bottom: var(--s-8);
}

/* -- section head ------------------------------------------------------- */
.section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: var(--s-6);
  flex-wrap: wrap;
  margin-bottom: var(--s-8);
}

.section-head .lead {
  margin-top: var(--s-4);
}

/* -- fact strip ---------------------------------------------------------- */
.facts {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--s-6);
}

.fact {
  display: grid;
  gap: var(--s-3);
  padding: var(--s-6);
  border: 1px solid var(--line);
  border-radius: var(--r-m);
  background: var(--bg-2);
}

.fact h3 {
  font-family: var(--font-ui);
  font-size: var(--fs-body);
  font-weight: 600;
}

.fact p {
  font-size: var(--fs-small);
  color: var(--ink-2);
}

@media (max-width: 800px) {
  .facts {
    grid-template-columns: 1fr;
  }
}

/* -- work cards / case blocks --------------------------------------------- */
.cases-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--s-6);
}

@media (max-width: 800px) {
  .cases-grid {
    grid-template-columns: 1fr;
  }
}

.case-hero {
  display: grid;
  grid-template-columns: 1.15fr 1fr;
  gap: var(--s-8);
  align-items: center;
  padding-block: var(--s-8);
  border-top: 1px solid var(--line);
}

.case-hero .card-media {
  border-radius: var(--r-m);
  border: 1px solid var(--line);
}

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

.case-meta {
  display: grid;
  gap: var(--s-4);
}

.fact-line {
  display: flex;
  gap: var(--s-3);
  align-items: baseline;
  padding-block: var(--s-3);
  border-bottom: 1px solid var(--line);
  font-size: var(--fs-small);
}

.fact-line .k {
  min-width: 120px;
  color: var(--ink-3);
  font-size: var(--fs-label);
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.ba-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--s-4);
  max-width: 560px;
}

.ba-grid figure {
  display: grid;
  gap: var(--s-2);
}

.ba-grid img {
  width: 100%;
  border-radius: var(--r-s);
  border: 1px solid var(--line);
  aspect-ratio: 3 / 4;
  object-fit: cover;
}

.ba-grid figcaption {
  font-size: var(--fs-label);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-3);
}

/* -- service rows ------------------------------------------------------------ */
.service-row {
  display: grid;
  grid-template-columns: 44px 1fr auto auto;
  align-items: center;
  gap: var(--s-6);
  padding-block: var(--s-6);
  border-top: 1px solid var(--line);
  transition: border-color var(--t-2) var(--ease-out);
}

.service-row:last-of-type {
  border-bottom: 1px solid var(--line);
}

.service-row:hover {
  border-top-color: var(--line-2);
}

.service-row .arrow {
  color: var(--ink-3);
  transition: transform var(--t-2) var(--ease-out), color var(--t-2) var(--ease-out);
}

.service-row:hover .arrow {
  transform: translateX(6px);
  color: var(--accent);
}

.service-row h3 {
  font-size: var(--fs-3);
}

.service-row p {
  font-size: var(--fs-small);
  color: var(--ink-2);
  margin-top: var(--s-1);
}

.service-row .price-from .amount {
  font-size: 1.35rem;
}

@media (max-width: 800px) {
  .service-row {
    grid-template-columns: 44px 1fr auto;
  }

  .service-row .arrow {
    display: none;
  }
}

/* -- service detail blocks (services page) ------------------------------------ */
.service-block {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--s-8);
  padding-block: var(--s-9);
  border-top: 1px solid var(--line);
}

@media (max-width: 900px) {
  .service-block {
    grid-template-columns: 1fr;
    padding-block: var(--s-8);
  }
}

.includes-list {
  list-style: none;
  display: grid;
  gap: var(--s-3);
}

.includes-list li {
  display: flex;
  gap: var(--s-3);
  align-items: flex-start;
  color: var(--ink-2);
  font-size: var(--fs-small);
  line-height: 1.55;
}

.includes-list .icon {
  width: 18px;
  height: 18px;
  margin-top: 2px;
  color: var(--accent);
}

.service-side {
  display: grid;
  gap: var(--s-6);
  align-content: start;
}

.spec-card {
  background: var(--bg-2);
  border: 1px solid var(--line);
  border-radius: var(--r-m);
  padding: var(--s-6);
  display: grid;
  gap: var(--s-4);
}

/* -- steps (index teaser) ------------------------------------------------------- */
.steps-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--s-6);
}

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

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

.step-num {
  font-family: var(--font-display);
  font-size: var(--fs-2);
  color: var(--ink-3);
}

.step h3 {
  font-family: var(--font-ui);
  font-size: var(--fs-body);
  font-weight: 600;
  margin-top: var(--s-3);
}

.step p {
  font-size: var(--fs-small);
  color: var(--ink-2);
  margin-top: var(--s-2);
}

/* -- pinned rail (process page) ---------------------------------------------------
   Default layout is the stacked column — it works with no JS, with reduced
   motion, and on any viewport. main.js adds .is-pinned to [data-rail] ONLY
   when the GSAP pin is actually created; the horizontal track exists only then. */
.rail {
  position: relative;
}

.rail-track {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: var(--s-7);
  padding-inline: var(--gutter);
  padding-block: var(--s-7);
}

.rail.is-pinned {
  overflow: hidden;
}

.rail.is-pinned .rail-track {
  flex-direction: row;
  align-items: center;
  width: max-content;
  min-height: 100vh;
  padding-block: 0;
}

.scene {
  width: 100%;
  flex: none;
  background: var(--bg-2);
  border: 1px solid var(--line);
  border-radius: var(--r-m);
  padding: var(--s-8);
  display: grid;
  gap: var(--s-4);
}

.rail.is-pinned .scene {
  width: min(600px, 72vw);
}

.scene .step-num {
  font-size: var(--fs-1);
}

.scene .lead {
  font-size: var(--fs-body);
}

.rail-hint {
  display: none;
  position: absolute;
  right: var(--gutter);
  bottom: var(--s-6);
  color: var(--ink-3);
  font-size: var(--fs-label);
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.rail.is-pinned .rail-hint {
  display: block;
}

/* -- bands & CTA ---------------------------------------------------------------- */
.band {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-6);
  flex-wrap: wrap;
  background: var(--bg-2);
  border: 1px solid var(--line);
  border-radius: var(--r-m);
  padding: var(--s-7);
}

.cta-final {
  text-align: center;
  display: grid;
  gap: var(--s-6);
  justify-items: center;
}

.cta-final h2 {
  font-size: var(--fs-1);
  max-width: 14em;
}

/* -- principles / prose lists ----------------------------------------------------- */
.principles {
  display: grid;
  gap: 0;
  counter-reset: principle;
}

.principle {
  display: grid;
  grid-template-columns: 72px 1fr;
  gap: var(--s-6);
  padding-block: var(--s-6);
  border-top: 1px solid var(--line);
}

.principle:last-child {
  border-bottom: 1px solid var(--line);
}

.principle h3 {
  font-size: var(--fs-3);
}

.principle p {
  color: var(--ink-2);
  margin-top: var(--s-2);
  max-width: 34em;
}

/* -- contact -------------------------------------------------------------------- */
.contact-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: var(--s-9);
  align-items: start;
}

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

.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--s-6);
}

.form-grid .field-full {
  grid-column: 1 / -1;
}

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

.form-success {
  background: var(--bg-2);
  border: 1px solid var(--line-2);
  border-radius: var(--r-m);
  padding: var(--s-7);
  display: grid;
  gap: var(--s-4);
  outline: none;
}

.next-steps {
  display: grid;
  gap: var(--s-5);
}

.next-step {
  display: grid;
  grid-template-columns: 40px 1fr;
  gap: var(--s-4);
}

.next-step .step-num {
  font-size: var(--fs-3);
}

.next-step p {
  color: var(--ink-2);
  font-size: var(--fs-small);
}

/* -- THE TEARDOWN — the site that takes itself apart -------------------------------- */
.teardown {
  position: relative;
  overflow: hidden;
}

.teardown.is-live {
  min-height: 100vh;
}

.td-stage {
  padding-block: var(--s-8);
  display: grid;
  justify-items: center;
  text-align: center;
  gap: var(--s-5);
}

.teardown.is-live .td-stage {
  min-height: 100vh;
  align-content: center;
}

.td-site {
  position: relative;
  width: min(640px, 88vw);
  aspect-ratio: 16 / 10;
  margin-top: var(--s-6);
}

.td-layer {
  position: absolute;
  inset: 0;
  transform: translate(var(--tx, 0px), var(--ty, 0px));
  transition: transform 0.35s var(--ease-out);
  will-change: transform;
}

.td-inner {
  position: absolute;
  inset: 0;
}

.td-label {
  position: absolute;
  top: -30px;
  left: 50%;
  transform: translateX(-50%);
  font-size: var(--fs-label);
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ink-2);
  opacity: 0;
  white-space: nowrap;
}

.td-label b {
  color: var(--accent);
  font-weight: 600;
}

/* layer: code — the chassis */
.td-chassis {
  position: absolute;
  inset: 0;
  border: 1px solid rgba(53, 211, 242, 0.35);
  border-radius: var(--r-m);
  background: rgba(16, 16, 19, 0.82);
  box-shadow: 0 0 40px rgba(53, 211, 242, 0.08);
}

.td-chassis::before {
  content: '</>';
  position: absolute;
  right: 14px;
  bottom: 8px;
  font-family: ui-monospace, 'SF Mono', Menlo, monospace;
  font-size: 12px;
  color: rgba(53, 211, 242, 0.65);
  letter-spacing: 0.1em;
}

/* layer: story — the words */
.td-story-head {
  position: absolute;
  top: 12%;
  left: 8%;
  font-family: var(--font-display);
  font-size: clamp(1.2rem, 2.6vw, 1.8rem);
  color: var(--ink);
}

.td-bar {
  position: absolute;
  left: 8%;
  height: 8px;
  border-radius: 4px;
  background: rgba(239, 234, 227, 0.22);
}

/* layer: design — the palette */
.td-swatches {
  position: absolute;
  top: 14%;
  right: 8%;
  display: flex;
  gap: 8px;
}

.td-swatch {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  border: 1px solid var(--line-2);
}

.td-aa {
  position: absolute;
  right: 8%;
  top: 32%;
  font-family: var(--font-display);
  font-size: clamp(1.6rem, 3.4vw, 2.4rem);
  color: var(--ink-2);
}

/* layer: motion — the life */
.td-curve {
  position: absolute;
  left: 8%;
  right: 8%;
  bottom: 18%;
  width: 84%;
  height: auto;
}

.td-curve path {
  fill: none;
  stroke: url(#silk-spectrum);
  stroke-width: 2;
  stroke-linecap: round;
  filter: drop-shadow(0 0 6px rgba(139, 92, 246, 0.5));
}

.td-pill {
  position: absolute;
  right: 8%;
  bottom: 8%;
  pointer-events: auto;
}

.td-final {
  max-width: 34em;
  opacity: 0;
}

.teardown:not(.is-live) .td-final {
  opacity: 1;
}

.teardown:not(.is-live) .td-label {
  opacity: 1;
  position: static;
  transform: none;
  display: inline-block;
  margin-top: var(--s-2);
}

/* -- FAQ ----------------------------------------------------------------------------- */
.faq {
  border-top: 1px solid var(--line);
  max-width: 760px;
}

.faq-item {
  border-bottom: 1px solid var(--line);
}

.faq-item summary {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: var(--s-4);
  padding-block: var(--s-5);
  cursor: pointer;
  list-style: none;
  font-weight: 600;
}

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

.faq-item summary .icon {
  width: 18px;
  height: 18px;
  color: var(--accent);
  transition: transform var(--t-2) var(--ease-out);
}

.faq-item[open] summary .icon {
  transform: rotate(45deg);
}

.faq-a {
  padding-bottom: var(--s-5);
  color: var(--ink-2);
  font-size: var(--fs-small);
  line-height: 1.6;
  max-width: 60ch;
}

/* -- comparison strip ------------------------------------------------------------------ */
.compare {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--s-5);
}

@media (max-width: 800px) {
  .compare {
    grid-template-columns: 1fr;
  }
}

.compare-col {
  background: var(--bg-2);
  border: 1px solid var(--line);
  border-radius: var(--r-m);
  padding: var(--s-6);
  display: grid;
  gap: var(--s-4);
  align-content: start;
}

.compare-col.is-us {
  border-color: rgba(200, 169, 110, 0.45);
}

.compare-col h3 {
  font-family: var(--font-ui);
  font-size: var(--fs-body);
  font-weight: 600;
}

.compare-col ul {
  list-style: none;
  display: grid;
  gap: var(--s-3);
  font-size: var(--fs-small);
  color: var(--ink-2);
}

.compare-col li {
  display: flex;
  gap: var(--s-3);
  align-items: flex-start;
}

.compare-col li .icon {
  width: 16px;
  height: 16px;
  margin-top: 3px;
  color: var(--ink-3);
}

.compare-col.is-us li .icon {
  color: var(--accent);
}

/* -- scene icon (process rail) ---------------------------------------------------------- */
.scene-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-4);
}

.scene-head .icon {
  width: 26px;
  height: 26px;
}

/* -- media frames (generated illustrations) ------------------------------------------ */
.media-frame {
  border-radius: var(--r-m);
  border: 1px solid var(--line);
  overflow: hidden;
}

.media-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.service-media {
  aspect-ratio: 16 / 10;
}

.scene-media {
  aspect-ratio: 16 / 7;
}

.aside-media {
  aspect-ratio: 16 / 9;
}

.photo-wide {
  aspect-ratio: 21 / 9;
}

.photo-wide + .small,
.aside-media + .small {
  margin-top: var(--s-3);
}

/* -- photo duo (studio) ------------------------------------------------------------ */
.photo-duo {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--s-5);
}

@media (max-width: 700px) {
  .photo-duo {
    grid-template-columns: 1fr;
  }
}

.photo-duo figure {
  display: grid;
  gap: var(--s-3);
}

.photo-duo img {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  border-radius: var(--r-m);
  border: 1px solid var(--line);
}

.photo-duo figcaption {
  font-size: var(--fs-label);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-3);
}

/* -- footer ----------------------------------------------------------------------- */
.footer {
  border-top: 1px solid var(--line);
  padding-block: var(--s-8) var(--s-6);
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: var(--s-7);
}

@media (max-width: 800px) {
  .footer-grid {
    grid-template-columns: 1fr;
  }
}

.footer .wordmark {
  font-size: 1.6rem;
}

.footer-tag {
  color: var(--ink-2);
  margin-top: var(--s-3);
  max-width: 22em;
}

.footer-col {
  display: grid;
  gap: var(--s-3);
  align-content: start;
  font-size: var(--fs-small);
  color: var(--ink-2);
}

.footer-col .label {
  font-size: var(--fs-label);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-3);
  margin-bottom: var(--s-2);
}

.footer-meta {
  display: flex;
  justify-content: space-between;
  gap: var(--s-4);
  flex-wrap: wrap;
  margin-top: var(--s-8);
  padding-top: var(--s-5);
  border-top: 1px solid var(--line);
  font-size: var(--fs-label);
  letter-spacing: 0.06em;
  color: var(--ink-3);
}

/* ============================================================
   LIGHT LAYER v2 — the high-tech glow
   Light is atmosphere, gold stays the only ACTION color.
   ============================================================ */

:root {
  /* spectral light — cinema gels over the black silk */
  --violet: #8b5cf6;
  --cyan: #35d3f2;
  --rose: #ef6fb4;
  --glow-gold: rgba(200, 169, 110, 0.2);
  --glow-violet: rgba(139, 92, 246, 0.32);
  --glow-cyan: rgba(53, 211, 242, 0.24);
  --glow-rose: rgba(239, 111, 180, 0.2);
}

.section,
.page-hero {
  position: relative;
}

/* drifting aurora light fields */
.aurora {
  position: absolute;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
}

.aurora {
  background: radial-gradient(60% 55% at 65% 25%, rgba(239, 111, 180, 0.12), transparent 78%);
}

/* softness baked into the gradient stops — no blur filter, no compositing cost */
.aurora::before,
.aurora::after {
  content: '';
  position: absolute;
  width: 74vw;
  height: 74vw;
  max-width: 1200px;
  max-height: 1200px;
  border-radius: 50%;
  mix-blend-mode: screen;
  will-change: transform;
}

.aurora::before {
  background: radial-gradient(circle, var(--glow-violet) 0%, rgba(139, 92, 246, 0.14) 25%, rgba(139, 92, 246, 0.05) 50%, transparent 72%);
  top: -28%;
  left: -8%;
  animation: aurora-a 26s var(--ease-inout) infinite alternate;
}

.aurora::after {
  background: radial-gradient(circle, var(--glow-cyan) 0%, rgba(53, 211, 242, 0.11) 25%, rgba(53, 211, 242, 0.04) 50%, transparent 72%);
  bottom: -30%;
  right: -6%;
  animation: aurora-b 34s var(--ease-inout) infinite alternate;
}

@keyframes aurora-a {
  to { transform: translate(10vw, 9vh) scale(1.18); }
}

@keyframes aurora-b {
  to { transform: translate(-9vw, -7vh) scale(1.12); }
}

/* cursor spotlight (JS adds .spot + --sx/--sy on fine pointers) */
.spot {
  position: relative;
}

.spot::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  opacity: 0;
  transition: opacity var(--t-2) var(--ease-out);
  background: radial-gradient(340px circle at var(--sx, 50%) var(--sy, 50%), rgba(139, 92, 246, 0.14), rgba(53, 211, 242, 0.07) 45%, transparent 70%);
  pointer-events: none;
}

.spot:hover::after {
  opacity: 1;
}

/* glow on the action layer */
.btn-primary {
  transition: transform 0.35s var(--ease-out), box-shadow var(--t-2) var(--ease-out), background var(--t-1) var(--ease-out);
}

.btn-primary:hover,
.btn-primary:focus-visible {
  box-shadow: 0 6px 30px rgba(200, 169, 110, 0.3), 0 0 55px rgba(139, 92, 246, 0.18);
}

.draw-svg path {
  stroke: url(#silk-spectrum);
  filter: drop-shadow(0 0 7px rgba(139, 92, 246, 0.45));
}

/* gradient hairline frame — the tech border (doubled class beats any later single-class rule) */
.grad-border.grad-border {
  border: 1px solid transparent;
  background:
    linear-gradient(var(--bg-2), var(--bg-2)) padding-box,
    linear-gradient(120deg, rgba(139, 92, 246, 0.55), rgba(53, 211, 242, 0.45) 50%, rgba(200, 169, 110, 0.55)) border-box;
}

.kit-tile:nth-child(1):hover { border-color: rgba(139, 92, 246, 0.55); }
.kit-tile:nth-child(2):hover { border-color: rgba(53, 211, 242, 0.55); }
.kit-tile:nth-child(3):hover { border-color: rgba(200, 169, 110, 0.6); }

.kit-draw path {
  stroke: url(#silk-spectrum);
  filter: drop-shadow(0 0 7px rgba(53, 211, 242, 0.5));
}

.scroll-progress {
  box-shadow: 0 0 12px rgba(200, 169, 110, 0.55);
}

/* -- lit text: light inside the typography ----------------------------------- */
.hero-title,
.page-hero h1 {
  text-shadow: 0 0 70px rgba(139, 92, 246, 0.4), 0 0 140px rgba(53, 211, 242, 0.2);
}

.section-head h2,
.cta-final h2,
.hero-outro h2 {
  text-shadow: 0 0 60px rgba(139, 92, 246, 0.3);
}

.eyebrow {
  text-shadow: 0 0 22px rgba(200, 169, 110, 0.55);
}

/* one lit word per heading — static clip; two NEIGHBOR hues so they fuse */
.lit {
  background: linear-gradient(100deg, var(--violet) 0%, var(--cyan) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  -webkit-text-fill-color: transparent;
}

.counters .counter-num {
  background: linear-gradient(120deg, var(--violet), var(--cyan));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  -webkit-text-fill-color: transparent;
}

/* iridescent shimmer on a headline word — silk catching the gels */
.shimmer {
  background: linear-gradient(110deg, var(--ink) 22%, var(--rose) 40%, var(--violet) 50%, var(--cyan) 60%, var(--ink) 78%);
  background-size: 250% 100%;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  -webkit-text-fill-color: transparent;
  animation: shimmer-slide 6s var(--ease-inout) infinite;
}

@keyframes shimmer-slide {
  0% { background-position: 125% 0; }
  100% { background-position: -125% 0; }
}

/* -- honest counters ---------------------------------------------------------- */
.counters {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--s-6);
  text-align: center;
}

@media (max-width: 800px) {
  .counters {
    grid-template-columns: 1fr 1fr;
  }
}

.counter {
  display: grid;
  gap: var(--s-2);
  padding: var(--s-6) var(--s-4);
  border: 1px solid var(--line);
  border-radius: var(--r-m);
  background: var(--bg-2);
}

.counter-num {
  font-family: var(--font-display);
  font-size: var(--fs-1);
  line-height: 1;
  color: var(--ink);
}

.counter .small {
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-size: var(--fs-label);
}

/* -- playground (signature kit, live) ------------------------------------------- */
.kit-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--s-5);
}

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

.kit-tile {
  background: var(--bg-2);
  border: 1px solid var(--line);
  border-radius: var(--r-m);
  padding: var(--s-6);
  display: grid;
  gap: var(--s-3);
  transition: border-color var(--t-2) var(--ease-out);
}

.kit-tile:hover {
  border-color: var(--line-2);
}

.kit-tile h3 {
  font-family: var(--font-ui);
  font-size: var(--fs-body);
  font-weight: 600;
}

.kit-tile p {
  color: var(--ink-2);
}

.kit-stage {
  position: relative;
  height: 170px;
  border-radius: var(--r-s);
  border: 1px solid var(--line);
  background: var(--bg);
  display: grid;
  place-items: center;
  overflow: hidden;
  touch-action: none;
}

.kit-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.kit-hint {
  position: absolute;
  left: 50%;
  bottom: var(--s-3);
  transform: translateX(-50%);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-size: var(--fs-label);
  color: var(--ink-3);
  pointer-events: none;
  text-shadow: 0 1px 6px rgba(0, 0, 0, 0.8);
}

.kit-draw {
  width: 90%;
  height: auto;
}

.kit-draw path {
  fill: none;
  stroke: var(--accent);
  stroke-width: 2;
  stroke-linecap: round;
  filter: drop-shadow(0 0 7px rgba(200, 169, 110, 0.5));
  transition: stroke-dashoffset 1.3s var(--ease-out);
}

/* -- founder note ------------------------------------------------------------------ */
.note {
  max-width: 660px;
  border-left: 2px solid var(--accent);
  padding-left: var(--s-6);
  display: grid;
  gap: var(--s-4);
}

.note-text {
  font-family: var(--font-display);
  font-size: var(--fs-3);
  line-height: 1.5;
}

/* ============================================================
   FIRST LIGHT — the title sequence (index, once per session)
   A gate script adds .has-intro to <html> before styles load;
   main.js choreographs and removes it. Everything here must be
   restorable to stylesheet defaults by removing the class.
   ============================================================ */

.has-intro [data-nav],
.has-intro .hero-inner > *,
.has-intro .hero-hint {
  opacity: 0;
}

.has-intro .grain {
  opacity: 0;
}

.has-intro .hero::before {
  opacity: var(--gel, 0);
  animation-play-state: paused;
}

.intro {
  position: fixed;
  inset: 0;
  z-index: 2000;
  overflow: hidden;
  pointer-events: none;
}

.intro-sweep {
  position: absolute;
  top: -35vh;
  bottom: -35vh;
  left: 0;
  width: 340vw;
  display: flex;
  will-change: transform;
}

.intro-band {
  width: 30vw;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(239, 234, 227, 0.16) 45%, rgba(200, 169, 110, 0.11) 55%, transparent);
  mix-blend-mode: screen;
}

.intro-shroud {
  flex: 1;
  height: 100%;
  margin-left: -8vw;
  background: linear-gradient(90deg, transparent 0, #0a0a0b 14vw);
}

.intro-rule {
  position: absolute;
  left: 50%;
  top: calc(50% + clamp(52px, 7vw, 88px));
  width: min(130px, 16vw);
  height: 1px;
  background: var(--accent);
  box-shadow: 0 0 14px rgba(200, 169, 110, 0.6);
  transform: translateX(-50%) scaleX(0);
}

.intro-word {
  position: absolute;
  left: 50%;
  top: 47%;
  font-family: var(--font-display);
  font-size: clamp(2.2rem, 5.5vw, 3.6rem);
  letter-spacing: 0.02em;
  color: var(--ink);
  display: flex;
  text-shadow: 0 0 60px rgba(139, 92, 246, 0.35);
}

.intro-word span {
  display: inline-block;
  opacity: 0;
  will-change: transform;
}

/* -- reveal defaults (JS-driven; harmless without JS) --------------------- */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .grain {
    animation: none;
  }

  .scroll-hint::after {
    animation: none;
  }

  *,
  *::before,
  *::after {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
  }
}
