/* ==========================================================================
   Blog (/blog, /blog/<post>) and the owner's page (/admin).
   Loaded after styles.css; pages are rendered by src/worker.js.
   ========================================================================== */
.page-blog main { background: #18110d; }
.page-blog [hidden] { display: none !important; }
/* the nav has one more link here: on phones Work goes too (Artwork, Blog, Contact stay) */
@media (max-width: 560px) { .page-blog .nav a.nav-sec { display: none; } }
.blog, .post {
  position: relative; isolation: isolate; min-height: 100svh;
  padding: calc(var(--section) * .6 + 40px) 0 var(--section);
}
.blog::before, .post::before {
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background:
    var(--patina) right -280px top -60px / 680px no-repeat,
    var(--patina) left -340px bottom -220px / 760px no-repeat;
}
.blog-empty { margin-top: 40px; font-size: var(--t-lede); color: var(--muted); }

/* the list: paper cards, a slight tilt each, like the postcards on the wall */
.post-list {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 340px), 1fr));
  gap: clamp(36px, 5vw, 64px); margin-top: clamp(40px, 5vw, 64px); align-items: start;
}
.post-card { --rot: -1.2deg; }
.post-card:nth-child(3n+2) { --rot: 1deg; }
.post-card:nth-child(3n) { --rot: -.6deg; }
.post-card a {
  display: flex; flex-direction: column; gap: 6px;
  padding: 14px 14px 20px; color: var(--paper-ink); text-decoration: none;
  background: var(--stain-a) right -150px bottom -160px / 300px no-repeat, var(--paper);
  border: var(--ink-line); box-shadow: 10px 12px 0 var(--ink-deep);
  transform: rotate(var(--rot)); transition: transform .25s var(--ease-out), box-shadow .25s var(--ease-out);
}
.post-card:nth-child(even) a { background: var(--stain-b) left -170px top -150px / 320px no-repeat, var(--paper); }
.post-card a:hover { transform: rotate(0) translate(-3px, -3px); box-shadow: 13px 15px 0 var(--ink-deep); }
.post-card a:focus-visible { outline-color: var(--toxic); }
.post-card img { display: block; width: 100%; aspect-ratio: 4 / 3; object-fit: cover; height: auto; border: var(--ink-line); background: var(--ink-3); margin-bottom: 8px; }
.post-card.is-portrait img { aspect-ratio: 4 / 5; } /* a portrait upload keeps more of the piece (item 12) */
.post-meta { font-family: var(--f-mono); font-weight: 700; font-size: .9rem; letter-spacing: .12em; text-transform: uppercase; color: var(--oxblood); }
.post-title { font-family: var(--f-display); font-weight: 900; font-size: var(--t-card); line-height: .95; letter-spacing: .02em; text-transform: uppercase; overflow-wrap: anywhere; }
.post-excerpt { font-family: var(--f-serif); font-size: 1.2rem; line-height: 1.35; color: var(--paper-soft); font-weight: 500; }

/* Posts / Photo wall switch */
.view-toggle { display: inline-flex; margin-top: clamp(32px, 4vw, 48px); border: var(--ink-line); box-shadow: 5px 5px 0 var(--blood); }
.view-toggle button {
  min-height: 48px; padding: 0 1.25rem; border: 0; background: var(--bone); color: var(--ink-deep); cursor: pointer;
  font-family: var(--f-ui); font-weight: 700; font-size: 1.05rem; letter-spacing: .12em; text-transform: uppercase;
}
.view-toggle button + button { border-left: var(--ink-line); }
.view-toggle button[aria-pressed="true"] { background: var(--toxic); }
.view-toggle button:hover { background: var(--toxic); }
.view-toggle button:focus-visible { outline: 3px solid var(--bone); outline-offset: 3px; }
.view-toggle + .post-list { margin-top: clamp(32px, 4vw, 48px); }

/* the photo wall: large postcards, each one opens its post */
/* two styles, switched by .is-2d / .is-3d on ul.collage (WALL_JS in src/worker.js): a dense grid of big tiles,
   or a tunnel of photos drifting toward the viewer. Captions show on hover, always on touch screens */
.dim-toggle { display: inline-flex; margin: clamp(32px, 4vw, 48px) 0 0 14px; border: var(--ink-line); box-shadow: 5px 5px 0 var(--blood); vertical-align: top; }
.dim-toggle button { min-height: 48px; padding: 0 1rem; border: 0; background: var(--bone); color: var(--ink-deep); cursor: pointer; font-family: var(--f-ui); font-weight: 700; font-size: 1.05rem; letter-spacing: .12em; text-transform: uppercase; }
.dim-toggle button + button { border-left: var(--ink-line); }
.dim-toggle button[aria-pressed="true"], .dim-toggle button:hover { background: var(--toxic); }
.dim-toggle button:focus-visible { outline: 3px solid var(--bone); outline-offset: 3px; }
.wall-hint { margin-top: 14px; font-family: var(--f-mono); font-size: .8rem; letter-spacing: .12em; text-transform: uppercase; color: var(--bone); opacity: .7; }
.dim-toggle[hidden], .wall-hint[hidden] { display: none; }
@media (max-width: 480px) { .wall-tools-row { gap: 10px; } }
.collage { list-style: none; padding: 0; margin: clamp(24px, 3vw, 36px) 0 0; }
.collage li { margin: 0; }
.collage a { display: block; position: relative; color: var(--paper); text-decoration: none; background: #2a211b; border: var(--ink-line); overflow: hidden; } /* lighter than the page while a photo loads */
.collage a:focus-visible { outline: 3px solid var(--toxic); outline-offset: 3px; }
.collage img { display: block; width: 100%; height: 100%; object-fit: cover; }
.collage .pc-cap { position: absolute; left: 0; right: 0; bottom: 0; padding: 18px 14px 30px; font-family: var(--f-display); font-weight: 900; font-size: 1.3rem; line-height: 1; letter-spacing: .02em; text-transform: uppercase; background: linear-gradient(transparent, rgba(11, 8, 6, .85)); overflow-wrap: anywhere; }
.collage .pc-date { position: absolute; left: 14px; bottom: 11px; font-family: var(--f-mono); font-size: .72rem; letter-spacing: .12em; text-transform: uppercase; color: var(--toxic); }
.collage .pc-cap, .collage .pc-date { opacity: 0; transform: translateY(8px); transition: opacity .25s, transform .25s var(--ease-out); }
.collage a:hover .pc-cap, .collage a:hover .pc-date, .collage a:focus-visible .pc-cap, .collage a:focus-visible .pc-date { opacity: 1; transform: none; }
@media (hover: none) { .collage .pc-cap, .collage .pc-date { opacity: 1; transform: none; } }
.collage .pc-cap:empty { display: none; }
/* the wall sits outside the page column and spans the window (owner's request: larger scale) */
.wall-2d { padding-inline: clamp(12px, 2vw, 32px); padding-bottom: clamp(32px, 5vw, 64px); }
/* Photo wall view: the heading steps aside and one compact toolbar (view, 2D / 3D, zoom or size, full screen)
   sits right under the site header, so almost the whole window is the gallery */
section.blog.is-wall > .wrap { display: none; }
section.blog.is-wall { padding-top: calc(var(--nav-h, 70px) + 12px); }
.wall-tools { max-width: var(--max, 1240px); margin: 0 auto 12px; }
.wall-tools-row { display: flex; flex-wrap: nowrap; align-items: center; gap: 8px; min-height: 44px; }
.wall-tools .view-toggle, .wall-tools .dim-toggle { flex: none; margin: 0; box-shadow: 3px 3px 0 var(--blood); }
.wall-tools .view-toggle button, .wall-tools .dim-toggle button, .wall-fs { min-height: 44px; padding: 0 .75rem; font-size: .9rem; letter-spacing: .1em; }
.wall-tools .zoom-bar { flex: 1 1 auto; min-width: 60px; max-width: 420px; margin: 0; gap: 8px; }
.wall-tools .zoom-bar input { min-width: 0; }
.wt-short { display: none; }
.wall-fs { flex: none; display: inline-flex; align-items: center; gap: 8px; border: var(--ink-line); background: var(--bone); color: var(--ink-deep); box-shadow: 3px 3px 0 var(--blood); cursor: pointer; font-family: var(--f-ui); font-weight: 700; text-transform: uppercase; }
.wall-fs:hover, .wall-fs[aria-pressed="true"] { background: var(--toxic); }
.wall-fs:focus-visible { outline: 3px solid var(--bone); outline-offset: 3px; }
.wall-fs .fs-out, .wall-fs[aria-pressed="true"] .fs-in { display: none; }
.wall-fs[aria-pressed="true"] .fs-out { display: inline; }
/* the row (owner's order): the view and 2D / 3D switches on the left, the sliders in the middle (Zoom in 2D; Size,
   Depth and Spread in 3D), full screen on the far right */
.wall-sliders { flex: 1 1 auto; display: flex; align-items: center; gap: 8px 16px; min-width: 60px; }
.wall-sliders .zoom-bar { display: flex; flex: 1 1 0; min-width: 50px; max-width: 320px; }
.wall-2d:not(.is-3dmode) .only-3d { display: none !important; }
.wall-fs { margin-left: auto; }
/* the tunnel's pause chip (a click on the empty stage) */
.wall-paused { position: absolute; top: 12px; left: 12px; z-index: 3; padding: 4px 10px; background: var(--ink-deep); color: var(--toxic); border: 2px solid var(--toxic); font: 700 .8rem var(--f-mono); letter-spacing: .1em; text-transform: uppercase; pointer-events: none; }
.wall-tune { display: none; }
/* the tunnel takes the wheel once clicked into (desktop): a thin outline says so */
.wall-3d.is-engaged { outline: 2px solid var(--toxic); outline-offset: -2px; }
.wall-explore { position: absolute; left: 50%; bottom: 16px; z-index: 3; transform: translateX(-50%); min-height: 44px; padding: 0 18px; border: var(--ink-line); background: var(--toxic); color: var(--ink-deep); box-shadow: 3px 3px 0 var(--ink-deep); font: 700 .9rem var(--f-ui); letter-spacing: .12em; text-transform: uppercase; cursor: pointer; }
.wall-2d.is-fs .wall-explore { display: none; }
/* phones: one row of switches, the settings button and full screen; the sliders fold behind the settings button and
   open as a second row (owner: "expandable, otherwise too big") */
@media (max-width: 640px) {
  .wt-long { display: none; }
  .wt-short { display: inline; }
  .wall-tools-row { flex-wrap: wrap; gap: 8px 6px; }
  .wall-tools .view-toggle button, .wall-tools .dim-toggle button, .wall-fs, .wall-tune { padding: 0 .55rem; font-size: .8rem; letter-spacing: .06em; }
  .wall-tune { display: inline-flex; align-items: center; justify-content: center; min-width: 44px; min-height: 44px; border: var(--ink-line); background: var(--bone); color: var(--ink-deep); box-shadow: 3px 3px 0 var(--blood); cursor: pointer; }
  .wall-tune[aria-expanded="true"] { background: var(--toxic); }
  .wall-sliders { display: none; order: 5; flex: 1 1 100%; gap: 8px 12px; flex-wrap: wrap; padding: 10px 12px; background: var(--ink-deep); border: var(--ink-line); }
  .wall-2d.is-tuning .wall-sliders { display: flex; }
  .wall-sliders .zoom-bar { flex: 1 1 100%; max-width: none; }
  .wall-tools .zoom-bar > span { min-width: 3.9em; font-size: .72rem; }
}
/* full screen (the browser's, or the overlay where there is none): the site's background, the grid scrolls,
   the tunnel fills the height */
.wall-2d.is-fs { display: flex; flex-direction: column; box-sizing: border-box; width: 100%; height: 100%; overflow-y: auto; padding-top: 12px; background: var(--ink, #0e0c0a); }
.wall-2d.is-fs .wall-tools-row { margin-top: 0; }
.wall-2d.is-fs .wall-3d { flex: 1 1 auto; height: auto; min-height: 320px; }
.wall-2d.is-overlay { position: fixed; inset: 0; z-index: 80; height: 100dvh; }
.wall-2d::backdrop { background: var(--ink, #0e0c0a); }
.wall-lock, .wall-lock body { overflow: hidden; }
.wall-lock header.nav { visibility: hidden; } /* the overlay can't rise above the fixed site header, so it steps aside */
/* 2D: --cols photos per row (zoom bar or pinch, WALL_JS), every few photos one goes double size; tiles are a fixed
   share of the column width tall (--tile, set by WALL_JS). Only the tile under the pointer lifts, nothing else moves */
.collage.is-2d { display: grid; grid-template-columns: repeat(var(--cols, 3), minmax(0, 1fr)); grid-auto-rows: var(--tile, 240px); grid-auto-flow: dense; gap: clamp(8px, 1.2vw, 14px); }
.collage.is-2d li { grid-column: span 1; grid-row: span 1; }
.collage.is-2d[data-cols="2"] li:nth-child(3n+1), .collage.is-2d[data-cols="3"] li:nth-child(5n+1), .collage.is-2d[data-cols="4"] li:nth-child(7n+1),
.collage.is-2d[data-cols="5"] li:nth-child(9n+1), .collage.is-2d[data-cols="6"] li:nth-child(11n+1) { grid-column: span 2; grid-row: span 2; }
.collage.is-2d a { height: 100%; transition: transform .3s var(--ease-out), box-shadow .3s var(--ease-out); }
.collage.is-2d a:hover, .collage.is-2d a:focus-visible { transform: scale(1.03); box-shadow: 0 18px 36px rgba(0, 0, 0, .5); z-index: 2; }
/* on the smallest tiles the captions drop out (they still show in the full-screen viewer) */
.collage.is-2d[data-cols="5"] li:not(:nth-child(9n+1)) :is(.pc-cap, .pc-date),
.collage.is-2d[data-cols="6"] li:not(:nth-child(11n+1)) :is(.pc-cap, .pc-date) { display: none; }
.zoom-bar { display: none; align-items: center; gap: 12px; max-width: 420px; margin-top: 16px; font-family: var(--f-mono); font-size: .8rem; letter-spacing: .12em; text-transform: uppercase; color: var(--bone); }
.zoom-bar.is-on { display: flex; }
.zoom-bar input { flex: 1; min-height: 32px; accent-color: var(--toxic); }
.zoom-bar[hidden] { display: none !important; }
@media (max-width: 760px) {
  .collage.is-2d { gap: 8px; touch-action: pan-y; }
  .collage .pc-cap, .collage .pc-date { opacity: 1; transform: none; }
  .collage .pc-cap { font-size: 1.1rem; padding: 14px 10px 26px; }
  .collage .pc-date { left: 10px; bottom: 9px; }
  .collage.is-2d[data-cols="3"] li:not(:nth-child(5n+1)) :is(.pc-cap, .pc-date), .collage.is-2d[data-cols="4"] li:not(:nth-child(7n+1)) :is(.pc-cap, .pc-date) { display: none; }
}
.wall-3d { position: relative; height: min(86vh, 980px); min-height: 520px; margin-top: clamp(24px, 3vw, 36px); border: var(--ink-line); box-shadow: 10px 12px 0 var(--ink-deep); background: radial-gradient(ellipse at center, #1a1410, var(--ink-deep) 70%); overflow: hidden; cursor: grab; touch-action: none; user-select: none; }
.wall-3d:focus-visible { outline: 3px solid var(--toxic); outline-offset: 4px; }
/* touch screens: an up or down swipe scrolls the page past the tunnel, a sideways swipe moves through it;
   in full screen there is no page behind it, so the tunnel takes every gesture */
@media (hover: none), (pointer: coarse) { .wall-3d { touch-action: pan-y; } .wall-2d.is-fs .wall-3d { touch-action: none; } }
.wall-3d.is-dragging { cursor: grabbing; }
.wall-cam { position: absolute; inset: 0; perspective: 1100px; perspective-origin: 50% 50%; }
/* the list is a flat layer in front of the photos in 3D, so only the photos themselves take taps */
.collage.is-3d { position: absolute; inset: 0; margin: 0; transform-style: preserve-3d; transform: rotateX(var(--px, 0deg)) rotateY(var(--py, 0deg)); transition: transform .5s var(--ease-out); pointer-events: none; }
.collage.is-3d a { pointer-events: auto; }
/* --card: the photos' width as a share of the stage, from the size slider (WALL_JS); centred by the margins */
.collage.is-3d li { position: absolute; top: 50%; left: 50%; width: calc(var(--card, .44) * 100%); aspect-ratio: 4 / 3; margin: calc(var(--card, .44) * -37.5%) 0 0 calc(var(--card, .44) * -50%); transform-style: preserve-3d; }
.collage.is-3d.is-moving li { will-change: transform, opacity; } /* only while the tunnel runs (item 18) */
.collage.is-3d a { height: 100%; box-shadow: 0 20px 50px rgba(0, 0, 0, .6); }
.collage.is-3d a:hover { outline: 3px solid var(--toxic); }
.collage.is-3d .pc-cap, .collage.is-3d .pc-date { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .dim-toggle { display: none; }
  .collage.is-2d a { transition: none; transform: none !important; }
  .collage .pc-cap, .collage .pc-date { transition: none; }
}
/* the full-screen photo viewer (WALL_JS): arrows, swipe, Esc; its own wv- names, the reel's lightbox owns lb- */
.wv { width: 100vw; height: 100dvh; max-width: none; max-height: none; margin: 0; padding: 0; border: 0; background: rgba(11, 8, 6, .96); color: var(--bone); overscroll-behavior: contain; }
.wv::backdrop { background: rgba(11, 8, 6, .9); }
.wv-stage { position: absolute; inset: 0; display: grid; place-items: center; padding: 64px 12px 96px; touch-action: none; overflow: hidden; } /* pinch and pan are the viewer's own */
.wv-img { transform-origin: 50% 50%; will-change: transform; cursor: zoom-in; }
.wv.is-zoomed .wv-img { cursor: grab; }
.wv-img { display: block; max-width: 100%; max-height: 100%; width: auto; height: auto; object-fit: contain; border: 3px solid var(--ink-3); box-shadow: 0 30px 80px rgba(0, 0, 0, .7); user-select: none; -webkit-user-drag: none; }
.wv-bar { position: absolute; left: 0; right: 0; bottom: 0; display: flex; align-items: center; gap: 12px; padding: 14px clamp(14px, 3vw, 28px); background: linear-gradient(transparent, rgba(11, 8, 6, .9)); }
.wv-cap { flex: 1; min-width: 0; margin: 0; font-family: var(--f-display); font-weight: 900; font-size: clamp(1.1rem, 2.5vw, 1.6rem); letter-spacing: .02em; text-transform: uppercase; overflow-wrap: anywhere; }
.wv-cap small { display: block; font-family: var(--f-mono); font-weight: 700; font-size: .75rem; letter-spacing: .12em; color: var(--toxic); }
.wv-open { flex: none; display: inline-flex; align-items: center; min-height: 44px; padding: 0 16px; border: var(--ink-line); background: var(--toxic); color: var(--ink-deep); text-decoration: none; font-family: var(--f-ui); font-weight: 700; font-size: .95rem; letter-spacing: .12em; text-transform: uppercase; }
.wv-btn, .wv-close { position: absolute; display: grid; place-items: center; width: 52px; height: 52px; padding: 0; border: var(--ink-line); background: var(--bone); color: var(--ink-deep); font: 700 1.8rem/1 var(--f-ui); cursor: pointer; box-shadow: 4px 4px 0 var(--ink-deep); }
.wv-btn { top: 50%; transform: translateY(-50%); }
.wv-prev { left: 14px; }
.wv-next { right: 14px; }
.wv-close { top: 12px; right: 12px; width: 48px; height: 48px; font-size: 1.5rem; }
.wv-btn:hover, .wv-close:hover { background: var(--toxic); }
.wv-btn:focus-visible, .wv-close:focus-visible, .wv-open:focus-visible { outline: 3px solid var(--toxic); outline-offset: 3px; }
.wv-count { position: absolute; top: 26px; left: 18px; font-family: var(--f-mono); font-size: .8rem; letter-spacing: .12em; color: var(--bone); }
/* phones: the arrows sit on the photo's edges (swiping works too), clear of the caption bar */
@media (max-width: 560px) { .wv-btn { width: 44px; height: 44px; opacity: .9; } .wv-prev { left: 6px; } .wv-next { right: 6px; } .wv-stage { padding-bottom: 130px; } }

/* one post */
.post-wrap { max-width: 860px; }
.post-back a { font-family: var(--f-ui); font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--bone-dim); text-decoration: none; display: inline-flex; min-height: 44px; align-items: center; }
.post-back a:hover { color: var(--toxic); }
.post .post-meta { display: block; margin-top: 18px; color: var(--toxic); }
.post-h { margin-top: 10px; font-size: clamp(2.4rem, 6vw, 4.6rem); overflow-wrap: anywhere; }
/* the paper frame wraps the photo at its own size, centred: a small or portrait upload is never stretched or boxed in
   dark bars (design review 2026-10-18); a wide one still fills the column */
.post-photo { width: fit-content; max-width: 100%; margin: clamp(28px, 4vw, 48px) auto 0; padding: 12px; background: var(--paper); border: var(--ink-line); box-shadow: 10px 12px 0 var(--ink-deep); transform: rotate(-.6deg); }
.post-photo img { display: block; width: auto; max-width: 100%; height: auto; max-height: 80svh; object-fit: contain; border: var(--ink-line); background: var(--ink-3); }
@media (max-width: 560px) { .post-photo img { max-height: 60svh; } } /* phones: the text starts within the first screens (item 16) */
/* the way onward at the end of a post (item 13) */
.post-nav { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-top: clamp(36px, 5vw, 56px); padding-top: 24px; border-top: 2px dashed var(--ink-3); }
.post-nav a { display: grid; gap: 6px; padding: 14px 16px; color: var(--paper-ink); text-decoration: none; background: var(--paper); border: var(--ink-line); box-shadow: 6px 7px 0 var(--ink-deep); transition: transform .2s var(--ease-out), box-shadow .2s var(--ease-out); }
.post-nav a:hover { transform: translate(-2px, -2px); box-shadow: 8px 9px 0 var(--ink-deep); }
.post-nav-older { text-align: right; }
.post-nav-k { font-family: var(--f-mono); font-weight: 700; font-size: .85rem; letter-spacing: .12em; text-transform: uppercase; color: var(--oxblood); }
.post-nav-t { font-family: var(--f-display); font-weight: 900; font-size: 1.25rem; line-height: 1.05; letter-spacing: .02em; text-transform: uppercase; }
.post-nav-all { grid-column: 1 / -1; justify-items: center; font-family: var(--f-ui); font-weight: 700; font-size: 1.05rem; letter-spacing: .12em; text-transform: uppercase; background: var(--toxic); }
@media (max-width: 560px) { .post-nav { grid-template-columns: 1fr; } .post-nav-older { text-align: left; } }
@media (prefers-reduced-motion: reduce) { .post-nav a { transition: none; } .post-nav a:hover { transform: none; } }
.post-body { margin-top: clamp(28px, 4vw, 44px); font-family: var(--f-serif); font-size: clamp(1.25rem, 1.1rem + .5vw, 1.45rem); line-height: 1.55; color: var(--bone); font-weight: 500; }
.post-body p + p { margin-top: 1em; }
/* structure inside a post (worker.js textToHtml): subheadings, numbered steps, lists, "Term: text" lists */
.post-body .post-sub { margin: 1.6em 0 .5em; font-family: var(--f-display); font-weight: 900; font-size: clamp(1.5rem, 1.2rem + 1vw, 2rem); line-height: 1.05; letter-spacing: .02em; text-transform: uppercase; color: var(--bone); text-shadow: 3px 3px 0 var(--ink-deep); }
.post-body ol, .post-body ul { margin: 1em 0 0; padding-left: 1.6em; display: grid; gap: .45em; }
.post-body li { padding-left: .2em; }
.post-body li::marker { font-family: var(--f-display); font-weight: 900; color: var(--toxic); letter-spacing: .02em; }
.post-body ul::marker, .post-body ul li::marker { color: var(--toxic); }
.post-body .post-defs { list-style: none; padding-left: 0; }
.post-body .post-defs li { padding-left: 1em; border-left: 3px solid var(--toxic); }
.post-body strong { color: var(--paper, var(--bone)); font-weight: 700; }
.post-body .post-sub + ol, .post-body .post-sub + ul, .post-body .post-sub + p { margin-top: 0; }
.post-body ol + p, .post-body ul + p, .post-body p + ol, .post-body p + ul { margin-top: 1em; }
.post-body a { color: var(--toxic); text-underline-offset: 3px; overflow-wrap: anywhere; }
.post-video { position: relative; margin-top: 36px; aspect-ratio: 16 / 9; border: var(--ink-line); box-shadow: 10px 12px 0 var(--ink-deep); background: var(--ink-deep); }
.post-video iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.post-link { margin-top: 36px; }
.post-link .btn { max-width: 100%; overflow-wrap: anywhere; }

/* ---------------------------------------------------------------- owner's page */
.adm-wrap { max-width: 760px; }
.adm-who { margin-top: 14px; color: var(--muted); font-size: 1.1rem; }
.adm-form {
  display: grid; gap: 20px; margin-top: 32px; padding: clamp(18px, 4vw, 32px);
  background: var(--paper); color: var(--paper-ink); border: var(--ink-line); box-shadow: 10px 12px 0 var(--ink-deep);
}
.adm-form label { display: grid; gap: 8px; font-family: var(--f-ui); font-weight: 700; font-size: 1.1rem; letter-spacing: .1em; text-transform: uppercase; }
.adm-req, .adm-opt { font-family: var(--f-serif); font-size: 1rem; letter-spacing: 0; text-transform: none; color: var(--paper-muted); font-weight: 500; }
.adm-form input:not([type="file"]), .adm-form textarea, .adm-form select {
  width: 100%; min-height: 48px; padding: 10px 12px; border: var(--ink-line); border-radius: 0;
  background: #fffaf0; color: var(--paper-ink); font-family: var(--f-serif); font-size: 1.2rem; font-weight: 500; letter-spacing: 0; text-transform: none;
}
.adm-form textarea { min-height: 220px; line-height: 1.45; resize: vertical; }
.adm-form input[type="file"] { font-family: var(--f-serif); font-size: 1.1rem; letter-spacing: 0; text-transform: none; min-height: 48px; }
.adm-form :focus-visible { outline: 3px solid var(--ink-deep); outline-offset: 2px; }
.adm-preview { display: flex; flex-wrap: wrap; align-items: end; gap: 12px; }
.adm-preview img { max-width: 220px; max-height: 220px; border: var(--ink-line); }
.adm-msg { min-height: 1.4em; font-size: 1.15rem; font-weight: 500; }
.adm-msg.bad { color: var(--blood); }
.adm-actions { display: flex; flex-wrap: wrap; gap: 16px; }
.adm-cancel { background: var(--bone); color: var(--ink-deep); cursor: pointer; }
.adm-form button[disabled] { opacity: .6; cursor: progress; }
.btn { cursor: pointer; }
.adm-small {
  min-height: 44px; padding: 0 14px; border: var(--ink-line); background: var(--bone); color: var(--ink-deep);
  font-family: var(--f-ui); font-weight: 700; font-size: 1rem; letter-spacing: .1em; text-transform: uppercase; cursor: pointer;
}
.adm-small:hover { background: var(--toxic); }
.adm-danger { background: #f2c6bd; }
.adm-danger:hover { background: var(--blood); color: var(--bone); }
.adm-list-h { margin-top: clamp(56px, 8vw, 88px); }
.adm-list { display: grid; gap: 12px; }
.adm-row { display: flex; align-items: center; gap: 14px; padding: 10px; background: var(--ink-3); border: 2px solid var(--line); }
.adm-row img, .adm-noimg { width: 72px; height: 72px; flex: none; object-fit: cover; border: 2px solid var(--ink-deep); background: var(--line); }
.adm-row-text { flex: 1; min-width: 0; display: grid; gap: 4px; }
.adm-row-text a { color: var(--bone); font-size: 1.2rem; font-weight: 500; overflow-wrap: anywhere; }
.adm-row-text small { color: var(--muted); font-size: 1rem; }
.adm-row-btns { display: flex; gap: 8px; flex-wrap: wrap; justify-content: end; }
.adm-foot { margin-top: 40px; color: var(--muted); font-size: 1.1rem; }
.adm-foot a { color: var(--bone-dim); text-underline-offset: 3px; }
@media (max-width: 560px) {
  .adm-row { flex-wrap: wrap; }
  .adm-row-btns { width: 100%; justify-content: start; }
}

/* ---------------------------------------------------------------- polls (src/polls.js): under the post text, and the
   owner's panel under each post row at /admin/blog */
.post-poll { margin-top: clamp(32px, 5vw, 56px); padding: clamp(18px, 3vw, 28px); color: var(--paper-ink); background: var(--paper); border: var(--ink-line); box-shadow: 8px 10px 0 var(--ink-deep); }
.post-poll[hidden] { display: none; }
.post-poll .hand-title { margin: 0; color: var(--oxblood); }
.poll-q { margin: 6px 0 16px; font: 900 clamp(1.5rem, 3vw, 2rem)/1.05 var(--f-display); text-transform: uppercase; overflow-wrap: anywhere; }
.poll-form fieldset { margin: 0; padding: 0; border: 0; }
.poll-form[hidden], .poll-results[hidden] { display: none; }
.poll-opts { display: grid; gap: 8px; margin-bottom: 16px; }
.poll-opts label { display: flex; align-items: center; gap: 10px; min-height: 44px; padding: 6px 12px; border: 2px solid var(--ink-deep); background: #f6efdc; font: 500 1.2rem/1.25 var(--f-serif); cursor: pointer; }
.poll-opts label:has(input:checked) { background: var(--toxic); }
.poll-opts input { width: 20px; height: 20px; flex: none; accent-color: var(--ink-deep); }
.poll-opts label:focus-within { outline: 3px solid var(--oxblood); outline-offset: 2px; }
.poll-results { display: grid; gap: 10px; margin: 0; padding: 0; list-style: none; }
.poll-results li { position: relative; display: flex; justify-content: space-between; gap: 12px; padding: 8px 12px; border: 2px solid var(--ink-deep); background: #f6efdc; font: 500 1.15rem/1.25 var(--f-serif); isolation: isolate; }
.poll-results .poll-bar { position: absolute; inset: 0 auto 0 0; width: var(--w, 0%); background: rgba(255, 214, 10, .55); z-index: -1; transition: width .6s var(--ease-out); }
.poll-results li.is-mine { font-weight: 700; }
.poll-results li.is-mine .poll-bar { background: var(--toxic); }
.poll-pct { font-family: var(--f-mono); font-weight: 700; white-space: nowrap; }
.poll-note { margin: 12px 0 0; font-family: var(--f-mono); font-size: .85rem; letter-spacing: .1em; text-transform: uppercase; color: var(--paper-muted); }
.adm-poll { display: grid; gap: 10px; padding: 16px; margin: -4px 0 8px; background: var(--ink-3); border: 2px solid var(--toxic); }
.adm-poll[hidden] { display: none; }
.adm-poll label { display: grid; gap: 4px; color: var(--bone); }
.adm-poll input, .adm-poll textarea { padding: 8px 10px; border: var(--ink-line); background: var(--bone); color: var(--ink-deep); font: 500 1.05rem var(--f-serif); }
.adm-poll .poll-results li { color: var(--paper-ink); }
.adm-poll .poll-note { color: var(--bone); }
@media (prefers-reduced-motion: reduce) { .poll-results .poll-bar { transition: none; } }
/* ---------------------------------------------------------------- posts with several photos, and reel links */
.post-photos { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 220px), 1fr)); gap: 10px; margin-top: 10px; }
.post-photos img { display: block; width: 100%; height: auto; aspect-ratio: 1; object-fit: cover; border: var(--ink-line); background: #2a211b; }
/* a link (an Instagram reel, a YouTube video, a TikTok, any page) as a small card: no full-size player in the post */
.link-card { display: flex; align-items: center; gap: 14px; max-width: 560px; margin-top: clamp(24px, 3vw, 36px); padding: 10px; color: var(--paper-ink); text-decoration: none; background: var(--paper); border: var(--ink-line); box-shadow: 6px 7px 0 var(--ink-deep); transition: transform .2s var(--ease-out); }
/* the card lifts; its shadow stays on the surface and grows by the lift (CLAUDE.md shadow rule) */
.link-card { transition: transform .2s var(--ease-out), box-shadow .2s var(--ease-out); }
.link-card:hover { transform: translateY(-3px); box-shadow: 6px 10px 0 var(--ink-deep); }
.link-card:focus-visible { outline: 3px solid var(--toxic); outline-offset: 3px; }
.link-thumb { flex: none; width: 96px; height: 72px; object-fit: cover; border: 2px solid var(--ink-deep); background: var(--ink-deep); }
.link-badge { display: grid; place-items: center; color: var(--toxic); font: 900 2rem/1 var(--f-display); }
.link-text { flex: 1; min-width: 0; display: grid; gap: 2px; }
.link-kind { font: 900 1.15rem/1.1 var(--f-display); text-transform: uppercase; letter-spacing: .02em; }
.link-url { font-size: .95rem; color: var(--paper-muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.link-open { flex: none; display: inline-flex; align-items: center; min-height: 44px; padding: 0 14px; background: var(--toxic); border: 2px solid var(--ink-deep); font: 700 .95rem var(--f-ui); letter-spacing: .12em; text-transform: uppercase; }
@media (max-width: 420px) { .link-thumb { width: 72px; height: 54px; } .link-card { gap: 10px; } }
@media (prefers-reduced-motion: reduce) { .link-card { transition: none; } }
/* the editor's photo strip */
.adm-hint { font-family: var(--f-serif); font-size: 1.1rem; color: var(--paper-muted); }
.adm-photos { display: grid; grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: 12px; margin: 0; padding: 0; list-style: none; }
.adm-photos li { position: relative; display: grid; gap: 6px; }
.adm-photos img { width: 100%; aspect-ratio: 1; object-fit: cover; border: var(--ink-line); background: var(--ink-3); }
.adm-cover { position: absolute; left: 6px; top: 6px; padding: 2px 8px; background: var(--toxic); border: 2px solid var(--ink-deep); font: 700 .85rem var(--f-ui); letter-spacing: .1em; text-transform: uppercase; }
.adm-photo-btns { display: flex; gap: 6px; }
.adm-photo-btns .adm-small { flex: 1; min-height: 36px; padding: 0; }
/* polls with photo answers: image tiles, 2 per row on phones and up to 4 on wide screens, the answer under each */
.post-poll.has-photos .poll-opts, .post-poll.has-photos .poll-results { grid-template-columns: repeat(auto-fill, minmax(min(46%, 180px), 1fr)); }
.post-poll.has-photos .poll-opts { display: grid; }
.post-poll.has-photos .poll-opts label { flex-direction: column; align-items: stretch; gap: 8px; padding: 8px; text-align: center; }
.post-poll.has-photos .poll-opts input { position: absolute; opacity: 0; }
.post-poll.has-photos .poll-opts label { position: relative; }
.post-poll.has-photos .poll-results li { flex-direction: column; align-items: stretch; gap: 6px; padding: 8px; text-align: center; }
.poll-img { display: block; width: 100%; aspect-ratio: 1; object-fit: cover; border: 2px solid var(--ink-deep); background: #2a211b; }
.post-poll.has-photos .poll-results .poll-bar { inset: auto 0 0 0; width: var(--w, 0%); height: 8px; }
/* the owner's answer rows */
.adm-answers { display: grid; gap: 8px; margin: 0; padding: 0; list-style: none; }
.adm-answers li { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.adm-answers li > input { flex: 1 1 180px; }
.adm-answer-img { width: 48px; height: 48px; object-fit: cover; border: 2px solid var(--ink-deep); }
.adm-answer-img[hidden] { display: none; }
.adm-answers .adm-small { min-height: 40px; }
.adm-answers-h { margin: 6px 0 0; color: var(--bone); }