/* samuelprakoso.com
   Direction: "Type and nothing else" (tasteskill seed 994324770), Hanken Grotesk, rose grey and orange.
   Every colour and size below is a token; sections only pick a chapter. */

:root {
  --bg: #ebe5e3;
  --surface: #e1dad7;
  --ink: #2b2622;
  --muted: #574f4b;
  --accent: #a83c08;
  --accent-ink: #ffffff;
  --field: #e85a0c;       /* the hero's orange field */
  --field-pale: #fff4ea;  /* pale ink, display size only */
  --field-dark: #0f0d0c;  /* dark ink on the field */
  --peach: #ffd9bd;
  --apricot: #ffa463;     /* orange that reads on the ink field */

  --font: "Hanken Grotesk", system-ui, -apple-system, "Segoe UI", sans-serif;

  --step-small: clamp(0.8125rem, 0.79rem + 0.1vw, 0.875rem);
  --step-body: clamp(1.0625rem, 1rem + 0.25vw, 1.1875rem);
  --step-lead: clamp(1.25rem, 1.05rem + 0.75vw, 1.875rem);
  --step-head: clamp(2.75rem, 1.6rem + 4.2vw, 5.5rem);
  --step-display: clamp(5.5rem, 20vw, 20rem);

  --margin: clamp(1rem, 3vw, 3rem);
  --gutter: clamp(1rem, 2vw, 2rem);
  --pad: clamp(5rem, 9vw, 9rem);
  --bar: 4rem;

  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-expo: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-in-out: cubic-bezier(0.76, 0, 0.24, 1);
  --ease-soft: cubic-bezier(0.33, 1, 0.68, 1);
  --ease-exit: cubic-bezier(0.55, 0.055, 0.675, 0.19);
  --t-press: 140ms;
  --t-hover: 180ms;
  --t-ui: 240ms;
  --t-reveal: 800ms;
  --t-open: 1200ms;
  --stagger-line: 90ms;
  --stagger-item: 70ms;
}

/* ---------- chapters: each section is one field of colour ---------- */
[data-chapter="field"] { --c-bg: var(--field); --c-ink: var(--field-dark); --c-soft: var(--field-dark); --c-hi: var(--field-pale); }
[data-chapter="rose"]  { --c-bg: var(--bg); --c-ink: var(--ink); --c-soft: var(--muted); --c-hi: var(--accent); }
[data-chapter="dark"]  { --c-bg: var(--ink); --c-ink: var(--bg); --c-soft: #c9c0bc; --c-hi: var(--apricot); }
[data-chapter="stone"] { --c-bg: var(--surface); --c-ink: var(--ink); --c-soft: var(--muted); --c-hi: var(--accent); }
[data-chapter="peach"] { --c-bg: var(--peach); --c-ink: var(--ink); --c-soft: #5a4136; --c-hi: var(--accent); }
.chapter { background: var(--c-bg); color: var(--c-ink); }

/* ---------- reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; overflow-x: clip; }
body { margin: 0; background: var(--ink); color: var(--ink); font-family: var(--font); font-size: var(--step-body); line-height: 1.5; letter-spacing: -0.005em; font-kerning: normal; -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; overflow-x: clip; }
h1, h2, h3, p, figure, blockquote, ul, ol { margin: 0; }
ul, ol { padding: 0; list-style: none; }
img, svg { display: block; max-width: 100%; }
img { height: auto; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
a { color: inherit; }
ins { text-decoration: none; }
::selection { background: var(--accent); color: var(--accent-ink); }
:focus-visible { outline: 3px solid currentColor; outline-offset: 4px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.skip { position: fixed; left: var(--margin); top: 0.75rem; z-index: 100; padding: 0.6rem 1rem; background: var(--ink); color: var(--bg); border-radius: 999px; transform: translateY(-160%); transition: transform var(--t-ui) var(--ease-out); }
.skip:focus { transform: none; }

/* ---------- type ---------- */
h1, h2, h3 { font-weight: 500; text-wrap: balance; hyphens: none; }
.display { font-size: var(--step-display); font-weight: 500; line-height: 0.82; letter-spacing: -0.05em; }
.head { font-size: var(--step-head); font-weight: 500; line-height: 0.95; letter-spacing: -0.045em; }
.lead { font-size: var(--step-lead); line-height: 1.25; letter-spacing: -0.015em; }
.small { font-size: var(--step-small); line-height: 1.45; }
p { text-wrap: pretty; }
.nums { font-variant-numeric: tabular-nums; }

/* ---------- controls ---------- */
.button {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.6em;
  min-height: 3.25rem; padding: 0 1.6rem; border-radius: 999px;
  background: var(--c-ink); color: var(--c-bg);
  font-size: var(--step-body); font-weight: 500; text-decoration: none; white-space: nowrap;
  transition: transform var(--t-press) var(--ease-out), background-color var(--t-hover) ease, color var(--t-hover) ease;
  will-change: transform;
}
.button:active { transform: translate(var(--mx, 0), var(--my, 0)) scale(0.96); }
.button--accent { background: var(--apricot); color: var(--ink); }
.button__label { display: block; overflow: hidden; height: 1.5em; line-height: 1.5; }
.button__label span { display: block; transition: transform var(--t-ui) var(--ease-out); }
.button__label span::after { content: attr(data-text); display: block; }
@media (hover: hover) and (pointer: fine) {
  .button:hover .button__label span { transform: translateY(-50%); }
  .button--accent:hover { background: var(--bg); }
}

/* plain links: the underline grows from the left */
.ul { text-decoration: none; background: none; position: relative; }
.ul::after { content: ""; position: absolute; left: 0; right: 0; bottom: -0.08em; height: 0.08em; min-height: 2px; background: currentColor; transform: scaleX(0); transform-origin: right; transition: transform var(--t-ui) var(--ease-out); }
.ul.is-current::after { transform: scaleX(1); }
@media (hover: hover) and (pointer: fine) {
  .ul:hover::after { transform: scaleX(1); transform-origin: left; }
}

/* ---------- the bar ---------- */
.bar {
  position: fixed; inset: 0 0 auto 0; z-index: 40; height: var(--bar);
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  padding-inline: var(--margin);
  background: var(--c-bg); color: var(--c-ink);
  font-size: var(--step-small); font-weight: 500;
  transition: background-color 300ms ease, color 300ms ease, transform 420ms var(--ease-out);
}
.bar.is-hidden { transform: translateY(-100%); }
.bar__mark { text-decoration: none; font-size: var(--step-body); letter-spacing: -0.02em; }
.bar__nav { display: flex; gap: clamp(1rem, 2.4vw, 2.25rem); font-size: var(--step-body); }
.bar__nav a { text-decoration: none; }
.bar__menu { display: none; font-size: var(--step-body); font-weight: 500; min-height: 2.75rem; padding: 0 0.25rem; }

/* full-screen menu for phones: opens from the button it was asked for */
.menu {
  position: fixed; inset: 0; z-index: 60; display: flex; flex-direction: column; justify-content: space-between;
  padding: calc(var(--bar) + 1.5rem) var(--margin) 2rem;
  background: var(--field); color: var(--field-dark);
  clip-path: circle(0% at calc(100% - 2.5rem) 2rem);
  transition: clip-path 700ms var(--ease-in-out);
}
.menu[hidden] { display: none; }
.menu.is-open { clip-path: circle(150% at calc(100% - 2.5rem) 2rem); }
.menu__close { position: absolute; top: 0; right: var(--margin); height: var(--bar); font-weight: 500; }
.menu__links a { display: block; font-size: 17vw; line-height: 1; letter-spacing: -0.05em; font-weight: 500; text-decoration: none; padding-block: 0.04em; }
.menu__links li { overflow: hidden; }
.menu__links li a { transform: translateY(105%); transition: transform 600ms var(--ease-expo); }
.menu.is-open .menu__links li a { transform: none; transition-delay: calc(250ms + var(--i) * 70ms); }
.menu__foot { font-size: var(--step-body); }
.menu__foot a { font-weight: 500; }

/* ---------- hero: its type scrolls slower than the page and parts sideways ---------- */
.hero {
  position: relative; z-index: 0;
  height: 100svh; min-height: 34rem;
  display: flex; flex-direction: column; justify-content: space-between;
  padding: max(15svh, calc(var(--bar) + 2rem)) var(--margin) clamp(1.5rem, 4svh, 3rem);
  overflow: clip;
}
.hero::after { content: ""; position: absolute; inset: 0; background: var(--ink); opacity: var(--cover, 0); pointer-events: none; }
.hero__title { margin-left: -0.04em; transform: translate3d(0, var(--ty, 0), 0); }
.hero__title .line { display: block; overflow: clip; padding-bottom: 0.1em; margin-bottom: -0.1em; white-space: nowrap; transform: translate3d(var(--px, 0), 0, 0); }
.hero__title [data-line] { display: block; }
.hero__l1 { color: var(--field-pale); }
.hero__l2 { color: var(--field-dark); }
.hero__foot { display: flex; align-items: flex-end; justify-content: space-between; gap: 2rem; transform: translate3d(0, var(--fy, 0), 0); opacity: var(--fo, 1); }
.hero__lead { max-width: 38ch; }

/* a struck-out phrase: the line is drawn, then the correction follows */
.strike { position: relative; white-space: nowrap; text-decoration: line-through; text-decoration-thickness: 0.09em; }
.js .strike { text-decoration: none; }
.js .strike::after { content: ""; position: absolute; left: -0.05em; right: -0.05em; top: 52%; height: 0.09em; min-height: 2px; background: currentColor; transform: scaleX(var(--strike, 1)); transform-origin: left; transition: transform 700ms var(--ease-in-out); }
.del-ink { color: var(--c-soft); }

/* ---------- about: the self-edited bio ---------- */
.about { position: relative; z-index: 1; padding: var(--pad) var(--margin); }
.about__top { display: flex; align-items: flex-end; justify-content: space-between; gap: 1.5rem; flex-wrap: wrap; margin-bottom: clamp(2.5rem, 5vw, 4.5rem); }

.mode { position: relative; display: inline-grid; grid-template-columns: 1fr 1fr; background: var(--surface); border-radius: 999px; padding: 0.3rem; }
.mode__thumb { position: absolute; top: 0.3rem; bottom: 0.3rem; left: 0.3rem; width: calc(50% - 0.3rem); border-radius: 999px; background: var(--ink); transition: transform 420ms var(--ease-out); }
.mode[data-mode="formal"] .mode__thumb { transform: translateX(100%); }
.mode__opt { position: relative; z-index: 1; min-height: 2.75rem; padding: 0 1.4rem; border-radius: 999px; font-weight: 500; transition: color var(--t-ui) ease, background-color 0s; }
/* the thumb slides across; the pressed button takes its colour when it arrives */
.mode__opt[aria-pressed="true"] { color: var(--bg); background: var(--ink); transition: color var(--t-ui) ease, background-color 0s linear 400ms; }
.mode__opt:active { transform: scale(0.96); }

.bio { columns: 2; column-gap: var(--gutter); font-size: var(--step-lead); line-height: 1.22; letter-spacing: -0.015em; hyphens: auto; transition: opacity 260ms ease, transform 420ms var(--ease-out); }
.bio p { margin-bottom: 0.9em; break-inside: avoid-column; }
.bio strong { font-weight: 500; }
.bio.is-switching { opacity: 0; transform: translateY(10px); transition-duration: 180ms; }
.bio[data-mode="formal"] .strike,
.bio[data-mode="formal"] [data-only="friendly"] { display: none; }
.bio .go { display: inline-block; margin-top: 0.4em; }

/* highlighter marks: the colour is real; a cover in the page colour slides off it, left to right */
.hl { position: relative; z-index: 0; white-space: nowrap; padding: 0 0.12em; margin: 0 -0.02em; color: var(--ink); background: var(--hl, var(--peach)); }
.hl::before { content: ""; position: absolute; inset: -1px; z-index: -1; background: var(--c-bg); transform: scaleX(var(--cover, 0)); transform-origin: right; transition: transform 700ms var(--ease-out); transition-delay: var(--d, 0ms); }
.hl--field { --hl: var(--field); color: var(--field-dark); }
.hl--ink { --hl: var(--ink); color: var(--bg); }
.hl--go { --hl: var(--accent); color: var(--accent-ink); text-decoration: none; white-space: normal; box-decoration-break: clone; -webkit-box-decoration-break: clone; }
.hl--go::before { display: none; }
@media (hover: hover) and (pointer: fine) {
  .hl--go { transition: background-color var(--t-hover) ease; }
  .hl--go:hover { background: var(--ink); }
}

/* ---------- services: one per poster line ---------- */
.services { position: relative; z-index: 1; padding: var(--pad) var(--margin); overflow: clip; }
.services__top { display: flex; justify-content: space-between; align-items: flex-end; gap: 2rem; flex-wrap: wrap; margin-bottom: clamp(2rem, 5vw, 4rem); }
.services__top p { max-width: 34ch; }
/* the fact sits under its word, so even the longest word can run the full width */
.poster__item { display: flex; flex-direction: column; align-items: flex-start; gap: 0.35rem; margin-bottom: clamp(1.35rem, 2.5vw, 2.25rem); cursor: default; }
.poster__word { display: block; font-size: var(--step-display); line-height: 0.92; letter-spacing: -0.05em; font-weight: 500; white-space: nowrap; transform: translate3d(var(--px, 0), 0, 0); }
.poster__word span { display: inline-block; transition: color var(--t-hover) ease, transform 500ms var(--ease-out); }
.poster__note { color: var(--c-soft); transition: color var(--t-hover) ease; }
@media (hover: hover) and (pointer: fine) {
  .poster__item:hover .poster__word span { color: var(--apricot); transform: translateX(0.06em); }
  .poster__item:hover .poster__note { color: var(--c-ink); }
}

/* ---------- portfolio: the bookshelf ---------- */
.work { position: relative; z-index: 1; padding: var(--pad) var(--margin) calc(var(--pad) * 0.8); }
.work__top { display: flex; justify-content: space-between; align-items: flex-end; gap: 2rem; flex-wrap: wrap; margin-bottom: clamp(2.5rem, 5vw, 4rem); }
.work__top p { max-width: 38ch; }
/* one shelf of every book: full titles up the spines, the one you pick read out below */
.shelf { display: flex; align-items: flex-end; gap: 6px; height: 32rem; }
.spine {
  --s-bg: var(--bg); --s-ink: var(--ink);
  flex: var(--w, 1) 1 0; min-width: 0; height: var(--h, 90%);
  display: flex; flex-direction: column; align-items: center; justify-content: space-between; gap: 0.75rem;
  padding: 1rem 0.4rem 0.9rem; background: var(--s-bg); color: var(--s-ink);
  text-align: left; transform-origin: bottom center;
  transition: transform 360ms var(--ease-out), background-color var(--t-hover) ease;
}
.spine > span { writing-mode: vertical-rl; }
.spine__title { flex: 1 1 auto; min-height: 0; overflow: hidden; font-size: var(--step-body); font-weight: 500; line-height: 1.25; letter-spacing: -0.01em; }
.spine__year { flex: none; white-space: nowrap; font-size: var(--step-small); font-variant-numeric: tabular-nums; }
.spine[data-kind="book"] { --s-bg: var(--ink); --s-ink: var(--bg); }
.spine[data-kind="cowritten"] { --s-bg: var(--field); --s-ink: var(--field-dark); }
.spine[data-kind="guide"] { --s-bg: var(--peach); --s-ink: var(--ink); }
.spine[data-kind="novel"] { --s-bg: var(--accent); --s-ink: var(--accent-ink); }
.spine.is-active { transform: translateY(-1.25rem); }
.spine:active { transform: translateY(-0.75rem) scale(0.98); }
.spine:focus-visible { outline-color: var(--ink); }
.plank { height: 0.875rem; background: var(--ink); }
.reader { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gutter); margin-top: clamp(1.75rem, 3vw, 2.5rem); min-height: 4.5em; }
.reader__title { grid-column: 1 / 8; font-size: var(--step-lead); line-height: 1.2; letter-spacing: -0.015em; font-weight: 500; }
.reader__meta { grid-column: 9 / 13; }
/* laptops: smaller type on the spines so all twenty still stand on one shelf */
@media (max-width: 89.99rem) {
  .shelf { height: 30rem; gap: 4px; }
  .spine { gap: 0.5rem; padding: 0.8rem 0.25rem 0.75rem; }
  .spine__title { font-size: var(--step-small); }
}
/* tablets and phones: the shelf becomes a list of titles */
@media (max-width: 60rem) {
  .shelf { height: auto; flex-wrap: wrap; gap: 10px; }
  .spine { flex: 0 1 auto; height: auto; flex-direction: row; align-items: baseline; gap: 0.6rem; padding: 0.55rem 0.85rem; border-radius: 0.4rem; }
  .spine > span { writing-mode: horizontal-tb; }
  .spine__title { overflow: visible; font-size: var(--step-body); }
  .spine.is-active, .js .work .shelf.is-in .spine.is-active { transform: translateY(-3px); }
  .plank { display: none; }
  .reader__title, .reader__meta { grid-column: 1 / 13; }
  .reader__meta { margin-top: 0.4rem; }
}
.reader.is-swapping > * { opacity: 0; transform: translateY(8px); }
.reader > * { transition: opacity 260ms ease, transform 360ms var(--ease-out); }

/* ---------- since 2002: the year holds still while the milestones pass ---------- */
.timeline { position: relative; z-index: 1; padding: var(--pad) var(--margin); }
.timeline__top { display: flex; justify-content: space-between; align-items: flex-end; gap: 2rem; flex-wrap: wrap; margin-bottom: clamp(2.5rem, 5vw, 4.5rem); }
.timeline__top p { max-width: 34ch; }
.timeline__body { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gutter); }
.timeline__stage { display: none; grid-column: 1 / 7; align-self: start; position: sticky; top: calc(50svh - 0.45 * var(--step-display)); overflow: clip; }
.timeline__year { display: block; font-size: var(--step-display); line-height: 0.9; letter-spacing: -0.05em; font-weight: 500; color: var(--field-pale); white-space: nowrap; }
.timeline__list { grid-column: 1 / 13; }
.mile { padding-bottom: clamp(2.5rem, 5vw, 3.5rem); }
.mile__title { font-size: var(--step-lead); line-height: 1.15; letter-spacing: -0.015em; font-weight: 500; margin-bottom: 0.6rem; }
.mile__year { display: block; font-size: var(--step-head); line-height: 1; letter-spacing: -0.045em; margin-bottom: 0.4rem; }
.mile p { max-width: 40ch; }
.mile__link { font-weight: 500; text-decoration-thickness: 0.08em; text-underline-offset: 0.15em; }
@media (min-width: 60.0625rem) {
  .js .timeline__stage { display: block; }
  .js .timeline__list { grid-column: 8 / 13; }
  .js .mile { min-height: 34svh; }
  /* the big year on the left says it; the inline one stays for screen readers */
  .js .mile__year { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
}

/* ---------- blog: the line-up ---------- */
.blog { position: relative; z-index: 1; padding: var(--pad) var(--margin); }
.blog__top { display: flex; justify-content: space-between; align-items: flex-end; gap: 2rem; flex-wrap: wrap; margin-bottom: clamp(1.5rem, 3vw, 2.5rem); }
.blog__top p { max-width: 36ch; }
.lineup { font-size: var(--step-lead); line-height: 1.2; letter-spacing: -0.015em; }
.lineup__year { padding: 2.5rem 0 0.75rem; color: var(--accent); font-size: var(--step-lead); font-variant-numeric: tabular-nums; }
.row { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gutter); align-items: baseline; padding: 0.55em 0.5rem; margin-inline: -0.5rem; text-decoration: none; border-radius: 0.4rem; transition: background-color var(--t-hover) ease; }
.row__title { grid-column: 1 / 9; transition: transform 400ms var(--ease-out); }
.row__cat { grid-column: 9 / 11; color: var(--c-soft); }
.row__date { grid-column: 11 / 13; text-align: right; font-variant-numeric: tabular-nums; }
@media (hover: hover) and (pointer: fine) {
  .row:hover { background: var(--bg); }
  .row:hover .row__title { transform: translateX(0.4rem); }
}
.blog__all { margin-top: clamp(2rem, 4vw, 3rem); }

/* ---------- blog list and category pages ---------- */
.bloghead { position: relative; z-index: 1; padding: calc(var(--bar) + clamp(2.5rem, 8svh, 6rem)) var(--margin) clamp(2.5rem, 5vw, 4.5rem); }
/* the title runs as large as the hero, but never wider than the page: --len is its letter count */
.bloghead__title { font-size: min(var(--step-display), calc((100vw - 2 * var(--margin)) / (var(--len, 4) * 0.52))); font-weight: 500; line-height: 0.82; letter-spacing: -0.05em; margin-left: -0.04em; white-space: nowrap; }
.bloghead__foot { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gutter); row-gap: 1.75rem; align-items: end; margin-top: clamp(2rem, 4vw, 3.5rem); }
.bloghead__lead { grid-column: 1 / 6; }
.cats { grid-column: 7 / 13; display: flex; flex-wrap: wrap; gap: 0.5rem; justify-content: flex-end; }
.cat { display: inline-flex; align-items: baseline; gap: 0.45em; min-height: 2.75rem; padding: 0.65rem 1.05rem; border-radius: 999px; background: var(--bg); color: var(--ink); text-decoration: none; font-weight: 500; line-height: 1.1; transition: background-color var(--t-hover) ease, color var(--t-hover) ease, transform var(--t-press) var(--ease-out); }
.cat__n { font-size: var(--step-small); font-weight: 400; color: var(--muted); font-variant-numeric: tabular-nums; transition: color var(--t-hover) ease; }
.cat.is-current { background: var(--ink); color: var(--bg); }
.cat.is-current .cat__n { color: #c9c0bc; }
.cat:active { transform: scale(0.96); }
@media (hover: hover) and (pointer: fine) {
  .cat:hover { background: var(--ink); color: var(--bg); }
  .cat:hover .cat__n { color: #c9c0bc; }
}

.archive { position: relative; z-index: 1; padding: clamp(1rem, 2vw, 2rem) var(--margin) var(--pad); }
.row--full .row__desc { grid-column: 1 / 9; max-width: 62ch; margin-top: 0.4rem; font-size: var(--step-body); line-height: 1.45; letter-spacing: 0; color: var(--c-ink); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.row--full { padding-block: 0.8em; }
@media (hover: hover) and (pointer: fine) {
  .archive .row:hover { background: var(--surface); }
}

/* ---------- one post ---------- */
.post__head { position: relative; z-index: 1; padding: calc(var(--bar) + clamp(2.5rem, 7svh, 5rem)) var(--margin) clamp(2.5rem, 5vw, 4rem); }
/* long titles shrink until they fit on two lines, but never below 24px: --len is the title's length */
.post__title { font-size: clamp(1.5rem, calc((100vw - 2 * var(--margin)) * 3.8 / var(--len, 30)), var(--step-head)); font-weight: 500; line-height: 1.02; letter-spacing: -0.045em; max-width: 30ch; text-wrap: balance; }
.post__meta { margin-top: clamp(1.25rem, 2.5vw, 2rem); color: var(--c-soft); }
.post__meta a { color: var(--c-ink); }
.post__body { position: relative; z-index: 1; padding: clamp(2.5rem, 5vw, 4.5rem) var(--margin) var(--pad); }
.post__cover { max-width: 60rem; margin: 0 auto clamp(2rem, 4vw, 3.5rem); }
.post__cover img { width: 100%; height: auto; }

/* the reading column: one measure, set in the page's text face */
.prose { max-width: 42rem; margin-inline: auto; font-size: var(--step-body); line-height: 1.65; overflow-wrap: break-word; }
.prose > * + * { margin-top: 1.15em; }
.prose h2 { font-size: var(--step-lead); line-height: 1.2; letter-spacing: -0.015em; margin-top: 2.2em; }
.prose h3, .prose h4 { font-size: var(--step-body); font-weight: 500; margin-top: 1.9em; }
.prose h2 + *, .prose h3 + *, .prose h4 + * { margin-top: 0.6em; }
.prose a { color: var(--accent); text-decoration: underline; text-decoration-thickness: 0.08em; text-underline-offset: 0.16em; transition: color var(--t-hover) ease; }
.prose strong { font-weight: 500; }
.prose ul, .prose ol { padding-left: 1.35em; }
.prose ul { list-style: disc; }
.prose ol { list-style: decimal; }
.prose li + li { margin-top: 0.4em; }
.prose li::marker { color: var(--c-soft); }
.prose img { display: block; max-width: 100%; height: auto; margin-inline: auto; }
.prose blockquote { padding: 1.1rem 1.35rem; background: var(--surface); border-radius: 0.5rem; }
.prose code { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 0.86em; background: var(--surface); padding: 0.12em 0.4em; border-radius: 0.3rem; }
.prose pre { background: var(--ink); color: var(--bg); padding: 1.2rem 1.35rem; border-radius: 0.5rem; overflow-x: auto; font-size: var(--step-small); line-height: 1.6; }
.prose pre code { background: none; padding: 0; font-size: inherit; color: inherit; border-radius: 0; }
.prose table { width: 100%; border-collapse: collapse; font-size: var(--step-small); }
.prose th, .prose td { text-align: left; padding: 0.6rem 0.75rem; border-bottom: 1px solid var(--surface); }
.prose iframe { display: block; width: 100%; aspect-ratio: 16 / 9; height: auto; border: 0; }
.prose hr { border: 0; margin: 3em 0; }
@media (hover: hover) and (pointer: fine) {
  .prose a:hover { color: var(--ink); }
}
.codeblock { position: relative; }
.copy--code { position: absolute; top: 0.55rem; right: 0.55rem; min-height: 2.25rem; padding: 0 0.85rem; margin: 0; background: var(--bg); color: var(--ink); font-size: var(--step-small); }

/* keep reading: three more posts as rows, then everything */
.more { position: relative; z-index: 1; padding: var(--pad) var(--margin); }
.more__title { margin-bottom: clamp(1.5rem, 3vw, 2.5rem); }
.more__item { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gutter); align-items: baseline; padding: 1.1rem 0.5rem; margin-inline: -0.5rem; border-radius: 0.4rem; text-decoration: none; transition: background-color var(--t-hover) ease; }
.more__date { grid-column: 1 / 3; color: var(--c-soft); font-variant-numeric: tabular-nums; }
.more__name { grid-column: 3 / 10; font-size: var(--step-lead); line-height: 1.2; letter-spacing: -0.015em; transition: transform 400ms var(--ease-out); }
.more__cat { grid-column: 10 / 13; text-align: right; color: var(--c-soft); }
.more__all { margin-top: clamp(1.75rem, 3vw, 2.5rem); }
@media (hover: hover) and (pointer: fine) {
  .more__item:hover { background: var(--bg); }
  .more__item:hover .more__name { transform: translateX(0.4rem); }
}

/* the ask: a field of orange after every post */
.ask { position: relative; z-index: 1; padding: var(--pad) var(--margin); }
.ask__foot { display: flex; justify-content: space-between; align-items: flex-end; gap: 2rem; flex-wrap: wrap; margin-top: clamp(1.5rem, 3vw, 2.5rem); }
.ask__foot .lead { max-width: 30ch; }
.ask__actions { display: flex; align-items: center; gap: 1.25rem; flex-wrap: wrap; }
.ask__mail { font-weight: 500; }

@media (max-width: 60rem) {
  .bloghead__lead, .cats { grid-column: 1 / 13; }
  .cats { justify-content: flex-start; }
  .row--full .row__desc { grid-column: 1 / 13; order: 2; }
  .more__date { grid-column: 1 / 7; grid-row: 1; font-size: var(--step-small); }
  .more__cat { grid-column: 7 / 13; grid-row: 1; font-size: var(--step-small); }
  .more__name { grid-column: 1 / 13; grid-row: 2; margin-top: 0.3rem; }
}

/* ---------- 404 ---------- */
.lost { position: relative; z-index: 1; min-height: 100svh; display: flex; flex-direction: column; justify-content: space-between; gap: 2.5rem; padding: max(15svh, calc(var(--bar) + 2rem)) var(--margin) clamp(2rem, 5svh, 3.5rem); }
.lost__title { font-size: var(--step-display); font-weight: 500; line-height: 0.82; letter-spacing: -0.05em; margin-left: -0.04em; }
.lost__code { color: var(--field-pale); }
.lost__foot { display: flex; justify-content: space-between; align-items: flex-end; gap: 2rem; flex-wrap: wrap; }
.lost__foot .lead { max-width: 32ch; }
.lost__actions { display: flex; align-items: center; gap: 1.25rem; flex-wrap: wrap; }
.lost__blog { font-weight: 500; }
@media (max-width: 40rem) {
  .lost { min-height: 0; justify-content: flex-start; gap: 2.5rem; padding-bottom: 4rem; }
}

/* ---------- contact: address in display rows ---------- */
.contact { position: relative; z-index: 1; padding: 0 0 0; }
.crow { display: flex; align-items: flex-end; justify-content: space-between; gap: 1.5rem; min-height: clamp(6rem, 10vw, 9.5rem); padding: 0 var(--margin) clamp(1rem, 1.6vw, 1.5rem); font-size: var(--step-head); line-height: 1; letter-spacing: -0.045em; font-weight: 500; }
.crow:nth-child(even) { background: var(--surface); }
.crow > a, .crow > p, .crow > h2 { font-size: inherit; }
.crow a { text-decoration: none; }
.crow__note { font-size: var(--step-body); letter-spacing: -0.005em; font-weight: 400; color: var(--c-soft); text-align: right; max-width: 22ch; line-height: 1.35; padding-bottom: 0.3em; }
.avatar[hidden] { display: none; }
.avatar { position: relative; flex: 0 0 auto; width: clamp(4.5rem, 7vw, 6.5rem); aspect-ratio: 1; border-radius: 50%; overflow: clip; background: var(--field); display: grid; place-items: center; color: var(--field-dark); font-size: var(--step-body); letter-spacing: -0.02em; }
.avatar img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.copy { flex: 0 0 auto; min-height: 2.75rem; padding: 0 1.2rem; border-radius: 999px; background: var(--ink); color: var(--bg); font-size: var(--step-body); letter-spacing: 0; font-weight: 500; margin-bottom: 0.2em; transition: transform var(--t-press) var(--ease-out), background-color var(--t-hover) ease; }
.copy:active { transform: scale(0.95); }
.copy.is-done { background: var(--accent); }
.crow--go { background: var(--accent) !important; color: var(--accent-ink); }
.go-row { display: flex; align-items: center; gap: 0.35em; }
.go-btn { display: grid; place-items: center; width: 0.9em; height: 0.9em; border-radius: 50%; background: var(--accent-ink); color: var(--accent); transition: transform 420ms var(--ease-out); }
.go-btn svg { width: 45%; height: 45%; }
@media (hover: hover) and (pointer: fine) {
  .go-row:hover .go-btn { transform: rotate(-45deg) scale(1.08); }
  .crow a.ul-big:hover { color: var(--accent); }
}
.crow a.ul-big { transition: color var(--t-hover) ease; }

/* ---------- footer: the curtain ---------- */
.page { position: relative; z-index: 1; }
.foot {
  position: sticky; bottom: 0; z-index: 0;
  min-height: 100svh;
  display: grid; grid-template-rows: auto 1fr auto auto;
  padding: 2.5rem var(--margin) 1.25rem;
  font-size: var(--step-body);
}
.foot__cols { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gutter); row-gap: 2rem; }
.foot__cols > :first-child { grid-column: 1 / 7; }
.foot__cols > :nth-child(2) { grid-column: 7 / 10; }
.foot__cols > :last-child { grid-column: 10 / 13; }
.foot__cols p:first-child, .foot__cols .foot__h { color: var(--c-ink); font-weight: 500; margin-bottom: 0.6rem; }
.foot__cols li, .foot__cols p { color: var(--c-soft); }
.foot__cols a { text-decoration: none; }
.foot__cols .button { margin-top: 1.25rem; }
.foot__mark { display: block; width: 100%; margin-top: 2rem; overflow: clip; }
.foot__mark svg { width: 100%; height: auto; overflow: visible; fill: var(--c-ink); }
.foot__mark text { font-family: var(--font); font-weight: 500; letter-spacing: -0.05em; }
.foot__legal { margin-top: 0.75rem; font-size: var(--step-small); color: var(--c-soft); display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap; }

/* ---------- motion (content stays visible without JavaScript) ---------- */
@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }

  .js .hero [data-line] { transform: translateY(105%); animation: line-up 1000ms var(--ease-expo) forwards; animation-delay: calc(120ms + var(--i) * 110ms); }
  .js .hero [data-load] { opacity: 0; transform: translateY(14px); animation: rise 600ms var(--ease-out) forwards; animation-delay: var(--d); }
  .js .hero .strike { --strike: 0; }
  .js .hero.is-struck .strike { --strike: 1; }

  .js [data-reveal] { opacity: 0; transform: translateY(24px); transition: opacity 700ms var(--ease-out), transform 900ms var(--ease-expo); transition-delay: var(--d, 0ms); }
  .js [data-reveal].is-in { opacity: 1; transform: none; }

  .js .bio .hl { --cover: 1; }
  .js .bio.is-in .hl { --cover: 0; }
  .js .bio .strike { --strike: 0; }
  .js .bio.is-in .strike { --strike: 1; transition-delay: calc(var(--d, 0ms) + 300ms); }

  .js .poster__item { opacity: 0; transform: translateY(40px); transition: opacity 700ms var(--ease-out), transform 1000ms var(--ease-expo); }
  .js .poster__item.is-in { opacity: 1; transform: none; }

  .js .shelf .spine { opacity: 0; transform: translateY(3rem); }
  .js .shelf.is-in .spine { opacity: 1; transform: none; transition: opacity 600ms var(--ease-out) calc(var(--i) * 45ms), transform 900ms var(--ease-expo) calc(var(--i) * 45ms), background-color var(--t-hover) ease; }
  .js .shelf.is-in .spine.is-active { transform: translateY(-1.25rem); transition-delay: 0ms; }
  .js .shelf.is-in .spine:active { transform: translateY(-0.75rem) scale(0.98); }

  .js .mile { opacity: 0; transform: translateY(32px); transition: opacity 700ms var(--ease-out), transform 1000ms var(--ease-expo); }
  .js .mile.is-in { opacity: 1; transform: none; }

  .js .lineup .row { opacity: 0; transform: translateY(16px); }
  .js .lineup.is-in .row { opacity: 1; transform: none; transition: opacity 600ms var(--ease-out) calc(var(--i, 0) * 60ms), transform 800ms var(--ease-expo) calc(var(--i, 0) * 60ms), background-color var(--t-hover) ease; }

  .js .crow { opacity: 0; transform: translateY(28px); transition: opacity 700ms var(--ease-out), transform 900ms var(--ease-expo); transition-delay: calc(var(--i, 0) * 70ms); }
  .js .rows.is-in .crow { opacity: 1; transform: none; }

  .js .foot__mark text { transform: translateY(40%); opacity: 0; transition: transform 1100ms var(--ease-expo), opacity 600ms ease; }
  .js .foot__mark.is-in text { transform: none; opacity: 1; }
}
@keyframes line-up { to { transform: none; } }
@keyframes rise { to { opacity: 1; transform: none; } }

@media (prefers-reduced-motion: reduce) {
  .menu, .menu__links li a, .bar { transition: none; }
  .menu__links li a { transform: none; }
}

/* ---------- tablet ---------- */
@media (max-width: 60rem) {
  :root { --step-display: 22vw; }
  /* the sentence follows the name instead of waiting at the foot of the screen */
  .hero { justify-content: flex-start; gap: clamp(2rem, 5svh, 3rem); height: auto; min-height: 0; padding-bottom: clamp(4rem, 10svh, 6rem); }
  .hero__foot { flex-direction: column; align-items: flex-start; gap: 1.5rem; }
  .bio { columns: 1; max-width: 36ch; }
  .row__title { grid-column: 1 / 13; }
  .row__cat { grid-column: 1 / 7; font-size: var(--step-small); padding-top: 0.3rem; }
  .row__date { grid-column: 7 / 13; font-size: var(--step-small); padding-top: 0.3rem; }
  .crow--clock { flex-direction: column; align-items: flex-start; justify-content: flex-end; gap: 0.35rem; }
  .crow--clock .crow__note { text-align: left; max-width: none; padding: 0; }
  .foot__cols > :first-child { grid-column: 1 / 13; }
  .foot__cols > :nth-child(2) { grid-column: 1 / 7; }
  .foot__cols > :last-child { grid-column: 7 / 13; }
}

/* ---------- phone: five sizes, small 13 · body 17 · lead 20 · head 38 · display 86 ---------- */
@media (max-width: 40rem) {
  :root { --bar: 3.5rem; --step-display: 22vw; --step-head: 2.4rem; --step-lead: 1.25rem; }
  .bar__nav { display: none; }
  .bar__menu { display: block; }
  .hero { padding-top: 16svh; }
  .hero__foot { gap: 1.25rem; }
  .hero__lead { max-width: none; line-height: 1.3; }
  .bio { line-height: 1.3; hyphens: manual; max-width: none; }
  .crow { min-height: 5.25rem; padding-inline: 1rem; flex-wrap: wrap; align-items: flex-end; row-gap: 0.5rem; }
  .crow__note { text-align: left; padding: 0; }
  .crow--clock { align-items: flex-start; }
  .crow--email { flex-direction: column; align-items: flex-start; padding-top: 1rem; }
  .avatar { width: 3.75rem; }
  .foot { position: relative; min-height: auto; padding-top: 2rem; }
  .foot__cols { row-gap: 2rem; }
  .foot__mark { margin-top: 20svh; }
}
