/* Main page (index.php) modern styles */
.main-container {
    max-width: 700px;
    margin: 36px auto 36px auto;
    display: flex;
    flex-direction: column;
    gap: 28px;
    padding: 0 8px;
}
.welcome-card {
    background: #f8fafc;
    border-radius: 16px;
    box-shadow: 0 2px 12px rgba(0,0,0,0.07);
    padding: 32px 24px 18px 24px;
    text-align: center;
}
.main-title {
    font-size: 2.1em;
    color: #007bff;
    margin-bottom: 10px;
}
.main-desc {
    font-size: 1.13em;
    color: #444;
    margin-bottom: 0;
}
.section-card {
    background: #fff;
    border-radius: 14px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.06);
    padding: 24px 20px 18px 20px;
    margin-bottom: 0;
}
.section-card h3 {
    font-size: 1.25em;
    color: #222;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 8px;
}
.section-icon {
    font-size: 1.2em;
    margin-right: 2px;
}
.section-list {
    margin: 0 0 0 18px;
    padding: 0;
    list-style: disc inside;
    font-size: 1.08em;
    color: #333;
}
.sub-list {
    margin: 8px 0 0 18px;
    padding: 0;
    list-style: circle inside;
    font-size: 0.98em;
    color: #444;
}
.rules-img {
    max-width: 220px;
    width: 100%;
    margin: 12px auto 0 auto;
    display: block;
    border-radius: 8px;
    box-shadow: 0 1px 6px rgba(0,0,0,0.08);
}
@media (max-width: 700px) {
    .main-container { max-width: 99vw; }
    .welcome-card, .section-card { padding: 12px 4vw 10px 4vw; }
    .main-title { font-size: 1.3em; }
}
/* Withdraw Form Styles */
.withdraw-container {
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 2px 16px rgba(0,0,0,0.10);
    max-width: 420px;
    margin: 32px auto 32px auto;
    padding: 32px 24px 24px 24px;
    display: flex;
    flex-direction: column;
    align-items: center;
}
.withdraw-form {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.withdraw-range-row {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    --slider-progress: 0%;
}

.withdraw-form input[type="range"] {
    display: block;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
}
.withdraw-notes {
    font-size: 0.98em;
    color: #666;
    margin-top: 12px;
    text-align: left;
    width: 100%;
}
.withdraws-page {
    max-width: 1120px;
    margin: 40px auto;
    padding: 0 20px 24px;
}
.withdraws-card {
    background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
    border: 1px solid #dbe7f3;
    border-radius: 22px;
    box-shadow: 0 16px 40px rgba(18, 38, 63, 0.10);
    padding: 32px 30px 26px;
}
.withdraws-title {
    margin: 0 0 10px;
    color: #17324d;
    font-size: 2.35rem;
    line-height: 1.1;
}
.withdraws-desc {
    margin: 0 0 24px;
    color: #58708a;
    font-size: 1.04rem;
    line-height: 1.6;
}
.withdraws-table-wrap {
    overflow-x: auto;
    padding-bottom: 6px;
}
.withdraws-table {
    width: 100%;
    min-width: 760px;
    border-collapse: separate;
    border-spacing: 0 10px;
}
.withdraws-table th,
.withdraws-table td {
    padding: 16px 18px;
    text-align: left;
    vertical-align: middle;
}
.withdraws-table th {
    color: #4c5d70;
    font-size: 0.82rem;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    background: transparent;
    border-bottom: 0;
    padding-bottom: 8px;
}
.withdraws-table tbody tr td {
    background: #ffffff;
    border-top: 1px solid #e7eef6;
    border-bottom: 1px solid #e7eef6;
}
.withdraws-table tbody tr td:first-child {
    border-left: 1px solid #e7eef6;
    border-top-left-radius: 14px;
    border-bottom-left-radius: 14px;
}
.withdraws-table tbody tr td:last-child {
    border-right: 1px solid #e7eef6;
    border-top-right-radius: 14px;
    border-bottom-right-radius: 14px;
}
.withdraws-table tbody tr:hover td {
    background: #f4f9ff;
}
.wallet-cell {
    font-family: monospace;
    letter-spacing: 0.04em;
    color: #24384d;
    white-space: nowrap;
}
.withdraw-type-pill {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 58px;
    padding: 6px 12px;
    border-radius: 999px;
    background: #e7f1ff;
    color: #175ea8;
    font-size: 0.85rem;
    font-weight: bold;
}

.withdraw-status-pill {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 88px;
    padding: 6px 12px;
    border-radius: 999px;
    font-size: 0.79rem;
    font-weight: 800;
    letter-spacing: 0.02em;
}

.withdraw-status-pill.status-pending {
    background: #fff2cf;
    color: #8f5b00;
}

.withdraw-status-pill.status-completed {
    background: #def7e8;
    color: #1c6b3f;
}

.withdraw-status-pill.status-cancelled {
    background: #fde2e2;
    color: #8f2323;
}
.withdraws-empty {
    color: #6a7b8f;
    text-align: center;
    white-space: normal;
}
.withdraws-table tbody td:nth-child(1) {
    width: 24%;
    white-space: nowrap;
    color: #203244;
}
.withdraws-table tbody td:nth-child(2) {
    width: 36%;
}
.withdraws-table tbody td:nth-child(3) {
    width: 22%;
    white-space: nowrap;
    font-variant-numeric: tabular-nums;
}
.withdraws-table tbody td:nth-child(4) {
    width: 18%;
}
@media (max-width: 600px) {
    .withdraw-container {
        max-width: 98vw;
        padding: 10px 2vw;
    }
    .withdraw-form {
        gap: 10px;
    }
    .withdraws-card {
        padding: 20px 14px 16px;
    }
    .withdraws-title {
        font-size: 1.7rem;
    }
    .withdraws-desc {
        font-size: 0.96rem;
        margin-bottom: 18px;
    }
    .withdraws-page {
        padding: 0 10px 20px;
    }
    .withdraws-table {
        min-width: 680px;
    }
    .withdraws-table th,
    .withdraws-table td {
        padding: 14px 12px;
    }
}
/* Registration Form Styles */
.register-container {
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 2px 16px rgba(0,0,0,0.10);
    max-width: 420px;
    margin: 32px auto 32px auto;
    padding: 32px 24px 24px 24px;
    display: flex;
    flex-direction: column;
    align-items: center;
}
.register-title {
    font-size: 2em;
    font-weight: bold;
    margin-bottom: 10px;
    color: #007bff;
    text-align: center;
}
.register-desc {
    font-size: 1.08em;
    color: #444;
    margin-bottom: 22px;
    text-align: center;
}
.register-form {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 18px;
}
.form-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.form-control {
    padding: 10px 12px;
    border: 1px solid #cfd8dc;
    border-radius: 6px;
    font-size: 1em;
    background: #f8fafc;
    transition: border 0.2s;
}
.form-control:focus {
    border: 1.5px solid #007bff;
    outline: none;
    background: #fff;
}

.form-control[type="range"] {
    padding: 0;
    border: 0;
    background: transparent;
}
.register-btn {
    background: #007bff;
    color: #fff;
    border: none;
    border-radius: 8px;
    padding: 12px 0;
    font-size: 1.15em;
    font-weight: bold;
    cursor: pointer;
    margin-top: 8px;
    transition: background 0.2s;
    box-shadow: 0 1px 4px rgba(0,0,0,0.07);
}
.register-btn:hover {
    background: #0056b3;
}
.captcha-group {
    margin-bottom: 0;
}
.captcha-row {
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.captcha-img {
    width: 100%;
    max-width: 260px;
    height: auto;
}
@media (min-width: 420px) {
    .captcha-row {
        flex-direction: row;
        align-items: center;
        gap: 12px;
    }
    .captcha-img {
        height: 38px;
        width: auto;
    }
}
.captcha-input {
    flex: 1;
    min-width: 0;
}
.captcha-img {
    border-radius: 6px;
    border: 1px solid #cfd8dc;
    background: #f4f4f4;
}
@media (max-width: 600px) {
    .register-container {
        max-width: 98vw;
        padding: 10px 2vw;
    }
    .register-title {
        font-size: 1.3em;
    }
    .register-form {
        gap: 10px;
    }
}
/* Podbarvení řádků v tabulce sázek */
.bet-win {
    background-color: #e6ffe6 !important;
}
.bet-lose {
    background-color: #ffeaea !important;
}
/* Statistiky - tabulka */
.stats-table {
    width: 100%;
    max-width: 420px;
    margin: 0 auto 18px auto;
    border-collapse: collapse;
    background: #fff;
    box-shadow: 0 2px 12px rgba(0,0,0,0.08);
    border-radius: 12px;
    overflow: hidden;
    font-size: 1.08em;
}
.stats-table th, .stats-table td {
    padding: 12px 14px;
    border-bottom: 1px solid #eee;
    text-align: left;
}
.stats-table th {
    background: #f4f4f4;
    font-weight: bold;
    width: 60%;
}
.stats-table tr:last-child td, .stats-table tr:last-child th {
    border-bottom: none;
}
.stats-table td {
    background: #fff;
}
.stats-table tr:hover td {
    background: #eaf4ff;
}
.won-cell {
    color: #1ca91c;
    font-weight: bold;
}
.lost-cell {
    color: #d32f2f;
    font-weight: bold;
}
@media (max-width: 600px) {
    .stats-table { font-size: 0.98em; }
    .stats-table th, .stats-table td { padding: 8px 6px; }
}
body {
    font-family: Arial, sans-serif;
    margin: 0;
    padding: 0;
    background-color: #f4f4f4;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}
.container {
    width: 80%;
    margin: auto;
    overflow: hidden;
    flex: 1;
}
header {
    background: #333;
    color: #fff;
    padding-top: 30px;
    min-height: 70px;
    border-bottom: #77aaff 3px solid;
    text-align: center;
}
header h1 {
    font-size: 36px;
    font-weight: bold;
    color: #fff;
    text-shadow: 2px 2px #aaa;
    margin: 0;
}
header nav {
    margin: 20px 0;
}
header a {
    color: #fff;
    text-decoration: none;
    text-transform: uppercase;
    font-size: 16px;
    margin: 0 10px;
    transition: color 0.3s;
}
header a:hover {
    color: #77aaff;
}
hr {
    border: 0;
    height: 1px;
    background: #333;
    background-image: linear-gradient(to right, #ccc, #333, #ccc);
    margin: 20px 0;
}
.content {
    padding: 20px;
    background: #fff;
    margin-top: 20px;
    word-wrap: break-word; /* Zalamování textu */
}
footer {
    background: #333;
    color: #fff;
    text-align: center;
    padding: 10px 0;
    position: relative;
    bottom: 0;
    width: 100%;
    margin-top: auto; /* Umožňuje zápatí být na konci stránky */
}
.wallet-address {
    display: inline-block;
    cursor: pointer;
    color: #007bff;
    text-decoration: underline;
}
.navbar {
    overflow: hidden;
    background-color: #333;
    position: relative;
}
.navbar a {
    float: left;
    display: block;
    color: #f2f2f2;
    text-align: center;
    padding: 14px 16px;
    text-decoration: none;
    font-size: 17px;
}
.navbar a:hover {
    background-color: #ddd;
    color: black;
}
.navbar a.active {
    background-color: #4CAF50;
    color: white;
}
.navbar .icon {
    display: none;
}
.dropdown {
    float: left;
    overflow: hidden;
}
.dropdown .dropbtn {
    font-size: 17px;
    border: none;
    outline: none;
    color: white;
    padding: 14px 16px;
    background-color: inherit;
    font-family: inherit;
    margin: 0;
}
.navbar a:hover, .dropdown:hover .dropbtn {
    background-color: red;
    color: white;
}
.dropdown-content {
    display: none;
    position: absolute;
    background-color: #f9f9f9;
    min-width: 160px;
    box-shadow: 0px 8px 16px 0px rgba(0,0,0,0.2);
    z-index: 1;
}
.dropdown-content a {
    float: none;
    color: black;
    padding: 12px 16px;
    text-decoration: none;
    display: block;
    text-align: left;
}
.dropdown-content a:hover {
    background-color: #ddd;
    color: black;
}
.dropdown:hover .dropdown-content {
    display: block;
}
@media screen and (max-width: 600px) {
    .navbar a:not(:first-child), .dropdown .dropbtn {
        display: none;
    }
    .navbar a.icon {
        float: right;
        display: block;
    }
}
@media screen and (max-width: 600px) {
    .navbar.responsive {position: relative;}
    .navbar.responsive .icon {
        position: absolute;
        right: 0;
        top: 0;
    }
    .navbar.responsive a {
        float: none;
        display: block;
        text-align: left;
    }
    .navbar.responsive .dropdown {float: none;}
    .navbar.responsive .dropdown-content {position: relative;}
    .navbar.responsive .dropdown .dropbtn {
        display: block;
        width: 100%;
        text-align: left;
    }
}
.language-selector {
    text-align: right;
    margin: 10px 0;
}
.language-selector select {
    padding: 5px;
    font-size: 16px;
}
.game-form {
    background: #fff;
    border-radius: 12px;
    padding: 24px 18px 18px 18px;
    box-shadow: 0 2px 12px rgba(0,0,0,0.08);
    max-width: 420px;
    margin: 0 auto;
}
.bet-label {
    font-weight: bold;
    font-size: 1.1em;
}
.min-max-bet {
    font-size: 0.95em;
    color: #888;
    margin-top: 2px;
}
#bet_amount {
    width: 100%;
    margin: 10px 0 0 0;
}
#betOutput {
    font-weight: bold;
    margin-left: 8px;
    color: #007bff;
}
.choice-label {
    display: block;
    margin: 18px 0 8px 0;
    font-weight: bold;
    font-size: 1.1em;
}
.choices-container {
    display: flex;
    justify-content: space-between;
    gap: 8px;
    margin-bottom: 18px;
}
.choice-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    background: #f4f4f4;
    border-radius: 8px;
    padding: 8px 6px 4px 6px;
    cursor: pointer;
    border: 2px solid transparent;
    transition: border 0.2s, background 0.2s;
    min-width: 60px;
    min-height: 70px;
    font-size: 0.98em;
}
.choice-btn span:first-child {
    margin-bottom: 4px;
}
.choices-container input[type="radio"] {
    display: none;
}
.choices-container input[type="radio"]:checked + label {
    border: 2px solid #007bff;
    background: #e6f0ff;
}
.bet-btn {
    margin-top: 10px;
    background: #007bff;
    color: #fff;
    border: none;
    border-radius: 6px;
    padding: 10px 24px;
    font-size: 1.1em;
    cursor: pointer;
    transition: background 0.2s;
}
.bet-btn:hover {
    background: #0056b3;
}
/* ========== GAME SELECTOR GRID / MŘÍŽKA VÝBĚRU HRY / GRID PEMILIHAN GAME ========== */

/**
 * Container pro všechny hry (Container for all games)
 * Kontainer untuk semua game
 * Контейнер для всех игр
 */
.games-container {
    max-width: 1200px;
    margin: 32px auto;
    padding: 0 16px;
}

.games-container h1 {
    text-align: center;
    font-size: 2.2em;
    color: #007bff;
    margin-bottom: 40px;
    font-weight: bold;
}

/**
 * Mřížka her - Responsivní design (Game grid - Responsive design)
 * Grid game - Desain responsif
 * Сетка игр - Адаптивный дизайн
 */
.games-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
    margin-bottom: 32px;
}

/**
 * Karta hry - Jednotlivý prvek v mřížce (Game card - Individual grid item)
 * Kartu game - Item grid individual
 * Карточка игры - Отдельный элемент сетки
 */
.game-card {
    background: linear-gradient(135deg, #f8fafc 0%, #fff 100%);
    border-radius: 12px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
    padding: 24px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    transition: transform 0.3s, box-shadow 0.3s, background 0.3s;
    border: 2px solid transparent;
    cursor: pointer;
}

.game-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 8px 24px rgba(0, 123, 255, 0.15);
    background: linear-gradient(135deg, #e6f0ff 0%, #f0f8ff 100%);
    border: 2px solid #007bff;
}

/**
 * Emoji ikona hry (Game emoji icon)
 * Ikon emoji game
 * Эмоджи-иконка игры
 */
.game-emoji {
    font-size: 3.6em;
    margin-bottom: 14px;
    display: block;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/**
 * Název hry (Game title)
 * Judul game
 * Название игры
 */
.game-title {
    font-size: 1.4em;
    color: #222;
    margin: 8px 0 12px 0;
    font-weight: bold;
    line-height: 1.4;
}

/**
 * Popis hry (Game description)
 * Deskripsi game
 * Описание игры
 */
.game-description {
    font-size: 0.95em;
    color: #666;
    margin-bottom: 16px;
    line-height: 1.5;
    flex-grow: 1;
}

/**
 * Rozsah sázky (Bet range)
 * Jangkauan sazaran
 * Диапазон ставок
 */
.bet-range {
    background: #f4f4f4;
    border-radius: 8px;
    padding: 12px 16px;
    width: 100%;
    margin-bottom: 16px;
    font-size: 0.9em;
}

.bet-range p {
    margin: 6px 0;
    color: #333;
}

.bet-range strong {
    color: #007bff;
    font-weight: 600;
}

/**
 * Tlačítko hry (Play button)
 * Tombol mainkan
 * Кнопка "Играть"
 */
.play-button {
    background: linear-gradient(135deg, #007bff 0%, #0056b3 100%);
    color: #fff;
    padding: 12px 32px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: bold;
    font-size: 1.05em;
    border: none;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s, background 0.2s;
    box-shadow: 0 2px 8px rgba(0, 123, 255, 0.3);
    display: inline-block;
    width: 100%;
    text-align: center;
}

.play-button:hover {
    transform: scale(1.05);
    background: linear-gradient(135deg, #0056b3 0%, #003d7a 100%);
    box-shadow: 0 4px 16px rgba(0, 123, 255, 0.4);
}

.play-button:active {
    transform: scale(0.98);
}

@media (max-width: 600px) {
    .game-form { max-width: 98vw; padding: 10px; }
    .choices-container { gap: 2px; }
    .choice-btn { min-width: 40px; min-height: 50px; font-size: 0.9em; }
    .choice-btn span:first-child { font-size: 1.3em; }
    
    /* Game grid mobile adjustments (Mobilní úpravy mřížky her) */
    .games-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }
    
    .games-container h1 {
        font-size: 1.6em;
        margin-bottom: 24px;
    }
    
    .game-emoji {
        font-size: 2.8em;
        height: 60px;
    }
    
    .game-title {
        font-size: 1.2em;
    }
    
    .game-description {
        font-size: 0.85em;
    }
}
/* ============================================================
   CryptoGame - Branding & Header (v2)
   ============================================================ */

/* Reset & base */
*, *::before, *::after { box-sizing: border-box; }
body { font-family: 'Segoe UI', Arial, sans-serif; background: #0d1117; color: #c9d1d9; margin: 0; }
.container { max-width: 1100px; margin: 0 auto; padding: 0 20px; }
.main-content { padding-top: 24px; padding-bottom: 48px; }
a { color: #58a6ff; text-decoration: none; }
a:hover { text-decoration: underline; }

/* ---- Site Header ---- */
.site-header { background: #161b22; border-bottom: 1px solid #30363d; position: sticky; top: 0; z-index: 100; }
.site-header .container { display: flex; flex-direction: column; gap: 0; }

/* ---- Topbar (replaces brand-bar + navbar in one row) ---- */
.topbar { display: flex; align-items: center; gap: 10px; padding: 8px 0; }

/* ---- Brand Bar ---- */
.brand-link { display: flex; align-items: center; gap: 10px; text-decoration: none; flex-shrink: 0; }
.brand-logo { width: 36px; height: 36px; }
.brand-name { font-size: 1.45em; font-weight: 900; color: #c9d1d9; letter-spacing: -0.5px; white-space: nowrap; }
.brand-accent { color: #f7b731; }

.lang-select { background: #21262d; color: #c9d1d9; border: 1px solid #30363d; border-radius: 6px; padding: 6px 10px; font-size: 0.9em; cursor: pointer; }
.lang-select:focus { outline: none; border-color: #58a6ff; }

/* ---- Main Nav ---- */
.main-nav { display: flex; align-items: center; flex-wrap: wrap; gap: 2px; flex: 1; }
.main-nav a { color: #8b949e; padding: 6px 10px; border-radius: 6px; font-size: 0.88em; transition: background 0.15s, color 0.15s; white-space: nowrap; text-decoration: none; }
.main-nav a:hover, .main-nav a.active { background: #21262d; color: #f0f6fc; }
.main-nav a.nav-play { background: linear-gradient(135deg, #238636, #2ea043); color: #fff !important; font-weight: 600; }
.main-nav a.nav-play:hover { background: linear-gradient(135deg, #2ea043, #3fb950); }
.main-nav a.nav-register { background: linear-gradient(135deg, #1f6feb, #388bfd); color: #fff !important; font-weight: 600; }
.main-nav .nav-mobile-toggle { display: none; background: none; border: none; color: #8b949e; font-size: 1.4em; cursor: pointer; padding: 4px 8px; margin-left: auto; }
/* Legacy class support */
.navbar { display: flex; align-items: center; flex-wrap: wrap; gap: 4px; padding: 4px 0 8px; }
.navbar a { color: #8b949e; padding: 6px 12px; border-radius: 6px; font-size: 0.9em; transition: background 0.15s, color 0.15s; white-space: nowrap; }
.navbar a:hover, .navbar a.active { background: #21262d; color: #f0f6fc; text-decoration: none; }
.navbar a.nav-play { background: linear-gradient(135deg, #238636, #2ea043); color: #fff !important; font-weight: 600; }
.navbar a.nav-play:hover { background: linear-gradient(135deg, #2ea043, #3fb950); }
.navbar a.nav-register { background: linear-gradient(135deg, #1f6feb, #388bfd); color: #fff !important; font-weight: 600; }
.navbar a.icon { display: none; }
.nav-info, .nav-balance { font-size: 0.85em; color: #8b949e; padding: 6px 12px; }
.nav-balance { color: #f7b731; font-weight: 600; }

/* ---- Header right (balance + profile btn) ---- */
.header-right { display: flex; align-items: center; gap: 8px; flex-shrink: 0; margin-left: auto; }
.header-balance-pill { font-size: 0.82em; color: #f7b731; font-weight: 700; white-space: nowrap; padding: 4px 10px; background: rgba(247,183,49,.1); border-radius: 20px; border: 1px solid rgba(247,183,49,.25); }
.profile-btn { display: flex; align-items: center; gap: 5px; background: #21262d; border: 1px solid #30363d; color: #c9d1d9; border-radius: 8px; padding: 6px 12px; font-size: 0.85em; font-weight: 600; cursor: pointer; transition: background 0.15s, border-color 0.15s; white-space: nowrap; }
.profile-btn:hover { background: #30363d; border-color: #58a6ff; color: #f0f6fc; }
.profile-btn svg { flex-shrink: 0; }

@media (max-width: 980px) {
    .main-nav { flex: 0 0 auto; gap: 0; }
    .main-nav a:not(.nav-mobile-toggle) { display: none; }
    .main-nav .nav-mobile-toggle { display: inline-flex; }
    .header-right { margin-left: auto; gap: 4px; flex-shrink: 0; }
    .header-balance-pill { font-size: 0.72em; padding: 3px 7px; max-width: 120px; overflow: hidden; text-overflow: ellipsis; }
    .profile-btn { padding: 5px 8px; font-size: 0.78em; gap: 3px; }
    .profile-btn svg { width: 14px; height: 14px; }
}

@media (max-width: 520px) {
    .brand-name { display: none; }
    .brand-link { gap: 0; }
    .header-balance-pill { max-width: 92px; }
}

/* ---- Wallet Bar (legacy, kept for fallback) ---- */
.wallet-bar { background: #0d1117; border-top: 1px solid #21262d; padding: 8px 0; display: flex; flex-wrap: wrap; gap: 12px; }
.wallet-item { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.wallet-label { font-size: 0.78em; color: #8b949e; white-space: nowrap; }
.wallet-address { font-size: 0.78em; color: #58a6ff; word-break: break-all; }
.wallet-address:hover { color: #79c0ff; }
.wallet-coin { font-size: 0.7em; font-weight: 700; padding: 2px 6px; border-radius: 4px; white-space: nowrap; }
.wallet-coin.xmr { background: #ff6600; color: #fff; }
.wallet-coin.ltc { background: #345d9d; color: #fff; }

/* ============================================================
   Profile Drawer
   ============================================================ */
.profile-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.55);
    z-index: 999;
    backdrop-filter: blur(2px);
}
.profile-overlay.is-open { display: block; }

.profile-drawer {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    width: 360px;
    max-width: 100vw;
    background: #161b22;
    border-left: 1px solid #30363d;
    z-index: 1000;
    display: flex;
    flex-direction: column;
    transform: translateX(100%);
    transition: transform 0.28s cubic-bezier(.4,0,.2,1);
    overflow: hidden;
}
.profile-drawer.is-open { transform: translateX(0); }

.pd-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    border-bottom: 1px solid #21262d;
    flex-shrink: 0;
}
.pd-title { font-size: 1.05em; font-weight: 700; color: #f0f6fc; display: flex; align-items: center; gap: 8px; }
.pd-title svg { color: #58a6ff; }
.pd-close { background: none; border: none; color: #8b949e; font-size: 1.4em; cursor: pointer; padding: 2px 6px; border-radius: 6px; line-height: 1; transition: background 0.15s; }
.pd-close:hover { background: #21262d; color: #f0f6fc; }

.pd-body {
    flex: 1;
    overflow-y: auto;
    padding: 0 0 20px;
}

.pd-balance-card {
    background: linear-gradient(135deg, #1a2332 0%, #0f1923 100%);
    border-bottom: 1px solid #21262d;
    padding: 20px 20px 16px;
    text-align: center;
}
.pd-balance-label { font-size: 0.78em; color: #8b949e; margin-bottom: 6px; text-transform: uppercase; letter-spacing: 0.8px; }
.pd-balance-val { font-size: 1.45em; font-weight: 800; color: #f7b731; margin-bottom: 10px; }
.pd-withdraw-link { display: inline-block; font-size: 0.82em; color: #58a6ff; text-decoration: none; border: 1px solid #30363d; border-radius: 6px; padding: 5px 14px; transition: background 0.15s; }
.pd-withdraw-link:hover { background: #21262d; text-decoration: none; }

.pd-section {
    padding: 16px 20px;
    border-bottom: 1px solid #21262d;
}
.pd-section-logout { border-bottom: none; }
.pd-label { font-size: 0.78em; font-weight: 700; color: #8b949e; text-transform: uppercase; letter-spacing: 0.8px; margin-bottom: 10px; }
.pd-hint { font-size: 0.8em; color: #6e7681; margin: 0 0 10px; line-height: 1.5; }

/* Ref code row */
.pd-ref-row { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; }
.pd-ref-val { font-size: 1.5em; font-weight: 800; color: #f0f6fc; letter-spacing: 2px; }

/* Generic copy button */
.pd-copy-btn { background: #21262d; border: 1px solid #30363d; color: #8b949e; font-size: 0.78em; font-weight: 600; padding: 4px 10px; border-radius: 6px; cursor: pointer; transition: background 0.15s, color 0.15s; white-space: nowrap; }
.pd-copy-btn:hover { background: #30363d; color: #c9d1d9; }
.pd-copy-btn.copied { background: #1f4d26; border-color: #238636; color: #7ee787; }

/* Invite / generic link button */
.pd-link-btn { display: inline-block; font-size: 0.82em; color: #58a6ff; text-decoration: none; }
.pd-link-btn:hover { text-decoration: underline; }

/* Wallet blocks */
.pd-wallet-block { background: #0d1117; border: 1px solid #21262d; border-radius: 10px; padding: 14px; margin-bottom: 10px; }
.pd-wallet-header { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; }
.pd-wallet-name { font-size: 0.85em; font-weight: 600; color: #c9d1d9; flex: 1; }
.pd-addr { font-size: 0.72em; color: #58a6ff; word-break: break-all; line-height: 1.5; margin-bottom: 10px; font-family: monospace; }
.pd-qr { display: flex; justify-content: center; margin-top: 10px; }
.pd-qr canvas, .pd-qr img { border-radius: 6px; border: 3px solid #fff; }

/* Voucher form */
.pd-voucher-form { margin-bottom: 6px; }
.pd-voucher-row { display: flex; gap: 8px; }
.pd-voucher-input { flex: 1; background: #0d1117; border: 1px solid #30363d; color: #c9d1d9; border-radius: 8px; padding: 8px 12px; font-size: 0.88em; min-width: 0; }
.pd-voucher-input:focus { outline: none; border-color: #58a6ff; }
.pd-voucher-btn { background: linear-gradient(135deg, #1f6feb, #0b53bf); color: #fff; border: none; border-radius: 8px; padding: 8px 14px; font-size: 0.85em; font-weight: 600; cursor: pointer; white-space: nowrap; transition: opacity 0.15s; }
.pd-voucher-btn:hover { opacity: 0.88; }
.pd-voucher-msg { font-size: 0.82em; min-height: 18px; padding: 2px 0; }
.pd-voucher-msg.ok { color: #7ee787; }
.pd-voucher-msg.err { color: #f85149; }

/* Language select */
.pd-lang-select { width: 100%; }

/* Logout btn */
.pd-logout-btn { display: block; text-align: center; background: #21262d; border: 1px solid #30363d; color: #8b949e; border-radius: 8px; padding: 10px; font-size: 0.9em; font-weight: 600; text-decoration: none; transition: background 0.15s, color 0.15s; }
.pd-logout-btn:hover { background: #3d1515; border-color: #f85149; color: #f85149; text-decoration: none; }

/* Statistic btn */
.pd-stats-btn { display: block; text-align: center; background: #21262d; border: 1px solid #30363d; color: #8b949e; border-radius: 8px; padding: 10px; font-size: 0.9em; font-weight: 600; text-decoration: none; transition: background 0.15s, color 0.15s; }
.pd-stats-btn:hover { background: #21262d; border-color: #21262d; color: #0b53bf; text-decoration: none; }

/* Deposit info card (used on index.php) */
.deposit-info-card {
    background: linear-gradient(135deg, #0d1f12 0%, #0d1117 100%);
    border: 1px solid #238636;
    border-radius: 14px;
    padding: 24px 28px;
    margin-bottom: 40px;
}
.deposit-info-card .dic-title { font-size: 1.15em; font-weight: 800; color: #7ee787; margin-bottom: 6px; }
.deposit-info-card .dic-sub { font-size: 0.9em; color: #8b949e; margin-bottom: 18px; }
.deposit-info-card .dic-wallets { display: flex; flex-direction: column; gap: 10px; }
.deposit-info-card .dic-wallet { background: #0d1117; border: 1px solid #21262d; border-radius: 8px; padding: 10px 14px; display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.deposit-info-card .dic-addr { font-size: 0.75em; color: #58a6ff; word-break: break-all; flex: 1; font-family: monospace; }
.deposit-info-card .dic-copy { background: #21262d; border: 1px solid #30363d; color: #8b949e; font-size: 0.75em; font-weight: 600; padding: 3px 8px; border-radius: 5px; cursor: pointer; white-space: nowrap; transition: background 0.15s; }
.deposit-info-card .dic-copy:hover { background: #30363d; color: #c9d1d9; }
.deposit-info-card .dic-steps { display: flex; gap: 12px; margin-bottom: 18px; flex-wrap: wrap; }
.deposit-info-card .dic-step { flex: 1; min-width: 160px; background: #0d1117; border: 1px solid #21262d; border-radius: 8px; padding: 12px; }
.deposit-info-card .dic-step-num { font-size: 0.7em; font-weight: 700; color: #238636; text-transform: uppercase; letter-spacing: 0.8px; margin-bottom: 4px; }
.deposit-info-card .dic-step-text { font-size: 0.82em; color: #8b949e; }



/* ============================================================
   CryptoGame - Hero Section
   ============================================================ */
.hero-section { background: linear-gradient(135deg, #0d1117 0%, #1a237e 50%, #0d1117 100%); border-radius: 12px; padding: 60px 24px; text-align: center; margin-bottom: 40px; }
.hero-logo { width: 90px; height: 90px; margin-bottom: 20px; filter: drop-shadow(0 4px 12px rgba(247,183,49,.5)); }
.hero-title { font-size: 2.4em; font-weight: 900; color: #f0f6fc; margin: 0 0 12px; letter-spacing: -1px; }
.hero-sub { font-size: 1.1em; color: #8b949e; margin: 0 0 28px; }
.hero-ctas { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }
.btn-hero-primary { background: linear-gradient(135deg, #f7b731, #e67e22); color: #1a237e; font-weight: 800; font-size: 1.1em; padding: 14px 28px; border-radius: 8px; text-decoration: none; transition: transform 0.15s; }
.btn-hero-primary:hover { transform: scale(1.04); text-decoration: none; color: #1a237e; }
.btn-hero-secondary { background: transparent; color: #58a6ff; border: 2px solid #58a6ff; font-weight: 600; font-size: 1em; padding: 12px 24px; border-radius: 8px; text-decoration: none; transition: background 0.15s; }
.btn-hero-secondary:hover { background: rgba(88,166,255,.12); text-decoration: none; }
.btn-outline { background: transparent; color: #58a6ff; border: 2px solid #58a6ff; font-size: 0.95em; padding: 10px 24px; border-radius: 8px; text-decoration: none; transition: background 0.15s; }
.btn-outline:hover { background: rgba(88,166,255,.12); text-decoration: none; }

/* ============================================================
   CryptoGame - Section Layout
   ============================================================ */
.section-block { margin-bottom: 48px; }
.section-title { font-size: 1.7em; font-weight: 800; color: #f0f6fc; margin: 0 0 24px; }
.game-card-actions { display: flex; gap: 8px; margin-top: 8px; }
.rules-link { background: #21262d; color: #8b949e; padding: 8px 16px; border-radius: 6px; font-size: 0.9em; text-align: center; flex: 1; transition: background 0.15s; }
.rules-link:hover { background: #30363d; color: #c9d1d9; text-decoration: none; }

.play-button,
.rules-link,
.btn-hero-primary,
.btn-hero-secondary,
.btn-outline,
.register-btn,
.bet-btn {
    min-height: 44px;
}

/* Higher contrast card styles for index preview game tiles */
.games-preview-grid .game-card {
    border: 1px solid #365275;
    box-shadow: 0 10px 24px rgba(7, 17, 29, 0.35);
}

.games-preview-grid .game-description {
    color: #5b6673;
}

.games-preview-grid .bet-range {
    background: #d7dee8;
    border: 1px solid #b4c2d5;
    color: #253648;
    font-weight: 600;
}

.games-preview-grid .game-economy {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.games-preview-grid .economy-payout {
    color: #1a3650;
    font-weight: 800;
    letter-spacing: 0.01em;
}

.games-preview-grid .economy-divider {
    color: #5f7288;
    font-weight: 700;
}

.games-preview-grid .economy-bet {
    color: #30465e;
    font-weight: 700;
}

.games-preview-grid .rules-link {
    background: #2a3646;
    border: 1px solid #445a75;
    color: #e8eef6;
    font-weight: 600;
}

.games-preview-grid .rules-link:hover {
    background: #34465d;
    color: #ffffff;
}

/* Subtle page-load motion for cards */
.reveal-rise {
    opacity: 0;
    transform: translateY(14px);
    animation: riseIn 0.45s ease forwards;
    animation-delay: calc(var(--card-index, 0) * 0.04s);
}

@keyframes riseIn {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Graphical withdraw success state */
.withdraw-success {
    max-width: 560px;
    margin: 26px auto;
    padding: 26px 22px;
    border-radius: 16px;
    background: linear-gradient(160deg, #10263e 0%, #0f1e32 100%);
    border: 1px solid #28486a;
    box-shadow: 0 14px 32px rgba(6, 16, 26, 0.45);
    color: #dce9f8;
}

.withdraw-success-icon {
    width: 58px;
    height: 58px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.6rem;
    font-weight: 800;
    margin-bottom: 12px;
    color: #0f2f1e;
    background: #5fe08b;
    border: 2px solid #80efaa;
}

.withdraw-success-title {
    margin: 0 0 8px;
    color: #f3f8ff;
    font-size: 1.55rem;
}

.withdraw-success-text,
.withdraw-success-eta {
    margin: 0 0 8px;
    color: #b4c7db;
    line-height: 1.55;
}

.withdraw-success-details {
    margin-top: 16px;
    background: rgba(11, 27, 45, 0.72);
    border: 1px solid #2b4868;
    border-radius: 12px;
    padding: 14px;
}

.withdraw-success-details h3 {
    margin: 0 0 10px;
    font-size: 0.95rem;
    color: #d7e8fb;
}

.withdraw-success-row {
    display: flex;
    justify-content: space-between;
    gap: 14px;
    padding: 8px 0;
    border-top: 1px solid rgba(69, 98, 128, 0.5);
    font-size: 0.94rem;
}

.withdraw-success-row:first-of-type {
    border-top: 0;
    padding-top: 0;
}

.withdraw-success-row span {
    color: #9db4cc;
}

.withdraw-success-row strong {
    color: #f1f6ff;
    text-align: right;
}

.withdraw-success-wallet {
    font-family: monospace;
    letter-spacing: 0.03em;
}

.withdraw-success-actions {
    margin-top: 16px;
    display: flex;
    gap: 10px;
}

.withdraw-success-actions .play-button,
.withdraw-success-actions .rules-link {
    flex: 1;
    text-align: center;
}

@media (max-width: 600px) {
    .withdraw-success {
        margin: 16px auto;
        padding: 18px 14px;
    }

    .withdraw-success-title {
        font-size: 1.28rem;
    }

    .withdraw-success-row {
        flex-direction: column;
        gap: 4px;
    }

    .withdraw-success-row strong {
        text-align: left;
    }

    .withdraw-success-actions {
        flex-direction: column;
    }
}

/* ============================================================
   CryptoGame - How It Works
   ============================================================ */
.steps-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 16px; }
.step-card { background: #161b22; border: 1px solid #30363d; border-radius: 10px; padding: 24px; text-align: center; }
.step-icon { font-size: 2.2em; margin-bottom: 10px; }
.step-card h3 { font-size: 1em; font-weight: 700; color: #f0f6fc; margin: 0 0 8px; }
.step-card p { font-size: 0.88em; color: #8b949e; margin: 0; line-height: 1.5; }

/* ============================================================
   CryptoGame - Info Grid (Referral / Fairness / Deposit)
   ============================================================ */
.info-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 20px; }
.info-card { background: #161b22; border: 1px solid #30363d; border-radius: 10px; padding: 28px; }
.info-card h2 { font-size: 1.2em; font-weight: 700; color: #f0f6fc; margin: 0 0 14px; }
.info-card p, .info-card li { font-size: 0.9em; color: #8b949e; line-height: 1.6; }
.info-card ol, .info-card ul { padding-left: 20px; margin: 0; }
.info-card li { margin-bottom: 8px; }

/* ============================================================
   CryptoGame - Games Full Page (games.php)
   ============================================================ */
.games-hero { text-align: center; padding: 40px 20px 28px; border-bottom: 1px solid #21262d; margin-bottom: 36px; }
.games-hero h1 { font-size: 2em; font-weight: 900; color: #f0f6fc; margin: 0 0 10px; }
.games-subtitle { font-size: 1em; color: #8b949e; margin: 0; }

.games-grid-full { display: flex; flex-direction: column; gap: 24px; margin-bottom: 48px; }
.game-full-card { background: #161b22; border: 1px solid #30363d; border-radius: 12px; overflow: hidden; }
.game-card-header { display: flex; align-items: flex-start; gap: 20px; padding: 24px; border-bottom: 1px solid #21262d; flex-wrap: wrap; }
.game-emoji-lg { font-size: 3em; line-height: 1; flex-shrink: 0; }
.game-card-meta { flex: 1; min-width: 200px; }
.game-card-meta h2 { font-size: 1.3em; font-weight: 700; color: #f0f6fc; margin: 0 0 10px; }
.game-stats { display: flex; flex-wrap: wrap; gap: 8px; }
.stat-badge { font-size: 0.82em; padding: 4px 10px; border-radius: 20px; }
.stat-badge.payout { background: rgba(247,183,49,.15); color: #f7b731; border: 1px solid rgba(247,183,49,.3); }
.stat-badge.chance { background: rgba(63,185,80,.15); color: #3fb950; border: 1px solid rgba(63,185,80,.3); }
.stat-badge.bet { background: rgba(88,166,255,.12); color: #58a6ff; border: 1px solid rgba(88,166,255,.3); }
.game-play-btn { align-self: flex-start; white-space: nowrap; margin-left: auto; flex-shrink: 0; }
.register-cta { background: linear-gradient(135deg, #1f6feb, #388bfd) !important; }

.game-rules-list { padding: 20px 24px; }
.game-rules-list h3 { font-size: 1em; font-weight: 700; color: #8b949e; text-transform: uppercase; letter-spacing: 0.5px; margin: 0 0 12px; }
.game-rules-list ol { margin: 0; padding-left: 20px; }
.game-rules-list li { font-size: 0.9em; color: #c9d1d9; line-height: 1.6; margin-bottom: 6px; }

/* ---- Terms Section ---- */
.terms-section { background: #161b22; border: 1px solid #30363d; border-radius: 12px; padding: 28px; margin-bottom: 32px; }
.terms-section h2 { font-size: 1.3em; font-weight: 700; color: #f0f6fc; margin: 0 0 16px; }
.terms-list { margin: 0; padding-left: 20px; }
.terms-list li { font-size: 0.9em; color: #8b949e; line-height: 1.6; margin-bottom: 8px; }

/* ============================================================
   Responsive overrides
   ============================================================ */
@media (max-width: 700px) {
    .hero-title { font-size: 1.6em; }
    .hero-section { padding: 40px 16px; }
    .hero-logo { width: 64px; height: 64px; }
    .btn-hero-primary, .btn-hero-secondary { font-size: 0.95em; padding: 12px 20px; }
    .hero-ctas { width: 100%; }
    .hero-ctas a { width: 100%; text-align: center; }
    .game-card-header { flex-direction: column; }
    .game-play-btn { margin-left: 0; width: 100%; text-align: center; }
    .brand-name { font-size: 1.2em; }

    /* New topbar / main-nav mobile */
    .topbar { flex-wrap: nowrap; gap: 4px; padding: 6px 0; }
    .brand-logo { width: 28px; height: 28px; }
    /* nav shrinks to just hamburger, does NOT flex:1 so header-right stays visible */
    .main-nav { flex: 0 0 auto; gap: 0; }
    .main-nav a:not(.nav-mobile-toggle) { display: none; }
    .main-nav.responsive { flex-direction: column; position: fixed; top: 48px; left: 0; right: 0; background: #161b22; border-bottom: 1px solid #30363d; padding: 8px 16px 12px; z-index: 200; }
    .main-nav.responsive a { display: block; padding: 8px 10px; }
    .main-nav .nav-mobile-toggle { display: inline-flex; }
    /* header-right: push to right of topbar, stays visible */
    .header-right { margin-left: auto; gap: 4px; flex-shrink: 0; }
    .header-balance-pill { font-size: 0.7em; padding: 3px 6px; max-width: 110px; overflow: hidden; text-overflow: ellipsis; }
    .profile-btn { padding: 5px 8px; font-size: 0.78em; gap: 3px; }
    .profile-btn svg { width: 14px; height: 14px; }
    .profile-btn span.profile-btn-label { display: none; }

    /* Profile drawer full-width on mobile */
    .profile-drawer { width: 100vw; }

    /* Legacy navbar (kept for compatibility) */
    .navbar {
        width: 100%;
        background: #111827;
        border: 1px solid #2a3340;
        border-radius: 10px;
        padding: 6px;
    }
    .navbar a.icon { display: block; font-size: 1.4em; margin-left: auto; }
    .navbar:not(.responsive) a:not(.icon) { display: none; }
    .navbar.responsive { flex-direction: column; align-items: flex-start; }
    .navbar.responsive a,
    .navbar.responsive .nav-info,
    .navbar.responsive .nav-balance {
        display: block;
        width: 100%;
        padding: 10px 12px;
        border-radius: 8px;
    }

    .wallet-bar {
        flex-direction: column;
        gap: 8px;
    }

    .wallet-item {
        align-items: flex-start;
    }

    .wallet-address {
        font-size: 0.72em;
        line-height: 1.45;
    }

    .game-card {
        padding: 18px 14px;
    }

    .game-card-actions {
        width: 100%;
        flex-direction: column;
    }

    .games-preview-grid .game-economy {
        gap: 8px;
        flex-wrap: wrap;
    }

    /* Runner gets a compact mobile layout so the game is visible without heavy scrolling */
    body[data-page="runner"] .main-content {
        padding-top: 10px;
        padding-bottom: 18px;
    }

    body[data-page="runner"] .brand-bar {
        padding: 8px 0 6px;
    }

    body[data-page="runner"] .brand-logo {
        width: 36px;
        height: 36px;
    }

    body[data-page="runner"] .brand-name {
        font-size: 1.15em;
    }

    body[data-page="runner"] .navbar {
        padding: 0;
        background: transparent;
        border: none;
        border-radius: 0;
    }

    body[data-page="runner"] .language-selector {
        display: none;
    }

    body[data-page="runner"] .brand-bar {
        flex-wrap: nowrap;
        align-items: center;
        gap: 6px;
        padding: 4px 0 3px;
    }

    body[data-page="runner"] .navbar .icon {
        padding: 4px 8px;
        font-size: 1.1em;
    }

    body[data-page="runner"] .wallet-bar {
        display: none;
    }

    body[data-page="runner"] .nav-info,
    body[data-page="runner"] .nav-balance {
        display: none;
    }

    body[data-page="runner"] .runner-page-wrap {
        padding: 8px 10px 14px;
    }

    body[data-page="runner"] .runner-header {
        margin-bottom: 8px;
    }

    body[data-page="runner"] .runner-desc,
    body[data-page="runner"] .runner-legend,
    body[data-page="runner"] .runner-controls,
    body[data-page="runner"] .runner-limits {
        display: none;
    }

    body[data-page="runner"] .runner-canvas-wrap {
        margin-bottom: 0;
        border-radius: 12px;
    }

    body[data-page="runner"] #runner-canvas {
        min-height: 220px;
    }

    body[data-page="runner"] .runner-mode-switch {
        width: 100%;
        justify-content: center;
        gap: 6px;
    }

    body[data-page="runner"] .runner-mode-btn {
        min-width: 0;
        flex: 1 1 0;
        padding: 8px 10px;
    }

    body[data-page="runner"][data-runner-mode="fullscreen"] .runner-header {
        padding: 8px 8px 6px;
    }

    body[data-page="runner"][data-runner-mode="fullscreen"] #runner-canvas {
        min-height: calc(100vh - 54px);
    }
}

@media (max-width: 420px) {
    body[data-page="runner"] .runner-page-wrap {
        padding: 6px 8px 12px;
    }

    body[data-page="runner"] .game-screen-title {
        font-size: 1.45rem;
        margin: 8px 0 10px;
    }

    body[data-page="runner"] #runner-canvas {
        min-height: 200px;
    }

    body[data-page="runner"][data-runner-mode="fullscreen"] #runner-canvas {
        min-height: calc(100vh - 50px);
    }
}

@media (max-width: 420px) {
    .section-title {
        font-size: 1.35em;
    }

    .game-title {
        font-size: 1.18em;
    }

    .bet-range {
        font-size: 0.84em;
        padding: 10px 12px;
    }

    .games-preview-grid .economy-divider {
        display: none;
    }
}

@media (prefers-reduced-motion: reduce) {
    .reveal-rise {
        animation: none;
        opacity: 1;
        transform: none;
    }
}

/* Mobile bottom quick action bar */
.mobile-quickbar {
    position: fixed;
    left: 10px;
    right: 10px;
    bottom: 10px;
    z-index: 120;
    display: none;
    gap: 8px;
    padding: 8px;
    border-radius: 14px;
    background: rgba(13, 20, 31, 0.94);
    border: 1px solid #2d3e54;
    box-shadow: 0 12px 28px rgba(0, 0, 0, 0.42);
    backdrop-filter: blur(6px);
}

.mobile-quickbar .mq-item {
    flex: 1;
    min-height: 42px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    text-align: center;
    border-radius: 10px;
    background: #1d2939;
    border: 1px solid #344860;
    color: #dfe9f6;
    font-size: 0.85rem;
    font-weight: 700;
    text-decoration: none;
    padding: 8px 10px;
}

.mobile-quickbar .mq-item.is-primary {
    background: linear-gradient(135deg, #1f6feb 0%, #0b53bf 100%);
    border-color: #3a7de0;
    color: #ffffff;
}

.mobile-quickbar .mq-item.is-active {
    border-color: #7fb3ff;
    box-shadow: inset 0 0 0 1px rgba(127, 179, 255, 0.45);
    background: #22344a;
}

.mobile-quickbar .mq-item:hover {
    text-decoration: none;
    filter: brightness(1.06);
}

@media (max-width: 760px) {
    .mobile-quickbar {
        display: flex;
    }

    .main-content {
        padding-bottom: 96px;
    }
}

/* Dedicated polish for game selector page cards */
.games-selector-grid {
    align-items: stretch;
}

.games-selector-grid .game-card {
    position: relative;
    overflow: hidden;
    border: 1px solid #3a5474;
    box-shadow: 0 12px 28px rgba(3, 10, 22, 0.35);
}

.games-selector-grid .game-card::before {
    content: "";
    position: absolute;
    width: 160px;
    height: 160px;
    right: -64px;
    top: -74px;
    border-radius: 50%;
    background: radial-gradient(circle at center, rgba(88, 166, 255, 0.22) 0%, rgba(88, 166, 255, 0) 70%);
    pointer-events: none;
}

.selector-economy {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.selector-economy-pill {
    border-radius: 10px;
    padding: 9px 10px;
    font-size: 0.84rem;
    font-weight: 700;
}

.selector-economy-payout {
    background: #deebfb;
    color: #20384f;
    border: 1px solid #bdd2ea;
}

.selector-economy-range {
    background: #e9f4eb;
    color: #21452f;
    border: 1px solid #b8d8c1;
}

@media (max-width: 700px) {
    .games-selector-grid .game-card {
        padding: 16px 12px;
    }

    .selector-economy-pill {
        font-size: 0.8rem;
    }
}

/* ============================================================
   CryptoGame - PvP Duel page
   ============================================================ */
.duel-wrap {
    max-width: 900px;
    margin: 0 auto;
}

.duel-wrap h1 {
    margin: 0 0 10px;
    color: #f0f6fc;
    font-size: 2rem;
}

.duel-subtitle {
    margin: 0 0 22px;
    color: #8b949e;
}

.duel-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 16px;
}

.duel-card {
    background: #161b22;
    border: 1px solid #30363d;
    border-radius: 12px;
    padding: 18px;
    margin-bottom: 16px;
}

.duel-card h2 {
    margin-top: 0;
    color: #f0f6fc;
}

.duel-input {
    width: 100%;
    background: #0d1117;
    border: 1px solid #30363d;
    color: #c9d1d9;
    border-radius: 8px;
    padding: 10px 12px;
}

.duel-form {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.duel-choices {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.duel-choice {
    background: #0d1117;
    border: 1px solid #30363d;
    border-radius: 999px;
    padding: 8px 12px;
}

.duel-waiting {
    color: #f7b731;
    font-weight: 600;
}

.duel-message {
    font-weight: 600;
}

.duel-ok {
    border-color: rgba(63, 185, 80, 0.45);
    background: rgba(63, 185, 80, 0.08);
}

.duel-error {
    border-color: rgba(248, 81, 73, 0.45);
    background: rgba(248, 81, 73, 0.08);
}

.duel-alert {
    border-color: rgba(247, 183, 49, 0.45);
    background: rgba(247, 183, 49, 0.08);
}

.duel-danger {
    background: #8b1e3f;
}

.duel-danger:hover {
    background: #a61f48;
}

.duel-result.win {
    color: #3fb950;
    font-weight: 700;
}

.duel-result.lose {
    color: #f85149;
    font-weight: 700;
}

.duel-result.draw {
    color: #79c0ff;
    font-weight: 700;
}

.duel-help {
    color: #8b949e;
    font-size: 0.85rem;
}

.duel-note {
    border-style: dashed;
}

.duel-public-room {
    padding: 12px 0;
    border-top: 1px solid #30363d;
}

.duel-public-room:first-of-type {
    border-top: 0;
    padding-top: 0;
}

.duel-public-room:last-of-type {
    padding-bottom: 0;
}

/* Duel Slider Styles */
.slider-display {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 12px 0;
    --slider-progress: 0%;
}

.duel-slider,
input[type="range"] {
    flex: 1;
    width: 100%;
    display: block;
    height: 20px;
    padding: 0;
    margin: 0;
    border-radius: 999px;
    background: transparent;
    outline: none;
    -webkit-appearance: none;
    appearance: none;
    border: 0;
    box-shadow: none;
    cursor: pointer;
    overflow: visible;
    transition: box-shadow 0.18s ease, filter 0.18s ease;
}

.duel-slider::-webkit-slider-thumb,
input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 20px;
    height: 20px;
    margin-top: -8px;
    border-radius: 50%;
    background: radial-gradient(circle at 30% 30%, #e8f4ff 0%, #7bb7ff 35%, #2f7be5 100%);
    cursor: pointer;
    border: 1px solid rgba(255, 255, 255, 0.7);
    box-shadow: 0 4px 14px rgba(47, 123, 229, 0.45);
    transform: translateY(-1px);
    transition: transform 0.18s ease, box-shadow 0.18s ease, filter 0.18s ease;
}

.duel-slider::-moz-range-thumb,
input[type="range"]::-moz-range-thumb {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: radial-gradient(circle at 30% 30%, #e8f4ff 0%, #7bb7ff 35%, #2f7be5 100%);
    cursor: pointer;
    border: 1px solid rgba(255, 255, 255, 0.7);
    box-shadow: 0 4px 14px rgba(47, 123, 229, 0.45);
    transform: translateY(-1px);
    transition: transform 0.18s ease, box-shadow 0.18s ease, filter 0.18s ease;
}

.duel-slider::-webkit-slider-runnable-track,
input[type="range"]::-webkit-slider-runnable-track {
    height: 6px;
    border-radius: 999px;
    background: linear-gradient(90deg, #57e39b 0%, #2f7be5 var(--slider-progress, 0%), rgba(22, 35, 58, 0.96) var(--slider-progress, 0%), rgba(22, 35, 58, 0.96) 100%);
    border: 1px solid rgba(88, 166, 255, 0.18);
    box-shadow: inset 0 1px 2px rgba(255, 255, 255, 0.08), 0 0 0 1px rgba(0, 0, 0, 0.28);
}

.duel-slider::-moz-range-track,
input[type="range"]::-moz-range-track {
    height: 6px;
    border-radius: 999px;
    background: linear-gradient(90deg, #57e39b 0%, #2f7be5 var(--slider-progress, 0%), rgba(22, 35, 58, 0.96) var(--slider-progress, 0%), rgba(22, 35, 58, 0.96) 100%);
    border: 1px solid rgba(88, 166, 255, 0.18);
    box-shadow: inset 0 1px 2px rgba(255, 255, 255, 0.08), 0 0 0 1px rgba(0, 0, 0, 0.28);
}

.duel-slider::-moz-range-progress,
input[type="range"]::-moz-range-progress {
    height: 6px;
    border-radius: 999px;
    background: linear-gradient(90deg, #57e39b 0%, #2f7be5 100%);
}

.duel-slider:focus-visible,
input[type="range"]:focus-visible {
    outline: 2px solid rgba(87, 227, 155, 0.55);
    outline-offset: 3px;
}

.slider-value {
    min-width: 90px;
    padding: 4px 8px;
    background: linear-gradient(90deg, rgba(87, 227, 155, 0.22) 0%, rgba(47, 123, 229, 0.24) var(--slider-progress, 0%), rgba(47, 123, 229, 0.12) var(--slider-progress, 0%), rgba(47, 123, 229, 0.12) 100%);
    border-radius: 6px;
    font-weight: 600;
    color: #dcecff;
    font-size: 0.95em;
    border: 1px solid rgba(47, 123, 229, 0.22);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08), 0 10px 24px rgba(15, 23, 42, 0.16);
    transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
}

.slider-display.is-live .slider-value {
    transform: translateY(-1px);
    border-color: rgba(87, 227, 155, 0.36);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1), 0 14px 28px rgba(47, 123, 229, 0.18);
}

.slider-display.is-live .duel-slider,
.slider-display.is-live input[type="range"] {
    filter: brightness(1.03);
    box-shadow: inset 0 1px 2px rgba(255, 255, 255, 0.08), 0 0 0 1px rgba(47, 123, 229, 0.16), 0 10px 22px rgba(47, 123, 229, 0.14);
}

.slider-display.is-live .duel-slider::-webkit-slider-thumb,
.slider-display.is-live input[type="range"]::-webkit-slider-thumb,
.slider-display.is-live .duel-slider::-moz-range-thumb,
.slider-display.is-live input[type="range"]::-moz-range-thumb {
    transform: translateY(-1px) scale(1.06);
    box-shadow: 0 6px 18px rgba(47, 123, 229, 0.52);
}

/* Duel Choices Display */
.duel-choices-display {
    display: flex;
    gap: 12px;
    justify-content: center;
    margin: 20px 0;
    flex-wrap: wrap;
}

.duel-choice-display {
    background: linear-gradient(135deg, #1f6feb 0%, #3fb950 100%);
    border-radius: 12px;
    padding: 12px 20px;
    font-weight: 600;
    color: #fff;
    font-size: 1.1em;
    display: flex;
    align-items: center;
    gap: 8px;
}

.duel-choice-display::first-letter {
    text-transform: uppercase;
}

/* Colored choice options */
.duel-choice input[type="radio"] {
    margin-right: 6px;
}

.duel-choice-rock {
    border-color: rgba(156, 163, 165, 0.5);
}

.duel-choice-rock:hover {
    background: rgba(156, 163, 165, 0.1);
}

.duel-choice-paper {
    border-color: rgba(100, 150, 200, 0.5);
}

.duel-choice-paper:hover {
    background: rgba(100, 150, 200, 0.1);
}

.duel-choice-scissors {
    border-color: rgba(255, 152, 0, 0.5);
}

.duel-choice-scissors:hover {
    background: rgba(255, 152, 0, 0.1);
}

.choice-icon {
    font-size: 1.3em;
    display: inline-block;
}

.stats-share-box {
    background: #161b22;
    border: 1px solid #30363d;
    border-radius: 10px;
    padding: 14px;
}

/* Internal admin dashboard (mischa_ops_dashboard.php) */
.ops-wrap {
    max-width: 1400px;
    margin: 0 auto;
}

.ops-head h1 {
    margin: 0 0 8px;
    color: #f0f6fc;
}

.ops-head p {
    margin: 0 0 18px;
    color: #8b949e;
}

.ops-grid-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 12px;
    margin-bottom: 20px;
}

.ops-card {
    background: #161b22;
    border: 1px solid #30363d;
    border-radius: 10px;
    padding: 14px;
}

.ops-card h3 {
    margin: 0 0 8px;
    color: #8b949e;
    font-size: 0.95rem;
}

.ops-card p {
    margin: 0;
    color: #f0f6fc;
    font-size: 1.15rem;
    font-weight: 700;
}

.ops-section {
    margin-bottom: 24px;
}

.ops-section h2 {
    color: #f0f6fc;
    margin: 0 0 10px;
}

.ops-table-wrap {
    overflow: auto;
    border: 1px solid #30363d;
    border-radius: 10px;
}

.ops-table {
    width: 100%;
    border-collapse: collapse;
    min-width: 900px;
}

.ops-table th,
.ops-table td {
    border-bottom: 1px solid #21262d;
    padding: 10px;
    text-align: left;
    font-size: 0.86rem;
}

.ops-table th {
    background: #0d1117;
    color: #8b949e;
    text-transform: uppercase;
    font-size: 0.75rem;
    letter-spacing: 0.04em;
}

.ops-table td {
    color: #c9d1d9;
}

.ops-table tr:hover td {
    background: rgba(88, 166, 255, 0.08);
}

.ops-table tr.ops-rtp-promo td {
    background: rgba(63, 185, 80, 0.09);
}

.ops-table tr.ops-rtp-balanced td {
    background: rgba(88, 166, 255, 0.08);
}

.ops-table tr.ops-rtp-tight td {
    background: rgba(248, 81, 73, 0.08);
}

.ops-table tr.ops-rtp-promo:hover td,
.ops-table tr.ops-rtp-balanced:hover td,
.ops-table tr.ops-rtp-tight:hover td {
    filter: brightness(1.08);
}

.ops-mono {
    font-family: monospace;
}

.ops-user-row {
    cursor: pointer;
}

.ops-user-row td {
    transition: background 0.15s ease;
}

.ops-user-row:hover td {
    background: rgba(88, 166, 255, 0.12);
}

.ops-user-row.is-open td {
    background: rgba(88, 166, 255, 0.2);
}

.ops-token-cell {
    max-width: 420px;
    overflow-wrap: anywhere;
    word-break: break-word;
    font-size: 0.8rem;
}

.ops-token-cell-wrap {
    display: flex;
    align-items: center;
    gap: 10px;
}

.ops-copy-btn {
    border: 1px solid #3b516a;
    background: #1f2c3c;
    color: #d8e4f3;
    border-radius: 6px;
    padding: 6px 10px;
    font-size: 0.76rem;
    font-weight: 700;
    cursor: pointer;
    flex-shrink: 0;
}

.ops-copy-btn:hover {
    background: #2a3d53;
}

.ops-copy-btn.is-copied {
    background: #1f5f3a;
    border-color: #3da76a;
    color: #e7fff1;
}

.ops-user-detail-row {
    display: none;
}

.ops-user-detail-row.is-open {
    display: table-row;
}

.ops-user-detail-row td {
    background: #111926;
    border-bottom: 1px solid #2a3442;
    padding: 14px 12px;
}

.ops-user-detail-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 8px 14px;
    font-size: 0.84rem;
    color: #c9d1d9;
}

.ops-user-detail-grid strong {
    color: #8b949e;
}

.ops-profile-btn {
    min-height: 34px !important;
    padding: 8px 12px !important;
    font-size: 0.9rem !important;
    border-radius: 8px !important;
}

.ops-delta-ok {
    color: #7ee787;
    font-weight: 700;
}

.ops-delta-high {
    color: #ff7b72;
    font-weight: 700;
}

.ops-neutral {
    color: #8b949e;
}

.vip-voucher-page {
    max-width: 980px;
    margin: 0 auto;
    display: grid;
    gap: 16px;
}

.vip-voucher-card {
    background: linear-gradient(180deg, #161d29 0%, #111827 100%);
    border: 1px solid #2a3442;
    border-radius: 16px;
    padding: 20px;
    box-shadow: 0 14px 28px rgba(2, 8, 20, 0.38);
}

.vip-voucher-title {
    margin: 0 0 8px;
    color: #f2f7ff;
    font-size: 1.8rem;
}

.vip-voucher-subtitle {
    margin: 0 0 12px;
    color: #b8c6d9;
    line-height: 1.5;
}

.vip-balance-badge {
    margin: 0 0 14px;
    display: inline-flex;
    gap: 8px;
    align-items: center;
    padding: 8px 12px;
    border-radius: 999px;
    background: rgba(63, 185, 80, 0.16);
    border: 1px solid rgba(63, 185, 80, 0.4);
    color: #d7ffe2;
    font-weight: 700;
}

.vip-voucher-form {
    display: grid;
    gap: 10px;
    max-width: 540px;
}

.vip-voucher-form label {
    color: #d6e2f1;
    font-weight: 600;
}

.vip-voucher-card .duel-input {
    background: #0b1220;
    border-color: #2d3a4c;
    color: #e5edf8;
}

.vip-voucher-card .duel-input::placeholder {
    color: #91a2b8;
}

.vip-voucher-card .bet-btn {
    background: linear-gradient(90deg, #2458c9 0%, #3f7df0 100%);
    border-radius: 10px;
    font-weight: 700;
}

.vip-voucher-card .bet-btn:hover {
    background: linear-gradient(90deg, #1f4dab 0%, #366fd2 100%);
}

.vip-voucher-card .duel-message {
    color: #e6edf7;
}

.vip-voucher-card .duel-ok {
    border-color: rgba(63, 185, 80, 0.5);
    background: rgba(63, 185, 80, 0.16);
}

.vip-voucher-card .duel-error {
    border-color: rgba(248, 81, 73, 0.5);
    background: rgba(248, 81, 73, 0.16);
}

.vip-voucher-history-title {
    margin: 0 0 10px;
    color: #f2f7ff;
}

.vip-voucher-table {
    min-width: 760px;
}

.vip-voucher-card .ops-table-wrap {
    border-color: #2a3442;
}

.vip-voucher-table th {
    background: #0a101b;
    color: #9fb1c8;
}

.vip-voucher-table td {
    color: #d8e1ef;
    background: #111926;
}

.vip-voucher-table tr:hover td {
    background: #172234;
}

.vip-voucher-table .withdraws-empty {
    color: #a8b7cb;
}

.vip-voucher-table .ops-neutral {
    color: #c7d2e3;
    font-weight: 700;
}

@media (max-width: 900px) {
    .ops-token-cell-wrap {
        flex-direction: column;
        align-items: flex-start;
    }

    .vip-voucher-card {
        padding: 14px;
    }

    .vip-voucher-title {
        font-size: 1.35rem;
    }
}

.ops-two-col {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 18px;
}

@media (max-width: 1000px) {
    .ops-two-col {
        grid-template-columns: 1fr;
    }
}

/* Brighter game view overrides */
.game-screen-wrap {
    max-width: 640px;
    margin: 0 auto;
}

.game-screen-title {
    text-align: center;
    color: #f0f6fc;
    margin: 0 0 12px;
    font-size: 1.6rem;
}

.game-form {
    background: linear-gradient(180deg, #1b2533 0%, #121a25 100%) !important;
    border: 1px solid #2f4055;
    border-radius: 14px;
    padding: 20px 18px;
    box-shadow: 0 10px 32px rgba(0, 0, 0, 0.35);
}

.bet-label,
.choice-label {
    color: #d8e3f3 !important;
    font-weight: 700;
}

.min-max-bet {
    color: #9fb3cc !important;
}

.sim-rounds-select {
    width: 100%;
    margin: 6px 0 4px;
    background: #0f1722;
    border: 1px solid #2f4055;
    color: #d8e3f3;
    border-radius: 10px;
    padding: 10px 12px;
    font-weight: 700;
    outline: none;
}

.sim-rounds-select:focus {
    border-color: #4f8cff;
    box-shadow: 0 0 0 2px rgba(79, 140, 255, 0.18);
}

.bet-output-wrap {
    margin-top: 8px;
    color: #d8e3f3;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 5px 10px;
    border-radius: 8px;
    background: linear-gradient(90deg, rgba(87, 227, 155, 0.18) 0%, rgba(47, 123, 229, 0.24) var(--slider-progress, 0%), rgba(47, 123, 229, 0.1) var(--slider-progress, 0%), rgba(47, 123, 229, 0.1) 100%);
    border: 1px solid rgba(47, 123, 229, 0.22);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08), 0 10px 24px rgba(15, 23, 42, 0.14);
    transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
}

#betOutput {
    color: #58a6ff !important;
    font-weight: 800;
}

.withdraw-range-row output {
    display: inline-flex;
    align-items: center;
    padding: 4px 8px;
    border-radius: 8px;
    background: linear-gradient(90deg, rgba(87, 227, 155, 0.16) 0%, rgba(47, 123, 229, 0.22) var(--slider-progress, 0%), rgba(47, 123, 229, 0.1) var(--slider-progress, 0%), rgba(47, 123, 229, 0.1) 100%);
    border: 1px solid rgba(47, 123, 229, 0.2);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08), 0 8px 18px rgba(15, 23, 42, 0.12);
    color: #58a6ff;
    font-weight: 800;
    transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
}

.bet-output-wrap.is-slider-live,
.withdraw-range-row.is-slider-live output {
    border-color: rgba(87, 227, 155, 0.34);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1), 0 14px 28px rgba(47, 123, 229, 0.16);
}

.bet-output-wrap.is-slider-live {
    transform: translateY(-1px);
}

.withdraw-range-row.is-slider-live output {
    transform: translateY(-1px);
}

@media (max-width: 600px) {
    .slider-display {
        gap: 10px;
        align-items: flex-start;
        flex-direction: column;
    }

    .slider-value,
    .bet-output-wrap,
    .withdraw-range-row output {
        font-size: 0.9em;
    }

    .slider-value,
    .bet-output-wrap {
        min-width: 0;
        width: fit-content;
        max-width: 100%;
    }

    .withdraw-range-row {
        gap: 8px;
    }
}

/* ─── VIP Voucher Floating Button & Modal ─────────────────────────────── */

.voucher-fab {
    position: fixed;
    bottom: 22px;
    right: 22px;
    z-index: 1100;
    background: linear-gradient(135deg, #7b3fe4 0%, #c87d1c 100%);
    color: #fff;
    border: none;
    border-radius: 30px;
    padding: 0 18px;
    height: 44px;
    font-size: 0.88rem;
    font-weight: 700;
    letter-spacing: 0.02em;
    cursor: pointer;
    box-shadow: 0 4px 18px rgba(123, 63, 228, 0.55);
    transition: transform 0.15s, box-shadow 0.15s;
    white-space: nowrap;
}

.voucher-fab:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 28px rgba(123, 63, 228, 0.7);
}

.voucher-fab:active {
    transform: translateY(0);
}

.voucher-backdrop {
    position: fixed;
    inset: 0;
    z-index: 1200;
    background: rgba(5, 10, 20, 0.72);
    backdrop-filter: blur(3px);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.22s;
}

.voucher-backdrop.is-open {
    opacity: 1;
    pointer-events: auto;
}

.voucher-modal {
    position: fixed;
    z-index: 1300;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -42%) scale(0.95);
    width: min(92vw, 420px);
    background: linear-gradient(180deg, #1b2533 0%, #0f1923 100%);
    border: 1px solid rgba(123, 63, 228, 0.4);
    border-radius: 18px;
    padding: 28px 28px 26px;
    box-shadow: 0 24px 80px rgba(0, 0, 0, 0.7), 0 0 0 1px rgba(255,255,255,0.05);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.22s, transform 0.22s;
    text-align: center;
}

.voucher-modal.is-open {
    opacity: 1;
    pointer-events: auto;
    transform: translate(-50%, -50%) scale(1);
}

.voucher-modal-close {
    position: absolute;
    top: 14px;
    right: 16px;
    background: rgba(255,255,255,0.07);
    border: none;
    color: #8b949e;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    font-size: 1rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.15s, color 0.15s;
}

.voucher-modal-close:hover {
    background: rgba(255,255,255,0.14);
    color: #f0f6fc;
}

.voucher-modal-icon {
    font-size: 2.6rem;
    margin-bottom: 6px;
    line-height: 1;
}

.voucher-modal-title {
    color: #c9a84c;
    font-size: 1.3rem;
    font-weight: 800;
    margin: 0 0 4px;
}

.voucher-modal-subtitle {
    color: #8b949e;
    font-size: 0.83rem;
    margin: 0 0 16px;
    line-height: 1.4;
}

.voucher-modal-form {
    display: flex;
    flex-direction: column;
    gap: 10px;
    text-align: left;
}

.voucher-modal-form label {
    color: #d8e3f3;
    font-weight: 600;
    font-size: 0.88rem;
}

.voucher-modal-alert {
    background: rgba(255, 80, 80, 0.14);
    border: 1px solid rgba(255, 80, 80, 0.35);
    border-radius: 8px;
    color: #ff7b72;
    font-size: 0.85rem;
    padding: 9px 12px;
    text-align: left;
    margin-bottom: 4px;
}

.voucher-modal-success {
    flex-direction: column;
    align-items: center;
    gap: 6px;
    padding: 16px 0 8px;
}

.voucher-success-icon {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    background: linear-gradient(135deg, #238636, #2ea043);
    color: #fff;
    font-size: 1.6rem;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 8px;
    box-shadow: 0 0 24px rgba(46, 160, 67, 0.55);
}

.voucher-success-amount {
    color: #7ee787;
    font-size: 1.5rem;
    font-weight: 800;
    margin: 0;
}

.voucher-success-balance {
    color: #8b949e;
    font-size: 0.88rem;
    margin: 0;
}

@media (max-width: 600px) {
    .voucher-fab {
        bottom: 70px;
        right: 14px;
        font-size: 0.82rem;
        padding: 0 14px;
        height: 40px;
    }

    .voucher-modal {
        padding: 22px 18px 20px;
    }
}

.choices-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(96px, 1fr));
    gap: 10px;
}

.choice-btn {
    background: #0f1622 !important;
    color: #d6e2f2 !important;
    border: 1px solid #2f4055 !important;
    min-height: 82px;
}

.choice-btn:hover {
    border-color: #58a6ff !important;
    background: #162234 !important;
}

.choice-emoji {
    font-size: 1.8rem;
    display: block;
    margin-bottom: 4px;
}

.choices-container input[type="radio"]:checked + label {
    border-color: #58a6ff !important;
    box-shadow: 0 0 0 2px rgba(88, 166, 255, 0.22);
    background: #1a2a3f !important;
}

.bet-btn {
    background: linear-gradient(135deg, #1f6feb, #388bfd) !important;
    color: #fff;
    border-radius: 10px;
    border: 0;
    padding: 12px 16px;
    font-size: 1.05rem;
    font-weight: 700;
}

.bet-btn:hover {
    background: linear-gradient(135deg, #388bfd, #58a6ff) !important;
}

.game-back-link {
    margin-top: 14px;
    max-width: 320px;
    display: block;
    margin-left: auto;
    margin-right: auto;
}

.game-result-popup-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(6, 10, 18, 0.62);
    backdrop-filter: blur(4px);
    z-index: 1390;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.22s ease;
}

.game-result-popup-backdrop.is-open {
    opacity: 1;
    pointer-events: auto;
}

.game-result-popup {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -46%);
    width: min(94vw, 580px);
    z-index: 1400;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.22s ease, transform 0.22s ease;
}

.game-result-popup.is-open {
    opacity: 1;
    pointer-events: auto;
    transform: translate(-50%, -50%);
}

.game-result-popup-progress {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    border-top-left-radius: 12px;
    border-top-right-radius: 12px;
    overflow: hidden;
    background: rgba(255, 255, 255, 0.08);
}

.game-result-popup-progress span {
    display: block;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, #5fb3ff, #7ee787);
    transform-origin: left center;
}

.game-result-popup .modern-result {
    margin: 0;
    max-width: none;
    box-shadow: 0 24px 54px rgba(2, 7, 15, 0.5);
}

.game-result-popup-close {
    position: absolute;
    top: 10px;
    right: 12px;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, 0.26);
    background: rgba(15, 24, 36, 0.92);
    color: #d5e5fb;
    font-size: 1.25rem;
    line-height: 1;
    cursor: pointer;
    z-index: 2;
}

.game-result-popup-close:hover {
    color: #ffffff;
    border-color: rgba(255, 255, 255, 0.42);
}

.game-result-popup[data-slot-pending] {
    opacity: 0 !important;
    pointer-events: none !important;
    transform: translate(-50%, -46%) !important;
    transition: none !important;
}

.game-result-popup-backdrop[data-slot-pending] {
    opacity: 0 !important;
    pointer-events: none !important;
    transition: none !important;
}

.modern-result {
    max-width: 520px;
    margin: 0 auto 14px;
    border-radius: 12px;
    padding: 14px 16px;
    border: 1px solid #2f4055;
    background: #151e2b;
    color: #dbe7f6;
    animation: resultReveal 0.5s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.modern-result-title {
    font-weight: 800;
}

.modern-result-final {
    font-weight: 800;
    animation: resultPulse 1.1s ease 0.08s;
    text-align: center;
    width: 100%;
}

.modern-result-head {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin-bottom: 10px;
    text-align: center;
}

.modern-result-grid {
    display: grid;
    gap: 8px;
}

.modern-result-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 8px 10px;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.06);
}

.modern-result-label {
    font-size: 0.88rem;
    color: #9fb0c6;
    font-weight: 600;
}

.modern-result-value {
    font-weight: 700;
    color: #e6eefb;
    text-align: right;
}

.modern-result-net {
    font-weight: 700;
}

.modern-result-net.net-pos {
    color: #7ee787;
}

.modern-result-net.net-neg {
    color: #ff7b72;
}

.modern-result.win { border-color: #2d7d46; }
.modern-result.lose { border-color: #8a3d3d; }
.modern-result.draw { border-color: #2f5f8e; }
.modern-result.error { border-color: #ad5b1a; }

.modern-result.win .modern-result-final { color: #7ee787; }
.modern-result.lose .modern-result-final { color: #ff7b72; }
.modern-result.draw .modern-result-final { color: #79c0ff; }
.modern-result.error .modern-result-final { color: #ffb86b; }

.sim-results-table-wrap {
    margin-top: 12px;
    overflow-x: auto;
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    background: rgba(255, 255, 255, 0.02);
}

.sim-results-table {
    width: 100%;
    min-width: 920px;
    border-collapse: collapse;
    font-size: 0.78rem;
}

.sim-results-table th,
.sim-results-table td {
    padding: 8px 9px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    text-align: right;
    white-space: nowrap;
}

.sim-results-table th {
    color: #99aecd;
    font-weight: 700;
    background: rgba(255, 255, 255, 0.03);
}

.sim-results-table th:first-child,
.sim-results-table td:first-child,
.sim-results-table th:nth-child(2),
.sim-results-table td:nth-child(2) {
    text-align: left;
}

.sim-net {
    font-weight: 800;
}

.sim-net.sim-net-pos {
    color: #7ee787;
}

.sim-net.sim-net-neg {
    color: #ff7b72;
}

.game-visual {
    max-width: 520px;
    margin: 0 auto 14px;
    border: 1px solid #2f4055;
    border-radius: 14px;
    min-height: 94px;
    background: radial-gradient(circle at 20% 20%, #1f2f46, #111a27 70%);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    overflow: hidden;
}

.visual-rpsls span {
    font-size: 2rem;
    font-family: "Segoe UI Emoji", "Apple Color Emoji", "Noto Color Emoji", sans-serif;
    font-variant-emoji: emoji;
    animation: floatPulse 2.6s ease-in-out infinite;
}
.visual-rpsls span:nth-child(2) { animation-delay: 0.15s; }
.visual-rpsls span:nth-child(3) { animation-delay: 0.3s; }
.visual-rpsls span:nth-child(4) { animation-delay: 0.45s; }
.visual-rpsls span:nth-child(5) { animation-delay: 0.6s; }

.visual-dice .dice-face {
    font-size: 3.1rem;
    animation: diceShake 1.8s ease-in-out infinite;
}

.visual-dice .dice-face svg {
    width: clamp(64px, 12vw, 80px);
    height: clamp(64px, 12vw, 80px);
    display: block;
}

.visual-all-games-sim span {
    font-size: 2rem;
    animation: floatPulse 2.4s ease-in-out infinite;
}

.visual-all-games-sim span:nth-child(2) { animation-delay: 0.12s; }
.visual-all-games-sim span:nth-child(3) { animation-delay: 0.24s; }
.visual-all-games-sim span:nth-child(4) { animation-delay: 0.36s; }
.visual-all-games-sim span:nth-child(5) { animation-delay: 0.48s; }

.visual-coin .coin-orbit {
    width: 86px;
    height: 86px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    position: relative;
    font-size: 1.55rem;
    font-weight: 900;
    letter-spacing: 0.08em;
    color: #f8fbff;
    text-shadow: 0 1px 0 rgba(0, 0, 0, 0.24);
    background: radial-gradient(circle at 30% 28%, #fff6b0 0%, #f7cb54 30%, #d89b12 64%, #8b5e08 100%);
    border: 1px solid rgba(255, 236, 168, 0.72);
    box-shadow: inset 0 2px 8px rgba(255,255,255,0.35), 0 10px 24px rgba(0, 0, 0, 0.26);
    animation: coinFlip 1.5s linear infinite;
    transform-style: preserve-3d;
}

.visual-coin .coin-svg {
    width: 100%;
    height: 100%;
    display: block;
}

.visual-coin .coin-orbit::before {
    content: attr(data-coin-face-label);
}

.visual-coin .coin-orbit::after {
    content: '';
    position: absolute;
    inset: 10px;
    border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, 0.25);
    box-shadow: inset 0 0 0 1px rgba(130, 92, 5, 0.18);
}

.visual-even-odd span {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    font-weight: 800;
}

.visual-even-odd .eo-even {
    background: #2ea043;
    color: #fff;
    animation: pulseUp 1.6s ease-in-out infinite;
}

.visual-even-odd .eo-odd {
    background: #d29922;
    color: #111;
    animation: pulseUp 1.6s ease-in-out infinite 0.8s;
}

.visual-high-low {
    gap: 16px;
}

.visual-high-low .card-low,
.visual-high-low .card-high {
    width: 64px;
    height: 86px;
    border-radius: 8px;
    background: #f6f8fa;
    border: 1px solid #a8b3c2;
    font-size: 1.7rem;
    font-weight: 800;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 8px 18px rgba(0, 0, 0, 0.28);
}

.visual-high-low .card-low {
    color: #d1242f;
    animation: cardLift 2s ease-in-out infinite;
}

.visual-high-low .card-high {
    color: #1f6feb;
    animation: cardLift 2s ease-in-out infinite 0.6s;
}

.visual-wheel {
    position: relative;
}

.visual-wheel .wheel-disc {
    font-size: 3.2rem;
    animation: wheelSpin 2.4s linear infinite;
}

.visual-wheel .wheel-tip {
    position: absolute;
    top: 8px;
    color: #ffb86b;
    font-size: 1rem;
}

.visual-colors {
    gap: 18px;
}

.visual-colors .color-chip {
    width: 56px;
    height: 56px;
    border-radius: 16px;
    display: inline-block;
    box-shadow: 0 10px 18px rgba(0, 0, 0, 0.28);
    animation: colorBounce 1.8s ease-in-out infinite;
}

.visual-colors .color-chip.red {
    background: linear-gradient(135deg, #ff5b6e, #c6283f);
}

.visual-colors .color-chip.blue {
    background: linear-gradient(135deg, #60a5fa, #1d4ed8);
    animation-delay: 0.2s;
}

.visual-colors .color-chip.gold {
    background: linear-gradient(135deg, #ffd76a, #d29922);
    animation-delay: 0.4s;
}

.visual-colors .color-chip.green,
.visual-color-clash .color-chip.green {
    background: linear-gradient(135deg, #4ade80, #16a34a);
}

.visual-color-clash .color-chip.silver {
    background: linear-gradient(135deg, #d1d5db, #9ca3af);
}

.visual-quick-draw,
.visual-race-21,
.visual-target-50 {
    display: flex;
    justify-content: center;
    gap: 10px;
    flex-wrap: wrap;
}

.visual-quick-draw span,
.visual-race-21 span,
.visual-target-50 span {
    min-width: 52px;
    min-height: 52px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: linear-gradient(135deg, #1f6feb, #58a6ff);
    color: #fff;
    font-weight: 800;
    box-shadow: 0 10px 24px rgba(31, 111, 235, 0.25);
}

.visual-color-clash {
    display: flex;
    justify-content: center;
    gap: 12px;
    flex-wrap: wrap;
}

.visual-color-clash .color-chip {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    display: inline-block;
    box-shadow: 0 12px 28px rgba(0, 0, 0, 0.28);
}

.visual-slot-machine {
    padding: 12px 18px;
    width: 100%;
}

.slot-cabinet {
    width: min(100%, 420px);
    min-width: 320px;
    position: relative;
    margin-top: 18px;
    padding: 18px 18px 16px;
    border-radius: 22px;
    background: linear-gradient(180deg, #24354f 0%, #121b28 100%);
    border: 1px solid rgba(255, 215, 106, 0.2);
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.06), 0 16px 32px rgba(0,0,0,0.34);
    display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
    gap: 14px;
    align-items: stretch;
    justify-content: center;
    overflow: visible;
}

.slot-cabinet::before {
    content: 'CLASSIC SLOT';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translate(-50%, -28px);
    color: #ffd76a;
    letter-spacing: 0.14em;
    font-size: 0.72rem;
    font-weight: 800;
}

.slot-reel {
    flex: 1 1 0;
    min-width: 106px;
    height: 120px;
    border-radius: 18px;
    background: linear-gradient(180deg, #f9fbff 0%, #dce8ff 100%);
    border: 1px solid rgba(167, 188, 222, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: inset 0 2px 6px rgba(255,255,255,0.75), 0 8px 18px rgba(9, 18, 33, 0.28);
    overflow: hidden;
    position: relative;
}

.slot-reel::before,
.slot-reel::after {
    content: '';
    position: absolute;
    left: 8px;
    right: 8px;
    height: 14px;
    border-radius: 999px;
    pointer-events: none;
    background: linear-gradient(180deg, rgba(255,255,255,0.6), rgba(255,255,255,0));
}

.slot-reel::before {
    top: 8px;
}

.slot-reel::after {
    bottom: 8px;
    transform: rotate(180deg);
}

.slot-reel span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    line-height: 1;
    font-size: clamp(3.6rem, 7vw, 4.8rem);
    font-family: "Segoe UI Emoji", "Apple Color Emoji", "Noto Color Emoji", sans-serif;
    font-variant-emoji: emoji;
    animation: slotBounce 1.5s ease-in-out infinite;
    transition: transform 0.35s ease, filter 0.35s ease;
    text-align: center;
}

.slot-reel span svg {
    width: 100%;
    height: 100%;
    display: block;
}

.slot-reel:nth-child(2) span {
    animation-delay: 0.16s;
}

.slot-reel:nth-child(3) span {
    animation-delay: 0.32s;
}

.game-visual [data-choice],
.dice-face,
.coin-orbit,
.slot-reel span,
.visual-wheel .wheel-disc,
.visual-race-21 span,
.visual-target-50 span {
    transition: transform 0.35s ease, filter 0.35s ease, box-shadow 0.35s ease;
}

.game-visual [data-choice].is-user-choice,
.dice-face.is-user-choice,
.coin-orbit.is-user-choice {
    filter: drop-shadow(0 0 14px rgba(88, 166, 255, 0.38));
}

.game-visual [data-choice].is-computer-choice,
.dice-face.is-computer-choice,
.coin-orbit.is-computer-choice,
.visual-wheel .wheel-disc.is-computer-choice,
.visual-race-21 span.is-computer-choice,
.visual-target-50 span.is-computer-choice {
    animation: none !important;
    transform: scale(1.5);
    filter: drop-shadow(0 0 18px rgba(255, 215, 106, 0.46));
}

.game-visual [data-choice].is-winning-choice,
.dice-face.is-winning-choice,
.coin-orbit.is-winning-choice,
.slot-reel span.is-winning-choice,
.visual-wheel .wheel-disc.is-winning-choice,
.visual-race-21 span.is-winning-choice,
.visual-target-50 span.is-winning-choice {
    animation: none !important;
    filter: drop-shadow(0 0 22px rgba(126, 231, 135, 0.6));
}

.game-visual [data-choice].is-draw-choice,
.slot-reel span.is-draw-choice,
.visual-wheel .wheel-disc.is-draw-choice,
.visual-race-21 span.is-draw-choice,
.visual-target-50 span.is-draw-choice {
    animation: none !important;
    filter: drop-shadow(0 0 18px rgba(121, 192, 255, 0.5));
}

.game-visual.has-result.result-win {
    box-shadow: 0 0 0 1px rgba(126, 231, 135, 0.16), 0 18px 42px rgba(46, 160, 67, 0.14);
}

.game-visual.has-result.result-lose {
    box-shadow: 0 0 0 1px rgba(248, 81, 73, 0.14), 0 18px 42px rgba(248, 81, 73, 0.12);
}

.game-visual.has-result.result-draw {
    box-shadow: 0 0 0 1px rgba(121, 192, 255, 0.16), 0 18px 42px rgba(88, 166, 255, 0.12);
}

.slot-reel span.is-spinning {
    animation: slotSpinBlur 0.18s linear infinite;
}

.slot-reel span.is-final-stop {
    animation: slotStopPop 0.45s ease;
}

.game-form .bet-btn.is-submitting,
.game-form .bet-btn:disabled {
    opacity: 0.82;
    cursor: wait;
    filter: saturate(0.92) brightness(0.98);
}

.visual-slot-machine.is-spinning .slot-cabinet {
    animation: cabinetShake 0.28s ease-in-out infinite;
}

.visual-slot-machine.result-win .slot-cabinet {
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.08), 0 0 0 1px rgba(126, 231, 135, 0.18), 0 18px 36px rgba(46, 160, 67, 0.22);
}

.visual-slot-machine.result-lose .slot-cabinet {
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.06), 0 0 0 1px rgba(248, 81, 73, 0.16), 0 16px 32px rgba(248, 81, 73, 0.14);
}

.visual-slot-machine .slot-reel.is-reel-stop {
    animation: reelSettle 0.38s ease;
}

.visual-slot-machine .slot-reel.is-reel-match {
    box-shadow: inset 0 2px 6px rgba(255,255,255,0.78), 0 0 0 1px rgba(255, 215, 106, 0.32), 0 14px 30px rgba(255, 215, 106, 0.22);
}

.dice-face.is-final-stop,
.coin-orbit.is-final-stop,
.visual-wheel .wheel-disc.is-final-stop,
.visual-race-21 span.is-final-stop,
.visual-target-50 span.is-final-stop {
    animation: slotStopPop 0.45s ease;
}

.visual-race-21 span.is-preview-step,
.visual-target-50 span.is-preview-step {
    animation: pulseUp 0.5s ease;
}

@media (max-width: 600px) {
    .slot-cabinet {
        width: min(100%, 360px);
        min-width: 0;
        gap: 10px;
        padding: 16px 14px 14px;
    }

    .slot-reel {
        min-width: 0;
        height: 98px;
    }

    .slot-reel span {
        font-size: 3rem;
    }
}

@keyframes floatPulse {
    0%, 100% { transform: translateY(0) scale(1); opacity: 0.88; }
    50% { transform: translateY(-6px) scale(1.08); opacity: 1; }
}

@keyframes diceShake {
    0%, 100% { transform: rotate(0deg) scale(1); }
    20% { transform: rotate(-8deg) scale(1.07); }
    40% { transform: rotate(8deg) scale(1.05); }
    60% { transform: rotate(-4deg) scale(1.03); }
    80% { transform: rotate(4deg) scale(1.02); }
}

@keyframes coinFlip {
    0% { transform: rotateY(0deg); }
    100% { transform: rotateY(360deg); }
}

@keyframes pulseUp {
    0%, 100% { transform: scale(1); box-shadow: 0 0 0 rgba(0,0,0,0); }
    50% { transform: scale(1.12); box-shadow: 0 0 18px rgba(255,255,255,0.2); }
}

@keyframes cardLift {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    50% { transform: translateY(-7px) rotate(-2deg); }
}

@keyframes wheelSpin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

@keyframes colorBounce {
    0%, 100% { transform: translateY(0) scale(1); }
    50% { transform: translateY(-8px) scale(1.06); }
}

@keyframes slotBounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-6px) scale(1.06); }
}

@keyframes slotSpinBlur {
    0% { transform: translateY(-14px) scale(1.02); filter: blur(0.5px); }
    50% { transform: translateY(14px) scale(0.98); filter: blur(1.8px); }
    100% { transform: translateY(-14px) scale(1.02); filter: blur(0.5px); }
}

@keyframes slotStopPop {
    0% { transform: scale(0.82); }
    60% { transform: scale(1.16); }
    100% { transform: scale(1); }
}

@keyframes resultReveal {
    0% { opacity: 0; transform: translateY(10px) scale(0.98); }
    100% { opacity: 1; transform: translateY(0) scale(1); }
}

@keyframes resultPulse {
    0%, 100% { transform: scale(1); }
    40% { transform: scale(1.04); }
}

@keyframes cabinetShake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-2px); }
    50% { transform: translateX(2px); }
    75% { transform: translateX(-1px); }
}

@keyframes reelSettle {
    0% { transform: translateY(-3px) scale(0.98); }
    60% { transform: translateY(2px) scale(1.02); }
    100% { transform: translateY(0) scale(1); }
}

.slot-cabinet.is-slot-win {
    animation: slotWinPulse 0.7s ease 1 forwards;
}

.slot-cabinet.is-jackpot {
    animation: jackpotGlow 0.55s ease-in-out infinite alternate;
}

.slot-cabinet.is-jackpot::after {
    content: '\2605 JACKPOT! \2605';
    position: absolute;
    bottom: -38px;
    left: 50%;
    transform: translateX(-50%);
    color: #ffd76a;
    font-size: 0.88rem;
    font-weight: 900;
    letter-spacing: 0.12em;
    text-shadow: 0 0 10px rgba(255, 215, 106, 0.9), 0 0 22px rgba(255, 185, 0, 0.5);
    white-space: nowrap;
    animation: jackpotBadge 0.45s ease;
}

@keyframes slotWinPulse {
    0%   { box-shadow: inset 0 1px 0 rgba(255,255,255,0.08), 0 0 0 1px rgba(126, 231, 135, 0.28), 0 18px 36px rgba(46, 160, 67, 0.22); }
    45%  { box-shadow: inset 0 1px 0 rgba(255,255,255,0.12), 0 0 0 3px rgba(126, 231, 135, 0.6), 0 22px 48px rgba(46, 160, 67, 0.44); }
    100% { box-shadow: inset 0 1px 0 rgba(255,255,255,0.08), 0 0 0 1px rgba(126, 231, 135, 0.28), 0 18px 36px rgba(46, 160, 67, 0.22); }
}

@keyframes jackpotGlow {
    from { box-shadow: inset 0 1px 0 rgba(255,255,255,0.1), 0 0 0 2px rgba(255, 215, 106, 0.5), 0 18px 36px rgba(255, 185, 0, 0.28); }
    to   { box-shadow: inset 0 1px 0 rgba(255,255,255,0.14), 0 0 0 4px rgba(255, 200, 50, 0.85), 0 22px 50px rgba(255, 185, 0, 0.55); }
}

@keyframes jackpotBadge {
    0%   { opacity: 0; transform: translateX(-50%) scale(0.7); }
    70%  { opacity: 1; transform: translateX(-50%) scale(1.08); }
    100% { opacity: 1; transform: translateX(-50%) scale(1); }
}

/* ── Game progression table (race_to_21, target_50) ──────────────────── */

.game-progression {
    display: flex;
    justify-content: center;
    overflow-x: auto;
    margin: 14px 0 6px;
    animation: fadeSlideUp 0.42s ease;
    -webkit-overflow-scrolling: touch;
}

.progression-table {
    display: inline-table;
    border-collapse: separate;
    border-spacing: 5px;
    font-size: 0.8rem;
}

.progression-table thead th {
    padding: 2px 4px;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.38);
    text-align: center;
    letter-spacing: 0.04em;
    font-size: 0.68rem;
    white-space: nowrap;
}

.progression-table tbody th {
    padding: 0 10px 0 2px;
    font-size: 0.72rem;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.42);
    text-align: left;
    white-space: nowrap;
    vertical-align: middle;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.progression-table td {
    padding: 0;
    text-align: center;
    font-variant-numeric: tabular-nums;
    vertical-align: middle;
}

/* Each data cell is a badge pill */
.progression-table td span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 30px;
    height: 30px;
    border-radius: 8px;
    padding: 0 6px;
    font-size: 0.8rem;
    font-weight: 600;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.07);
    color: rgba(200, 218, 255, 0.7);
}

.prog-row.prog-player td span {
    background: rgba(88, 130, 200, 0.12);
    border-color: rgba(121, 192, 255, 0.18);
    color: rgba(121, 192, 255, 0.9);
}

.prog-row.prog-computer td span {
    background: rgba(200, 200, 220, 0.07);
    border-color: rgba(200, 200, 220, 0.11);
    color: rgba(200, 200, 210, 0.72);
}

/* Last step (the finishing move) */
.progression-table td span.prog-cell-last {
    font-weight: 800;
    border-color: rgba(121, 192, 255, 0.35);
    color: #c8daff;
}

/* Total column separator + badge */
.prog-total-head {
    color: rgba(255, 255, 255, 0.55) !important;
    padding-left: 10px !important;
}

.progression-table td.prog-total-cell {
    padding-left: 6px;
}

.progression-table td.prog-total-cell span {
    min-width: 36px;
    height: 32px;
    border-radius: 10px;
    font-size: 0.88rem;
    font-weight: 800;
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.14);
    color: rgba(200, 218, 255, 0.95);
}

.progression-table td.prog-total-cell span.prog-total-win {
    background: rgba(46, 160, 67, 0.18);
    border-color: rgba(126, 231, 135, 0.35);
    color: #7ee787;
    box-shadow: 0 0 8px rgba(126, 231, 135, 0.22);
}

.progression-table td.prog-total-cell span.prog-total-draw {
    background: rgba(88, 166, 255, 0.14);
    border-color: rgba(121, 192, 255, 0.3);
    color: #79c0ff;
}

@keyframes fadeSlideUp {
    from { opacity: 0; transform: translateY(8px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* ── XMR Runner arcade game ─────────────────────────────────────────────── */

.runner-page-wrap {
    max-width: 860px;
    margin: 0 auto;
    padding: 18px 14px 32px;
}

.runner-header { text-align: center; margin-bottom: 14px; }

.runner-mode-switch {
    display: inline-flex;
    gap: 8px;
    margin: 6px 0 10px;
    padding: 5px;
    border-radius: 999px;
    background: rgba(255,255,255,0.05);
    border: 1px solid rgba(88,166,255,0.12);
}

.runner-mode-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 96px;
    padding: 8px 14px;
    border-radius: 999px;
    color: rgba(200,218,255,0.72);
    text-decoration: none;
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    background: transparent;
    transition: background 0.18s ease, color 0.18s ease, transform 0.18s ease;
}

.runner-mode-btn:hover { text-decoration: none; transform: translateY(-1px); }

.runner-mode-btn.is-active {
    color: #0d1117;
    background: linear-gradient(135deg, #79c0ff, #58a6ff);
    box-shadow: 0 0 0 1px rgba(88,166,255,0.28), 0 10px 24px rgba(88,166,255,0.2);
}

.runner-desc {
    color: rgba(200,218,255,0.68);
    font-size: 0.88rem;
    line-height: 1.55;
    margin: 6px 0 10px;
}

.runner-legend {
    display: flex;
    flex-wrap: wrap;
    gap: 10px 20px;
    justify-content: center;
    font-size: 0.8rem;
    color: rgba(200,218,255,0.6);
    margin-bottom: 4px;
}

.runner-legend-item { display: flex; align-items: center; gap: 6px; }

.legend-dot {
    width: 11px; height: 11px;
    border-radius: 50%;
    display: inline-block;
    box-shadow: 0 0 6px currentColor;
}

.legend-flag { font-size: 1rem; color: #ffd700; }

.runner-legend-sep { width: 1px; background: rgba(255,255,255,0.1); align-self: stretch; }

.runner-canvas-wrap {
    width: 100%;
    max-width: 820px;
    margin: 0 auto 10px;
    border-radius: 14px;
    overflow: hidden;
    border: 1px solid rgba(88,166,255,0.15);
    box-shadow: 0 0 0 1px rgba(88,166,255,0.08), 0 18px 42px rgba(0,0,0,0.44);
    background: #030b16;
    cursor: pointer;
}

#runner-canvas {
    display: block;
    width: 100%;
    height: auto;
    image-rendering: crisp-edges;
    image-rendering: pixelated;
}

.runner-controls {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 24px;
    justify-content: center;
    font-size: 0.78rem;
    color: rgba(200,218,255,0.45);
    margin-top: 10px;
}

.runner-controls kbd {
    display: inline-block;
    padding: 1px 6px;
    border-radius: 5px;
    background: rgba(255,255,255,0.07);
    border: 1px solid rgba(255,255,255,0.12);
    font-family: monospace;
    font-size: 0.78rem;
    color: rgba(200,218,255,0.75);
}

.runner-limits {
    text-align: center;
    font-size: 0.72rem;
    color: rgba(200,218,255,0.3);
    margin-top: 10px;
}

body[data-page="runner"][data-runner-mode="fullscreen"] .site-header {
    display: none;
}

body[data-page="runner"][data-runner-mode="fullscreen"] .main-content {
    padding-top: 0;
    padding-bottom: 0;
}

body[data-page="runner"][data-runner-mode="fullscreen"] .runner-page-wrap {
    max-width: none;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    padding: 0;
}

body[data-page="runner"][data-runner-mode="fullscreen"] .runner-header {
    margin-bottom: 0;
    padding: 10px 10px 8px;
}

body[data-page="runner"][data-runner-mode="fullscreen"] .runner-desc,
body[data-page="runner"][data-runner-mode="fullscreen"] .runner-legend,
body[data-page="runner"][data-runner-mode="fullscreen"] .runner-controls,
body[data-page="runner"][data-runner-mode="fullscreen"] .runner-limits {
    display: none;
}

body[data-page="runner"][data-runner-mode="fullscreen"] .runner-canvas-wrap {
    max-width: none;
    width: 100vw;
    margin: 0;
    border-radius: 0;
    border-left: 0;
    border-right: 0;
    box-shadow: none;
    flex: 1 1 auto;
}

body[data-page="runner"][data-runner-mode="fullscreen"] #runner-canvas {
    min-height: calc(100vh - 64px);
}
