:root {
  --cream: #f3efe6;
  --paper: #fbf9f4;
  --ink: #14130f;
  --muted: #6f6857;
  --line: #ddd6c7;
  --line2: #cfc7b5;
  --go: #1f6f4a;
  --no: #9a2b2b;
  --dark: #070709;
  --shadow: 0 20px 60px rgba(20, 19, 15, 0.28);
}
* { box-sizing: border-box; }
html, body { margin: 0; }
body { background: var(--cream); color: var(--ink); min-height: 100vh;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif; -webkit-font-smoothing: antialiased; }
a { color: inherit; }

/* ============ chrome (brand + view toggle + filters) ============ */
.chrome { position: sticky; top: 0; z-index: 30; background: var(--cream);
  border-bottom: 1px solid var(--line); padding: 14px 22px 10px; transition: opacity .4s; }
.bar { display: flex; align-items: center; justify-content: space-between; gap: 16px; max-width: 1280px; margin: 0 auto; }
.logo { font-weight: 800; letter-spacing: 0.17em; font-size: clamp(20px, 3vw, 28px); transition: color .35s; }
.views { position: relative; display: inline-flex; background: var(--paper); border: 1px solid var(--line); border-radius: 999px; padding: 4px; }
.view { position: relative; z-index: 1; flex: 1 1 0; min-width: 134px; text-align: center; white-space: nowrap; font: inherit; font-size: 13.5px;
  font-weight: 600; color: var(--muted); border: none; background: none; cursor: pointer; padding: 8px 16px; border-radius: 999px; transition: color .35s; }
.view .ic { opacity: .85; }
.view.is-active { color: var(--cream); }
.slider { position: absolute; top: 4px; bottom: 4px; left: 4px; width: calc(50% - 4px); background: var(--ink); border-radius: 999px; z-index: 0; transition: left .5s cubic-bezier(.55,0,.2,1), background .35s; }
body[data-view="closet"] .slider { left: 50%; }

.toolbar { max-width: 1280px; margin: 12px auto 0; display: flex; flex-wrap: wrap; align-items: center; gap: 9px; }
#q { flex: 1 1 220px; min-width: 170px; padding: 11px 15px; font-size: 16px; border: 1.5px solid var(--line); border-radius: 11px; background: var(--paper); color: var(--ink); outline: none; }   /* 16px: below it iOS Safari zooms the page on focus */
#q:focus { border-color: var(--ink); }
.facets { display: flex; flex-wrap: wrap; gap: 9px; }
.facet { position: relative; }
.facet-btn { font: inherit; font-size: 14px; font-weight: 600; cursor: pointer; padding: 10px 14px; border: 1.5px solid var(--line);
  border-radius: 11px; background: var(--paper); color: var(--ink); display: inline-flex; align-items: center; gap: 7px; transition: background .3s, color .3s, border-color .3s; }
.facet-btn:hover { border-color: var(--line2); }
.facet.has-sel .facet-btn { border-color: var(--ink); }
.facet-btn .cnt { font-size: 11px; font-weight: 800; background: var(--ink); color: var(--cream); border-radius: 999px; padding: 1px 7px; min-width: 18px; text-align: center; }
.facet-btn .car { color: var(--muted); font-size: 11px; }
.facet-pop { position: absolute; z-index: 40; top: calc(100% + 6px); left: 0; width: 264px; max-height: 360px; display: none; flex-direction: column;
  background: var(--paper); border: 1px solid var(--line2); border-radius: 13px; box-shadow: var(--shadow); overflow: hidden; }
.facet.open .facet-pop { display: flex; }
.facet-search { margin: 10px; padding: 8px 11px; font-size: 16px; border: 1px solid var(--line); border-radius: 8px; background: var(--cream); outline: none; color: var(--ink); }   /* 16px: avoid iOS focus-zoom */
.facet-list { overflow-y: auto; padding: 2px 6px 8px; }
.opt { display: flex; align-items: center; gap: 9px; padding: 8px 9px; border-radius: 8px; cursor: pointer; font-size: 14px; color: var(--ink); }
.opt:hover { background: var(--cream); }
.opt input { accent-color: var(--ink); width: 15px; height: 15px; }
.opt .ov { flex: 1; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.opt .oc { color: var(--muted); font-size: 12px; font-variant-numeric: tabular-nums; }
.opt.hide { display: none; }
.sort { font-size: 13px; color: var(--muted); display: inline-flex; align-items: center; gap: 6px; margin-left: auto; }
.sort select { font: inherit; font-size: 14px; padding: 9px 11px; border: 1.5px solid var(--line); border-radius: 10px; background: var(--paper); color: var(--ink); }

.active { max-width: 1280px; margin: 10px auto 0; display: flex; flex-wrap: wrap; gap: 7px; }
.chip { font-size: 13px; font-weight: 600; background: var(--ink); color: var(--cream); border: none; border-radius: 999px; padding: 6px 8px 6px 12px; cursor: pointer; display: inline-flex; align-items: center; gap: 7px; }
.chip .x { opacity: .7; font-size: 14px; }
.chip:hover .x { opacity: 1; }
.chip.clear { background: none; color: var(--no); border: 1.5px solid var(--no); padding: 5px 13px; }
.status { max-width: 1280px; margin: 9px auto 0; color: var(--muted); font-size: 13.5px; }
.status b { color: var(--ink); }

/* ============ the wall ============ */
main.wall { max-width: 1280px; margin: 0 auto; }
.grid { display: grid; gap: 22px 16px; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); padding: 18px 20px 48px; }
.tile { position: relative; border: none; background: none; padding: 0; cursor: pointer; text-align: left; font: inherit; color: inherit; display: block; }
.art { position: relative; width: 100%; border-radius: 8px; overflow: hidden; background: var(--paper); border: 1px solid var(--line); box-shadow: 0 6px 18px rgba(20,19,15,.10); transition: transform .12s, box-shadow .12s; }
/* hold a rock-solid 5:7 box via padding (iOS Safari can collapse an aspect-ratio box around an <img>) */
.art::before { content: ''; display: block; padding-bottom: 140%; }
.tile:hover .art { transform: translateY(-3px); box-shadow: 0 14px 30px rgba(20,19,15,.20); }
.art img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; }
.ph { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 12px; background: linear-gradient(180deg, rgba(20,19,15,.04), rgba(20,19,15,0) 30%), var(--paper); }
.ph .c { font-weight: 800; letter-spacing: .12em; font-size: 10px; color: var(--muted); }
.ph .n { font-weight: 800; font-size: clamp(32px, 6vw, 44px); line-height: 1; margin: 8px 0; }
.ph .pt { font-family: Georgia, serif; font-size: 12.5px; line-height: 1.25; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.badge { position: absolute; top: 8px; left: 8px; font-weight: 800; font-size: 11px; letter-spacing: .03em; padding: 4px 8px; border-radius: 999px; background: rgba(20,19,15,.82); color: var(--cream); }
/* The title sits in a FIXED-height slot (exactly two 18px lines = 36px). A normal block honours `height`
   reliably on iOS — unlike min-height on a -webkit-line-clamp box — so short and long titles reserve the
   identical space and every tile is the same height. Long titles clamp to 2 lines with an ellipsis. */
.cap { padding: 9px 3px 0; }
.cap .t-wrap { display: block; height: 36px; overflow: hidden; }
.cap .t { font-family: Georgia, "Times New Roman", serif; font-size: 15px; font-weight: 600; line-height: 18px;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.cap .y { color: var(--muted); font-size: 12.5px; line-height: 16px; display: block; margin-top: 3px;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }   /* keep the year·country to one line */
.none { grid-column: 1 / -1; text-align: center; padding: 60px 18px; color: var(--muted); }
.none h3 { font-family: Georgia, serif; color: var(--ink); font-size: 22px; margin: 0 0 8px; }

.site-foot { text-align: center; color: var(--muted); font-size: 11.5px; padding: 14px 18px 28px; }
.dot { margin: 0 5px; opacity: .5; }

/* ============ The Closet — full-viewport overlay ============ */
.closet-overlay { position: fixed; inset: 0; z-index: 40; background: var(--dark);
  opacity: 0; transform: scale(1.06); pointer-events: none;
  transition: opacity .5s cubic-bezier(.55,0,.2,1), transform .55s cubic-bezier(.55,0,.2,1); }
.closet-overlay iframe { width: 100%; height: 100%; border: 0; display: block; background: var(--dark); }
.closet-prompt { position: absolute; left: 50%; bottom: 26px; transform: translateX(-50%); z-index: 2;
  background: rgba(12,12,14,.72); color: #e8e3d6; border: 1px solid rgba(244,241,234,.16); border-radius: 999px;
  padding: 9px 18px; font-size: 13px; opacity: 0; transition: opacity .4s; pointer-events: none; }
.closet-prompt b { color: #fff; }

.flash { position: fixed; inset: 0; background: var(--dark); opacity: 0; pointer-events: none; transition: opacity .26s ease; z-index: 90; }
.flash.on { opacity: .92; }

/* loading veil — hides the one-time label generation so titles never pop in */
.closet-loader { position: fixed; inset: 0; z-index: 85; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 11px;
  background: radial-gradient(120% 120% at 50% 36%, #16161c 0%, #07070a 78%); opacity: 0; pointer-events: none; transition: opacity .5s ease; }
.cl-brand { font-weight: 800; letter-spacing: .34em; font-size: 15px; color: #cfc9bb; }
.cl-sub { font-family: Georgia, "Times New Roman", serif; font-style: italic; font-size: 14.5px; color: #8c887e; animation: clpulse 1.4s ease-in-out infinite; }
@keyframes clpulse { 0%, 100% { opacity: .5 } 50% { opacity: 1 } }
/* appear INSTANTLY to cover loading (no fade-in, or the splash bleeds through while it ramps up);
   the fade only plays on the way out, when the base .5s transition takes over as the class is removed */
body.closet-loading #closet-loader { opacity: 1; pointer-events: auto; transition: none; }

/* ---- closet mode: go full immersive, float the chrome over the 3D ---- */
body[data-view="closet"] .closet-overlay { opacity: 1; transform: none; pointer-events: auto; }
/* in the closet, touch never scrolls the page — one-finger drag is look */
body[data-view="closet"] { overflow: hidden; overscroll-behavior: none; }
body[data-view="closet"] .closet-overlay, body[data-view="closet"] #closet-frame { touch-action: none; }
/* in the List, drop the fixed closet iframe out of hit-testing immediately so iOS can't catch a scroll
   on it. The flash blink masks the swap; going back to the closet, opacity still fades in. */
body[data-view="wall"] .closet-overlay { visibility: hidden; }
body[data-view="closet"] .closet-prompt { opacity: 1; }
/* mobile: keep the how-to tiny and at the TOP so it never collides with the bottom HUD */
/* mobile: no top hint — the "Enter the Closet" splash already teaches the controls */
body.is-touch .closet-prompt { display: none !important; }
@media (pointer: coarse) { .closet-prompt { display: none !important; } }
body[data-view="closet"] main.wall,
body[data-view="closet"] .site-foot { display: none; }

/* the chrome becomes a centered glassmorphic panel (this is the "Esc menu"). The big
   100vmax shadow dims the whole view but captures no clicks, so clicking the dimmed
   closet around the card re-locks you back in. */
/* CSS-3D stage: the menu is a FIXED object bolted in the doorway — only the camera moves around it */
#chrome-stage, #chrome-cam { display: contents; }
body[data-view="closet"] #chrome-stage {
  display: block; position: fixed; inset: 0; z-index: 60; overflow: hidden; pointer-events: none;
}
body[data-view="closet"] #chrome-cam {
  display: block; position: absolute; top: 50%; left: 50%; width: 0; height: 0;
  transform-style: preserve-3d; transform-origin: 0 0;
}
body[data-view="closet"] .chrome {
  position: absolute; top: 0; left: 0; pointer-events: auto;
  opacity: 0;   /* hidden until the world projection places it — never flashes at the top-left during load */
  width: 520px; border-bottom: none;
  border: 1px solid rgba(255,255,255,.16); border-radius: 22px;
  background: rgba(19,19,25,.64);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);   /* lighter blur, no saturate: the panel's transform is rewritten every look-frame, re-sampling the live WebGL behind it */
  box-shadow: 0 30px 90px rgba(0,0,0,.5), inset 0 1px 0 rgba(255,255,255,.08);
  padding: 18px 22px 16px; transition: opacity .2s ease;
  transform-style: flat;
}
body.closet-loading .chrome { opacity: 0 !important; }   /* keep the menu out of the loading veil */
body[data-view="wall"] .chrome { opacity: 1; transition: none; }   /* List top bar is always solid — no fade-from-closet that can stick */
/* while the splash is up, keep the shell's chrome/prompt/cursor out of the way — but ONLY in the closet:
   if the intro flag lingers after toggling to the List, the List's top bar must still show. */
body[data-view="closet"].closet-intro .chrome,
body[data-view="closet"].closet-intro .closet-prompt,
body[data-view="closet"].closet-intro #x-cursor,
body[data-view="closet"].closet-intro .esc-hint { opacity: 0 !important; pointer-events: none !important; }

/* a List/Closet switch pinned top-right. On a phone it stays up the whole time in the closet (the
   doorway panel's toggle isn't reachable there); on ANY platform it also shows on the start-screen
   splash, so it's reachable straight from the splash / after pressing Esc. */
.closet-toggle { display: none; position: fixed; top: 12px; right: 12px; z-index: 70; gap: 0; padding: 4px;
  background: rgba(20,20,26,.5); border: 1px solid rgba(255,255,255,.16); border-radius: 999px;
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); opacity: .9; transition: opacity .2s; }
body.is-touch[data-view="closet"] .closet-toggle,
body[data-view="closet"].closet-intro .closet-toggle { display: inline-flex; }
/* on the splash, sit it exactly where the List view's bar toggle lands — same top, and right-aligned to
   the centred max-width:1280 bar (22px gutter ≤1324px, growing past that) — so toggling doesn't jump */
body[data-view="closet"].closet-intro .closet-toggle { top: 14px; right: calc(22px + max(0px, (100vw - 1324px) / 2)); opacity: 1; }
@media (max-width: 640px) { body[data-view="closet"].closet-intro .closet-toggle { top: 10px; right: 12px; } }
.closet-toggle:active { opacity: 1; }
.ct-btn { font: inherit; font-size: 13.5px; font-weight: 600; white-space: nowrap; cursor: pointer;
  border: none; background: none; color: rgba(243,239,230,.72); padding: 8px 16px; border-radius: 999px; }   /* no line-height override → matches .view height exactly */
.ct-btn.is-active { background: var(--cream); color: var(--ink); }
/* closet view: a vertical pill-stack top-left — Filters (spins to the menu) + Buy me a coffee */
.closet-actions { display: none; position: fixed; top: 17px; left: 12px; z-index: 70;   /* top tuned so the first pill's centre lines up with the taller List/Closet toggle */
  flex-direction: column; align-items: flex-start; gap: 8px; }
body[data-view="closet"] .closet-actions { display: flex; }
body[data-view="closet"].closet-intro .closet-actions,
body.closet-inspecting .closet-actions { display: none; }            /* hide on the splash and while holding a case */
.closet-filter, .closet-coffee {
  display: inline-flex; align-items: center; gap: 7px; text-decoration: none;
  padding: 7px 12px 7px 11px; background: rgba(20,20,26,.5); border: 1px solid rgba(255,255,255,.16); border-radius: 999px;
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); color: rgba(243,239,230,.92);
  font: inherit; font-size: 13.5px; font-weight: 600; cursor: pointer; opacity: .9;
  transition: opacity .2s, transform .12s, background .15s; }
.closet-filter:hover, .closet-coffee:hover { opacity: 1; background: rgba(34,34,42,.62); transform: translateY(-1px); }
.closet-filter:active, .closet-coffee:active { transform: translateY(0); }
.cf-ic { width: 15px; height: 15px; display: block; flex: none; }
.cf-key { font-size: 10.5px; font-weight: 700; line-height: 1.25; color: rgba(243,239,230,.62);
  border: 1px solid rgba(255,255,255,.24); border-radius: 5px; padding: 0 5px; margin-left: 1px; }
body.is-touch .cf-key { display: none; }                             /* key hints are desktop-only */
@media (max-width: 640px) { .closet-actions { top: 16px; } }
body[data-view="closet"] .bar { max-width: none; }
body[data-view="closet"] .logo { color: #f3efe6; font-size: 19px; }
body[data-view="closet"] .toolbar { max-width: none; margin-top: 15px; justify-content: flex-start; }
body[data-view="closet"] #q { flex: 1 1 200px; background: rgba(255,255,255,.07); border-color: rgba(255,255,255,.16); color: #f3efe6; }
body[data-view="closet"] #q:focus { border-color: rgba(255,255,255,.5); }
body[data-view="closet"] #q::placeholder { color: rgba(243,239,230,.5); }
body[data-view="closet"] .sort { display: none; }       /* sorting is meaningless walking the shelves */
body[data-view="closet"] .status { display: block; max-width: none; color: rgba(243,239,230,.62); margin: 11px 0 0; }
body[data-view="closet"] .status b { color: #f3efe6; }
body[data-view="closet"] .active { max-width: none; margin: 12px 0 0; }
/* the doorway menu is always usable: you aim the pointer-lock crosshair at a control and click. */
/* the pointer-lock cursor, drawn ON TOP of the doorway menu (z above it) so you can see where you point */
#x-cursor { position: fixed; left: 50%; top: 50%; width: 15px; height: 15px; margin: -7.5px 0 0 -7.5px; z-index: 100;
  pointer-events: none; opacity: 0; border-radius: 50%; border: 2px solid rgba(255,255,255,.92);
  background: rgba(255,255,255,.16); box-shadow: 0 0 0 1px rgba(0,0,0,.5), 0 1px 5px rgba(0,0,0,.55);
  transition: opacity .2s, transform .1s, border-color .1s, background .1s; }
body[data-view="closet"].closet-locked:not(.closet-inspecting) #x-cursor { opacity: 1; }
#x-cursor.over { border-color: #6dffb0; background: rgba(109,255,176,.32); transform: scale(1.4);
  box-shadow: 0 0 11px rgba(109,255,176,.6), 0 0 0 1px rgba(0,0,0,.4); }

.xhair-on { position: relative; }
.facet-btn.xhair-on, .lpill.xhair-on, .ltool.xhair-on, .view.xhair-on, .opt.xhair-on, .ic-more.xhair-on {
  box-shadow: 0 0 0 2px #f3efe6, 0 0 16px rgba(243,239,230,.55) !important; border-radius: 8px;
}
#q.xhair-on { box-shadow: 0 0 0 2px #f3efe6, 0 0 16px rgba(243,239,230,.5); }
body[data-view="closet"] .views { background: rgba(255,255,255,.12); border-color: rgba(255,255,255,.18); }
/* mobile closet already has the top-right List/Closet switch — drop the in-panel toggle so "THE CLOSET" isn't squeezed */
body.is-touch[data-view="closet"] .views { display: none; }
body[data-view="closet"] .view { color: rgba(243,239,230,.72); }
body[data-view="closet"] .view.is-active { color: var(--ink); }
body[data-view="closet"] .slider { background: var(--cream); }
body[data-view="closet"] .facet-btn { background: rgba(28,28,34,.62); color: #f1ece0; border-color: rgba(255,255,255,.16); }
body[data-view="closet"] .facet-btn:hover { border-color: rgba(255,255,255,.4); }
body[data-view="closet"] .facet.has-sel .facet-btn { border-color: var(--cream); }
body[data-view="closet"] .facet-btn .cnt { background: var(--cream); color: var(--ink); }
body[data-view="closet"] .facet-btn .car { color: rgba(243,239,230,.6); }

/* the doorway menu stays visible while you mouse-look (it's a world object) — only the
   "click to look" prompt fades. The menu's own visibility is driven by the world projection. */
body.closet-locked .closet-prompt { opacity: 0; pointer-events: none; }
body.prompt-hidden .closet-prompt { opacity: 0 !important; }   /* wins over the touch opacity → splash entry suppresses it */
body.closet-inspecting .closet-prompt { opacity: 0 !important; pointer-events: none; }   /* gone once you're holding a DVD */

/* the one cue you need while pointer-locked: how to get out */
.esc-hint { position: fixed; top: 16px; left: 50%; z-index: 80; transform: translateX(-50%) translateY(-8px);
  background: rgba(10,10,12,.34); color: rgba(243,239,230,.6); border: 1px solid rgba(255,255,255,.07); border-radius: 999px;
  padding: 5px 13px; font-size: 11.5px; font-weight: 500; opacity: 0; pointer-events: none;
  transition: opacity .35s, transform .35s; backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px); }
.esc-hint kbd { background: #f3efe6; color: #14130f; border-radius: 5px; padding: 2px 8px; font-weight: 800; font-size: 12px; font-family: inherit; margin-right: 7px; }
body.closet-locked:not(.closet-inspecting) .esc-hint { opacity: 1; transform: translateX(-50%) translateY(0); }

/* ============ verdict overlay (wall) ============ */
.overlay { position: fixed; inset: 0; background: rgba(20,19,15,.55); display: flex; align-items: center; justify-content: center; padding: 20px; z-index: 100; }
.overlay.hidden { display: none; }
.card { width: 100%; max-width: 430px; background: var(--paper); border-radius: 20px; box-shadow: var(--shadow); padding: 30px 30px 24px; position: relative; text-align: center; animation: pop .16s ease-out; max-height: 92vh; overflow: auto; }
@keyframes pop { from { transform: scale(.96); opacity: .5 } to { transform: scale(1); opacity: 1 } }
.card .close { position: absolute; top: 12px; right: 15px; border: none; background: none; font-size: 25px; line-height: 1; color: var(--muted); cursor: pointer; }
.hero { width: 168px; margin: 4px auto 18px; }
.hero .art { box-shadow: 0 16px 34px rgba(20,19,15,.32); border-radius: 7px; }   /* 5:7 comes from .art::before */
.spine-line { font-weight: 800; font-size: clamp(40px, 12vw, 58px); line-height: 1; margin: 6px 0 4px; }
.spine-line small { font-size: .42em; color: var(--muted); vertical-align: super; }
.card .film { font-family: Georgia, "Times New Roman", serif; font-size: 23px; font-weight: 600; margin: 2px 0 3px; }
.card .credit { color: var(--muted); font-size: 14.5px; margin-bottom: 9px; }
.syn-wrap { margin: 0 0 14px; }
.card .syn { font-size: 14.5px; line-height: 1.55; color: var(--ink); text-align: left; margin: 0;
  display: -webkit-box; -webkit-line-clamp: 4; -webkit-box-orient: vertical; overflow: hidden; }   /* collapsed preview */
.card .syn.expanded { display: block; -webkit-line-clamp: unset; }
.syn-more { background: none; border: none; padding: 4px 0 0; margin: 0; cursor: pointer; font: inherit;
  font-size: 13px; font-weight: 700; color: var(--muted); text-decoration: underline; text-underline-offset: 2px; }
.syn-more[hidden] { display: none; }
.tags { display: flex; flex-wrap: wrap; gap: 6px; justify-content: center; margin: 0 0 16px; }   /* metadata chips, sat under the byline */
.tag { font-size: 12px; font-weight: 500; color: var(--muted); background: var(--cream); border: 1px solid var(--line); border-radius: 999px; padding: 4px 11px; cursor: pointer; }
.tag:hover { border-color: var(--ink); color: var(--ink); }
.actions { display: grid; gap: 9px; }
.btn { display: block; text-decoration: none; padding: 13px 16px; border-radius: 11px; font-weight: 600; font-size: 15px; border: 1.5px solid var(--ink); }
.btn.primary { background: var(--ink); color: var(--cream); }
.btn.ghost { background: transparent; color: var(--ink); }
.btn.ghost:hover { background: rgba(20,19,15,.05); }
.minor { margin-top: 15px; font-size: 12.5px; color: var(--muted); }
.minor a { text-decoration: underline; }

/* ============ Your Lists (custom collections) ============ */
.lists-row { max-width: 1280px; margin: 14px auto 0; }
.lists-head { font-size: 11px; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); margin: 0 0 7px; }
.lists-pills { display: flex; flex-wrap: wrap; gap: 7px; align-items: center; }
.lpill { font: inherit; font-size: 13px; font-weight: 600; cursor: pointer; padding: 7px 12px; border-radius: 999px;
  border: 1.5px solid var(--line); background: var(--paper); color: var(--ink); display: inline-flex; align-items: center; gap: 7px; transition: background .25s, border-color .25s, color .25s; }
.lpill:hover { border-color: var(--line2); }
.lpill .lc { font-size: 11px; font-weight: 800; color: var(--muted); background: var(--cream); border-radius: 999px; padding: 1px 7px; min-width: 17px; text-align: center; }
.lpill.on { background: var(--ink); color: var(--cream); border-color: var(--ink); }
.lpill.on .lc { background: rgba(255,255,255,.22); color: var(--cream); }
.lpill.new { border-style: dashed; color: var(--muted); }
.lpill.new:hover { color: var(--ink); border-color: var(--ink); }
.list-tools { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 10px; align-items: center; }
.ltool { font: inherit; font-size: 12.5px; font-weight: 600; cursor: pointer; padding: 6px 11px; border-radius: 8px; border: 1.5px solid var(--line); background: var(--paper); color: var(--ink); }
.ltool:hover { border-color: var(--line2); }
.ltool.done { background: transparent; border-color: var(--go); color: var(--go); font-weight: 800; }   /* green outline + green tick */
.ltool.add { color: #1c8a52; border-color: rgba(28,138,82,.5); }
.ltool.rm  { color: #b3413f; border-color: rgba(179,65,63,.5); }
.ltool.danger { color: var(--no); border-color: var(--no); }

/* dark variants inside the glass panel */
body[data-view="closet"] .lists-head { color: rgba(243,239,230,.55); }
body[data-view="closet"] .lpill { background: rgba(255,255,255,.07); border-color: rgba(255,255,255,.16); color: #f1ece0; }
body[data-view="closet"] .lpill .lc { background: rgba(255,255,255,.14); color: #f1ece0; }
body[data-view="closet"] .lpill.on { background: var(--cream); color: var(--ink); border-color: var(--cream); }
body[data-view="closet"] .lpill.on .lc { background: rgba(20,19,15,.16); color: var(--ink); }
body[data-view="closet"] .lpill.new { color: rgba(243,239,230,.6); }
body[data-view="closet"] .ltool { background: rgba(255,255,255,.07); border-color: rgba(255,255,255,.16); color: #f1ece0; }
body[data-view="closet"] .ltool.done { background: rgba(109,255,176,.08); border-color: #57d99a; color: #6dffb0; }   /* bright green outline + tick on the dark panel */
/* add/remove films is a List-view action — the closet doorway panel only shows it once you're already building (Done) */
body[data-view="closet"] .ltool.add,
body[data-view="closet"] .ltool.rm { display: none; }

/* add/remove mode on the wall: tiles become add/remove targets with a clear green/red affordance */
.edit-tag { position: absolute; top: 8px; left: 8px; right: 8px; display: none; justify-content: center;
  padding: 5px 0; border-radius: 8px; font-size: 12.5px; font-weight: 800; letter-spacing: .02em;
  color: #fff; z-index: 2; pointer-events: none; }   /* the shadow lives on the hovered badge only → always-on badges stay cheap */
/* Add AND Remove mode show the badge/outline only on the hovered tile — a shadowed badge + outline on
   every tile tanks scroll, and a remove list can be huge. The "Building/Removing …" banner is the cue.
   Only edit-in (already-added) keeps a flat, shadow-free badge so you can see what's in the list. */
.tile.edit-add:hover .edit-tag,
.tile.edit-rm:hover .edit-tag,
.tile.edit-in .edit-tag { display: flex; }
.tile.edit-add .edit-tag { background: #1c8a52; }
.tile.edit-rm  .edit-tag { background: #b3413f; }
.tile.edit-in  .edit-tag { background: rgba(20,19,15,.72); }
.tile.edit-in  .art { opacity: .82; }
/* the cover you're pointing at gets an unmistakable colour wash + bold ring + bigger badge */
.tile.edit-add:hover .art,
.tile.edit-rm:hover  .art { outline: 3px solid #1c8a52; outline-offset: 2px; }
.tile.edit-rm:hover  .art { outline-color: #c0403e; }
.tile.edit-add:hover .art::after,
.tile.edit-rm:hover  .art::after { content: ''; position: absolute; inset: 0; z-index: 1; pointer-events: none; }
.tile.edit-add:hover .art::after { background: rgba(20,120,70,.40); box-shadow: inset 0 0 0 2px rgba(255,255,255,.18); }
.tile.edit-rm:hover  .art::after { background: rgba(150,30,30,.46); box-shadow: inset 0 0 0 2px rgba(255,255,255,.18); }
.tile.edit-add:hover .edit-tag,
.tile.edit-rm:hover  .edit-tag { transform: scale(1.06); box-shadow: 0 4px 14px rgba(0,0,0,.45); }
body.building .tile .art { cursor: pointer; }
body.building .tile:active .art { transform: scale(.97); }
body.removing-mode .tile .art { cursor: pointer; }

/* "add to a list" control on the verdict card */
.card-lists { margin: 2px 0 18px; text-align: left; }
.card-lists .cl-head { font-size: 11px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); margin-bottom: 8px; }
.card-lists .lpill { font-size: 12.5px; }

.bar-l { display: flex; align-items: center; gap: 10px; }

/* keep facet dropdowns from spilling off a narrow screen */
.facet-pop { max-width: calc(100vw - 20px); }

/* ============ mobile / small screens ============ */
/* mobile "Filters" disclosure — keeps the List clean by default (desktop hides this button) */
.filters-btn { display: none; }
.filters-btn .fb-count { font-size: 11px; font-weight: 800; background: var(--ink); color: var(--cream); border-radius: 999px; padding: 1px 7px; }
.filters-btn .fb-car { color: var(--muted); font-size: 11px; transition: transform .2s; }
body.filters-open .filters-btn .fb-car { transform: rotate(180deg); }

@media (max-width: 640px) {
  .grid { grid-template-columns: repeat(auto-fill, minmax(116px, 1fr)); gap: 16px 10px; padding: 12px 12px 44px; }
  .chrome { padding: 10px 12px 8px; }
  .bar { gap: 10px; }
  .bar-l { min-width: 0; }                                  /* let the logo shrink so the toggle keeps its gutter */
  .logo { font-size: clamp(15px, 4.6vw, 22px); letter-spacing: .12em; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .views { flex: 0 0 auto; }                                /* the toggle keeps its size; the logo gives way */
  /* iOS Safari sizes native <button> by its own intrinsic metrics, so the List toggle came out shorter &
     narrower than the closet one. Pin EVERYTHING explicitly & symmetrically — same pill height, same button
     height, content width with no flex grow/shrink — so both toggles render identically. */
  .views, .closet-toggle { height: 40px; align-items: center; }
  .view, .ct-btn { height: 30px; box-sizing: border-box; flex: 0 0 auto; display: inline-flex; align-items: center; justify-content: center;
    padding: 0 12px; font-size: 12.5px; line-height: 1; white-space: nowrap; -webkit-appearance: none; appearance: none; }
  .view { min-width: 0; }
  /* content-width buttons ⇒ the 50% sliding pill no longer fits; use a solid active highlight (same as the closet switch) */
  .slider { display: none; }
  .view.is-active { background: var(--ink); }
  .view .ic { display: none; }
  .toolbar { gap: 7px; margin-top: 9px; }
  #q { flex: 1 1 130px; min-width: 120px; font-size: 16px; padding: 10px 13px; }   /* keep ≥16px so iOS doesn't zoom on focus */
  .facet-btn { padding: 9px 11px; font-size: 13px; }
  .sort { margin-left: 0; }
  .card { max-width: 94vw; padding: 22px 18px 18px; }
  .hero { width: 132px; }
  .cap .t { font-size: 13.5px; }
  /* the doorway glass panel: keep it inside the viewport when the closet is opened on a phone */
  body[data-view="closet"] .chrome { width: min(520px, 92vw); padding: 14px 16px 12px; }

  /* the List: show the compact "Filters" button and collapse the heavy rows until it's tapped */
  body[data-view="wall"] .filters-btn { display: inline-flex; align-items: center; gap: 7px; font: inherit;
    font-size: 13px; font-weight: 600; cursor: pointer; padding: 9px 13px; border: 1.5px solid var(--line);
    border-radius: 11px; background: var(--paper); color: var(--ink); white-space: nowrap; }
  body[data-view="wall"] .filters-btn.has-sel { border-color: var(--ink); }
  body[data-view="wall"]:not(.filters-open) .facets,
  body[data-view="wall"]:not(.filters-open) .sort,
  body[data-view="wall"]:not(.filters-open) .lists-row,
  body[data-view="wall"]:not(.filters-open) .active,
  body[data-view="wall"]:not(.filters-open) .status { display: none; }
  body[data-view="wall"].filters-open .facets { width: 100%; margin-top: 2px; }
}
@media (max-width: 380px) {
  .grid { grid-template-columns: repeat(auto-fill, minmax(104px, 1fr)); }
  .view, .ct-btn { font-size: 12px; padding: 0 9px; }
}

/* touch: hide the pointer-lock-only cursors/hints that don't apply without a mouse */
body.is-touch #x-cursor, body.is-touch .esc-hint { display: none !important; }

/* ---- in-page trailer player ---- */
.trailer-modal { position: fixed; inset: 0; z-index: 200; display: flex; align-items: center; justify-content: center;
  background: rgba(6,6,8,.92); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); animation: tmIn .2s ease; }
.trailer-modal[hidden] { display: none; }
@keyframes tmIn { from { opacity: 0 } to { opacity: 1 } }
.tm-frame { width: min(92vw, 1120px); aspect-ratio: 16 / 9; background: #000; border-radius: 10px; overflow: hidden;
  box-shadow: 0 24px 90px rgba(0,0,0,.65); }
.tm-frame iframe { width: 100%; height: 100%; border: 0; display: block; }
.tm-close { position: fixed; top: 16px; right: 20px; z-index: 201; width: 42px; height: 42px; border-radius: 999px; cursor: pointer;
  border: 1px solid rgba(255,255,255,.22); background: rgba(20,20,26,.72); color: #f3efe6; font-size: 24px; line-height: 38px; text-align: center;
  backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); transition: transform .12s; }
.tm-close:hover { transform: scale(1.08); }
