:root {
    --r-common:    #a3a3a3;
    --r-uncommon:  #c48b5c;
    --r-rare:      #82a9d9;
    --r-epic:      #b88ae0;
    --r-legendary: #e8c96a;
    --r-icon:      #ff8a5c;
}
[data-rarity="common"]    { --rc: var(--r-common); }
[data-rarity="uncommon"]  { --rc: var(--r-uncommon); }
[data-rarity="rare"]      { --rc: var(--r-rare); }
[data-rarity="epic"]      { --rc: var(--r-epic); }
[data-rarity="legendary"] { --rc: var(--r-legendary); }
[data-rarity="icon"]      { --rc: var(--r-icon); }

.rarity {
    display: inline-flex; align-items: center; gap: 7px;
    font-family: var(--sans);
    font-size: 0.56rem; font-weight: 600; letter-spacing: 0.22em; text-transform: uppercase;
    color: var(--rc, var(--silver-mid));
}
.rarity::before {
    content: '';
    width: 7px; height: 7px;
    transform: rotate(45deg);
    background: var(--rc, var(--silver-mid));
    box-shadow: 0 0 8px var(--rc, transparent);
}

[hidden] { display: none !important; }

.page-head.single { grid-template-columns: 1fr; }
.page-head .h1 .sub {
    display: block;
    font-size: 0.42em;
    font-style: italic;
    color: var(--gold-hi);
    margin-top: 10px;
}

/* ── Category nav (sticky under the top bar) ── */
.cat-nav {
    position: sticky;
    top: 47px;
    z-index: 40;
    margin-top: 40px;
    background: linear-gradient(180deg, rgba(23,5,4,0.9), rgba(23,5,4,0.7));
    backdrop-filter: blur(8px);
    border-bottom: 1px solid rgba(228,228,228,0.08);
}
.cat-nav-inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 40px;
    display: flex; gap: 6px;
    overflow-x: auto;
    scrollbar-width: none;
}
.cat-nav-inner::-webkit-scrollbar { display: none; }
.cat-nav a {
    flex-shrink: 0;
    display: flex; align-items: baseline; gap: 8px;
    padding: 16px 16px 14px;
    font-family: var(--sans);
    font-size: 0.64rem; font-weight: 600; letter-spacing: 0.22em; text-transform: uppercase;
    color: var(--silver-mid);
    text-decoration: none;
    border-bottom: 2px solid transparent;
    transition: color 0.25s, border-color 0.25s;
}
.cat-nav a small { font-weight: 400; color: var(--silver-dim); letter-spacing: 0.08em; }
.cat-nav a:hover { color: var(--white); }
.cat-nav a.on { color: var(--gold-hi); border-bottom-color: var(--gold-hi); }

section.cat { padding-top: 90px; padding-bottom: 40px; scroll-margin-top: 90px; }
.cat-head { display: flex; justify-content: space-between; align-items: flex-end; flex-wrap: wrap; gap: 24px; }

/* ── Set viewer ── */
.viewer {
    margin-top: 44px;
    display: grid;
    grid-template-columns: minmax(0, 1.7fr) minmax(300px, 1fr);
    border: 1px solid rgba(233,201,106,0.18);
    border-radius: 14px;
    overflow: hidden;
    background:
        radial-gradient(ellipse 60% 70% at 35% 20%, rgba(255,220,170,0.10), transparent 70%),
        linear-gradient(180deg, rgba(0,0,0,0.15), rgba(0,0,0,0.4));
    box-shadow: 0 30px 70px rgba(0,0,0,0.45);
}
.v-stage {
    --u: clamp(34px, 4.8vw, 70px);
    position: relative;
    min-height: calc(var(--u) * 3.4);
    display: flex; align-items: flex-end; justify-content: center;
    gap: clamp(0px, 0.6vw, 8px);
    padding: 30px 20px 46px;
}
.v-stage::after {
    content: '';
    position: absolute; left: 12%; right: 12%; bottom: 32px;
    height: 34px;
    background: radial-gradient(ellipse at center, rgba(0,0,0,0.5), transparent 70%);
    filter: blur(3px);
}
.v-slot {
    width: calc(var(--u) * var(--s));
    height: calc(var(--u) * var(--s));
    position: relative;
    z-index: 1;
}
.v-slot img {
    width: 100%; height: 100%;
    object-fit: contain;
    transform-origin: 50% 100%;
    filter: drop-shadow(0 0 1px rgba(255,236,200,0.5)) drop-shadow(0 10px 12px rgba(0,0,0,0.55));
    transition: transform 0.45s cubic-bezier(0.34, 1.56, 0.64, 1), opacity 0.25s ease;
}
.v-slot:hover img { transform: translateY(-8%) scale(1.12) rotate(-3deg); }
.viewer.swapping .v-slot img { opacity: 0; transform: translateY(12%) scale(0.92); }

.v-color {
    position: absolute; top: 16px; left: 16px;
    z-index: 2;
    display: flex;
    border: 1px solid rgba(228,228,228,0.18);
    border-radius: 999px;
    padding: 3px;
    background: rgba(0,0,0,0.3);
}
.v-color button {
    font-family: var(--sans);
    font-size: 0.56rem; font-weight: 600; letter-spacing: 0.2em; text-transform: uppercase;
    color: var(--silver-mid);
    background: none; border: 0;
    padding: 6px 12px;
    border-radius: 999px;
    cursor: var(--cur-hand, pointer);
}
.v-color button.on { background: var(--silver-hi); color: #1a0806; }

.v-info {
    padding: 34px 32px;
    border-left: 1px solid rgba(228,228,228,0.08);
    display: flex; flex-direction: column; justify-content: center;
}
.v-team {
    font-family: var(--serif); font-weight: 500;
    font-size: clamp(1.8rem, 3.4vw, 2.8rem);
    line-height: 1.05;
    color: var(--white);
    margin-top: 14px;
}
.v-year {
    font-family: var(--serif); font-style: italic;
    font-size: 1.2rem;
    color: var(--gold-hi);
    margin-top: 6px;
}
.v-meta {
    font-family: var(--sans);
    font-size: 0.8rem;
    color: var(--silver-dim);
    margin-top: 12px;
    line-height: 1.6;
}
.v-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 26px; }
.v-actions .btn { padding: 10px 16px; }

/* ── Filters ── */
.filters {
    display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between;
    gap: 14px;
    margin-top: 40px;
}
.pills { display: flex; flex-wrap: wrap; gap: 6px; }
.pill {
    font-family: var(--sans);
    font-size: 0.6rem; font-weight: 600; letter-spacing: 0.18em; text-transform: uppercase;
    color: var(--silver-mid);
    background: none;
    border: 1px solid rgba(228,228,228,0.16);
    padding: 8px 13px;
    border-radius: 999px;
    cursor: var(--cur-hand, pointer);
    transition: color 0.2s, border-color 0.2s, background 0.2s;
}
.pill small { font-weight: 400; opacity: 0.6; margin-left: 4px; letter-spacing: 0.05em; }
.pill:hover { color: var(--white); border-color: rgba(233,201,106,0.5); }
.pill.on { color: #2a0907; background: var(--gold-hi); border-color: var(--gold-hi); }
.search {
    position: relative;
    flex: 0 1 260px;
}
.search input {
    width: 100%;
    font-family: var(--sans);
    font-size: 0.85rem;
    color: var(--white);
    background: rgba(0,0,0,0.25);
    border: 1px solid rgba(228,228,228,0.16);
    border-radius: 999px;
    padding: 10px 16px 10px 38px;
    outline: none;
    transition: border-color 0.2s;
}
.search input::placeholder { color: var(--silver-dim); }
.search input:focus { border-color: var(--gold-hi); }
.search svg {
    position: absolute; left: 14px; top: 50%;
    width: 14px; height: 14px;
    transform: translateY(-50%);
    stroke: var(--silver-dim);
}

/* ── Set grid ── */
.set-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 14px;
    margin-top: 26px;
}
.set-card {
    position: relative;
    display: flex; flex-direction: column; align-items: center;
    padding: 16px 10px 14px;
    border-radius: 8px;
    border: 1px solid rgba(228,228,228,0.07);
    background: linear-gradient(180deg, rgba(255,255,255,0.03), rgba(0,0,0,0.2));
    cursor: var(--cur-hand, pointer);
    text-align: center;
    color: inherit;
    font: inherit;
    overflow: hidden;
    transition: transform 0.3s cubic-bezier(0.22, 1, 0.36, 1), border-color 0.3s, background 0.3s;
    animation: cardIn 0.45s cubic-bezier(0.22, 1, 0.36, 1) both;
}
@keyframes cardIn { from { opacity: 0; transform: translateY(14px); } }
.set-card::after {
    content: '';
    position: absolute; left: 0; right: 0; bottom: 0;
    height: 2px;
    background: var(--rc);
    opacity: 0.7;
}
.set-card:hover, .set-card.current {
    transform: translateY(-4px);
    border-color: color-mix(in srgb, var(--rc) 50%, transparent);
    background: linear-gradient(180deg, color-mix(in srgb, var(--rc) 10%, transparent), rgba(0,0,0,0.2));
}
.set-card.current { box-shadow: 0 0 0 1px var(--gold-hi); }
.set-card .imgs { position: relative; width: 96px; height: 96px; }
.set-card img {
    position: absolute; inset: 0;
    width: 100%; height: 100%;
    object-fit: contain;
    filter: drop-shadow(0 6px 8px rgba(0,0,0,0.5));
    transition: opacity 0.3s, transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
    transform-origin: 50% 100%;
}
.set-card img.alt { opacity: 0; }
.set-card:hover img.main { opacity: 0; }
.set-card:hover img.alt { opacity: 1; transform: scale(1.08); }
.set-card .n {
    font-family: var(--serif); font-weight: 500;
    font-size: 0.92rem;
    color: var(--white);
    margin-top: 10px;
    line-height: 1.2;
}
.set-card .y {
    font-family: var(--sans);
    font-size: 0.62rem; letter-spacing: 0.16em;
    color: var(--silver-dim);
    margin-top: 3px;
}
.set-card .rarity { margin-top: 8px; font-size: 0.5rem; }
.empty {
    grid-column: 1 / -1;
    padding: 50px 0;
    text-align: center;
    font-family: var(--sans);
    color: var(--silver-dim);
}
/* A taste of each catalogue; the rest is in the game */
.in-khora {
    margin-top: 28px;
    text-align: center;
    font-family: var(--sans);
    font-size: 0.82rem;
    color: var(--silver-mid);
}
.in-khora a {
    margin-left: 4px;
    color: var(--gold-hi);
    font-weight: 600;
    text-decoration: none;
    white-space: nowrap;
    border-bottom: 1px solid rgba(233,201,106,0.35);
    transition: border-color 0.2s;
}
.in-khora a:hover { border-color: var(--gold-hi); }

/* ── Boards ── */
.tile-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 18px;
    margin-top: 40px;
}
.tile {
    background: none; border: 0; padding: 0;
    color: inherit; font: inherit; text-align: left;
    cursor: zoom-in;
    perspective: 700px;
}
.tile .art {
    position: relative;
    aspect-ratio: 1;
    border-radius: 4px;
    overflow: hidden;
    box-shadow: 0 0 0 1px rgba(0,0,0,0.6), 0 0 0 3px color-mix(in srgb, var(--rc) 45%, transparent), 0 16px 30px rgba(0,0,0,0.5);
    transition: transform 0.45s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.35s;
    transform-origin: 50% 80%;
}
.tile .art img { width: 100%; height: 100%; object-fit: cover; display: block; }
.tile:hover .art {
    transform: rotateX(14deg) translateY(-6px);
    box-shadow: 0 0 0 1px rgba(0,0,0,0.6), 0 0 0 3px var(--rc), 0 26px 40px rgba(0,0,0,0.6), 0 0 30px color-mix(in srgb, var(--rc) 35%, transparent);
}
.tile .cap { margin-top: 12px; }
.tile .cap p {
    font-family: var(--serif); font-weight: 500;
    font-size: 0.95rem;
    color: var(--white);
    line-height: 1.25;
}
.tile .cap .rarity { margin-top: 5px; }

/* ── Stadiums: board seated inside its frame, sized like the game does ── */
.stad-grid { grid-template-columns: repeat(3, 1fr); gap: 28px; }
/* The hover used to animate `filter` from one drop-shadow to two. A
   drop-shadow has to walk the alpha silhouette of everything below it —
   here two stacked PNGs — and changing its parameters re-does that every
   single frame. Measured on this page: p90 50ms a frame, peaking at 67ms,
   against 16.8ms once the filter stops animating. That was the lag.
   So the resting shadow is now CONSTANT — rasterised once, then merely
   transformed — and the only animated properties are transform and the
   glow's opacity, both of which the compositor handles on its own. */
.stad {
    position: relative;
    aspect-ratio: 1;
    transition: transform 0.38s cubic-bezier(0.22, 1, 0.36, 1);
    filter: drop-shadow(0 20px 30px rgba(0,0,0,0.55));
}
/* The rarity halo, as its own layer so it can fade instead of being
   recomputed. It has to hang off the TILE, not off .stad: a filtered
   element renders its whole subtree to a texture before filtering, so a
   child fading inside .stad would drag the drop-shadow back into every
   frame — the exact cost this change exists to remove. Out here it is
   just an opacity, which the compositor does for free.
   It is deliberately soft and wide; at 24px of blur the old drop-shadow
   read as a halo rather than a silhouette anyway, so little is lost.
   Painted before .stad in DOM order, and both are positioned at z-index
   auto, so it sits behind the stadium without needing a z-index. */
.stad-grid .tile { position: relative; }
.stad-grid .tile::before {
    content: '';
    position: absolute;
    left: -6%; top: -6%; width: 112%;
    aspect-ratio: 1;
    border-radius: 50%;
    background: radial-gradient(closest-side,
        color-mix(in srgb, var(--rc) 30%, transparent),
        color-mix(in srgb, var(--rc) 12%, transparent) 55%,
        transparent 78%);
    opacity: 0;
    transition: opacity 0.28s ease;
    pointer-events: none;
}
.stad .pitch {
    position: absolute;
    left: 50%; top: 50%;
    width: calc(var(--pitch) * 1%);
    aspect-ratio: 1;
    transform: translate(-50%, -50%);
    object-fit: cover;
}
.stad .frame {
    position: absolute; inset: 0;
    width: 100%; height: 100%;
    object-fit: contain;
}
.tile:hover .stad { transform: translateY(-6px) scale(1.03); }
.stad-grid .tile:hover::before { opacity: 1; }
.stad-grid .tile .cap { text-align: center; }
.stad-grid .tile .cap .rarity { justify-content: center; }

/* ── Titles ── */
.guess-toggle {
    display: inline-flex; align-items: center; gap: 12px;
    font-family: var(--sans);
    font-size: 0.64rem; font-weight: 600; letter-spacing: 0.2em; text-transform: uppercase;
    color: var(--silver-hi);
    background: none; border: 0;
    cursor: var(--cur-hand, pointer);
}
.guess-toggle .sw {
    width: 38px; height: 20px;
    border-radius: 999px;
    background: rgba(228,228,228,0.15);
    position: relative;
    transition: background 0.25s;
}
.guess-toggle .sw::after {
    content: '';
    position: absolute; top: 3px; left: 3px;
    width: 14px; height: 14px; border-radius: 50%;
    background: var(--silver-hi);
    transition: transform 0.25s;
}
.guess-toggle[aria-pressed="true"] .sw { background: var(--gold); }
.guess-toggle[aria-pressed="true"] .sw::after { transform: translateX(18px); }

.title-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(118px, 1fr));
    gap: 10px;
}
.title-tile {
    display: flex; flex-direction: column; align-items: center;
    padding: 14px 6px 12px;
    border-radius: 10px;
    transition: background 0.3s;
}
.title-tile:hover { background: rgba(255,255,255,0.04); }
.title-tile .disc {
    width: 92px; height: 92px;
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    background: radial-gradient(circle at 50% 40%, rgba(247,239,221,0.16), rgba(247,239,221,0.03) 70%);
    box-shadow: inset 0 0 0 1px rgba(228,228,228,0.08);
    transition: transform 0.45s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.3s;
}
.title-tile img {
    width: 80px; height: 80px;
    object-fit: contain;
    filter: drop-shadow(0 0 1px rgba(255,240,210,0.5)) drop-shadow(0 6px 8px rgba(0,0,0,0.5));
}
.title-tile:hover .disc { transform: scale(1.14) rotate(-4deg); box-shadow: inset 0 0 0 1px rgba(233,201,106,0.4), 0 0 26px rgba(233,201,106,0.2); }
.title-tile p {
    font-family: var(--sans);
    font-size: 0.66rem; letter-spacing: 0.06em;
    color: var(--silver-hi);
    margin-top: 10px;
    text-align: center;
    transition: filter 0.3s, opacity 0.3s;
}

/* Guess mode: one title at a time, four choices */
.title-stage { margin-top: 36px; }
.tg {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 44px;
    align-items: center;
    padding: 30px 36px;
    border: 1px solid rgba(233,201,106,0.2);
    border-radius: 14px;
    background: linear-gradient(135deg, rgba(233,201,106,0.06), rgba(0,0,0,0.25));
}
.tg-disc {
    width: 220px; height: 220px;
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    background: radial-gradient(circle at 50% 40%, rgba(247,239,221,0.18), rgba(247,239,221,0.03) 70%);
    box-shadow: inset 0 0 0 1px rgba(228,228,228,0.1), 0 0 44px color-mix(in srgb, var(--rc, #e9c46a) 22%, transparent);
    transition: transform 0.45s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.3s;
}
.tg-disc img {
    width: 180px; height: 180px;
    object-fit: contain;
    filter: drop-shadow(0 0 1px rgba(255,240,210,0.5)) drop-shadow(0 10px 14px rgba(0,0,0,0.55));
}
.tg-disc.enter img { animation: tgIn 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) both; }
@keyframes tgIn { from { opacity: 0; transform: scale(0.6) rotate(-12deg); } }
.tg-disc.hit {
    transform: scale(1.08) rotate(-4deg);
    box-shadow: inset 0 0 0 2px var(--gold-hi), 0 0 60px rgba(233,201,106,0.5);
}
.tg-disc.miss { animation: tgShake 0.45s; }
@keyframes tgShake { 20%, 60% { transform: translateX(-8px); } 40%, 80% { transform: translateX(8px); } }
.tg-q { font-family: var(--serif); font-size: 1.6rem; color: var(--white); }
.tg-opts { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 18px; }
.tg-opts button {
    display: flex; align-items: center; gap: 10px;
    padding: 12px 14px;
    border-radius: 8px;
    border: 1px solid rgba(228,228,228,0.16);
    background: rgba(0,0,0,0.25);
    color: var(--silver-hi);
    font-family: var(--sans); font-size: 0.9rem;
    text-align: left;
    cursor: var(--cur-hand, pointer);
    transition: border-color 0.2s, background 0.2s, color 0.2s, opacity 0.2s;
}
.tg-opts button i {
    flex: none;
    display: inline-flex; align-items: center; justify-content: center;
    width: 20px; height: 20px;
    border-radius: 50%;
    border: 1px solid rgba(228,228,228,0.2);
    font-style: normal; font-size: 0.6rem;
    color: var(--silver-dim);
}
.tg-opts button:hover:not(:disabled) { border-color: var(--gold-hi); color: var(--white); background: rgba(233,201,106,0.08); }
.tg-opts button:disabled { cursor: default; opacity: 0.45; }
.tg-opts button.right {
    opacity: 1;
    color: #2a0907;
    border-color: var(--gold-hi);
    background: linear-gradient(135deg, #a57c2a, var(--gold-hi) 50%, var(--gold));
}
.tg-opts button.right i { border-color: rgba(42,9,7,0.4); color: #2a0907; }
.tg-opts button.wrong { opacity: 1; color: #ffb4a8; border-color: rgba(255,120,100,0.6); background: rgba(160,30,20,0.35); }
.tg-score {
    display: flex; flex-wrap: wrap; gap: 8px 24px;
    margin-top: 20px;
    font-family: var(--sans);
    font-size: 0.6rem; letter-spacing: 0.2em; text-transform: uppercase;
    color: var(--silver-dim);
}
.tg-score b {
    margin-left: 6px;
    font-family: var(--serif); font-size: 1.15rem; font-weight: 500;
    letter-spacing: 0;
    color: var(--gold-hi);
}
.titles-cta {
    display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 16px;
    margin-top: 36px;
    padding: 22px 26px;
    border: 1px solid rgba(233,201,106,0.2);
    border-radius: 10px;
    background: linear-gradient(90deg, rgba(233,201,106,0.07), transparent);
}
.titles-cta p { font-family: var(--serif); font-size: 1.2rem; color: var(--white); }

/* ── Film & print artwork ── */
.art-tile { display: block; width: 100%; --rc: rgba(228,228,228,0.3); }
.art-tile .art { aspect-ratio: auto; border-radius: 3px; }
.art-tile .art img, .art-tile .art video { height: auto; object-fit: fill; }
.art-tile .art video { display: block; width: 100%; aspect-ratio: 1; }
.art-tile:hover .art { transform: translateY(-6px) rotateX(5deg); }
.art-tile .cap .meta {
    display: block;
    margin-top: 4px;
    font-family: var(--sans);
    font-size: 0.56rem; font-weight: 600; letter-spacing: 0.22em; text-transform: uppercase;
    color: var(--silver-dim);
}

.tarot-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 40px 34px;
    max-width: 940px;
    margin: 44px auto 0;
}
.tarot-grid .art {
    aspect-ratio: 5 / 7;
    display: flex; align-items: flex-end; justify-content: center;
    overflow: visible;
    box-shadow: none;
}
.tarot-grid .art img {
    width: auto; max-width: 100%; max-height: 100%;
    border-radius: 6px;
    box-shadow: 0 18px 34px rgba(0,0,0,0.55);
    transition: box-shadow 0.35s;
}
.tarot-grid .tile:hover .art { box-shadow: none; transform: translateY(-10px) rotate(-1.5deg); }
.tarot-grid .tile:hover .art img { box-shadow: 0 30px 44px rgba(0,0,0,0.6), 0 0 28px rgba(233,201,106,0.25); }
.tarot-grid .cap { text-align: center; }

.poster-feature {
    display: grid;
    grid-template-columns: 0.72fr 1fr 0.9fr;
    gap: 28px;
    align-items: center;
    margin-top: 44px;
}
.pf-text h3 {
    margin-top: 10px;
    font-family: var(--serif); font-weight: 500;
    font-size: 2rem;
    color: var(--white);
}
.pf-text .meta {
    display: block;
    margin-top: 4px;
    font-family: var(--sans);
    font-size: 0.6rem; font-weight: 600; letter-spacing: 0.22em; text-transform: uppercase;
    color: var(--silver-dim);
}
.pf-text > p:last-child { margin-top: 18px; color: var(--silver-mid); line-height: 1.6; }

.poster-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 28px;
    align-items: start;
    margin-top: 40px;
}
/* Same frame for every poster; the lightbox still shows each one uncropped */
.poster-grid .art { aspect-ratio: 3 / 4; }
.poster-grid .art img { height: 100%; object-fit: cover; }

.other-grid {
    columns: 3;
    column-gap: 24px;
    margin-top: 44px;
}
.other-grid .tile { break-inside: avoid; margin-bottom: 28px; }

/* ── Lightbox ── */
.lightbox {
    position: fixed; inset: 0;
    z-index: 90;
    display: flex; align-items: center; justify-content: center;
    padding: 70px 70px 40px;
    background: rgba(10,3,2,0.92);
    backdrop-filter: blur(6px);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s;
}
.lightbox.open { opacity: 1; pointer-events: auto; }
.lb-body {
    display: flex; flex-direction: column; align-items: center;
    gap: 16px;
    max-width: 100%;
    transform: scale(0.96);
    transition: transform 0.35s cubic-bezier(0.22, 1, 0.36, 1);
}
.lightbox.open .lb-body { transform: none; }
.lb-media {
    position: relative;
    width: min(78vh, 86vw);
    height: min(78vh, 86vw);
}
.lb-media > img, .lb-media > video { width: 100%; height: 100%; object-fit: contain; display: block; }
.lb-cap[data-rarity=""] .rarity { color: var(--silver-dim); }
.lb-cap[data-rarity=""] .rarity::before { display: none; }
.lb-media .stad { width: 100%; height: 100%; filter: drop-shadow(0 30px 40px rgba(0,0,0,0.6)); }
.lb-cap { text-align: center; }
.lb-cap p { font-family: var(--serif); font-size: 1.3rem; color: var(--white); }
.lb-cap .rarity { justify-content: center; margin-top: 6px; }
.lb-btn {
    display: flex; align-items: center; justify-content: center;
    position: absolute;
    width: 44px; height: 44px;
    border-radius: 50%;
    border: 1px solid rgba(228,228,228,0.25);
    background: rgba(0,0,0,0.35);
    color: var(--white);
    font-size: 1rem;
    cursor: var(--cur-hand, pointer);
    transition: border-color 0.2s, background 0.2s;
}
.lb-btn:hover { border-color: var(--gold-hi); background: rgba(233,201,106,0.12); }
.lb-close { top: 18px; right: 18px; }
.lb-prev { left: 18px; top: 50%; transform: translateY(-50%); }
.lb-next { right: 18px; top: 50%; transform: translateY(-50%); }

@media (max-width: 1000px) {
    .tile-grid { grid-template-columns: repeat(3, 1fr); }
    .tile-grid:not(.stad-grid) .tile:nth-child(n+7) { display: none; }
}
@media (max-width: 860px) {
    .cat-nav { top: 45px; }
    .cat-nav-inner { padding: 0 12px; }
    .viewer { grid-template-columns: 1fr; }
    .v-info { border-left: 0; border-top: 1px solid rgba(228,228,228,0.08); padding: 24px 22px; }
    .stad-grid { grid-template-columns: repeat(2, 1fr); gap: 18px; }
    .poster-feature { grid-template-columns: 0.72fr 1fr; }
    .pf-text { grid-column: 1 / -1; }
    .other-grid { columns: 2; }
    .lightbox { padding: 60px 12px 24px; }
    .lb-prev, .lb-next { top: auto; bottom: 18px; transform: none; }
}
@media (max-width: 560px) {
    .tile-grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
    .set-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }
    .v-slot.edge { display: none; }
    .search { flex-basis: 100%; }
    .tarot-grid, .poster-grid { grid-template-columns: repeat(2, 1fr); gap: 28px 14px; }
    .poster-feature { grid-template-columns: 1fr; }
    .other-grid { columns: 1; }
    .title-grid { grid-template-columns: repeat(3, 1fr); gap: 4px; }
    .title-tile .disc { width: 78px; height: 78px; }
    .title-tile img { width: 66px; height: 66px; }
    .tg { grid-template-columns: 1fr; justify-items: center; gap: 22px; padding: 24px 16px; }
    .tg-disc { width: 170px; height: 170px; }
    .tg-disc img { width: 140px; height: 140px; }
    .tg-side { width: 100%; }
    .tg-q { text-align: center; font-size: 1.3rem; }
    .tg-opts button { padding: 11px 10px; font-size: 0.82rem; }
    .tg-score { justify-content: center; }
}
