/* ATD26 Nick Floro Resources — v2 · modern */

:root {
  /* Prototyping-for-Learning palette: warm off-white canvas, deep ink, sealworks orange */
  --bg: #fafaf7;
  --bg-2: #f2efe8;
  --bg-3: #ffffff;
  --ink: #141414;
  --ink-2: #1e1e1e;
  --ink-dim: #4a4a4a;
  --ink-faint: #8a8a8a;
  --line: #ebe7dc;
  --line-2: #d7d1bf;
  --accent: #d77f3c;        /* sealworks warm orange */
  --accent-2: #f5b27a;       /* lighter warm */
  --accent-3: #2a5c8a;       /* deep blue secondary */
  --accent-ink: #141414;

  /* Supporting palette (used by category glyphs, tinted tiles) */
  --tint-orange-bg: #fdeadb;
  --tint-orange-fg: #b35a1e;
  --tint-blue-bg: #e8f0f7;
  --tint-blue-fg: #2a5c8a;
  --tint-olive-bg: #eef2e6;
  --tint-olive-fg: #4b6b2a;
  --tint-purple-bg: #f2eaff;
  --tint-purple-fg: #6b2ea4;

  --font-display: "Space Grotesk", "Helvetica Neue", sans-serif;
  --font-body: "Inter", ui-sans-serif, system-ui, -apple-system, "Helvetica Neue", sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
  --font-hand: "Caveat", "Comic Sans MS", cursive;

  --radius: 14px;
  --radius-sm: 10px;
  --radius-lg: 20px;
}

/* Font pairings via Tweaks — Space Grotesk is the new default */
html[data-font="editorial"] {
  --font-display: "Instrument Serif", "Bodoni Moda", "Times New Roman", serif;
  --font-body: "Inter", system-ui, sans-serif;
}
html[data-font="modernist"] {
  --font-display: "Space Grotesk", "Helvetica Neue", sans-serif;
  --font-body: "Inter", system-ui, sans-serif;
}
html[data-font="techno"] {
  --font-display: "JetBrains Mono", ui-monospace, monospace;
  --font-body: "Inter", system-ui, sans-serif;
}
html[data-font="classic"] {
  --font-display: "Fraunces", "Georgia", serif;
  --font-body: "IBM Plex Sans", system-ui, sans-serif;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: clip;
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }

.mono { font-family: var(--font-mono); font-feature-settings: "tnum" 1; letter-spacing: 0; }
.serif { font-family: var(--font-display); }
.upper { text-transform: uppercase; letter-spacing: 0.1em; }

.container {
  max-width: 1320px;
  margin: 0 auto;
  padding: 0 32px;
}
@media (max-width: 640px) { .container { padding: 0 20px; } }

/* ──────────── Booth ribbon ──────────── */
.booth-ribbon {
  background: var(--ink);
  color: var(--bg);
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.04em;
  overflow: hidden;
  position: relative;
}
.booth-ribbon .track {
  display: flex; gap: 48px;
  padding: 10px 0;
  white-space: nowrap;
  animation: marquee 38s linear infinite;
  will-change: transform;
}
.booth-ribbon .track span { display: inline-flex; align-items: center; gap: 12px; }
/* Booth ribbon accent marker — slightly lighter orange glow */
.booth-ribbon .dot { display:inline-block; width: 6px; height: 6px; border-radius: 50%; background: var(--accent-2); }
@keyframes marquee {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

/* ──────────── Nav ──────────── */
.nav {
  position: sticky; top: 0; z-index: 40;
  background: color-mix(in oklab, var(--bg) 88%, transparent);
  backdrop-filter: saturate(140%) blur(16px);
  -webkit-backdrop-filter: saturate(140%) blur(16px);
  border-bottom: 1px solid var(--line);
}
.nav-inner {
  display: flex; align-items: center; justify-content: space-between;
  height: 68px;
}
.nav-brand {
  display: flex; align-items: center; gap: 12px;
  font-family: var(--font-display);
  font-size: 20px;
  letter-spacing: -0.01em;
}
.nav-brand .brand-at {
  color: var(--accent);
  font-style: italic;
  font-weight: 400;
  margin: 0 1px;
}
.nav-brand .mark {
  width: 28px; height: 28px; border-radius: 50%;
  background: var(--ink);
  position: relative;
  overflow: hidden;
}
.nav-brand .mark::before {
  content: ""; position: absolute; inset: 6px;
  background: var(--accent); border-radius: 50%;
}
.nav-links {
  display: flex; gap: 4px; align-items: center;
  font-size: 14px;
  background: var(--bg-3);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 5px;
}
.nav-links a {
  padding: 8px 14px;
  border-radius: 999px;
  color: var(--ink-dim);
  transition: background 0.15s, color 0.15s;
}
.nav-links a:hover { color: var(--ink); }
.nav-links a.active { background: var(--ink); color: var(--bg); }
.nav-actions {
  display: flex; align-items: center; gap: 8px;
}
.nav-icon {
  width: 40px; height: 40px;
  border-radius: 50%;
  background: var(--bg-3);
  border: 1px solid var(--line);
  color: var(--ink-dim);
  cursor: pointer;
  display: inline-flex; align-items: center; justify-content: center;
  transition: color 0.15s, border-color 0.15s, background 0.15s;
  padding: 0;
}
.nav-icon:hover { color: var(--ink); border-color: var(--ink); background: var(--bg); }
.nav-cta {
  background: var(--accent); color: #fff;
  padding: 10px 18px; border-radius: 999px;
  font-size: 14px; font-weight: 500;
  display: inline-flex; align-items: center; gap: 10px;
  border: 1px solid var(--accent);
  box-shadow: 0 6px 16px -6px rgba(215,127,60,0.5);
  transition: transform 0.15s, box-shadow 0.15s, background 0.15s;
}
.nav-cta .dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: #fff;
  box-shadow: 0 0 0 3px rgba(255,255,255,0.3);
  animation: pulse 2s ease-in-out infinite;
}
@keyframes pulse {
  0%, 100% { box-shadow: 0 0 0 3px rgba(255,255,255,0.3); }
  50% { box-shadow: 0 0 0 5px rgba(255,255,255,0); }
}
.nav-cta:hover { transform: translateY(-2px); box-shadow: 0 10px 22px -8px rgba(215,127,60,0.6); background: #e88a48; }
@media (max-width: 900px) {
  .nav-links { display: none; }
  .nav-cta-label { display: none; }
  .nav-cta { padding: 10px 14px; }
}

/* ──────────── Buttons ──────────── */
.btn {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 14px 22px;
  border-radius: 999px;
  font-size: 15px;
  font-weight: 500;
  transition: transform 0.15s, box-shadow 0.15s, background 0.15s;
  cursor: pointer;
  border: 1px solid var(--ink);
}
.btn-primary { background: var(--ink); color: #fff; border-color: var(--ink); box-shadow: 0 10px 24px -12px rgba(20,20,20,0.4); }
.btn-primary:hover { background: var(--accent); color: #fff; border-color: var(--accent); transform: translateY(-2px); box-shadow: 0 14px 28px -12px rgba(215,127,60,0.5); }
.btn-ghost { background: transparent; color: var(--ink); border-color: var(--ink); }
.btn-ghost:hover { background: var(--ink); color: #fff; }
.btn-dark { background: var(--ink); color: var(--bg); }
.btn-dark:hover { background: var(--ink-2); }
.arrow::after { content: "→"; display: inline-block; transition: transform 0.2s; }
.arrow:hover::after { transform: translateX(3px); }

/* ──────────── Hero ──────────── */
.hero { padding: 56px 0 40px; position: relative; overflow: hidden; }
.eyebrow {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.08em;
  color: var(--ink-dim);
  display: inline-flex; align-items: center; gap: 10px;
  margin-bottom: 28px;
  text-transform: uppercase;
}
.eyebrow .pill {
  background: var(--ink); color: var(--bg);
  padding: 4px 10px; border-radius: 999px; font-weight: 500;
}
.eyebrow .pill.accent { background: var(--accent); color: #fff; }

.h-display {
  font-family: var(--font-display);
  font-size: clamp(48px, 8vw, 128px);
  line-height: 0.92;
  letter-spacing: -0.025em;
  font-weight: 400;
  margin: 0 0 28px;
  text-wrap: balance;
}
.h-display .italic { font-style: italic; color: var(--accent); }
.h-display .alt { font-style: italic; }

.h-sub {
  font-size: clamp(17px, 1.4vw, 20px);
  color: var(--ink-dim);
  max-width: 62ch;
  margin: 0 0 32px;
  line-height: 1.5;
  text-wrap: pretty;
}

.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; }

/* Hero variant A — Editorial with stat ticker */
.hero-a .hero-stack { display: grid; grid-template-columns: 1.3fr 1fr; gap: 48px; align-items: end; }
.hero-a .hero-stats {
  display: grid; grid-template-columns: 1fr 1fr; gap: 1px;
  background: var(--line); border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
}
.hero-a .stat {
  background: var(--bg); padding: 20px;
  display: flex; flex-direction: column; gap: 6px;
}
.hero-a .stat .num {
  font-family: var(--font-display);
  font-size: 56px; line-height: 1; font-weight: 400;
  letter-spacing: -0.03em;
}
.hero-a .stat .num .italic { font-style: italic; color: var(--accent); }
.hero-a .stat .lbl {
  font-family: var(--font-mono); font-size: 11px;
  color: var(--ink-dim); text-transform: uppercase; letter-spacing: 0.08em;
}

/* Hero variant B — Poster */
.hero-b .poster {
  font-family: var(--font-display);
  font-size: clamp(64px, 15vw, 240px);
  line-height: 0.86;
  letter-spacing: -0.04em;
  font-weight: 400;
  margin: 0;
}
.hero-b .poster .row { display: block; }
.hero-b .poster .italic { font-style: italic; color: var(--accent); }
.hero-b .poster .outline {
  color: transparent;
  -webkit-text-stroke: 1.5px var(--ink);
}
.hero-b .poster-foot {
  display: flex; gap: 28px; margin-top: 28px; flex-wrap: wrap;
  font-family: var(--font-mono); font-size: 12px; color: var(--ink-dim);
  border-top: 1px solid var(--line); padding-top: 20px;
  text-transform: uppercase; letter-spacing: 0.06em;
}

/* Hero variant C — Portrait card */
.hero-c .hero-stack { display: grid; grid-template-columns: 1fr 440px; gap: 56px; align-items: center; }
.hero-c .portrait {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  aspect-ratio: 4/5;
  background: var(--ink);
  border: 1px solid var(--line);
  box-shadow: 0 30px 60px -24px rgba(0,0,0,0.25);
}
.hero-c .portrait img {
  width: 100%; height: 100%; object-fit: cover;
  filter: contrast(1.05);
}
.hero-c .portrait .tag {
  position: absolute; bottom: 16px; left: 16px; right: 16px;
  background: var(--bg); color: var(--ink);
  padding: 12px 16px; border-radius: var(--radius-sm);
  display: flex; justify-content: space-between; align-items: center;
  font-family: var(--font-mono); font-size: 11px; text-transform: uppercase; letter-spacing: 0.08em;
}
.hero-c .portrait .tag strong { font-weight: 600; color: var(--accent); }

@media (max-width: 960px) {
  .hero-a .hero-stack, .hero-c .hero-stack { grid-template-columns: 1fr; gap: 32px; }
  .hero-c .portrait { max-width: 380px; margin: 0 auto; }
}

/* ──────────── Section ──────────── */
.section { padding: 88px 0; border-bottom: 1px solid var(--line); position: relative; }
.section-dark { background: var(--ink); color: var(--bg); border-color: var(--ink-2); }
.section-dark h2 { color: var(--bg); }
.section-dark .lede,
.section-dark .section-head .lede { color: #ffffff; }
.section-dark .lede strong { color: #ffffff; font-weight: 600; }
.section-dark .section-num { color: rgba(245,241,232,0.65); }

.section-num {
  font-family: var(--font-mono); font-size: 12px;
  color: var(--ink-faint); letter-spacing: 0.1em; text-transform: uppercase;
  margin-bottom: 16px;
  display: flex; align-items: center; gap: 10px;
}
.section-num::before {
  content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--accent);
}
.section-head {
  display: flex; align-items: flex-end; justify-content: space-between;
  margin-bottom: 44px; gap: 32px; flex-wrap: wrap;
}
.section-head h2 {
  font-family: var(--font-display);
  font-size: clamp(36px, 5vw, 72px);
  font-weight: 400;
  letter-spacing: -0.025em;
  line-height: 1;
  margin: 0;
  max-width: 18ch;
  text-wrap: balance;
}
.section-head h2 .italic { font-style: italic; color: var(--accent); }
.section-head .lede { color: var(--ink-dim); max-width: 44ch; font-size: 17px; margin: 0; }

/* ──────────── Category mosaic ──────────── */
.mosaic {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
}
@media (max-width: 1080px) { .mosaic { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 760px) { .mosaic { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 440px) { .mosaic { grid-template-columns: 1fr; } }

.cat {
  background: var(--bg-3);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 20px;
  display: flex; flex-direction: column; gap: 14px;
  min-height: 180px;
  transition: transform 0.2s, box-shadow 0.2s, background 0.2s;
  position: relative; overflow: hidden;
}
.cat:hover { transform: translateY(-3px); border-color: var(--accent); box-shadow: 0 18px 40px -20px rgba(0,0,0,0.15); background: var(--bg-3); }
.cat .cat-head { display: flex; align-items: flex-start; justify-content: space-between; }
.cat .glyph {
  width: 44px; height: 44px; border-radius: 12px;
  background: var(--ink); color: var(--bg);
  display: flex; align-items: center; justify-content: center;
  font-size: 22px;
}
.cat .cat-count {
  font-family: var(--font-mono); font-size: 11px; color: var(--ink-faint);
  text-transform: uppercase; letter-spacing: 0.08em;
  background: var(--bg); border: 1px solid var(--line); border-radius: 999px;
  padding: 4px 10px;
}
.cat h3 {
  font-family: var(--font-display); font-size: 24px; font-weight: 400;
  letter-spacing: -0.01em; margin: 0; line-height: 1.1;
  color: var(--ink);
}
.cat p { color: var(--ink-dim); font-size: 14px; margin: 0; flex: 1; line-height: 1.5; }
.cat .cat-foot {
  font-family: var(--font-mono); font-size: 12px; color: var(--ink);
  display: flex; align-items: center; gap: 6px;
  margin-top: auto;
}

/* Soft tinted glyph tiles — cycled 4-color per Prototyping palette */
.cat:nth-child(4n+1) .glyph { background: var(--tint-orange-bg); color: var(--tint-orange-fg); }
.cat:nth-child(4n+2) .glyph { background: var(--tint-blue-bg);   color: var(--tint-blue-fg); }
.cat:nth-child(4n+3) .glyph { background: var(--tint-olive-bg);  color: var(--tint-olive-fg); }
.cat:nth-child(4n+4) .glyph { background: var(--tint-purple-bg); color: var(--tint-purple-fg); }

/* ──────────── Featured cards (bento) ──────────── */
.bento { display: grid; grid-template-columns: 1.3fr 1fr 1fr; gap: 12px; }
@media (max-width: 900px) { .bento { grid-template-columns: 1fr; } }
.bento-card {
  background: var(--bg-3);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 28px;
  display: flex; flex-direction: column; gap: 14px;
  min-height: 280px;
  transition: transform 0.2s, box-shadow 0.2s;
  position: relative; overflow: hidden;
}
.bento-card:hover { transform: translateY(-3px); border-color: var(--accent); box-shadow: 0 18px 40px -20px rgba(0,0,0,0.15); }
.bento-card.big { background: linear-gradient(135deg, var(--ink) 0%, #1e1e1e 100%); color: #fff; border-color: var(--ink); }
.bento-card.big h4 { color: #fff; }
.bento-card.big p { color: rgba(255,255,255,0.75); }
.bento-card.big .pill-tag { background: var(--accent); color: #fff; border-color: var(--accent); }
.bento-card.big .featured-url { color: var(--accent-2); }
.bento-card.accent { background: var(--accent); border-color: var(--accent); color: #fff; }
.bento-card.accent h4 { color: #fff; }
.bento-card.accent p { color: rgba(255,255,255,0.85); }
.bento-card.accent .featured-url { color: rgba(255,255,255,0.9); }
.bento-card.accent .pill-tag { color: #fff; border-color: rgba(255,255,255,0.7); background: rgba(255,255,255,0.12); }
.bento-card .top {
  display: flex; justify-content: space-between; align-items: center;
}
.pill-tag {
  font-family: var(--font-mono); font-size: 10px;
  text-transform: uppercase; letter-spacing: 0.1em;
  padding: 4px 10px; border-radius: 999px;
  border: 1px solid var(--ink); color: var(--ink);
}
.bento-card h4 {
  font-family: var(--font-display); font-size: clamp(28px,3.5vw,44px);
  font-weight: 400; letter-spacing: -0.02em; margin: 0; line-height: 1;
  color: var(--ink);
}
.bento-card h4 .italic { font-style: italic; }
.bento-card p { color: var(--ink-dim); font-size: 14px; margin: 0; flex: 1; }
.bento-card .featured-url {
  font-family: var(--font-mono); font-size: 12px; color: var(--accent);
  margin-top: auto;
}

/* ──────────── Resource list (directory + categories) ──────────── */
/* Search bar across the top — sticky */
.search-topbar {
  position: sticky; top: 0; z-index: 50;
  display: flex; gap: 10px; align-items: center; flex-wrap: wrap;
  padding: 12px;
  margin: -12px 0 24px;
  background: rgba(245,241,232,0.94);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: 0 6px 24px rgba(13,13,13,0.08);
}
.search-topbar .search {
  flex: 1; min-width: 240px;
  display: flex; align-items: center; gap: 10px;
  padding: 12px 16px;
  background: var(--bg-3);
  border: 1px solid var(--line);
  border-radius: 999px;
}
.search-topbar .search input {
  flex: 1; background: transparent; border: none; outline: none;
  color: var(--ink); font-family: var(--font-body); font-size: 15px;
  min-width: 0;
}
.search-topbar .search input::placeholder { color: var(--ink-faint); }
.search-topbar .search svg { width: 16px; height: 16px; color: var(--ink-dim); flex-shrink: 0; }
.search-topbar .sort {
  display: flex; gap: 2px; padding: 4px;
  background: var(--bg-3); border: 1px solid var(--line); border-radius: 999px;
}
.search-topbar .sort button {
  background: transparent; border: none; color: var(--ink-dim);
  padding: 8px 14px; border-radius: 999px; cursor: pointer;
  font-family: var(--font-mono); font-size: 11px; text-transform: uppercase; letter-spacing: 0.08em;
}
.search-topbar .sort button.active { background: var(--ink); color: var(--bg); }
.search-topbar .count {
  font-family: var(--font-mono); font-size: 11px; color: var(--ink-faint);
  text-transform: uppercase; letter-spacing: 0.08em; padding: 0 12px;
}

/* Sticky sidebar wrapper (categories only now) */
.filters-sticky {
  position: sticky;
  top: 92px;
  align-self: start;
  max-height: calc(100vh - 108px);
  overflow-y: auto;
  padding-right: 8px;
  scrollbar-width: thin;
}
.filters-sticky::-webkit-scrollbar { width: 4px; }
.filters-sticky::-webkit-scrollbar-thumb { background: var(--line-2); border-radius: 4px; }

/* Layout: categories sidebar | list */
.directory-layout {
  display: grid;
  grid-template-columns: 260px 1fr;
  gap: 32px;
  align-items: start;
}
@media (max-width: 900px) {
  .directory-layout { grid-template-columns: 1fr; gap: 16px; }
  .filters-sticky { position: static; max-height: none; overflow: visible; padding-right: 0; }
  .search-topbar { top: 8px; }
}

/* legacy list-toolbar kept minimal for any other consumer */
.list-toolbar { display: none; }

/* Category filter chips — stacked */
.cat-chips {
  display: flex; flex-direction: column; gap: 4px;
  margin-bottom: 14px;
  padding: 12px;
  background: var(--bg-3);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}
.cat-chips-label {
  font-family: var(--font-mono);
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--ink-faint);
  padding: 4px 10px 8px;
}

/* Category filter chips */
.cat-chip {
  font-family: var(--font-mono); font-size: 12px; letter-spacing: 0.04em;
  padding: 10px 14px; border-radius: 10px;
  background: transparent; border: 1px solid transparent; color: var(--ink-dim);
  cursor: pointer;
  text-align: left;
  display: flex; align-items: center; gap: 8px;
  transition: all 0.15s;
}
.cat-chip:hover { color: var(--ink); background: var(--bg); }
.cat-chip.active { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.cat-chip .cat-chip-count { margin-left: auto; opacity: 0.6; font-size: 10px; }

.list { display: flex; flex-direction: column; gap: 10px; }
.row {
  display: grid;
  grid-template-columns: 36px minmax(160px, 1.2fr) 2.2fr minmax(160px, 1fr) 110px 32px;
  gap: 20px;
  padding: 16px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--line);
  background: var(--bg-3);
  align-items: center;
  cursor: pointer;
  transition: transform 0.15s, border-color 0.15s, box-shadow 0.15s;
}
.row:hover {
  transform: translateY(-2px);
  border-color: var(--accent);
  box-shadow: 0 14px 32px -16px rgba(0,0,0,0.18);
}
.row .num {
  font-family: var(--font-mono);
  color: var(--ink-faint);
  font-size: 11px;
  letter-spacing: 0.06em;
}
.row .name-box {
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 12px 14px;
  transition: background 0.15s, border-color 0.15s;
}
.row[data-hue="0"] .name-box { background: color-mix(in oklab, var(--accent) 14%, var(--bg-3)); border-color: color-mix(in oklab, var(--accent) 40%, var(--line)); }
.row[data-hue="1"] .name-box { background: color-mix(in oklab, var(--accent-2) 18%, var(--bg-3)); border-color: color-mix(in oklab, var(--accent-2) 45%, var(--line)); }
.row[data-hue="2"] .name-box { background: color-mix(in oklab, var(--accent-3) 10%, var(--bg-3)); border-color: color-mix(in oklab, var(--accent-3) 30%, var(--line)); }
.row:hover .name-box { background: var(--bg-3); border-color: var(--ink); }

.row .name-title {
  font-family: var(--font-display);
  font-size: clamp(20px, 1.6vw, 26px);
  font-weight: 400;
  letter-spacing: -0.01em;
  line-height: 1.1;
  color: var(--ink);
  text-wrap: balance;
  overflow-wrap: anywhere;
  word-break: break-word;
  hyphens: auto;
}
.row .desc { color: var(--ink-dim); font-size: 14px; line-height: 1.5; }
.row .cat-tag {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 8px 12px;
  border-radius: 999px;
  background: var(--bg);
  border: 1px solid var(--line);
  width: fit-content;
}
.row .cat-glyph { font-size: 16px; line-height: 1; }
.row[data-hue="0"] .cat-tag { background: color-mix(in oklab, var(--accent) 12%, var(--bg-3)); border-color: color-mix(in oklab, var(--accent) 35%, var(--line)); }
.row[data-hue="1"] .cat-tag { background: color-mix(in oklab, var(--accent-2) 16%, var(--bg-3)); border-color: color-mix(in oklab, var(--accent-2) 40%, var(--line)); }
.row[data-hue="2"] .cat-tag { background: color-mix(in oklab, var(--accent-3) 10%, var(--bg-3)); border-color: color-mix(in oklab, var(--accent-3) 28%, var(--line)); }
.row .cat-label {
  font-family: var(--font-mono);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--ink);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 18ch;
}
.row .chip {
  display: inline-block; padding: 4px 10px; border-radius: 999px;
  background: var(--bg); border: 1px solid var(--line);
  font-family: var(--font-mono); font-size: 10px; text-transform: uppercase; letter-spacing: 0.08em;
  color: var(--ink-dim);
}
.row .go { color: var(--ink-faint); font-size: 18px; transition: transform 0.2s, color 0.2s; text-align: right; }
.row:hover .go { color: var(--accent); transform: translateX(4px); }
@media (max-width: 960px) {
  .row {
    grid-template-columns: 1fr auto;
    grid-template-areas:
      "name  go"
      "desc  desc"
      "cat   chip";
    gap: 10px 12px;
    padding: 16px;
  }
  .row .num { display: none; }
  .row .name-box { grid-area: name; min-width: 0; }
  .row .desc { grid-area: desc; font-size: 13px; }
  .row .cat-tag { grid-area: cat; margin-top: 0; }
  .row > div:has(.chip) { grid-area: chip; justify-self: end; align-self: center; }
  .row .go { grid-area: go; align-self: center; }
  .row .name-title { font-size: 17px; }
  .row .cat-label { font-size: 10px; }
  .row .chip { font-size: 10px; padding: 4px 8px; }
}
@media (max-width: 520px) {
  .row {
    grid-template-areas:
      "name  go"
      "desc  desc"
      "cat   cat"
      "chip  chip";
  }
  .row > div:has(.chip) { justify-self: start; }
  .row .desc { display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
}

/* Mobile list toolbar stacks cleanly */
@media (max-width: 760px) {
  .list-toolbar { flex-direction: column; align-items: stretch; gap: 12px; }
  .list-toolbar .search { width: 100%; }
  .list-toolbar .sort { width: 100%; display: flex; }
  .list-toolbar .sort button { flex: 1; }
  .list-toolbar .count { text-align: left; font-size: 11px; }
}

/* ──────────── About Nick ──────────── */
.about-nick {
  display: grid; grid-template-columns: 420px 1fr; gap: 64px; align-items: center;
}
.about-nick .portrait {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  aspect-ratio: 4/5;
  background: var(--ink);
  border: 1px solid var(--line);
  box-shadow: 0 30px 60px -24px rgba(0,0,0,0.3);
}
.about-nick .portrait img { width: 100%; height: 100%; object-fit: cover; }
.about-nick .bio { color: var(--ink-dim); font-size: 18px; line-height: 1.6; }
.about-nick .bio p + p { margin-top: 14px; }
.about-nick .links { display: flex; gap: 10px; margin-top: 28px; flex-wrap: wrap; }
@media (max-width: 880px) {
  .about-nick { grid-template-columns: 1fr; gap: 32px; }
  .about-nick .portrait { max-width: 340px; margin: 0; }
}

/* ──────────── Sessions ──────────── */
.sessions { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
@media (max-width: 760px) { .sessions { grid-template-columns: 1fr; } }
.session {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 24px;
  background: var(--bg-3);
  display: flex; flex-direction: column; gap: 10px;
  transition: transform 0.2s, box-shadow 0.2s;
}
.section-dark .session { background: rgba(255,255,255,0.04); border-color: rgba(255,255,255,0.1); color: var(--bg); }
.session:hover { transform: translateY(-3px); border-color: var(--accent); box-shadow: 0 18px 40px -20px rgba(0,0,0,0.15); }
.session .sn { font-family: var(--font-mono); font-size: 11px; color: var(--accent); letter-spacing: 0.12em; text-transform: uppercase; }
.session h5 { font-family: var(--font-display); font-size: 22px; margin: 0; font-weight: 400; letter-spacing: -0.01em; }
.session .meta { font-family: var(--font-mono); font-size: 12px; color: var(--ink-dim); display: inline-flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.session .meta .meta-time { color: var(--ink); font-weight: 500; }
.session .meta .meta-sep { color: var(--ink-faint); }
.session .meta .meta-room { color: var(--ink-dim); }
.section-dark .session .meta { color: rgba(245,241,232,0.55); }
.section-dark .session .meta .meta-time { color: #ffffff; }
.section-dark .session .meta .meta-sep { color: rgba(245,241,232,0.4); }
.section-dark .session .meta .meta-room { color: rgba(245,241,232,0.7); }

/* ──────────── Sites row ──────────── */
.sites { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
@media (max-width: 780px) { .sites { grid-template-columns: 1fr; } }
.site {
  background: var(--bg-3);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 28px;
  display: flex; flex-direction: column; gap: 16px;
  min-height: 220px;
  transition: transform 0.2s, box-shadow 0.2s;
  position: relative; overflow: hidden;
}
.site:hover { transform: translateY(-3px); border-color: var(--accent); box-shadow: 0 18px 40px -20px rgba(0,0,0,0.15); }
.site .site-url { font-family: var(--font-mono); font-size: 11px; text-transform: uppercase; letter-spacing: 0.1em; color: var(--ink-faint); }
.site h4 { font-family: var(--font-display); font-size: 36px; font-weight: 400; margin: 0; letter-spacing: -0.02em; line-height: 1; }
.site h4 .italic { font-style: italic; color: var(--accent); }
.site p { color: var(--ink-dim); font-size: 14px; margin: 0; flex: 1; line-height: 1.5; }
.site .site-go { margin-top: auto; font-family: var(--font-mono); font-size: 12px; color: var(--ink); display: flex; align-items: center; gap: 6px; }

/* ──────────── Footer ──────────── */
.footer { padding: 72px 0 40px; color: rgba(245,241,232,0.7); background: var(--ink); }
.footer-top {
  display: grid; grid-template-columns: 1.5fr 1fr 1fr 1fr; gap: 40px; margin-bottom: 56px;
}
@media (max-width: 820px) { .footer-top { grid-template-columns: 1fr 1fr; } }
.footer h6 {
  font-family: var(--font-mono); font-size: 11px;
  color: rgba(245,241,232,0.55); text-transform: uppercase; letter-spacing: 0.12em;
  margin: 0 0 16px;
}
.footer .big {
  font-family: var(--font-display); font-size: clamp(40px,4.5vw,72px);
  line-height: 0.95; font-weight: 400; letter-spacing: -0.025em;
  color: var(--bg); margin: 0 0 16px;
}
.footer .big .italic { font-style: italic; color: var(--accent); }
.footer ul { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 10px; }
.footer ul a { color: rgba(245,241,232,0.7); }
.footer ul a:hover { color: var(--accent); }
.footer-bottom {
  display: flex; justify-content: space-between; align-items: center;
  padding-top: 28px; border-top: 1px solid rgba(255,255,255,0.1);
  font-family: var(--font-mono); font-size: 12px; color: rgba(245,241,232,0.55);
  flex-wrap: wrap; gap: 12px;
}

/* ──────────── Tweaks panel ──────────── */
.tweaks-panel {
  position: fixed; right: 20px; bottom: 20px; z-index: 100;
  background: var(--bg-3); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 18px; width: 280px;
  box-shadow: 0 24px 48px -16px rgba(0,0,0,0.25);
  display: none;
}
.tweaks-panel.open { display: block; }
.tweaks-panel h6 {
  font-family: var(--font-mono); font-size: 11px; color: var(--ink-faint);
  margin: 0 0 14px; text-transform: uppercase; letter-spacing: 0.12em;
}
.tweaks-panel .tw-group { margin-bottom: 16px; }
.tweaks-panel label { display: block; font-size: 12px; color: var(--ink-dim); margin-bottom: 8px; font-family: var(--font-mono); text-transform: uppercase; letter-spacing: 0.08em; }
.tweaks-panel .tw-row { display: flex; gap: 6px; flex-wrap: wrap; }
.tweaks-panel button {
  flex: 1; min-width: 0;
  background: var(--bg); color: var(--ink-dim);
  border: 1px solid var(--line); border-radius: 8px;
  padding: 9px 10px; font-size: 12px; cursor: pointer;
  font-family: var(--font-mono); text-transform: uppercase; letter-spacing: 0.04em;
}
.tweaks-panel button.active { background: var(--ink); color: var(--bg); border-color: var(--ink); }

/* ──────────── Utilities ──────────── */
.divider {
  height: 1px; background: var(--line); margin: 24px 0;
}
.spacer-24 { height: 24px; }
.spacer-48 { height: 48px; }

/* Decorative shape */
.blob {
  position: absolute;
  pointer-events: none;
  filter: blur(40px);
  opacity: 0.5;
}

/* Category page hero specifics */
.cat-hero-glyph {
  display: inline-flex; align-items: center; justify-content: center;
  width: 72px; height: 72px; border-radius: 20px;
  background: var(--ink); color: var(--bg);
  font-size: 36px;
  margin-bottom: 24px;
}

/* ──────────── CoolApps page — split type/stats ──────────── */
.coolapps-split {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 48px;
  align-items: start;
}
@media (max-width: 880px) { .coolapps-split { grid-template-columns: 1fr; gap: 32px; } }

.coolapps-lede {
  font-size: clamp(20px, 1.8vw, 26px);
  line-height: 1.45;
  color: var(--ink-2);
  font-family: var(--font-display);
  font-weight: 400;
  letter-spacing: -0.005em;
}
.coolapps-lede p { margin: 0 0 20px; }
.coolapps-lede p:last-child { margin-bottom: 0; }
.coolapps-lede strong {
  font-style: italic;
  color: var(--accent);
  font-weight: 400;
}
.coolapps-lede em {
  font-style: italic;
  color: var(--ink);
}

.coolapps-stats {
  display: flex; flex-direction: column; gap: 12px;
  border-left: 2px solid var(--ink);
  padding-left: 28px;
}
@media (max-width: 880px) {
  .coolapps-stats { border-left: none; padding-left: 0; border-top: 2px solid var(--ink); padding-top: 24px; flex-direction: row; flex-wrap: wrap; }
  .coolapps-stat { flex: 1; min-width: 120px; }
}
.coolapps-stat-num {
  font-family: var(--font-display);
  font-size: clamp(40px, 4.5vw, 64px);
  line-height: 1;
  letter-spacing: -0.02em;
  color: var(--accent);
  font-style: italic;
  margin-bottom: 6px;
}
.coolapps-stat-lbl {
  font-family: var(--font-mono);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--ink-dim);
}
.proof-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}
@media (max-width: 760px) { .proof-grid { grid-template-columns: 1fr; } }

.proof-card {
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: var(--radius);
  padding: 40px 36px 32px;
  min-height: 360px;
  display: flex; flex-direction: column;
  position: relative; overflow: hidden;
  transition: transform 0.25s, border-color 0.25s, background 0.25s;
}
.proof-card:hover {
  transform: translateY(-3px);
  border-color: var(--accent);
  background: rgba(215,127,60,0.08);
}
/* cream/light section fallback */
.section:not(.section-dark) .proof-card {
  background: var(--bg-3);
  border: 1px solid var(--line);
}
.section:not(.section-dark) .proof-card:hover {
  background: var(--bg);
  border-color: var(--accent);
  box-shadow: 0 22px 48px -20px rgba(0,0,0,0.18);
}

.proof-kicker {
  font-family: var(--font-mono);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--accent);
  margin-bottom: 4px;
}
.proof-num {
  font-family: var(--font-display);
  font-size: clamp(96px, 14vw, 220px);
  line-height: 0.88;
  letter-spacing: -0.04em;
  font-weight: 400;
  color: var(--bg);
  margin: 4px 0 20px;
  flex-shrink: 0;
}
.section:not(.section-dark) .proof-num { color: var(--ink); }
.proof-num em {
  font-style: italic;
  color: var(--accent);
}
.proof-num .proof-plus {
  font-style: italic;
  color: var(--accent);
  font-size: 0.55em;
  vertical-align: 0.25em;
  margin-left: 0.04em;
}
.proof-label {
  font-family: var(--font-body);
  font-size: clamp(18px, 1.6vw, 22px);
  line-height: 1.35;
  color: rgba(245,241,232,0.78);
  max-width: 32ch;
  margin-bottom: auto;
  text-wrap: balance;
}
.section:not(.section-dark) .proof-label { color: var(--ink-dim); }
.proof-label em {
  font-style: italic;
  color: var(--bg);
}
.section:not(.section-dark) .proof-label em { color: var(--ink); }
.proof-foot {
  margin-top: 24px;
  padding-top: 16px;
  border-top: 1px solid rgba(255,255,255,0.12);
  font-family: var(--font-mono);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: rgba(245,241,232,0.55);
}
.section:not(.section-dark) .proof-foot {
  border-top-color: var(--line);
  color: var(--ink-faint);
}
