/* ==========================================================================
   MNANDCO — design tokens
   ========================================================================== */

:root{
  /* palette — dark cinematic, black/brown ground, warm white, amber/gold accent */
  --bg:            #0a0705;
  --bg-alt:        #150f0a;
  --panel:         #17110b;
  --border:        rgba(206, 165, 106, 0.14);
  --border-strong: rgba(206, 165, 106, 0.30);

  --text:          #f3ead9;
  --text-dim:      #b7a992;
  --text-mute:     #8c7c64;

  --amber:         #cd9a52;
  --amber-bright:  #eabd7c;
  --amber-deep:    #8a5a2b;
  --amber-deep-btn: #a77843;
  --amber-glow:    rgba(205, 154, 82, 0.35);

  --locked:        #4d4335;

  --font-display: 'Fraunces', 'Iowan Old Style', Georgia, serif;
  --font-body:    'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-mono:    'JetBrains Mono', 'SF Mono', Menlo, monospace;

  --container: 1240px;
  --edge: clamp(20px, 5vw, 64px);

  --ease-out: cubic-bezier(.16,.8,.24,1);
  --ease-soft: cubic-bezier(.4,0,.2,1);

  color-scheme: dark;
}

/* ==========================================================================
   Reset
   ========================================================================== */

*, *::before, *::after{ box-sizing: border-box; }
html{ scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce){
  html{ scroll-behavior: auto; }
  *, *::before, *::after{
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
}

body{
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img, svg{ display: block; max-width: 100%; }
a{ color: inherit; text-decoration: none; }
ul{ list-style: none; margin: 0; padding: 0; }
button{ font: inherit; color: inherit; background: none; border: none; cursor: pointer; }
input{ font: inherit; color: inherit; }

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

.skip-link{
  position: absolute;
  left: 12px; top: -60px;
  background: var(--amber);
  color: #14100b;
  padding: 10px 18px;
  border-radius: 6px;
  font-weight: 600;
  z-index: 1000;
  transition: top .2s var(--ease-out);
}
.skip-link:focus{ top: 12px; }

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

::selection{ background: var(--amber-deep); color: var(--text); }

/* film grain overlay */
.grain{
  position: fixed; inset: 0;
  pointer-events: none;
  z-index: 500;
  opacity: 0.05;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='140' height='140'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/></filter><rect width='100%25' height='100%25' filter='url(%23n)'/></svg>");
  background-size: 180px 180px;
}

/* ==========================================================================
   Type
   ========================================================================== */

h1, h2, h3, h4{
  font-family: var(--font-display);
  line-height: 1.08;
  margin: 0;
  color: var(--text);
  letter-spacing: -0.01em;
}
h1{ font-weight: 400; }
h2{ font-weight: 500; }
h3, h4{ font-weight: 600; }

p{ margin: 0; }

/* Section labels read as manuscript marginalia — an italic serif note, not
   a tracked-out mono/uppercase tag — so they carry the book's voice rather
   than a dev-tool one. */
.eyebrow{
  display: flex;
  align-items: baseline;
  gap: 12px;
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 400;
  font-size: 16px;
  letter-spacing: 0;
  color: var(--amber);
  margin: 0 0 18px;
}
.eyebrow.center{ justify-content: center; }
.eyebrow-line{
  width: 22px; height: 1px;
  background: var(--amber);
  display: inline-block;
  transform: translateY(-4px);
}

.section-title{
  font-size: clamp(2rem, 1.4rem + 2.6vw, 3.4rem);
  margin-bottom: 20px;
  text-wrap: balance;
}
.section-title.center{ text-align: center; margin-left: auto; margin-right: auto; }

/* ==========================================================================
   Layout helpers
   ========================================================================== */

.section-inner{
  max-width: var(--container);
  margin: 0 auto;
  padding-left: var(--edge);
  padding-right: var(--edge);
}

.reveal{
  opacity: 0;
  transform: translateY(22px);
  transition: opacity .9s var(--ease-out), transform .9s var(--ease-out);
  transition-delay: var(--reveal-delay, 0s);
}
.reveal.in-view{
  opacity: 1;
  transform: translateY(0);
}

/* Services' header stays quiet on purpose — the section's real signature
   motion is the padlock list unlocking below it, so the heading just
   fades in rather than repeating the hero/about slide-up. */
.reveal-fade{
  opacity: 0;
  transition: opacity .7s var(--ease-out);
  transition-delay: var(--reveal-delay, 0s);
}
.reveal-fade.in-view{ opacity: 1; }

/* Newsletter materializes rather than slides — echoes the glow blooming
   behind it, like the invitation itself is sealing into place. */
.reveal-scale{
  opacity: 0;
  transform: scale(0.97);
  transition: opacity .8s var(--ease-out), transform .8s var(--ease-out);
  transition-delay: var(--reveal-delay, 0s);
}
.reveal-scale.in-view{
  opacity: 1;
  transform: scale(1);
}

/* ==========================================================================
   Buttons
   ========================================================================== */

.btn{
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 13px 26px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0.01em;
  white-space: nowrap;
  overflow: hidden;
  transition: transform 160ms var(--ease-out), border-color .3s, background .3s, box-shadow .25s;
}
.btn span{ position: relative; z-index: 2; }
.btn:active{ transform: scale(0.97); }

.btn-primary{
  background: linear-gradient(180deg, var(--amber-bright), var(--amber-deep-btn));
  color: #170f08;
  box-shadow: 0 1px 0 rgba(255,255,255,0.25) inset, 0 10px 26px -12px rgba(205,154,82,0.55);
}
.btn-primary::after{
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(115deg, transparent 30%, rgba(255,255,255,0.55) 48%, transparent 66%);
  transform: translateX(-120%);
  transition: transform .7s var(--ease-out);
}
@media (hover: hover) and (pointer: fine){
  .btn-primary:hover{ transform: translateY(-2px); box-shadow: 0 1px 0 rgba(255,255,255,0.3) inset, 0 16px 34px -14px rgba(205,154,82,0.7); }
  .btn-primary:hover::after{ transform: translateX(120%); }
}

.btn-lg{ padding: 16px 30px; font-size: 15px; }

/* ==========================================================================
   Header
   ========================================================================== */

.site-header{
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 200;
  padding: 22px 0;
  transition: padding .4s var(--ease-out), background .4s var(--ease-out), border-color .4s var(--ease-out);
  border-bottom: 1px solid transparent;
}
.site-header.scrolled{
  padding: 14px 0;
  background: rgba(10, 7, 5, 0.72);
  backdrop-filter: blur(14px) saturate(140%);
  -webkit-backdrop-filter: blur(14px) saturate(140%);
  border-bottom: 1px solid var(--border);
}

.header-inner{
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 var(--edge);
  display: flex;
  align-items: center;
  gap: 40px;
}

.logo{
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-display);
  font-size: 19px;
  letter-spacing: 0.06em;
  color: var(--text);
  margin-right: auto;
}
.logo-mark{ color: var(--amber); font-size: 15px; }

.primary-nav ul{ display: flex; gap: 34px; }
.primary-nav a{
  position: relative;
  font-size: 14px;
  color: var(--text-dim);
  padding: 4px 0;
  transition: color .25s;
}
.primary-nav a::after{
  content: "";
  position: absolute; left: 0; right: 100%; bottom: -2px;
  height: 1px;
  background: var(--amber);
  transition: right .2s var(--ease-out);
}
.primary-nav a.active{ color: var(--text); }
.primary-nav a.active::after{ right: 0; }
@media (hover: hover) and (pointer: fine){
  .primary-nav a:hover{ color: var(--text); }
  .primary-nav a:hover::after{ right: 0; }
}

.header-actions{ display: flex; align-items: center; gap: 12px; }

.menu-toggle{
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 34px; height: 34px;
}
.menu-toggle span{
  display: block;
  width: 100%; height: 1px;
  background: var(--text);
  transition: transform .35s var(--ease-out), opacity .25s;
}
.menu-toggle[aria-expanded="true"] span:nth-child(1){ transform: translateY(6px) rotate(45deg); }
.menu-toggle[aria-expanded="true"] span:nth-child(2){ opacity: 0; }
.menu-toggle[aria-expanded="true"] span:nth-child(3){ transform: translateY(-6px) rotate(-45deg); }

.mobile-nav{
  position: fixed; inset: 0;
  z-index: 190;
  background: #0a0705ee;
  backdrop-filter: blur(20px);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 44px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-12px);
  transition: opacity .25s var(--ease-out), transform .25s var(--ease-out), visibility 0s linear .25s;
}
.mobile-nav.open{
  opacity: 1; visibility: visible; transform: translateY(0);
  transition: opacity .4s var(--ease-out), transform .4s var(--ease-out), visibility 0s;
}
.mobile-nav ul{ display: flex; flex-direction: column; gap: 26px; text-align: center; }
.mobile-nav a{ font-family: var(--font-display); font-size: 34px; color: var(--text); }
@media (hover: hover) and (pointer: fine){
  .mobile-nav a:hover{ color: var(--amber-bright); }
}
.mobile-nav-actions{ display: flex; flex-direction: column; gap: 14px; width: min(280px, 80vw); }
.mobile-nav-actions .btn{ width: 100%; }

/* ==========================================================================
   Hero
   ========================================================================== */

.hero{
  position: relative;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 120px var(--edge);
  overflow: hidden;
  background:
    radial-gradient(60% 50% at 78% 18%, rgba(205,154,82,0.10), transparent 60%),
    radial-gradient(55% 45% at 10% 85%, rgba(138,90,43,0.10), transparent 65%),
    var(--bg);
}

.hero-glow{
  position: absolute;
  width: 480px; height: 480px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(205,154,82,0.16), transparent 70%);
  top: 20%; left: 60%;
  filter: blur(10px);
  pointer-events: none;
  transition: transform .7s var(--ease-soft);
  will-change: transform;
}

.hero-vignette{
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(120% 90% at 50% 45%, transparent 45%, rgba(6,4,3,0.55) 100%),
    linear-gradient(180deg, rgba(6,4,3,0.5), transparent 18%, transparent 78%, rgba(6,4,3,0.7));
  z-index: 1;
}

.hero-corner-tag{
  position: absolute;
  bottom: 40px;
  left: var(--edge);
  z-index: 2;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.16em;
  color: var(--text-mute);
}

/* fixed reading-progress rail — right edge, vertically centered, visible
   throughout the whole page. The label is given a fixed height (enough for
   the longest section name) so swapping "Hero" for "Newsletter" never
   resizes the flex column and shifts the rest of the rail. */
.scene-index{
  position: fixed;
  right: var(--edge);
  top: 50%;
  transform: translateY(-50%);
  z-index: 150;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.1em;
  color: var(--text-mute);
}
.scene-index-num{ color: var(--amber); }
.scene-index-line{
  width: 1px;
  height: 130px;
  background: rgba(255,255,255,0.08);
  position: relative;
  overflow: hidden;
}
.scene-index-fill{
  position: absolute; left: 0; right: 0; top: 0; bottom: 0;
  transform: scaleY(0);
  transform-origin: top;
  background: var(--amber);
  transition: transform .25s linear;
}
.scene-index-label{
  writing-mode: vertical-rl;
  letter-spacing: 0.14em;
  height: 100px;
  overflow: hidden;
}

@media (max-width: 980px){
  .scene-index{ display: none; }
}

.hero-inner{
  max-width: var(--container);
  margin: 0 auto;
  width: 100%;
  display: grid;
  grid-template-columns: minmax(0,1.05fr) minmax(0,0.95fr);
  gap: clamp(30px, 5vw, 70px);
  align-items: center;
  position: relative;
  z-index: 2;
}

.hero-title{
  font-size: clamp(2.5rem, 0.7rem + 4.6vw, 4.8rem);
  margin-bottom: 26px;
  text-wrap: balance;
}

/* cinematic title-sequence stagger for the hero's own reveal-on-load */
.hero-copy .eyebrow{ --reveal-delay: .1s; }
.hero-copy .hero-title{ --reveal-delay: .26s; }
.hero-copy .hero-sub{ --reveal-delay: .46s; }
.hero-copy .hero-actions{ --reveal-delay: .62s; }
.hero-visual.reveal{ --reveal-delay: .78s; }

.hero-sub{
  font-size: clamp(1rem, 0.94rem + 0.3vw, 1.18rem);
  color: var(--text-dim);
  max-width: 46ch;
  margin-bottom: 40px;
  font-weight: 300;
}

.hero-actions{ display: flex; flex-wrap: wrap; gap: 16px; }

/* ---- 404 page: reuses .hero's background/glow, centered single column ---- */

.error-page{
  position: relative;
  z-index: 2;
  max-width: 480px;
  margin: 0 auto;
  text-align: center;
}
.error-page-sub{
  font-size: 1rem;
  color: var(--text-dim);
  font-weight: 300;
  margin-bottom: 32px;
}

/* ---- legal pages (privacy/cookies): plain reading page, no hero chrome ---- */

.legal-header{
  padding: 28px var(--edge);
}

.legal-page{
  max-width: 640px;
  margin: 0 auto;
  padding: 20px var(--edge) 140px;
}
.legal-page h1{
  font-size: clamp(1.8rem, 1.4rem + 1.6vw, 2.6rem);
  margin: 0 0 6px;
}
.legal-updated{
  color: var(--text-mute);
  font-size: 13px;
  margin-bottom: 32px;
}
.legal-page > p{
  color: var(--text-dim);
  font-weight: 300;
  max-width: 62ch;
  margin-bottom: 16px;
}
.legal-page h2{
  font-size: 1.3rem;
  margin: 40px 0 12px;
}
.legal-page a{ color: var(--amber); text-decoration: underline; text-underline-offset: 3px; }
.legal-page a:hover{ color: var(--amber-bright); }
.legal-back{ margin-top: 24px; }

@media (max-width: 640px){
  .legal-page{ padding-bottom: 90px; }
}

/* ---- hero code visual: a faded, always-writing story engine ---- */

.hero-visual{
  position: relative;
  aspect-ratio: 6 / 5.2;
  width: 100%;
  will-change: transform;
}

.code-field{
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  background: linear-gradient(180deg, rgba(23,17,11,0.6), rgba(23,17,11,0.4));
  border: 1px solid var(--border);
  border-radius: 14px;
  overflow: hidden;
  backdrop-filter: blur(8px);
  box-shadow: 0 40px 90px -40px rgba(0,0,0,0.65);
  opacity: 0.92;
}
.code-field-head{
  flex: none;
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--border);
  background: rgba(28,21,16,0.5);
}
.code-field-head .dot{
  width: 7px; height: 7px; border-radius: 50%;
  background: var(--locked);
}
.code-field-title{
  margin-left: 8px;
  font-family: var(--font-mono);
  font-size: 10.5px;
  color: var(--text-mute);
  letter-spacing: 0.03em;
}

.code-field-body{
  flex: 1;
  min-height: 0;
  position: relative;
  overflow: hidden;
  -webkit-mask-image: linear-gradient(to bottom, transparent 0%, black 16%, black 84%, transparent 100%);
  mask-image: linear-gradient(to bottom, transparent 0%, black 16%, black 84%, transparent 100%);
}

.code-stream{
  height: 100%;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  gap: 2px;
  padding: 22px 22px 26px;
  font-family: var(--font-mono);
  font-size: 12px;
  line-height: 1.7;
}
.code-row{
  white-space: pre;
  color: var(--text-dim);
}
.code-row .typed-text{ color: var(--amber-bright); }
.code-row .tok-kw{ color: var(--amber-bright); font-weight: 500; }
.code-row .tok-tag{ color: var(--amber-bright); }
.code-row .tok-attr{ color: var(--amber); }
.code-row .tok-str{ color: var(--amber); }
.code-row .tok-prop{ color: var(--text); }
.code-row .tok-punc{ color: var(--text-dim); }
.code-row .tok-comment{ color: var(--text-mute); }

.caret{
  display: inline-block;
  width: 6px; height: 13px;
  background: var(--amber);
  margin-left: 2px;
  transform: translateY(2px);
  animation: blink 1s step-end infinite;
}
@keyframes blink{ 50%{ opacity: 0; } }

/* ==========================================================================
   About
   ========================================================================== */

.about{
  padding: 140px 0;
  background: var(--bg-alt);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.about-grid{
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: clamp(40px, 6vw, 90px);
  align-items: start;
}

.about-body p{
  color: var(--text-dim);
  font-size: 1.02rem;
  font-weight: 300;
  max-width: 54ch;
}
.about-body p + p{ margin-top: 20px; }

.about-stats{
  display: flex;
  flex-direction: column;
  gap: 34px;
  padding-top: 8px;
}
.stat{ position: relative; padding-left: 22px; border-left: 1px solid var(--border); }
.stat-num{
  font-family: var(--font-display);
  font-size: clamp(2.4rem, 1.6vw + 2rem, 3.2rem);
  color: var(--amber-bright);
  line-height: 1;
}
.stat-suffix{
  font-family: var(--font-display);
  font-size: clamp(1.6rem, 1.2vw + 1.2rem, 2rem);
  color: var(--amber-bright);
}
.stat-label{
  display: block;
  margin-top: 8px;
  font-size: 13px;
  color: var(--text-mute);
  max-width: 26ch;
}

/* ==========================================================================
   Services — an unlock list, not a card grid
   ========================================================================== */

.services{ padding: 140px 0; }

.services-head{ max-width: 640px; margin: 0 auto 64px; text-align: center; }
.services-sub{ color: var(--text-dim); font-weight: 300; font-size: 1.02rem; }

/* A single spine runs down the list; each row is a padlock waiting for the
   reader to scroll to it. When it crosses into view it unlocks — the
   shackle swings open, the node lights amber — the same animation
   language as the hero's own locked/unlocked story choices. */
.unlock-list{
  position: relative;
  display: flex;
  flex-direction: column;
  max-width: 760px;
  margin: 0 auto;
}
.unlock-list::before{
  content: "";
  position: absolute;
  left: 21px;
  top: 26px;
  bottom: 26px;
  width: 1px;
  background: var(--border-strong);
  z-index: 0;
}

.unlock-item{
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 44px 1fr;
  column-gap: 28px;
  padding: 38px 0;
}
.unlock-item + .unlock-item{ border-top: 1px solid var(--border); }
.unlock-item.reveal{ transition: opacity .25s var(--ease-out), transform .25s var(--ease-out); }
.unlock-item.reveal.in-view{ transition: opacity .4s var(--ease-out), transform .4s var(--ease-out); }

.unlock-rail{ display: flex; justify-content: center; padding-top: 2px; }
.unlock-node{
  position: relative;
  width: 44px; height: 44px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--panel);
  border: 1px solid var(--border);
  color: var(--text-mute);
  transition: border-color .3s var(--ease-out), color .3s var(--ease-out), box-shadow .32s var(--ease-out), background .3s var(--ease-out);
}
.unlock-shackle{ transform-origin: 32% 62%; transition: transform .3s var(--ease-out); }

.unlock-item.in-view .unlock-node{
  border-color: var(--amber);
  color: var(--amber-bright);
  background: rgba(205,154,82,0.1);
  box-shadow: 0 0 0 5px rgba(205,154,82,0.08), 0 0 22px -6px rgba(205,154,82,0.6);
}
.unlock-item.in-view .unlock-shackle{
  transform: translate(3px, -5px) rotate(-52deg);
}

.unlock-body{ padding-top: 2px; }
.unlock-body h3{ font-size: 1.3rem; margin-bottom: 6px; }
.unlock-tagline{
  font-family: var(--font-display);
  font-style: italic;
  color: var(--amber);
  font-size: 0.98rem;
  margin-bottom: 14px;
}
.unlock-desc{
  font-size: 14px;
  line-height: 1.7;
  color: var(--text-mute);
  max-width: 52ch;
}

/* ==========================================================================
   Newsletter
   ========================================================================== */

.newsletter{
  position: relative;
  padding: 52px 0;
  text-align: center;
  background: var(--bg-alt);
  border-top: 1px solid var(--border);
  overflow: hidden;
}
.newsletter-glow{
  position: absolute;
  width: 620px; height: 620px;
  left: 50%; top: 0;
  transform: translate(-50%, -55%);
  background: radial-gradient(circle, rgba(205,154,82,0.14), transparent 68%);
  pointer-events: none;
}

.newsletter-inner{ max-width: 480px; position: relative; z-index: 2; }
.newsletter-sub{
  color: var(--text-dim);
  font-weight: 300;
  font-size: 1.02rem;
  margin: 0 auto 44px;
  max-width: 36ch;
}

.newsletter-form{ display: flex; flex-direction: column; align-items: center; gap: 14px; }
.field-row{
  display: flex;
  width: 100%;
  max-width: 380px;
  border: 1px solid var(--border-strong);
  border-radius: 999px;
  padding: 6px 6px 6px 22px;
  background: var(--panel);
  transition: border-color .3s, box-shadow .3s, transform .35s var(--ease-out);
}
.field-row:focus-within{
  border-color: var(--amber);
  box-shadow: 0 0 0 4px rgba(205,154,82,0.12), 0 14px 30px -18px rgba(205,154,82,0.5);
  transform: scale(1.018);
}
.field-row.error{
  border-color: #d97b6a;
  box-shadow: 0 0 0 4px rgba(217,123,106,0.12);
}
.field-row input[type="email"]{
  flex: 1;
  min-width: 0;
  background: none;
  border: none;
  outline: none;
  color: var(--text);
  font-size: 14px;
  padding: 10px 8px;
}
.field-row input[type="email"]::placeholder{ color: var(--text-mute); }

.field-note{
  font-size: 12.5px;
  color: var(--text-mute);
  transition: color .3s;
}
.field-note.success{ color: var(--amber-bright); }
.field-note.error{ color: #d97b6a; }

/* ==========================================================================
   Footer
   ========================================================================== */

.site-footer{ padding: 70px 0 0; background: var(--bg); }

.footer-grid{
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: flex-start;
  gap: 40px;
  padding-bottom: 54px;
  border-bottom: 1px solid var(--border);
}
.footer-brand{ max-width: 400px; }
.footer-col{ text-align: right; }

.footer-brand p{
  margin-top: 14px;
  color: var(--text-mute);
  font-size: 12px;
  max-width: 32ch;
  line-height: 1.6;
}

.footer-col h4{
  font-family: var(--font-body);
  font-size: 12px;
  letter-spacing: 0.02em;
  color: var(--text-dim);
  font-weight: 500;
  margin-bottom: 14px;
}
.footer-col ul{ display: flex; flex-direction: column; gap: 10px; }
.footer-col a{ font-size: 13px; color: var(--text-dim); transition: color .25s; }
@media (hover: hover) and (pointer: fine){
  .footer-col a:hover{ color: var(--amber-bright); }
}

.footer-bottom{
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px var(--edge) 22px;
  font-size: 12px;
  color: var(--text-mute);
}
.footer-legal-link{ text-decoration: underline; text-underline-offset: 2px; transition: color .25s; }
.footer-legal-link:hover{ color: var(--amber-bright); }

.to-top{ color: var(--text-mute); transition: color .25s, transform .25s; display: inline-block; }
@media (hover: hover) and (pointer: fine){
  .to-top:hover{ color: var(--amber-bright); transform: translateY(-2px); }
}

/* ==========================================================================
   Responsive
   ========================================================================== */

@media (max-width: 980px){
  .primary-nav, .header-actions{ display: none; }
  .menu-toggle{ display: flex; }
  .hero-corner-tag{ display: none; }

  .hero-inner{ grid-template-columns: 1fr; text-align: center; }
  .hero-copy{ display: flex; flex-direction: column; align-items: center; }
  .hero-sub{ margin-left: auto; margin-right: auto; }
  .hero-actions{ justify-content: center; }
  .hero-visual{ max-width: 480px; margin: 20px auto 0; aspect-ratio: 6/5.6; }

  .about-grid{ grid-template-columns: 1fr; }
  .about-stats{ flex-direction: row; flex-wrap: wrap; gap: 30px 40px; }
  .stat{ flex: 1 1 200px; }

  .footer-grid{ row-gap: 36px; }
}

@media (max-width: 640px){
  .hero{ padding-top: 130px; }
  .hero-title{ letter-spacing: -0.005em; }

  .hero-actions{ flex-direction: column; width: 100%; }
  .hero-actions .btn{ width: 100%; }

  .about, .services{ padding: 90px 0; }
  .newsletter{ padding: 40px 0; }

  .unlock-item{ grid-template-columns: 36px 1fr; column-gap: 18px; padding: 30px 0; }
  .unlock-node{ width: 36px; height: 36px; }
  .unlock-node svg{ width: 14px; height: 14px; }
  .unlock-list::before{ left: 17px; }

  .field-row{ flex-direction: column; border-radius: 18px; padding: 14px; gap: 10px; }
  .field-row input[type="email"]{ width: 100%; text-align: center; }
  .field-row .btn{ width: 100%; }

  .footer-grid{ flex-direction: column; align-items: flex-start; gap: 32px; }
  .footer-col{ text-align: left; }
  .footer-bottom{ flex-direction: column; gap: 14px; text-align: center; }
}

@media (max-width: 359px){
  .hero-title{ font-size: 2.15rem; }
}

/* ==========================================================================
   Cookie consent modal
   ========================================================================== */

/* Quiet dismiss action — not a bordered secondary button (the system has
   none), just underlined text at the same tap-target size as a .btn. */
.btn-text{
  background: transparent;
  color: var(--text-dim);
}
.btn-text:hover, .btn-text:focus-visible{ color: var(--text); text-decoration: underline; }

.cookie-overlay[hidden]{ display: none; }
.cookie-overlay{
  position: fixed;
  inset: 0;
  z-index: 500;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  background: rgba(6, 4, 2, 0.72);
  backdrop-filter: blur(6px);
}

.cookie-modal{
  max-width: 420px;
  width: 100%;
  padding: 28px 26px;
  border-radius: 18px;
  background: var(--panel);
  border: 1px solid var(--border-strong);
  box-shadow: 0 30px 70px -20px rgba(0,0,0,0.7);
  text-align: center;
}
.cookie-modal-title{
  margin: 0 0 10px;
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 500;
  color: var(--text);
}
.cookie-modal p{
  margin: 0;
  font-size: 14px;
  line-height: 1.6;
  color: var(--text-dim);
}
.cookie-modal p a{ color: var(--amber); text-decoration: underline; text-underline-offset: 2px; }
.cookie-modal p a:hover{ color: var(--amber-bright); }
.cookie-modal-actions{
  display: flex;
  justify-content: center;
  gap: 10px;
  margin-top: 22px;
}
.cookie-modal .btn{ padding: 10px 24px; font-size: 13px; }

@media (max-width: 480px){
  .cookie-modal-actions{ flex-direction: column-reverse; }
  .cookie-modal .btn{ width: 100%; }
}
