/* Ketch Lab — studio site. Tokens from css/letrero.css:7-17 (plan §6.10). */

@font-face { font-family: "Big Shoulders Display"; src: url("../assets/fonts/big-shoulders-display-800.woff2") format("woff2"); font-weight: 800; font-display: swap; }
@font-face { font-family: "Hanken Grotesk"; src: url("../assets/fonts/hanken-grotesk-var.woff2") format("woff2"); font-weight: 400 600; font-display: swap; }
@font-face { font-family: "IBM Plex Mono"; src: url("../assets/fonts/ibm-plex-mono-400.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "IBM Plex Mono"; src: url("../assets/fonts/ibm-plex-mono-600.woff2") format("woff2"); font-weight: 600; font-display: swap; }

:root {
  --verde: #10302A; --verde-900: #0A231E; --verde-700: #2C5047; --verde-500: #3E5750;
  --hueso: #ECE8DF; --hueso-300: #B8C1B9; --papel: #F6F3EC; --linea-hueso: #C9C5BA;
  --bermellon: #E0482B; --tinta: #07191A; --slot: #030B09;
  --sombra: 0 18px 40px -18px rgba(6, 24, 20, .55);
  --f-display: "Big Shoulders Display", Impact, "Arial Narrow", sans-serif;
  --f-body: "Hanken Grotesk", system-ui, sans-serif;
  --f-mono: "IBM Plex Mono", ui-monospace, monospace;
  --gutter: 20px;
  --sec-y: clamp(72px, 10vw, 112px);
  --spring: cubic-bezier(.3, 1.6, .5, 1);
  --ease: cubic-bezier(.2, .7, .2, 1);
  --max: 1180px;
  --sheetbar: 0px;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 16px; scroll-padding-bottom: var(--sheetbar); scrollbar-color: var(--verde-700) var(--verde-900); }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body {
  margin: 0; background: var(--verde); color: var(--hueso);
  font: 400 17px/1.55 var(--f-body); font-kerning: normal;
  text-rendering: optimizeLegibility; -webkit-font-smoothing: antialiased;
  caret-color: var(--bermellon); accent-color: var(--bermellon);
}
body::before {
  content: ""; position: fixed; inset: 0; pointer-events: none; z-index: 60; opacity: .07; mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}
::selection { background: var(--hueso); color: var(--verde); }
img, svg, video { display: block; max-width: 100%; }
a { color: inherit; }
button, input, select, textarea { font: inherit; color: inherit; }
h1, h2, h3, p, ol, ul, dl, dd, blockquote { margin: 0; }
h1, h2, h3 { text-wrap: balance; }
p, dd, li { text-wrap: pretty; }
[hidden] { display: none !important; }
.t-pending [data-t] { visibility: hidden; }
.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; }
.wrap { width: min(100% - 2 * var(--gutter), var(--max)); margin-inline: auto; }
.mono { font-family: var(--f-mono); font-size: 13px; letter-spacing: .04em; font-variant-numeric: tabular-nums; }
.kicker { font: 600 12px/1.3 var(--f-mono); letter-spacing: .14em; text-transform: uppercase; color: var(--hueso-300); margin-bottom: 18px; }
.display { font: 800 clamp(48px, 11vw, 132px)/.88 var(--f-display); text-transform: uppercase; letter-spacing: -.005em; }
.display--m { font-size: clamp(40px, 7.4vw, 92px); }
.lede { font-size: 19px; line-height: 1.5; max-width: 36ch; color: var(--hueso); }
.plain { margin-top: 18px; max-width: 46ch; color: var(--hueso-300); font-size: 16px; }
.sec-head { margin-bottom: clamp(28px, 5vw, 48px); }
.sec-head .lede { margin-top: 16px; }

:focus-visible { outline: 2px solid var(--hueso); outline-offset: 3px; border-radius: 2px; }
.work :focus-visible, .order__paper :focus-visible, .proof__paper :focus-visible { outline-color: var(--verde); }

.skip { position: absolute; left: 12px; top: -60px; z-index: 100; background: var(--hueso); color: var(--verde); padding: 10px 14px; font-weight: 600; text-decoration: none; }
.skip:focus { top: 12px; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 48px; padding: 12px 22px; border: 0; border-radius: 0; cursor: pointer;
  background: var(--hueso); color: var(--verde); font-weight: 600; font-size: 16px; text-decoration: none;
  box-shadow: var(--sombra); transition: transform .35s var(--spring), background-color .2s;
}
.btn:hover { background: #fff; }
.btn:active { transform: scale(.98); }
.btn[disabled] { opacity: .45; cursor: not-allowed; transform: none; }
.btn--small { min-height: 44px; padding: 8px 16px; font-size: 15px; }
.btn--ghost { background: transparent; color: inherit; box-shadow: inset 0 0 0 1px currentColor; }
.btn--ghost:hover { background: rgba(236, 232, 223, .08); }
.btn--block { width: 100%; }
.btn--icon { min-width: 48px; padding: 0; }
.btn--icon svg { width: 20px; height: 20px; fill: currentColor; }
.link { background: none; border: 0; padding: 10px 0; min-height: 44px; cursor: pointer; color: inherit; font-weight: 600; text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 4px; display: inline-flex; align-items: center; gap: 4px; }
.link:hover { text-decoration-color: var(--bermellon); }
.actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 24px; margin-top: 28px; }

/* Nav (not sticky) */
.nav { position: absolute; top: 0; left: 0; right: 0; z-index: 20; display: flex; align-items: center; justify-content: space-between; padding: 14px var(--gutter); }
.nav__brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; font: 800 22px/1 var(--f-display); text-transform: uppercase; letter-spacing: .02em; min-height: 44px; }
.k { width: 28px; height: 28px; fill: currentColor; }
.nav__links { display: flex; align-items: center; gap: 22px; }
.nav__link { text-decoration: none; font-weight: 500; min-height: 44px; display: inline-flex; align-items: center; }
.nav__link:hover { text-decoration: underline; text-underline-offset: 4px; }
@media (max-width: 760px) { .nav__link { display: none; } }

/* 1 · Film */
.film { position: relative; background: var(--verde-900); }
.film__stage { position: sticky; top: 0; height: 100svh; overflow: hidden; }
.film__plate {
  position: absolute; inset: 0;
  background:
    radial-gradient(120% 70% at 70% 105%, rgba(44, 80, 71, .55), transparent 60%),
    radial-gradient(80% 60% at 15% 0%, rgba(16, 48, 42, .9), transparent 70%),
    var(--verde-900);
}
/* The world: a 16:9 box (9:16 on portrait screens) covering the stage, so the frames and the
   K share one coordinate system. The K's box is the mainmast + mainsail of sail-*.{avif,webp}
   (measured on the 4K master: mast u .478, head v .33, waterline v .715; tools/make-ketch-frames.py). */
.film__world {
  position: absolute; left: 50%; top: 50%;
  width: max(100%, 100svh * 16 / 9); aspect-ratio: 16 / 9;
  translate: -50% -50%; transform-origin: 0% 55%;
  scale: calc(1.2 + .06 * var(--push, 0));
  will-change: scale;
}
.film__frame, .film__frame img { position: absolute; inset: 0; width: 100%; height: 100%; }
.film__frame img { object-fit: cover; }
.film__frame--sea { opacity: 1; }
.film__frame--sail { opacity: calc(1 - var(--signed, 0)); }
.film__frame--craft { opacity: calc(var(--craft, 0) * (1 - var(--code, 0))); }
.film__frame--code { opacity: calc(var(--code, 0) * (1 - var(--signed, 0))); }
.film__frame--craft img { scale: calc(1.04 - .04 * var(--craft, 0)); transform-origin: 48% 70%; }
.film__k {
  position: absolute; left: 40.24%; top: 26.92%; width: 28.5%; height: auto;
  fill: var(--hueso); opacity: var(--signed, 0);
  filter: drop-shadow(0 18px 30px rgba(6, 24, 20, .55));
}
.film__vetas { position: absolute; inset: 0; mix-blend-mode: screen; }
.film__vetas .vetas, .vetas-host > .vetas { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
.film__scrim {
  position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(90deg, rgba(10, 35, 30, .78) 0%, rgba(10, 35, 30, .45) 38%, rgba(10, 35, 30, 0) 62%),
    linear-gradient(180deg, rgba(10, 35, 30, 0) 70%, rgba(10, 35, 30, .6) 100%);
}
@media (max-aspect-ratio: 1/1) {
  /* Phone frames are the outpainted 1536x2752 plates; the K lands on the mast, then the
     camera pushes into it. */
  .film__world {
    width: max(100%, 114svh * 1536 / 2752); aspect-ratio: 1536 / 2752; translate: -50% calc(-50% - 7svh);
    transform-origin: 54.5% 50.5%; scale: calc(1 + .04 * var(--push, 0) + 1.1 * var(--signed, 0));
  }
  .film__k { left: 40.24%; top: 43.04%; width: 28.51%; }
  .film__scrim { background: linear-gradient(180deg, rgba(10, 35, 30, .72) 0%, rgba(10, 35, 30, .25) 30%, rgba(10, 35, 30, 0) 40%, rgba(10, 35, 30, 0) 54%, rgba(10, 35, 30, .8) 66%); }
}
.film__chapters { position: relative; z-index: 2; margin-top: -100svh; }
.chapter {
  min-height: 62svh; display: flex; flex-direction: column; justify-content: center;
  padding: 96px var(--gutter) 48px; max-width: calc(var(--max) + 2 * var(--gutter)); margin-inline: auto;
}
.chapter--sail { min-height: 100svh; padding-top: 120px; }
.chapter--sail h1 { max-width: 9ch; }
.chapter--signed { min-height: 80svh; }
.chapter .lede { margin-top: 22px; }
.chapter h2 { max-width: 12ch; }
.chapter .lede strong { font-weight: 600; }
.js .chapter:not(.chapter--sail) > * { opacity: 0; translate: 0 18px; transition: opacity .7s var(--ease), translate .7s var(--ease); }
.js .chapter.is-in > * { opacity: 1; translate: 0 0; }
.js .chapter.is-in > :nth-child(2) { transition-delay: .08s; }
@media (max-width: 760px) {
  .chapter { min-height: 55svh; text-shadow: 0 1px 18px rgba(10, 35, 30, .8); }
  .chapter--sail { min-height: 100svh; justify-content: flex-start; padding-top: 96px; }
  .chapter--sail h1 { max-width: none; }
  .chapter--sail .lede { margin-top: 30svh; }
}

/* 2 · Try it */
.try { padding: var(--sec-y) 0; background: var(--verde); position: relative; }
.try__fields { display: grid; gap: 16px; grid-template-columns: repeat(3, minmax(0, 1fr)); margin-bottom: 24px; }
@media (max-width: 860px) { .try__fields { grid-template-columns: 1fr 1fr; } .try__fields .field:last-child { grid-column: 1 / -1; } }
@media (max-width: 480px) { .try__fields { grid-template-columns: 1fr; } }
.field { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.field label { font: 600 12px/1.3 var(--f-mono); letter-spacing: .1em; text-transform: uppercase; color: var(--hueso-300); }
.field .opt { text-transform: none; letter-spacing: 0; font-weight: 400; }
select, input, textarea {
  width: 100%; min-height: 48px; padding: 12px 14px; border-radius: 0;
  background: var(--verde-900); border: 1px solid var(--verde-700); color: var(--hueso); font-size: 16px;
}
select { appearance: none; background-image: linear-gradient(45deg, transparent 50%, var(--hueso-300) 50%), linear-gradient(135deg, var(--hueso-300) 50%, transparent 50%); background-position: calc(100% - 20px) 50%, calc(100% - 15px) 50%; background-size: 5px 5px; background-repeat: no-repeat; padding-right: 36px; }
select:focus, input:focus, textarea:focus { border-color: var(--hueso); outline: none; box-shadow: 0 0 0 1px var(--hueso); }
::placeholder { color: #8E9C95; opacity: 1; }
.other { margin-top: 4px; }

.try__grid { display: grid; grid-template-columns: minmax(0, 6fr) minmax(0, 4fr); gap: 24px; align-items: start; }
@media (max-width: 767px) { .try__grid { grid-template-columns: 1fr; } .try .order { display: none; } }

.convo { border: 1px solid var(--verde-700); background: var(--verde-900); display: flex; flex-direction: column; min-height: 420px; }
.convo__head { display: flex; align-items: center; gap: 10px; padding: 14px 18px; border-bottom: 1px solid var(--verde-700); color: var(--hueso-300); }
.dot { width: 8px; height: 8px; background: var(--bermellon); border-radius: 50%; }
.convo__log { list-style: none; padding: 18px; display: flex; flex-direction: column; gap: 12px; flex: 1; }
.msg { max-width: 88%; padding: 12px 15px; line-height: 1.45; animation: msg-in .35s var(--ease) both; }
.msg--ariel { background: var(--verde); border: 1px solid var(--verde-700); align-self: flex-start; }
.msg--visitor { background: var(--hueso); color: var(--verde); align-self: flex-end; }
.msg--note { align-self: center; font: 13px/1.4 var(--f-mono); color: var(--hueso-300); background: none; padding: 4px 0; }
@keyframes msg-in { from { opacity: 0; translate: 0 6px; } }
@media (prefers-reduced-motion: reduce) { .msg { animation: none; } }

.chips, .quick { padding: 0 18px 14px; }
.chips__label { color: var(--hueso-300); margin-bottom: 10px; }
.chips__row, .quick { display: flex; flex-wrap: wrap; gap: 8px; }
.chips > .btn { margin-top: 12px; }
.chip {
  min-height: 44px; padding: 10px 14px; background: transparent; color: var(--hueso); cursor: pointer; text-align: left;
  border: 1px solid var(--verde-700); border-radius: 999px; font-size: 15px; transition: transform .35s var(--spring), background-color .15s, border-color .15s;
}
.chip:hover { border-color: var(--hueso-300); }
.chip:active { transform: scale(.98); }
.chip[aria-pressed="true"] { background: var(--hueso); color: var(--verde); border-color: var(--hueso); }
.chip[aria-pressed="true"]::before { content: "✓ "; }
.chip[disabled] { opacity: .4; cursor: not-allowed; }
.typing { padding: 0 18px 12px; color: var(--hueso-300); }
.composer { display: flex; gap: 8px; padding: 12px; border-top: 1px solid var(--verde-700); }
.composer textarea { resize: none; min-height: 48px; max-height: 160px; line-height: 1.4; }

/* Work order (paper) */
.order { position: sticky; top: 16px; }
.order__paper { background: var(--papel); color: var(--tinta); padding: 22px 22px 18px; box-shadow: var(--sombra); position: relative; }
.order__stamp { font-weight: 600; letter-spacing: .16em; text-transform: uppercase; color: var(--verde-500); border-bottom: 1px dashed var(--linea-hueso); padding-bottom: 10px; margin-bottom: 14px; }
.order__title { font: 800 30px/.95 var(--f-display); text-transform: uppercase; }
.order__quote { margin-top: 14px; padding-left: 12px; border-left: 3px solid var(--bermellon); font-style: italic; color: var(--verde-500); }
.order__quote::before { content: "“"; } .order__quote::after { content: "”"; }
.order__pieces { list-style: none; padding: 0; margin-top: 16px; display: flex; flex-direction: column; }
.piece { display: grid; grid-template-columns: 14px 1fr; gap: 10px; padding: 10px 0; border-top: 1px solid var(--linea-hueso); animation: piece-in .5s var(--spring) both; }
.piece::before { content: ""; width: 10px; height: 10px; margin-top: 6px; background: var(--bermellon); }
.piece strong { display: block; font-weight: 600; line-height: 1.3; }
.piece span { display: block; font-size: 15px; color: var(--verde-500); margin-top: 3px; }
@keyframes piece-in { from { opacity: 0; transform: translateY(6px) scale(.98); } }
@media (prefers-reduced-motion: reduce) { .piece { animation: none; } }
.order__empty { margin-top: 16px; color: var(--verde-500); }
.order__proofs { display: flex; flex-wrap: wrap; gap: 0 18px; margin-top: 10px; }
.order__proofs .link { color: var(--verde); font-size: 15px; }
.order__send { margin-top: 16px; padding-top: 16px; border-top: 1px dashed var(--linea-hueso); display: flex; flex-direction: column; gap: 12px; }
.order__send .field label { color: var(--verde-500); }
.order__send input { background: #fff; border-color: var(--linea-hueso); color: var(--tinta); }
.order__send input:focus { border-color: var(--verde); box-shadow: 0 0 0 1px var(--verde); }
.order__send .btn { background: var(--verde); color: var(--hueso); }
.order__send .btn:hover { background: var(--verde-900); }
.fine { font-size: 13px; color: var(--verde-500); line-height: 1.45; }
.fine a { color: var(--verde); }
.promise { color: var(--verde-500); font-size: 12px; }
.err { color: #A8301A; font-size: 14px; font-weight: 600; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.order__done { margin-top: 16px; padding-top: 16px; border-top: 1px dashed var(--linea-hueso); }
.order__done .btn { background: var(--verde); color: var(--hueso); }
.order__done .link { color: var(--verde); }

/* Phone: work-order bar + sheet */
.sheetbar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; padding: 10px var(--gutter) calc(10px + env(safe-area-inset-bottom)); background: var(--verde-900); border-top: 1px solid var(--verde-700); }
.sheetbar__btn { width: 100%; min-height: 48px; background: var(--hueso); color: var(--verde); border: 0; font-weight: 600; font-size: 16px; cursor: pointer; }
dialog { border: 0; padding: 0; color: inherit; }
dialog::backdrop { background: rgba(3, 11, 9, .7); }
.sheet { width: 100%; max-width: 100%; max-height: 90svh; margin: auto 0 0; background: var(--verde-900); }
.sheet[open] { animation: sheet-in .35s var(--ease); }
@keyframes sheet-in { from { translate: 0 30%; opacity: .4; } }
.sheet__head { display: flex; justify-content: space-between; align-items: center; padding: 12px var(--gutter); position: sticky; top: 0; z-index: 1; background: var(--verde-900); border-bottom: 1px solid var(--verde-700); }
.sheet__head h3 { font: 800 26px/1 var(--f-display); text-transform: uppercase; }
.sheet__body { padding: 16px var(--gutter) calc(20px + env(safe-area-inset-bottom)); }
.sheet__body .order { position: static; }

/* Proofs: receipt and call */
.proof { width: min(100% - 24px, 460px); max-height: 90svh; background: transparent; }
.proof__paper { background: var(--papel); color: var(--tinta); padding: 22px; font-family: var(--f-mono); font-size: 14px; }
.proof__head { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.proof__head h3 { font: 800 26px/1 var(--f-display); text-transform: uppercase; }
.proof__head .btn--ghost { color: var(--verde); }
.proof__note { color: var(--verde-500); margin: 10px 0 12px; border-bottom: 1px dashed var(--linea-hueso); padding-bottom: 10px; }
.proof__lines { list-style: none; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.proof__lines li { display: grid; grid-template-columns: 52px 1fr auto; gap: 8px; align-items: baseline; animation: print .4s var(--ease) both; }
.proof__lines li .st { color: var(--verde-500); font-size: 11px; letter-spacing: .08em; }
.proof__lines li.call { grid-template-columns: 70px 1fr; }
@keyframes print { from { opacity: 0; clip-path: inset(0 0 100% 0); } }
@media (prefers-reduced-motion: reduce) { .proof__lines li { animation: none; } }
.proof__foot { margin-top: 14px; padding-top: 12px; border-top: 1px dashed var(--linea-hueso); display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.stamp { display: inline-block; border: 2px solid var(--bermellon); color: var(--bermellon); padding: 4px 10px; font: 800 24px/1 var(--f-display); letter-spacing: .06em; rotate: -6deg; }

/* 3 · Work (bone) */
.work { background: var(--hueso); color: var(--verde); padding: var(--sec-y) 0; }
.work .kicker { color: var(--verde-500); }
.work .lede { color: var(--verde); max-width: 52ch; }
.work__pause { color: var(--verde); margin-bottom: 18px; }
.cases { list-style: none; padding: 0; display: flex; flex-direction: column; gap: clamp(48px, 8vw, 96px); }
.case { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: clamp(20px, 4vw, 56px); align-items: center; }
.case:nth-child(even) .case__media { order: 2; }
@media (max-width: 760px) { .case { grid-template-columns: 1fr; } .case:nth-child(even) .case__media { order: 0; } }
.case__media { justify-self: center; }
.device { width: min(300px, 70vw); aspect-ratio: 390 / 844; border-radius: 34px; padding: 10px; background: var(--tinta); box-shadow: 0 30px 60px -30px rgba(6, 24, 20, .6); }
.device__screen { width: 100%; height: 100%; border-radius: 26px; overflow: hidden; background: var(--verde-900); position: relative; }
.device__screen img, .device__screen video { width: 100%; height: 100%; object-fit: cover; object-position: top; }
.case__tag { display: inline-block; font: 600 11px/1 var(--f-mono); letter-spacing: .14em; text-transform: uppercase; padding: 6px 8px; border: 1px solid var(--verde-500); color: var(--verde-500); margin-bottom: 14px; }
.case__name { font: 800 clamp(36px, 5vw, 60px)/.9 var(--f-display); text-transform: uppercase; }
.case__meta { margin-top: 8px; font-family: var(--f-mono); font-size: 13px; color: var(--verde-500); }
.case dl { margin-top: 18px; display: grid; gap: 12px; }
.case dt { font: 600 12px/1.3 var(--f-mono); letter-spacing: .1em; text-transform: uppercase; color: var(--verde-500); }
.case dd { margin-top: 2px; max-width: 46ch; }
.case .actions { margin-top: 12px; }

/* 3b · Find the leak — free calculator. The hull fills to match the monthly figure. */
.leak { padding: var(--sec-y) 0; background: var(--verde-900); border-block: 1px solid var(--verde-700); }
.leak__grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(28px, 6vw, 88px); align-items: center; }
.leak .lede { margin-top: 18px; max-width: 40ch; }
.leak__form { margin-top: 32px; display: grid; gap: 22px; max-width: 460px; }
.leak__field label { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; font-size: 15px; color: var(--hueso-300); }
.leak__field output { color: var(--hueso); font-size: 16px; }
.leak input[type="range"] { width: 100%; margin-top: 10px; height: 28px; background: transparent; }
.leak__num { margin-top: 8px; width: 160px; font: 600 22px/1 var(--f-mono); padding: 10px 12px; background: transparent; border: 1px solid var(--verde-700); color: var(--hueso); border-radius: 0; }
.leak__num:focus { outline: none; border-color: var(--bermellon); }
.leak__note { color: var(--hueso-300); font-size: 12px; }
.leak__hull { margin: 0; display: grid; justify-items: center; text-align: center; }
.leak__hull svg { width: min(100%, 460px); overflow: visible; }
.leak__inside { fill: rgba(236, 232, 223, .03); }
.leak__water { transition: transform .7s var(--spring); }
.leak__wave { fill: rgba(150, 206, 182, .34); stroke: rgba(236, 232, 223, .85); stroke-width: 1.5; animation: leak-swell 4.2s linear infinite paused; }
.leak.is-live .leak__wave { animation-play-state: running; }
.leak__wave--b { fill: rgba(150, 206, 182, .16); stroke: rgba(150, 206, 182, .5); animation-duration: 6.4s; animation-direction: reverse; }
@keyframes leak-swell { to { transform: translateX(200px); } }
.leak__shell { fill: none; stroke: var(--hueso); stroke-width: 1.5; stroke-linejoin: round; }
.leak__crack { fill: none; stroke: var(--bermellon); stroke-width: 2; stroke-linecap: square; }
.is-dry .leak__crack { stroke: var(--verde-500); }
.leak__out { margin-top: 18px; display: grid; gap: 6px; }
.leak__lbl { color: var(--hueso-300); text-transform: uppercase; letter-spacing: .14em; font-size: 12px; }
.leak__money { font: 800 clamp(56px, 9vw, 104px)/.9 var(--f-display); color: var(--hueso); font-variant-numeric: tabular-nums; }
.leak__year { color: var(--hueso-300); }
.leak__act { margin-top: 24px; display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 12px 22px; }
@media (max-width: 860px) { .leak__grid { grid-template-columns: 1fr; } .leak__form { max-width: none; } }
@media (prefers-reduced-motion: reduce) { .leak__wave { animation: none; } .leak__water { transition: none; } }

/* 4 · What we do */
.what { padding: var(--sec-y) 0; }
.vetas-host { position: relative; isolation: isolate; }
.vetas-host > .vetas { z-index: -1; }
.what__body { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); gap: clamp(28px, 5vw, 72px); align-items: center; }
.what__list { border-top: 1px solid var(--verde-700); }
.what__list > div { padding: 20px 0; border-bottom: 1px solid var(--verde-700); transition: background-color .25s; }
.what__list dt { font: 800 34px/1 var(--f-display); text-transform: uppercase; display: flex; align-items: baseline; gap: 12px; }
.what__list dt .mono { font-size: 13px; color: var(--hueso-300); letter-spacing: .08em; }
.what__list > div:hover dt .mono { color: var(--bermellon); }

/* The rig: the four services as the parts of one ketch (main, jib, hull, mizzen). */
.rig { margin: 0; }
.rig svg { width: 100%; height: auto; overflow: visible; }
.rig path { fill: none; stroke: var(--hueso); stroke-width: 1.2; stroke-linejoin: round; vector-effect: non-scaling-stroke; }
.rig__lines path, .rig__water { stroke: var(--hueso-300); opacity: .45; stroke-width: 1; }
.rig__part { transition: stroke .25s, fill .25s; fill: rgba(236, 232, 223, .03) !important; }
.rig__tags text { font: 600 13px var(--f-mono); fill: var(--hueso-300); letter-spacing: .08em; transition: fill .25s; }
.rig figcaption { margin-top: 14px; color: var(--hueso-300); }
.what__body:has([data-part="main"]:hover) .rig__main,
.what__body:has([data-part="jib"]:hover) .rig__jib,
.what__body:has([data-part="hull"]:hover) .rig__hull,
.what__body:has([data-part="mizzen"]:hover) .rig__mizzen { stroke: var(--bermellon); fill: rgba(224, 72, 43, .1) !important; }
@supports (animation-timeline: view()) {
  @media (prefers-reduced-motion: no-preference) {
    .rig path { stroke-dasharray: 1400; animation: rig-draw linear both; animation-timeline: view(); animation-range: entry 10% cover 45%; }
    .rig__tags { animation: rig-tags linear both; animation-timeline: view(); animation-range: cover 30% cover 45%; }
  }
}
@keyframes rig-draw { from { stroke-dashoffset: 1400; } to { stroke-dashoffset: 0; } }
@keyframes rig-tags { from { opacity: 0; } to { opacity: 1; } }
@media (max-width: 860px) { .what__body { grid-template-columns: 1fr; } }
.what__list dd { margin-top: 8px; color: var(--hueso-300); max-width: 40ch; }
@media (max-width: 640px) { .what__list { grid-template-columns: 1fr; } .what__list > div:nth-child(n) { padding: 18px 0; border-right: 0; } }
.breakers { margin-top: clamp(36px, 6vw, 56px); }
.breakers__h { text-transform: uppercase; letter-spacing: .14em; color: var(--hueso-300); margin-bottom: 14px; }
.breakers__list { list-style: none; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 0 28px; }
.breakers__list li { display: grid; grid-template-columns: 104px 1fr; gap: 12px; padding: 11px 0; border-bottom: 1px solid var(--verde-700); font-size: 15px; }
.breakers__list .mono { color: var(--hueso-300); text-transform: uppercase; font-size: 12px; padding-top: 2px; }

/* 5 · Method */
.method { padding: 0 0 var(--sec-y); }
.steps { list-style: none; padding: 0; counter-reset: s; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 24px; }
.steps li { counter-increment: s; border-top: 2px solid var(--hueso); padding-top: 16px; }
.steps li::before { content: counter(s, decimal-leading-zero); font: 600 13px/1 var(--f-mono); color: var(--hueso-300); }
.steps h3 { font: 800 28px/1 var(--f-display); text-transform: uppercase; margin-top: 10px; }
.steps p { margin-top: 8px; color: var(--hueso-300); font-size: 16px; }
@media (max-width: 860px) { .steps { grid-template-columns: 1fr 1fr; } }
@media (max-width: 480px) { .steps { grid-template-columns: 1fr; gap: 18px; } }

/* 6 · Close + footer */
.close { padding: var(--sec-y) 0; background: var(--verde-900); border-top: 1px solid var(--verde-700); }
.close h2 { max-width: 10ch; }
.close .wrap { position: relative; }
.close__k { position: absolute; right: 0; top: 50%; translate: 0 -50%; width: min(34vw, 420px); fill: none; stroke: var(--hueso); stroke-width: .35; opacity: .5; }
.close__k path { fill: rgba(224, 72, 43, .06); }
@media (max-width: 860px) { .close__k { display: none; } }
.close__mail { color: var(--hueso-300); }
.foot { background: var(--verde-900); padding: 24px 0 calc(28px + var(--sheetbar)); border-top: 1px solid var(--verde-700); }
.foot__row { display: flex; flex-wrap: wrap; align-items: center; gap: 0 12px; color: var(--hueso-300); font-size: 14px; }
.foot__row .k { width: 20px; height: 20px; fill: var(--hueso); }
.foot a { min-height: 44px; display: inline-flex; align-items: center; }

/* Vela — the studio's chat. Launcher: bone bubble whose tail is the K's triangle, lit by the
   boat's vermilion light. Panel: a sheet of log paper over the green. */
.vela { position: fixed; right: 16px; bottom: calc(16px + env(safe-area-inset-bottom)); z-index: 40; display: flex; flex-direction: column; align-items: flex-end; gap: 12px; }
.vela__open {
  display: inline-flex; align-items: center; gap: 10px; min-height: 52px; padding: 8px 18px 8px 10px;
  background: var(--verde-900); color: var(--hueso); border: 1px solid var(--verde-700); border-radius: 0; cursor: pointer;
  box-shadow: var(--sombra); font-weight: 600; font-size: 15px; transition: transform .35s var(--spring), border-color .2s;
}
.vela__open:hover { border-color: var(--hueso-300); }
.vela__open:active { transform: scale(.97); }
.vela__open .vela__sym { width: 34px; height: 34px; }
.vela.is-open .vela__label { display: none; }
.vela.is-open .vela__open { padding: 8px; }
.vela__sym { display: block; flex: none; overflow: visible; }
.vela__bubble { fill: var(--hueso); }
.vela__tail { fill: var(--hueso-300); }
.vela__light { fill: var(--bermellon); transform-box: fill-box; transform-origin: center; }
.vela__open:hover .vela__light { animation: vela-blink 1.6s var(--ease) 1; }
@keyframes vela-blink { 0%, 100% { opacity: 1; } 40% { opacity: .25; } }

.vela__panel {
  width: min(380px, calc(100vw - 32px)); height: min(580px, calc(100svh - 120px));
  display: flex; flex-direction: column; background: var(--papel); color: var(--tinta);
  box-shadow: 0 30px 60px -20px rgba(3, 11, 9, .7), 0 0 0 1px rgba(7, 25, 26, .12);
  transform-origin: bottom right; animation: vela-in .32s var(--spring);
}
@keyframes vela-in { from { opacity: 0; transform: translateY(10px) scale(.97); } to { opacity: 1; transform: none; } }
.vela__head { display: flex; align-items: center; gap: 12px; padding: 14px 12px 14px 16px; background: var(--verde-900); color: var(--hueso); }
.vela__avatar img { width: 44px; height: 44px; border-radius: 50%; box-shadow: 0 0 0 2px var(--verde-700); object-fit: cover; }
.vela__dot { display: inline-block; width: 7px; height: 7px; margin-right: 7px; background: #5FBF8F; border-radius: 50%; vertical-align: 1px; animation: vela-live 2.4s var(--ease) infinite; }
@keyframes vela-live { 0%, 100% { box-shadow: 0 0 0 0 rgba(95, 191, 143, .5); } 60% { box-shadow: 0 0 0 5px rgba(95, 191, 143, 0); } }
.vela__head > div { flex: 1; min-width: 0; }
.vela__name { font: 800 24px/1 var(--f-display); text-transform: uppercase; letter-spacing: .01em; }
.vela__role { font: 400 12px/1.3 var(--f-mono); color: var(--hueso-300); margin-top: 4px; letter-spacing: .02em; }
.vela__x { width: 44px; height: 44px; display: grid; place-items: center; background: none; border: 0; color: var(--hueso); cursor: pointer; }
.vela__x svg, .vela__send svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.8; }
.vela__log {
  list-style: none; margin: 0; padding: 18px 16px 8px; flex: 1; overflow-y: auto; display: flex; flex-direction: column; gap: 10px;
  background-image: repeating-linear-gradient(180deg, transparent 0 27px, rgba(7, 25, 26, .06) 27px 28px);
}
.vela__msg { max-width: 88%; font-size: 15px; line-height: 1.45; padding: 10px 12px; }
.vela__msg--bot { position: relative; align-self: flex-start; margin-left: 40px; max-width: calc(88% - 40px); background: #fff; border-left: 2px solid var(--verde); animation: vela-msg .28s var(--ease); }
.vela__msg--you { animation: vela-msg .2s var(--ease); }
@keyframes vela-msg { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
.vela__face { position: absolute; left: -40px; top: 0; width: 32px; height: 32px; border-radius: 50%; object-fit: cover; }
.vela__msg--bot:not(.has-face) { margin-top: -6px; }
.vela__welcome { align-self: center; width: 172px; margin: 4px 0 6px; animation: vela-wave .6s var(--spring); }
.vela__welcome img { width: 172px; height: 172px; border-radius: 50%; object-fit: cover; box-shadow: 0 0 0 4px var(--papel), 0 0 0 5px var(--linea-hueso), 0 18px 30px -16px rgba(6, 24, 20, .6); }
@keyframes vela-wave { from { opacity: 0; transform: translateY(14px) scale(.92); } to { opacity: 1; transform: none; } }
.vela__msg--you { align-self: flex-end; background: var(--verde); color: var(--hueso); }
.vela__msg--action { padding: 0; align-self: flex-start; }
.vela__act { background: none; border: 1px solid var(--verde); color: var(--verde); font-weight: 600; font-size: 14px; padding: 9px 14px; min-height: 40px; cursor: pointer; }
.vela__act:hover { background: var(--verde); color: var(--hueso); }
.is-typing { display: inline-flex; gap: 4px; padding: 14px 12px; }
.is-typing span { width: 6px; height: 6px; background: var(--verde-500); animation: vela-dot 1s infinite var(--ease); }
.is-typing span:nth-child(2) { animation-delay: .15s; } .is-typing span:nth-child(3) { animation-delay: .3s; }
@keyframes vela-dot { 0%, 100% { opacity: .25; } 50% { opacity: 1; } }
.vela__chips { display: flex; flex-wrap: wrap; gap: 6px; padding: 8px 16px 10px; }
.vela__chip { background: transparent; border: 1px solid var(--linea-hueso); color: var(--tinta); font-size: 13px; padding: 7px 10px; min-height: 36px; cursor: pointer; }
.vela__chip:hover { border-color: var(--verde); }
.vela__chip:first-child { background: var(--verde); border-color: var(--verde); color: var(--hueso); }
.vela__form { display: flex; border-top: 1px solid var(--linea-hueso); }
.vela__input { flex: 1; min-width: 0; border: 0; background: transparent; padding: 14px 16px; font-size: 16px; color: var(--tinta); }
.vela__input:focus { outline: none; }
.vela__form:focus-within { box-shadow: inset 0 2px 0 var(--bermellon); }
.vela__send { width: 52px; border: 0; background: var(--verde); color: var(--hueso); cursor: pointer; }
.vela__panel :focus-visible { outline-color: var(--verde); }
@media (max-width: 520px) {
  .vela { right: 12px; bottom: calc(12px + env(safe-area-inset-bottom)); }
  .vela__label { display: none; }
  .vela__open { padding: 8px; }
  .vela.is-open { left: 0; right: 0; bottom: 0; top: 0; gap: 0; }
  .vela.is-open .vela__open { display: none; }
  .vela__panel { width: 100%; height: 100%; }
}
@media (prefers-reduced-motion: reduce) { .vela__panel, .vela__msg, .vela__welcome, .vela__dot { animation: none; } .is-typing span { animation: none; opacity: .6; } }

/* Privacy page */
.doc { padding: 120px 0 var(--sec-y); }
.doc h1 { font: 800 clamp(44px, 8vw, 80px)/.9 var(--f-display); text-transform: uppercase; }
.doc h2 { font: 800 26px/1 var(--f-display); text-transform: uppercase; margin-top: 34px; }
.doc p, .doc ul { margin-top: 12px; max-width: 62ch; }
.doc li { margin-top: 6px; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition-duration: .01ms !important; }
  .js .chapter:not(.chapter--sail) > * { opacity: 1; translate: none; }
}
