@font-face { font-family: 'Atkinson Hyperlegible'; src: url(/fonts/atkinson-hyperlegible-latin-400-normal.woff2) format('woff2'); font-weight: 400; font-display: swap; }
@font-face { font-family: 'Atkinson Hyperlegible'; src: url(/fonts/atkinson-hyperlegible-latin-700-normal.woff2) format('woff2'); font-weight: 700; font-display: swap; }
@font-face { font-family: 'Bricolage Grotesque'; src: url(/fonts/bricolage-grotesque-latin-700-normal.woff2) format('woff2'); font-weight: 700; font-display: swap; }
@font-face { font-family: 'Bricolage Grotesque'; src: url(/fonts/bricolage-grotesque-latin-800-normal.woff2) format('woff2'); font-weight: 800; font-display: swap; }
/* Bento: flat white tiles on a sage-grey ground, one cobalt tile holds the size to buy, butter marks where you are. */
:root {
  --ground: #e9ede6; --tile: #fff; --line: #d6ddd3; --ink: #16201a; --soft: #48544c;
  --cobalt: #2541c4; --cobalt-deep: #1b3299; --butter: #f4d35e; --butter-soft: #fbf1c7; --moss: #33403a;
  --sans: 'Atkinson Hyperlegible', system-ui, sans-serif; --display: 'Bricolage Grotesque', 'Atkinson Hyperlegible', sans-serif;
  --r: 24px; --r-sm: 14px; --gap: clamp(10px, 1.4vw, 16px); --gut: clamp(12px, 3vw, 32px);
  color-scheme: light;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scrollbar-color: #b9c3b5 var(--ground); }
body { margin: 0; background: var(--ground); color: var(--ink); font: 400 1.1875rem/1.6 var(--sans); }
::selection { background: var(--butter); color: var(--ink); }
a { color: var(--cobalt-deep); text-decoration-thickness: 2px; text-underline-offset: 3px; }
a:hover { color: var(--ink); text-decoration-color: var(--cobalt); }
:focus-visible { outline: 3px solid var(--cobalt); outline-offset: 3px; border-radius: 8px; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--tile); padding: 10px 14px; border-radius: var(--r-sm); z-index: 9; }
.skip:focus { left: 8px; }
h1, h2, h3 { font-family: var(--display); font-weight: 700; line-height: 1.12; letter-spacing: -0.015em; text-wrap: balance; }
h2 { font-size: 1.4rem; margin: 0 0 .6em; }
p, li { text-wrap: pretty; }

/* header: wordmark and pill tabs */
.tin { padding: 14px 0 0; }
.tin-in { max-width: 1180px; margin: 0 auto; padding: 0 var(--gut); display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 24px; }
.logo { display: flex; align-items: center; gap: 10px; color: var(--ink); text-decoration: none; font: 800 1.3rem var(--display); letter-spacing: -0.02em; min-height: 48px; }
.logo:hover { color: var(--ink); }
.tabs { display: flex; gap: 4px; background: var(--tile); padding: 5px; border-radius: 999px; }
.tabs a { display: flex; align-items: center; justify-content: center; min-height: 46px; padding: 0 20px; border-radius: 999px; color: var(--ink); text-decoration: none; font-weight: 700; }
.tabs a:hover { background: var(--butter-soft); color: var(--ink); }
.tabs a[aria-current] { background: var(--ink); color: #fff; box-shadow: inset 0 -4px 0 var(--butter); }

main { max-width: 1180px; margin: 0 auto; padding: 14px var(--gut) 48px; }
.crumbs { font-size: 1rem; margin: 4px 4px 12px; color: var(--soft); }
.crumbs a { color: var(--soft); }

/* the board */
.bento { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: var(--gap); }
.tile, .card { background: var(--tile); border-radius: var(--r); padding: clamp(18px, 2.4vw, 32px); min-width: 0; margin: 0; }
.bento > * { grid-column: span 6; }
.bento > .t-q { grid-column: span 4; }
.bento > .t-size { grid-column: span 2; }
.bento > .t-plan { grid-column: span 4; }
.bento > .t-side { grid-column: span 2; }
.bento > .t-shop, .bento > .t-shop + .t-src { grid-column: span 3; }
.bento > .t-full { grid-column: span 6; }
.t-q h1, .card h1 { font-size: clamp(2rem, 1.3rem + 2.4vw, 3.25rem); font-weight: 800; letter-spacing: -0.025em; margin: 0 0 16px; }
.answer { font-size: 1.3rem; line-height: 1.5; margin: 0; max-width: 62ch; }
.answer .cite, .method .cite { white-space: nowrap; }

/* the size to buy: the one cobalt tile on the page */
.t-size { background: var(--cobalt); color: #fff; display: flex; align-items: flex-end; }
.t-size, .home > .t-q { padding: 40px; } /* room for the oversized type */
.t-size p { margin: 0; display: flex; flex-direction: column; gap: 6px; }
.t-size b { font: 800 clamp(2.6rem, 1.6rem + 3.6vw, 4.6rem)/1 var(--display); letter-spacing: -0.03em; font-variant-numeric: tabular-nums; }
.t-size span { font-weight: 700; color: var(--butter); font-size: 1.05rem; }

.plan svg { display: block; width: 100%; height: auto; border-radius: var(--r-sm); }
.plan figcaption { font-size: 1rem; color: var(--soft); margin-top: 10px; }
.fact { font-size: 1.1rem; margin: 0; }
.steps { padding-left: 1.4em; margin: 0; } .steps li { margin: .5em 0; }
.t-side h2, .t-wide h2 { font-size: 1.25rem; }

.tw { overflow-x: auto; -webkit-overflow-scrolling: touch; scrollbar-color: #b9c3b5 transparent; }
table { border-collapse: collapse; width: 100%; min-width: 480px; font-size: 1rem; }
caption { text-align: left; font: 700 1.25rem var(--display); letter-spacing: -0.01em; padding-bottom: 12px; }
th, td { text-align: left; padding: 12px 14px 12px 0; border-bottom: 1px solid var(--line); vertical-align: top; }
thead th { font-size: .95rem; color: var(--soft); font-weight: 700; border-bottom: 2px solid var(--ink); }
tbody th, tbody td:nth-child(2), tbody td:nth-child(3) { font-family: var(--display); font-weight: 700; font-variant-numeric: tabular-nums; }
tbody td:last-child { font-family: var(--sans); font-weight: 400; }
tbody tr:hover { background: #f5f7f3; }

.method ul { padding-left: 1.2em; margin: 0; } .method li { margin: .45em 0; }
.note { background: var(--butter-soft); padding: 14px 18px; border-radius: var(--r-sm); font-size: 1.05rem; margin: 14px 0 0; }

/* shopping */
.shop h2 { margin: 0 0 4px; }
.shop p { margin: 0 0 14px; font-size: 1.05rem; }
.shop ul { list-style: none; margin: 0 0 14px; padding: 0; display: flex; flex-wrap: wrap; gap: 10px; }
.buy { display: inline-flex; align-items: center; min-height: 48px; padding: 10px 22px; background: var(--cobalt); color: #fff; font-weight: 700; text-decoration: none; border-radius: 999px; }
.buy:hover { background: var(--cobalt-deep); color: #fff; }
.shop .disc { font-size: .95rem; color: var(--soft); margin: 0; }

.sources { font-size: 1rem; }
.sources ol { padding-left: 1.4em; margin: 0; } .sources li { margin: .35em 0; }
.sources li:target { background: var(--butter-soft); border-radius: 6px; }
.updated { font-size: .95rem; color: var(--soft); margin: 14px 0 0; }

/* neighbours and lists: tiles with the size in cobalt */
.next { margin-top: 40px; }
.next h2 { margin: 0 4px 14px; font-size: 1.6rem; }
.next ul, .qs { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: var(--gap); }
.next a, .qs a { display: flex; flex-direction: column; gap: 4px; height: 100%; min-height: 48px; background: var(--tile); border-radius: 20px; padding: 18px 20px; text-decoration: none; color: var(--ink); transition: background-color .2s ease-out; }
.next a:hover, .qs a:hover { background: var(--butter-soft); color: var(--ink); }
.next a span, .qs a span { font: 700 1.3rem var(--display); color: var(--cobalt); letter-spacing: -0.01em; order: -1; font-variant-numeric: tabular-nums; }
.qs.wide { grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); }
.qs a small { font-size: 1rem; color: var(--soft); margin-top: 4px; }

/* hubs and home */
.hub, .home { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: var(--gap); }
.hub > *, .home > * { grid-column: span 6; }
.hub h1, .home h1 { font-size: clamp(2.2rem, 1.3rem + 3.4vw, 4rem); font-weight: 800; letter-spacing: -0.03em; margin: 0 0 14px; }
.lede { font-size: 1.25rem; max-width: 58ch; margin: 0; }
.home > .t-q { grid-column: span 3; display: flex; flex-direction: column; justify-content: flex-end; background: var(--cobalt); color: #fff; }
.home > .t-q h1 { color: #fff; }
.home > .t-q .lede { color: #eef1fc; }
.home > .plan { grid-column: span 3; }
.drawers { display: grid; gap: var(--gap); grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); }
.drawers > section { background: var(--tile); border-radius: var(--r); padding: 22px; }
.drawers h2 { margin: 0 0 12px; font-size: 1.6rem; }
.drawers h2 a { color: var(--ink); text-decoration: none; }
.drawers h2 a:hover { text-decoration: underline; text-decoration-color: var(--cobalt); }
.drawers .qs { grid-template-columns: 1fr; gap: 6px; }
.drawers .qs a { background: #f3f5f1; padding: 12px 16px; border-radius: var(--r-sm); }
.drawers .qs a span { font-size: 1.1rem; }

/* planners */
.planner { display: grid; gap: 16px; }
.planner fieldset { border: 0; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.planner legend { font: 700 1.1rem var(--display); margin-bottom: 8px; width: 100%; }
.planner fieldset label { display: inline-flex; align-items: center; gap: 8px; min-height: 48px; padding: 8px 16px; border: 1.5px solid var(--line); border-radius: 999px; background: #fff; cursor: pointer; }
.planner fieldset label:hover { background: var(--butter-soft); }
.planner fieldset label:has(input:checked) { border-color: var(--cobalt); box-shadow: inset 0 0 0 1.5px var(--cobalt); background: #eef1fc; }
.planner input[type=radio] { accent-color: var(--cobalt); width: 20px; height: 20px; margin: 0; }
.planner p { margin: 0; display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; }
.planner p > label { font-weight: 700; }
.planner input[type=number], .planner select { font: 700 1.2rem var(--display); font-variant-numeric: tabular-nums; min-height: 48px; padding: 6px 14px; border: 1.5px solid #9aa79f; border-radius: var(--r-sm); width: 7em; background: #fff; color: var(--ink); caret-color: var(--cobalt); }
.planner select { width: auto; font-family: var(--sans); }
.planner input:hover, .planner select:hover { border-color: var(--ink); }
[hidden] { display: none !important; }

.prose { font-size: 1.1rem; max-width: 860px; } .prose h2 { font-size: 1.35rem; margin-top: 1.8em; }
.card .lede { margin-top: 8px; }

footer.site { background: var(--ink); color: #e3e9e4; margin: 0 var(--gut) var(--gut); border-radius: var(--r); padding: 36px clamp(20px, 4vw, 48px) 32px; }
.fin { max-width: 1120px; margin: 0 auto; display: grid; gap: 24px; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
footer.site h2 { font-size: 1.1rem; margin: 0 0 8px; color: var(--butter); }
footer.site ul { list-style: none; padding: 0; margin: 0; }
footer.site a { color: #fff; display: inline-block; padding: 6px 0; min-height: 44px; }
footer.site a:hover { color: var(--butter); }
footer.site :focus-visible { outline-color: var(--butter); }
.fine { max-width: 1120px; margin: 20px auto 0; font-size: .95rem; color: #c9d3cb; }

@media (max-width: 760px) {
  .bento > *, .hub > *, .home > * { grid-column: 1 / -1 !important; }
  .t-size { align-items: center; }
  .t-size, .home > .t-q { padding: 26px; }
}
@media (max-width: 560px) {
  body { font-size: 1.125rem; }
  .tin-in { justify-content: center; }
  .tabs { width: 100%; } .tabs a { flex: 1; padding: 0 6px; font-size: 1.05rem; }
  .answer { font-size: 1.2rem; }
  table { min-width: 0; font-size: .95rem; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }
@media print { .tin, footer.site, .t-shop, .next, .planner { display: none; } body { background: #fff; } .tile, .card { padding: 0; } }
