/* ==========================================================================
   Brandcode10 — "Sheets"
   A project is a stack of sheets: brief, design, code, launch. The hero deals
   them out as you scroll; every piece of content below sits on its own sheet.
   ========================================================================== */

:root {
  --canvas: #eceef3;
  --paper: #ffffff;
  --paper-2: #f7f8fa;
  --ink: #0b0d12;
  --slate: #596273;
  --rule: #d6dae2;
  --signal: #f15800;
  --signal-text: #c44700;
  --blue: #2b4bff;
  --shadow: 0 1px 2px rgba(11, 13, 18, 0.06), 0 14px 34px -18px rgba(11, 13, 18, 0.32);

  --display: 'Chivo', 'Segoe UI', system-ui, sans-serif;
  --body: 'Figtree', 'Segoe UI', system-ui, sans-serif;
  --mono: 'Fira Code', ui-monospace, Consolas, monospace;

  --gut: clamp(20px, 4vw, 56px);
  --max: 1320px;
  --radius: 6px;
  --nav-h: 66px;
  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: calc(var(--nav-h) + 16px); }
body { margin: 0; background: var(--canvas); color: var(--ink); font-family: var(--body); font-size: 17px; line-height: 1.6; -webkit-font-smoothing: antialiased; overflow-x: hidden; }
h1, h2, h3, h4, p, ul, ol, figure, blockquote, dl, dd, pre { margin: 0; }
ul, ol { padding: 0; }
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; cursor: pointer; }
::selection { background: var(--signal); color: #fff; }
:focus-visible { outline: 2px solid var(--blue); outline-offset: 3px; border-radius: 3px; }
.screen-reader-text { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.skip-link:focus { position: fixed; left: 12px; top: 12px; z-index: 1000; width: auto; height: auto; clip-path: none; background: var(--ink); color: #fff; padding: 10px 16px; border-radius: 6px; }
.wrap { width: 100%; max-width: var(--max); margin: 0 auto; padding-left: var(--gut); padding-right: var(--gut); }

/* ───────── type ───────── */
.display, .h1, .h2 { font-family: var(--display); font-weight: 900; letter-spacing: -0.03em; line-height: 0.96; }
.display { font-size: clamp(44px, 7.4vw, 118px); }
.h1 { font-size: clamp(40px, 6vw, 92px); }
.h2 { font-size: clamp(32px, 4.2vw, 60px); line-height: 1.02; }
.h3 { font-family: var(--display); font-weight: 700; font-size: clamp(20px, 1.9vw, 26px); letter-spacing: -0.015em; line-height: 1.15; }
.lead { font-size: clamp(18px, 1.45vw, 21px); line-height: 1.55; color: var(--slate); max-width: 54ch; }
.mono { font-family: var(--mono); font-size: 12.5px; }
.eyebrow { font-family: var(--mono); font-size: 12.5px; color: var(--signal-text); margin-bottom: 16px; }
.eyebrow[data-code]::after { content: none; }

/* ───────── buttons ───────── */
.btn { display: inline-flex; align-items: center; gap: 10px; font-weight: 700; font-size: 16px; line-height: 1; padding: 16px 24px; border-radius: var(--radius); border: 1.5px solid var(--ink); background: var(--ink); color: #fff; transition: background-color 0.2s, border-color 0.2s, color 0.2s, transform 0.2s var(--ease); }
.btn .ar { transition: transform 0.25s var(--ease); }
.btn:hover { background: var(--signal); border-color: var(--signal); transform: translateY(-1px); }
.btn:hover .ar { transform: translateX(4px); }
.btn--ghost { background: transparent; color: var(--ink); border-color: var(--rule); }
.btn--ghost:hover { background: var(--paper); border-color: var(--ink); color: var(--ink); transform: none; }
.btn--sm { padding: 11px 16px; font-size: 14.5px; }
.link { font-weight: 700; border-bottom: 2px solid var(--signal); padding-bottom: 1px; transition: color 0.2s; }
.link:hover { color: var(--signal-text); }
.tags { display: flex; flex-wrap: wrap; gap: 6px; list-style: none; }
.tags li, .tag { font-family: var(--mono); font-size: 11.5px; color: var(--slate); background: var(--canvas); border-radius: 4px; padding: 4px 8px; }

/* ───────── nav ───────── */
.nav { position: fixed; inset: 0 0 auto 0; z-index: 100; height: var(--nav-h); background: color-mix(in srgb, var(--canvas) 86%, transparent); -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px); border-bottom: 1px solid transparent; transition: border-color 0.25s; }
.nav.is-stuck { border-bottom-color: var(--rule); }
.nav-in { height: 100%; display: flex; align-items: center; gap: 28px; }
.logo { display: inline-flex; align-items: baseline; font-family: var(--display); font-weight: 900; font-size: 21px; letter-spacing: -0.03em; margin-right: auto; flex: none; }
.logo .c { color: var(--signal-text); }
.nav-links { display: flex; gap: clamp(14px, 2vw, 28px); list-style: none; }
.nav-links a { font-size: 15.5px; font-weight: 600; color: var(--slate); padding: 6px 0; border-bottom: 2px solid transparent; transition: color 0.2s, border-color 0.2s; }
.nav-links a:hover, .nav-links a[aria-current="page"] { color: var(--ink); border-bottom-color: var(--signal); }
.burger { display: none; flex: none; width: 44px; height: 44px; border: 0; background: none; position: relative; margin-right: -10px; }
.burger::before, .burger::after { content: ''; position: absolute; left: 11px; right: 11px; height: 2px; background: currentColor; transition: transform 0.25s var(--ease); }
.burger::before { top: 17px; } .burger::after { top: 25px; }
.burger[aria-expanded="true"]::before { transform: translateY(4px) rotate(45deg); }
.burger[aria-expanded="true"]::after { transform: translateY(-4px) rotate(-45deg); }
.menu { position: fixed; inset: var(--nav-h) 0 0 0; z-index: 99; background: var(--canvas); padding: 24px var(--gut) 36px; display: flex; flex-direction: column; visibility: hidden; opacity: 0; transition: opacity 0.2s, visibility 0s 0.2s; overflow-y: auto; }
.menu.is-open { visibility: visible; opacity: 1; transition: opacity 0.2s; }
.menu ul { list-style: none; }
.menu li { border-bottom: 1px solid var(--rule); }
.menu li a { display: block; padding: 15px 0; font-family: var(--display); font-weight: 800; font-size: 30px; letter-spacing: -0.02em; }
.menu-foot { margin-top: auto; padding-top: 28px; display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; color: var(--slate); }
@media (max-width: 940px) { .nav-links, .nav .btn { display: none; } .burger { display: block; } }

/* ───────── sheets: the recurring surface ───────── */
.sheet { position: relative; background: var(--paper); border-radius: var(--radius); box-shadow: var(--shadow); }
.sheet-tab { position: absolute; left: 0; bottom: 100%; font-family: var(--mono); font-size: 11.5px; letter-spacing: 0.02em; color: var(--slate); background: var(--paper); padding: 7px 14px 5px; border-radius: var(--radius) var(--radius) 0 0; box-shadow: 0 -6px 14px -10px rgba(11, 13, 18, 0.25); }
.sheet-tab b { color: var(--signal-text); font-weight: 500; }
.tile { position: relative; background: var(--paper); border-radius: var(--radius); box-shadow: var(--shadow); padding: clamp(22px, 2.4vw, 32px); transition: transform 0.25s var(--ease), box-shadow 0.25s; }
.tile .h3 { margin-bottom: 10px; }
.tile p { color: var(--slate); font-size: 16px; }
.tile .mono { display: block; margin-bottom: 14px; color: var(--signal-text); }
a.tile:hover { transform: translateY(-4px); box-shadow: 0 1px 2px rgba(11, 13, 18, 0.06), 0 26px 44px -20px rgba(11, 13, 18, 0.38); }

/* ───────── hero: the deck ───────── */
.hero { padding-top: var(--nav-h); }
.deck-run { position: relative; }
.deck-pin { padding: clamp(40px, 8vh, 96px) 0 clamp(40px, 7vh, 80px); }
.deck-grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: clamp(24px, 4vw, 64px); align-items: center; }
.deck-copy .eyebrow { margin-bottom: 20px; }
.deck-copy .display { position: relative; }
.deck-copy .display .stage-word { display: block; color: var(--signal); }
.deck-copy .lead { margin-top: 22px; }
.deck-ctas { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 30px; }
.deck-steps { display: flex; gap: 18px; margin-top: 36px; list-style: none; font-family: var(--mono); font-size: 12.5px; color: var(--slate); }
.deck-step { display: flex; align-items: center; gap: 8px; transition: color 0.3s; cursor: pointer; padding: 4px 0; border: 0; background: none; font: inherit; color: inherit; }
.deck-step:hover { color: var(--ink); }
.deck-step::before { content: ''; width: 22px; height: 3px; border-radius: 2px; background: var(--rule); transition: background-color 0.3s; }
.deck-step.is-on { color: var(--ink); }
.deck-step.is-on::before { background: var(--signal); }

.deck { position: relative; height: min(520px, 62vh); perspective: 1400px; }
.card { position: absolute; inset: 0; margin: auto; width: min(100%, 560px); height: 100%; background: var(--paper); border-radius: 10px; box-shadow: var(--shadow); overflow: hidden; display: flex; flex-direction: column; transform-origin: 50% 100%; will-change: transform, opacity; transition: transform 0.75s var(--ease), opacity 0.6s var(--ease); }
.card-head { display: flex; align-items: center; justify-content: space-between; padding: 14px 18px; border-bottom: 1px solid var(--rule); font-family: var(--mono); font-size: 12px; color: var(--slate); }
.card-head b { color: var(--ink); font-weight: 500; }
.card-body { padding: 20px; flex: 1; min-height: 0; }
.card--launch .card-body { padding: 0; }
.card--launch img { width: 100%; height: 100%; object-fit: cover; object-position: top; }

/* brief sheet: a filled-in brief */
.brief { display: grid; grid-template-columns: 110px 1fr; gap: 10px 16px; font-size: 15px; }
.brief dt { font-family: var(--mono); font-size: 12px; color: var(--slate); padding-top: 2px; }
.brief dd { border-bottom: 1px solid var(--rule); padding-bottom: 8px; }
.brief dd:last-child { border-bottom: 0; }
/* design sheet: tokens + a wireframe */
.design { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; height: 100%; }
.swatches { list-style: none; display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.swatches i { display: block; aspect-ratio: 1; border-radius: 5px; border: 1px solid var(--rule); }
.specimen { font-family: var(--display); font-weight: 900; font-size: 44px; line-height: 1; letter-spacing: -0.03em; margin-top: 18px; }
.specimen small { display: block; font: 400 12px var(--mono); color: var(--slate); letter-spacing: 0; margin-top: 6px; }
.wire { border: 1.5px dashed var(--blue); border-radius: 6px; padding: 12px; display: grid; gap: 8px; align-content: start; }
.wire i { display: block; border-radius: 3px; background: color-mix(in srgb, var(--blue) 16%, transparent); height: 10px; }
.wire i.t { height: 22px; width: 70%; }
.wire i.img { height: 64px; }
.wire i.s { width: 45%; }
.wire i.b { width: 38%; height: 26px; background: var(--blue); }
/* code sheet */
.code { font: 400 13px/1.75 var(--mono); color: var(--ink); white-space: pre; overflow: hidden; }
.code .k { color: var(--blue); } .code .s { color: var(--signal-text); } .code .c { color: var(--slate); }

@media (max-width: 980px) {
  .deck-pin { padding: clamp(32px, 6vh, 56px) 0 24px; }
  .deck-grid { grid-template-columns: 1fr; gap: 36px; }
  .deck { height: auto; perspective: none; display: grid; gap: 16px; }
  .card { position: static; height: auto; width: auto; transform: none !important; opacity: 1 !important; }
  .card--launch img { aspect-ratio: 16 / 10; }
  .deck-steps { display: none; }
  .deck-copy .display .stage-word { color: var(--signal); }
}

/* ───────── sections ───────── */
.band { padding: clamp(68px, 10vh, 128px) 0; }
.band + .band { border-top: 1px solid var(--rule); }
.head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 20px 40px; margin-bottom: clamp(36px, 5vh, 64px); }
.head .lead { max-width: 42ch; }
.page-hero { padding: calc(var(--nav-h) + clamp(52px, 9vh, 110px)) 0 clamp(44px, 7vh, 84px); }
.page-hero .lead { margin-top: 24px; }
.page-hero .h1 { max-width: 16ch; }
.grid-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(18px, 2.4vw, 36px); }
.grid-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(16px, 2vw, 28px); }
@media (max-width: 900px) { .grid-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 700px) { .grid-2, .grid-3 { grid-template-columns: 1fr; } }

/* services: one sheet per job, with its tab */
.svc-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(18px, 2.4vw, 32px); margin-top: 20px; }
.svc-col { position: relative; background: var(--paper); border-radius: 0 var(--radius) var(--radius) var(--radius); box-shadow: var(--shadow); padding: clamp(20px, 2vw, 28px); display: flex; flex-direction: column; gap: 16px; }
.svc-group { display: flex; align-items: baseline; justify-content: space-between; font-family: var(--display); font-weight: 900; font-size: clamp(26px, 2.6vw, 36px); letter-spacing: -0.03em; padding-bottom: 12px; border-bottom: 2px solid var(--ink); }
.svc-group small { font: 400 12px var(--mono); color: var(--slate); letter-spacing: 0; }
.svc { display: flex; flex-direction: column; gap: 10px; flex: 1; padding: 0; box-shadow: none; border-radius: 0; background: none; border-top: 1px solid var(--rule); padding-top: 16px; }
.svc:first-of-type { border-top: 0; padding-top: 0; }
.svc .h3 { transition: color 0.2s; }
.svc:hover { transform: none; box-shadow: none; }
.svc:hover .h3 { color: var(--signal-text); }
.svc .tags { margin-top: auto; padding-top: 8px; }
@media (max-width: 940px) { .svc-grid { grid-template-columns: 1fr; gap: 44px; } }

/* work */
.case { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: clamp(24px, 4vw, 68px); align-items: center; }
.case + .case { margin-top: clamp(56px, 9vh, 112px); }
.case:nth-of-type(even) { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); }
.case:nth-of-type(even) .shot { order: 2; }
.case-meta { display: flex; flex-wrap: wrap; gap: 6px 14px; color: var(--slate); margin-bottom: 14px; }
.case-meta b { color: var(--signal-text); font-weight: 500; }
.case .h2 { font-size: clamp(28px, 3.2vw, 46px); }
.case p { color: var(--slate); margin: 16px 0 22px; max-width: 46ch; }
.shot { display: block; background: var(--paper); border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; transition: transform 0.35s var(--ease), box-shadow 0.35s; }
.shot-bar { display: flex; align-items: center; gap: 8px; padding: 10px 14px; border-bottom: 1px solid var(--rule); color: var(--slate); }
.shot-bar i { width: 8px; height: 8px; border-radius: 2px; background: var(--rule); }
.shot-bar span { margin-left: 6px; }
.shot-img { aspect-ratio: 16 / 10; overflow: hidden; }
.shot-img img { width: 100%; height: 100%; object-fit: cover; object-position: top; }
a.shot:hover { transform: translateY(-5px); box-shadow: 0 1px 2px rgba(11, 13, 18, 0.06), 0 30px 50px -22px rgba(11, 13, 18, 0.4); }
@media (max-width: 860px) { .case, .case:nth-of-type(even) { grid-template-columns: 1fr; } .case:nth-of-type(even) .shot { order: 0; } }

/* process: the same four stages as the hero, in order */
.steps { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: clamp(14px, 1.6vw, 24px); list-style: none; counter-reset: step; }
.step { position: relative; background: var(--paper); border-radius: var(--radius); box-shadow: var(--shadow); padding: clamp(18px, 2vw, 26px); counter-increment: step; }
.step::before { content: counter(step, decimal-leading-zero); display: block; font-family: var(--mono); font-size: 12.5px; color: var(--signal-text); margin-bottom: 36px; }
.step::after { content: ''; position: absolute; left: 0; top: 0; bottom: 0; width: 4px; background: var(--signal); border-radius: var(--radius) 0 0 var(--radius); }
.step p { color: var(--slate); font-size: 16px; margin-top: 8px; }
.step .tag { display: inline-block; margin-top: 16px; }
@media (max-width: 900px) { .steps { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 520px) { .steps { grid-template-columns: 1fr; } }

/* industries */
.ind { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(14px, 1.6vw, 24px); list-style: none; }
.ind > li { background: var(--paper); border-radius: var(--radius); box-shadow: var(--shadow); padding: clamp(18px, 2vw, 26px); display: flex; flex-direction: column; gap: 8px; transition: transform 0.25s var(--ease); }
.ind > li:hover { transform: translateY(-3px); }
.ind p { color: var(--slate); font-size: 15.5px; }
.ind .tags { margin-top: auto; padding-top: 12px; }
@media (max-width: 900px) { .ind { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) { .ind { grid-template-columns: 1fr; } }

/* closing call — the last sheet, ink on ink */
.cta { padding: clamp(72px, 11vh, 140px) 0; }
.cta .wrap > .sheet-in { background: var(--ink); color: #fff; border-radius: 10px; padding: clamp(36px, 6vw, 80px); --slate: #a6adbb; --signal-text: #ff8a4c; box-shadow: 0 30px 60px -30px rgba(11, 13, 18, 0.6); }
.cta .h1 { max-width: 14ch; font-size: clamp(36px, 5vw, 76px); }
.cta .lead { margin-top: 18px; }
.cta-row { display: flex; flex-wrap: wrap; align-items: center; gap: 16px 28px; margin-top: clamp(26px, 4vh, 40px); }
.cta .btn { background: var(--signal); border-color: var(--signal); color: #fff; }
.cta .btn:hover { background: #fff; border-color: #fff; color: var(--ink); }
.cta .link { color: #fff; }
.cta .link:hover { color: var(--signal-text); }
.cta :focus-visible { outline-color: #fff; }

/* footer */
.foot { padding: clamp(44px, 7vh, 76px) 0 28px; border-top: 1px solid var(--rule); }
.foot-top { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 3fr) minmax(0, 3fr); gap: 32px; }
.foot-top p { color: var(--slate); font-size: 15.5px; max-width: 36ch; margin-top: 14px; }
.foot h2 { font: 400 12.5px var(--mono); color: var(--slate); margin-bottom: 14px; }
.foot ul { list-style: none; display: grid; gap: 8px; }
.foot ul a { font-size: 15.5px; font-weight: 600; transition: color 0.2s; }
.foot ul a:hover { color: var(--signal-text); }
.foot-bot { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px 24px; margin-top: clamp(36px, 6vh, 60px); padding-top: 20px; border-top: 1px solid var(--rule); color: var(--slate); font-size: 14px; }
.foot-bot a:hover { color: var(--ink); }
@media (max-width: 760px) { .foot-top { grid-template-columns: 1fr 1fr; } .foot-top > :first-child { grid-column: 1 / -1; } }

/* ───────── inner pages ───────── */
.prose { max-width: 760px; font-size: 18px; line-height: 1.7; }
.prose > * + * { margin-top: 1.2em; }
.prose h2 { font-family: var(--display); font-weight: 900; font-size: clamp(26px, 2.8vw, 38px); letter-spacing: -0.03em; line-height: 1.08; margin-top: 1.9em; }
.prose h3 { font-family: var(--display); font-weight: 700; font-size: 22px; margin-top: 1.6em; }
.prose p, .prose li { color: #2b3140; }
.prose ul, .prose ol { padding-left: 1.2em; }
.prose a { border-bottom: 2px solid var(--signal); font-weight: 600; }
.prose a:hover { color: var(--signal-text); }
.prose img { border-radius: var(--radius); box-shadow: var(--shadow); width: 100%; }
.prose blockquote { border-left: 3px solid var(--signal); padding-left: 20px; font-size: 1.1em; }
.prose pre { background: var(--ink); color: #e9ebef; padding: 18px 20px; border-radius: var(--radius); overflow-x: auto; font: 400 14px/1.7 var(--mono); }
.prose code { font-family: var(--mono); font-size: 0.9em; }
.prose :not(pre) > code { background: var(--paper); border: 1px solid var(--rule); border-radius: 4px; padding: 1px 5px; }
.prose--wide { max-width: 900px; }
.band .prose { background: var(--paper); border-radius: var(--radius); box-shadow: var(--shadow); padding: clamp(24px, 4vw, 56px); max-width: 860px; }
.facts { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); background: var(--paper); border-radius: var(--radius); box-shadow: var(--shadow); margin-bottom: clamp(32px, 6vh, 60px); overflow: hidden; }
.facts > div { padding: 18px 20px; border-right: 1px solid var(--rule); }
.facts > div:last-child { border-right: 0; }
.facts dt { font: 400 12px var(--mono); color: var(--slate); margin-bottom: 6px; }
.facts dd { font-weight: 700; font-size: 16.5px; }
@media (max-width: 760px) { .facts { grid-template-columns: 1fr 1fr; } .facts > div:nth-child(2n) { border-right: 0; } .facts > div:nth-child(-n+2) { border-bottom: 1px solid var(--rule); } }
.timeline { list-style: none; background: var(--paper); border-radius: var(--radius); box-shadow: var(--shadow); padding: 0 clamp(20px, 3vw, 40px); }
.timeline li { display: grid; grid-template-columns: 170px minmax(0, 1fr); gap: 12px 32px; padding: 24px 0; border-bottom: 1px solid var(--rule); }
.timeline li:last-child { border-bottom: 0; }
.timeline .mono { color: var(--signal-text); padding-top: 5px; }
.timeline p { color: var(--slate); margin-top: 6px; max-width: 60ch; }
@media (max-width: 600px) { .timeline li { grid-template-columns: 1fr; gap: 6px; } }
.svc-detail { display: grid; grid-template-columns: minmax(0, 6fr) minmax(0, 5fr); gap: clamp(24px, 4vw, 72px); align-items: start; }
.svc-detail .lead { margin-top: 18px; color: var(--ink); }
.svc-detail .prose { font-size: 16.5px; margin-top: 16px; background: none; box-shadow: none; padding: 0; }
.svc-detail .tags { margin-top: 22px; }
.checks { list-style: none; margin-top: 4px; }
.checks li { display: flex; gap: 12px; padding: 13px 0; border-bottom: 1px solid var(--rule); font-size: 16px; }
.checks li:last-child { border-bottom: 0; padding-bottom: 0; }
.checks li::before { content: ''; flex: none; width: 8px; height: 8px; margin-top: 9px; background: var(--signal); border-radius: 2px; }
@media (max-width: 860px) { .svc-detail { grid-template-columns: 1fr; } }
.post-row { display: grid; grid-template-columns: 130px minmax(0, 1fr) auto; gap: 12px 28px; align-items: baseline; padding: 22px 20px; background: var(--paper); border-radius: var(--radius); box-shadow: var(--shadow); margin-bottom: 12px; transition: transform 0.25s var(--ease); }
.post-row .mono { color: var(--slate); }
.post-row:hover { transform: translateX(6px); }
.post-row:hover .h3 { color: var(--signal-text); }
@media (max-width: 640px) { .post-row { grid-template-columns: 1fr; gap: 6px; } }
.pager { margin-top: 32px; font-family: var(--mono); font-size: 14px; display: flex; gap: 8px; }
.pager .page-numbers { padding: 8px 12px; background: var(--paper); border-radius: 6px; box-shadow: var(--shadow); }
.pager .current { background: var(--ink); color: #fff; }
.form { display: grid; gap: 18px; background: var(--paper); border-radius: var(--radius); box-shadow: var(--shadow); padding: clamp(22px, 3vw, 40px); }
.form .row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.field label { display: block; font-weight: 700; font-size: 14.5px; margin-bottom: 7px; }
.field input, .field select, .field textarea { width: 100%; font: inherit; font-size: 16px; color: var(--ink); background: var(--paper-2); border: 1.5px solid var(--rule); border-radius: var(--radius); padding: 13px 14px; transition: border-color 0.2s; }
.field textarea { min-height: 170px; resize: vertical; }
.field input:hover, .field select:hover, .field textarea:hover { border-color: var(--slate); }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--blue); }
.hp { position: absolute; left: -9999px; }
.notice { background: var(--paper); border-left: 4px solid var(--signal); border-radius: var(--radius); box-shadow: var(--shadow); padding: 16px 20px; margin-bottom: 32px; font-weight: 600; }
.form .btn { justify-self: start; }
.stack { display: grid; gap: 18px; align-content: start; }
.stack .tile a { border-bottom: 2px solid var(--signal); }
@media (max-width: 600px) { .form .row2 { grid-template-columns: 1fr; } }
.case-nav { display: flex; flex-wrap: wrap; gap: 12px; margin-top: clamp(36px, 6vh, 60px); }

/* ───────── motion ───────── */
[data-reveal] { opacity: 0; transform: translateY(18px); transition: opacity 0.6s var(--ease), transform 0.6s var(--ease); transition-delay: calc(var(--i, 0) * 70ms); }
[data-reveal].is-in { opacity: 1; transform: none; }
.no-js [data-reveal] { opacity: 1; transform: none; }
@view-transition { navigation: auto; }
::view-transition-old(root) { animation: 0.2s ease both vt-out; }
::view-transition-new(root) { animation: 0.35s var(--ease) both vt-in; }
@keyframes vt-out { to { opacity: 0; } }
@keyframes vt-in { from { opacity: 0; transform: translateY(8px); } }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-delay: 0s !important; transition-duration: 0.01ms !important; }
  [data-reveal] { opacity: 1; transform: none; }
  .deck-pin { padding: 40px 0; } .card { transition: none; }
  .deck { height: auto; display: grid; gap: 16px; } .card { position: static; height: auto; transform: none !important; opacity: 1 !important; }
  ::view-transition-group(*), ::view-transition-old(*), ::view-transition-new(*) { animation: none !important; }
}

/* refinements after first render */
.deck-copy .display { font-size: clamp(40px, 6vw, 94px); }
@media (max-width: 980px) { .card--launch .card-body { height: auto; } .card--launch img { height: auto; } }

/* ───────── theme switch + dark mode ───────── */
.theme-switch { display: inline-flex; flex: none; padding: 3px; border: 1px solid var(--rule); border-radius: 7px; background: var(--paper); }
.theme-switch button { border: 0; background: none; font-family: var(--mono); font-size: 12px; padding: 6px 10px; border-radius: 4px; color: var(--slate); transition: background-color 0.2s, color 0.2s; }
.theme-switch button[aria-pressed="true"] { background: var(--ink); color: var(--canvas); }
.theme-switch button:not([aria-pressed="true"]):hover { color: var(--ink); }
@media (max-width: 940px) { .nav-in { gap: 12px; } }
@media (max-width: 380px) { .theme-switch button { padding: 6px 7px; } .logo { font-size: 19px; } }

html[data-theme="dark"] {
  --canvas: #14161c; --paper: #1d2027; --paper-2: #232731; --ink: #eef1f6; --slate: #9aa1ab; --rule: #2e333d;
  --signal-text: #ff8a4c; --blue: #7a93ff;
  --shadow: 0 1px 2px rgba(0, 0, 0, 0.4), 0 18px 40px -18px rgba(0, 0, 0, 0.7);
  color-scheme: dark;
}
@media (prefers-color-scheme: dark) {
  html:not([data-theme="light"]) {
    --canvas: #14161c; --paper: #1d2027; --paper-2: #232731; --ink: #eef1f6; --slate: #9aa1ab; --rule: #2e333d;
    --signal-text: #ff8a4c; --blue: #7a93ff;
    --shadow: 0 1px 2px rgba(0, 0, 0, 0.4), 0 18px 40px -18px rgba(0, 0, 0, 0.7);
    color-scheme: dark;
  }
}
/* surfaces that are ink-on-ink in light mode become paper-on-dark in dark mode */
html[data-theme="dark"] .cta .wrap > .sheet-in, html[data-theme="dark"] .prose pre { background: #0b0d12; }
html[data-theme="dark"] .btn { color: #14161c; background: var(--ink); border-color: var(--ink); }
html[data-theme="dark"] .btn:hover { background: var(--signal); border-color: var(--signal); color: #fff; }
html[data-theme="dark"] .btn--ghost { background: transparent; color: var(--ink); border-color: var(--rule); }
html[data-theme="dark"] .btn--ghost:hover { background: var(--paper); border-color: var(--ink); }
html[data-theme="dark"] .cta .btn { background: var(--signal); border-color: var(--signal); color: #fff; }
html[data-theme="dark"] .cta .btn:hover { background: var(--ink); border-color: var(--ink); color: #14161c; }
html[data-theme="dark"] .wire i { background: color-mix(in srgb, var(--blue) 28%, transparent); }
html[data-theme="dark"] .wire i.b { background: var(--blue); }
html[data-theme="dark"] .prose p, html[data-theme="dark"] .prose li { color: #cfd4dc; }
html[data-theme="dark"] .skip-link:focus { background: var(--paper); }
@media (prefers-color-scheme: dark) {
  html:not([data-theme="light"]) .cta .wrap > .sheet-in, html:not([data-theme="light"]) .prose pre { background: #0b0d12; }
  html:not([data-theme="light"]) .btn { color: #14161c; background: var(--ink); border-color: var(--ink); }
  html:not([data-theme="light"]) .btn:hover { background: var(--signal); border-color: var(--signal); color: #fff; }
  html:not([data-theme="light"]) .btn--ghost { background: transparent; color: var(--ink); border-color: var(--rule); }
  html:not([data-theme="light"]) .btn--ghost:hover { background: var(--paper); border-color: var(--ink); }
  html:not([data-theme="light"]) .cta .btn { background: var(--signal); border-color: var(--signal); color: #fff; }
  html:not([data-theme="light"]) .cta .btn:hover { background: var(--ink); border-color: var(--ink); color: #14161c; }
  html:not([data-theme="light"]) .wire i { background: color-mix(in srgb, var(--blue) 28%, transparent); }
  html:not([data-theme="light"]) .wire i.b { background: var(--blue); }
  html:not([data-theme="light"]) .prose p, html:not([data-theme="light"]) .prose li { color: #cfd4dc; }
}
html.is-switching::view-transition-old(root) { animation: none; }
html.is-switching::view-transition-new(root) { animation: 0.5s var(--ease) both vt-wipe; }
@keyframes vt-wipe { from { clip-path: inset(0 0 100% 0); } to { clip-path: inset(0); } }

/* launch sheet: a tall capture of the live site pans slowly inside the card, never cropped at the sides */
.card--launch .card-body { overflow: hidden; container-type: size; }
.card--launch img { width: 100%; height: auto; object-fit: unset; object-position: unset; animation: site-pan 18s ease-in-out infinite alternate; }
@keyframes site-pan { from { transform: translateY(0); } to { transform: translateY(min(0px, calc(100cqh - 100%))); } }
@media (max-width: 980px) { .card--launch .card-body { max-height: 420px; } }
@media (prefers-reduced-motion: reduce) { .card--launch img { animation: none; } }
