/* The Book Wheel. Palette offwhite-bottle-yellow (bottle-green ink, highlighter yellow), EB Garamond / Jost. */
:root {
  --bg: #f7f7f5; --surface: #ebebe7; --ink: #0d2a1c; --muted: #4f5c55; --line: #d5d8d2;
  --accent: #f6e016; --deep: #0d2a1c; --deep-2: #1c3629; --on-deep: #f7f7f5; --on-deep-muted: #b3beb8;
  --serif: "EB Garamond", Georgia, serif; --sans: "Jost", system-ui, sans-serif;
  --wrap: 1200px; --gut: clamp(16px, 4vw, 40px);
}
* { box-sizing: border-box; }
html { scroll-padding-top: 24px; -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 400 18px/1.6 var(--sans); }
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { background: var(--accent); text-decoration-color: var(--ink); }
:focus-visible { outline: 3px solid var(--ink); outline-offset: 3px; box-shadow: 0 0 0 6px var(--accent); }
h1, h2, h3 { font-family: var(--serif); font-weight: 500; letter-spacing: -0.012em; line-height: 1.1; margin: 0; text-wrap: balance; }
p { margin: 0; }
.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gut); }
.skip { position: absolute; left: -999px; top: 8px; background: var(--accent); color: var(--ink); padding: 10px 14px; z-index: 10; }
.skip:focus { left: 8px; }
.eyebrow { font: 500 13px/1.4 var(--sans); letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.eyebrow a { text-decoration: none; }
.lede { font-size: 20px; line-height: 1.55; color: var(--ink); max-width: 38em; }

/* masthead */
.masthead { border-bottom: 1px solid var(--line); background: var(--bg); }
.masthead .wrap { display: flex; align-items: center; justify-content: space-between; gap: 24px; min-height: 72px; flex-wrap: wrap; }
.brand { display: inline-flex; align-items: center; gap: 10px; font: 500 24px/1 var(--serif); text-decoration: none; }
.mark { width: 32px; height: 32px; }
.nav { display: flex; gap: 6px 22px; flex-wrap: wrap; font-size: 16px; }
.nav a { text-decoration: none; padding: 10px 0; }
.nav a:hover { background: none; text-decoration: underline; text-decoration-color: var(--ink); text-decoration-thickness: 2px; }

/* buttons */
.actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 32px; }
.btn { display: inline-flex; align-items: center; min-height: 48px; padding: 0 22px; font: 500 16px/1 var(--sans); text-decoration: none; border: 1.5px solid var(--ink); transition: transform .15s, background .15s; }
.btn:hover { transform: translateY(-1px); text-decoration: none; }
.btn:active { transform: translateY(1px); }
.btn-solid { background: var(--ink); color: var(--bg); }
.btn-line { background: transparent; color: var(--ink); }
.btn-line:hover { background: var(--surface); }
.btn-accent { background: var(--accent); color: var(--ink); border-color: var(--accent); }

/* hero and the wheel */
.hero { padding: clamp(40px, 6vw, 88px) 0 clamp(24px, 3vw, 48px); }
.hero-grid { display: grid; grid-template-columns: minmax(0, 6fr) minmax(0, 5fr); gap: clamp(32px, 5vw, 72px); align-items: center; }
.hero h1 { font-size: clamp(44px, 4.4vw + 12px, 84px); line-height: 1.02; letter-spacing: -0.018em; max-width: 11ch; }
.textlink { font-weight: 500; text-underline-offset: 5px; align-self: center; padding: 12px 4px; }
.hero .lede { margin-top: 24px; max-width: 30em; }
.wheel { --size: min(470px, 86vw); position: relative; width: var(--size); aspect-ratio: 1; justify-self: center; }
.spine { --w: calc(var(--size) * .072); --hub: calc(var(--size) * .2); --len: calc(var(--size) * .5 - var(--hub) - var(--lift, 0px));
         position: absolute; left: 50%; top: 50%; width: var(--w); height: var(--len); margin-left: calc(var(--w) / -2);
         transform-origin: 50% 0; transform: rotate(calc(var(--i) * 360deg / var(--n) + 180deg)) translateY(calc(var(--hub) + var(--pull, 0px)));
         display: flex; align-items: center; justify-content: center; text-decoration: none; border-radius: 1px 1px 3px 3px;
         transition: transform .25s ease; box-shadow: inset 0 0 0 1px rgba(13, 42, 28, .22); }
.spine:nth-child(3n+1) { --lift: calc(var(--size) * .035); }
.spine:nth-child(4n+2) { --lift: calc(var(--size) * .07); }
.spine:nth-child(5n+3) { --lift: calc(var(--size) * .015); }
.spine span { transform: rotate(calc(-1 * (var(--i) * 360deg / var(--n) + 180deg))); font: 500 max(15px, calc(var(--size) * .046))/1 var(--serif); }
.spine::before, .spine::after { content: ""; position: absolute; left: 20%; right: 20%; height: 2px; background: currentColor; opacity: .5; }
.spine::before { top: 9%; } .spine::after { bottom: 9%; }
a.spine:hover, a.spine:focus-visible { --pull: calc(var(--size) * .035); text-decoration: none; background-color: inherit; }
.spine.blank { background: transparent; box-shadow: inset 0 0 0 1px rgba(13, 42, 28, .16); }
.spine.blank::before, .spine.blank::after { display: none; }
.s1 { background: var(--deep); color: var(--on-deep); }
.s2 { background: var(--accent); color: var(--ink); }
.s3 { background: #fff; color: var(--ink); }
.s4 { background: var(--deep-2); color: var(--on-deep); }
.s5 { background: var(--surface); color: var(--ink); }
.hub { position: absolute; left: 50%; top: 50%; width: calc(var(--size) * .3); aspect-ratio: 1; transform: translate(-50%, -50%);
       border-radius: 50%; background: var(--bg); border: 2px solid var(--ink); display: grid; place-content: center; text-align: center;
       font: 500 13px/1.2 var(--sans); letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.hub b { display: block; font: 500 calc(var(--size) * .1)/1 var(--serif); letter-spacing: 0; text-transform: none; color: var(--ink); }

/* sections */
.section { padding: clamp(48px, 6vw, 88px) 0; }
.section + .section { padding-top: 0; }
.section h2, .more h2 { font-size: clamp(32px, 2vw + 18px, 48px); }
.head-row { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.topics { list-style: none; margin: 32px 0 0; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0; border-top: 2px solid var(--ink); }
.topics li { padding: 22px 22px 8px 0; border-right: 1px solid var(--line); }
.topics li + li { padding-left: 22px; }
.topics li:last-child { border-right: 0; }
.topics h3 { font-size: 28px; }
.topics h3 a { text-decoration: none; }
.topics p { margin-top: 10px; color: var(--muted); font-size: 16px; }
.topics .count { margin-top: 4px; font: 500 14px/1.4 var(--sans); color: var(--ink); }
.topics .latest { margin-top: 14px; font-size: 15px; color: var(--ink); }
.cards { list-style: none; margin: 32px 0 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr)); gap: 40px 28px; }
.no { color: var(--ink); font-weight: 600; }
.card .thumb { display: block; overflow: hidden; margin-bottom: 16px; background: var(--surface); }
.card .thumb img { aspect-ratio: 16 / 9; object-fit: cover; transition: transform .3s; }
.card:hover .thumb img { transform: scale(1.025); }
.card h3 { margin-top: 8px; font-size: 26px; line-height: 1.15; }
.card h3 a { text-decoration: none; }
.card h3 a:hover { text-decoration: underline; text-decoration-color: var(--accent); text-decoration-thickness: 3px; }
.rows { list-style: none; margin: 0; padding: 0; }
.rows li { padding: 14px 0; border-top: 1px solid var(--line); display: flex; justify-content: space-between; gap: 16px; align-items: baseline; }
.rows li a { font: 500 22px/1.25 var(--serif); text-decoration: none; }
.rows li .eyebrow { white-space: nowrap; text-transform: none; letter-spacing: 0; font-size: 14px; }
.band { background: var(--deep); color: var(--on-deep); padding: clamp(56px, 7vw, 104px) 0; }
.band-grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: clamp(32px, 5vw, 80px); align-items: start; }
.band h2 { margin-top: 10px; font-size: clamp(34px, 2.4vw + 18px, 56px); }
.band p:not(.eyebrow) { margin-top: 16px; color: var(--on-deep-muted); max-width: 32em; }
.band .eyebrow { color: var(--accent); }
.band .btn { margin-top: 28px; }
.band .rows li { border-color: rgba(247, 247, 245, .18); }
.band .rows .eyebrow { color: var(--on-deep-muted); }

/* pages */
.crumbs { font-size: 15px; color: var(--muted); padding-top: 28px; }
.section > .wrap > .crumbs:first-child { padding-top: 0; }
.crumbs a { color: var(--muted); }
.section:has(> .wrap > .crumbs:first-child) { padding-top: 32px; }
.page-title { margin-top: 18px; font-size: clamp(40px, 3vw + 18px, 64px); }
.section .lede { margin-top: 14px; }
.empty { margin-top: 28px; }
.groups { display: grid; gap: 48px; margin-top: 32px; }
.group h2 a { text-decoration: none; }
.group .rows { margin-top: 14px; }

/* article */
.article-head { padding-bottom: 28px; }
.article-head .eyebrow { margin-top: 28px; }
.article-head h1 { margin-top: 10px; font-size: clamp(40px, 3.2vw + 16px, 68px); max-width: 18ch; }
.article-head .lede { margin-top: 18px; }
.meta { margin-top: 18px; font-size: 15px; color: var(--muted); }
.hero-img img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; }
.col { max-width: calc(760px + 2 * var(--gut)); }
.prose { max-width: calc(760px + 2 * var(--gut)); padding-top: 40px; padding-bottom: 64px; font: 400 21px/1.6 var(--serif); }
.prose > * + * { margin-top: 1em; }
.prose h2 { margin-top: 1.8em; font-size: clamp(27px, 1.3vw + 20px, 34px); line-height: 1.15; }
.prose h3 { margin-top: 1.5em; font-size: 26px; }
.prose ul, .prose ol { padding-left: 1.2em; }
.prose li + li { margin-top: .4em; }
.prose blockquote { margin: 1.5em 0; padding: 4px 0 4px 22px; border-left: 4px solid var(--accent); font-style: italic; }
.prose figure { margin: 2em 0; }
.prose a { text-decoration-color: color-mix(in srgb, var(--ink) 45%, transparent); }
.more { background: var(--surface); padding: clamp(48px, 6vw, 80px) 0; }

/* footer */
.footer { border-top: 2px solid var(--ink); padding: 48px 0 40px; }
.footer .wrap { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 24px 40px; align-items: start; }
.footer p { margin-top: 10px; color: var(--muted); font-size: 16px; }
.footer nav { display: flex; flex-wrap: wrap; gap: 8px 24px; font-size: 16px; }
.footer nav a { padding: 8px 0; }
.footer .legal { grid-column: 1 / -1; font-size: 14px; }

@media (max-width: 1023px) {
  .hero-grid, .band-grid { grid-template-columns: minmax(0, 1fr); }
  .topics { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .topics li:nth-child(2) { border-right: 0; }
  .topics li:nth-child(3) { padding-left: 0; }
  .cards { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 639px) {
  body { font-size: 17px; }
  .masthead .wrap { padding-block: 8px; gap: 2px 16px; min-height: 0; }
  .brand { font-size: 21px; }
  .nav { gap: 0 14px; font-size: 15px; }
  .nav a { padding: 8px 0; }
  .topics, .cards { grid-template-columns: minmax(0, 1fr); }
  .topics li, .topics li + li { padding: 20px 0 8px; border-right: 0; border-bottom: 1px solid var(--line); }
  .rows li { flex-direction: column; gap: 4px; }
  .prose { font-size: 19px; }
  .footer .wrap { grid-template-columns: minmax(0, 1fr); }
  .actions .btn { width: 100%; justify-content: center; }
  .hero .lede { font-size: 18px; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }
