/* ─── DESIGN TOKENS ─────────────────────────────────────────────── */
:root {
    --bg: #0a0a0a;
    --bg-2: #111111;
    --bg-3: #1a1a1a;
    --surface: #141414;
    --surface-2: #1e1e1e;
    --surface-3: #242424;
    --text: #f0f0f0;
    --text-2: #a0a0a0;
    --text-3: #606060;
    --line: rgba(255,255,255,0.08);
    --line-2: rgba(255,255,255,0.14);
    --accent: #ffffff;
    --accent-dim: rgba(255,255,255,0.12);
    --danger: #ff4d4d;
    --danger-dim: rgba(255,77,77,0.12);
    --success: #3ddc84;
    --success-dim: rgba(61,220,132,0.12);
    --warning: #ffd166;
    --glow: 0 0 40px rgba(255,255,255,0.06);
    --glow-strong: 0 0 60px rgba(255,255,255,0.12);
    --radius: 12px;
    --radius-sm: 8px;
    --radius-lg: 18px;
    --shadow: 0 8px 32px rgba(0,0,0,0.6);
    --shadow-lg: 0 20px 60px rgba(0,0,0,0.8);
    --grad-main: linear-gradient(135deg, #1a1a1a 0%, #0a0a0a 50%, #1a1a1a 100%);
    --grad-card: linear-gradient(145deg, #1e1e1e, #141414);
    --grad-accent: linear-gradient(135deg, #ffffff, #c0c0c0);
    --grad-border: linear-gradient(135deg, rgba(255,255,255,0.15), rgba(255,255,255,0.04));
    --transition: 0.22s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-slow: 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    /* Game category colors */
    --codm: #ff6a00;
    --codm-dim: rgba(255,106,0,0.12);
    --codm-glow: rgba(255,106,0,0.3);
    --mlbb: #00c2ff;
    --mlbb-dim: rgba(0,194,255,0.12);
    --mlbb-glow: rgba(0,194,255,0.3);
}

/* ─── CSS ICON SYSTEM ───────────────────────────────────────────── */
.ico {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    flex-shrink: 0;
}
/* Store icon */
.ico-store::before { content: "⬡"; font-size: 18px; }
/* Shield icon */
.ico-shield::before { content: "◈"; font-size: 15px; }
/* Eye icon (view) */
.ico-eye { position: relative; }
.ico-eye::before {
    content: "";
    width: 14px; height: 9px;
    border: 2px solid currentColor;
    border-radius: 50% 50% 50% 50% / 60% 60% 40% 40%;
    display: block;
}
.ico-eye::after {
    content: "";
    position: absolute;
    width: 5px; height: 5px;
    background: currentColor;
    border-radius: 50%;
}
/* Arrow down */
.ico-chevron::before { content: "›"; font-size: 20px; display: block; transform: rotate(90deg); line-height: 1; }
.ico-chevron.up::before { transform: rotate(-90deg); }
/* Plus */
.ico-plus::before { content: "+"; font-size: 20px; line-height: 1; }
/* Grid */
.ico-grid::before { content: "⊞"; font-size: 17px; }
/* Edit */
.ico-edit::before { content: "✎"; font-size: 16px; }
/* Trash */
.ico-trash::before { content: "⌫"; font-size: 16px; }
/* Check */
.ico-check::before { content: "✓"; font-size: 15px; font-weight: 900; }
/* Arrow back */
.ico-back::before { content: "←"; font-size: 16px; }
/* Logout */
.ico-logout::before { content: "⏻"; font-size: 15px; }
/* Image */
.ico-image::before { content: "◻"; font-size: 16px; }
/* Star */
.ico-star::before { content: "✦"; font-size: 13px; }
/* Lock */
.ico-lock::before { content: "⊝"; font-size: 15px; }
/* User */
.ico-user::before { content: "◯"; font-size: 15px; }
/* Tag/price */
.ico-tag::before { content: "◇"; font-size: 14px; }
/* Server */
.ico-server::before { content: "▣"; font-size: 13px; }

/* ─── RESET & BASE ──────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { color-scheme: dark; scroll-behavior: smooth; font-size: 16px; }
body {
    min-height: 100vh;
    background: var(--bg);
    color: var(--text);
    font-family: 'Inter', ui-sans-serif, system-ui, -apple-system, sans-serif;
    line-height: 1.6;
    background-image:
        radial-gradient(ellipse 80% 50% at 50% -20%, rgba(255,255,255,0.05) 0%, transparent 60%),
        radial-gradient(ellipse 50% 40% at 80% 80%, rgba(255,255,255,0.02) 0%, transparent 50%);
    background-attachment: fixed;
}
a { color: inherit; text-decoration: none; }
button, input, textarea, select { font: inherit; color: inherit; }
button { cursor: pointer; border: none; background: none; }
img { display: block; max-width: 100%; }
h1, h2, h3, h4 { line-height: 1.1; letter-spacing: -0.04em; }

/* ─── ANIMATIONS ────────────────────────────────────────────────── */
@keyframes fadeUp {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}
@keyframes shimmer {
    0% { background-position: -200% 0; }
    100% { background-position: 200% 0; }
}
@keyframes pulseGlow {
    0%, 100% { opacity: 0.4; }
    50% { opacity: 0.8; }
}
@keyframes scanLine {
    0% { transform: translateY(-100%); }
    100% { transform: translateY(100vh); }
}
@keyframes borderRotate {
    0% { --angle: 0deg; }
    100% { --angle: 360deg; }
}
@keyframes slideIn {
    from { opacity: 0; transform: translateX(-10px); }
    to { opacity: 1; transform: translateX(0); }
}
/* NEW: Title reveal — letters drop in staggered */
@keyframes letterDrop {
    0%   { opacity: 0; transform: translateY(-32px) rotateX(60deg); filter: blur(4px); }
    60%  { opacity: 1; transform: translateY(4px) rotateX(-4deg); filter: blur(0); }
    100% { opacity: 1; transform: translateY(0) rotateX(0deg); }
}
/* NEW: Eyebrow slide from left */
@keyframes eyebrowSlide {
    from { opacity: 0; transform: translateX(-24px) skewX(-6deg); }
    to   { opacity: 1; transform: translateX(0) skewX(0deg); }
}
/* NEW: Hero description fade up with blur */
@keyframes blurFadeUp {
    from { opacity: 0; transform: translateY(12px); filter: blur(6px); }
    to   { opacity: 1; transform: translateY(0); filter: blur(0); }
}
/* NEW: Stat counter pop */
@keyframes statPop {
    0%   { opacity: 0; transform: scale(0.6) translateY(8px); }
    70%  { transform: scale(1.08) translateY(-2px); }
    100% { opacity: 1; transform: scale(1) translateY(0); }
}
/* NEW: Banner parallax drift */
@keyframes bannerDrift {
    0%, 100% { transform: scale(1.06) translateX(0); }
    50%       { transform: scale(1.06) translateX(-8px); }
}
/* NEW: Banner title glitch sweep */
@keyframes glitchSweep {
    0%   { clip-path: inset(0 100% 0 0); }
    40%  { clip-path: inset(0 0% 0 0); }
    100% { clip-path: inset(0 0% 0 0); }
}
/* NEW: Category tab underline slide */
@keyframes tabLineSlide {
    from { transform: scaleX(0); }
    to   { transform: scaleX(1); }
}
/* NEW: Banner shimmer overlay */
@keyframes bannerShimmer {
    0%   { opacity: 0; transform: translateX(-100%) skewX(-20deg); }
    40%  { opacity: 0.08; }
    100% { opacity: 0; transform: translateX(120%) skewX(-20deg); }
}
/* NEW: Floating particle drift */
@keyframes particleDrift {
    0%   { transform: translateY(0) translateX(0) scale(1); opacity: 0.15; }
    33%  { transform: translateY(-18px) translateX(10px) scale(1.1); opacity: 0.3; }
    66%  { transform: translateY(-8px) translateX(-6px) scale(0.9); opacity: 0.2; }
    100% { transform: translateY(0) translateX(0) scale(1); opacity: 0.15; }
}
/* NEW: Card entrance from bottom with spring */
@keyframes cardSpring {
    0%   { opacity: 0; transform: translateY(28px) scale(0.96); }
    65%  { opacity: 1; transform: translateY(-4px) scale(1.01); }
    100% { opacity: 1; transform: translateY(0) scale(1); }
}
/* NEW: Glow pulse for active category */
@keyframes categoryGlow {
    0%, 100% { box-shadow: 0 0 0 0 transparent; }
    50%       { box-shadow: 0 0 24px 2px var(--cat-glow, rgba(255,255,255,0.15)); }
}

/* Ambient scan line on body */
body::before {
    content: "";
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 2px;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.03), transparent);
    animation: scanLine 8s linear infinite;
    pointer-events: none;
    z-index: 9999;
}

/* ─── NOISE TEXTURE ─────────────────────────────────────────────── */
body::after {
    content: "";
    position: fixed;
    inset: 0;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)' opacity='0.03'/%3E%3C/svg%3E");
    pointer-events: none;
    z-index: 9998;
    opacity: 0.4;
}

/* ─── SCROLLBAR ─────────────────────────────────────────────────── */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--bg-2); }
::-webkit-scrollbar-thumb { background: var(--bg-3); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: var(--text-3); }

/* ─── SITE HEADER ───────────────────────────────────────────────── */
.site-header, .admin-header {
    position: sticky; top: 0; z-index: 100;
    display: flex; align-items: center; justify-content: space-between;
    gap: 16px; min-height: 64px;
    padding: 0 clamp(20px, 4vw, 56px);
    background: rgba(10,10,10,0.85);
    border-bottom: 1px solid var(--line);
    backdrop-filter: blur(20px) saturate(1.5);
    -webkit-backdrop-filter: blur(20px) saturate(1.5);
}
.site-header::after {
    content: "";
    position: absolute;
    bottom: 0; left: 0; right: 0; height: 1px;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.1), transparent);
}

.brand {
    display: inline-flex; align-items: center; gap: 12px;
    font-weight: 800; font-size: 15px; letter-spacing: -0.02em;
    animation: fadeIn 0.5s ease both;
}
.brand:hover { opacity: 0.85; }
.brand-mark {
    width: 40px; height: 40px;
    display: grid; place-items: center;
    background: linear-gradient(135deg, #fff 0%, #888 100%);
    color: #000; border-radius: 10px;
    font-weight: 900; font-size: 13px;
    letter-spacing: -0.06em;
    box-shadow: 0 4px 16px rgba(255,255,255,0.15), inset 0 1px 0 rgba(255,255,255,0.5);
    position: relative; overflow: hidden;
}
.brand-mark::after {
    content: "";
    position: absolute; inset: 0;
    background: linear-gradient(135deg, rgba(255,255,255,0.3) 0%, transparent 60%);
}
.brand-mark.small { width: 32px; height: 32px; border-radius: 8px; font-size: 11px; }

.header-actions { display: flex; align-items: center; gap: 8px; }
.header-actions form { margin: 0; }

/* Header status badge */
.header-status {
    display: flex; align-items: center; gap: 6px;
    padding: 4px 10px; border-radius: 99px;
    background: var(--accent-dim); border: 1px solid var(--line-2);
    font-size: 11px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase;
    color: var(--text-2);
}
.header-status-dot {
    width: 6px; height: 6px; border-radius: 50%;
    background: var(--success);
    box-shadow: 0 0 8px var(--success);
    animation: pulseGlow 2s ease infinite;
}

/* ─── PAGE SHELL ────────────────────────────────────────────────── */
.page-shell {
    width: min(1200px, calc(100% - 40px));
    margin: 0 auto;
    padding: 64px 0 80px;
    animation: fadeUp 0.5s ease both;
}

/* ─── HERO SECTION ──────────────────────────────────────────────── */
.hero {
    max-width: 760px;
    margin-bottom: 56px;
    position: relative;
}
.hero::before {
    content: "";
    position: absolute;
    top: -40px; left: -60px;
    width: 400px; height: 300px;
    background: radial-gradient(ellipse, rgba(255,255,255,0.04) 0%, transparent 70%);
    pointer-events: none;
}

.eyebrow {
    display: inline-flex; align-items: center; gap: 8px;
    margin-bottom: 16px;
    color: var(--text-3);
    font-size: 11px; font-weight: 800;
    letter-spacing: 0.16em; text-transform: uppercase;
    animation: eyebrowSlide 0.7s cubic-bezier(0.4,0,0.2,1) 0.15s both;
}
.eyebrow::before {
    content: "";
    width: 20px; height: 1px;
    background: var(--text-3);
}

h1 {
    font-size: clamp(36px, 6vw, 72px);
    font-weight: 900;
    line-height: 1;
    letter-spacing: -0.05em;
    margin-bottom: 16px;
    background: linear-gradient(135deg, #ffffff 0%, #888888 60%, #ffffff 100%);
    background-size: 200% auto;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: shimmer 6s linear infinite;
    perspective: 400px;
}
/* Animated title spans (added via JS) */
.title-char {
    display: inline-block;
    animation: letterDrop 0.55s cubic-bezier(0.3,0,0.2,1) both;
}
h2 { font-size: clamp(20px, 3vw, 28px); font-weight: 800; }

.hero > p:not(.eyebrow) {
    font-size: 16px; color: var(--text-2); max-width: 480px;
    animation: blurFadeUp 0.7s ease 0.55s both;
}
.hero > p:last-child {
    font-size: 16px; color: var(--text-2); max-width: 480px;
}

/* Hero stats row */
.hero-stats {
    display: flex; gap: 32px;
    margin-top: 28px; padding-top: 28px;
    border-top: 1px solid var(--line);
}
.hero-stat { display: grid; gap: 2px; }
.hero-stat-num {
    font-size: 22px; font-weight: 900; letter-spacing: -0.04em; color: var(--text);
    animation: statPop 0.6s cubic-bezier(0.3,0,0.2,1) both;
}
.hero-stat:nth-child(1) .hero-stat-num { animation-delay: 0.65s; }
.hero-stat:nth-child(2) .hero-stat-num { animation-delay: 0.75s; }
.hero-stat:nth-child(3) .hero-stat-num { animation-delay: 0.85s; }
.hero-stat:nth-child(4) .hero-stat-num { animation-delay: 0.95s; }
.hero-stat-label { font-size: 11px; color: var(--text-3); font-weight: 600; text-transform: uppercase; letter-spacing: 0.08em; }

/* ─── LISTING GRID ──────────────────────────────────────────────── */
.listing-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
    gap: 20px;
    align-items: start;
}

/* ─── LISTING CARD ──────────────────────────────────────────────── */
.listing-card {
    position: relative;
    background: var(--grad-card);
    border-radius: var(--radius-lg);
    overflow: hidden;
    transition: transform 0.28s cubic-bezier(0.4,0,0.2,1), box-shadow 0.28s cubic-bezier(0.4,0,0.2,1), border-color 0.28s ease, opacity 0.28s ease;
    animation: cardSpring 0.55s cubic-bezier(0.3,0,0.2,1) both;
    border: 1px solid var(--line);
}
.listing-card::before {
    content: "";
    position: absolute;
    inset: 0; border-radius: inherit;
    background: linear-gradient(135deg, rgba(255,255,255,0.05) 0%, transparent 50%);
    pointer-events: none; z-index: 0;
}
.listing-card::after {
    content: "";
    position: absolute;
    inset: -1px; border-radius: inherit;
    background: linear-gradient(135deg, rgba(255,255,255,0.12), transparent, rgba(255,255,255,0.04));
    z-index: 0; pointer-events: none;
    opacity: 0;
    transition: var(--transition);
}
.listing-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg), 0 0 40px rgba(255,255,255,0.05);
    border-color: rgba(255,255,255,0.12);
}
.listing-card:hover::after { opacity: 1; }
.listing-card > * { position: relative; z-index: 1; }

/* Sold card dimming */
.listing-card.sold { opacity: 0.55; }
.listing-card.sold:hover { opacity: 0.7; }

/* ─── CARD MEDIA ────────────────────────────────────────────────── */
.card-media {
    position: relative;
    aspect-ratio: 16 / 10;
    background: var(--bg-3);
    overflow: hidden;
}
.card-media::after {
    content: "";
    position: absolute; inset: 0;
    background: linear-gradient(to bottom, transparent 50%, rgba(0,0,0,0.6) 100%);
    z-index: 1;
}
.card-media > img {
    width: 100%; height: 100%;
    object-fit: cover;
    transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    filter: grayscale(20%);
}
.listing-card:hover .card-media > img {
    transform: scale(1.06);
    filter: grayscale(0%);
}
.media-placeholder {
    height: 100%;
    display: grid; place-items: center;
    color: var(--text-3); font-size: 13px;
}
.media-placeholder::before { content: "◻"; font-size: 32px; display: block; margin-bottom: 8px; }

.status-badge, .image-count {
    position: absolute; z-index: 2;
    top: 14px;
    padding: 5px 10px;
    border-radius: var(--radius-sm);
    font-size: 10px; font-weight: 800;
    letter-spacing: 0.1em; text-transform: uppercase;
}
.status-badge {
    left: 14px;
    background: rgba(255,255,255,0.92);
    color: #000;
    box-shadow: 0 2px 8px rgba(0,0,0,0.4);
}
.status-badge.reserved {
    background: rgba(255,209,102,0.9);
    color: #000;
}
.status-badge.sold {
    background: rgba(255,77,77,0.9);
    color: #fff;
}
.image-count {
    right: 14px;
    background: rgba(0,0,0,0.7);
    color: rgba(255,255,255,0.8);
    border: 1px solid rgba(255,255,255,0.1);
    display: flex; align-items: center; gap: 5px;
}
.image-count::before { content: "◻"; font-size: 10px; }

/* ─── CARD SUMMARY ──────────────────────────────────────────────── */
.card-summary {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    padding: 18px 20px 12px;
}
.card-summary h2 {
    font-size: 16px; font-weight: 800;
    letter-spacing: -0.03em;
    margin-bottom: 4px;
    color: var(--text);
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
    max-width: 200px;
}
.summary-meta {
    color: var(--text-3);
    font-size: 12px;
    display: flex; align-items: center; gap: 6px;
}
.summary-meta::before { content: "▣"; font-size: 10px; }
.price {
    white-space: nowrap;
    font-size: 20px; font-weight: 900;
    letter-spacing: -0.04em;
    background: var(--grad-accent);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* ─── DETAILS TOGGLE ────────────────────────────────────────────── */
.details-toggle {
    width: 100%;
    display: flex; align-items: center; justify-content: space-between;
    padding: 12px 20px;
    border-top: 1px solid var(--line);
    background: transparent;
    color: var(--text-2);
    font-weight: 700; font-size: 12px;
    letter-spacing: 0.06em; text-transform: uppercase;
    text-align: left;
    transition: var(--transition);
}
.details-toggle:hover {
    background: rgba(255,255,255,0.03);
    color: var(--text);
}
.arrow {
    width: 20px; height: 20px;
    border: 1px solid var(--line-2);
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-size: 12px;
    transition: transform 0.25s ease, background 0.2s ease;
}
.details-toggle[aria-expanded="true"] .arrow {
    transform: rotate(180deg);
    background: rgba(255,255,255,0.08);
}

/* ─── DETAILS PANEL ─────────────────────────────────────────────── */
.details-panel {
    padding: 20px;
    border-top: 1px solid var(--line);
    background: rgba(0,0,0,0.3);
    animation: fadeUp 0.25s ease both;
}

.thumbnail-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0,1fr));
    gap: 8px; margin-bottom: 20px;
}
.thumbnail-grid a { display: block; border-radius: var(--radius-sm); overflow: hidden; }
.thumbnail-grid img {
    width: 100%; aspect-ratio: 1;
    object-fit: cover;
    border: 1px solid var(--line);
    border-radius: var(--radius-sm);
    transition: var(--transition);
    filter: grayscale(30%);
}
.thumbnail-grid a:hover img {
    border-color: rgba(255,255,255,0.2);
    transform: scale(1.03);
    filter: grayscale(0%);
}

.details-list { display: grid; gap: 0; }
.details-list > div {
    display: grid;
    grid-template-columns: 110px 1fr;
    gap: 12px;
    padding: 11px 0;
    border-bottom: 1px solid var(--line);
    align-items: start;
    animation: slideIn 0.3s ease both;
}
.details-list > div:last-child { border-bottom: 0; }
.details-list dt {
    color: var(--text-3);
    font-size: 10px; font-weight: 800;
    letter-spacing: 0.12em; text-transform: uppercase;
    padding-top: 2px;
}
.details-list dd { overflow-wrap: anywhere; font-size: 14px; color: var(--text-2); }

/* ─── FOOTER NOTE ───────────────────────────────────────────────── */
.site-note {
    max-width: 640px; margin: 48px auto 0;
    color: var(--text-3); font-size: 11px;
    text-align: center; line-height: 1.7;
    padding-top: 24px;
    border-top: 1px solid var(--line);
}

/* ─── BUTTON SYSTEM ─────────────────────────────────────────────── */
.button {
    display: inline-flex; align-items: center; justify-content: center;
    gap: 7px; min-height: 40px; padding: 9px 16px;
    border: 1px solid transparent; border-radius: var(--radius-sm);
    font-weight: 800; font-size: 13px; letter-spacing: 0.01em;
    transition: var(--transition);
    position: relative; overflow: hidden;
    white-space: nowrap;
}
.button::before {
    content: "";
    position: absolute; inset: 0;
    background: rgba(255,255,255,0);
    transition: var(--transition);
}
.button:hover::before { background: rgba(255,255,255,0.05); }
.button:hover { transform: translateY(-1px); }
.button:active { transform: translateY(0px); }

.button.primary {
    background: #fff; color: #000;
    box-shadow: 0 4px 20px rgba(255,255,255,0.15);
}
.button.primary:hover { background: #e8e8e8; box-shadow: 0 6px 28px rgba(255,255,255,0.25); }

.button.ghost {
    background: transparent;
    border-color: var(--line-2);
    color: var(--text-2);
}
.button.ghost:hover { border-color: rgba(255,255,255,0.25); color: var(--text); }

.button.danger {
    background: transparent;
    border-color: rgba(255,77,77,0.3);
    color: var(--danger);
}
.button.danger:hover { background: var(--danger-dim); border-color: var(--danger); }

.button.compact { min-height: 32px; padding: 5px 12px; font-size: 12px; }
.button.full { width: 100%; }
.button.icon-only { min-width: 36px; padding: 0; width: 36px; height: 36px; }

.payment-link {
    min-width: 100px;
    background: rgba(255,255,255,0.06);
    border-color: var(--line-2);
    color: var(--text);
}
.payment-link:hover { background: rgba(255,255,255,0.12); border-color: rgba(255,255,255,0.2); }

/* ─── AUTH PAGES ────────────────────────────────────────────────── */
.auth-body {
    min-height: 100vh;
    display: grid; place-items: center;
    padding: 28px 16px;
    background: var(--bg);
    position: relative;
}
.auth-body::before {
    content: "";
    position: absolute; inset: 0;
    background:
        radial-gradient(ellipse 60% 50% at 50% 0%, rgba(255,255,255,0.04) 0%, transparent 60%),
        radial-gradient(ellipse 40% 40% at 80% 100%, rgba(255,255,255,0.02) 0%, transparent 50%);
    pointer-events: none;
}
.auth-shell { width: min(460px, 100%); position: relative; z-index: 1; }
.install-shell { width: min(720px, 100%); position: relative; z-index: 1; }

.auth-card {
    padding: clamp(28px, 5vw, 44px);
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    animation: fadeUp 0.4s ease both;
    position: relative; overflow: hidden;
}
.auth-card::before {
    content: "";
    position: absolute; top: 0; left: 0; right: 0; height: 1px;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.15), transparent);
}
.auth-card .brand-mark { margin-bottom: 28px; }
.auth-card h1 { font-size: 36px; margin-bottom: 8px; }
.muted { color: var(--text-2); font-size: 14px; margin-bottom: 24px; }
.back-link {
    display: flex; align-items: center; justify-content: center; gap: 6px;
    margin-top: 24px; color: var(--text-3); font-size: 13px;
    transition: var(--transition);
}
.back-link:hover { color: var(--text-2); }

/* Login decoration line */
.auth-divider {
    display: flex; align-items: center; gap: 12px;
    margin: 4px 0;
}
.auth-divider::before, .auth-divider::after {
    content: ""; flex: 1; height: 1px; background: var(--line);
}
.auth-divider span { font-size: 11px; color: var(--text-3); font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; }

/* ─── FORMS ─────────────────────────────────────────────────────── */
.stack-form { display: grid; gap: 18px; }
.stack-form label {
    display: grid; gap: 8px;
    color: var(--text-2); font-size: 12px; font-weight: 800;
    letter-spacing: 0.06em; text-transform: uppercase;
}
.stack-form small { color: var(--text-3); font-weight: 500; font-size: 11px; text-transform: none; letter-spacing: 0; }

input, textarea, select {
    width: 100%;
    padding: 12px 14px;
    color: var(--text);
    background: var(--bg-3);
    border: 1px solid var(--line);
    border-radius: var(--radius-sm);
    outline: none;
    transition: var(--transition);
    font-size: 14px;
}
input::placeholder, textarea::placeholder { color: var(--text-3); }
input:hover, textarea:hover, select:hover { border-color: var(--line-2); }
input:focus, textarea:focus, select:focus {
    border-color: rgba(255,255,255,0.3);
    background: var(--bg-2);
    box-shadow: 0 0 0 3px rgba(255,255,255,0.05);
}
textarea { resize: vertical; min-height: 90px; }
select { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8'%3E%3Cpath d='M6 8 0 0h12z' fill='%23606060'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 14px center; padding-right: 36px; }
select option { background: #1a1a1a; }

input[type="file"] {
    padding: 10px 12px;
    background: var(--bg-3);
    border-style: dashed;
    cursor: pointer;
}
input[type="file"]:hover { border-color: rgba(255,255,255,0.2); }

.form-grid { display: grid; gap: 16px; }
.form-grid.two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.form-grid.three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
hr { width: 100%; margin: 4px 0; border: 0; border-top: 1px solid var(--line); }
code { padding: 2px 6px; background: var(--bg-3); border: 1px solid var(--line); border-radius: 4px; font-size: 12px; color: var(--text-2); }

/* ─── ALERTS ────────────────────────────────────────────────────── */
.alert {
    display: flex; align-items: flex-start; gap: 10px;
    margin-bottom: 20px;
    padding: 14px 16px;
    border: 1px solid; border-radius: var(--radius-sm);
    font-size: 13px; line-height: 1.5;
    animation: fadeIn 0.3s ease both;
}
.alert.success { color: var(--success); background: var(--success-dim); border-color: rgba(61,220,132,0.2); }
.alert.success::before { content: "✓"; font-weight: 900; font-size: 14px; flex-shrink: 0; margin-top: 1px; }
.alert.error { color: var(--danger); background: var(--danger-dim); border-color: rgba(255,77,77,0.2); }
.alert.error::before { content: "⚠"; font-size: 14px; flex-shrink: 0; margin-top: 1px; }

/* ─── EMPTY STATE ───────────────────────────────────────────────── */
.empty-state {
    padding: 64px 24px;
    background: var(--surface);
    border: 1px dashed rgba(255,255,255,0.08);
    border-radius: var(--radius-lg);
    text-align: center;
    animation: fadeIn 0.4s ease both;
}
.empty-state::before { content: "⬡"; font-size: 40px; display: block; margin-bottom: 16px; color: var(--text-3); }
.empty-state h2 { margin-bottom: 8px; font-size: 20px; color: var(--text-2); }
.empty-state p { color: var(--text-3); font-size: 14px; }
.empty-state.compact { padding: 36px 20px; }
.empty-state.compact::before { font-size: 28px; margin-bottom: 10px; }

/* ─── ADMIN LAYOUT ──────────────────────────────────────────────── */
.admin-body { background: var(--bg); }
.admin-shell {
    width: min(1480px, calc(100% - 40px));
    margin: 0 auto;
    padding: 36px 0 72px;
}
.admin-shell.narrow { width: min(960px, calc(100% - 40px)); }

.admin-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.1fr) minmax(420px, 0.9fr);
    gap: 24px;
    align-items: start;
}

/* ─── PANELS ────────────────────────────────────────────────────── */
.panel {
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
    position: relative; overflow: hidden;
}
.panel::before {
    content: "";
    position: absolute; top: 0; left: 0; right: 0; height: 1px;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.08), transparent);
    pointer-events: none;
}
.form-panel { padding: clamp(22px, 3vw, 34px); }
.listings-panel { overflow: hidden; }

.panel-heading {
    display: flex; align-items: center; justify-content: space-between;
    gap: 16px; margin-bottom: 26px;
}
.panel-heading h1 { font-size: 22px; letter-spacing: -0.04em; }
.panel-heading h2 { font-size: 18px; letter-spacing: -0.04em; }
.listings-panel .panel-heading { padding: 24px 24px 0; }

.count-pill {
    min-width: 32px; height: 28px;
    display: grid; place-items: center;
    padding: 0 10px;
    background: var(--accent-dim);
    border: 1px solid var(--line-2);
    color: var(--text-2);
    border-radius: 99px;
    font-size: 12px; font-weight: 800;
}

/* ─── ADMIN LIST ────────────────────────────────────────────────── */
.admin-list { display: grid; }
.admin-list-item {
    display: grid;
    grid-template-columns: 68px minmax(0,1fr) auto;
    align-items: center; gap: 14px;
    padding: 14px 20px;
    border-top: 1px solid var(--line);
    transition: var(--transition);
    animation: slideIn 0.3s ease both;
}
.admin-list-item:hover { background: rgba(255,255,255,0.02); }
.admin-list-item > img, .admin-thumb-placeholder {
    width: 68px; height: 52px;
    object-fit: cover;
    border: 1px solid var(--line);
    border-radius: var(--radius-sm);
    background: var(--bg-3);
    transition: var(--transition);
}
.admin-list-item > img:hover { border-color: var(--line-2); transform: scale(1.03); }
.admin-thumb-placeholder {
    display: grid; place-items: center;
    color: var(--text-3); font-size: 10px;
}
.admin-item-main { min-width: 0; display: grid; gap: 4px; }
.admin-item-main strong {
    overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
    font-size: 14px; font-weight: 700; color: var(--text);
}
.admin-item-main span { color: var(--text-3); font-size: 11px; font-weight: 500; }
.admin-item-actions { display: flex; gap: 6px; }
.admin-item-actions form { margin: 0; }

/* ─── EDIT IMAGE GRID ───────────────────────────────────────────── */
.edit-image-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0,1fr));
    gap: 12px; margin-bottom: 26px;
}
.edit-image-item { display: grid; gap: 8px; }
.edit-image-item img {
    width: 100%; aspect-ratio: 1;
    object-fit: cover;
    border: 1px solid var(--line);
    border-radius: var(--radius-sm);
    transition: var(--transition);
}
.edit-image-item img:hover { border-color: var(--line-2); }

/* ─── ADMIN HEADER EXTRAS ───────────────────────────────────────── */
.admin-nav-pills {
    display: flex; gap: 4px; align-items: center;
}
.admin-nav-pill {
    padding: 5px 12px; border-radius: 99px;
    font-size: 11px; font-weight: 700;
    letter-spacing: 0.04em;
    color: var(--text-3);
    border: 1px solid transparent;
    transition: var(--transition);
}
.admin-nav-pill:hover { color: var(--text-2); border-color: var(--line); }
.admin-nav-pill.active { color: var(--text); background: var(--accent-dim); border-color: var(--line-2); }

/* ─── SECTION DIVIDER ───────────────────────────────────────────── */
.section-label {
    display: flex; align-items: center; gap: 12px;
    margin-bottom: 20px;
    color: var(--text-3); font-size: 10px; font-weight: 800;
    letter-spacing: 0.14em; text-transform: uppercase;
}
.section-label::after { content: ""; flex: 1; height: 1px; background: var(--line); }

/* ─── GAME CATEGORY BANNER ──────────────────────────────────────── */
.game-banner {
    position: relative;
    width: 100%;
    border-radius: var(--radius-lg);
    overflow: hidden;
    margin-bottom: 28px;
    aspect-ratio: 21 / 6;
    background: var(--bg-3);
    border: 1px solid var(--line);
    cursor: pointer;
    display: none; /* shown by JS per active category */
}
.game-banner.visible {
    display: block;
    animation: fadeUp 0.45s cubic-bezier(0.4,0,0.2,1) both;
}
.game-banner img {
    width: 100%; height: 100%;
    object-fit: cover;
    animation: bannerDrift 18s ease-in-out infinite;
}
/* Shimmer sweep over banner */
.game-banner::before {
    content: "";
    position: absolute; inset: 0; z-index: 2;
    background: linear-gradient(105deg, transparent 30%, rgba(255,255,255,0.12) 50%, transparent 70%);
    animation: bannerShimmer 4s ease-in-out infinite;
    pointer-events: none;
}
/* Dark gradient overlay */
.game-banner::after {
    content: "";
    position: absolute; inset: 0; z-index: 1;
    background: linear-gradient(to right, rgba(0,0,0,0.75) 0%, rgba(0,0,0,0.25) 60%, rgba(0,0,0,0.5) 100%);
    pointer-events: none;
}
.banner-content {
    position: absolute; inset: 0; z-index: 3;
    display: flex; flex-direction: column; justify-content: center;
    padding: clamp(20px, 4vw, 48px);
    gap: 8px;
}
.banner-eyebrow {
    font-size: 10px; font-weight: 800;
    letter-spacing: 0.2em; text-transform: uppercase;
    color: rgba(255,255,255,0.6);
    animation: glitchSweep 0.8s ease 0.2s both;
}
.banner-title {
    font-size: clamp(22px, 4vw, 48px);
    font-weight: 900;
    letter-spacing: -0.04em;
    line-height: 1;
    color: #fff;
    text-shadow: 0 2px 24px rgba(0,0,0,0.8);
    animation: glitchSweep 0.85s ease 0.3s both;
}
.banner-sub {
    font-size: 13px; color: rgba(255,255,255,0.65);
    animation: glitchSweep 0.9s ease 0.45s both;
}
/* CODM banner accent */
.game-banner.codm .banner-title { color: #ff9f5a; text-shadow: 0 0 40px rgba(255,106,0,0.5), 0 2px 24px rgba(0,0,0,0.8); }
.game-banner.codm .banner-eyebrow { color: var(--codm); }
/* MLBB banner accent */
.game-banner.mlbb .banner-title { color: #6ddcff; text-shadow: 0 0 40px rgba(0,194,255,0.5), 0 2px 24px rgba(0,0,0,0.8); }
.game-banner.mlbb .banner-eyebrow { color: var(--mlbb); }

/* ─── CATEGORY TABS ─────────────────────────────────────────────── */
.category-tabs {
    display: flex; align-items: stretch; gap: 0;
    margin-bottom: 24px;
    border-bottom: 1px solid var(--line);
    position: relative;
    animation: fadeUp 0.5s ease 0.2s both;
}
.category-tab {
    position: relative;
    display: flex; align-items: center; gap: 8px;
    padding: 12px 20px 14px;
    font-size: 13px; font-weight: 800;
    letter-spacing: 0.04em;
    color: var(--text-3);
    cursor: pointer; border: none; background: none;
    transition: color 0.2s ease;
    white-space: nowrap;
}
.category-tab::after {
    content: "";
    position: absolute; bottom: -1px; left: 0; right: 0; height: 2px;
    border-radius: 2px 2px 0 0;
    transform: scaleX(0); transform-origin: left center;
    transition: transform 0.3s cubic-bezier(0.4,0,0.2,1);
}
.category-tab:hover { color: var(--text-2); }
.category-tab.active { color: var(--text); }
.category-tab.active::after {
    transform: scaleX(1);
}
/* All tab */
.category-tab[data-cat="all"].active { color: var(--text); }
.category-tab[data-cat="all"].active::after { background: rgba(255,255,255,0.6); }
/* CODM tab */
.category-tab[data-cat="codm"].active { color: var(--codm); }
.category-tab[data-cat="codm"].active::after { background: var(--codm); box-shadow: 0 0 8px var(--codm-glow); }
/* MLBB tab */
.category-tab[data-cat="mlbb"].active { color: var(--mlbb); }
.category-tab[data-cat="mlbb"].active::after { background: var(--mlbb); box-shadow: 0 0 8px var(--mlbb-glow); }
/* Tab icon badge */
.tab-icon {
    width: 20px; height: 20px;
    border-radius: 5px;
    display: grid; place-items: center;
    font-size: 11px; font-weight: 900;
    flex-shrink: 0;
}
.tab-icon.codm { background: linear-gradient(135deg, #ff6a00, #ff9f5a); color: #000; }
.tab-icon.mlbb { background: linear-gradient(135deg, #00c2ff, #0072ff); color: #fff; }
.tab-icon.all  { background: linear-gradient(135deg, #fff, #888); color: #000; }
/* Tab count */
.tab-count {
    font-size: 10px; font-weight: 700;
    padding: 1px 6px; border-radius: 99px;
    background: rgba(255,255,255,0.07);
    color: var(--text-3);
    transition: background 0.2s, color 0.2s;
}
.category-tab.active .tab-count { background: rgba(255,255,255,0.12); color: var(--text-2); }
.category-tab[data-cat="codm"].active .tab-count { background: var(--codm-dim); color: var(--codm); }
.category-tab[data-cat="mlbb"].active .tab-count { background: var(--mlbb-dim); color: var(--mlbb); }

/* ─── FILTER BAR ────────────────────────────────────────────────── */
.filter-bar {
    display: flex; align-items: center; gap: 8px;
    margin-bottom: 28px; flex-wrap: wrap;
}
.filter-chip {
    padding: 6px 14px; border-radius: 99px;
    font-size: 12px; font-weight: 700;
    letter-spacing: 0.04em;
    border: 1px solid var(--line);
    color: var(--text-3); background: transparent;
    cursor: pointer; transition: var(--transition);
}
.filter-chip:hover, .filter-chip.active {
    color: var(--text); border-color: rgba(255,255,255,0.2);
    background: rgba(255,255,255,0.05);
}
.filter-chip.available.active { color: var(--success); border-color: rgba(61,220,132,0.3); background: var(--success-dim); }
.filter-chip.reserved.active { color: var(--warning); border-color: rgba(255,209,102,0.3); background: rgba(255,209,102,0.06); }
.filter-chip.sold.active { color: var(--danger); border-color: rgba(255,77,77,0.3); background: var(--danger-dim); }

/* ─── RESPONSIVE ────────────────────────────────────────────────── */
@media (max-width: 1020px) {
    .admin-grid { grid-template-columns: 1fr; }
    .listings-panel { order: 2; }
}
@media (max-width: 720px) {
    .category-tab { padding: 10px 14px 12px; font-size: 12px; }
    .game-banner { aspect-ratio: 16 / 7; }
    .banner-title { font-size: 22px; }
    .listing-grid { grid-template-columns: 1fr; }
    .form-grid.two, .form-grid.three { grid-template-columns: 1fr; }
    .admin-list-item { grid-template-columns: 56px minmax(0,1fr); }
    .admin-list-item > img, .admin-thumb-placeholder { width: 56px; height: 48px; }
    .admin-item-actions { grid-column: 1 / -1; justify-content: flex-end; }
    .edit-image-grid { grid-template-columns: repeat(2, minmax(0,1fr)); }
    .details-list > div { grid-template-columns: 1fr; gap: 4px; }
    .thumbnail-grid { grid-template-columns: repeat(3, minmax(0,1fr)); }
    .site-header, .admin-header { padding-inline: 16px; }
    .hero-stats { gap: 20px; }
    .admin-nav-pills { display: none; }
    .brand > span:last-child { max-width: 160px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
}
@media (max-width: 480px) {
    .game-banner { aspect-ratio: 16 / 9; }
    .category-tabs { overflow-x: auto; -webkit-overflow-scrolling: touch; }
    .category-tab { padding: 9px 12px 11px; }
    .page-shell, .admin-shell, .admin-shell.narrow { width: calc(100% - 24px); }
    .page-shell { padding-top: 40px; }
    h1 { font-size: 38px; }
    .card-summary { flex-direction: column; gap: 8px; }
    .thumbnail-grid { grid-template-columns: repeat(2, minmax(0,1fr)); }
    .filter-bar { display: none; }
    .listing-grid { grid-template-columns: 1fr; gap: 14px; }
    .auth-card { padding: 24px 20px; }
}
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
    body::before { display: none; }
    h1 { animation: none; background: #fff; }
}
