/* High Tide Publishing House — colours sampled from the logo */
:root {
  --paper: #F7F8F3;
  --paper-2: #EEF1EA;
  --blue: #004AAD;
  --blue-deep: #0B3B85;
  --blue-bg: #184F9A; /* background of the blue logo */
  --blue-ink: #0A2A5E;
  --blush: #FFE4E4;
  --sand: #F1E6D2;
  --ink: #16233B;
  --muted: #5A6578;
  --line: rgba(0, 74, 173, .18);
  --radius: 14px;
  --shadow: 0 1px 2px rgba(10, 42, 94, .06), 0 12px 32px -12px rgba(10, 42, 94, .22);
  --serif: "Fraunces", Georgia, serif;
  --sans: "Jost", system-ui, -apple-system, sans-serif;
  --wave-front: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='360' height='44' viewBox='0 0 360 44' preserveAspectRatio='none'%3E%3Cpath d='M0 22 C60 6 120 6 180 22 S300 38 360 22 V44 H0Z' fill='%23F7F8F3' fill-opacity='1'/%3E%3C/svg%3E");
  --wave-back: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='480' height='44' viewBox='0 0 480 44' preserveAspectRatio='none'%3E%3Cpath d='M0 16 C80 0 160 0 240 16 S400 32 480 16 V44 H0Z' fill='%23F7F8F3' fill-opacity='0.45'/%3E%3C/svg%3E");
  --wave-front-blue: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='360' height='44' viewBox='0 0 360 44' preserveAspectRatio='none'%3E%3Cpath d='M0 22 C60 6 120 6 180 22 S300 38 360 22 V44 H0Z' fill='%23184F9A' fill-opacity='1'/%3E%3C/svg%3E");
  --wave-back-blue: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='480' height='44' viewBox='0 0 480 44' preserveAspectRatio='none'%3E%3Cpath d='M0 16 C80 0 160 0 240 16 S400 32 480 16 V44 H0Z' fill='%23184F9A' fill-opacity='0.45'/%3E%3C/svg%3E");
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 400 17px/1.65 var(--sans);
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--blue); text-underline-offset: 3px; }
a:hover { color: var(--blue-deep); }
h1, h2, h3 { font-family: var(--serif); font-weight: 400; color: var(--blue-ink); line-height: 1.12; margin: 0 0 .4em; letter-spacing: -.01em; }
h1 { font-size: clamp(2.3rem, 5vw, 3.8rem); }
h2 { font-size: clamp(1.8rem, 3.4vw, 2.6rem); }
h3, .h3 { font-size: 1.35rem; }
h1 em, h2 em { font-style: italic; color: inherit; }
p { margin: 0 0 1em; }
:focus-visible { outline: 2px solid var(--blue); outline-offset: 3px; border-radius: 4px; }

.wrap { width: min(1160px, 100% - 32px); margin-inline: auto; }
.narrow { width: min(760px, 100% - 32px); }
.center { text-align: center; }
.muted { color: var(--muted); }
.lede { font-size: 1.18rem; color: var(--muted); }
.eyebrow { font: 500 .78rem/1.3 var(--sans); letter-spacing: .16em; text-transform: uppercase; color: var(--blue); margin: 0 0 .7em; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--blue); color: #fff; padding: 8px 14px; border-radius: 6px; z-index: 100; }
.skip:focus { left: 8px; }
.hp { position: absolute; left: -9999px; }

/* Header */
.site-header { position: sticky; top: 0; z-index: 50; background: rgba(247, 248, 243, .92); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); }
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 84px; }
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; color: var(--blue); }
.brand img { height: 62px; width: auto; }
.site-nav { display: flex; gap: 6px; }
.site-nav a { text-decoration: none; color: var(--ink); font-weight: 500; padding: 8px 14px; border-radius: 999px; }
.site-nav a:hover { background: var(--paper-2); color: var(--blue); }
.site-nav a[aria-current="page"] { color: var(--blue); background: var(--paper-2); }
.nav-toggle { display: none; background: none; border: 0; color: var(--blue); padding: 8px; cursor: pointer; }
.nav-toggle svg { width: 26px; height: 26px; }

/* Buttons */
.btn { display: inline-flex; align-items: center; gap: 8px; padding: 12px 20px; border-radius: 999px; font: 500 .95rem/1.2 var(--sans); text-decoration: none; border: 1.5px solid transparent; cursor: pointer; transition: transform .15s, background .15s, color .15s; }
.btn svg { width: 16px; height: 16px; }
.btn:hover { transform: translateY(-1px); }
.btn-primary { background: var(--blue); color: #fff; }
.btn-primary:hover { background: var(--blue-deep); color: #fff; }
.btn-ghost { border-color: var(--line); color: var(--blue); background: transparent; }
.btn-ghost:hover { border-color: var(--blue); }
.btn-light { background: var(--paper); color: var(--blue); }
.btn-light:hover { background: #fff; color: var(--blue-deep); }
.btn-outline-light { border-color: rgba(255, 255, 255, .55); color: #fff; }
.btn-outline-light:hover { border-color: #fff; color: #fff; }
.text-link { display: inline-flex; align-items: center; gap: 6px; font-weight: 500; text-decoration: none; }
.text-link svg { width: 15px; height: 15px; transition: transform .15s; }
.text-link:hover svg { transform: translateX(3px); }
.badge { display: inline-block; padding: 6px 12px; border-radius: 999px; background: var(--blush); color: var(--blue-ink); font-size: .82rem; font-weight: 500; white-space: nowrap; }

/* Waves */
.wave { position: relative; height: 44px; margin-bottom: -1px;
  background-image: var(--wave-front), var(--wave-back);
  background-repeat: repeat-x; background-position: 0 bottom, 120px bottom;
  background-size: 360px 44px, 480px 44px;
  animation: wave-drift 18s linear infinite; }
.wave-footer { background-image: var(--wave-front-blue), var(--wave-back-blue); background-color: var(--paper); margin: 0 0 -1px; }
@keyframes wave-drift { to { background-position: -360px bottom, 600px bottom; } }

/* Hero */
.hero { position: relative; overflow: hidden; background: var(--blue-bg); color: #fff; }
.hero-photo { position: absolute; inset: 0 0 0 auto; width: 62%;
  background: url("https://images.unsplash.com/photo-1790704982561-3b56bb6e65f2?w=1600&q=80&auto=format&fit=crop") 50% 62% / cover no-repeat; }
.hero-photo::after { content: ""; position: absolute; inset: 0;
  background: linear-gradient(90deg, var(--blue-bg) 0%, rgba(24, 79, 154, .82) 22%, rgba(24, 79, 154, .35) 60%, rgba(24, 79, 154, .12) 100%); }
.hero-photo { -webkit-mask-image: linear-gradient(90deg, transparent, #000 30%); mask-image: linear-gradient(90deg, transparent, #000 30%); }
.hero-about .hero-photo { -webkit-mask-image: none; mask-image: none; }
.hero-inner, .hero .wave { position: relative; z-index: 1; }
.hero-inner { padding: clamp(64px, 10vw, 136px) 0 clamp(56px, 8vw, 104px); }
.hero-copy { max-width: 600px; }
.hero h1 { color: #fff; }
.hero .eyebrow { color: var(--blush); }
.hero .lede { color: rgba(255, 255, 255, .85); max-width: 34em; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }

/* About hero: full-width photo, text over a blue fade */
.hero-about .hero-photo { width: 100%;
  background-image: url("https://images.unsplash.com/photo-1788410965876-0f31eb5023e0?w=2000&q=80&auto=format&fit=crop");
  background-position: 50% 65%; transform: scaleX(-1); }
.hero-about .hero-photo::after {
  background: linear-gradient(270deg, rgba(24, 79, 154, .96) 0%, rgba(24, 79, 154, .8) 38%, rgba(24, 79, 154, .3) 72%, rgba(24, 79, 154, .15) 100%); }
.hero-about .hero-copy { max-width: 680px; }

.hero-contact .hero-photo {
  background-image: url("https://images.unsplash.com/photo-1636333798006-993a9f2611e3?w=1600&q=80&auto=format&fit=crop");
  background-position: 55% 60%; }
.hero-contact .hero-copy { max-width: 520px; }

/* Sections */
.section { padding: clamp(56px, 8vw, 96px) 0; }
.section-tint { background: var(--paper-2); }
.section-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 24px; flex-wrap: wrap; margin-bottom: 24px; }
.section-head .muted { margin: 0; max-width: 28em; }
.page-hero { padding: clamp(48px, 7vw, 80px) 0 0; }

/* Filter chips */
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 36px; }
.chip { font: 500 .88rem/1 var(--sans); padding: 9px 16px; border-radius: 999px; border: 1.5px solid var(--line); background: transparent; color: var(--ink); cursor: pointer; }
.chip:hover { border-color: var(--blue); color: var(--blue); }
.chip.is-active { background: var(--blue); border-color: var(--blue); color: #fff; }

/* Book grid */
.book-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 44px 32px; }
.book-card { display: flex; flex-direction: column; }
.book-card[hidden] { display: none; }
.book-card-link { display: block; margin-bottom: 18px; }
.book-card-link .cover { transition: transform .25s, box-shadow .25s; }
.book-card-link:hover .cover { transform: translateY(-4px) rotate(-.6deg); box-shadow: 0 2px 4px rgba(10, 42, 94, .08), 0 22px 40px -14px rgba(10, 42, 94, .35); }
.book-card h3 { margin-bottom: .15em; }
.book-card h3 a { color: inherit; text-decoration: none; }
.book-card h3 a:hover { color: var(--blue); }
.book-author { color: var(--muted); font-size: .95rem; margin-bottom: .6em; }
.book-blurb { font-size: .96rem; flex: 1; }
.book-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 16px; margin: 6px 0 4px; }

/* Placeholder covers */
.cover { position: relative; aspect-ratio: 2 / 3; border-radius: 4px 10px 10px 4px; box-shadow: var(--shadow); overflow: hidden; background: var(--blue); color: #fff; container-type: inline-size; }
.cover::after { content: ""; position: absolute; inset: 0 auto 0 0; width: 6%; background: linear-gradient(90deg, rgba(0,0,0,.18), rgba(255,255,255,.08) 60%, transparent); }
.cover.has-image img { width: 100%; height: 100%; object-fit: cover; }
.cover-frame { position: absolute; inset: 7%; border: 1.5px solid currentColor; border-radius: 6px; display: flex; flex-direction: column; justify-content: center; align-items: center; text-align: center; padding: 10%; gap: 6cqi; opacity: .98; }
.cover-title { font: 400 11cqi/1.05 var(--serif); }
.cover-sub { font: italic 400 5cqi/1.3 var(--serif); opacity: .85; }
.cover-author { position: absolute; bottom: 8%; font: 500 4.2cqi/1 var(--sans); letter-spacing: .18em; text-transform: uppercase; }
.cover-series { position: absolute; top: 8%; font: 500 3.8cqi/1 var(--sans); letter-spacing: .18em; text-transform: uppercase; opacity: .85; }
.cover-blue { background: var(--blue); color: #fff; }
.cover-deep { background: var(--blue-ink); color: var(--blush); }
.cover-sand { background: var(--sand); color: var(--blue); }
.cover-blush { background: var(--blush); color: var(--blue); }
.cover-outline { background: #fff; color: var(--blue); }
.cover-sm { width: 100%; }
.cover-md { width: 150px; flex-shrink: 0; }
.cover-lg { width: 100%; max-width: 380px; }

/* Book detail */
.back-link { display: inline-block; margin-bottom: 28px; text-decoration: none; font-weight: 500; }
.book-layout { display: grid; grid-template-columns: minmax(240px, 380px) 1fr; gap: clamp(32px, 6vw, 72px); align-items: start; }
.book-cover-col { position: sticky; top: 100px; }
.book-subtitle { font: italic 400 1.3rem/1.4 var(--serif); color: var(--muted); margin-bottom: .3em; }
.book-info .book-actions { margin: 20px 0 32px; }
.prose p { max-width: 40em; }
.book-meta { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 18px; padding: 24px 0; margin: 28px 0; border-block: 1px solid var(--line); }
.book-meta dt { font: 500 .74rem/1.3 var(--sans); letter-spacing: .14em; text-transform: uppercase; color: var(--muted); }
.book-meta dd { margin: 4px 0 0; }
.inline-list { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 4px 10px; }
.inline-list li:not(:last-child)::after { content: "·"; margin-left: 10px; color: var(--muted); }
.note { background: var(--blush); border-radius: var(--radius); padding: 20px 24px; color: var(--blue-ink); }
.note strong { display: block; font-family: var(--serif); font-weight: 400; font-size: 1.15rem; margin-bottom: 4px; }
.note .book-actions { margin-top: 14px; }
.more-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 190px)); gap: 28px; margin-top: 20px; }
.mini-book { text-decoration: none; color: var(--ink); font-family: var(--serif); font-size: 1.05rem; display: grid; gap: 12px; }
.mini-book:hover { color: var(--blue); }

/* Reader callout */
.reader-callout { display: flex; align-items: center; justify-content: space-between; gap: 32px; flex-wrap: wrap; }
.reader-callout > div { max-width: 40em; }
.reader-callout p:last-child { margin: 0; }

/* Resources */
.resource-hero { background: var(--blue-bg); color: #fff; }
.resource-hero-inner { display: flex; gap: 36px; align-items: center; padding: clamp(40px, 6vw, 72px) 0; }
.resource-hero h1 { color: #fff; }
.resource-hero .eyebrow { color: var(--blush); }
.resource-hero .lede { color: rgba(255, 255, 255, .85); margin: 0; max-width: 32em; }
.resource-hero .cover { border: 1px solid rgba(255,255,255,.25); }
.resource-list { list-style: none; padding: 0; margin: 0 0 40px; display: grid; gap: 16px; }
.resource { display: grid; grid-template-columns: auto 1fr auto; gap: 20px; align-items: center; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 22px 24px; }
.resource-icon { width: 52px; height: 52px; border-radius: 50%; background: var(--paper-2); color: var(--blue); display: grid; place-items: center; }
.resource-icon svg { width: 24px; height: 24px; }
.resource h3 { margin: 0 0 .2em; }
.resource p { margin: 0; color: var(--muted); font-size: .95rem; }
.resource .eyebrow { margin-bottom: .35em; }

/* Form */
.form { display: grid; gap: 18px; margin: 32px 0; }
.form label { display: grid; gap: 6px; font-weight: 500; font-size: .95rem; }
.form input, .form textarea { font: inherit; padding: 13px 15px; border: 1.5px solid var(--line); border-radius: 10px; background: #fff; color: var(--ink); }
.form input:focus, .form textarea:focus { outline: none; border-color: var(--blue); box-shadow: 0 0 0 3px rgba(0, 74, 173, .14); }
.form .btn { justify-self: start; }
.form-status { margin: 0; min-height: 1.4em; color: var(--blue); }

/* Footer */
.site-footer { background: var(--blue-bg); color: rgba(255, 255, 255, .85); margin-top: 0; }
.footer-inner { display: flex; gap: 48px; align-items: center; padding: 48px 0 56px; flex-wrap: wrap; }
.footer-mark { width: 110px; }
.footer-cols { display: grid; gap: 12px; }
.footer-nav { display: flex; gap: 24px; flex-wrap: wrap; }
.site-footer a { color: #fff; text-decoration: none; }
.site-footer a:hover { text-decoration: underline; color: #fff; }
.site-footer p { margin: 0; }
.fine { font-size: .82rem; color: rgba(255, 255, 255, .65); }
main:has(> .section-tint:last-child) + .site-footer .wave-footer { background-color: var(--paper-2); }

/* Responsive */
@media (max-width: 860px) {
  .hero-photo { width: 100%; background-position: 78% 70%; -webkit-mask-image: none; mask-image: none; }
  .hero-photo::after { background: linear-gradient(180deg, rgba(24, 79, 154, .55) 0%, rgba(24, 79, 154, .8) 55%, var(--blue-bg) 100%); }
  .hero-about .hero-photo::after { background: rgba(24, 79, 154, .82); }
  .book-layout { grid-template-columns: 1fr; }
  .book-cover-col { position: static; max-width: 300px; }
}
@media (max-width: 720px) {
  body { font-size: 16px; }
  .nav-toggle { display: block; }
  .brand img { height: 50px; }
  .site-nav { display: none; position: absolute; top: 100%; left: 0; right: 0; flex-direction: column; background: var(--paper); border-bottom: 1px solid var(--line); padding: 8px 16px 16px; }
  .site-nav.is-open { display: flex; }
  .book-grid { grid-template-columns: repeat(2, 1fr); gap: 32px 16px; }
  .book-blurb { display: none; }
  .book-card .btn { padding: 10px 14px; font-size: .85rem; }
  .resource-hero-inner { flex-direction: column; align-items: flex-start; gap: 24px; }
  .cover-md { width: 110px; }
  .resource { grid-template-columns: auto 1fr; padding: 18px; }
  .resource-action { grid-column: 1 / -1; }
}
@media (prefers-reduced-motion: reduce) {
  .wave { animation: none; }
  * { transition: none !important; scroll-behavior: auto !important; }
}

/* About */
.page-hero .lede { margin-top: 12px; }
.about-split { display: grid; grid-template-columns: .8fr 1.2fr; gap: clamp(32px, 6vw, 80px); align-items: start; }
.card-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; margin-top: 12px; }
.card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 28px 26px; }
.card h3 { margin: 18px 0 .4em; }
.card p { margin: 0; color: var(--muted); font-size: .96rem; }
.card-icon { width: 52px; height: 52px; border-radius: 50%; background: var(--blush); color: var(--blue); display: grid; place-items: center; }
.card-icon svg { width: 24px; height: 24px; }
.steps { list-style: none; padding: 0; margin: 12px 0 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 32px; }
.steps li { border-top: 2px solid var(--blue); padding-top: 20px; }
.step-num { font: italic 400 2.2rem/1 var(--serif); color: var(--blue); display: block; margin-bottom: 14px; }
.steps h3 { margin-bottom: .35em; }
.steps p { margin: 0; color: var(--muted); font-size: .96rem; }
.values { display: grid; grid-template-columns: .8fr 1.2fr; gap: clamp(32px, 6vw, 80px); }
.values-list { margin: 0; display: grid; gap: 24px; }
.values-list div { padding-bottom: 24px; border-bottom: 1px solid var(--line); }
.values-list div:last-child { border-bottom: 0; padding-bottom: 0; }
.values-list dt { font: 400 1.3rem/1.3 var(--serif); color: var(--blue-ink); margin-bottom: 4px; }
.values-list dd { margin: 0; color: var(--muted); }
.cta-band { padding: clamp(56px, 8vw, 96px) 0; }
.cta-inner { display: flex; justify-content: space-between; align-items: center; gap: 32px; flex-wrap: wrap;
  background: var(--blush); border-radius: 24px; padding: clamp(32px, 5vw, 56px); }
.cta-inner > div:first-child { max-width: 36em; }
.cta-band p { color: var(--blue-ink); margin: 0; }
.cta-band .eyebrow { margin-bottom: .7em; }
.cta-actions { display: flex; gap: 12px; flex-wrap: wrap; }
.form select { font: inherit; padding: 13px 15px; border: 1.5px solid var(--line); border-radius: 10px; background: #fff; color: var(--ink); }
.publish-fields { display: grid; gap: 18px; padding: 20px; background: var(--paper-2); border-radius: var(--radius); }
.publish-fields[hidden], .form label[hidden] { display: none; }
@media (max-width: 1060px) { .card-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .card-grid { grid-template-columns: 1fr; } }
@media (max-width: 860px) {
  .about-split, .values { grid-template-columns: 1fr; gap: 16px; }
}

/* Title pages */
.cover.has-image { aspect-ratio: auto; background: none; }
.cover.has-image::after { display: none; }
.cover.has-image img { height: auto; object-fit: initial; }
.book-grid { align-items: start; }
.btn-disabled { background: var(--paper-2); color: var(--muted); cursor: default; }
.btn-disabled:hover { transform: none; }
.crumbs { font-size: .9rem; color: var(--muted); margin-bottom: 28px; }
.crumbs a { color: var(--muted); }
.title-page { padding-top: clamp(28px, 4vw, 48px); }
.title-hero { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: clamp(32px, 5vw, 64px); align-items: start; }
.title-cover { background: var(--paper-2); border-radius: var(--radius); padding: clamp(18px, 3vw, 32px); }
.title-cover .cover { max-width: 100%; margin-inline: auto; box-shadow: 0 18px 40px rgba(16, 36, 58, .28); border-radius: 4px; }
.eyebrow-accent { color: #D9534F; }
.title-h1 { font-size: clamp(2rem, 4.2vw, 3.1rem); text-wrap: balance; }
.buy-row { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 18px; margin: 22px 0 10px; }
.price { font: 400 1.9rem/1 var(--serif); color: var(--blue-ink); }
.price small { font: 400 .82rem var(--sans); color: var(--muted); margin-left: 4px; }
.price-extra { font-size: .92rem; color: var(--muted); margin: 0 0 8px; }
.points { list-style: none; padding: 0; margin: 24px 0 0; display: grid; gap: 14px; }
.points li { display: grid; grid-template-columns: 20px 1fr; gap: 10px; }
.points li::before { content: ""; width: 10px; height: 10px; border-radius: 50%; background: var(--blue); margin-top: 8px; }
.points b { display: block; font-weight: 600; color: var(--blue-ink); }
.points span { color: var(--muted); font-size: .96rem; }
.title-section { margin-top: clamp(56px, 7vw, 88px); }
.title-section > h2 { margin-bottom: .25em; }
.title-section .lead { color: var(--muted); max-width: 46em; margin-bottom: 24px; }
.gallery { display: grid; gap: 20px; }
.gallery figure { margin: 0; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.gallery img { width: 100%; }
.gallery figcaption { padding: 12px 16px 16px; font-size: .9rem; color: var(--muted); }
.gallery-mixed { grid-template-columns: repeat(6, minmax(0, 1fr)); }
.gallery-mixed .g-wide { grid-column: span 6; }
.gallery-mixed .g-third { grid-column: span 2; }
.gallery-mixed .g-half { grid-column: span 3; }
.gallery-four { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.chapters { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 40px; counter-reset: ch; }
.chapters li { display: grid; grid-template-columns: 40px 1fr; gap: 8px; padding: 14px 0; border-top: 1px solid var(--line); }
.chapters li::before { counter-increment: ch; content: counter(ch); font: italic 400 1.35rem/1.3 var(--serif); color: var(--blue); }
.chapters b { display: block; font-weight: 600; color: var(--blue-ink); }
.chapters span { color: var(--muted); font-size: .95rem; }
.freebie { display: grid; grid-template-columns: minmax(0, 6fr) minmax(0, 5fr); gap: 40px; align-items: center; background: var(--blush); border-radius: 24px; padding: clamp(24px, 4vw, 44px); }
.freebie p { color: var(--blue-ink); }
.freebie-pages { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.freebie-pages img { border-radius: 4px; box-shadow: 0 10px 24px rgba(16, 36, 58, .18); }
.title-cols { display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 2fr); gap: clamp(32px, 5vw, 56px); align-items: start; }
.title-desc ul { padding-left: 20px; }
.title-desc li { margin-bottom: 4px; }
.title-desc h3 { margin-top: 1.4em; }
.toc { columns: 2; column-gap: 32px; padding-left: 20px; font-size: .96rem; }
.toc li { break-inside: avoid; }
.specs { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 22px 24px; }
.specs h3 { font: 500 .78rem/1.3 var(--sans); letter-spacing: .14em; text-transform: uppercase; color: var(--muted); margin-bottom: 12px; }
.specs dl { display: grid; grid-template-columns: auto 1fr; gap: 8px 16px; margin: 0; font-size: .95rem; }
.specs dt { color: var(--muted); }
.specs dd { margin: 0; }
.specs-note { font-size: .82rem; color: var(--muted); margin: 16px 0 0; }
.title-cta { display: flex; justify-content: space-between; align-items: center; gap: 24px; flex-wrap: wrap; background: var(--sand); border-radius: 24px; padding: clamp(24px, 4vw, 40px); }
.title-cta > div { max-width: 40em; }
.title-cta h2 { font-size: 1.6rem; }
.title-cta p { margin: 0; color: var(--blue-ink); }

/* Resources pages */
.resource-edition { color: rgba(255, 255, 255, .8); font-family: var(--serif); font-style: italic; margin: -4px 0 10px; }
.resource-hero-inner > a { flex-shrink: 0; }
.resource-feature { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: 32px; align-items: start; background: #fff; border: 1px solid var(--line); border-radius: 20px; padding: clamp(20px, 4vw, 36px); }
.resource-feature h2 { font-size: 1.7rem; }
.resource-feature h4 { font: 500 .78rem/1.3 var(--sans); letter-spacing: .14em; text-transform: uppercase; color: var(--blue); margin: 22px 0 8px; }
.resource-feature ul { padding-left: 20px; margin: 0; }
.resource-meta { font-size: .88rem; color: var(--muted); margin: 10px 0 0; }
.resource-block { margin-top: 56px; }
.resource-about { display: grid; grid-template-columns: 150px 1fr; gap: 28px; align-items: start; }
.resource-about ul { padding-left: 20px; }
.companions { list-style: none; padding: 0; margin: 16px 0 0; display: grid; gap: 14px; }
.companions li { padding: 16px 20px; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); }
.companions b a { color: var(--blue-ink); }
.support { margin-top: 56px; }
.support p { margin: 0 0 10px; }
.support dl { display: grid; grid-template-columns: auto 1fr; gap: 6px 16px; margin: 0; }
.support dt { font-weight: 600; }
.support dd { margin: 0; }
.fine-print { font-size: .85rem; margin-top: 40px; }

@media (max-width: 860px) {
  .title-hero, .title-cols, .freebie, .resource-feature { grid-template-columns: 1fr; gap: 28px; }
  .title-cover { max-width: 380px; }
  .chapters { grid-template-columns: 1fr; }
  .gallery-four { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .gallery-mixed .g-third, .gallery-mixed .g-half { grid-column: span 6; }
  .toc { columns: 1; }
  .resource-about { grid-template-columns: 1fr; }
  .resource-about .cover { width: 120px; }
}
/* Catalogue: covers of different proportions stand on a common shelf line */
.book-card-link .cover.has-image, .mini-book .cover.has-image { aspect-ratio: 5 / 8; display: flex; align-items: flex-end; justify-content: center; box-shadow: none; border-radius: 0; overflow: visible; }
.book-card-link .cover.has-image img, .mini-book .cover.has-image img { width: 100%; max-height: 100%; object-fit: contain; object-position: bottom; border-radius: 3px; box-shadow: var(--shadow); }
.book-card-link:hover .cover.has-image { box-shadow: none; }
