:root {
    --bg: #0b1020;
    --panel: #141b33;
    --panel-2: #1a2342;
    --text: #f3f6ff;
    --muted: #a9b3d1;
    --accent: #6aa8ff;
    --accent-2: #8c6cff;
    --good: #4ad97b;
    --bad: #ff6b81;
    --border: rgba(255,255,255,0.1);
    --shadow: 0 20px 50px rgba(0,0,0,0.35);
}

* { box-sizing: border-box; }
body {
    margin: 0;
    font-family: Inter, Arial, sans-serif;
    background:
        radial-gradient(circle at top, rgba(106,168,255,0.18), transparent 35%),
        linear-gradient(180deg, #08101f, #0e1430 45%, #090d1a);
    color: var(--text);
}

a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; }

.page-shell {
    max-width: 1800px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 180px minmax(0, 1fr) 180px;
    gap: 20px;
    padding: 20px;
}

.main-content {
    min-height: 100vh;
}

.hero, .request-section, .top-ad, .info-bar, .game-card {
    background: rgba(20, 27, 51, 0.86);
    border: 1px solid var(--border);
    box-shadow: var(--shadow);
    border-radius: 24px;
    backdrop-filter: blur(10px);
}

.hero {
    padding: 28px;
    display: flex;
    justify-content: space-between;
    gap: 20px;
    align-items: end;
    margin-bottom: 18px;
}

.eyebrow {
    display: inline-block;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    font-size: 12px;
    color: #93a6d9;
    margin-bottom: 10px;
}

.hero h1, .request-section h2 {
    margin: 0 0 8px;
    font-size: clamp(2rem, 4vw, 3.2rem);
}

.hero p, .request-section p, .vote-note, .status-text, .info-bar, .game-desc {
    color: var(--muted);
}

.hero-actions {
    display: grid;
    gap: 12px;
    width: min(420px, 100%);
}

.hero-actions input,
.hero-actions select,
.request-form input,
.request-form textarea {
    width: 100%;
    border: 1px solid rgba(255,255,255,0.12);
    border-radius: 14px;
    background: rgba(255,255,255,0.05);
    color: var(--text);
    padding: 14px 16px;
}

.hero-actions input::placeholder,
.request-form input::placeholder,
.request-form textarea::placeholder {
    color: #8c96b4;
}

.top-ad, .info-bar {
    margin-bottom: 18px;
    padding: 14px 18px;
}

.ad-inner {
    min-height: 90px;
    display: grid;
    place-items: center;
    border: 1px dashed rgba(255,255,255,0.2);
    border-radius: 18px;
    color: var(--muted);
    text-align: center;
    padding: 14px;
}

.ad-inner.vertical {
    min-height: 600px;
}

.sidebar-ad {
    position: sticky;
    top: 20px;
    height: fit-content;
}

.games-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 18px;
}

.game-card {
    overflow: hidden;
}

.thumb-wrap {
    position: relative;
    aspect-ratio: 16 / 9;
    background: #0d1429;
}

.game-thumb {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.category-badge {
    position: absolute;
    top: 14px;
    left: 14px;
    background: rgba(0,0,0,0.6);
    border: 1px solid rgba(255,255,255,0.12);
    padding: 8px 12px;
    border-radius: 999px;
    font-size: 12px;
}

.game-meta {
    padding: 18px;
}

.title-row {
    display: grid;
    grid-template-columns: 56px 1fr;
    gap: 14px;
    align-items: start;
    margin-bottom: 14px;
}

.game-icon {
    width: 56px;
    height: 56px;
    border-radius: 16px;
    object-fit: cover;
}

.game-name {
    margin: 0 0 8px;
    font-size: 1.2rem;
}

.game-desc {
    margin: 0;
    line-height: 1.45;
}

.stats-row, .card-actions, .vote-row, .cookie-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: center;
}

.stats-row {
    margin-bottom: 16px;
}

.players-pill, .place-pill {
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 999px;
    padding: 8px 12px;
    font-size: 13px;
}

.card-actions {
    justify-content: space-between;
    gap: 14px;
}

.play-btn, .primary-btn, .secondary-btn, .vote-btn {
    border: none;
    border-radius: 14px;
    padding: 12px 16px;
    cursor: pointer;
    transition: transform 0.15s ease, opacity 0.15s ease, background 0.15s ease;
}

.play-btn, .primary-btn {
    background: linear-gradient(135deg, var(--accent), var(--accent-2));
    color: white;
    font-weight: 700;
}

.secondary-btn, .vote-btn {
    background: rgba(255,255,255,0.06);
    color: var(--text);
    border: 1px solid rgba(255,255,255,0.08);
}

.play-btn:hover, .primary-btn:hover, .secondary-btn:hover, .vote-btn:hover {
    transform: translateY(-1px);
}

.vote-btn.active.up { border-color: rgba(74,217,123,0.7); }
.vote-btn.active.down { border-color: rgba(255,107,129,0.7); }
.vote-btn:disabled { opacity: 0.45; cursor: not-allowed; }

.request-section {
    margin-top: 28px;
    padding: 24px;
}

.form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
    margin: 20px 0 16px;
}

.form-grid textarea {
    min-height: 140px;
    grid-column: 1 / -1;
    resize: vertical;
}

.cookie-banner {
    position: fixed;
    left: 20px;
    right: 20px;
    bottom: 20px;
    z-index: 50;
    background: rgba(10, 16, 34, 0.96);
    border: 1px solid var(--border);
    box-shadow: var(--shadow);
    border-radius: 24px;
    padding: 18px 20px;
    display: flex;
    justify-content: space-between;
    gap: 16px;
    align-items: center;
}

.empty-state {
    text-align: center;
    color: var(--muted);
    padding: 30px 12px;
}

.hidden { display: none !important; }

@media (max-width: 1200px) {
    .page-shell {
        grid-template-columns: 1fr;
    }
    .sidebar-ad {
        display: none;
    }
}

@media (max-width: 760px) {
    .hero {
        padding: 22px;
        align-items: stretch;
        flex-direction: column;
    }
    .form-grid {
        grid-template-columns: 1fr;
    }
    .cookie-banner {
        left: 12px;
        right: 12px;
        bottom: 12px;
        flex-direction: column;
        align-items: stretch;
    }
}
