/* BookLab v2 — Brandbook 2.0. Plain CSS, no build step, no CDN framework. */

:root {
  --ink: #0A0A0A;
  --kadm: #FF3B14;
  --lime: #D9F24B;
  --white: #FFFFFF;
  --grey: #5A5A5A;
  --grey-dark: #2A2A2A;
  --line: #E2E2E2;
  --soft: #F4F4F1;
  --error: #B3260C;
  --display: "Anton", Impact, "Arial Narrow Bold", "Arial Narrow", sans-serif;
  --text: "Inter", system-ui, -apple-system, "Segoe UI", Arial, sans-serif;
  --radius: 2px;
  --border: 2px solid var(--ink);
  --shadow: 4px 4px 0 var(--ink);
  --wrap: 1200px;
  --gutter: 20px;
  --header-h: 64px;
}

@media (min-width: 768px) {
  :root { --gutter: 40px; }
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 16px); }

body {
  margin: 0;
  background: var(--white);
  color: var(--ink);
  font-family: var(--text);
  font-size: 17px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img, svg { display: block; max-width: 100%; }
a { color: inherit; }
button, input, textarea, select { font: inherit; color: inherit; }
button { cursor: pointer; }
p { margin: 0 0 1em; }
h1, h2, h3 { margin: 0; }

:focus-visible { outline: 3px solid var(--kadm); outline-offset: 2px; }
.on-kadm :focus-visible, .btn-kadm:focus-visible { outline-color: var(--ink); }

.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}

.skip-link {
  position: absolute; left: 12px; top: -60px; z-index: 100;
  background: var(--ink); color: var(--white); padding: 10px 14px; font-weight: 700;
}
.skip-link:focus { top: 12px; }

.wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gutter); }

/* Type */
.display {
  font-family: var(--display);
  font-weight: 400;
  text-transform: uppercase;
  letter-spacing: 0.005em;
  line-height: 0.95;
}
.h1 { font-size: clamp(44px, 9vw, 104px); }
.h2 { font-size: clamp(36px, 6vw, 72px); }
.h3 { font-size: clamp(26px, 3.4vw, 36px); }
.eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  font-size: 13px; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase;
}
.eyebrow::before { content: ""; width: 10px; height: 10px; background: var(--kadm); }
.on-kadm .eyebrow::before, .on-lime .eyebrow::before { background: var(--ink); }
.lead { font-size: clamp(18px, 2.1vw, 22px); line-height: 1.45; max-width: 40ch; }
.muted { color: var(--grey); }
.small { font-size: 14px; }
.dot { color: var(--kadm); }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 52px; padding: 12px 22px;
  border: var(--border); border-radius: var(--radius);
  background: var(--white); color: var(--ink);
  font-weight: 700; font-size: 17px; letter-spacing: 0.06em; text-transform: uppercase;
  text-decoration: none; text-align: center; line-height: 1.15;
  transition: transform 120ms ease, box-shadow 120ms ease, background-color 120ms ease, color 120ms ease;
}
.btn:hover { transform: translate(-2px, -2px); box-shadow: var(--shadow); }
.btn:active { transform: translate(0, 0); box-shadow: none; }
.btn[disabled], .btn[aria-disabled="true"] { opacity: 0.55; cursor: not-allowed; transform: none; box-shadow: none; }
/* White on kadm passes contrast only as large bold text: keep these buttons >= 19px bold. */
.btn-kadm { background: var(--kadm); color: var(--white); font-size: 19px; }
.btn-ink { background: var(--ink); color: var(--white); }
.btn-lime { background: var(--lime); }
.btn-ink:hover { box-shadow: 4px 4px 0 var(--kadm); }
.path-card .btn-lime { min-width: 260px; }
.btn-block { width: 100%; }
.btn-lg { min-height: 60px; font-size: 19px; }
.link-btn {
  background: none; border: 0; padding: 0; color: var(--ink);
  text-decoration: underline; text-underline-offset: 3px; font-weight: 600; font-size: inherit;
  min-height: 44px; display: inline-flex; align-items: center;
}

.chip {
  display: inline-flex; align-items: center; min-height: 44px; padding: 8px 14px;
  border: var(--border); border-radius: var(--radius); background: var(--white);
  font-size: 15px; font-weight: 600; text-decoration: none; text-align: left;
  transition: background-color 120ms ease, color 120ms ease;
}
.chip:hover { background: var(--ink); color: var(--white); }

/* Ticker */
.ticker { background: var(--ink); color: var(--white); overflow: hidden; border-bottom: var(--border); }
.ticker-track { display: flex; width: max-content; animation: ticker 42s linear infinite; }
.ticker:hover .ticker-track, .ticker:focus-within .ticker-track { animation-play-state: paused; }
.ticker-item {
  display: inline-flex; align-items: center; gap: 18px; padding: 9px 0 9px 18px;
  font-size: 14px; font-weight: 600; white-space: nowrap; background: none; border: 0; color: inherit;
}
.ticker-item::after { content: "•"; color: var(--kadm); }
.ticker-item:hover { text-decoration: underline; }
@keyframes ticker { from { transform: translateX(0); } to { transform: translateX(-50%); } }

/* Header */
.site-header { position: sticky; top: 0; z-index: 40; background: var(--white); border-bottom: var(--border); }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: var(--header-h); }
.logo { font-family: var(--display); font-size: 28px; line-height: 1; letter-spacing: 0.02em; text-decoration: none; }
.logo .dot { display: inline-block; }
.nav { display: none; align-items: center; gap: 26px; }
.nav a { text-decoration: none; font-weight: 600; font-size: 15px; }
.nav a:hover { text-decoration: underline; text-underline-offset: 4px; }
.nav .btn { min-height: 44px; padding: 8px 16px; font-size: 15px; }
.header-cta { min-height: 44px; padding: 8px 14px; font-size: 14px; }
@media (min-width: 900px) {
  .nav { display: flex; }
  .header-cta { display: none; }
}

/* Sections */
section { position: relative; }
.section { padding: clamp(64px, 9vw, 120px) 0; border-bottom: var(--border); }
.section-head { display: grid; gap: 18px; margin-bottom: clamp(32px, 5vw, 56px); }
.on-ink { background: var(--ink); color: var(--white); }
.on-ink .muted { color: #BDBDBD; }
.on-lime { background: var(--lime); }
.on-kadm { background: var(--kadm); color: var(--ink); }
.on-soft { background: var(--soft); }

/* Hero */
.hero { padding: clamp(40px, 7vw, 96px) 0 clamp(48px, 7vw, 96px); border-bottom: var(--border); }
.hero-grid { display: grid; gap: 40px; }
.hero h1 .accent { color: var(--kadm); }
.hero-form { margin-top: 28px; display: grid; gap: 12px; max-width: 640px; }
.field-label { font-weight: 700; font-size: 15px; }
.hero-form .field-label { font-weight: 800; font-size: clamp(19px, 1vw + 15px, 22px); line-height: 1.2; }
.input, .textarea {
  width: 100%; min-height: 56px; padding: 14px 16px;
  border: var(--border); border-radius: var(--radius); background: var(--white);
  font-size: 18px;
}
.textarea { min-height: 120px; resize: vertical; line-height: 1.45; }
/* #767676 is the lightest grey that still reads at 4.5:1 on white (WCAG AA). */
.input::placeholder, .textarea::placeholder { color: #767676; transition: color 400ms ease; }
.input.is-typing::placeholder { color: var(--ink); transition: none; }
.input[aria-invalid="true"], .textarea[aria-invalid="true"] { border-color: var(--error); }
.field-help { font-size: 14px; color: var(--grey); }
.field-error { font-size: 14px; color: var(--error); font-weight: 600; }
.hero-note { font-size: 14px; color: var(--grey); font-weight: 600; letter-spacing: 0.02em; }
/* The three promises do not fit one line below 414 px: break before the last one, never inside a phrase. */
@media (max-width: 413px) { .hero-note-sep { display: none; } .hero-note-last { display: block; } }
.nowrap { white-space: nowrap; }

.paths-start { display: grid; gap: 16px; }
.path-tile {
  display: grid; gap: 6px; padding: 22px; text-decoration: none;
  border: var(--border); border-radius: var(--radius); background: var(--white);
  transition: transform 120ms ease, box-shadow 120ms ease;
}
.path-tile:hover { transform: translate(-2px, -2px); box-shadow: var(--shadow); }
.path-tile .tile-name { font-family: var(--display); font-size: 34px; line-height: 1; text-transform: uppercase; }
.path-tile .tile-price { font-weight: 800; font-size: 18px; }
.path-tile .tile-desc { color: var(--grey-dark); font-size: 15px; }
.path-tile .tile-cta { margin-top: 8px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; font-size: 15px; }
.path-tile .tile-cta::after { content: " →"; color: var(--kadm); }
.path-tile.sell { background: var(--ink); color: var(--white); }
.path-tile.sell .tile-desc { color: #CFCFCF; }
@media (min-width: 640px) { .paths-start { grid-template-columns: 1fr 1fr; } }
@media (min-width: 1024px) {
  .hero-grid { grid-template-columns: 1.35fr 1fr; align-items: center; }
  .paths-start { grid-template-columns: 1fr; }
}

/* Proof */
.proof { border-bottom: var(--border); }
.proof-grid { display: grid; grid-template-columns: 1fr 1fr; }
.proof-item { padding: 22px var(--gutter); border-right: var(--border); border-bottom: var(--border); }
.proof-item:nth-child(2n) { border-right: 0; }
.proof-item:nth-last-child(-n+2) { border-bottom: 0; }
.proof-value { font-family: var(--display); font-size: clamp(28px, 4vw, 44px); line-height: 1; }
.proof-label { font-size: 14px; color: var(--grey-dark); margin-top: 6px; }
@media (min-width: 900px) {
  .proof-grid { grid-template-columns: repeat(4, 1fr); }
  .proof-item { border-bottom: 0; }
  .proof-item:nth-child(2n) { border-right: var(--border); }
  .proof-item:last-child { border-right: 0; }
}

/* Two columns */
.split { display: grid; gap: 40px; }
@media (min-width: 960px) { .split { grid-template-columns: 1fr 1fr; align-items: start; } }

/* TOC card */
.toc-card { background: var(--white); border: var(--border); border-radius: var(--radius); box-shadow: var(--shadow); padding: 22px; }
.toc-card-top { display: flex; justify-content: space-between; gap: 12px; align-items: center; font-size: 13px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; }
.badge { display: inline-block; padding: 3px 8px; border: var(--border); font-size: 12px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; background: var(--white); }
.badge-lime { background: var(--lime); }
.toc-title { font-weight: 800; font-size: 20px; line-height: 1.25; margin: 14px 0 10px; }
.toc-list { list-style: none; margin: 0; padding: 0; }
.toc-list li { display: grid; grid-template-columns: 40px 1fr; gap: 8px; padding: 10px 0; border-top: 1px solid var(--line); }
.toc-list .num { font-family: var(--display); color: var(--kadm); font-size: 20px; line-height: 1.2; }
.toc-list .sub { grid-column: 2; font-size: 14px; color: var(--grey); margin: 2px 0 0; padding-left: 0; list-style: none; }

/* Paths section */
.path-cards { display: grid; gap: 20px; }
@media (min-width: 900px) { .path-cards { grid-template-columns: 1fr 1fr; } }
.path-card { border: var(--border); border-radius: var(--radius); padding: 24px; background: var(--white); display: grid; gap: 12px; align-content: start; }
/* Side by side, both cards share six rows (subgrid), so prices, notes, topic lists and the two CTAs line up. */
@media (min-width: 900px) {
  .path-cards { grid-template-rows: repeat(7, auto); }
  .path-card { grid-row: span 7; grid-template-rows: subgrid; }
}
.path-card-name { display: block; font-family: var(--display); font-size: 36px; text-transform: uppercase; line-height: 1; }
.path-card-from { display: block; font-weight: 800; }
.path-card-files { font-size: 15px; padding: 10px 12px; background: var(--soft); border-left: 4px solid var(--kadm); }
/* The sample publication of a path. Small text is ink, not kadm: kadm on white is 3.57:1, enough only for large bold text. */
.sample-row { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 14px; padding: 10px 12px 10px 10px; border: var(--border); border-radius: var(--radius); background: var(--white); color: var(--ink); text-decoration: none; box-shadow: var(--shadow); }
.sample-row:hover { background: var(--soft); }
.sample-row:focus-visible { outline: 3px solid var(--kadm); outline-offset: 2px; }
.sample-thumb { width: 58px; height: 82px; object-fit: cover; object-position: top; border: 1px solid var(--ink); background: var(--white); display: block; }
.sample-text { display: grid; gap: 2px; min-width: 0; }
.sample-kicker { font-size: 13px; font-weight: 800; letter-spacing: 0.06em; text-transform: uppercase; }
.sample-title { font-weight: 800; line-height: 1.25; }
.sample-meta { font-size: 14px; color: var(--grey); }
.sample-arrow { color: var(--kadm); font-weight: 800; font-size: 20px; }
.path-card-cta { align-self: end; padding-top: 4px; }
.topics-label { display: flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 800; letter-spacing: 0.06em; text-transform: uppercase; color: var(--grey); }
.topics-label::before { content: ""; width: 8px; height: 8px; background: var(--kadm); flex: none; }
.topic-list { list-style: none; margin: 8px 0 0; padding: 0; border-top: 1px solid var(--line); }
.topic-list a { display: flex; justify-content: space-between; align-items: center; gap: 12px; min-height: 48px; padding: 10px 6px; border-bottom: 1px solid var(--line); color: var(--ink); text-decoration: none; font-weight: 600; font-size: 15px; transition: background-color 120ms ease; }
.topic-list a:hover { background: var(--soft); }
.topic-list .topic-arrow { color: var(--kadm); font-weight: 800; font-size: 18px; flex: none; transition: transform 120ms ease; }
.topic-list a:hover .topic-arrow { transform: translateX(3px); }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }

/* How */
.steps { list-style: none; margin: 0; padding: 0; display: grid; gap: 0; border-top: 2px solid var(--white); }
.steps li { display: grid; grid-template-columns: 64px 1fr; gap: 16px; padding: 22px 0; border-bottom: 2px solid #333; }
.steps .step-num { font-family: var(--display); font-size: 44px; line-height: 1; color: var(--kadm); }
.steps .step-title { font-weight: 800; font-size: 20px; }
@media (min-width: 900px) {
  .steps { grid-template-columns: repeat(4, 1fr); border-top: 0; }
  .steps li { grid-template-columns: 1fr; border-bottom: 0; border-left: 2px solid #333; padding: 0 22px; }
  .steps li:first-child { border-left: 0; padding-left: 0; }
}

/* Feature list */
.feature-list { list-style: none; margin: 0; padding: 0; border-top: var(--border); }
.feature-list li { display: grid; grid-template-columns: 56px 1fr; gap: 12px; padding: 18px 0; border-bottom: var(--border); }
.feature-list .num { font-family: var(--display); font-size: 26px; color: var(--kadm); line-height: 1.1; }
.feature-list .title { font-weight: 800; }

/* Writers */
.is-isnt { display: grid; gap: 16px; }
@media (min-width: 700px) { .is-isnt { grid-template-columns: 1fr 1fr; } }
.is-box { border: var(--border); padding: 20px; background: var(--white); }
.is-box h3 { font-size: 15px; font-weight: 800; letter-spacing: 0.08em; text-transform: uppercase; margin-bottom: 10px; }
.is-box ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.is-box li { display: grid; grid-template-columns: 18px 1fr; gap: 8px; }
.is-box.yes li::before { content: "✓"; font-weight: 800; color: var(--ink); }
.is-box.no li::before { content: "✕"; font-weight: 800; color: var(--error); }
.example-box { margin-top: 20px; border: var(--border); background: var(--lime); padding: 22px; display: grid; gap: 14px; }
@media (min-width: 700px) { .example-box { grid-template-columns: 1fr auto; align-items: center; } }
.example-box .title { font-family: var(--display); font-size: 28px; text-transform: uppercase; line-height: 1; }

/* Pricing */
.table-scroll { overflow-x: auto; border: var(--border); background: var(--white); }
.price-table { width: 100%; border-collapse: collapse; min-width: 300px; font-variant-numeric: tabular-nums; }
.price-table caption { text-align: left; padding: 12px clamp(6px, 2vw, 14px); font-size: 14px; color: var(--grey); caption-side: top; }
.price-table th, .price-table td { padding: 12px clamp(6px, 2vw, 14px); border-top: 1px solid var(--line); text-align: right; }
.price-table thead th { border-top: var(--border); border-bottom: var(--border); font-size: 15px; vertical-align: bottom; }
.price-table th[scope="row"], .price-table thead th:first-child { text-align: left; }
.price-table td { font-weight: 700; font-size: 18px; white-space: nowrap; }
.price-table .range { display: block; font-weight: 500; font-size: 13px; color: var(--grey); }
.price-table .rec { display: inline-block; font-size: 11px; font-weight: 800; text-transform: uppercase; letter-spacing: 0.06em; background: var(--lime); border: 1.5px solid var(--ink); padding: 1px 5px; margin-left: 6px; vertical-align: middle; }
.price-notes { display: grid; gap: 16px; margin-top: 20px; }
@media (min-width: 800px) { .price-notes { grid-template-columns: 1fr 1fr; } }
.price-note { border: var(--border); padding: 18px; background: var(--white); display: grid; gap: 6px; }
.price-note .name { font-family: var(--display); font-size: 26px; text-transform: uppercase; line-height: 1; }
.price-note .example { font-weight: 800; }
.vat-note { margin-top: 14px; font-size: 14px; color: var(--grey); }

/* FAQ */
.faq-list { border-top: var(--border); }
.faq-item { border-bottom: var(--border); }
.faq-q {
  width: 100%; display: flex; justify-content: space-between; align-items: center; gap: 16px;
  padding: 20px 0; background: none; border: 0; text-align: left; font-weight: 800; font-size: 19px; min-height: 56px;
}
.faq-sign { font-family: var(--display); font-size: 30px; line-height: 1; color: var(--kadm); flex: 0 0 auto; }
.faq-a { padding: 0 0 22px; max-width: 72ch; color: var(--grey-dark); }

/* Final CTA. White on kadm is 3.57:1, which passes only as large text (≥24px, or ≥18.66px bold),
   so every line here is sized to that threshold. */
.final-cta { text-align: left; }
.final-cta, .final-cta h2, .final-cta p { color: var(--white); }
.final-cta .lead { font-size: 24px; }
.final-cta p.small { font-size: 19px; font-weight: 700; }
.final-cta .btn { margin-top: 26px; }

/* Footer */
.site-footer { background: var(--ink); color: var(--white); padding: 48px 0 28px; }
.footer-grid { display: grid; gap: 32px; }
@media (min-width: 900px) { .footer-grid { grid-template-columns: 1.4fr 1fr 0.9fr 1.2fr; } }
.footer-nav { display: grid; gap: 4px; align-content: start; }
.footer-nav a, .footer-nav button { color: var(--white); background: none; border: 0; padding: 0; text-align: left; text-decoration: underline; text-underline-offset: 3px; min-height: 40px; display: inline-flex; align-items: center; font-size: 15px; }
.footer-small { font-size: 14px; color: #BDBDBD; }
.stack > p.footer-small { margin: 0; }
.site-footer .stack { align-content: start; }
.footer-bottom { margin-top: 32px; padding-top: 18px; border-top: 1px solid #333; font-size: 13px; color: #9A9A9A; }
.site-footer .logo { color: var(--white); }
.compact-footer { border-top: var(--border); padding: 22px 0 40px; font-size: 14px; }
.compact-footer .wrap { display: flex; flex-wrap: wrap; gap: 6px 20px; align-items: center; }
.compact-footer a, .compact-footer button { background: none; border: 0; padding: 0; text-decoration: underline; text-underline-offset: 3px; min-height: 40px; font-size: 14px; display: inline-flex; align-items: center; line-height: 1.2; }
.compact-social { display: inline-flex; flex-wrap: wrap; gap: 6px 16px; align-items: center; }
.social-follow { border-top: 1px solid var(--line); padding-top: 18px; display: grid; gap: 10px; }
.social-buttons { display: flex; flex-wrap: wrap; gap: 10px; }

/* Reveal on scroll (added by JS only when motion is welcome) */
.reveal-ready .reveal { opacity: 0; transform: translateY(18px); transition: opacity 520ms ease, transform 520ms ease; }
.reveal-ready .reveal.is-visible { opacity: 1; transform: none; }

/* ---------- Order flow ---------- */
.flow-page { min-height: 100vh; display: flex; flex-direction: column; background: var(--white); }
.flow-header { border-bottom: var(--border); }
.flow-header .wrap { display: flex; justify-content: space-between; align-items: center; min-height: 60px; gap: 12px; }
.flow-step-label { font-weight: 700; font-size: 14px; letter-spacing: 0.06em; text-transform: uppercase; }
.flow-body { flex: 1; padding: 24px 0 140px; }
.flow-grid { display: grid; gap: 32px; }
@media (min-width: 1024px) {
  .flow-grid { grid-template-columns: minmax(0, 1fr) 360px; align-items: start; }
  .flow-body { padding-bottom: 64px; }
}
.flow-main { max-width: 720px; display: grid; gap: 18px; align-content: start; }
.progress { display: grid; grid-template-columns: repeat(var(--steps, 4), 1fr); gap: 6px; }
.progress span { height: 6px; background: var(--line); }
.progress span.done { background: var(--ink); }
.progress span.now { background: var(--kadm); }
.flow-title { font-size: clamp(38px, 7vw, 64px); }
.purpose-line { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; font-size: 15px; padding: 8px 12px; border: var(--border); width: fit-content; }

.options { display: grid; gap: 10px; }
.option {
  display: grid; grid-template-columns: 1fr auto; gap: 4px 16px; align-items: center;
  width: 100%; min-height: 64px; padding: 14px 16px;
  border: var(--border); border-radius: var(--radius); background: var(--white); color: var(--ink);
  text-align: left; transition: background-color 120ms ease, color 120ms ease;
}
.option:hover { background: var(--soft); }
.option[aria-checked="true"] { background: var(--ink); color: var(--white); }
.option .opt-name { font-weight: 800; font-size: 18px; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.option .opt-detail { grid-column: 1; font-size: 14px; color: var(--grey); }
.option[aria-checked="true"] .opt-detail { color: #D0D0D0; }
.option .opt-price { grid-row: 1 / span 2; grid-column: 2; font-weight: 500; color: var(--grey); white-space: nowrap; font-variant-numeric: tabular-nums; }
.option[aria-checked="true"] .opt-price { font-weight: 800; color: var(--white); }
.option .rec { font-size: 11px; font-weight: 800; letter-spacing: 0.06em; text-transform: uppercase; background: var(--lime); color: var(--ink); border: 1.5px solid var(--ink); padding: 1px 6px; }
.option.pick { grid-template-columns: 28px 1fr auto; }
.option.pick .radio-dot { grid-row: 1 / span 2; width: 22px; height: 22px; border: var(--border); border-radius: 50%; background: var(--white); }
.option.pick[aria-checked="true"] .radio-dot { border-color: var(--white); box-shadow: inset 0 0 0 5px var(--ink); }
.option.pick .opt-name, .option.pick .opt-detail { grid-column: 2; }
.option.pick .opt-price { grid-column: 3; }
.option.purpose { grid-template-columns: 28px 1fr; align-items: start; }
.option.purpose .radio-dot { width: 22px; height: 22px; border: var(--border); border-radius: 50%; margin-top: 3px; background: var(--white); }
.option.purpose[aria-checked="true"] .radio-dot { border-color: var(--white); box-shadow: inset 0 0 0 5px var(--ink); background: var(--white); }
.option.purpose .opt-body { display: grid; gap: 4px; }
.option.purpose .opt-price { grid-row: auto; grid-column: auto; font-weight: 800; color: inherit; }
.group-label { font-weight: 800; font-size: 14px; letter-spacing: 0.08em; text-transform: uppercase; margin-top: 8px; }

.check {
  display: grid; grid-template-columns: 28px 1fr auto; gap: 12px; align-items: start; width: 100%;
  padding: 14px 16px; min-height: 56px; border: var(--border); border-radius: var(--radius); background: var(--white); text-align: left;
}
.check.plain { border: 0; padding: 8px 0; grid-template-columns: 28px 1fr; }
.check .box { width: 24px; height: 24px; border: var(--border); display: grid; place-items: center; font-weight: 900; font-size: 15px; background: var(--white); margin-top: 1px; }
.check input:checked + .box { background: var(--ink); color: var(--white); }
.check input:focus-visible + .box { outline: 3px solid var(--kadm); outline-offset: 2px; }
.check { cursor: pointer; position: relative; }
.check .check-price { font-weight: 800; white-space: nowrap; }
.check-detail { display: block; font-size: 14px; color: var(--grey); font-weight: 400; }
.package-row { display: grid; grid-template-columns: 28px 1fr auto; gap: 12px; padding: 14px 16px; border: var(--border); background: var(--lime); }
.package-row .box { width: 24px; height: 24px; border: var(--border); display: grid; place-items: center; background: var(--ink); color: var(--white); font-weight: 900; font-size: 15px; }
.package-row .check-price { font-weight: 800; }
.edition-note { font-size: 14px; color: var(--grey); }

.summary { border: var(--border); }
.summary-row { display: flex; justify-content: space-between; gap: 12px; padding: 10px 14px; border-top: 1px solid var(--line); font-size: 15px; }
.summary-row:first-child { border-top: 0; }
.summary-row .v { font-weight: 700; white-space: nowrap; font-variant-numeric: tabular-nums; }
.summary-total { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; padding: 14px; border-top: var(--border); background: var(--soft); }
.summary-total .label { font-weight: 800; }
.summary-total .amount { font-family: var(--display); font-size: 32px; line-height: 1; }
.summary-total .was { text-decoration: line-through; color: var(--grey); font-size: 16px; margin-right: 8px; font-family: var(--text); }
.summary-topic { padding: 12px 14px; border-bottom: var(--border); display: flex; justify-content: space-between; gap: 12px; align-items: flex-start; }
.summary-topic .t { font-weight: 700; overflow-wrap: anywhere; }

.disclosure { display: flex; flex-wrap: wrap; gap: 4px 20px; }
.inline-field { display: grid; gap: 8px; padding: 14px; border: var(--border); background: var(--soft); }
.inline-row { display: grid; grid-template-columns: 1fr auto; gap: 8px; }
.inline-row .btn { min-height: 56px; }
.notice { padding: 12px 14px; border: var(--border); font-size: 15px; }
.notice-error { border-color: var(--error); color: var(--error); font-weight: 600; background: #FFF5F2; }
.notice-ok { background: var(--lime); font-weight: 600; }

.flow-actions {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 30;
  background: var(--white); border-top: var(--border);
  padding: 12px var(--gutter) calc(12px + env(safe-area-inset-bottom));
}
.flow-actions-inner { max-width: 720px; display: grid; gap: 8px; }
.flow-actions .total-line { display: flex; justify-content: space-between; align-items: baseline; font-weight: 700; }
.flow-actions .total-line .amount { font-family: var(--display); font-size: 28px; line-height: 1; }
.flow-actions .secondary { display: flex; justify-content: space-between; align-items: center; gap: 12px; font-size: 14px; color: var(--grey); }
.flow-actions .secondary .link-btn { white-space: nowrap; }
@media (min-width: 1024px) {
  .flow-actions { position: static; border-top: 0; padding: 8px 0 0; background: transparent; }
  .flow-actions-inner { max-width: none; }
}

.flow-aside { display: none; }
@media (min-width: 1024px) {
  .flow-aside { display: block; position: sticky; top: 24px; border: var(--border); padding: 20px; background: var(--soft); }
}
.flow-aside h2 { font-family: var(--display); font-size: 26px; text-transform: uppercase; font-weight: 400; margin-bottom: 12px; }
.aside-row { display: flex; justify-content: space-between; gap: 12px; padding: 8px 0; border-top: 1px solid #D5D5D0; font-size: 15px; }
.aside-row .v { font-weight: 700; text-align: right; overflow-wrap: anywhere; }
.aside-benefits { list-style: none; margin: 16px 0 0; padding: 0; display: grid; gap: 8px; font-size: 14px; }
.aside-benefits li::before { content: "✓ "; font-weight: 800; }

.loader { display: inline-flex; gap: 6px; }
.loader span { width: 10px; height: 10px; background: var(--kadm); animation: blink 1.2s infinite ease-in-out; }
.loader span:nth-child(2) { animation-delay: 0.2s; }
.loader span:nth-child(3) { animation-delay: 0.4s; }
@keyframes blink { 0%, 80%, 100% { opacity: 0.25; transform: scale(0.85); } 40% { opacity: 1; transform: scale(1); } }

.back-btn { justify-self: start; }

/* ---------- Status page ---------- */
.status-page { min-height: 100vh; display: flex; flex-direction: column; }
.status-main { flex: 1; padding: 28px 0 48px; }
.status-card { max-width: 720px; display: grid; gap: 18px; }
.order-no { font-size: 13px; color: var(--grey); overflow-wrap: anywhere; }
.topic-block { border-left: 4px solid var(--kadm); padding: 4px 0 4px 12px; }
.topic-block .t { font-weight: 800; font-size: 18px; overflow-wrap: anywhere; }
.price-big { font-family: var(--display); font-size: 44px; line-height: 1; }
.price-was { text-decoration: line-through; color: var(--grey); font-size: 20px; margin-right: 10px; }
.stages { list-style: none; margin: 0; padding: 0; border: var(--border); }
.stages li { display: grid; grid-template-columns: 30px 1fr auto; gap: 12px; align-items: center; padding: 14px 16px; border-top: 1px solid var(--line); }
.stages li:first-child { border-top: 0; }
.stages .mark { width: 22px; height: 22px; border: var(--border); display: grid; place-items: center; font-size: 13px; font-weight: 900; }
.stages .done .mark { background: var(--ink); color: var(--white); }
.stages .now .mark { background: var(--kadm); animation: pulse 1.6s ease-in-out infinite; }
.stages .todo { color: var(--grey); }
.stages .todo .mark { border-color: var(--grey); }
.stages .state { font-size: 14px; font-weight: 600; }
@keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.45; } }
.downloads { display: grid; gap: 10px; }
.downloads .row { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.facts { border: var(--border); }
.facts .row { display: flex; justify-content: space-between; gap: 12px; padding: 12px 14px; border-top: 1px solid var(--line); }
.facts .row:first-child { border-top: 0; }
.facts .v { font-weight: 700; text-align: right; }
.ba-card { max-width: 720px; margin-top: 28px; background: var(--ink); color: var(--white); border: var(--border); padding: 32px; display: grid; gap: 16px; }
.ba-card .eyebrow { color: var(--lime); }
.ba-card .ba-title { margin: 0; color: var(--white); }
.ba-card .ba-text { margin: 0; color: #E6E6E6; max-width: 560px; font-size: 17px; line-height: 1.5; }
.ba-actions { display: flex; flex-wrap: wrap; gap: 12px 20px; align-items: center; }
.ba-note { font-size: 14px; color: #BDBDBD; }
@media (max-width: 599px) { .ba-card { padding: 24px 20px; } }
.offer-list { display: grid; gap: 10px; }
.offer { border: var(--border); padding: 16px; display: grid; gap: 10px; background: var(--white); }
@media (min-width: 640px) { .offer { grid-template-columns: 1fr auto; align-items: center; } }
.offer .name { font-weight: 800; font-size: 18px; }
.box-title { font-weight: 800; font-size: 14px; letter-spacing: 0.08em; text-transform: uppercase; }
.stars { display: flex; gap: 6px; }
.star { background: none; border: 0; padding: 4px; min-width: 44px; min-height: 44px; display: grid; place-items: center; }
.star svg { width: 34px; height: 34px; }
.affiliate { border-top: var(--border); background: var(--lime); padding: 48px 0; }
.affiliate-inner { max-width: 960px; }
.example-note { font-size: 14px; margin: 0; }
.affiliate .steps-mini { list-style: none; margin: 18px 0; padding: 0; display: grid; gap: 10px; }
@media (min-width: 800px) { .affiliate .steps-mini { grid-template-columns: repeat(4, 1fr); } }
.affiliate .steps-mini li { border: var(--border); background: var(--white); padding: 14px; }
.affiliate .steps-mini .n { font-family: var(--display); color: var(--kadm); font-size: 24px; line-height: 1; }
.spinner { width: 22px; height: 22px; border: 3px solid var(--line); border-top-color: var(--kadm); border-radius: 50%; animation: spin 0.9s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- Legal ---------- */
.legal-wrap { padding: 32px 0 64px; }
.legal-page { max-width: 760px; }
.legal-page h1 { font-family: var(--display); font-weight: 400; text-transform: uppercase; font-size: clamp(32px, 5vw, 52px); line-height: 1; margin: 8px 0 16px; }
.legal-page h2 { font-size: 22px; font-weight: 800; margin: 34px 0 10px; }
.legal-page h3 { font-size: 18px; font-weight: 800; margin: 20px 0 8px; }
.legal-page p, .legal-page li { line-height: 1.65; }
.legal-page ul, .legal-page ol { padding-left: 22px; }
.legal-page section { border-top: 1px solid var(--line); }
.legal-page blockquote { border-left: 4px solid var(--kadm); margin: 16px 0; padding: 8px 14px; background: var(--soft); }
.legal-page table { border-collapse: collapse; width: 100%; font-size: 15px; }
.legal-page th, .legal-page td { border: 1px solid var(--line); padding: 8px; text-align: left; vertical-align: top; }

/* ---------- Cookie consent (card as on mojcieplydom.pl, BookLab colours) ---------- */
.cookie-layer { position: fixed; inset: 0; z-index: 90; display: flex; align-items: center; justify-content: center; padding: 16px; pointer-events: none; }
.cookie-card {
  pointer-events: auto; width: 100%; max-width: 420px; max-height: calc(100dvh - 32px); overflow-y: auto;
  background: var(--ink); color: rgba(255, 255, 255, 0.85); border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--radius); box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.45); padding: 16px;
  font-size: 13px; line-height: 1.625;
}
@media (min-width: 768px) { .cookie-card { padding: 20px; } }
.cookie-card a { color: inherit; text-decoration: underline; text-underline-offset: 2px; }
.cookie-card a:hover, .cookie-link:hover { color: var(--white); }
.cookie-title { margin: 0; font-size: 16px; font-weight: 700; line-height: 1.5; color: var(--white); }
.cookie-title:focus { outline: none; }
.cookie-text { margin: 6px 0 0; }
.cookie-actions { margin-top: 12px; display: flex; gap: 8px; }
.cookie-btn { flex: 1; min-height: 44px; padding: 10px 12px; border: 1px solid transparent; border-radius: var(--radius); font-size: 14px; font-weight: 700; line-height: 20px; transition: background-color 120ms ease; }
.cookie-btn-primary { background: var(--lime); color: var(--ink); }
.cookie-btn-primary:hover { background: #C6DE3A; }
.cookie-btn-dark { background: var(--grey-dark); color: var(--white); }
.cookie-btn-dark:hover { background: #3A3A3A; }
.cookie-btn-outline { background: transparent; color: var(--white); border-color: rgba(255, 255, 255, 0.25); }
.cookie-btn-outline:hover { background: rgba(255, 255, 255, 0.1); }
.cookie-link { display: block; width: 100%; margin-top: 10px; padding: 4px 0; background: none; border: 0; text-align: center; font-size: 13px; color: rgba(255, 255, 255, 0.7); text-decoration: underline; text-underline-offset: 2px; }
.cookie-categories { margin-top: 12px; display: grid; gap: 8px; line-height: 1.375; }
.cookie-category { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; padding: 12px; background: rgba(255, 255, 255, 0.05); border-radius: var(--radius); }
label.cookie-category { cursor: pointer; }
.cookie-category-name { display: block; font-weight: 700; color: var(--white); }
.cookie-category-desc { display: block; margin-top: 2px; color: rgba(255, 255, 255, 0.6); }
.cookie-category input { flex: none; width: 18px; height: 18px; margin: 2px 0 0; accent-color: var(--lime); }
.cookie-details { margin: 8px 0 0; font-size: 12px; color: rgba(255, 255, 255, 0.6); }

/* ---------- Misc ---------- */
.page-message { padding: 64px 0; }
.page-message .wrap { max-width: 720px; margin: 0 auto; display: grid; gap: 18px; justify-items: start; }
.stack { display: grid; gap: 12px; }
.row-wrap { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.notice-row { display: flex; gap: 12px; align-items: flex-start; }
.notice-row .spinner { flex: none; }
noscript .wrap { padding: 32px var(--gutter); }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; }
  .ticker-track { animation: none; }
  .reveal-ready .reveal { opacity: 1; transform: none; }
}

/* The page as plain HTML in index.html, for readers without JavaScript (crawlers, scripts switched
   off). index.html hides it and a <noscript> style there shows it; these rules only shape it for a
   browser with scripts off. */
.static-page { max-width: 760px; margin: 0 auto; padding: 32px 20px 64px; }
.static-page h1 { font-size: 32px; line-height: 1.2; margin: 16px 0; }
.static-page h2 { font-size: 24px; line-height: 1.25; margin: 40px 0 12px; }
.static-page h3 { font-size: 18px; margin: 24px 0 8px; }
.static-page p, .static-page li { line-height: 1.6; }
.static-page ul, .static-page ol { padding-left: 22px; }
.static-page a { text-decoration: underline; }
.static-page table { border-collapse: collapse; width: 100%; margin: 16px 0; }
.static-page caption { text-align: left; font-weight: 700; padding-bottom: 8px; }
.static-page th, .static-page td { border: 1px solid var(--ink); padding: 8px 10px; text-align: left; }
