/* =========================================================
   Puzzle Magazine – site styles
   Mobile-first. No framework. Fonts are self-hosted (no Google requests).
   ========================================================= */

@font-face { font-family: "Fraunces"; src: url("../fonts/fraunces.woff2") format("woff2"); font-weight: 100 900; font-display: swap; }
@font-face { font-family: "Figtree"; src: url("../fonts/figtree-400.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Figtree"; src: url("../fonts/figtree-500.woff2") format("woff2"); font-weight: 500; font-display: swap; }
@font-face { font-family: "Figtree"; src: url("../fonts/figtree-700.woff2") format("woff2"); font-weight: 600 800; font-display: swap; }

:root {
  --paper: #fbf8f1;
  --paper-2: #f3eee2;
  --card: #ffffff;
  --ink: #1d1a17;
  --ink-2: #4a443d;
  --muted: #736a5f;
  --line: #e4dccb;

  --accent: #e2b53b;
  --green: #1f7a6d;
  --red: #d9502f;

  --radius: 14px;
  --radius-sm: 8px;
  --shadow: 0 1px 2px rgba(29,26,23,.06), 0 6px 18px -8px rgba(29,26,23,.18);
  --shadow-lg: 0 2px 4px rgba(29,26,23,.06), 0 18px 40px -16px rgba(29,26,23,.32);

  --max: 1180px;
  --gutter: clamp(16px, 4vw, 32px);
  --head-h: 64px;

  --f-display: "Fraunces", Georgia, "Times New Roman", serif;
  --f-body: "Figtree", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 150px; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } * { transition: none !important; } }

body { margin: 0; background: var(--paper); color: var(--ink); font: 400 17px/1.6 var(--f-body); -webkit-font-smoothing: antialiased; }
img { max-width: 100%; height: auto; }
a { color: var(--green); text-underline-offset: 3px; text-decoration-thickness: 1.5px; }
a:hover { color: var(--ink); }
h1, h2, h3 { font-family: var(--f-display); font-weight: 750; line-height: 1.12; letter-spacing: -.01em; margin: 0 0 .5em; text-wrap: balance; }
h1 { font-size: clamp(2rem, 1.2rem + 3.4vw, 3.3rem); font-weight: 800; }
h2 { font-size: clamp(1.45rem, 1.1rem + 1.3vw, 1.95rem); }
h3 { font-size: 1.15rem; }
p { margin: 0 0 1em; }
.small { font-size: .9rem; color: var(--muted); }

.sr-only { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--ink); color: #fff; padding: 8px 14px; border-radius: 6px; z-index: 100; }
.skip:focus { left: 8px; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; border-radius: 4px; }

/* Layout: children of <main> are centred unless they opt out with .bleed */
.wrap, main > :not(.bleed) { width: min(100% - 2 * var(--gutter), var(--max)); margin-inline: auto; }
.bleed { width: 100%; }

.eyebrow { font-size: .78rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--c, var(--green)); margin-bottom: .6em; }
.lede { font-size: clamp(1.05rem, 1rem + .3vw, 1.2rem); color: var(--ink-2); max-width: 38em; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5em;
  min-height: 48px; padding: .7em 1.3em; border-radius: 999px; border: 2px solid var(--ink);
  background: transparent; color: var(--ink); font: 700 1rem/1.1 var(--f-body); text-decoration: none; cursor: pointer;
  transition: transform .15s, box-shadow .15s, background .15s;
}
.btn:hover { transform: translateY(-1px); box-shadow: 0 4px 0 var(--ink); color: var(--ink); }
.btn--primary { background: var(--ink); color: var(--paper); }
.btn--primary:hover { color: var(--paper); box-shadow: 0 4px 0 var(--accent); }
.btn--accent { background: var(--accent); border-color: var(--accent); color: var(--ink); }
.btn--ghost { border-color: var(--line); background: var(--card); }
.btn--ghost:hover { border-color: var(--ink); }
.btn--block { width: 100%; }
.btn--sm { min-height: 40px; padding: .5em 1.1em; font-size: .92rem; }
.btn[disabled] { cursor: not-allowed; background: var(--paper-2); border-color: var(--line); color: var(--muted); transform: none; box-shadow: none; }

/* ---------- Offer bar & header ---------- */
.offer-bar { background: var(--accent); color: var(--ink); text-align: center; font-weight: 700; padding: 8px var(--gutter); font-size: .95rem; }

.site-head { position: sticky; top: 0; z-index: 50; background: rgba(251,248,241,.94); backdrop-filter: saturate(1.4) blur(10px); -webkit-backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); }
.site-head__inner { display: flex; align-items: center; justify-content: space-between; min-height: var(--head-h); gap: 16px; position: relative; }
.site-head__actions { display: flex; align-items: center; gap: 4px; }
.logo { display: inline-flex; align-items: center; gap: 10px; color: var(--ink); text-decoration: none; }
.logo__mark { width: 34px; height: 34px; flex: none; }
.logo__text { font: 600 1.25rem/1 var(--f-display); letter-spacing: -.01em; }
.logo__text b { font-weight: 800; margin-left: 2px; }
.basket { display: inline-flex; align-items: center; gap: 6px; padding: 8px 10px; border-radius: 999px; color: var(--ink); text-decoration: none; font-weight: 600; }
.basket:hover { background: var(--paper-2); }
.basket__label { font-size: .95rem; }

.nav-toggle { display: grid; place-items: center; width: 44px; height: 44px; border: 0; background: none; cursor: pointer; border-radius: 10px; }
.nav-toggle__bars, .nav-toggle__bars::before, .nav-toggle__bars::after { content: ""; display: block; width: 22px; height: 2px; background: var(--ink); border-radius: 2px; transition: transform .2s; }
.nav-toggle__bars { position: relative; }
.nav-toggle__bars::before { position: absolute; top: -7px; }
.nav-toggle__bars::after { position: absolute; top: 7px; }
.nav-toggle[aria-expanded="true"] .nav-toggle__bars { background: transparent; }
.nav-toggle[aria-expanded="true"] .nav-toggle__bars::before { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle__bars::after { transform: translateY(-7px) rotate(-45deg); }

.site-nav { position: absolute; left: calc(-1 * var(--gutter)); right: calc(-1 * var(--gutter)); top: 100%; display: none; flex-direction: column; background: var(--paper); border-bottom: 1px solid var(--line); padding: 4px var(--gutter) 16px; box-shadow: var(--shadow); }
.site-nav.is-open { display: flex; }
.site-nav a { padding: 14px 4px; color: var(--ink); text-decoration: none; font-weight: 600; border-bottom: 1px solid var(--line); display: flex; align-items: center; gap: 6px; }
.site-nav a:last-child { border-bottom: 0; }
.no-js .nav-toggle { display: none; }
.no-js .site-head__inner { flex-wrap: wrap; }
.no-js .site-nav { position: static; display: flex; flex-flow: row wrap; gap: 0 14px; box-shadow: none; border: 0; padding: 0 0 8px; background: none; }
.no-js .site-nav a { border: 0; padding: 6px 0; }

@media (min-width: 900px) {
  .nav-toggle { display: none; }
  .site-head__inner { flex-wrap: nowrap; }
  .site-nav { position: static; display: flex; flex-direction: row; gap: 2px; padding: 0; background: none; border: 0; box-shadow: none; order: 2; }
  .site-head__actions { order: 3; }
  .site-nav a { border: 0; padding: 8px 12px; border-radius: 999px; font-size: .95rem; }
  .site-nav a:hover { background: var(--paper-2); }
  .site-nav__ext { margin-left: 6px; border: 1.5px solid var(--line) !important; }
  .site-nav { margin-left: auto; }
}

/* ---------- Hero ---------- */
.hero {
  position: relative; border-bottom: 1px solid var(--line);
  background:
    linear-gradient(var(--line) 1px, transparent 1px) 0 0 / 36px 36px,
    linear-gradient(90deg, var(--line) 1px, transparent 1px) 0 0 / 36px 36px,
    var(--paper);
}
.hero::before { content: ""; position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(ellipse 70% 90% at 22% 40%, var(--paper) 38%, rgba(251,248,241,.55) 100%); }
.hero > * { position: relative; }
.hero__inner { display: grid; gap: 36px; padding: clamp(36px, 7vw, 88px) 0 clamp(28px, 5vw, 52px); align-items: center; }
.hero h1 em { font-style: normal; color: var(--red); }
.hero__cta { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 26px; }

.hero__art { position: relative; justify-self: center; width: min(100%, 360px); height: 290px; }
.fan { position: absolute; top: 10px; width: 46%; aspect-ratio: 3 / 4; border-radius: 10px; overflow: hidden; box-shadow: var(--shadow-lg); background: var(--card); border: 3px solid #fff; }
.fan img, .fan .cover-ph { width: 100%; height: 100%; object-fit: cover; display: block; }
.fan--0 { left: 2%; transform: rotate(-9deg) translateY(18px); }
.fan--1 { left: 27%; z-index: 2; transform: translateY(-6px); }
.fan--2 { right: 2%; transform: rotate(9deg) translateY(18px); }

.perks { list-style: none; padding: 0 0 26px; margin-top: 0; display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.perks li { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 12px 14px; display: flex; flex-direction: column; line-height: 1.3; }
.perks b { font-size: .95rem; }
.perks span { font-size: .84rem; color: var(--muted); }
@media (min-width: 860px) {
  .hero__inner { grid-template-columns: 1.3fr 1fr; }
  .hero__art { height: 340px; }
  .perks { grid-template-columns: repeat(4, 1fr); }
}

/* ---------- Finder ---------- */
.finder { position: sticky; top: var(--head-h); z-index: 40; background: rgba(251,248,241,.95); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); }
.finder__inner { display: flex; flex-direction: column; gap: 10px; padding-block: 12px; }
.finder__search { display: flex; align-items: center; gap: 8px; background: var(--card); border: 1.5px solid var(--line); border-radius: 999px; padding: 0 16px; color: var(--muted); }
.finder__search:focus-within { border-color: var(--ink); }
.finder__search input { flex: 1; border: 0; background: none; min-height: 44px; font: inherit; color: var(--ink); outline: none; min-width: 0; }
.chips { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; margin-inline: calc(-1 * var(--gutter)); padding-inline: var(--gutter); }
.chips::-webkit-scrollbar { display: none; }
.chip { flex: none; display: inline-flex; align-items: center; gap: 8px; padding: 8px 14px; border-radius: 999px; background: var(--card); border: 1.5px solid var(--line); color: var(--ink); text-decoration: none; font-weight: 600; font-size: .9rem; white-space: nowrap; }
.chip::before { content: ""; width: 9px; height: 9px; border-radius: 50%; background: var(--c); }
.chip:hover { border-color: var(--c); color: var(--ink); }
.finder__empty { text-align: center; color: var(--muted); padding: 48px 0; }
@media (min-width: 1000px) {
  .finder__inner { flex-direction: row; align-items: center; justify-content: space-between; }
  .finder__search { width: 300px; flex: none; }
  .chips { margin: 0; padding: 0; }
}

/* ---------- Shelves & cards ---------- */
.shelf { padding-top: clamp(40px, 6vw, 64px); }
.shelf__head { display: grid; grid-template-columns: 1fr auto; align-items: end; gap: 4px 16px; margin-bottom: 20px; border-bottom: 3px solid var(--ink); padding-bottom: 12px; }
.shelf__head h2 { margin: 0; display: flex; align-items: center; gap: 12px; }
.shelf__head h2::before { content: ""; width: 14px; height: 14px; background: var(--c, var(--ink)); border-radius: 3px; flex: none; }
.shelf__head p { grid-column: 1; margin: 0; color: var(--muted); font-size: .95rem; }
.shelf__count { grid-column: 2; grid-row: 1 / span 2; align-self: center; font-size: .85rem; font-weight: 700; color: var(--muted); background: var(--paper-2); padding: 4px 10px; border-radius: 999px; }

.grid { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (min-width: 600px) { .grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; } }
@media (min-width: 900px) { .grid { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 22px; } }
@media (min-width: 1120px) { .grid { grid-template-columns: repeat(5, minmax(0, 1fr)); } }
.legacy-page .grid { grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); }

.card { min-width: 0; }
.card__link { display: flex; flex-direction: column; height: 100%; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; text-decoration: none; color: var(--ink); transition: transform .18s ease, box-shadow .18s ease, border-color .18s; }
.card__link:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); border-color: var(--c); color: var(--ink); }
.card__cover { position: relative; aspect-ratio: 3 / 4; background: var(--paper-2); overflow: hidden; }
.card__cover .cover-img { width: 100%; height: 100%; object-fit: cover; display: block; }
.card__badge { position: absolute; top: 10px; left: 10px; background: var(--accent); color: var(--ink); font-size: .75rem; font-weight: 800; padding: 4px 9px; border-radius: 999px; }
.card__body { padding: 11px 14px 14px; border-top: 4px solid var(--c); flex: 1; display: flex; flex-direction: column; }
.card__title { font-size: 1.02rem; margin: 0 0 2px; }
.card__tag { margin: 0 0 4px; font-size: .84rem; line-height: 1.35; color: var(--ink-2); }
.card__meta { margin: auto 0 0; font-size: .8rem; color: var(--muted); }

.cover-ph { --c: var(--green); position: relative; width: 100%; height: 100%; display: flex; flex-direction: column; justify-content: flex-end; padding: 14px; color: #fff; overflow: hidden;
  background: linear-gradient(rgba(255,255,255,.16) 1.5px, transparent 1.5px) 0 0 / 22px 22px, linear-gradient(90deg, rgba(255,255,255,.16) 1.5px, transparent 1.5px) 0 0 / 22px 22px, var(--c); }
.cover-ph__kicker { position: absolute; top: 14px; left: 14px; font-size: .62rem; letter-spacing: .14em; text-transform: uppercase; font-weight: 700; }
.cover-ph__title { font: 800 1.3rem/1.05 var(--f-display); }

/* ---------- About, promos, video ---------- */
.about { display: grid; gap: 24px; margin-top: clamp(48px, 8vw, 88px); padding: clamp(24px, 4vw, 48px); background: var(--card); border: 1px solid var(--line); border-radius: calc(var(--radius) + 6px); }
.about__text { max-width: 40em; }
.about__text p { color: var(--ink-2); }
.about__card { background: var(--ink); color: var(--paper); border-radius: var(--radius); padding: 24px; align-self: start; }
.about__card h3 { color: var(--paper); }
.about__card p { color: rgba(251,248,241,.78); }
@media (min-width: 860px) { .about { grid-template-columns: 1fr 320px; } }

.promos { display: grid; gap: 20px; margin-top: clamp(40px, 6vw, 64px); padding: clamp(20px, 3vw, 32px); background: #fff7dd; border: 1px solid #f0dc9a; border-radius: calc(var(--radius) + 6px); --c: #9a6a00; }
.promos__intro h2 { margin-bottom: .3em; }
.promos__intro p { margin: 0 0 .6em; color: var(--ink-2); }
.promos__more { font-weight: 700; color: #7a5300; }
.promos__books { list-style: none; margin: 0; padding: 0 0 4px; display: grid; grid-auto-flow: column; grid-auto-columns: minmax(118px, 1fr); gap: 14px; overflow-x: auto; scrollbar-width: thin; }
.promo { display: flex; flex-direction: column; gap: 8px; text-decoration: none; color: var(--ink); font-weight: 600; font-size: .88rem; line-height: 1.25; }
.promo img { width: 100%; aspect-ratio: 3 / 4; object-fit: cover; border-radius: 4px; box-shadow: var(--shadow); background: #fff; transition: transform .15s, box-shadow .15s; }
.promo:hover img { transform: translateY(-3px); box-shadow: var(--shadow-lg); }
.promo:hover { color: var(--ink); }
@media (min-width: 900px) { .promos { grid-template-columns: 280px 1fr; align-items: center; gap: 32px; } }

.video-panel { display: grid; gap: 20px; margin-top: clamp(40px, 6vw, 64px); align-items: center; }
.video-panel__text p:last-child { color: var(--ink-2); }
@media (min-width: 860px) { .video-panel { grid-template-columns: 1fr 1.4fr; gap: 40px; } }

.yt { position: relative; aspect-ratio: 16 / 9; border-radius: var(--radius); overflow: hidden; background: #000; box-shadow: var(--shadow-lg); }
.yt iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.yt__play { position: absolute; inset: 0; display: flex; align-items: flex-end; background: #222 center / cover no-repeat; color: #fff; text-decoration: none; }
.yt__play::before { content: ""; position: absolute; inset: 0; background: linear-gradient(transparent 50%, rgba(0,0,0,.65)); }
.yt__btn { position: absolute; left: 50%; top: 50%; width: 72px; height: 50px; margin: -25px 0 0 -36px; background: #e62117; border-radius: 14px; transition: transform .15s; }
.yt__btn::after { content: ""; position: absolute; left: 29px; top: 15px; border-style: solid; border-width: 10px 0 10px 17px; border-color: transparent transparent transparent #fff; }
.yt__play:hover .yt__btn { transform: scale(1.08); }
.yt__title { position: relative; padding: 14px 16px; font-weight: 700; font-size: .95rem; }
.video-grid { display: grid; gap: 24px; }
.video-grid h3 { margin-bottom: .6em; }
.video-grid .small { margin-top: 10px; }
@media (min-width: 700px) { .video-grid { grid-template-columns: 1fr 1fr; } }

/* ---------- Product page ---------- */
.crumbs { font-size: .88rem; color: var(--muted); padding-top: 20px; display: flex; flex-wrap: wrap; gap: 6px; }
.crumbs a { color: var(--muted); }

.product { display: grid; gap: 28px; padding: 20px 0 40px; }
.product__cover { width: 208px; max-width: 70%; justify-self: center; border-radius: 10px; overflow: hidden; box-shadow: var(--shadow-lg); aspect-ratio: 3 / 4; background: var(--paper-2); border: 4px solid #fff; }
/* Covers are shown at their real size (200px) so they stay sharp. A larger
   image set as 'cover' in inc/magazines.php is shown bigger. */
.product__cover--large { width: 308px; }
.product__cover .cover-img, .product__cover .cover-ph { width: 100%; height: 100%; object-fit: cover; display: block; }
.product__info h1 { margin-bottom: .3em; }
.facts { list-style: none; padding: 0; margin: 18px 0 22px; display: grid; gap: 8px; }
.facts li { position: relative; padding-left: 22px; color: var(--ink-2); }
.facts li::before { content: ""; position: absolute; left: 0; top: .55em; width: 10px; height: 10px; border-radius: 2px; background: var(--c); }
.product__extras { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 14px; }
.product__aside { margin: 16px 0 0; padding: 12px 14px; font-size: .93rem; background: #fff7dd; border: 1px solid #f0dc9a; border-radius: var(--radius-sm); max-width: 480px; }
@media (min-width: 820px) {
  .product { grid-template-columns: auto 1fr; gap: 56px; align-items: start; padding-top: 28px; }
  .product__cover { margin-top: 12px; max-width: none; }
}

/* Buy box */
.buy { background: var(--card); border: 1.5px solid var(--line); border-radius: var(--radius); padding: 18px; max-width: 480px; }
.buy__top { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 14px; }
.buy__price .p b { font: 800 2.2rem/1 var(--f-display); }
.buy__price .p small { font-size: .8rem; font-weight: 700; color: var(--muted); margin-left: 2px; }
.buy__label { margin: 0; font-weight: 700; }
.p s { color: var(--muted); font-weight: 400; margin-right: 2px; }
.buy[data-currency="GBP"] .p--usd, .buy[data-currency="USD"] .p--gbp { display: none; }
.no-js .cur { display: none; }
.cur { display: inline-flex; background: var(--paper-2); border-radius: 999px; padding: 3px; }
.cur button { border: 0; background: none; font: 600 .85rem/1 var(--f-body); padding: 8px 12px; border-radius: 999px; cursor: pointer; color: var(--muted); }
.cur button[aria-pressed="true"] { background: var(--card); color: var(--ink); box-shadow: var(--shadow); }
.buy__offer { background: var(--accent); border-radius: var(--radius-sm); padding: 8px 12px; font-weight: 700; font-size: .9rem; }
.buy__small { font-size: .84rem; color: var(--muted); margin: 12px 0 0; }
.edition { display: flex; align-items: center; gap: 12px; padding: 10px 0; border-top: 1px solid var(--line); }
.edition__img { width: 48px; height: 64px; object-fit: cover; border-radius: 4px; box-shadow: var(--shadow); flex: none; }
.edition__text { flex: 1; display: flex; flex-direction: column; line-height: 1.3; }
.edition__text .p b { font-size: 1.05rem; }
.edition .buy__form { margin: 0; }

/* Article body */
.prose { max-width: 760px !important; padding-top: 28px; border-top: 1px solid var(--line); }
.prose h2 { margin-top: 1.4em; }
.prose > h2:first-of-type { margin-top: 0; }
.prose p, .prose li { color: var(--ink-2); }
.prose ol { padding-left: 1.3em; display: grid; gap: 10px; }
.figure { margin: 0 0 20px; }
.figure img { display: block; border-radius: var(--radius-sm); box-shadow: var(--shadow); background: #fff; }
.figure figcaption { font-size: .82rem; color: var(--muted); margin-top: 6px; }
@media (min-width: 700px) { .figure { float: right; max-width: 42%; margin: 4px 0 20px 32px; } }
.prose h2, .prose .callout, .prose .yt, .prose .video-grid { clear: both; }
.callout { margin: 28px 0; padding: 18px 22px; background: #eaf3f1; border-left: 4px solid var(--green); border-radius: 0 var(--radius-sm) var(--radius-sm) 0; }
.callout p { margin: .4em 0 0; }
.ticks { list-style: none; padding: 0; display: grid; gap: 10px; }
.ticks li { position: relative; padding-left: 30px; }
.ticks li::before { content: ""; position: absolute; left: 0; top: .3em; width: 18px; height: 18px; border-radius: 50%; background: var(--green) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='m6 12 4 4 8-8' fill='none' stroke='white' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 14px no-repeat; }
.shelf--related { padding-bottom: 8px; }

/* ---------- Old (unconverted) pages ---------- */
.legacy-page { max-width: 860px !important; padding-top: clamp(24px, 4vw, 40px); color: var(--ink-2); }
.legacy-page::after { content: ""; display: block; clear: both; }
.legacy-page h1, .legacy-page h2 { color: var(--ink); clear: both; }
.legacy-page h1 { font-size: clamp(1.9rem, 1.3rem + 2.4vw, 2.8rem); }
.legacy-page h2 { margin-top: 1.4em; }
.legacy-page img[align="right"] { display: block; margin: 0 auto 20px; border-radius: var(--radius-sm); box-shadow: var(--shadow); }
@media (min-width: 700px) { .legacy-page img[align="right"] { float: right; max-width: 42%; margin: 4px 0 20px 32px; } }
.legacy-page iframe { display: block; width: 100%; max-width: 100%; height: auto; aspect-ratio: 16 / 9; border-radius: var(--radius); border: 0; margin: 8px 0 16px; }
.legacy-page [style*="width"] { max-width: 100% !important; }
.legacy-page div[style*="background"] { border-radius: var(--radius-sm); padding: 12px 16px !important; margin: 16px 0 !important; }
.legacy-page table { max-width: 100%; border-collapse: collapse; }
.legacy-page td { padding: 6px 8px; }
.legacy-page b, .legacy-page strong { color: var(--ink); }
.tln { margin-bottom: 20px; }
.tln > div { background: #fff7dd !important; border: 1px solid #f0dc9a !important; border-radius: var(--radius-sm); padding: 12px 14px !important; margin: 0 !important; font-size: .95rem; }
.legacy-block { margin-top: 32px; clear: both; }

.buy-panel { display: grid; gap: 20px; align-items: center; margin-top: 36px; padding: clamp(18px, 3vw, 28px); background: var(--paper-2); border-radius: calc(var(--radius) + 4px); clear: both; }
.buy-panel h2 { margin: 0 0 .3em; font-size: 1.5rem; }
.buy-panel__text p { margin: 0; }
.buy-panel__extra img { float: right; max-width: 90px; margin: 0 0 8px 12px; border-radius: 4px; }
@media (min-width: 760px) { .buy-panel { grid-template-columns: 1fr 360px; } }

/* ---------- Footer ---------- */
.site-foot { margin-top: clamp(64px, 10vw, 112px); background: var(--ink); color: rgba(251,248,241,.75); font-size: .95rem; }
.site-foot a { color: var(--paper); text-decoration: none; }
.site-foot a:hover { color: var(--accent); }
.site-foot h2 { font: 700 .78rem/1 var(--f-body); letter-spacing: .12em; text-transform: uppercase; color: var(--accent); margin-bottom: 14px; }
.site-foot ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.site-foot__grid { display: grid; gap: 32px; padding: 48px 0 32px; }
.site-foot__inline { display: flex !important; gap: 18px !important; }
.site-foot__guides ul { grid-template-columns: 1fr 1fr; column-gap: 16px; font-size: .9rem; }
.logo--foot .logo__text { color: var(--paper); font-size: 1.4rem; }
.site-foot__base { border-top: 1px solid rgba(255,255,255,.12); padding: 18px 0 28px; font-size: .85rem; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 6px 20px; }
.site-foot__base p { margin: 0; }
@media (min-width: 760px) { .site-foot__grid { grid-template-columns: 1fr 1fr; } }
@media (min-width: 1040px) { .site-foot__grid { grid-template-columns: 1.2fr .9fr 1.6fr .9fr; } }

/* ---------- Cookie notice ---------- */
.cookie { position: fixed; left: 12px; right: 12px; bottom: 12px; z-index: 60; display: flex; align-items: center; gap: 14px; justify-content: space-between; background: var(--ink); color: var(--paper); padding: 12px 14px 12px 18px; border-radius: var(--radius); box-shadow: var(--shadow-lg); max-width: 560px; margin-inline: auto; font-size: .9rem; }
.cookie[hidden] { display: none; }
.cookie p { margin: 0; }
.cookie a { color: var(--accent); }
.cookie .btn--primary { background: var(--accent); color: var(--ink); border-color: var(--accent); flex: none; }
@media (min-width: 900px) { .shelf--related .grid { grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 16px; } .legacy-page .shelf--related .grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }

/* ---------- Hub pages, guides, forms ---------- */
.page-head { padding: 8px 0 28px; max-width: 760px; }
.page-head h1 { margin-bottom: .3em; }
.crumbs--legacy { padding-top: 0; margin-bottom: 18px; }
.guides { list-style: none; padding: 0; margin: 0 auto 48px; display: grid; gap: 12px; grid-template-columns: repeat(auto-fill, minmax(min(100%, 220px), 1fr)); }
.guide { display: flex; flex-direction: column; gap: 2px; height: 100%; padding: 16px 18px; background: var(--card); border: 1px solid var(--line); border-left: 5px solid var(--c); border-radius: var(--radius-sm); text-decoration: none; color: var(--ink); transition: box-shadow .15s, transform .15s; }
.guide:hover { box-shadow: var(--shadow); transform: translateY(-2px); color: var(--ink); }
.guide__title { font: 700 1.08rem/1.2 var(--f-display); }
.guide__meta { font-size: .82rem; color: var(--muted); }
.prose--spaced { margin-top: 48px; }
.prose--plain { border-top: 0; padding-top: 0; }

.guide-cta { display: flex; gap: 20px; align-items: center; margin: 40px 0 8px; padding: 20px; background: var(--card); border: 1px solid var(--line); border-top: 5px solid var(--c); border-radius: var(--radius); clear: both; }
.guide-cta__cover { flex: none; width: 110px; aspect-ratio: 3 / 4; border-radius: 6px; overflow: hidden; box-shadow: var(--shadow); }
.guide-cta__cover img, .guide-cta__cover .cover-ph { width: 100%; height: 100%; object-fit: cover; display: block; }
.guide-cta h2 { margin: 0 0 .3em; font-size: 1.4rem; }
.guide-cta p:not(.eyebrow) { margin-bottom: .8em; }
@media (max-width: 520px) { .guide-cta { flex-direction: column; align-items: flex-start; } }
.guide-list { margin-top: 36px; clear: both; }
.guide-list h2 { font-size: 1.3rem; }
.chips--wrap { list-style: none; padding: 0; margin: 0; flex-wrap: wrap; overflow: visible; }
.chips--wrap .chip::before { display: none; }

.contact { max-width: 980px !important; }
.contact__grid { display: grid; gap: 28px; align-items: start; }
@media (min-width: 820px) { .contact__grid { grid-template-columns: 1.4fr 1fr; } }
.contact .callout { margin: 0; }
.form { display: grid; gap: 16px; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: clamp(18px, 3vw, 28px); }
.form label { display: grid; gap: 6px; font-weight: 600; font-size: .95rem; }
.form input, .form textarea { font: inherit; font-weight: 400; color: var(--ink); background: var(--paper); border: 1.5px solid var(--line); border-radius: var(--radius-sm); padding: 11px 13px; width: 100%; }
.form input:focus, .form textarea:focus { outline: none; border-color: var(--ink); background: #fff; }
.form .btn { justify-self: start; }
.captcha { font-weight: 400; letter-spacing: .04em; background: var(--paper-2); padding: 1px 6px; border-radius: 4px; }
.notice { padding: 14px 16px; border-radius: var(--radius-sm); }
.notice--ok { background: #eaf3f1; border: 1px solid #b9dad3; }
.notice--error { background: #fdecea; border: 1px solid #f3b8ae; }
.prose img { max-width: 100%; height: auto; }
.site-foot__all { color: var(--accent) !important; font-weight: 700; }
.edition__img--blank { display: block; background: repeating-linear-gradient(45deg, var(--paper-2) 0 6px, #ebe4d4 6px 12px); box-shadow: none; }
.contact > .page-head:first-child { padding-top: clamp(28px, 5vw, 48px); }
@media (min-width: 860px) { .about--single { grid-template-columns: 1fr; } }
.table-wrap { overflow-x: auto; margin: 0 0 1em; }
.info-table { width: 100%; border-collapse: collapse; font-size: .95rem; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius-sm); }
.info-table th, .info-table td { text-align: left; vertical-align: top; padding: 10px 12px; border-bottom: 1px solid var(--line); }
.info-table th { background: var(--paper-2); font-weight: 700; }
.info-table code { font-size: .88em; background: var(--paper-2); padding: 1px 5px; border-radius: 4px; }
