/* =========================================================================
   Kai-Hamilton — Timeline Blog
   Type:  Space Grotesk (UI/headings) · Newsreader (body/long-read) · Space Mono (labels)
   ========================================================================= */

/* ---------- theme tokens ---------- */
:root{
  --font-head:'Space Grotesk',system-ui,sans-serif;
  --font-body:'Newsreader',Georgia,serif;
  --font-mono:'Space Mono','SFMono-Regular',ui-monospace,monospace;

  --accent: oklch(0.55 0.19 256);          /* primary, tweakable */
  --accent-ink: oklch(0.45 0.19 256);

  /* category hues — same L/C, varied hue, used only for dots + labels */
  --c-note:  var(--ink-3);
  --c-read:  oklch(0.62 0.13 80);
  --c-video: oklch(0.60 0.17 25);
  --c-photo: oklch(0.60 0.13 305);
  --c-music: oklch(0.62 0.15 345);
  --c-pod:   oklch(0.60 0.12 155);
  --c-book:  oklch(0.64 0.13 50);
  --c-link:  var(--accent);

  --maxw: 1100px;
  --text-measure: 600px;
  --media-w: 880px;          /* spacious by default */
  --radius: 14px;
  --rail-x: 132px;           /* distance from content edge to rail line */
}
[data-images="cozy"]{ --media-w: 660px; }

/* ---- light (paper) : default ---- */
:root,[data-theme="paper"]{
  --bg:      oklch(0.972 0.008 85);
  --surface: oklch(0.995 0.004 85);
  --surface-2: oklch(0.955 0.009 85);
  --ink:     oklch(0.24 0.012 60);
  --ink-2:   oklch(0.46 0.011 60);
  --ink-3:   oklch(0.63 0.010 60);
  --border:  oklch(0.89 0.010 78);
  --border-2:oklch(0.83 0.012 78);
  --rail:    oklch(0.30 0.012 60);
  --shadow: 0 1px 2px rgba(40,35,25,.05), 0 12px 30px -16px rgba(40,35,25,.22);
}
[data-theme="sepia"]{
  --bg:      oklch(0.945 0.022 75);
  --surface: oklch(0.975 0.016 78);
  --surface-2: oklch(0.925 0.024 73);
  --ink:     oklch(0.30 0.03 48);
  --ink-2:   oklch(0.46 0.028 50);
  --ink-3:   oklch(0.60 0.026 52);
  --border:  oklch(0.86 0.026 68);
  --border-2:oklch(0.80 0.03 66);
  --rail:    oklch(0.36 0.03 48);
  --shadow: 0 1px 2px rgba(70,45,20,.06), 0 12px 30px -16px rgba(70,45,20,.25);
}
[data-theme="dark"]{
  --bg:      oklch(0.205 0.012 264);
  --surface: oklch(0.245 0.014 264);
  --surface-2: oklch(0.285 0.016 264);
  --ink:     oklch(0.93 0.008 85);
  --ink-2:   oklch(0.74 0.010 85);
  --ink-3:   oklch(0.58 0.012 85);
  --border:  oklch(0.34 0.014 264);
  --border-2:oklch(0.42 0.016 264);
  --rail:    oklch(0.55 0.014 264);
  --accent:  oklch(0.70 0.15 256);
  --accent-ink: oklch(0.78 0.14 256);
  --shadow: 0 1px 2px rgba(0,0,0,.3), 0 16px 40px -18px rgba(0,0,0,.7);
}
[data-cat="off"]{
  --c-read:var(--ink-3);--c-video:var(--ink-3);--c-photo:var(--ink-3);
  --c-music:var(--ink-3);--c-pod:var(--ink-3);--c-book:var(--ink-3);--c-link:var(--ink-3);
}

*{box-sizing:border-box;}
html{scroll-behavior:smooth;}
body{
  margin:0;background:var(--bg);color:var(--ink);
  font-family:var(--font-body);font-size:19px;line-height:1.62;
  -webkit-font-smoothing:antialiased;text-rendering:optimizeLegibility;
  transition:background .3s ease,color .3s ease;
}
a{color:var(--accent);text-decoration:none;}
a:hover{text-decoration:underline;text-underline-offset:3px;text-decoration-thickness:1.5px;}
img{display:block;max-width:100%;}

/* ---------- top bar ---------- */
.nav{
  position:sticky;top:0;z-index:40;background:color-mix(in oklab,var(--bg) 86%,transparent);
  -webkit-backdrop-filter:blur(12px) saturate(140%);backdrop-filter:blur(12px) saturate(140%);
  border-bottom:1px solid transparent;transition:border-color .25s ease;
}
.nav.scrolled{border-bottom-color:var(--border);}
.nav-in{max-width:var(--maxw);margin:0 auto;padding:14px 28px;display:flex;align-items:center;gap:18px;}
.wordmark{font-family:var(--font-mono);font-size:13px;letter-spacing:.02em;color:var(--ink-2);display:flex;align-items:center;gap:9px;}
.wordmark .dot{width:8px;height:8px;border-radius:50%;background:var(--accent);box-shadow:0 0 0 3px color-mix(in oklab,var(--accent) 22%,transparent);}
.wordmark b{color:var(--ink);font-weight:700;letter-spacing:.04em;}
.nav-links{margin-left:auto;display:flex;gap:6px;align-items:center;flex-wrap:wrap;justify-content:flex-end;font-family:var(--font-head);}
.nav-links a{color:var(--ink-2);font-size:14.5px;font-weight:500;padding:7px 13px;border-radius:9px;transition:background .15s,color .15s;}
.nav-links a:hover{background:var(--surface-2);color:var(--ink);text-decoration:none;}
.nav-rss{display:inline-flex;width:34px;height:34px;align-items:center;justify-content:center;border-radius:9px;color:var(--ink-2);}
.nav-rss:hover{background:var(--surface-2);color:var(--accent);}

/* ---------- identity hero ---------- */
.hero{max-width:var(--maxw);margin:0 auto;padding:62px 28px 30px;text-align:center;}
.hero image-slot{width:108px;height:108px;margin:0 auto 22px;border-radius:50%;box-shadow:0 0 0 1px var(--border),0 8px 26px -12px rgba(0,0,0,.4);}
.hero h1{font-family:var(--font-head);font-weight:700;font-size:clamp(36px,5vw,54px);letter-spacing:-.02em;line-height:1;margin:0 0 14px;}
.hero .tagline{font-size:20px;color:var(--ink-2);max-width:540px;margin:0 auto;line-height:1.5;}
.hero .meta{margin-top:18px;display:flex;gap:7px 18px;justify-content:center;flex-wrap:wrap;font-family:var(--font-mono);font-size:12.5px;color:var(--ink-3);text-transform:uppercase;letter-spacing:.08em;}
.hero .meta span{display:inline-flex;align-items:center;gap:6px;}
.hero .meta i{width:5px;height:5px;border-radius:50%;background:var(--c-pod);font-style:normal;}

/* ---------- filter chips ---------- */
.filters{max-width:var(--maxw);margin:0 auto;padding:14px 28px 8px;display:flex;gap:8px;justify-content:center;flex-wrap:wrap;position:sticky;top:62px;z-index:30;}
.chip{
  font-family:var(--font-head);font-size:13.5px;font-weight:500;cursor:pointer;
  border:1px solid var(--border-2);background:var(--surface);color:var(--ink-2);
  padding:7px 15px;border-radius:999px;transition:all .15s ease;display:inline-flex;align-items:center;gap:7px;
}
.chip:hover{color:var(--ink);border-color:var(--ink-3);}
.chip[aria-pressed="true"]{background:var(--ink);color:var(--bg);border-color:var(--ink);}
.chip .ct{font-family:var(--font-mono);font-size:11px;opacity:.65;}

/* =========================================================================
   TIMELINE
   ========================================================================= */
.timeline{max-width:var(--maxw);margin:0 auto;padding:26px 28px 40px;}
.tl{position:relative;padding-left:var(--rail-x);}
.tl::before{content:"";position:absolute;left:calc(var(--rail-x) - 38px);top:14px;bottom:40px;width:2px;
  background:linear-gradient(var(--border-2),var(--border-2));}
.entry{position:relative;margin-bottom:54px;scroll-margin-top:120px;}
.entry.is-hidden{display:none;}

.entry .date{position:absolute;left:calc(-1 * var(--rail-x));top:2px;width:88px;text-align:right;
  font-family:var(--font-mono);font-size:13px;line-height:1.25;color:var(--ink-2);padding-right:10px;}
.entry .date b{display:block;color:var(--ink);font-weight:700;font-size:15px;}
.entry .date small{display:block;font-size:11px;color:var(--ink-3);}
.entry .node{position:absolute;left:calc(-1 * var(--rail-x) + 88px + 0.5px);top:5px;width:13px;height:13px;border-radius:50%;
  background:var(--surface);border:2.5px solid var(--dot,var(--ink-3));box-shadow:0 0 0 4px var(--bg);z-index:1;}

.entry[data-type="note"]   .node{--dot:var(--c-note);}
.entry[data-type="read"]   .node{--dot:var(--c-read);}
.entry[data-type="video"]  .node{--dot:var(--c-video);}
.entry[data-type="photo"]  .node{--dot:var(--c-photo);}
.entry[data-type="music"]  .node{--dot:var(--c-music);}
.entry[data-type="podcast"].node,.entry[data-type="podcast"] .node{--dot:var(--c-pod);}
.entry[data-type="book"]   .node{--dot:var(--c-book);}
.entry[data-type="link"]   .node{--dot:var(--c-link);}

/* kicker label per type */
.kicker{font-family:var(--font-mono);font-size:11.5px;font-weight:700;letter-spacing:.12em;text-transform:uppercase;
  display:inline-flex;align-items:center;gap:7px;margin-bottom:10px;color:var(--kc,var(--ink-3));}
.kicker .gl{font-size:13px;}
.entry[data-type="read"]   .kicker{--kc:var(--c-read);}
.entry[data-type="video"]  .kicker{--kc:var(--c-video);}
.entry[data-type="photo"]  .kicker{--kc:var(--c-photo);}
.entry[data-type="music"]  .kicker{--kc:var(--c-music);}
.entry[data-type="podcast"] .kicker{--kc:var(--c-pod);}
.entry[data-type="book"]   .kicker{--kc:var(--c-book);}
.entry[data-type="link"]   .kicker{--kc:var(--c-link);}

/* text posts sit in a comfy measure; media breaks wider */
.measure{max-width:var(--text-measure);}
.media{max-width:var(--media-w);transition:max-width .3s ease;}
.entry p{margin:0 0 .7em;}
.entry p:last-child{margin-bottom:0;}
.body-text{font-size:19.5px;line-height:1.6;}

/* permalink time on hover */
.permalink{font-family:var(--font-mono);font-size:11.5px;color:var(--ink-3);text-transform:uppercase;letter-spacing:.08em;
  margin-top:12px;display:inline-block;opacity:0;transition:opacity .2s;}
.entry:hover .permalink{opacity:1;}
.permalink:hover{color:var(--accent);text-decoration:none;}

/* ---------- LINK card ---------- */
.linkcard{display:flex;border:1px solid var(--border);border-radius:var(--radius);overflow:hidden;background:var(--surface);box-shadow:var(--shadow);margin-top:4px;}
.linkcard .lc-text{padding:16px 18px;flex:1;min-width:0;}
.linkcard .lc-src{font-family:var(--font-mono);font-size:11px;text-transform:uppercase;letter-spacing:.1em;color:var(--ink-3);}
.linkcard .lc-title{font-family:var(--font-head);font-weight:600;font-size:18px;line-height:1.25;margin:5px 0 0;color:var(--ink);}
.linkcard image-slot{width:148px;flex:none;align-self:stretch;border-radius:0;}
.linkcard:hover{border-color:var(--border-2);}

/* ---------- BOOK ---------- */
.book{display:flex;gap:20px;align-items:flex-start;}
.book image-slot{width:96px;height:142px;flex:none;box-shadow:0 10px 26px -10px rgba(0,0,0,.45);border-radius:4px;}
.book .stars{color:var(--c-book);letter-spacing:2px;font-size:14px;}
.book .b-meta{font-family:var(--font-mono);font-size:12px;color:var(--ink-3);margin:4px 0 10px;}
.book h3{font-family:var(--font-head);font-weight:700;font-size:24px;margin:2px 0 0;letter-spacing:-.01em;}

/* featured "book of the year" */
.entry.featured .media{max-width:760px;}
.book-feature{display:grid;grid-template-columns:158px 1fr;gap:26px;align-items:start;
  background:var(--surface);border:1px solid var(--border);border-radius:var(--radius);
  padding:24px;box-shadow:var(--shadow);position:relative;overflow:hidden;}
.book-feature::before{content:"";position:absolute;left:0;top:0;bottom:0;width:4px;background:var(--c-book);}
.book-feature image-slot{width:158px;height:236px;border-radius:6px;box-shadow:0 14px 34px -12px rgba(0,0,0,.5);}
.book-feature h2{font-family:var(--font-head);font-weight:700;font-size:30px;line-height:1.02;letter-spacing:-.02em;margin:2px 0 0;}
.book-feature .b-meta{font-family:var(--font-mono);font-size:12px;color:var(--ink-3);margin:6px 0 12px;text-transform:uppercase;letter-spacing:.06em;}
.book-feature p{font-size:18px;line-height:1.6;margin:0 0 14px;color:var(--ink);}
.booklink{font-family:var(--font-head);font-weight:600;font-size:15px;}
.entry.featured .kicker{color:var(--c-book);}
@media(max-width:640px){.book-feature{grid-template-columns:1fr;}.book-feature image-slot{width:130px;height:194px;}}

/* ---------- LONG READ / article ---------- */
.article{border:1px solid var(--border);border-radius:var(--radius);overflow:hidden;background:var(--surface);box-shadow:var(--shadow);}
.article image-slot.hero-img{width:100%;height:300px;border-radius:0;display:block;}
.article .art-body{padding:26px 30px 30px;}
.article h2{font-family:var(--font-head);font-weight:700;font-size:32px;line-height:1.05;letter-spacing:-.02em;margin:6px 0 6px;}
.article .art-meta{font-family:var(--font-mono);font-size:12px;color:var(--ink-3);text-transform:uppercase;letter-spacing:.08em;}
.article .excerpt{font-size:20px;line-height:1.6;margin-top:14px;color:var(--ink);}
.article .full{display:none;}
.article.open .full{display:block;animation:fade .35s ease;}
.article .full p{font-size:20px;line-height:1.66;}
.article .full p:first-letter{}
.article .full .dropcap:first-letter{float:left;font-family:var(--font-head);font-weight:700;font-size:62px;line-height:.78;padding:6px 10px 0 0;color:var(--accent);}
.article .pullquote{font-family:var(--font-head);font-weight:600;font-size:24px;line-height:1.3;color:var(--ink);border-left:3px solid var(--accent);padding:4px 0 4px 20px;margin:22px 0;letter-spacing:-.01em;}
.article .figure{margin:22px 0;}
.article .figure image-slot{width:100%;height:240px;border-radius:8px;}
.article .figure figcaption{font-family:var(--font-mono);font-size:11.5px;color:var(--ink-3);margin-top:8px;text-align:center;letter-spacing:.04em;}
.read-btn{margin-top:18px;font-family:var(--font-head);font-weight:600;font-size:15px;color:var(--ink);background:var(--surface-2);
  border:1px solid var(--border-2);padding:9px 18px;border-radius:10px;cursor:pointer;display:inline-flex;align-items:center;gap:8px;transition:all .15s;}
.read-btn:hover{border-color:var(--ink-3);background:var(--bg);}
.read-btn .arr{transition:transform .2s;}
.article.open .read-btn .arr{transform:rotate(90deg);}
@keyframes fade{from{opacity:0;transform:translateY(8px);}to{opacity:1;transform:none;}}

/* ---------- PHOTO gallery ---------- */
.gallery{display:grid;grid-template-columns:1.5fr 1fr;gap:10px;}
.gallery image-slot{width:100%;height:100%;border-radius:10px;}
.gallery .tall{grid-row:span 2;height:auto;min-height:300px;}
.gallery .stack{display:grid;gap:10px;}
.gallery .stack image-slot{height:145px;}
.caption{font-family:var(--font-mono);font-size:12px;color:var(--ink-3);margin-top:10px;letter-spacing:.02em;}

/* =========================================================================
   PLAYERS (podcast / youtube music / youtube video)
   ========================================================================= */
.player{border:1px solid var(--border);border-radius:var(--radius);background:var(--surface);box-shadow:var(--shadow);overflow:hidden;}

/* shared transport */
.pbtn{width:46px;height:46px;border-radius:50%;border:none;cursor:pointer;flex:none;display:flex;align-items:center;justify-content:center;
  background:var(--ink);color:var(--bg);transition:transform .12s,background .2s;}
.pbtn:hover{transform:scale(1.05);}
.pbtn:active{transform:scale(.96);}
.pbtn svg{width:18px;height:18px;}
.scrub{height:5px;border-radius:3px;background:var(--border-2);position:relative;cursor:pointer;flex:1;}
.scrub .fill{position:absolute;left:0;top:0;bottom:0;width:0%;background:var(--pcolor,var(--accent));border-radius:3px;}
.scrub .knob{position:absolute;top:50%;left:0%;width:12px;height:12px;border-radius:50%;background:var(--surface);border:2px solid var(--pcolor,var(--accent));transform:translate(-50%,-50%);}
.time{font-family:var(--font-mono);font-size:11.5px;color:var(--ink-3);white-space:nowrap;}

/* podcast */
.pl-pod{display:flex;gap:16px;padding:16px;align-items:center;border-left:4px solid var(--c-pod);--pcolor:var(--c-pod);}
.pl-pod image-slot{width:62px;height:62px;flex:none;border-radius:8px;}
.pl-pod .meta-row{display:flex;align-items:center;gap:7px;font-family:var(--font-mono);font-size:10.5px;letter-spacing:.08em;text-transform:uppercase;color:var(--c-pod);}
.pl-pod h4{font-family:var(--font-head);font-weight:600;font-size:16.5px;margin:3px 0 0;color:var(--ink);line-height:1.2;}
.pl-pod .controls{display:flex;align-items:center;gap:12px;margin-top:10px;}
.speed{font-family:var(--font-mono);font-size:11px;border:1px solid var(--border-2);border-radius:7px;padding:2px 7px;color:var(--ink-2);cursor:pointer;background:none;}

/* youtube music */
.pl-music{display:flex;gap:16px;padding:16px;align-items:center;border-left:4px solid var(--c-music);--pcolor:var(--c-music);}
.pl-music image-slot{width:74px;height:74px;flex:none;border-radius:8px;}
.pl-music .src{font-family:var(--font-mono);font-size:10.5px;letter-spacing:.08em;text-transform:uppercase;color:var(--c-music);display:flex;align-items:center;gap:6px;}
.pl-music h4{font-family:var(--font-head);font-weight:600;font-size:17px;margin:3px 0 0;color:var(--ink);line-height:1.2;}
.pl-music .artist{font-size:15px;color:var(--ink-2);font-family:var(--font-body);}
.pl-music .controls{display:flex;align-items:center;gap:12px;margin-top:11px;}
.pl-music .tbtn{background:none;border:none;cursor:pointer;color:var(--ink-2);padding:2px;display:flex;}
.pl-music .tbtn:hover{color:var(--ink);}
.pl-music .tbtn svg{width:17px;height:17px;}
.pl-music .pbtn{width:38px;height:38px;}
.pl-music .pbtn svg{width:14px;height:14px;}

/* youtube video facade */
.pl-video{--pcolor:var(--c-video);}
.yt-screen{position:relative;aspect-ratio:16/9;background:#0c0c0d;cursor:pointer;overflow:hidden;}
.yt-screen img{width:100%;height:100%;object-fit:cover;opacity:.92;transition:opacity .2s,transform .4s;}
.yt-screen:hover img{opacity:1;transform:scale(1.02);}
.yt-screen .scrim{position:absolute;inset:0;background:linear-gradient(transparent 40%,rgba(0,0,0,.55));}
.yt-play{position:absolute;left:50%;top:50%;transform:translate(-50%,-50%);width:74px;height:52px;border-radius:13px;
  background:var(--c-video);display:flex;align-items:center;justify-content:center;box-shadow:0 6px 20px rgba(0,0,0,.4);transition:transform .15s;}
.yt-screen:hover .yt-play{transform:translate(-50%,-50%) scale(1.08);}
.yt-play::after{content:"";border-left:20px solid #fff;border-top:12px solid transparent;border-bottom:12px solid transparent;margin-left:5px;}
.yt-badge{position:absolute;top:12px;left:12px;font-family:var(--font-mono);font-size:10.5px;font-weight:700;letter-spacing:.1em;color:#fff;background:var(--c-video);padding:3px 8px;border-radius:5px;}
.yt-dur{position:absolute;bottom:12px;right:12px;font-family:var(--font-mono);font-size:11px;color:#fff;background:rgba(0,0,0,.7);padding:2px 7px;border-radius:4px;}
.yt-cap{padding:14px 16px;border-top:1px solid var(--border);}
.yt-cap h4{font-family:var(--font-head);font-weight:600;font-size:17px;margin:0;color:var(--ink);line-height:1.25;}
.yt-cap .ch{font-family:var(--font-mono);font-size:11.5px;color:var(--ink-3);margin-top:5px;text-transform:uppercase;letter-spacing:.06em;}
.yt-screen iframe{width:100%;height:100%;border:0;display:block;}

/* ---------- footer ---------- */
.foot{max-width:var(--maxw);margin:0 auto;padding:30px 28px 70px;border-top:1px solid var(--border);
  display:flex;gap:18px;align-items:center;flex-wrap:wrap;font-family:var(--font-mono);font-size:12px;color:var(--ink-3);text-transform:uppercase;letter-spacing:.06em;}
.foot a{color:var(--ink-2);}
.foot .sp{margin-left:auto;}

/* end-of-feed marker */
.tl-end{position:relative;font-family:var(--font-mono);font-size:12px;color:var(--ink-3);letter-spacing:.1em;text-transform:uppercase;padding-left:4px;}
.tl-end::before{content:"";position:absolute;left:calc(-1 * var(--rail-x) + 88px + 0.5px);top:3px;width:13px;height:13px;border-radius:50%;background:var(--border-2);box-shadow:0 0 0 4px var(--bg);}

/* =========================================================================
   BOOKS PAGE
   ========================================================================= */
.page-head{max-width:var(--maxw);margin:0 auto;padding:54px 28px 8px;}
.page-head .eyebrow{font-family:var(--font-mono);font-size:12px;letter-spacing:.14em;text-transform:uppercase;color:var(--accent);}
.page-head h1{font-family:var(--font-head);font-weight:700;font-size:clamp(34px,5vw,52px);letter-spacing:-.02em;line-height:1;margin:10px 0 0;}
.page-head p{font-size:19px;color:var(--ink-2);max-width:620px;margin:14px 0 0;line-height:1.55;}

.shelf{max-width:var(--maxw);margin:0 auto;padding:34px 28px;}
.shelf h2{font-family:var(--font-head);font-weight:700;font-size:15px;letter-spacing:.02em;color:var(--ink);
  display:flex;align-items:center;gap:12px;margin:0 0 22px;text-transform:none;}
.shelf h2::before{content:"";font-family:var(--font-mono);}
.shelf h2 .lbl{font-family:var(--font-mono);font-size:12px;font-weight:700;letter-spacing:.12em;text-transform:uppercase;color:var(--ink-3);}
.shelf h2 .rule{flex:1;height:1px;background:var(--border);}
.shelf h2 .ct{font-family:var(--font-mono);font-size:12px;color:var(--ink-3);font-weight:400;}

.shelf-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(150px,1fr));gap:30px 26px;}
.book-card{display:flex;flex-direction:column;gap:12px;}
.book-card .cover{position:relative;aspect-ratio:2/3;border-radius:6px;overflow:hidden;background:var(--surface-2);
  box-shadow:0 12px 28px -12px rgba(0,0,0,.5),0 0 0 1px var(--border);transition:transform .2s ease,box-shadow .2s ease;}
.book-card .cover img{width:100%;height:100%;object-fit:cover;display:block;}
.book-card:hover .cover{transform:translateY(-4px);box-shadow:0 20px 38px -14px rgba(0,0,0,.55),0 0 0 1px var(--border-2);}
.book-card .bc-title{font-family:var(--font-head);font-weight:600;font-size:16.5px;line-height:1.2;color:var(--ink);text-decoration:none;}
.book-card:hover .bc-title{text-decoration:underline;text-underline-offset:3px;}
.book-card .bc-author{font-size:15px;color:var(--ink-2);font-family:var(--font-body);font-style:italic;margin-top:-4px;}

/* anime: score + meta on covers */
.cover .score-badge{position:absolute;bottom:8px;right:8px;font-family:var(--font-mono);font-size:11px;font-weight:700;
  color:#fff;background:rgba(0,0,0,.72);-webkit-backdrop-filter:blur(4px);backdrop-filter:blur(4px);
  padding:3px 7px;border-radius:6px;display:flex;align-items:center;gap:3px;}
.cover .score-badge .st{color:#ffd34d;}
.book-card .bc-sub{font-family:var(--font-mono);font-size:11.5px;color:var(--ink-3);text-transform:uppercase;letter-spacing:.06em;margin-top:-2px;}
.shelf .loading,.shelf .errbox{font-family:var(--font-mono);font-size:13px;color:var(--ink-3);padding:8px 0;}
.shelf .errbox a{color:var(--accent);}
/* skeleton shimmer */
.sk{aspect-ratio:2/3;border-radius:6px;background:linear-gradient(100deg,var(--surface-2) 30%,var(--border) 50%,var(--surface-2) 70%);
  background-size:200% 100%;animation:shimmer 1.3s infinite;}
@keyframes shimmer{from{background-position:200% 0;}to{background-position:-200% 0;}}

/* =========================================================================
   POPULATED FEED — real images (rendered from feed.js)
   ========================================================================= */
.hero img.avatar{width:108px;height:108px;object-fit:cover;border-radius:50%;margin:0 auto 22px;display:block;
  box-shadow:0 0 0 1px var(--border),0 8px 26px -12px rgba(0,0,0,.4);}

/* single photo */
.p-single{display:block;width:auto;max-width:100%;max-height:560px;border-radius:12px;
  border:1px solid var(--border);box-shadow:var(--shadow);background:var(--surface-2);}
.p-single.land{width:100%;max-height:none;}
.p-poster{display:block;width:auto;height:300px;border-radius:8px;border:1px solid var(--border);box-shadow:var(--shadow);background:var(--surface-2);}

/* photo grids */
.p-grid{display:grid;gap:8px;}
.p-grid img{width:100%;height:215px;object-fit:cover;border-radius:10px;border:1px solid var(--border);background:var(--surface-2);}
.p-grid.g2{grid-template-columns:1fr 1fr;}
.p-grid.g2 img{height:300px;}
.p-grid.g3{grid-template-columns:repeat(3,1fr);}
.p-grid.g4{grid-template-columns:repeat(2,1fr);}
.p-grid.g4 img{height:240px;}
.p-grid.g5,.p-grid.g6{grid-template-columns:repeat(3,1fr);}

/* inline figure inside a note (e.g. text screenshots) */
.p-figure{margin:12px 0 0;max-width:440px;}
.p-figure img{width:100%;border-radius:10px;border:1px solid var(--border);box-shadow:var(--shadow);}

/* video file */
.p-videofile video{width:100%;border-radius:12px;display:block;background:#000;border:1px solid var(--border);}

/* book entries (real covers) */
.book img.b-cover{width:96px;height:142px;object-fit:cover;flex:none;border-radius:4px;
  box-shadow:0 10px 26px -10px rgba(0,0,0,.45);background:var(--surface-2);}
.book-feature img.bf-cover{width:158px;height:236px;object-fit:cover;border-radius:6px;
  box-shadow:0 14px 34px -12px rgba(0,0,0,.5);background:var(--surface-2);}
@media(max-width:640px){.book-feature img.bf-cover{width:130px;height:194px;}}

/* link card thumb */
.linkcard img.lc-thumb{width:148px;flex:none;align-self:stretch;object-fit:cover;background:var(--surface-2);}
.lc-thumb-sk{width:148px;flex:none;align-self:stretch;background:linear-gradient(100deg,var(--surface-2) 30%,var(--border) 50%,var(--surface-2) 70%);background-size:200% 100%;animation:shimmer 1.3s infinite;}

/* article hero (real) */
.article img.hero-img{width:100%;height:300px;object-fit:cover;display:block;background:var(--surface-2);}
.article .gameshot{width:100%;border-radius:8px;border:1px solid var(--border);margin:18px 0 4px;display:block;}
.article .bestlist{margin:0 0 10px;padding-left:1.1em;}
.article .bestlist li{font-size:18px;line-height:1.5;margin:2px 0;}
.article .bestlist+h4,.article h4.bl-h{font-family:var(--font-head);font-weight:700;font-size:17px;margin:20px 0 8px;letter-spacing:-.01em;}

@media(max-width:760px){
  .p-grid.g3,.p-grid.g5,.p-grid.g6{grid-template-columns:1fr 1fr;}
  .p-grid img{height:150px;}
  .p-grid.g2 img{height:200px;}
}

/* quote / blockquote entries */
.q-block{font-family:var(--font-body);font-size:20px;line-height:1.5;color:var(--ink);
  border-left:3px solid var(--accent);padding:2px 0 2px 20px;margin:4px 0 0;}
.q-block.de{font-style:normal;}
.q-title{font-family:var(--font-head);font-weight:700;font-size:22px;letter-spacing:-.01em;margin:0 0 12px;color:var(--ink);}
.q-cite{font-family:var(--font-mono);font-size:12px;color:var(--ink-3);margin-top:12px;display:inline-block;}

/* ---------- responsive ---------- */
@media(max-width:760px){
  body{font-size:18px;}
  :root{--rail-x:54px;}
  .tl::before{left:6px;}
  .entry .date{position:relative;left:0;top:0;width:auto;text-align:left;margin-bottom:8px;display:flex;gap:8px;align-items:baseline;}
  .entry .date b{display:inline;}
  .entry .node{left:calc(-1 * var(--rail-x) + 3px);top:4px;}

  /* nav: two-row layout — wordmark top, links scroll below */
  .nav-in{padding:10px 16px 0;flex-wrap:wrap;gap:0;align-items:center;}
  .wordmark{padding-bottom:4px;}
  .nav-links{
    margin-left:0;width:100%;
    overflow-x:auto;flex-wrap:nowrap;
    padding-bottom:8px;gap:2px;
    scrollbar-width:none;-webkit-overflow-scrolling:touch;
  }
  .nav-links::-webkit-scrollbar{display:none;}
  .nav-links a{white-space:nowrap;font-size:13px;padding:5px 10px;}
  .nav-rss{margin-left:4px;}

  .hero{padding-top:42px;}
  .gallery{grid-template-columns:1fr;}
  .gallery .tall{grid-row:auto;min-height:240px;}
  .article image-slot.hero-img{height:200px;}
  .filters{top:80px;}
}
