/* The Thinking Corner · identity approved 7-oct-2026
   Ink #15223D · paper #F6F8F6 · grid #DDE5EE · marker #FFE14D (highlights, never text) · pencil #56657D · margin #E5484D
   Bricolage Grotesque (display + body) · Kalam (pencil notes) · JetBrains Mono (labels). All OFL, self-hosted. */

@font-face { font-family: "Bricolage Grotesque"; src: url("/fonts/bricolage-grotesque-latin.woff2") format("woff2"); font-weight: 400 800; font-display: swap; }
@font-face { font-family: "Kalam"; src: url("/fonts/kalam-latin.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "JetBrains Mono"; src: url("/fonts/jetbrains-mono-latin.woff2") format("woff2"); font-weight: 400 700; font-display: swap; }

:root {
  --paper: #f6f8f6;
  --sheet: #ffffff;
  --ink: #15223d;
  --pencil: #56657d;
  --grid: #dde5ee;
  --marker: #ffe14d;
  --margin: #e5484d;
  --ok: #1f7a4d;
  --shadow: 0 1px 0 rgba(21, 34, 61, .04), 0 10px 30px -18px rgba(21, 34, 61, .25);
  --display: "Bricolage Grotesque", "Avenir Next", "Segoe UI", system-ui, sans-serif;
  --hand: "Kalam", "Bradley Hand", "Segoe Print", cursive;
  --mono: "JetBrains Mono", ui-monospace, "SFMono-Regular", Menlo, monospace;
  --radius: 8px;
  --gutter: clamp(16px, 4vw, 32px);
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root {
    --paper: #0f172b; --sheet: #16223c; --ink: #eef2f8; --pencil: #a3b0c6; --grid: #22314f;
    --margin: #ff6b6e; --ok: #5fd39a; --shadow: 0 10px 30px -18px rgba(0, 0, 0, .6);
    color-scheme: dark;
  }
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 24px; }
body {
  margin: 0;
  background-color: var(--paper);
  background-image: linear-gradient(var(--grid) 1px, transparent 1px), linear-gradient(90deg, var(--grid) 1px, transparent 1px);
  background-size: 28px 28px;
  background-position: -1px -1px;
  color: var(--ink);
  font: 400 18px/1.6 var(--display);
  font-optical-sizing: auto;
  text-rendering: optimizeLegibility;
}
img, video { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration-thickness: 1.5px; text-underline-offset: 3px; }
a:hover { text-decoration-color: var(--marker); }
:focus-visible { outline: 3px solid var(--marker); outline-offset: 3px; border-radius: 4px; }
h1, h2, h3 { margin: 0; font-weight: 800; letter-spacing: -0.025em; line-height: 1.06; text-wrap: balance; }
p { margin: 0; }
mark {
  background: linear-gradient(transparent 40%, var(--marker) 40%, var(--marker) 90%, transparent 90%);
  color: inherit; padding: 0 .06em;
}
@media (prefers-color-scheme: dark) { mark { color: #15223d; background: var(--marker); border-radius: 2px; } }

.skip { position: absolute; left: -9999px; }
.skip:focus { left: 12px; top: 12px; z-index: 10; background: var(--marker); color: #15223d; padding: 8px 14px; border-radius: 99px; }
.wrap { max-width: 1100px; margin-inline: auto; padding-inline: var(--gutter); }
.wrap-narrow { max-width: calc(760px + 2 * var(--gutter)); margin-inline: auto; padding-inline: var(--gutter); }
.muted { color: var(--pencil); }
.eyebrow { font: 500 12px/1.4 var(--mono); letter-spacing: .12em; text-transform: uppercase; color: var(--pencil); }
.pencil { font-family: var(--hand); color: var(--pencil); font-size: 20px; line-height: 1.3; }
.lede { font-size: clamp(19px, 2.2vw, 22px); line-height: 1.5; max-width: 60ch; color: var(--ink); }
ul.plain { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; }

/* buttons & chips */
.actions { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.button {
  display: inline-flex; align-items: center; gap: 6px; min-height: 44px; padding: 8px 18px;
  font: 700 16px/1.2 var(--display); text-decoration: none;
  background: var(--ink); color: var(--paper); border: 1.5px solid var(--ink); border-radius: 99px;
  transition: transform .15s ease, box-shadow .15s ease;
}
.button:hover { transform: translateY(-1px); box-shadow: 0 4px 0 var(--marker); }
.button.ghost { background: var(--sheet); color: var(--ink); }
.chip {
  display: inline-block; font: 500 11.5px/1.5 var(--mono); letter-spacing: .04em; text-transform: uppercase;
  padding: 1px 9px; border: 1.5px solid currentColor; border-radius: 99px; color: var(--pencil); white-space: nowrap;
}
.chip.draft { color: #15223d; background: var(--marker); border-color: var(--marker); }
.chip.archive { border-style: dashed; }
.meta { display: flex; flex-wrap: wrap; gap: 6px 10px; align-items: center; font: 500 13px/1.4 var(--mono); color: var(--pencil); }

/* header & footer */
.site-header { padding-block: 18px; }
.header-row { display: flex; align-items: center; justify-content: space-between; gap: 12px 20px; flex-wrap: wrap; }
.brand { display: inline-flex; align-items: center; gap: 10px; font-weight: 800; font-size: 19px; letter-spacing: -0.02em; text-decoration: none; }
.brand .logo { width: 36px; height: 36px; flex: none; border-radius: 50%; }
@media (prefers-color-scheme: dark) { .brand .logo { box-shadow: 0 0 0 1.5px #34466b; } }
.site-header nav { display: flex; gap: 4px 18px; align-items: center; flex-wrap: wrap; font-weight: 600; font-size: 16px; }
.site-header nav a { text-decoration: none; padding: 6px 2px; }
.site-header nav a[aria-current="page"] { background: linear-gradient(transparent 62%, var(--marker) 62%, var(--marker) 92%, transparent 92%); }
@media (prefers-color-scheme: dark) { .site-header nav a[aria-current="page"] { background: none; box-shadow: inset 0 -3px 0 var(--marker); } }
.site-header .nav-cta { border: 1.5px solid var(--ink); border-radius: 99px; padding: 6px 14px; background: var(--sheet); }
.site-footer { margin-top: 96px; padding-block: 40px 28px; border-top: 1.5px solid var(--grid); background: var(--paper); }
.footer-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 28px; font-size: 16px; }
.footer-grid .eyebrow { margin-bottom: 8px; }
.footer-brand p { margin-top: 10px; color: var(--pencil); }
.fine { margin-top: 28px; font: 400 12.5px/1.5 var(--mono); color: var(--pencil); }

/* home */
.hero { padding-block: clamp(32px, 8vw, 96px) clamp(24px, 5vw, 48px); display: grid; gap: 18px; }
.hero h1 { font-size: clamp(42px, 7.4vw, 88px); max-width: 15ch; letter-spacing: -0.035em; line-height: 1; }
.hero .pencil { transform: rotate(-2deg); transform-origin: left; margin-top: 6px; }
.notes-home { display: grid; gap: 22px; }
.more-link { display: flex; justify-content: center; margin-top: 4px; }
.follow { margin-top: 56px; display: grid; justify-items: center; gap: 14px; text-align: center; }
.follow .pencil { margin-right: 6px; }

/* sheets: a notebook page with a red margin line */
.sheet {
  position: relative; background: var(--sheet); border: 1.5px solid var(--grid); border-radius: var(--radius);
  padding: clamp(22px, 4vw, 40px) clamp(18px, 4vw, 40px) clamp(22px, 4vw, 40px) clamp(34px, 6vw, 64px);
  box-shadow: var(--shadow);
}
.sheet::before { content: ""; position: absolute; left: clamp(18px, 3.4vw, 36px); top: 0; bottom: 0; width: 2px; background: var(--margin); opacity: .5; }

/* cards */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr)); gap: 22px; }
.grid.two { grid-template-columns: repeat(auto-fill, minmax(min(100%, 280px), 1fr)); }
.card { background: var(--sheet); border: 1.5px solid var(--grid); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); transition: transform .15s ease, border-color .15s ease; }
.card:hover { transform: translateY(-2px); border-color: var(--ink); }
.card-link { display: grid; height: 100%; text-decoration: none; grid-template-rows: auto 1fr; }
.card-media { aspect-ratio: 16 / 10; overflow: hidden; background: var(--grid); border-bottom: 1.5px solid var(--grid); }
.card-media img { width: 100%; height: 100%; object-fit: cover; }
.card.tall .card-media img { object-position: center 30%; }
.card-body { padding: 18px 20px 22px; display: grid; gap: 10px; align-content: start; }
.card h3 { font-size: 22px; }
.card-body > p:not(.meta) { color: var(--pencil); font-size: 16px; line-height: 1.5; }
.card .read { font-weight: 700; margin-top: 4px; }
.card.featured .card-link { grid-template-columns: minmax(0, 1fr); }
@media (min-width: 760px) {
  .card.featured .card-link { grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); grid-template-rows: 1fr; }
  .card.featured .card-media { aspect-ratio: auto; min-height: 380px; border-bottom: 0; border-right: 1.5px solid var(--grid); position: relative; }
  .card.featured .card-media img { position: absolute; inset: 0; }
  .card.featured.tall .card-media img { object-position: center 18%; }
  .card.featured .card-body { padding: clamp(24px, 4vw, 48px); align-content: center; gap: 14px; }
  .card.featured h3 { font-size: clamp(30px, 3.6vw, 44px); }
  .card.featured .card-body > p:not(.meta) { font-size: 19px; }
}

/* who's behind */
.behind { display: grid; grid-template-columns: minmax(0, 1fr); gap: 28px; align-items: center; margin-top: 72px; }
@media (min-width: 760px) { .behind { grid-template-columns: minmax(0, 300px) minmax(0, 1fr); gap: 48px; } }
.behind-text { display: grid; gap: 14px; }
.behind h2 { font-size: clamp(30px, 4vw, 44px); }
.polaroid { margin: 0; position: relative; max-width: 300px; background: #fff; padding: 10px 10px 0; border: 1.5px solid var(--grid); border-radius: 4px; transform: rotate(-2.5deg); box-shadow: var(--shadow); }
.polaroid::before { content: ""; position: absolute; top: -12px; left: 50%; width: 92px; height: 24px; transform: translateX(-50%) rotate(3deg); background: var(--marker); opacity: .85; border-radius: 2px; }
.polaroid img { border-radius: 2px; aspect-ratio: 1; object-fit: cover; }
.polaroid figcaption { color: #56657d; padding: 6px 4px 10px; text-align: center; font-size: 19px; }

/* page heads */
.page-head { padding-block: clamp(32px, 7vw, 80px) clamp(20px, 4vw, 40px); display: grid; gap: 16px; }
.page-head h1 { font-size: clamp(38px, 6.4vw, 72px); max-width: 16ch; letter-spacing: -0.035em; }
.archive-list { margin-top: 64px; display: grid; gap: 14px; }
.archive-list h2 { font-size: clamp(26px, 3.4vw, 34px); }
.archive-list .grid { margin-top: 8px; }

/* note */
.note-head { padding-block: clamp(24px, 5vw, 56px) 24px; display: grid; gap: 16px; }
.note-head h1 { font-size: clamp(36px, 6vw, 62px); letter-spacing: -0.035em; }
.crumbs { font: 500 14px var(--mono); }
.crumbs a { text-decoration: none; color: var(--pencil); }
.banner { margin-bottom: 20px; }
.banner { font: 500 14px/1.5 var(--mono); color: var(--pencil); }
.banner::before { content: "✎ "; }
.banner.draft { color: #15223d; }
.banner.draft::before { content: ""; }
p.banner.draft { background: var(--marker); padding: 10px 14px; border-radius: var(--radius); }
.reel { margin: 0 auto 28px; max-width: 340px; display: grid; gap: 8px; }
.reel video { width: 100%; aspect-ratio: 9 / 16; border-radius: 14px; border: 1.5px solid var(--grid); background: #15223d; box-shadow: var(--shadow); }
.reel figcaption { font: 500 13px/1.5 var(--mono); color: var(--pencil); text-align: center; }
.cover { margin: 0 0 28px; }
.cover img { width: 100%; max-height: 460px; object-fit: cover; border-radius: var(--radius); border: 1.5px solid var(--grid); }

/* long-form text */
.prose { font-size: 18.5px; line-height: 1.68; }
.prose > * + * { margin-top: 1.05em; }
.prose h2 { font-size: clamp(26px, 3.2vw, 32px); margin-top: 1.8em; scroll-margin-top: 24px; }
.prose h3 { font-size: 22px; margin-top: 1.5em; letter-spacing: -0.015em; }
.prose h2 + *, .prose h3 + * { margin-top: .6em; }
.prose > :first-child { margin-top: 0; }
.prose ul, .prose ol { padding-left: 1.3em; }
.prose li + li { margin-top: .35em; }
.prose li::marker { color: var(--pencil); }
.prose a { text-decoration-color: var(--marker); text-decoration-thickness: 3px; }
.prose a:hover { background: var(--marker); color: #15223d; }
.prose strong { font-weight: 700; }
.prose blockquote { margin-inline: 0; padding: 4px 0 4px 18px; border-left: 4px solid var(--marker); font-size: 1.05em; }
.prose blockquote > * + * { margin-top: .6em; }
.prose hr { border: 0; border-top: 1.5px dashed var(--grid); margin-block: 2em; }
.prose figure { margin-inline: 0; }
.prose figure img { border-radius: var(--radius); border: 1.5px solid var(--grid); margin-inline: auto; max-height: 520px; width: auto; }
.prose figcaption { font: 500 13px/1.5 var(--mono); color: var(--pencil); margin-top: 8px; text-align: center; }
.prose code { font: 500 .84em var(--mono); background: var(--paper); border: 1px solid var(--grid); border-radius: 4px; padding: .08em .35em; }
.prose pre { background: #15223d; color: #eef2f8; border-radius: var(--radius); padding: 16px 18px; white-space: pre-wrap; overflow-wrap: anywhere; font-size: 15px; line-height: 1.6; }
@media (max-width: 640px) { .prose pre { font-size: 13.5px; padding: 14px; } }
.prose pre code { background: none; border: 0; padding: 0; color: inherit; font-size: inherit; }
.prose .table { overflow-x: auto; }
.prose table { border-collapse: collapse; width: 100%; font-size: 16px; }
.prose th, .prose td { text-align: left; padding: 8px 10px; border-bottom: 1.5px solid var(--grid); vertical-align: top; }
.prose th { font: 600 12.5px var(--mono); text-transform: uppercase; letter-spacing: .06em; color: var(--pencil); }
.prose .aside { font-family: var(--hand); color: var(--pencil); font-size: 20px; line-height: 1.35; transform: rotate(-1deg); }
.prose .fineprint { font: 500 13.5px/1.6 var(--mono); color: var(--pencil); border-top: 1.5px dashed var(--grid); padding-top: 1em; }
.prose .files { list-style: none; padding: 0; display: grid; gap: 8px; }
.prose .files li { margin: 0; display: grid; grid-template-columns: minmax(0, 150px) minmax(0, 1fr); gap: 4px 14px; align-items: baseline; }
.prose .files code { justify-self: start; }
@media (max-width: 520px) { .prose .files li { grid-template-columns: minmax(0, 1fr); } }

.author { margin-top: 36px; display: grid; grid-template-columns: 72px minmax(0, 1fr); gap: 16px; align-items: center; font-size: 16px; }
.author img { width: 72px; height: 72px; border-radius: 50%; object-fit: cover; border: 2px solid var(--marker); }
.author > div { display: grid; gap: 4px; }
.actions.small { gap: 6px 16px; font-weight: 600; margin-top: 4px; }
.next { margin-top: 56px; display: grid; gap: 14px; }

/* about */
.about-hero { padding-block: clamp(28px, 6vw, 72px) 24px; display: grid; gap: 32px; align-items: center; }
@media (min-width: 820px) { .about-hero { grid-template-columns: minmax(0, 1.25fr) minmax(0, 340px); gap: 56px; } }
.about-hero .intro { display: grid; gap: 18px; }
.about-hero h1 { font-size: clamp(42px, 7vw, 80px); letter-spacing: -0.035em; }
.about-hero .polaroid { max-width: 340px; justify-self: center; transform: rotate(2deg); }
.about-hero .polaroid::before { transform: translateX(-50%) rotate(-4deg); }
.section { margin-top: clamp(56px, 9vw, 104px); display: grid; gap: 22px; }
.section-head { display: grid; gap: 10px; max-width: 760px; }
.section-head h2 { font-size: clamp(30px, 4.6vw, 48px); letter-spacing: -0.03em; }
.tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr)); gap: 18px; }
.tiles.two-up { grid-template-columns: repeat(auto-fit, minmax(min(100%, 420px), 1fr)); }
.tile { background: var(--sheet); border: 1.5px solid var(--grid); border-radius: var(--radius); padding: 22px 22px 24px; display: grid; gap: 10px; align-content: start; box-shadow: var(--shadow); }
.tile h3 { font-size: 22px; letter-spacing: -0.015em; }
.tile p { color: var(--pencil); font-size: 16px; line-height: 1.55; }
.tile .label { font: 600 12px var(--mono); letter-spacing: .08em; text-transform: uppercase; color: var(--ink); margin-top: 6px; }
.tile .label + p { color: var(--ink); }
.tile .status { justify-self: start; }
.tile .status.live { color: var(--ok); }
.problems { display: grid; gap: 0; }
.problem { display: grid; grid-template-columns: minmax(0, 1fr); gap: 6px 32px; padding-block: 22px; border-bottom: 1.5px dashed var(--grid); align-items: baseline; }
.problem:first-child { border-top: 1.5px dashed var(--grid); }
@media (min-width: 760px) { .problem { grid-template-columns: 56px minmax(0, 1fr) minmax(0, 1fr); } }
.problem .num { font: 600 14px var(--mono); color: var(--pencil); }
.problem .before { color: var(--pencil); }
.problem .before strong { text-decoration: line-through; text-decoration-color: var(--margin); text-decoration-thickness: 2px; font-weight: 700; color: var(--ink); }
.problem .after strong { font-size: 22px; letter-spacing: -0.015em; }
.problem .after strong, .problem .before strong { display: block; }
.principle { text-align: center; display: grid; gap: 14px; justify-items: center; padding-block: 12px; }
.principle h2 { font-size: clamp(32px, 5.4vw, 60px); letter-spacing: -0.035em; max-width: 18ch; }
.principle p { color: var(--pencil); max-width: 52ch; }
.contact { text-align: center; display: grid; gap: 16px; justify-items: center; }
.contact h2 { font-size: clamp(34px, 5.6vw, 64px); letter-spacing: -0.035em; max-width: 14ch; }
.contact .email { font: 500 15px var(--mono); color: var(--pencil); }

@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; }
  .card:hover, .button:hover { transform: none; }
}
