/* ─────────────────────────────────────────────────────────────
   Dalmanutha
   Palette is SAMPLED from the supplied artwork, not guessed:
   paper #FCF8F4 and ink #0D3829 are the logo's own two colours,
   #0E2528 is the dark plate's dominant tone. Keeping the site on
   the artwork's exact values is what lets the keyed line drawings
   sit full-bleed with no visible seam.
   ───────────────────────────────────────────────────────────── */

@font-face {
  font-family: 'Newsreader';
  src: url('/assets/fonts/newsreader.woff2') format('woff2-variations');
  font-weight: 200 700;
  font-display: swap;
}
@font-face {
  font-family: 'InterVar';
  src: url('/assets/fonts/inter.woff2') format('woff2-variations');
  font-weight: 100 900;
  font-display: swap;
}

:root {
  --paper:   #FCF8F4;
  --paper-2: #F6F1EA;
  --ink:     #0D3829;
  --deep:    #0E2528;
  /* ⚠️ The artwork's own line colour is #96A195, and that is what this started
     as — but every use of this token is TEXT (labels, captions, meta), and
     #96A195 measures 2.54:1 on --paper, well under AA. Darkened along the same
     hue to 5.02:1. Borders and rules use --hair, so nothing decorative changed. */
  --sage:    #646D63;
  --muted:   #4C5B50;   /* body text; measured 6.81:1 on --paper */
  --hair:    rgba(13, 56, 41, .14);
  --hair-2:  rgba(13, 56, 41, .07);

  --serif: 'Newsreader', 'Iowan Old Style', Georgia, serif;
  --sans:  'InterVar', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;

  --wrap: 1120px;
  --pad: 26px;
  --r: 3px;
  --ease: cubic-bezier(.22, .61, .36, 1);
}

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

body {
  margin: 0;
  background: var(--paper);
  color: var(--muted);
  font-family: var(--sans);
  font-size: 15px;
  line-height: 1.68;
  font-feature-settings: 'kern' 1, 'liga' 1;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }

h1, h2, h3, blockquote {
  font-family: var(--serif);
  color: var(--ink);
  font-weight: 300;
  letter-spacing: -.012em;
  line-height: 1.18;
  margin: 0;
  text-wrap: balance;
}
/* Deliberately restrained: the brief asked for small and clean, so the
   display sizes stay close to the body rather than shouting. */
h1 { font-size: clamp(1.95rem, 3.5vw, 2.85rem); line-height: 1.14; }
h2 { font-size: clamp(1.5rem, 2.5vw, 2.05rem); }
h3 { font-size: 1.0625rem; letter-spacing: -.005em; line-height: 1.35; }
p  { margin: 0; }

.wrap { width: 100%; max-width: var(--wrap); margin-inline: auto; padding-inline: var(--pad); }

.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 {
  position: absolute; left: -9999px; top: 0; z-index: 100;
  background: var(--ink); color: var(--paper); padding: 10px 16px; font-size: 13px;
}
.skip:focus { left: 8px; top: 8px; }

:where(a, button, input):focus-visible {
  outline: 2px solid var(--ink);
  outline-offset: 3px;
  border-radius: 2px;
}

/* ── shared type bits ── */
.overline {
  font-size: 10.5px;
  letter-spacing: .19em;
  text-transform: uppercase;
  color: var(--sage);
  /* Tracked text needs padding equal to its tracking, or the trailing space
     after the last letter drags the optical centre left. */
  padding-left: .19em;
  margin-bottom: 18px;
}
.lede {
  max-width: 54ch;
  font-size: 15.5px;
  line-height: 1.72;
  margin-top: 20px;
}
.fineprint { font-size: 11.5px; color: var(--sage); margin-top: 22px; letter-spacing: .01em; }

/* ── buttons ── */
.btn {
  --bg: var(--ink);
  display: inline-flex; align-items: center; gap: .5em;
  background: var(--bg); color: var(--paper);
  font-family: var(--sans); font-size: 13px; font-weight: 500; letter-spacing: .01em;
  padding: 11px 20px; border: 1px solid var(--bg); border-radius: 100px;
  text-decoration: none; cursor: pointer; white-space: nowrap;
  transition: background .3s var(--ease), color .3s var(--ease), transform .3s var(--ease);
}
.btn:hover { background: #0A2C20; transform: translateY(-1px); }
.btn:active { transform: translateY(0); }
.btn-sm { padding: 8px 15px; font-size: 12.5px; }
.btn-ghost {
  background: transparent; color: var(--ink); border-color: var(--hair);
}
.btn-ghost:hover { background: transparent; border-color: var(--ink); }
.arrow { transition: transform .3s var(--ease); }
.btn-ghost:hover .arrow { transform: translateX(3px); }

/* ── nav ── */
.nav {
  position: fixed; inset: 0 0 auto 0; z-index: 50;
  transition: background .35s var(--ease), border-color .35s var(--ease), backdrop-filter .35s;
  border-bottom: 1px solid transparent;
}
.nav.is-stuck {
  background: rgba(252, 248, 244, .84);
  backdrop-filter: blur(12px) saturate(1.1);
  border-bottom-color: var(--hair-2);
}
.nav-in { display: flex; align-items: center; gap: 22px; height: 68px; }
.brand {
  display: inline-flex; align-items: center; gap: 9px;
  text-decoration: none; margin-right: auto;
}
/* The arch mark is portrait (0.65:1), so it is sized by HEIGHT and the width
   follows. Fixing both to a square letterboxed it and shrank the drawing. */
.brand-mark { width: auto; height: 34px; }
.foot .brand-mark { height: 31px; }
.brand-word {
  font-family: var(--serif); font-size: 17px; font-weight: 400;
  color: var(--ink); letter-spacing: .015em;
  /* `align-items:center` centres the LINE BOX, and "Dalmanutha" is all
     ascenders with no descender, so its ink sits high inside that box and
     reads ~3px above the mark's optical centre. Measured, not guessed: the
     ink centres were 3px apart at 17px and 2px at 15px, i.e. ~0.16em, so it
     is expressed in em and stays correct at both sizes. */
  transform: translateY(.16em);
}
.nav-links { display: flex; gap: 26px; }
.nav-links a {
  font-size: 13px; color: var(--muted); text-decoration: none;
  position: relative; transition: color .25s var(--ease);
}
.nav-links a::after {
  content: ''; position: absolute; left: 0; right: 100%; bottom: -4px;
  height: 1px; background: var(--ink); transition: right .35s var(--ease);
}
.nav-links a:hover { color: var(--ink); }
.nav-links a:hover::after { right: 0; }

.nav-toggle {
  display: none; width: 42px; height: 42px; padding: 0;
  background: none; border: 0; cursor: pointer;
  flex-direction: column; align-items: center; justify-content: center; gap: 5px;
}
.nav-toggle span {
  display: block; width: 18px; height: 1px; background: var(--ink);
  transition: transform .3s var(--ease), opacity .3s var(--ease);
}
.nav-toggle[aria-expanded="true"] span:first-child { transform: translateY(3px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:last-child { transform: translateY(-3px) rotate(-45deg); }

.nav-menu {
  background: rgba(252, 248, 244, .97);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--hair-2);
  padding: 6px var(--pad) 14px;
}
.nav-menu a {
  display: block; padding: 13px 0; font-size: 14px; color: var(--ink);
  text-decoration: none; border-bottom: 1px solid var(--hair-2);
}
.nav-menu a:last-child { border-bottom: 0; }

/* ── scenes (the keyed line art) ── */
.scene {
  position: absolute; inset: 0;
  background-repeat: no-repeat;
  background-position: center bottom;
  background-size: cover;
  pointer-events: none;
  will-change: transform;
}
/* Scene choice is driven by where each drawing leaves its open space.
   background-2 is open on the LEFT (its arch sits right), which is where the
   left-aligned hero copy lands; background-1 is the mirror of it and would put
   the arch and agave straight through the headline. */
.scene-hero { background-image: url('/assets/img/scene-2.webp'); opacity: .88; }
.scene-2 {
  background-image: url('/assets/img/scene-1.webp');
  opacity: .34;
  background-position: center bottom;
}
.scene-dark { background-image: url('/assets/img/scene-dark.webp'); opacity: 1; }

/* ── hero ── */
.hero {
  position: relative; overflow: hidden;
  padding: 168px 0 108px;
  display: flex; align-items: center;
  min-height: min(86vh, 780px);
}
.hero-in { position: relative; z-index: 2; }
.hero h1 { margin-top: 4px; }
/* A wash, not a scrim: the drawing keeps its full strength on the open right
   side and only fades where type sits on top of it. A flat overlay across the
   whole scene would grey out the artwork to fix a problem that is local. */
.hero::before {
  content: ''; position: absolute; inset: 0; z-index: 1; pointer-events: none;
  background: linear-gradient(100deg,
    var(--paper) 0%, rgba(252, 248, 244, .92) 34%, rgba(252, 248, 244, .55) 52%, rgba(252, 248, 244, 0) 72%);
}
.hero-fade {
  position: absolute; inset: auto 0 0 0; height: 160px;
  background: linear-gradient(to bottom, rgba(252, 248, 244, 0), var(--paper));
  z-index: 1;
}
.cta-row { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 34px; }

/* ── bands ── */
.band { position: relative; padding: 104px 0; overflow: hidden; }
.band-alt { background: var(--paper-2); }
.band-tight { padding: 92px 0 104px; }
.band .wrap { position: relative; z-index: 2; }

/* ── premise columns ── */
.cols {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 40px;
  margin-top: 56px;
}
.col { border-top: 1px solid var(--hair); padding-top: 20px; }
.col-n {
  font-size: 10.5px; letter-spacing: .16em; color: var(--sage);
  display: block; margin-bottom: 12px;
}
.col h3 { margin-bottom: 9px; }
.col p { font-size: 14px; }

/* ── stepper ── */
.stepper { margin-top: 48px; }
.steps { display: flex; gap: 0; border-bottom: 1px solid var(--hair); }
.step {
  appearance: none; background: none; border: 0; cursor: pointer;
  font-family: var(--sans); text-align: left;
  padding: 0 30px 16px 0; margin-bottom: -1px;
  border-bottom: 1px solid transparent;
  color: var(--sage);
  transition: color .28s var(--ease), border-color .28s var(--ease);
}
.step:hover { color: var(--muted); }
.step.is-on { color: var(--ink); border-bottom-color: var(--ink); }
.step-n { display: block; font-size: 10.5px; letter-spacing: .16em; margin-bottom: 5px; }
.step-t { font-family: var(--serif); font-size: 1.0625rem; font-weight: 400; }

.panels { margin-top: 40px; }
.panel {
  display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: start;
  animation: panel-in .5s var(--ease) both;
}
/* ⚠️ `display` on the class beats the UA sheet's `[hidden]{display:none}`, so
   without this every panel renders at once and the tabs do nothing. */
.panel[hidden] { display: none; }
@keyframes panel-in { from { opacity: 0; transform: translateY(8px); } }
@media (prefers-reduced-motion: reduce) { .panel { animation: none; } }
.panel-copy h3 { margin-bottom: 12px; }
.panel-copy p { font-size: 14.5px; max-width: 46ch; }
.ticks { list-style: none; margin: 22px 0 0; padding: 0; }
.ticks li {
  position: relative; padding-left: 20px; font-size: 13.5px;
  padding-bottom: 9px; margin-bottom: 9px; border-bottom: 1px solid var(--hair-2);
}
.ticks li:last-child { border-bottom: 0; }
.ticks li::before {
  content: ''; position: absolute; left: 0; top: .62em;
  width: 7px; height: 7px; border: 1px solid var(--ink); border-radius: 50%;
}

/* ── illustrative cards ── */
.card {
  background: rgba(252, 248, 244, .72);
  border: 1px solid var(--hair);
  border-radius: var(--r);
  padding: 18px;
  backdrop-filter: blur(4px);
}
.card-head {
  display: flex; align-items: center; gap: 8px;
  font-size: 10.5px; letter-spacing: .16em; text-transform: uppercase;
  color: var(--sage); padding-bottom: 14px; margin-bottom: 6px;
  border-bottom: 1px solid var(--hair-2);
}
.dot { width: 5px; height: 5px; border-radius: 50%; background: var(--ink); opacity: .5; }
.rows { display: flex; flex-direction: column; }
.row {
  display: grid; grid-template-columns: 1fr auto auto; gap: 12px; align-items: center;
  padding: 11px 0; border-bottom: 1px solid var(--hair-2); font-size: 13px;
}
.row:last-child { border-bottom: 0; }
.row.is-dim { opacity: .45; }
.row-a { color: var(--ink); }
.row-m { color: var(--sage); font-size: 11.5px; font-variant-numeric: tabular-nums; }
.tag {
  font-size: 10px; letter-spacing: .1em; text-transform: uppercase;
  border: 1px solid var(--hair); border-radius: 100px; padding: 2px 8px; color: var(--ink);
}
.tag-q { color: var(--sage); }

.meters { display: flex; flex-direction: column; gap: 15px; padding-top: 8px; }
.meter span { display: block; font-size: 12px; margin-bottom: 7px; }
.meter i {
  display: block; height: 2px; background: var(--hair); position: relative;
}
.meter i::after {
  content: ''; position: absolute; inset: 0 auto 0 0; width: var(--v);
  background: var(--ink);
  transform-origin: left; transform: scaleX(0);
  animation: meter 1.1s var(--ease) forwards;
}
@keyframes meter { to { transform: scaleX(1); } }
@media (prefers-reduced-motion: reduce) { .meter i::after { animation: none; transform: scaleX(1); } }

.verdict { padding: 14px 0 16px; border-bottom: 1px solid var(--hair-2); }
.verdict-k { display: block; font-size: 10.5px; letter-spacing: .16em; text-transform: uppercase; color: var(--sage); margin-bottom: 6px; }
.verdict-v { font-family: var(--serif); font-size: 1.25rem; color: var(--ink); }
.ev { padding-top: 12px; }
.ev-row { display: flex; justify-content: space-between; font-size: 12.5px; padding: 7px 0; }
.ev-row b { color: var(--ink); font-weight: 500; font-variant-numeric: tabular-nums; }

/* ── capabilities grid ── */
.grid {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 1px; background: var(--hair);
  border: 1px solid var(--hair); margin-top: 52px;
}
.cell { background: var(--paper); padding: 28px 26px 30px; }
.cell h3 { margin-bottom: 8px; }
.cell p { font-size: 13.5px; }

/* ── dark statement ── */
.dark {
  position: relative; overflow: hidden;
  background: var(--deep);
  padding: 116px 0;
  color: rgba(246, 241, 234, .78);
}
.dark-in { position: relative; z-index: 2; max-width: 760px; }
/* Light enough to read the quote over, light enough to still see the painting.
   At .92 the artwork was effectively deleted. */
.dark::after {
  content: ''; position: absolute; inset: 0; z-index: 1;
  background: linear-gradient(96deg, rgba(14, 37, 40, .82) 0%, rgba(14, 37, 40, .58) 48%, rgba(14, 37, 40, .12) 100%);
}
.dark blockquote {
  margin: 0; font-size: clamp(1.35rem, 2.5vw, 1.95rem);
  color: #F3EEE6; line-height: 1.3;
}
.dark-sub { margin-top: 24px; font-size: 14.5px; max-width: 48ch; }

/* ── waitlist ── */
.wl { max-width: 620px; }
.wl-form {
  display: flex; gap: 10px; margin-top: 30px; flex-wrap: wrap;
}
.wl-form input {
  flex: 1 1 260px; min-width: 0;
  font-family: var(--sans); font-size: 15px; color: var(--ink);
  background: transparent;
  border: 1px solid var(--hair); border-radius: 100px;
  padding: 11px 18px;
  transition: border-color .25s var(--ease);
}
.wl-form input::placeholder { color: var(--sage); }
.wl-form input:hover { border-color: rgba(13, 56, 41, .3); }
.wl-form input:focus { outline: none; border-color: var(--ink); }
.wl-form.is-bad input { border-color: #9C4B36; }
/* Honeypot. Moved off-screen rather than display:none, because the simplest
   bots skip fields that are display:none but happily fill this one. */
.hp {
  position: absolute; left: -9999px; top: auto;
  width: 1px; height: 1px; overflow: hidden;
}
.wl-msg {
  min-height: 20px; margin-top: 14px; font-size: 13px; color: var(--sage);
  opacity: 0; transform: translateY(-3px);
  transition: opacity .3s var(--ease), transform .3s var(--ease);
}
.wl-msg.is-on { opacity: 1; transform: none; }
.wl-msg.is-bad { color: #9C4B36; }
.wl-msg a { color: var(--ink); }

/* ── footer ── */
.foot { border-top: 1px solid var(--hair); padding: 34px 0 40px; }
.foot-in { display: flex; align-items: center; gap: 20px; flex-wrap: wrap; }
.foot .brand { margin-right: auto; }
.foot .brand-word { font-size: 15px; }
.foot-links { display: flex; gap: 20px; }
.foot-links a { font-size: 13px; text-decoration: none; color: var(--muted); }
.foot-links a:hover { color: var(--ink); }
.foot-c { font-size: 12px; color: var(--sage); }

/* ── reveals ── */
.reveal {
  opacity: 0; transform: translateY(14px);
  transition: opacity .7s var(--ease), transform .7s var(--ease);
  transition-delay: calc(var(--d, 0) * 70ms);
}
.reveal.is-in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
}

/* ── responsive ── */
@media (max-width: 900px) {
  .panel { grid-template-columns: 1fr; gap: 32px; }
  .grid { grid-template-columns: repeat(2, 1fr); }
  .cols { gap: 30px; }
}
@media (max-width: 760px) {
  :root { --pad: 20px; }
  .nav-links, .nav .btn-sm { display: none; }
  .nav-toggle { display: flex; }
  .hero { padding: 132px 0 84px; min-height: 0; }
  .band { padding: 76px 0; }
  .dark { padding: 88px 0; }
  .cols, .grid { grid-template-columns: 1fr; }
  .grid { border-left: 0; border-right: 0; }
  .steps { overflow-x: auto; scrollbar-width: none; }
  .steps::-webkit-scrollbar { display: none; }
  .step { padding-right: 24px; }
  .scene-hero { opacity: .7; background-size: 168% auto; background-position: 62% bottom; }
  /* A 16px minimum stops iOS Safari zooming the page on focus. */
  .wl-form input { font-size: 16px; }
}
