/* ==========================================================================
   trevazo — "CONTOUR" design system
   Bone & ink editorial · dark shader hero · tidal-gauge / topographic motif
   Fonts: Instrument Serif (display) · Instrument Sans (body) · IBM Plex Mono
   ========================================================================== */

:root {
  --bone: #f2ede1;
  --bone-2: #e9e1cd;
  --ink: #16130c;
  --ink-deep: #0e0c07;
  --signal: #f04e12;
  --signal-soft: rgba(240, 78, 18, 0.12);
  --muted: #5d5545;
  --muted-on-dark: #a89f8c;
  --line: rgba(22, 19, 12, 0.18);
  --line-strong: rgba(22, 19, 12, 0.85);
  --line-on-dark: rgba(242, 237, 225, 0.22);
  --serif: "Instrument Serif", Georgia, serif;
  --sans: "Instrument Sans", "Helvetica Neue", Arial, sans-serif;
  --mono: "IBM Plex Mono", "SFMono-Regular", Consolas, monospace;
  --wrap: 1240px;
  --ease-out: cubic-bezier(0.19, 1, 0.22, 1);
  --ease-snap: cubic-bezier(0.65, 0, 0.35, 1);
  /* hand-drawn-feel topographic contour rings (data-URI SVG) */
  --contour-bg: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 400 400'%3E%3Cg fill='none' stroke='rgba(22,19,12,0.30)' stroke-width='1'%3E%3Cpath d='M200 40 C290 42 360 108 358 198 C356 292 288 358 198 356 C112 354 44 290 42 200 C40 112 110 38 200 40 Z'/%3E%3Cpath d='M200 82 C272 84 320 132 318 200 C316 270 268 316 198 314 C132 312 84 266 82 198 C80 134 130 80 200 82 Z'/%3E%3Cpath d='M200 124 C250 126 280 158 278 202 C276 248 248 276 200 274 C154 272 124 244 122 198 C120 156 152 122 200 124 Z'/%3E%3Cpath d='M200 164 C230 166 242 180 240 202 C238 226 226 238 200 236 C176 234 162 222 160 200 C158 180 172 162 200 164 Z'/%3E%3C/g%3E%3Ccircle cx='200' cy='200' r='5' fill='rgba(240,78,18,0.85)'/%3E%3C/svg%3E");
  --contour-bg-dark: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 400 400'%3E%3Cg fill='none' stroke='rgba(242,237,225,0.28)' stroke-width='1'%3E%3Cpath d='M200 40 C290 42 360 108 358 198 C356 292 288 358 198 356 C112 354 44 290 42 200 C40 112 110 38 200 40 Z'/%3E%3Cpath d='M200 82 C272 84 320 132 318 200 C316 270 268 316 198 314 C132 312 84 266 82 198 C80 134 130 80 200 82 Z'/%3E%3Cpath d='M200 124 C250 126 280 158 278 202 C276 248 248 276 200 274 C154 272 124 244 122 198 C120 156 152 122 200 124 Z'/%3E%3Cpath d='M200 164 C230 166 242 180 240 202 C238 226 226 238 200 236 C176 234 162 222 160 200 C158 180 172 162 200 164 Z'/%3E%3C/g%3E%3Ccircle cx='200' cy='200' r='5' fill='rgba(240,78,18,0.9)'/%3E%3C/svg%3E");
}

/* ---------- reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body {
  font-family: var(--sans);
  font-size: 1.0625rem;
  line-height: 1.6;
  color: var(--ink);
  background: var(--bone);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
img, svg, canvas { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
ul, ol { padding: 0; list-style: none; }
::selection { background: var(--signal); color: var(--bone); }

.wrap { width: min(var(--wrap), calc(100% - 3rem)); margin-inline: auto; }
.wrap-narrow { width: min(880px, calc(100% - 3rem)); }
.visually-hidden {
  position: absolute; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap;
}
.center { text-align: center; }

/* ---------- custom cursor (pointer: fine only, JS-gated) ---------- */
.cursor { display: none; }
html.has-cursor, html.has-cursor a, html.has-cursor button,
html.has-cursor summary, html.has-cursor label { cursor: none; }
html.has-cursor input, html.has-cursor textarea { cursor: text; }
html.has-cursor .cursor {
  display: block; position: fixed; inset: 0; pointer-events: none; z-index: 9999;
}
.cursor-dot, .cursor-ring {
  position: absolute; top: 0; left: 0; border-radius: 50%;
  transform: translate(-100px, -100px);
}
.cursor-dot { width: 8px; height: 8px; background: var(--signal); }
.cursor-ring {
  width: 34px; height: 34px; border: 1px solid var(--signal);
  opacity: 0.65; transition: width 0.25s var(--ease-out), height 0.25s var(--ease-out),
    opacity 0.25s, border-color 0.25s;
}
.cursor.is-hover .cursor-ring { width: 56px; height: 56px; opacity: 1; }
.cursor.is-down .cursor-ring { width: 24px; height: 24px; }

/* ---------- scroll progress ---------- */
.scroll-progress {
  position: fixed; top: 0; left: 0; height: 2px; width: 0;
  background: var(--signal); z-index: 1200;
}

/* ---------- language suggestion banner ---------- */
.lang-banner {
  position: fixed; bottom: 1rem; left: 50%; transform: translateX(-50%);
  z-index: 1100; display: flex; align-items: center; gap: 1rem;
  background: var(--ink); color: var(--bone);
  border: 1px solid var(--ink); padding: 0.7rem 1.1rem;
  font-family: var(--mono); font-size: 0.78rem; letter-spacing: 0.02em;
  box-shadow: 6px 6px 0 rgba(22, 19, 12, 0.18);
  max-width: calc(100vw - 2rem);
}
.lang-banner-link { color: var(--signal); text-decoration: underline; text-underline-offset: 3px; }
.lang-banner-close { color: var(--muted-on-dark); font-size: 1.1rem; line-height: 1; padding: 0 0.2rem; }
.lang-banner-close:hover { color: var(--bone); }
.lang-banner.is-hidden { display: none; }

/* ==========================================================================
   HEADER
   ========================================================================== */
.site-header {
  position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
  transition: background 0.45s var(--ease-out), color 0.45s, border-color 0.45s,
    transform 0.5s var(--ease-out);
  border-bottom: 1px solid transparent;
  color: var(--ink);
}
body.is-home .site-header:not(.is-scrolled) { color: var(--bone); }
.site-header.is-scrolled {
  background: rgba(242, 237, 225, 0.88);
  -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px);
  border-bottom-color: var(--line);
  color: var(--ink);
}
.header-inner {
  display: flex; align-items: center; justify-content: space-between;
  gap: 2rem; padding-block: 0.9rem;
}
.brand { display: inline-flex; align-items: center; gap: 0.65rem; }
.brand-mark { display: grid; place-items: center; }
.brand-name {
  font-family: var(--serif); font-size: 1.5rem; letter-spacing: 0.01em;
  line-height: 1;
}
.site-nav { display: flex; align-items: center; gap: 2rem; }
.site-nav > a {
  font-family: var(--mono); font-size: 0.8rem; letter-spacing: 0.14em;
  text-transform: uppercase; position: relative; padding-block: 0.3rem;
}
.site-nav > a::after {
  content: ""; position: absolute; left: 0; bottom: 0; height: 1px; width: 100%;
  background: currentColor; transform: scaleX(0); transform-origin: right;
  transition: transform 0.4s var(--ease-out);
}
.site-nav > a:hover::after, .site-nav > a.is-active::after { transform: scaleX(1); transform-origin: left; }
.site-nav > a.nav-cta {
  border: 1px solid currentColor; padding: 0.45rem 1rem;
  transition: background 0.3s, color 0.3s, border-color 0.3s;
}
.site-nav > a.nav-cta::after { display: none; }
.site-nav > a.nav-cta:hover, .site-nav > a.nav-cta.is-active {
  background: var(--signal); border-color: var(--signal); color: var(--ink-deep);
}
body.is-home .site-header:not(.is-scrolled) .site-nav > a.nav-cta:hover,
body.is-home .site-header:not(.is-scrolled) .site-nav > a.nav-cta.is-active { color: var(--bone); }
.lang-switch { display: flex; gap: 0.15rem; }
.lang-switch a {
  font-family: var(--mono); font-size: 0.68rem; letter-spacing: 0.08em;
  padding: 0.3rem 0.45rem; opacity: 0.55;
  transition: opacity 0.25s, color 0.25s;
}
.lang-switch a:hover { opacity: 1; }
.lang-switch a.is-active { opacity: 1; color: var(--signal); }
.nav-toggle { display: none; }

@media (max-width: 900px) {
  .nav-toggle {
    display: block; position: relative; z-index: 1002;
    width: 42px; height: 42px;
  }
  .nav-toggle-bars, .nav-toggle-bars::before, .nav-toggle-bars::after {
    position: absolute; left: 8px; width: 26px; height: 1.5px;
    background: currentColor; transition: transform 0.35s var(--ease-snap), opacity 0.25s;
  }
  .nav-toggle-bars { top: 50%; }
  .nav-toggle-bars::before, .nav-toggle-bars::after { content: ""; left: 0; }
  .nav-toggle-bars::before { transform: translateY(-7px); }
  .nav-toggle-bars::after { transform: translateY(7px); }
  .nav-toggle[aria-expanded="true"] .nav-toggle-bars { background: transparent; }
  .nav-toggle[aria-expanded="true"] .nav-toggle-bars::before { transform: rotate(45deg); }
  .nav-toggle[aria-expanded="true"] .nav-toggle-bars::after { transform: rotate(-45deg); }
  .site-nav {
    position: fixed; inset: 0; z-index: 1001;
    flex-direction: column; justify-content: center; gap: 1.6rem;
    background: var(--ink-deep); color: var(--bone);
    opacity: 0; visibility: hidden; transform: translateY(-1.5%);
    transition: opacity 0.4s var(--ease-out), transform 0.4s var(--ease-out), visibility 0.4s;
  }
  .site-nav.is-open { opacity: 1; visibility: visible; transform: none; }
  .site-nav > a { font-size: 1.5rem; font-family: var(--serif); text-transform: none; letter-spacing: 0; }
  .site-nav > a.nav-cta { padding: 0.6rem 1.6rem; font-size: 1.1rem; }
  .lang-switch { margin-top: 1rem; }
  .lang-switch a { font-size: 0.85rem; opacity: 0.7; }
}

/* ==========================================================================
   HERO — dark shader field
   ========================================================================== */
.hero {
  position: relative; min-height: 100svh;
  display: flex; flex-direction: column; justify-content: center;
  background: var(--ink-deep); color: var(--bone);
  overflow: hidden; padding: 8.5rem 0 7rem;
  isolation: isolate;
}
.hero-gl, .hero-fallback {
  position: absolute; inset: 0; width: 100%; height: 100%; z-index: -2;
}
.hero-fallback {
  background:
    radial-gradient(90% 70% at 78% 30%, rgba(240, 78, 18, 0.16), transparent 60%),
    radial-gradient(70% 90% at 15% 80%, rgba(240, 78, 18, 0.08), transparent 55%),
    linear-gradient(180deg, #12100a 0%, var(--ink-deep) 70%);
  opacity: 0; transition: opacity 0.6s;
}
.hero.no-gl .hero-fallback, .hero.reduced .hero-fallback { opacity: 1; }
.hero.no-gl .hero-gl, .hero.reduced .hero-gl { display: none; }
.hero-fallback svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.hero-fallback path { fill: none; stroke: rgba(242, 237, 225, 0.14); stroke-width: 1; }

.hero-inner { position: relative; z-index: 2; }
.kicker {
  display: inline-flex; align-items: center; gap: 0.7rem;
  font-family: var(--mono); font-size: 0.75rem; letter-spacing: 0.22em;
  text-transform: uppercase; color: var(--signal);
}
.kicker-tick {
  display: inline-block; width: 2.6rem; height: 10px; flex: none;
  background:
    repeating-linear-gradient(90deg, currentColor 0 1px, transparent 1px 7px);
  -webkit-mask: linear-gradient(90deg, #000 70%, transparent);
  mask: linear-gradient(90deg, #000 70%, transparent);
  opacity: 0.9;
}
.hero-title {
  font-family: var(--serif); font-weight: 400;
  font-size: clamp(3rem, 8.6vw, 7.6rem);
  line-height: 0.98; letter-spacing: -0.015em;
  margin: 1.6rem 0 2.2rem; max-width: 14ch;
}
.ht-pre, .ht-post { display: block; }
.ht-post { color: var(--muted-on-dark); font-size: 0.52em; line-height: 1.15; margin-top: 0.5em; max-width: 30ch; }
.ht-mark { display: block; font-style: italic; color: var(--signal); }

/* word reveal (JS-split) */
.wreveal .w { display: inline-block; overflow: hidden; vertical-align: bottom; }
.wreveal .wi {
  display: inline-block; transform: translateY(115%);
  transition: transform 0.9s var(--ease-out);
}
.wreveal.is-visible .wi { transform: none; }

.hero-answer {
  max-width: 46rem; border-left: 2px solid var(--signal);
  padding: 0.4rem 0 0.4rem 1.4rem; margin-bottom: 1.6rem;
  background: linear-gradient(90deg, rgba(240, 78, 18, 0.07), transparent 70%);
}
.hero-answer-tag {
  display: block; font-family: var(--mono); font-size: 0.72rem;
  letter-spacing: 0.24em; text-transform: uppercase; color: var(--signal);
  margin-bottom: 0.5rem;
}
.hero-answer p { font-size: 1.06rem; line-height: 1.65; color: #ddd6c6; }
.hero-lead { max-width: 38rem; color: var(--muted-on-dark); margin-bottom: 2.4rem; }

.hero-actions { display: flex; flex-wrap: wrap; gap: 1rem; margin-bottom: 3.4rem; }

/* ---------- buttons ---------- */
.btn {
  position: relative; display: inline-flex; align-items: center; gap: 0.8rem;
  font-family: var(--mono); font-size: 0.82rem; letter-spacing: 0.14em;
  text-transform: uppercase; padding: 1.05rem 1.9rem;
  border: 1px solid var(--line-strong); overflow: hidden;
  transition: color 0.35s var(--ease-out), border-color 0.35s;
  will-change: transform;
}
.btn span { position: relative; z-index: 1; }
.btn::before {
  content: ""; position: absolute; inset: 0; background: var(--signal);
  transform: translateY(101%); transition: transform 0.45s var(--ease-snap);
}
.btn:hover::before { transform: translateY(0); }
.btn-primary { background: var(--signal); border-color: var(--signal); color: var(--ink-deep); }
.btn-primary::before { background: var(--bone); }
.hero .btn-primary::before { background: var(--bone); }
.btn-primary:hover { color: var(--ink); border-color: var(--bone); }
.btn-ghost { color: inherit; border-color: currentColor; }
.btn-ghost:hover { color: var(--ink-deep); border-color: var(--signal); }
.btn-lg { padding: 1.25rem 2.4rem; font-size: 0.9rem; }
.btn-block { width: 100%; justify-content: center; }
.btn .btn-arrow { font-family: var(--sans); transition: transform 0.35s var(--ease-out); }
.btn:hover .btn-arrow { transform: translateX(5px); }

.hero-stats {
  display: grid; grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 2rem; max-width: 56rem;
  border-top: 1px solid var(--line-on-dark); padding-top: 1.8rem;
}
.hero-stat dd {
  font-family: var(--serif); font-size: clamp(2.2rem, 3.6vw, 3.4rem);
  line-height: 1; color: var(--bone);
}
.hero-stat dd .count { font-variant-numeric: tabular-nums; }
.hero-stat dt {
  font-family: var(--mono); font-size: 0.72rem; letter-spacing: 0.12em;
  text-transform: uppercase; color: var(--muted-on-dark); margin-top: 0.5rem;
}

/* hero vertical text + gauge + scroll cue */
.hero-vtext {
  position: absolute; right: 1.6rem; top: 50%; transform: translateY(-50%);
  writing-mode: vertical-rl; font-family: var(--mono); font-size: 0.68rem;
  letter-spacing: 0.34em; text-transform: uppercase; color: var(--muted-on-dark);
  opacity: 0.7; z-index: 2;
}
.hero-gauge {
  position: absolute; left: 0; right: 0; bottom: 0; height: 44px; z-index: 2;
  pointer-events: none; opacity: 0.85;
}
.hero-gauge svg { width: 100%; height: 100%; }
.hero-gauge line { stroke: rgba(242, 237, 225, 0.4); stroke-width: 1; }
.hero-gauge line.major { stroke: var(--signal); }

@media (max-width: 900px) {
  .hero-vtext { display: none; }
  .hero-stats { grid-template-columns: repeat(2, 1fr); }
}

/* ==========================================================================
   MARQUEE
   ========================================================================== */
.marquee {
  position: relative; z-index: 3;
  background: var(--signal); color: var(--ink-deep);
  transform: rotate(-1.4deg) scale(1.02);
  margin-block: -1.6rem 4.5rem;
  border-block: 1px solid var(--ink-deep);
  overflow: hidden; padding-block: 0.85rem;
}
.marquee-track {
  display: flex; gap: 3rem; width: max-content;
  animation: marquee 26s linear infinite;
}
.marquee-track span {
  font-family: var(--mono); font-size: 0.85rem; letter-spacing: 0.22em;
  text-transform: uppercase; white-space: nowrap;
  display: inline-flex; align-items: center; gap: 3rem;
}
.marquee-track span::after { content: "◦"; font-size: 1rem; }
@keyframes marquee { to { transform: translateX(-50%); } }
@media (prefers-reduced-motion: reduce) {
  .marquee-track { animation: none; }
}

/* ==========================================================================
   GENERIC SECTIONS
   ========================================================================== */
.section { position: relative; padding-block: clamp(4.5rem, 9vw, 8rem); }
.section-dark { background: var(--ink-deep); color: var(--bone); }

.section-head { max-width: 52rem; margin-bottom: clamp(2.5rem, 5vw, 4.5rem); }
.section-head h2, .subhero h1, .cta-panel h2 {
  font-family: var(--serif); font-weight: 400;
  font-size: clamp(2.4rem, 5vw, 4.2rem); line-height: 1.04;
  letter-spacing: -0.01em; margin: 1.2rem 0 1.1rem;
}
.section-lead { color: var(--muted); font-size: 1.12rem; max-width: 44rem; }
.section-dark .section-lead { color: var(--muted-on-dark); }
.section-head .vlabel {
  position: absolute; right: 0; top: 0.5rem;
  writing-mode: vertical-rl; font-family: var(--mono); font-size: 0.66rem;
  letter-spacing: 0.3em; text-transform: uppercase; color: var(--muted);
}

/* generic reveal (JS-gated so no-JS stays visible) */
.js .reveal { opacity: 0; transform: translateY(2.2rem); transition: opacity 0.9s var(--ease-out), transform 0.9s var(--ease-out); }
.js .reveal.is-visible { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .js .reveal { opacity: 1; transform: none; transition: none; }
  .js .wreveal .wi { transform: none; transition: none; }
}

/* ---------- facts (overlaps the hero) ---------- */
.facts-section { padding-top: 0; margin-top: -5.5rem; z-index: 4; }
.facts-panel {
  position: relative; background: var(--bone);
  border: 1px solid var(--line-strong);
  padding: clamp(1.8rem, 4vw, 3.2rem);
  box-shadow: 10px 10px 0 rgba(22, 19, 12, 0.9);
  overflow: hidden;
}
.facts-panel::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background-image: var(--contour-bg, none);
  background-repeat: no-repeat; background-position: right -60px top -40px;
  background-size: 480px; opacity: 0.5;
}
.facts-head { display: flex; align-items: baseline; justify-content: space-between; gap: 1rem; margin-bottom: 1.6rem; }
.facts-title {
  font-family: var(--serif); font-weight: 400;
  font-size: clamp(1.7rem, 3vw, 2.4rem); display: flex; align-items: center; gap: 0.9rem;
}
.gauge-dot {
  width: 0.7em; height: 0.7em; border-radius: 50%;
  background: var(--signal); flex: none;
  box-shadow: 0 0 0 4px var(--signal-soft);
}
.facts-grid {
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0 3rem; position: relative;
}
.fact-row {
  display: flex; align-items: baseline; gap: 1rem;
  padding-block: 0.85rem; border-top: 1px solid var(--line);
}
.fact-row dt {
  font-family: var(--mono); font-size: 0.72rem; letter-spacing: 0.16em;
  text-transform: uppercase; color: var(--signal); flex: none; min-width: 8.5rem;
}
.fact-row dd { font-size: 0.98rem; color: var(--ink); }
@media (max-width: 700px) {
  .facts-grid { grid-template-columns: 1fr; }
  .fact-row dt { min-width: 6.5rem; }
}

/* ---------- agents: broken grid + ghost numerals ---------- */
.agent-grid {
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(1.4rem, 3vw, 2.6rem);
}
.agent-card {
  position: relative; border: 1px solid var(--line-strong);
  background: var(--bone); padding: clamp(1.6rem, 3vw, 2.6rem);
  overflow: hidden;
  transition: transform 0.5s var(--ease-out), box-shadow 0.5s var(--ease-out);
}
.agent-card:hover { transform: translate(-4px, -4px); box-shadow: 8px 8px 0 rgba(22, 19, 12, 0.9); }
.agent-card:nth-child(even) { margin-top: clamp(0rem, 4vw, 3.5rem); }
.agent-ghost {
  position: absolute; top: -0.22em; right: -0.06em;
  font-family: var(--serif); font-style: italic;
  font-size: clamp(7rem, 12vw, 11rem); line-height: 1;
  color: transparent; -webkit-text-stroke: 1px rgba(22, 19, 12, 0.16);
  pointer-events: none; user-select: none;
}
.agent-top {
  display: flex; align-items: center; justify-content: space-between;
  font-family: var(--mono); font-size: 0.72rem; letter-spacing: 0.16em;
  text-transform: uppercase; color: var(--signal);
  border-bottom: 1px solid var(--line); padding-bottom: 0.9rem; margin-bottom: 1.3rem;
}
.agent-card h3 {
  font-family: var(--serif); font-weight: 400;
  font-size: clamp(1.6rem, 2.6vw, 2.1rem); line-height: 1.1; margin-bottom: 0.4rem;
}
.agent-sub { font-family: var(--mono); font-size: 0.8rem; color: var(--muted); letter-spacing: 0.04em; margin-bottom: 1rem; }
.agent-text { font-size: 0.98rem; margin-bottom: 1.3rem; }
.agent-points li {
  position: relative; padding: 0.5rem 0 0.5rem 1.6rem;
  border-top: 1px dashed var(--line); font-size: 0.92rem; color: var(--muted);
}
.agent-points li::before {
  content: ""; position: absolute; left: 0.2rem; top: 1.05rem;
  width: 0.55rem; height: 1px; background: var(--signal);
}
@media (max-width: 800px) {
  .agent-grid { grid-template-columns: 1fr; }
  .agent-card:nth-child(even) { margin-top: 0; }
}

/* ---------- features: numbered editorial rows ---------- */
.feature-list { border-top: 1px solid var(--line-strong); }
.feature-row {
  position: relative; display: grid;
  grid-template-columns: 7rem 1fr 3rem; align-items: start; gap: 1.5rem;
  padding: clamp(1.4rem, 3vw, 2.2rem) 0;
  border-bottom: 1px solid var(--line);
  transition: background 0.35s, padding-left 0.45s var(--ease-out);
}
.feature-row:hover { background: var(--bone-2); padding-left: 1.2rem; }
.feature-row:nth-child(even) .feature-body { margin-left: clamp(0rem, 6vw, 5rem); }
.feature-index {
  font-family: var(--serif); font-style: italic;
  font-size: clamp(2.2rem, 4vw, 3.4rem); line-height: 1; color: var(--signal);
}
.feature-body h3 {
  font-family: var(--serif); font-weight: 400;
  font-size: clamp(1.4rem, 2.4vw, 1.9rem); margin-bottom: 0.4rem;
}
.feature-body p { color: var(--muted); max-width: 46rem; font-size: 0.98rem; }
.feature-tick {
  width: 1.6rem; height: 1.6rem; margin-top: 0.4rem; justify-self: end;
  background:
    linear-gradient(var(--signal), var(--signal)) center/100% 1px no-repeat,
    linear-gradient(var(--signal), var(--signal)) center/1px 100% no-repeat;
  transform: rotate(45deg) scale(0.6); opacity: 0;
  transition: transform 0.4s var(--ease-snap), opacity 0.3s;
}
.feature-row:hover .feature-tick { transform: rotate(0deg) scale(1); opacity: 1; }
@media (max-width: 700px) {
  .feature-row { grid-template-columns: 3.4rem 1fr; }
  .feature-tick { display: none; }
  .feature-row:nth-child(even) .feature-body { margin-left: 0; }
}

/* ---------- steps: tidal-gauge timeline ---------- */
.timeline { position: relative; padding-left: 4.2rem; }
.timeline::before {
  content: ""; position: absolute; left: 1.55rem; top: 0.4rem; bottom: 0.4rem;
  width: 1px; background: var(--line-strong);
}
.timeline::after {
  content: ""; position: absolute; left: 0.95rem; top: 0; bottom: 0; width: 1.2rem;
  background: repeating-linear-gradient(180deg, var(--line) 0 1px, transparent 1px 14px);
  pointer-events: none;
}
.timeline-item { position: relative; padding-block: 1.8rem; }
.timeline-item + .timeline-item { border-top: 1px dashed var(--line); }
.timeline-node {
  position: absolute; left: -4.2rem; top: 1.9rem;
  width: 3.2rem; height: 3.2rem; border-radius: 50%;
  border: 1px solid var(--line-strong); background: var(--bone);
  display: grid; place-items: center;
  font-family: var(--mono); font-size: 0.78rem; letter-spacing: 0.06em;
  color: var(--signal); transition: background 0.35s, color 0.35s;
}
.timeline-item:hover .timeline-node { background: var(--signal); color: var(--ink-deep); border-color: var(--signal); }
.timeline-body h3 {
  font-family: var(--serif); font-weight: 400;
  font-size: clamp(1.5rem, 2.6vw, 2rem); margin-bottom: 0.5rem;
}
.timeline-body p { color: var(--muted); max-width: 42rem; }

/* ---------- app: dark showcase ---------- */
.app-inner {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: clamp(2.5rem, 6vw, 5.5rem); align-items: center;
}
.app-points li {
  display: flex; align-items: baseline; gap: 0.9rem;
  padding-block: 0.7rem; border-top: 1px solid var(--line-on-dark);
  color: #d8d1c0;
}
.app-check {
  flex: none; width: 0.65rem; height: 0.65rem; border-radius: 50%;
  border: 1px solid var(--signal); position: relative; top: -1px;
}
.app-meta {
  margin-top: 1.4rem; font-family: var(--mono); font-size: 0.75rem;
  letter-spacing: 0.16em; text-transform: uppercase; color: var(--signal);
}
.app-visual { position: relative; }
.app-visual::before {
  content: ""; position: absolute; inset: -8% -12%; z-index: -1;
  background-image: var(--contour-bg-dark, none);
  background-repeat: no-repeat; background-position: center; background-size: contain;
  opacity: 0.55; pointer-events: none;
}
.browser {
  border: 1px solid var(--line-on-dark); background: #171410;
  transform: rotate(1.2deg);
  transition: transform 0.6s var(--ease-out);
}
.browser:hover { transform: rotate(0deg); }
.browser-bar {
  display: flex; align-items: center; gap: 0.45rem;
  padding: 0.7rem 0.9rem; border-bottom: 1px solid var(--line-on-dark);
}
.browser-dot { width: 8px; height: 8px; border-radius: 50%; border: 1px solid var(--muted-on-dark); }
.browser-dot:first-child { background: var(--signal); border-color: var(--signal); }
.browser-url {
  margin-left: 0.6rem; font-family: var(--mono); font-size: 0.7rem;
  color: var(--muted-on-dark); letter-spacing: 0.08em;
}
.browser-screen { padding: 1.3rem; background: var(--bone); color: var(--ink); margin: 1.1rem; }
.screen-head {
  display: flex; justify-content: space-between; align-items: baseline;
  border-bottom: 1px solid var(--line-strong); padding-bottom: 0.7rem; margin-bottom: 1.1rem;
}
.screen-brand { font-family: var(--serif); font-size: 1.3rem; }
.screen-week { font-family: var(--mono); font-size: 0.7rem; letter-spacing: 0.18em; text-transform: uppercase; color: var(--signal); }
.screen-bars { margin-bottom: 1.1rem; }
.screen-bars small {
  display: block; margin-top: 0.5rem; font-family: var(--mono);
  font-size: 0.68rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--muted);
}
.s-bar { fill: var(--ink); opacity: 0.85; }
.s-bar-hot { fill: var(--signal); opacity: 1; }
.screen-brief { border: 1px solid var(--line-strong); padding: 0.9rem 1rem; margin-bottom: 1rem; }
.screen-brief small, .screen-lesson small {
  font-family: var(--mono); font-size: 0.66rem; letter-spacing: 0.18em;
  text-transform: uppercase; color: var(--signal); display: block; margin-bottom: 0.35rem;
}
.screen-brief p { font-size: 0.92rem; }
.screen-lesson { display: flex; align-items: center; gap: 0.9rem; }
.screen-lesson i {
  flex: none; width: 2.4rem; height: 2.4rem; border-radius: 50%;
  border: 1px solid var(--line-strong); position: relative;
}
.screen-lesson i::after {
  content: ""; position: absolute; inset: 0; margin: auto;
  width: 0.5rem; height: 0.5rem; background: var(--signal); border-radius: 50%;
}
.screen-lesson b { font-family: var(--serif); font-weight: 400; font-size: 1.05rem; }
@media (max-width: 900px) { .app-inner { grid-template-columns: 1fr; } }

/* ---------- FAQ ---------- */
.faq-list { border-top: 1px solid var(--line-strong); }
.faq-item { border-bottom: 1px solid var(--line); }
.faq-item summary {
  display: flex; align-items: baseline; justify-content: space-between; gap: 1.5rem;
  padding: 1.4rem 0; cursor: pointer; list-style: none;
  font-family: var(--serif); font-size: clamp(1.25rem, 2.2vw, 1.7rem);
  line-height: 1.25; transition: color 0.3s, padding-left 0.4s var(--ease-out);
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary:hover { color: var(--signal); padding-left: 0.8rem; }
.faq-plus {
  flex: none; width: 1.4rem; height: 1.4rem; align-self: center;
  background:
    linear-gradient(var(--signal), var(--signal)) center/100% 1.5px no-repeat,
    linear-gradient(var(--signal), var(--signal)) center/1.5px 100% no-repeat;
  transition: transform 0.4s var(--ease-snap);
}
.faq-item[open] .faq-plus {
  background: linear-gradient(var(--signal), var(--signal)) center/100% 1.5px no-repeat;
  transform: rotate(180deg);
}
.faq-answer { padding: 0 0 1.6rem; max-width: 46rem; color: var(--muted); }

/* ---------- CTA ---------- */
.cta-panel {
  position: relative; overflow: hidden;
  border: 1px solid var(--line-strong); background: var(--bone);
  padding: clamp(3rem, 8vw, 6.5rem) clamp(1.6rem, 6vw, 5rem);
  text-align: center; box-shadow: 12px 12px 0 rgba(22, 19, 12, 0.9);
}
.cta-rings {
  position: absolute; inset: 0; display: grid; place-items: center;
  pointer-events: none;
}
.cta-rings svg { width: min(90%, 620px); opacity: 0.5; }
.cta-rings circle { fill: none; stroke: var(--line); stroke-width: 1; stroke-dasharray: 3 5; }
.cta-panel h2 { position: relative; margin-top: 0; }
.cta-panel p { position: relative; max-width: 36rem; margin: 0 auto 2.2rem; color: var(--muted); }
.cta-panel .btn { position: relative; }

/* ==========================================================================
   SUBPAGES
   ========================================================================== */
.subhero {
  position: relative; padding: 10.5rem 0 4.5rem; overflow: hidden;
  border-bottom: 1px solid var(--line-strong);
}
.subhero h1 { max-width: 18ch; }
.subhero .section-lead { max-width: 44rem; }
.subhero-note {
  margin-top: 1.2rem; font-family: var(--mono); font-size: 0.75rem;
  letter-spacing: 0.14em; text-transform: uppercase; color: var(--signal);
}
.subhero-art {
  position: absolute; right: -4rem; top: 50%; transform: translateY(-50%);
  width: min(44vw, 480px); pointer-events: none;
}
.subhero-art svg { width: 100%; height: auto; }
.subhero-art .ring { fill: none; stroke: var(--line); stroke-width: 1; }
.subhero-art .ring-hot { stroke: var(--signal); stroke-dasharray: 4 6; }
.subhero-art .tick { stroke: var(--muted); stroke-width: 1; }
.subhero-art .mark { fill: var(--signal); }
@media (max-width: 900px) { .subhero-art { opacity: 0.35; } }

.prose { max-width: 44rem; margin-bottom: 1.4rem; font-size: 1.08rem; }
.wrap-narrow h2 {
  font-family: var(--serif); font-weight: 400;
  font-size: clamp(1.9rem, 3.4vw, 2.6rem); margin-bottom: 1.6rem;
}

.principles-grid {
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(1.4rem, 3vw, 2.4rem); margin-top: 2.5rem;
}
.principle-card {
  border: 1px solid var(--line-strong); background: var(--bone);
  padding: clamp(1.5rem, 3vw, 2.2rem);
  transition: transform 0.5s var(--ease-out), box-shadow 0.5s var(--ease-out);
}
.principle-card:hover { transform: translate(-4px, -4px); box-shadow: 8px 8px 0 rgba(22, 19, 12, 0.9); }
.principle-card .feature-index { display: block; margin-bottom: 0.9rem; }
.principle-card h3 { font-family: var(--serif); font-weight: 400; font-size: 1.5rem; margin-bottom: 0.5rem; }
.principle-card p { color: var(--muted); font-size: 0.95rem; }
@media (max-width: 700px) { .principles-grid { grid-template-columns: 1fr; } }

/* ---------- legal ---------- */
.legal-block { padding-block: 2.2rem; border-top: 1px solid var(--line); }
.legal-block:first-child { border-top: 0; }
.legal-block h2 {
  display: flex; align-items: baseline; gap: 1.2rem;
  font-size: clamp(1.5rem, 2.8vw, 2rem);
}
.legal-n {
  font-family: var(--mono); font-size: 0.8rem; color: var(--signal);
  letter-spacing: 0.1em; flex: none;
}

/* ---------- contact ---------- */
.contact-grid {
  display: grid; grid-template-columns: 1fr 1.35fr;
  gap: clamp(2.5rem, 6vw, 5rem); align-items: start;
}
.contact-info h2 { font-family: var(--serif); font-weight: 400; font-size: 1.8rem; margin-bottom: 1.4rem; }
.contact-info-list .fact-row dt { min-width: 9rem; }
.contact-panel {
  border: 1px solid var(--line-strong); background: var(--bone);
  padding: clamp(1.8rem, 4vw, 3rem);
  box-shadow: 10px 10px 0 rgba(22, 19, 12, 0.9);
}
.contact-title { font-family: var(--serif); font-weight: 400; font-size: 2rem; margin-bottom: 0.5rem; }
.contact-intro { color: var(--muted); margin-bottom: 1.8rem; }
.form-status-region { min-height: 0.5rem; }
.form-status {
  padding: 0.9rem 1.1rem; margin-bottom: 1.2rem; font-size: 0.95rem;
  border: 1px solid var(--line-strong);
}
.form-status-success { border-color: var(--signal); background: var(--signal-soft); }
.form-status-error { border-color: #b3261e; background: rgba(179, 38, 30, 0.08); color: #7a1a14; }
.field { margin-bottom: 1.5rem; }
.field label {
  display: block; font-family: var(--mono); font-size: 0.72rem;
  letter-spacing: 0.18em; text-transform: uppercase; color: var(--muted);
  margin-bottom: 0.4rem;
}
.field input, .field textarea {
  width: 100%; border: 0; border-bottom: 1px solid var(--line-strong);
  background: transparent; font: inherit; color: var(--ink);
  padding: 0.6rem 0.1rem; border-radius: 0;
  transition: border-color 0.3s, background 0.3s;
}
.field input:focus, .field textarea:focus {
  outline: none; border-bottom-color: var(--signal);
  background: linear-gradient(0deg, var(--signal-soft), transparent 60%);
}
.field textarea { resize: vertical; min-height: 8rem; }
.hp-field { position: absolute; left: -9999px; top: -9999px; height: 0; overflow: hidden; }
.form-privacy { margin-top: 1.1rem; font-size: 0.82rem; color: var(--muted); }
@media (max-width: 900px) { .contact-grid { grid-template-columns: 1fr; } }

/* ---------- 404 ---------- */
.notfound { min-height: 78vh; display: flex; align-items: center; border-bottom: 0; }
.notfound-code {
  font-family: var(--serif); font-style: italic;
  font-size: clamp(7rem, 22vw, 16rem); line-height: 0.9;
  color: transparent; -webkit-text-stroke: 1.5px var(--signal);
}
.notfound h1 { font-size: clamp(2rem, 4.4vw, 3.4rem); }
.notfound .section-lead { margin: 0 auto 2rem; }

/* ==========================================================================
   FOOTER
   ========================================================================== */
.site-footer {
  background: var(--ink-deep); color: var(--bone);
  padding: clamp(3.5rem, 7vw, 6rem) 0 2rem; margin-top: 2rem;
  position: relative; overflow: hidden;
}
.site-footer::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background-image: var(--contour-bg-dark, none);
  background-repeat: no-repeat; background-position: left -120px bottom -160px;
  background-size: 560px; opacity: 0.35;
}
.footer-grid {
  position: relative; display: grid;
  grid-template-columns: 1.6fr 1fr 1fr 1fr; gap: 2.5rem;
  padding-bottom: 3rem; border-bottom: 1px solid var(--line-on-dark);
}
.footer-brand .brand-name { font-size: 1.7rem; }
.footer-tagline { margin-top: 1.1rem; color: var(--muted-on-dark); font-size: 0.95rem; max-width: 24rem; }
.footer-status {
  margin-top: 1.4rem; font-family: var(--mono); font-size: 0.72rem;
  letter-spacing: 0.18em; text-transform: uppercase; color: var(--signal);
  display: flex; align-items: center; gap: 0.6rem;
}
.status-dot {
  width: 0.55rem; height: 0.55rem; border-radius: 50%; background: var(--signal);
  animation: pulse 2.4s ease-in-out infinite;
}
@keyframes pulse { 50% { box-shadow: 0 0 0 6px var(--signal-soft); } }
.footer-heading {
  font-family: var(--mono); font-size: 0.7rem; font-weight: 500;
  letter-spacing: 0.22em; text-transform: uppercase; color: var(--muted-on-dark);
  margin-bottom: 1.1rem;
}
.footer-nav a, .footer-legal a, .footer-langs a {
  display: block; padding-block: 0.32rem; color: #d8d1c0; font-size: 0.95rem;
  transition: color 0.25s, padding-left 0.3s var(--ease-out);
}
.footer-nav a:hover, .footer-legal a:hover, .footer-langs a:hover { color: var(--signal); padding-left: 0.5rem; }
.footer-langs a.is-active { color: var(--signal); }
.footer-bottom {
  position: relative; display: flex; flex-wrap: wrap; gap: 0.6rem 2.5rem;
  justify-content: space-between; padding-top: 1.8rem;
  font-size: 0.82rem; color: var(--muted-on-dark);
}
.footer-disclaimer { max-width: 34rem; }
.footer-word {
  position: relative; font-family: var(--serif); font-style: italic;
  font-size: clamp(4rem, 13vw, 11rem); line-height: 1; text-align: center;
  color: transparent; -webkit-text-stroke: 1px rgba(242, 237, 225, 0.22);
  padding: 2.5rem 0 0.5rem; user-select: none; pointer-events: none;
}
@media (max-width: 900px) {
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (prefers-reduced-motion: reduce) {
  .status-dot { animation: none; }
}

/* ---------- reduced motion: global ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.001s !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001s !important;
  }
}
