/*
  dymarkowski.com / The Manager People Stay For
  site.css

  Version history (newest first)
  v1.5.0  18.10.2026  Back-to-top button stays to the very bottom; the footer link hides when the button works;
                      more room under the footer wordmark on small screens.
  v1.4.0  18.10.2026  Floating back-to-top button with a scroll progress ring.
  v1.3.0  18.10.2026  Custom cursor (coral dot) removed; the normal system cursor is back.
  v1.2.0  14.10.2026  Footer columns flow with flex, so hidden columns leave no gap.
  v1.1.0  14.10.2026  Author photo: fills the frame, slightly darkened, soft vignette.
  v1.0.0  14.10.2026  First release: brand tokens, opening animation, side rail, sections 01 to 08,
                      footer, custom cursor, reduced-motion and mobile fallbacks.
*/

/* ---------- Fonts (self-hosted, subset to Latin + Polish letters) ---------- */
@font-face {
  font-family: "Newsreader";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url(../fonts/newsreader-latin.woff2) format("woff2");
  unicode-range: U+0000-00FF, U+2000-206F, U+20AC, U+2122, U+2190-2193, U+2197, U+2212;
}
@font-face {
  font-family: "Newsreader";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url(../fonts/newsreader-latin-ext.woff2) format("woff2");
  unicode-range: U+0104-0107, U+0118-0119, U+0141-0144, U+015A-015B, U+0179-017C;
}
@font-face {
  font-family: "Newsreader";
  font-style: italic;
  font-weight: 400;
  font-display: swap;
  src: url(../fonts/newsreader-italic-latin.woff2) format("woff2");
  unicode-range: U+0000-00FF, U+2000-206F, U+20AC, U+2122, U+2190-2193, U+2197, U+2212;
}
@font-face {
  font-family: "Newsreader";
  font-style: italic;
  font-weight: 400;
  font-display: swap;
  src: url(../fonts/newsreader-italic-latin-ext.woff2) format("woff2");
  unicode-range: U+0104-0107, U+0118-0119, U+0141-0144, U+015A-015B, U+0179-017C;
}
@font-face {
  font-family: "Inter";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url(../fonts/inter-latin.woff2) format("woff2");
  unicode-range: U+0000-00FF, U+2000-206F, U+20AC, U+2122, U+2190-2193, U+2197, U+2212;
}
@font-face {
  font-family: "Inter";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url(../fonts/inter-latin-ext.woff2) format("woff2");
  unicode-range: U+0104-0107, U+0118-0119, U+0141-0144, U+015A-015B, U+0179-017C;
}

/* ---------- Tokens ---------- */
:root {
  color-scheme: dark;
  --bg: #141211;
  --surface: #1c1a18;
  --surface-2: #242120;
  --text: #f2eee8;
  --text-soft: #d6d0c8;
  --muted: #9a928a;
  --line: rgba(242, 238, 232, 0.1);
  --line-strong: rgba(242, 238, 232, 0.2);
  --coral: #c8574b;
  --coral-hover: #d9776b;
  --coral-text: #d9776b; /* small coral text: passes AA on the dark background */
  --ink: #141211;
  --ink-soft: #5f5852;
  --on-coral: #0e0d0c;

  --serif: "Newsreader", "Palatino Linotype", Palatino, "Book Antiqua", Georgia, serif;
  --sans: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;

  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);

  --gutter: clamp(16px, 4vw, 64px);
  --gutter-r: var(--gutter);
  --maxw: 1320px;
  --header-h: 72px;
  --section-pad: clamp(96px, 13vw, 200px);
}
@media (min-width: 1024px) {
  /* room on the right for the side rail and its active label */
  :root { --gutter-r: max(var(--gutter), 204px); }
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html {
  background: var(--bg);
  color: var(--text);
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-padding-top: var(--header-h);
}
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }
.lenis.lenis-stopped { overflow: clip; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  overflow-x: clip;
}
h1, h2, h3, h4 { font-weight: 400; margin: 0; }
p { margin: 0; }
img, svg { display: block; max-width: 100%; }
a { color: inherit; }
button { font: inherit; color: inherit; }
::selection { background: var(--coral); color: var(--on-coral); }

:focus-visible {
  outline: 2px solid var(--coral-text);
  outline-offset: 4px;
}
main:focus, section:focus, .notify__done:focus { outline: none; }
.visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0);
  white-space: nowrap; border: 0;
}
.skip-link {
  position: fixed;
  left: var(--gutter);
  top: 12px;
  z-index: 300;
  padding: 12px 18px;
  background: var(--text);
  color: var(--ink);
  font: 600 14px/1 var(--sans);
  border-radius: 999px;
  text-decoration: none;
  transform: translateY(-160%);
  transition: transform 0.4s var(--ease);
}
.skip-link:focus-visible { transform: none; }

.container {
  width: 100%;
  max-width: calc(var(--maxw) + var(--gutter) + var(--gutter-r));
  margin-inline: auto;
  padding-left: var(--gutter);
  padding-right: var(--gutter-r);
}
.accent { color: var(--coral); font-style: inherit; }

/* Film grain */
.grain {
  position: fixed;
  inset: -50%;
  width: 200%;
  height: 200%;
  z-index: 150;
  pointer-events: none;
  background: url(../img/grain.png) repeat;
  background-size: 180px 180px;
  opacity: 0.06;
  animation: grain 1.4s steps(6) infinite;
}
@keyframes grain {
  0% { transform: translate(0, 0); }
  17% { transform: translate(-3%, 2%); }
  33% { transform: translate(2%, -4%); }
  50% { transform: translate(-4%, -2%); }
  67% { transform: translate(3%, 3%); }
  83% { transform: translate(-2%, 4%); }
  100% { transform: translate(0, 0); }
}

/* ---------- Type helpers ---------- */
.eyebrow {
  display: flex;
  align-items: center;
  gap: 0.75em;
  font: 500 12px/1.2 var(--sans);
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--muted);
}
.eyebrow__num { color: var(--text); font-variant-numeric: tabular-nums; }
.eyebrow__sep { color: var(--muted); opacity: 0.6; }

.section { position: relative; padding-block: var(--section-pad); }
.section-head {
  display: flex;
  align-items: center;
  gap: 24px;
}
.section-head__rule {
  flex: 1;
  height: 1px;
  background: var(--line);
  transform-origin: left center;
}
.section-title {
  font-family: var(--serif);
  font-size: clamp(2.6rem, 5.4vw, 5rem);
  line-height: 0.98;
  letter-spacing: -0.02em;
  margin-top: clamp(28px, 4vw, 48px);
}
.section-sub {
  margin-top: 18px;
  max-width: 34em;
  font-family: var(--serif);
  font-style: italic;
  font-size: clamp(1.15rem, 1.5vw, 1.35rem);
  line-height: 1.4;
  color: var(--muted);
}

/* ---------- Buttons ---------- */
.btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6em;
  min-height: 54px;
  padding: 0 28px;
  border-radius: 999px;
  border: 1px solid transparent;
  font: 500 15px/1 var(--sans);
  letter-spacing: 0.01em;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  background: none;
  transition: background-color 0.45s var(--ease), color 0.45s var(--ease), border-color 0.45s var(--ease);
}
.btn--primary { background: var(--coral); color: var(--on-coral); }
.btn--primary:hover { background: var(--coral-hover); }
.btn--outline { border-color: var(--line-strong); color: var(--text); }
.btn--outline:hover { border-color: var(--text); }
.btn--small { min-height: 40px; padding: 0 18px; font-size: 13px; }
.btn--ghost { border-color: var(--line-strong); color: var(--text); }
.btn--ghost:hover { border-color: var(--coral); background: var(--coral); color: var(--on-coral); }
.btn--dark { background: var(--ink); color: var(--text); }
.btn--dark:hover { background: #2a2624; }
.btn__arrow { transition: transform 0.5s var(--ease); }
.btn:hover .btn__arrow { transform: translateX(4px); }

.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5em;
  font: 500 15px/1.2 var(--sans);
  text-decoration: none;
  border-bottom: 1px solid currentColor;
  padding-bottom: 4px;
}

/* ---------- 00 Opening animation ---------- */
.intro { display: none; }
.intro-on .intro {
  display: block;
  position: fixed;
  inset: 0;
  z-index: 200;
  background: #0b0a09;
  --hole: 0px;
  -webkit-mask-image: radial-gradient(circle at 50% 50%, transparent var(--hole), #000 calc(var(--hole) + 1px));
  mask-image: radial-gradient(circle at 50% 50%, transparent var(--hole), #000 calc(var(--hole) + 1px));
}
.intro__stage {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
}
.intro__line {
  grid-area: 1 / 1;
  margin: 0;
  padding-inline: var(--gutter);
  text-align: center;
  font-family: var(--serif);
  font-size: clamp(2.1rem, 5.6vw, 5rem);
  line-height: 1.05;
  letter-spacing: -0.015em;
  color: var(--text);
}
.intro__line .w { display: inline-block; opacity: 0; will-change: transform, opacity; }
.intro__clock {
  grid-area: 1 / 1;
  width: min(36vmin, 320px);
  aspect-ratio: 1;
  color: var(--text);
  opacity: 0;
  will-change: transform, opacity;
}
.intro__clock svg { width: 100%; height: 100%; overflow: visible; }
.intro__skip {
  position: absolute;
  right: var(--gutter);
  bottom: max(20px, env(safe-area-inset-bottom));
  min-height: 44px;
  padding: 0 18px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  background: transparent;
  color: var(--muted);
  font: 500 12px/1 var(--sans);
  letter-spacing: 0.2em;
  text-transform: uppercase;
  cursor: pointer;
  transition: color 0.4s var(--ease), border-color 0.4s var(--ease);
}
.intro__skip:hover { color: var(--text); border-color: var(--text); }
.intro-on body { overflow: hidden; }

/* ---------- Header ---------- */
.site-header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 60;
  height: var(--header-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding-inline: var(--gutter);
  transition: transform 0.7s var(--ease), background-color 0.5s var(--ease), border-color 0.5s var(--ease);
  border-bottom: 1px solid transparent;
}
.site-header.is-scrolled {
  background: rgba(20, 18, 17, 0.78);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  border-bottom-color: var(--line);
}
.site-header.is-hidden { transform: translateY(-100%); }
.wordmark {
  font: 600 13px/1 var(--sans);
  letter-spacing: 0.34em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--text);
  padding: 14px 0;
}
.site-header__actions { display: flex; align-items: center; gap: 10px; }
.menu-toggle {
  display: none;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  min-width: 44px;
  padding: 0 4px 0 12px;
  border: 0;
  background: none;
  cursor: pointer;
  font: 500 12px/1 var(--sans);
  letter-spacing: 0.2em;
  text-transform: uppercase;
}
.menu-toggle__icon { position: relative; width: 22px; height: 10px; }
.menu-toggle__icon i {
  position: absolute; left: 0; right: 0; height: 1.5px; background: currentColor;
  transition: transform 0.5s var(--ease), top 0.5s var(--ease);
}
.menu-toggle__icon i:first-child { top: 0; }
.menu-toggle__icon i:last-child { top: 8.5px; }
.menu-open .menu-toggle__icon i:first-child { top: 4.25px; transform: rotate(45deg); }
.menu-open .menu-toggle__icon i:last-child { top: 4.25px; transform: rotate(-45deg); }

/* Mobile progress bar (the rail on small screens) */
.progress {
  position: fixed;
  left: 0; right: 0;
  top: var(--header-h);
  z-index: 61;
  height: 2px;
  background: var(--line);
  display: none;
  transition: transform 0.7s var(--ease);
}
.progress span {
  position: absolute; inset: 0;
  background: var(--coral);
  transform-origin: left center;
  transform: scaleX(0);
}
.header-hidden .progress { transform: translateY(calc(-1 * var(--header-h))); }

/* Full-screen menu */
.menu {
  position: fixed;
  inset: 0;
  z-index: 55;
  background: var(--bg);
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: calc(var(--header-h) + 24px) var(--gutter) 40px;
  clip-path: circle(0 at calc(100% - 40px) 36px);
  visibility: hidden;
  transition: clip-path 0.9s var(--ease), visibility 0s linear 0.9s;
}
.menu-open .menu {
  clip-path: circle(150% at calc(100% - 40px) 36px);
  visibility: visible;
  transition: clip-path 0.9s var(--ease), visibility 0s;
}
.menu ol { list-style: none; margin: 0; padding: 0; }
.menu a {
  display: flex;
  align-items: baseline;
  gap: 18px;
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
  font-family: var(--serif);
  font-size: clamp(1.9rem, 8vw, 3rem);
  line-height: 1.1;
  text-decoration: none;
}
.menu a span {
  font: 500 12px/1 var(--sans);
  letter-spacing: 0.18em;
  color: var(--muted);
  min-width: 2em;
}
.menu a[aria-current] { color: var(--coral); }
.menu a[aria-current] span { color: var(--coral-text); }
.menu__cta { margin-top: 32px; align-self: flex-start; }

/* ---------- Side rail ---------- */
.rail {
  position: fixed;
  right: clamp(20px, 2.4vw, 40px);
  top: 50%;
  z-index: 50;
  transform: translateY(-50%);
}
.rail ol { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; align-items: flex-end; }
.rail li { display: flex; flex-direction: column; align-items: flex-end; }
.rail__item {
  display: flex;
  align-items: center;
  gap: 14px;
  min-height: 30px;
  text-decoration: none;
  color: var(--muted);
  font: 500 12px/1 var(--sans);
  letter-spacing: 0.12em;
  transition: color 0.5s var(--ease);
}
.rail__num { width: 22px; text-align: right; font-variant-numeric: tabular-nums; }
.rail__label {
  font-size: 10.5px;
  letter-spacing: 0.17em;
  text-transform: uppercase;
  white-space: nowrap;
  padding: 5px 9px;
  margin-right: -9px;
  border-radius: 999px;
  background: rgba(20, 18, 17, 0.86);
  opacity: 0;
  transform: translateX(10px);
  transition: opacity 0.5s var(--ease), transform 0.6s var(--ease);
  pointer-events: none;
}
.rail__item:hover, .rail__item:focus-visible { color: var(--text); }
.rail__item:hover .rail__label,
.rail__item:focus-visible .rail__label,
.rail__item.is-active .rail__label { opacity: 1; transform: none; }
.rail__item.is-active { color: var(--coral-text); }
.rail__track {
  position: relative;
  width: 1px;
  height: 26px;
  margin: 2px 10.5px 2px 0;
  background: var(--line-strong);
  overflow: hidden;
}
.rail__fill {
  position: absolute; inset: 0;
  background: var(--coral);
  transform-origin: center top;
  transform: scaleY(0);
}

/* ---------- 01 Hero ---------- */
.hero {
  position: relative;
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  padding-top: calc(var(--header-h) + clamp(16px, 5vh, 64px));
  overflow: hidden;
}
.hero__glow {
  position: absolute;
  right: -12vw;
  top: 4%;
  width: min(70vw, 980px);
  aspect-ratio: 1;
  border-radius: 50%;
  background: radial-gradient(circle at 50% 50%, rgba(200, 87, 75, 0.26), rgba(200, 87, 75, 0.08) 38%, rgba(200, 87, 75, 0) 66%);
  pointer-events: none;
}
.hero__grid {
  position: relative;
  flex: 1;
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(0, 0.7fr);
  align-items: center;
  gap: clamp(32px, 5vw, 96px);
  padding-bottom: clamp(40px, 6vh, 80px);
}
.hero__title {
  margin: clamp(24px, 3.4vh, 40px) 0 clamp(20px, 3vh, 32px);
  font-family: var(--serif);
  font-size: clamp(3.4rem, 7.7vw, 8.4rem);
  line-height: 0.9;
  letter-spacing: -0.028em;
}
.hero__title .word { display: inline-block; will-change: transform, opacity; }
.hero__title .word--stay { color: var(--coral); }
.hero__subtitle {
  max-width: 26em;
  font-family: var(--serif);
  font-style: italic;
  font-size: clamp(1.25rem, 1.75vw, 1.6rem);
  line-height: 1.3;
  color: var(--text-soft);
}
.hero__author {
  margin-top: 20px;
  font: 500 12px/1.4 var(--sans);
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--muted);
}
.hero__author strong { font-weight: 500; color: var(--text); }
.hero__actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: clamp(28px, 4vh, 44px); }
.hero__note { margin-top: 18px; font-size: 13px; color: var(--muted); letter-spacing: 0.01em; }

/* 3D book */
.hero__book {
  display: flex;
  justify-content: center;
  align-items: center;
  perspective: 1800px;
  perspective-origin: 50% 40%;
}
.book {
  --w: clamp(220px, 27vw, 400px);
  --h: calc(var(--w) * 1.419);
  --t: calc(var(--w) * 0.1);
  position: relative;
  width: var(--w);
  height: var(--h);
  transform-style: preserve-3d;
  animation: book-float 7s ease-in-out infinite;
}
.book__parallax { position: relative; width: 100%; height: 100%; transform-style: preserve-3d; }
.book__inner {
  position: absolute;
  inset: 0;
  transform-style: preserve-3d;
  transform: rotateY(var(--ry, 26deg)) rotateX(var(--rx, 4deg));
}
.book__face { position: absolute; backface-visibility: hidden; -webkit-backface-visibility: hidden; }
.book__front {
  inset: 0;
  transform: translateZ(calc(var(--t) / 2));
  border-radius: 2px 4px 4px 2px;
  overflow: hidden;
  background: #1a1817;
  box-shadow: inset 0 0 0 1px rgba(242, 238, 232, 0.06);
}
.book__front img { width: 100%; height: 100%; object-fit: cover; }
.book__front::after {
  /* hinge crease and soft light */
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(0, 0, 0, 0.45) 0%, rgba(255, 255, 255, 0.07) 1.6%, rgba(0, 0, 0, 0.18) 3.4%, rgba(0, 0, 0, 0) 6%),
    linear-gradient(115deg, rgba(255, 255, 255, 0.07) 0%, rgba(255, 255, 255, 0) 38%);
  pointer-events: none;
}
.book__back {
  inset: 0;
  transform: rotateY(180deg) translateZ(calc(var(--t) / 2));
  background: #161413;
}
.book__spine {
  top: 0;
  left: 50%;
  width: var(--t);
  height: 100%;
  margin-left: calc(var(--t) / -2);
  transform: rotateY(-90deg) translateZ(calc(var(--w) / 2));
  background: linear-gradient(90deg, #0f0e0d, #1d1b19 45%, #141211);
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-direction: column;
  padding: 12% 0 9%;
  overflow: hidden;
}
.book__spine span {
  writing-mode: vertical-rl;
  font-family: var(--serif);
  font-size: calc(var(--t) * 0.36);
  line-height: 1;
  color: var(--text);
  white-space: nowrap;
}
.book__spine span:last-child {
  font: 500 calc(var(--t) * 0.22) / 1 var(--sans);
  letter-spacing: 0.28em;
  color: var(--muted);
}
.book__spine i {
  display: block;
  width: 36%;
  height: 1px;
  background: var(--coral);
}
.book__pages {
  top: 0;
  left: 50%;
  width: var(--t);
  height: calc(100% - 6px);
  margin-top: 3px;
  margin-left: calc(var(--t) / -2);
  transform: rotateY(90deg) translateZ(calc(var(--w) / 2 - 3px));
  background:
    repeating-linear-gradient(90deg, #e9e3da 0 1px, #d8d1c6 1px 2px, #efe9e1 2px 3px),
    #e9e3da;
  box-shadow: inset 6px 0 10px rgba(0, 0, 0, 0.25);
}
.book__top, .book__bottom {
  left: 3px;
  width: calc(100% - 6px);
  height: var(--t);
  top: 50%;
  margin-top: calc(var(--t) / -2);
  background: repeating-linear-gradient(0deg, #e9e3da 0 1px, #d6cfc4 1px 2px);
}
.book__top { transform: rotateX(90deg) translateZ(calc(var(--h) / 2 - 2px)); }
.book__bottom { transform: rotateX(-90deg) translateZ(calc(var(--h) / 2 - 2px)); }
.book__shadow {
  position: absolute;
  left: 8%;
  right: -4%;
  bottom: -9%;
  height: 9%;
  border-radius: 50%;
  background: radial-gradient(closest-side, rgba(0, 0, 0, 0.75), rgba(0, 0, 0, 0));
  transform: translateZ(-80px);
  animation: book-shadow 7s ease-in-out infinite;
}
@keyframes book-float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-14px); }
}
@keyframes book-shadow {
  0%, 100% { opacity: 0.9; transform: translateZ(-80px) scale(1); }
  50% { opacity: 0.6; transform: translateZ(-80px) translateY(14px) scale(0.92); }
}

/* Marquees */
.marquees {
  position: relative;
  border-top: 1px solid var(--line);
  padding-block: clamp(20px, 3vh, 32px) clamp(24px, 3.4vh, 36px);
  display: grid;
  gap: clamp(10px, 1.6vh, 16px);
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 7%, #000 93%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 7%, #000 93%, transparent);
}
.marquee { display: flex; overflow: hidden; }
.marquee__track {
  display: flex;
  flex-shrink: 0;
  width: max-content;
  animation: marquee var(--marquee-dur, 70s) linear infinite;
  will-change: transform;
}
.marquee--rev .marquee__track { animation-direction: reverse; }
.marquee:hover .marquee__track,
.marquee.is-paused .marquee__track { animation-play-state: paused; }
.marquee__list { display: flex; flex-shrink: 0; list-style: none; margin: 0; padding: 0; }
.marquee__list li {
  display: flex;
  align-items: center;
  white-space: nowrap;
  font-family: var(--serif);
  font-size: clamp(1.6rem, 2.7vw, 2.6rem);
  line-height: 1.2;
  color: var(--text);
}
.marquee__list li::after {
  content: "";
  flex-shrink: 0;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--coral);
  margin-inline: clamp(22px, 2.6vw, 44px);
}
.marquee--small .marquee__list li {
  font: 500 12px/1.4 var(--sans);
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--muted);
}
.marquee--small .marquee__list li::after { width: 4px; height: 4px; margin-inline: 22px; }
@keyframes marquee { to { transform: translateX(var(--marquee-shift, -50%)); } }

/* ---------- 02 Story ---------- */
.statement {
  margin-top: clamp(40px, 6vw, 88px);
  font-family: var(--serif);
  font-size: clamp(2.6rem, 6.4vw, 6.4rem);
  line-height: 1;
  letter-spacing: -0.022em;
}
.statement__line { display: block; }
.story__body {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: clamp(32px, 6vw, 96px);
  margin-top: clamp(64px, 9vw, 140px);
  align-items: start;
}
.story__clock {
  width: clamp(140px, 16vw, 220px);
  color: var(--text);
  opacity: 0.5;
}
.story__clock svg { width: 100%; height: auto; overflow: visible; }
.story__text { display: grid; gap: 1.2em; max-width: 36em; }
.story__text p {
  font-family: var(--serif);
  font-size: clamp(1.2rem, 1.55vw, 1.42rem);
  line-height: 1.55;
  color: var(--text-soft);
}
.story__text p:first-child { color: var(--text); }
.story__text em { font-style: italic; color: var(--text); }

/* ---------- 03 How it looked ---------- */
.looked { padding-block: 0; }
.looked__pin {
  position: relative;
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding-block: calc(var(--header-h) + clamp(16px, 3vh, 40px)) clamp(32px, 6vh, 72px);
  overflow: hidden;
}
.looked__head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px 48px;
  margin-bottom: clamp(24px, 4.5vh, 56px);
}
.looked__head .section-head { width: 100%; }
.looked__title { margin-top: clamp(20px, 3vh, 36px); font-size: clamp(2.4rem, 4.6vw, 4.4rem); }
.looked__meta {
  display: flex;
  align-items: center;
  gap: 18px;
  font: 500 13px/1 var(--sans);
  letter-spacing: 0.16em;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}
.looked__counter b { font-weight: 500; color: var(--text); }
.looked__progress { position: relative; width: clamp(96px, 12vw, 180px); height: 1px; background: var(--line-strong); }
.looked__progress span {
  position: absolute; inset: 0;
  background: var(--coral);
  transform-origin: left center;
  transform: scaleX(0.1667);
}
.looked__nav { display: flex; gap: 8px; }
.looked__nav button {
  width: 44px; height: 44px;
  display: grid; place-items: center;
  border: 1px solid var(--line-strong);
  border-radius: 50%;
  background: none;
  cursor: pointer;
  transition: border-color 0.4s var(--ease), opacity 0.4s;
}
.looked__nav button:hover { border-color: var(--text); }
.looked__nav button:disabled { opacity: 0.35; cursor: default; }
.looked__nav svg { width: 16px; height: 16px; }

.looked__viewport {
  position: relative;
  overflow-x: auto;
  overflow-y: hidden;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
  outline-offset: -2px;
}
.looked__viewport::-webkit-scrollbar { display: none; }
.looked__track {
  display: flex;
  gap: clamp(14px, 2vw, 32px);
  width: max-content;
  list-style: none;
  margin: 0;
  padding: 0 var(--gutter-r) 0 var(--track-start, var(--gutter));
}
.scene {
  position: relative;
  flex-shrink: 0;
  width: min(1060px, 74vw);
  height: clamp(380px, 56vh, 560px);
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  scroll-snap-align: start;
  scroll-margin-left: var(--track-start, var(--gutter));
  border-radius: 3px;
  overflow: hidden;
}
.scene__then, .scene__now {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 24px;
  padding: clamp(24px, 3.2vw, 52px);
}
.scene__then { background: var(--surface); border: 1px solid var(--line); border-right: 0; }
.scene__now { background: var(--text); color: var(--ink); }
.scene__label {
  position: relative;
  z-index: 1;
  font: 500 11px/1.3 var(--sans);
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--muted);
}
.scene__now .scene__label { color: var(--ink-soft); }
.scene__quote {
  position: relative;
  z-index: 1;
  margin: 0;
  font-family: var(--serif);
  font-style: italic;
  font-size: clamp(1.3rem, 2vw, 1.95rem);
  line-height: 1.28;
  color: var(--text);
}
.scene__quote::before {
  content: "\201C";
  display: block;
  height: 0.55em;
  font-size: 2.6em;
  line-height: 1;
  color: var(--muted);
  opacity: 0.5;
}
.scene__num {
  position: relative;
  z-index: 1;
  font: 200 clamp(2.6rem, 4vw, 4rem)/0.9 var(--sans);
  letter-spacing: -0.04em;
  color: var(--muted);
  opacity: 0.75;
  font-variant-numeric: tabular-nums;
}
.scene__principle {
  position: relative;
  z-index: 1;
  font-family: var(--serif);
  font-size: clamp(1.5rem, 2.5vw, 2.45rem);
  line-height: 1.12;
  letter-spacing: -0.01em;
  color: var(--ink-soft);
}
.scene__principle strong { font-weight: 400; color: var(--ink); }
.scene__mark {
  position: relative;
  z-index: 1;
  width: 40px;
  height: 2px;
  background: var(--coral);
}
.scene__veil {
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  background: var(--bg);
  opacity: 0;
}
/* carousel mode: the scene in view lights up, the old way dims */
.carousel-dim .scene__veil { transition: opacity 0.9s var(--ease); }
.carousel-dim .scene:not(.is-lit) .scene__now .scene__veil { opacity: 0.7; }
.carousel-dim .scene.is-lit .scene__then .scene__veil { opacity: 0.4; }

/* ---------- 04 Numbers ---------- */
.numbers__grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 1px minmax(0, 1fr);
  gap: clamp(32px, 6vw, 112px);
  margin-top: clamp(48px, 7vw, 104px);
}
.numbers__divider { background: var(--line-strong); transform-origin: center top; }
.stat { margin: 0; display: flex; flex-direction: column; gap: clamp(20px, 3vw, 36px); }
.stat__value {
  display: flex;
  align-items: flex-start;
  font-family: var(--sans);
  font-weight: 200;
  font-size: clamp(7rem, 17vw, 15.5rem);
  line-height: 0.84;
  letter-spacing: -0.065em;
  font-variant-numeric: tabular-nums;
  color: var(--text);
}
.stat__num { display: inline-block; min-width: 1.15em; }
.stat__unit {
  font-size: 0.36em;
  font-weight: 300;
  letter-spacing: -0.02em;
  margin: 0.12em 0 0 0.12em;
  color: var(--muted);
}
.stat__text {
  max-width: 24em;
  font-family: var(--serif);
  font-size: clamp(1.25rem, 1.8vw, 1.6rem);
  line-height: 1.32;
}
.stat__source {
  margin-top: 14px;
  font: 500 11px/1.5 var(--sans);
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--muted);
}

/* ---------- 05 Inside the book ---------- */
.parts {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(14px, 1.8vw, 28px);
  margin-top: clamp(48px, 6vw, 88px);
  align-items: start;
}
.part {
  position: relative;
  display: flex;
  flex-direction: column;
  min-height: clamp(440px, 38vw, 560px);
  padding: clamp(24px, 2.6vw, 40px);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 3px;
  transition: border-color 0.6s var(--ease), background-color 0.6s var(--ease);
}
.part:hover { border-color: var(--line-strong); background: #201d1b; }
.part__top { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; }
.part__num {
  font: 200 clamp(4.2rem, 6.4vw, 6.6rem)/0.82 var(--sans);
  letter-spacing: -0.06em;
  font-variant-numeric: tabular-nums;
}
.part__sketch { width: clamp(96px, 9vw, 136px); color: var(--text); opacity: 0.9; }
.part__sketch svg { width: 100%; height: auto; overflow: visible; }
.part__body { margin-top: auto; padding-top: 40px; }
.part__label {
  font: 500 11px/1.3 var(--sans);
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--muted);
}
.part__title {
  margin-top: 12px;
  font-family: var(--serif);
  font-size: clamp(1.75rem, 2.4vw, 2.3rem);
  line-height: 1.04;
  letter-spacing: -0.012em;
}
.part__chapters { margin-top: 28px; border-top: 1px solid var(--line); }
.part__chapters summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 52px;
  list-style: none;
  cursor: pointer;
  font: 500 12px/1 var(--sans);
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--text);
}
.part__chapters summary::-webkit-details-marker { display: none; }
.part__count { color: var(--muted); margin-left: 6px; }
.plus { position: relative; width: 14px; height: 14px; flex-shrink: 0; }
.plus::before, .plus::after {
  content: "";
  position: absolute;
  left: 0; right: 0; top: 50%;
  height: 1px;
  background: currentColor;
  transition: transform 0.5s var(--ease);
}
.plus::after { transform: rotate(90deg); }
.part__chapters[open] .plus::after { transform: rotate(0deg); }
.part__chapters::details-content {
  block-size: 0;
  overflow: hidden;
  transition: block-size 0.7s var(--ease), content-visibility 0.7s allow-discrete;
}
.part__chapters[open]::details-content { block-size: auto; }
.part__chapters { interpolate-size: allow-keywords; }
.chapter-list { list-style: none; margin: 0; padding: 0 0 6px; }
.chapter-list li {
  padding: 11px 0;
  border-top: 1px solid var(--line);
  font-family: var(--serif);
  font-size: 1.12rem;
  line-height: 1.3;
  color: var(--text-soft);
}

.toolkit {
  display: grid;
  grid-template-columns: minmax(0, 4fr) minmax(0, 8fr);
  gap: 28px clamp(32px, 5vw, 80px);
  margin-top: clamp(56px, 7vw, 104px);
  padding-top: clamp(28px, 3vw, 40px);
  border-top: 1px solid var(--line);
}
.toolkit__lead {
  font-family: var(--serif);
  font-size: clamp(1.6rem, 2.4vw, 2.2rem);
  line-height: 1.12;
  letter-spacing: -0.01em;
}
.toolkit__lead span { display: block; font: 500 11px/1.3 var(--sans); letter-spacing: 0.22em; text-transform: uppercase; color: var(--muted); margin-bottom: 14px; }
.tags { display: flex; flex-wrap: wrap; gap: 10px; list-style: none; margin: 0; padding: 0; align-content: flex-start; }
.tags li {
  padding: 10px 16px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  font: 500 13px/1.25 var(--sans);
  color: var(--text-soft);
  transition: border-color 0.4s var(--ease), color 0.4s var(--ease);
}
.tags li:hover { border-color: var(--text); color: var(--text); }

/* ---------- 06 Coaching questions ---------- */
.coach__intro {
  margin: clamp(40px, 5vw, 64px) auto 0;
  max-width: 34em;
  text-align: center;
  font-family: var(--serif);
  font-style: italic;
  font-size: clamp(1.15rem, 1.5vw, 1.35rem);
  line-height: 1.45;
  color: var(--muted);
}
.coach__card {
  position: relative;
  max-width: 860px;
  margin: 28px auto 0;
  padding: clamp(32px, 5vw, 72px) clamp(24px, 5vw, 80px) clamp(28px, 4vw, 52px);
  background: var(--text);
  color: var(--ink);
  border-left: 3px solid var(--coral);
  border-radius: 0 3px 3px 0;
  text-align: center;
}
.coach__sketch { width: 56px; margin: 0 auto 18px; color: var(--ink); opacity: 0.85; }
.coach__sketch svg { width: 100%; height: auto; }
.coach__label {
  font: 600 11px/1.3 var(--sans);
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--ink-soft);
}
.coach__stage {
  display: grid;
  place-items: center;
  min-height: clamp(200px, 22vw, 240px);
  margin-top: 20px;
}
.coach__q, .coach__end {
  grid-area: 1 / 1;
  max-width: 21em;
  margin: 0 auto;
}
.coach__q {
  font-family: var(--serif);
  font-style: italic;
  font-size: clamp(1.55rem, 3vw, 2.45rem);
  line-height: 1.2;
  letter-spacing: -0.005em;
}
.coach__end-text {
  font-family: var(--serif);
  font-size: clamp(2rem, 4vw, 3.2rem);
  line-height: 1.05;
  letter-spacing: -0.015em;
}
.coach__end .link-arrow { margin-top: 22px; color: var(--ink); }
.js .coach__q, .js .coach__end {
  opacity: 0;
  visibility: hidden;
  transform: translateY(14px);
  transition: opacity 0.7s var(--ease), transform 0.9s var(--ease-out), visibility 0s linear 0.7s;
}
.js .coach__q.is-active, .js .coach__end.is-active {
  opacity: 1;
  visibility: visible;
  transform: none;
  transition: opacity 0.7s var(--ease) 0.15s, transform 0.9s var(--ease-out) 0.15s, visibility 0s;
}
.no-js .coach__stage { gap: 24px; }
.no-js .coach__q, .no-js .coach__end { grid-area: auto; }
.coach__controls {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-top: 28px;
  padding-top: 20px;
  border-top: 1px solid rgba(20, 18, 17, 0.12);
}
.no-js .coach__controls { display: none; }
.coach__dots { display: flex; gap: 0; }
.coach__dots button {
  width: 44px; height: 44px;
  display: grid; place-items: center;
  border: 0; background: none; cursor: pointer;
}
.coach__dots span {
  display: block;
  width: 8px; height: 8px;
  border-radius: 4px;
  background: rgba(20, 18, 17, 0.25);
  transition: width 0.6s var(--ease), background-color 0.6s var(--ease);
}
.coach__dots button[aria-current] span { width: 26px; background: var(--coral); }
.coach__card :focus-visible { outline-color: #a8473c; }

/* ---------- 07 About the author ---------- */
.author__grid {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: clamp(40px, 7vw, 120px);
  align-items: center;
}
.author__photo { position: relative; overflow: hidden; border-radius: 3px; aspect-ratio: 4 / 5; background: var(--surface-2); }
.author__photo-inner {
  position: absolute;
  inset: -8% 0;
  display: grid;
  place-items: center;
  background:
    radial-gradient(120% 80% at 30% 20%, rgba(242, 238, 232, 0.1), rgba(242, 238, 232, 0) 60%),
    linear-gradient(160deg, #2b2826, #1a1817 70%);
  filter: grayscale(1);
}
.author__photo-inner picture { position: absolute; inset: 0; display: block; }
.author__photo-inner img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 30%; filter: grayscale(1) contrast(1.04) brightness(0.86); }
.author__photo::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  background: radial-gradient(120% 90% at 50% 35%, rgba(20, 18, 17, 0) 55%, rgba(20, 18, 17, 0.55) 100%);
  pointer-events: none;
}
.author__photo::after {
  content: "";
  position: absolute;
  inset: 0;
  background: url(../img/grain.png);
  background-size: 140px;
  opacity: 0.12;
  pointer-events: none;
}
.author__placeholder {
  display: grid;
  justify-items: center;
  gap: 10px;
  font: 500 11px/1.4 var(--sans);
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--muted);
  text-align: center;
}
.author__placeholder i {
  display: block;
  width: 64px; height: 64px;
  border: 1px solid var(--line-strong);
  border-radius: 50%;
}
.author__name {
  margin-top: clamp(24px, 3vw, 40px);
  font-family: var(--serif);
  font-size: clamp(2.8rem, 5.6vw, 5.4rem);
  line-height: 0.95;
  letter-spacing: -0.025em;
}
.author__bio {
  margin-top: clamp(20px, 2.6vw, 32px);
  max-width: 30em;
  font-family: var(--serif);
  font-size: clamp(1.2rem, 1.6vw, 1.45rem);
  line-height: 1.5;
  color: var(--text-soft);
}
.chips__label {
  margin-top: clamp(32px, 4vw, 48px);
  font: 500 11px/1.3 var(--sans);
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--muted);
}
.chips { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; margin: 14px 0 0; padding: 0; }
.chips li {
  padding: 10px 16px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  font: 500 14px/1.2 var(--sans);
}
.social { display: flex; gap: 24px; list-style: none; margin: clamp(28px, 3vw, 40px) 0 0; padding: 0; }
.social a {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 44px;
  font: 500 14px/1 var(--sans);
  letter-spacing: 0.04em;
  text-decoration: none;
  border-bottom: 1px solid var(--line-strong);
  transition: border-color 0.4s var(--ease), color 0.4s var(--ease);
}
.social a:hover { border-color: var(--coral); color: var(--coral-text); }

/* ---------- 08 Get notified ---------- */
.notify { overflow: hidden; }
.notify__clock {
  position: absolute;
  top: 50%;
  right: -14vw;
  width: min(92vw, 940px);
  aspect-ratio: 1;
  transform: translateY(-50%);
  color: var(--text);
  opacity: 0.07;
  pointer-events: none;
}
.notify__clock svg { width: 100%; height: 100%; overflow: visible; }
.notify__clock .clock-hand { transform-box: view-box; transform-origin: 100px 100px; }
.notify__clock .clock-hand--min { animation: spin 90s linear infinite; }
.notify__clock .clock-hand--hour { animation: spin 1080s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.notify__inner { position: relative; }
.notify__title {
  margin-top: clamp(40px, 6vw, 88px);
  max-width: 13.5em;
  font-family: var(--serif);
  font-size: clamp(2.7rem, 6.9vw, 7rem);
  line-height: 0.98;
  letter-spacing: -0.024em;
}
.notify__lead {
  margin-top: clamp(24px, 3vw, 40px);
  max-width: 30em;
  font-family: var(--serif);
  font-style: italic;
  font-size: clamp(1.25rem, 1.8vw, 1.6rem);
  line-height: 1.35;
  color: var(--text-soft);
}
.notify__form { margin-top: clamp(40px, 5vw, 64px); max-width: 760px; }
.field__label {
  display: block;
  font: 500 11px/1.3 var(--sans);
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--muted);
}
.field__row { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 16px 20px; margin-top: 8px; }
.field__row input {
  flex: 1 1 300px;
  min-width: 0;
  min-height: 56px;
  padding: 0 2px;
  border: 0;
  border-bottom: 1px solid var(--line-strong);
  border-radius: 0;
  background: transparent;
  color: var(--text);
  font: 400 1.2rem/1.2 var(--sans);
  transition: border-color 0.4s var(--ease), box-shadow 0.4s var(--ease);
}
.field__row input::placeholder { color: #6f6862; }
.field__row input:focus-visible {
  outline: none;
  border-bottom-color: var(--coral-text);
  box-shadow: 0 1px 0 0 var(--coral-text);
}
.field__row input[aria-invalid="true"] { border-bottom-color: var(--coral-text); }
.consent {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  margin-top: 26px;
  font-size: 14px;
  line-height: 1.5;
  color: var(--text-soft);
}
.consent input {
  appearance: none;
  -webkit-appearance: none;
  flex-shrink: 0;
  width: 22px; height: 22px;
  margin: 0;
  border: 1px solid var(--line-strong);
  border-radius: 3px;
  background: transparent;
  display: grid;
  place-items: center;
  cursor: pointer;
  transition: background-color 0.3s var(--ease), border-color 0.3s var(--ease);
}
.consent input::after {
  content: "";
  width: 10px; height: 6px;
  border-left: 2px solid var(--on-coral);
  border-bottom: 2px solid var(--on-coral);
  transform: translateY(-1px) rotate(-45deg) scale(0);
  transition: transform 0.3s var(--ease);
}
.consent input:checked { background: var(--coral); border-color: var(--coral); }
.consent input:checked::after { transform: translateY(-1px) rotate(-45deg) scale(1); }
.consent input[aria-invalid="true"] { border-color: var(--coral-text); }
.consent label { cursor: pointer; }
.form-msg { min-height: 1.5em; margin-top: 14px; font-size: 14px; color: var(--coral-text); }
.privacy-note { margin-top: 6px; max-width: 46em; font-size: 13px; line-height: 1.55; color: var(--muted); }
.privacy-note a { color: var(--text-soft); text-underline-offset: 3px; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.notify__done { margin-top: clamp(40px, 5vw, 64px); display: flex; align-items: center; gap: 28px; max-width: 760px; }
.notify__done[hidden] { display: none; }
.notify__done-sketch { width: 120px; flex-shrink: 0; color: var(--text); }
.notify__done-sketch svg { width: 100%; height: auto; }
.notify__done p { font-family: var(--serif); font-size: clamp(1.4rem, 2.2vw, 2rem); line-height: 1.25; }

/* ---------- Footer ---------- */
.site-footer { position: relative; padding-top: clamp(64px, 8vw, 112px); border-top: 1px solid var(--line); font-size: 13px; line-height: 1.6; color: var(--muted); }
.footer__grid {
  display: flex;
  flex-wrap: wrap;
  gap: 40px clamp(24px, 4vw, 64px);
}
.footer__grid > * { flex: 1 1 200px; min-width: 0; }
.footer__grid > .footer__brand { flex: 1.6 1 260px; }
.footer__brand img { width: 64px; height: auto; margin-bottom: 20px; opacity: 0.92; }
.footer__h {
  margin-bottom: 12px;
  font: 500 11px/1.3 var(--sans);
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--text);
}
.footer__grid p + p { margin-top: 6px; }
.footer__grid ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 2px; }
.footer__grid ul a, .footer__grid p a {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  text-decoration: none;
  color: var(--text-soft);
  transition: color 0.4s var(--ease);
}
.footer__grid ul a:hover { color: var(--coral-text); }
.footer__pl { font-family: var(--serif); font-style: italic; font-size: 1.05rem; color: var(--text-soft); }
.footer__base {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  margin-top: clamp(64px, 9vw, 128px);
  padding-bottom: clamp(24px, 3vw, 40px);
}
.footer__wordmark {
  font-family: var(--serif);
  font-size: clamp(2.6rem, 8.6vw, 9rem);
  line-height: 0.9;
  letter-spacing: -0.035em;
  color: var(--text);
}
.back-top {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 44px;
  font: 500 12px/1 var(--sans);
  letter-spacing: 0.2em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--muted);
  transition: color 0.4s var(--ease);
}
.back-top:hover { color: var(--text); }
.has-to-top .back-top { display: none; }

/* ---------- Back-to-top button ---------- */
/* Eases in after the first screen and stays to the very bottom */
.to-top {
  position: fixed;
  right: clamp(20px, 2.4vw, 40px);
  bottom: calc(clamp(20px, 2.4vw, 36px) + env(safe-area-inset-bottom));
  z-index: 52;
  width: 54px; height: 54px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: var(--text);
  background: rgba(20, 18, 17, 0.72);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  box-shadow: 0 14px 34px rgba(0, 0, 0, 0.45), inset 0 0 0 1px var(--line);
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  transform: translateY(18px) scale(0.8);
  transition: opacity 0.5s var(--ease) 0.05s, transform 0.5s var(--ease) 0.05s, visibility 0s linear 0.55s, box-shadow 0.4s var(--ease);
}
.to-top.is-visible {
  opacity: 1;
  visibility: visible;
  transform: none;
  transition: opacity 0.45s var(--ease), transform 0.7s cubic-bezier(0.34, 1.56, 0.5, 1), visibility 0s, box-shadow 0.4s var(--ease);
}
.to-top__ring { position: absolute; inset: 0; width: 100%; height: 100%; transform: rotate(-90deg); pointer-events: none; }
.to-top__ring circle { fill: none; stroke-width: 1.5; }
.to-top__track { stroke: var(--line-strong); }
.to-top__bar { stroke: var(--coral); stroke-linecap: round; stroke-dasharray: 144.51; stroke-dashoffset: 144.51; }
.to-top__arrow { position: relative; width: 20px; height: 20px; transition: transform 0.5s var(--ease-out); }
.to-top:hover { box-shadow: 0 18px 44px rgba(200, 87, 75, 0.22), inset 0 0 0 1px rgba(200, 87, 75, 0.45); }
.to-top:hover .to-top__arrow { transform: translateY(-3px); }
.to-top:focus-visible { outline: 2px solid var(--coral-text); outline-offset: 3px; }
.to-top.is-launching .to-top__arrow { animation: to-top-launch 0.7s var(--ease-out); }
@keyframes to-top-launch {
  0% { transform: none; }
  45% { transform: translateY(-26px); opacity: 0; }
  46% { transform: translateY(22px); opacity: 0; }
  100% { transform: none; opacity: 1; }
}
.intro-on .to-top { display: none; }
@media (max-width: 1023px) {
  .to-top { right: 16px; bottom: calc(16px + env(safe-area-inset-bottom)); width: 50px; height: 50px; }
  /* keep the footer wordmark clear of the button at the very bottom */
  .has-to-top .footer__base { padding-bottom: 48px; }
}

/* ---------- Sketch drawing ---------- */
.part:hover .sk-draw path[data-len],
.part:focus-within .sk-draw path[data-len],
.part.is-drawing .sk-draw path[data-len],
.notify__done .sk-draw path[data-len] {
  stroke-dasharray: var(--len);
  animation: sk-draw 1.3s var(--ease) both;
  animation-delay: calc(var(--i, 0) * 70ms);
}
.part:hover .sk-draw path.is-fill,
.part:focus-within .sk-draw path.is-fill,
.part.is-drawing .sk-draw path.is-fill,
.notify__done .sk-draw path.is-fill { animation: sk-fade 0.6s var(--ease) 0.8s both; }
@keyframes sk-draw { from { stroke-dashoffset: var(--len); } to { stroke-dashoffset: 0; } }
@keyframes sk-fade { from { opacity: 0; } to { opacity: 1; } }

/* ---------- Reveal (only when motion is allowed and JS runs) ---------- */
.motion [data-reveal] { opacity: 0; }
.motion .section-head__rule { transform: scaleX(0); }
.motion .numbers__divider { transform: scaleY(0); }
.motion .statement__line { opacity: 0.2; }
.motion.intro-on .hero__title .word,
.motion.hero-pending .hero__title .word { opacity: 0; }
.motion.intro-on .site-header,
.motion.intro-on .rail { opacity: 0; }

/* ---------- Responsive ---------- */
@media (max-width: 1023px) {
  .rail { display: none; }
  .menu-toggle { display: inline-flex; }
  .progress { display: block; }
  .site-header__actions .btn--small { display: none; }
}
@media (min-width: 1024px) {
  .menu { display: none; }
}
@media (max-width: 899px) {
  .hero__grid { grid-template-columns: minmax(0, 1fr); gap: 40px; padding-bottom: 48px; }
  .hero__book { order: -1; padding-top: 8px; }
  .book { --w: clamp(170px, 46vw, 260px); }
  .hero__glow { right: -40vw; top: 0; width: 120vw; }
  .statement__line { display: inline; }
  .story__body { grid-template-columns: minmax(0, 1fr); }
  .story__clock { width: 120px; }
  .scene { width: 86vw; height: auto; min-height: 0; grid-template-columns: minmax(0, 1fr); }
  .scene__then { border-right: 1px solid var(--line); border-bottom: 0; min-height: 260px; }
  .scene__now { min-height: 220px; }
  .numbers__grid { grid-template-columns: minmax(0, 1fr); }
  .numbers__divider { height: 1px; transform-origin: left center; }
  .motion .numbers__divider { transform: scaleX(0); }
  .parts { grid-template-columns: minmax(0, 1fr); }
  .part { min-height: 0; }
  .part__body { padding-top: 56px; }
  .toolkit { grid-template-columns: minmax(0, 1fr); }
  .author__grid { grid-template-columns: minmax(0, 1fr); }
  .author__photo { max-width: 420px; }
  .notify__clock { right: -40vw; width: 130vw; }
}
@media (max-width: 520px) {
  :root { --header-h: 64px; }
  .hero__actions .btn { flex: 1 1 100%; }
  .coach__controls { flex-direction: column-reverse; }
  .coach__controls .btn { width: 100%; }
  .field__row .btn { width: 100%; }
  .notify__done { flex-direction: column; align-items: flex-start; }
}
@media (min-width: 900px) {
  /* pinned mode: the slider is driven by vertical scroll, so no native horizontal scrolling */
  .is-pinned .looked__viewport { overflow: hidden; scroll-snap-type: none; }
  .is-pinned .looked__nav { display: none; }
}
@media (min-width: 1024px) {
  /* scenes slide out from under a clean edge, clear of the side rail */
  .looked__viewport { margin-right: var(--gutter-r); }
  .looked__track { padding-right: 0; }
}

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
  .grain { animation: none; }
  .book, .book__shadow { animation: none; }
  .marquees { -webkit-mask-image: none; mask-image: none; }
  .marquee__track { animation: none; width: auto; flex-wrap: wrap; justify-content: center; }
  .marquee__list + .marquee__list { display: none; }
  .marquee__list { flex-wrap: wrap; justify-content: center; row-gap: 6px; }
  .notify__clock .clock-hand { animation: none; }
  main { animation: page-fade 0.6s ease both !important; animation-duration: 0.6s !important; }
  .js .coach__q, .js .coach__end { transition: opacity 0.4s ease !important; transform: none !important; }
  .js .coach__q.is-active, .js .coach__end.is-active { transition: opacity 0.4s ease !important; }
  .menu { transition: visibility 0s !important; clip-path: none; }
  .menu-open .menu { clip-path: none; }
}
@keyframes page-fade { from { opacity: 0; } to { opacity: 1; } }
