/* ==========================================================================
   CasinoManager – Design System
   Zentrales Stylesheet für alle Seiten (öffentlich, Login, Admin, User).
   Unterstützt Dark/Light über [data-theme] auf <html>, siehe app.js.
   ========================================================================== */

/* -------------------------------------------------------------------- */
/* Tokens                                                                */
/* -------------------------------------------------------------------- */

:root,
[data-theme="dark"] {
    --color-bg: #14161c;
    --color-bg-alt: #0f1115;
    --color-surface: #1d2027;
    --color-surface-alt: #262a33;
    --color-border: #343a46;
    --color-text: #e8eaed;
    --color-text-muted: #9aa1ac;
    --color-primary: #e6394a;
    --color-primary-hover: #ff4d5e;
    --color-primary-contrast: #ffffff;
    --color-success: #3ddc84;
    --color-warning: #ffce4d;
    --color-danger: #ff5d5d;
    --color-info: #4da3ff;

    --shadow: 0 4px 16px rgba(0, 0, 0, 0.35);
}

[data-theme="light"] {
    --color-bg: #f4f5f7;
    --color-bg-alt: #eceef1;
    --color-surface: #ffffff;
    --color-surface-alt: #f0f1f4;
    --color-border: #dde1e6;
    --color-text: #1c1f26;
    --color-text-muted: #5b6270;
    --color-primary: #d6293a;
    --color-primary-hover: #c01f30;
    --color-primary-contrast: #ffffff;
    --color-success: #1f9d57;
    --color-warning: #b9790a;
    --color-danger: #d6293a;
    --color-info: #1d6fd1;

    --shadow: 0 4px 16px rgba(20, 22, 28, 0.08);
}

:root {
    --font-sans: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
    --radius-sm: 6px;
    --radius: 10px;
    --radius-lg: 16px;
    --transition: 0.2s ease;
    --sidebar-width: 250px;
    --topbar-height: 56px;
}

/* -------------------------------------------------------------------- */
/* Reset & Base                                                          */
/* -------------------------------------------------------------------- */

*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    -webkit-text-size-adjust: 100%;
    overflow-x: hidden;
}

body {
    margin: 0;
    overflow-x: hidden;
    font-family: var(--font-sans);
    background: var(--color-bg);
    color: var(--color-text);
    line-height: 1.5;
    transition: background-color var(--transition), color var(--transition);
}

h1, h2, h3, h4, h5, h6 {
    margin: 0 0 0.5em;
    font-weight: 600;
    line-height: 1.25;
}

p {
    margin: 0 0 1em;
}

a {
    color: var(--color-primary);
    text-decoration: none;
    transition: color var(--transition);
}

a:hover {
    color: var(--color-primary-hover);
}

img {
    max-width: 100%;
    display: block;
}

ul, ol {
    padding-left: 1.25em;
}

hr {
    border: none;
    border-top: 1px solid var(--color-border);
    margin: 1.5em 0;
}

/* -------------------------------------------------------------------- */
/* Layout: öffentliche Seiten                                            */
/* -------------------------------------------------------------------- */

.container {
    width: 100%;
    max-width: 1080px;
    margin: 0 auto;
    padding: 0 20px;
}

.site-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 0;
    border-bottom: 1px solid var(--color-border);
}

.site-header .brand {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 20px;
    font-weight: 700;
    color: var(--color-text);
}

.site-header .brand img {
    width: 32px;
    height: 32px;
    border-radius: var(--radius-sm);
}

.site-header nav {
    display: flex;
    align-items: center;
    gap: 12px;
}

.site-footer {
    border-top: 1px solid var(--color-border);
    padding: 24px 0;
    color: var(--color-text-muted);
    font-size: 14px;
    text-align: center;
}

.site-footer a {
    color: var(--color-text-muted);
}

.site-footer a:hover {
    color: var(--color-primary);
}

.site-footer .footer-links {
    display: flex;
    justify-content: center;
    gap: 16px;
    flex-wrap: wrap;
    margin-top: 8px;
}

/* Hero */

.hero {
    padding: 80px 0;
    text-align: center;
}

.hero h1 {
    font-size: clamp(28px, 5vw, 46px);
    margin-bottom: 16px;
}

.hero p {
    font-size: 18px;
    color: var(--color-text-muted);
    max-width: 640px;
    margin: 0 auto 28px;
}

.hero .actions {
    display: flex;
    justify-content: center;
    gap: 12px;
    flex-wrap: wrap;
}

/* Spektakulärer Hero (Landing Page) */

.hero-spectacular {
    position: relative;
    overflow: hidden;
    isolation: isolate;
}

.hero-glow {
    position: absolute;
    inset: -40% -10% auto -10%;
    height: 480px;
    background: radial-gradient(circle at 50% 30%, var(--color-primary) 0%, transparent 70%);
    opacity: 0.2;
    filter: blur(60px);
    z-index: -1;
    pointer-events: none;
    animation: hero-glow-pulse 8s ease-in-out infinite;
}

@keyframes hero-glow-pulse {
    0%, 100% { opacity: 0.15; transform: scale(1); }
    50% { opacity: 0.3; transform: scale(1.08); }
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 14px;
    border-radius: 999px;
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    font-size: 13px;
    font-weight: 600;
    color: var(--color-text-muted);
    margin-bottom: 16px;
}

.hero-badge i {
    color: var(--color-success);
    font-size: 10px;
    animation: hero-badge-pulse 2s ease-in-out infinite;
}

@keyframes hero-badge-pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.25; }
}

.hero h1 .text-accent {
    color: var(--color-primary);
}

/* Stats (Landing Page) */

.stats-section {
    padding-top: 0;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 20px;
}

.stat-card {
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
    padding: 28px 20px;
    text-align: center;
}

.stat-card .stat-value {
    display: block;
    font-size: 36px;
    font-weight: 700;
    color: var(--color-primary);
    line-height: 1.2;
    margin-bottom: 4px;
}

.stat-card .stat-label {
    color: var(--color-text-muted);
    font-size: 14px;
}

/* Steps (Landing Page) */

.steps {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 20px;
}

.step-card {
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
    padding: 24px;
    text-align: center;
}

.step-card .step-number {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--color-primary);
    color: var(--color-primary-contrast);
    font-weight: 700;
    margin-bottom: 12px;
}

.step-card h3 {
    font-size: 18px;
    margin-bottom: 8px;
}

.step-card p {
    color: var(--color-text-muted);
    margin-bottom: 0;
    font-size: 15px;
}

/* Feature / content grid */

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

.section {
    padding: 48px 0;
}

.section h2 {
    text-align: center;
    margin-bottom: 32px;
    font-size: 28px;
}

.feature-card {
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
    padding: 24px;
    text-align: center;
}

.feature-card i {
    font-size: 28px;
    color: var(--color-primary);
    margin-bottom: 12px;
}

.feature-card h3 {
    font-size: 18px;
    margin-bottom: 8px;
}

.feature-card p {
    color: var(--color-text-muted);
    margin-bottom: 0;
    font-size: 15px;
}

/* Simple article page (DSGVO/Impressum) */

.page-article {
    max-width: 760px;
    margin: 0 auto;
    padding: 40px 0 64px;
}

.page-article h1 {
    font-size: 30px;
    margin-bottom: 24px;
}

.page-article h2 {
    font-size: 20px;
    margin-top: 28px;
}

.page-article ul {
    color: var(--color-text-muted);
}

.page-article p {
    color: var(--color-text-muted);
}

/* Auth pages (Login, Passwort vergessen/zurücksetzen) */

.auth-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
}

.auth-card {
    width: 100%;
    max-width: 380px;
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
    padding: 32px;
}

.auth-card h1 {
    font-size: 22px;
    text-align: center;
    margin-bottom: 4px;
}

.auth-card .subtitle {
    text-align: center;
    color: var(--color-text-muted);
    font-size: 14px;
    margin-bottom: 24px;
}

.auth-card .links {
    text-align: center;
    margin-top: 16px;
    font-size: 14px;
}

.auth-card .links a {
    color: var(--color-text-muted);
}

.auth-card .links a:hover {
    color: var(--color-primary);
}

/* -------------------------------------------------------------------- */
/* App-Shell: Admin/User-Bereich mit Sidebar                            */
/* -------------------------------------------------------------------- */

.app-shell {
    display: flex;
    min-height: 100vh;
}

.sidebar {
    position: fixed;
    top: 0;
    left: 0;
    width: var(--sidebar-width);
    height: 100%;
    background: var(--color-surface);
    border-right: 1px solid var(--color-border);
    display: flex;
    flex-direction: column;
    z-index: 100;
    transition: transform var(--transition);
    overflow-y: auto;
}

.sidebar .profile {
    padding: 24px 20px;
    text-align: center;
    border-bottom: 1px solid var(--color-border);
}

.sidebar .profile img {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    margin: 0 auto 12px;
    border: 2px solid var(--color-border);
}

.sidebar .profile h3 {
    font-size: 16px;
    margin-bottom: 4px;
}

.sidebar .profile p {
    font-size: 13px;
    color: var(--color-text-muted);
    margin-bottom: 4px;
}

.sidebar .profile progress {
    width: 100%;
    height: 6px;
    margin-top: 6px;
    accent-color: var(--color-primary);
}

.sidebar-nav {
    list-style: none;
    margin: 0;
    padding: 12px 10px;
    flex: 1;
}

.sidebar-nav li + li {
    margin-top: 2px;
}

.sidebar-link {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 11px 14px;
    border-radius: var(--radius);
    color: var(--color-text-muted);
    font-size: 14px;
    font-weight: 500;
    transition: background-color var(--transition), color var(--transition);
}

.sidebar-link .icon {
    width: 18px;
    text-align: center;
    color: inherit;
}

.sidebar-link:hover {
    background: var(--color-surface-alt);
    color: var(--color-text);
}

.sidebar-link.active {
    background: var(--color-primary);
    color: var(--color-primary-contrast);
}

.sidebar-link.active .icon {
    color: var(--color-primary-contrast);
}

.sidebar-link.unread {
    color: var(--color-warning);
}

.sidebar-footer {
    padding: 14px 20px;
    border-top: 1px solid var(--color-border);
}

/* Topbar (mobile) */

.topbar {
    display: none;
    position: sticky;
    top: 0;
    z-index: 90;
    align-items: center;
    justify-content: space-between;
    height: var(--topbar-height);
    padding: 0 16px;
    background: var(--color-surface);
    border-bottom: 1px solid var(--color-border);
}

.topbar .brand {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 700;
    color: var(--color-text);
}

.topbar .brand img {
    width: 28px;
    height: 28px;
    border-radius: var(--radius-sm);
}

.hamburger {
    background: none;
    border: none;
    font-size: 22px;
    color: var(--color-text);
    cursor: pointer;
    padding: 6px;
    line-height: 1;
}

/* Main content area */

.main {
    margin-left: var(--sidebar-width);
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
}

.main-content {
    padding: 28px;
    flex: 1;
    width: 100%;
    max-width: 1100px;
    margin: 0 auto;
}

.page-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 24px;
}

.page-header h1 {
    font-size: 24px;
    margin: 0;
}

/* Overlay for mobile sidebar */

.sidebar-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 95;
}

/* -------------------------------------------------------------------- */
/* Components                                                            */
/* -------------------------------------------------------------------- */

/* Cards */

.card {
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
    padding: 20px;
    margin-bottom: 20px;
}

.card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
}

.card-header h2,
.card-header h3 {
    margin: 0;
    font-size: 17px;
}

/* Stat cards */

.stat-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 16px;
    margin-bottom: 20px;
}

.stat-card {
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
    padding: 18px;
}

.stat-card .label {
    color: var(--color-text-muted);
    font-size: 13px;
    margin-bottom: 6px;
}

.stat-card .value {
    font-size: 24px;
    font-weight: 700;
}

/* Buttons */

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 20px;
    font-size: 14px;
    font-weight: 600;
    border-radius: var(--radius);
    border: 1px solid transparent;
    cursor: pointer;
    text-decoration: none;
    transition: background-color var(--transition), color var(--transition), border-color var(--transition);
    line-height: 1.2;
}

.btn-primary {
    background: var(--color-primary);
    color: var(--color-primary-contrast);
}

.btn-primary:hover {
    background: var(--color-primary-hover);
    color: var(--color-primary-contrast);
}

.btn-secondary {
    background: var(--color-surface-alt);
    color: var(--color-text);
    border-color: var(--color-border);
}

.btn-secondary:hover {
    background: var(--color-border);
    color: var(--color-text);
}

.btn-ghost {
    background: transparent;
    color: var(--color-text);
    border-color: var(--color-border);
}

.btn-ghost:hover {
    background: var(--color-surface-alt);
    color: var(--color-text);
}

.btn-danger {
    background: var(--color-danger);
    color: #ffffff;
}

.btn-danger:hover {
    opacity: 0.9;
    color: #ffffff;
}

.btn-sm {
    padding: 6px 14px;
    font-size: 13px;
}

.btn-block {
    width: 100%;
}

.btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* Forms */

.form-group {
    margin-bottom: 18px;
}

.form-label {
    display: block;
    margin-bottom: 6px;
    font-size: 14px;
    font-weight: 600;
    color: var(--color-text);
}

.form-control,
input[type="text"],
input[type="password"],
input[type="email"],
input[type="number"],
input[type="date"],
select,
textarea {
    width: 100%;
    padding: 11px 14px;
    font-size: 14px;
    font-family: inherit;
    color: var(--color-text);
    background: var(--color-bg-alt);
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    transition: border-color var(--transition), box-shadow var(--transition);
}

.form-control:focus,
input:focus,
select:focus,
textarea:focus {
    outline: none;
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px rgba(230, 57, 74, 0.15);
}

.form-text {
    font-size: 13px;
    color: var(--color-text-muted);
    margin-top: 6px;
}

.invalid-feedback {
    display: block;
    font-size: 13px;
    color: var(--color-danger);
    margin-top: 6px;
}

.form-row {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
}

.form-row > .form-group {
    flex: 1;
    min-width: 180px;
}

/* Alerts */

.alert {
    padding: 14px 16px;
    border-radius: var(--radius);
    border: 1px solid transparent;
    margin-bottom: 18px;
    font-size: 14px;
}

.alert-success {
    background: rgba(61, 220, 132, 0.12);
    border-color: rgba(61, 220, 132, 0.35);
    color: var(--color-success);
}

.alert-danger {
    background: rgba(255, 93, 93, 0.12);
    border-color: rgba(255, 93, 93, 0.35);
    color: var(--color-danger);
}

.alert-info {
    background: rgba(77, 163, 255, 0.12);
    border-color: rgba(77, 163, 255, 0.35);
    color: var(--color-info);
}

.alert-warning {
    background: rgba(255, 206, 77, 0.12);
    border-color: rgba(255, 206, 77, 0.35);
    color: var(--color-warning);
}

/* Badges */

.badge {
    display: inline-flex;
    align-items: center;
    padding: 4px 10px;
    font-size: 12px;
    font-weight: 600;
    border-radius: 999px;
    background: var(--color-surface-alt);
    color: var(--color-text-muted);
    border: 1px solid var(--color-border);
}

.badge-success {
    background: rgba(61, 220, 132, 0.12);
    color: var(--color-success);
    border-color: rgba(61, 220, 132, 0.35);
}

.badge-danger {
    background: rgba(255, 93, 93, 0.12);
    color: var(--color-danger);
    border-color: rgba(255, 93, 93, 0.35);
}

.badge-warning {
    background: rgba(255, 206, 77, 0.12);
    color: var(--color-warning);
    border-color: rgba(255, 206, 77, 0.35);
}

.badge-info {
    background: rgba(77, 163, 255, 0.12);
    color: var(--color-info);
    border-color: rgba(77, 163, 255, 0.35);
}

/* Tables */

.table-responsive {
    width: 100%;
    overflow-x: auto;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
}

table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14px;
}

table th,
table td {
    padding: 12px 16px;
    text-align: left;
    border-bottom: 1px solid var(--color-border);
    white-space: nowrap;
}

table th {
    background: var(--color-surface-alt);
    color: var(--color-text-muted);
    font-weight: 600;
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

table tbody tr:last-child td {
    border-bottom: none;
}

table tbody tr:hover {
    background: var(--color-surface-alt);
}

table tbody tr.unread td {
    background: rgba(255, 206, 77, 0.12);
    font-weight: 600;
}

/* Aktions-Buttons innerhalb von Tabellenzellen (z. B. Jeton-Auszahlung) */

.bet-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    white-space: normal;
}

/* Theme toggle */

.theme-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    border-radius: var(--radius);
    border: 1px solid var(--color-border);
    background: var(--color-surface-alt);
    color: var(--color-text);
    cursor: pointer;
    font-size: 16px;
    transition: background-color var(--transition), color var(--transition);
}

.theme-toggle:hover {
    background: var(--color-border);
}

.theme-toggle .icon-light,
.theme-toggle .icon-dark {
    display: none;
}

[data-theme="dark"] .theme-toggle .icon-light {
    display: inline;
}

[data-theme="light"] .theme-toggle .icon-dark {
    display: inline;
}

/* Marquee / Ticker */

.ticker {
    background: var(--color-warning);
    color: #2b1d00;
    padding: 8px 0;
    font-weight: 600;
    overflow: hidden;
}

.ticker marquee {
    font-size: 15px;
}

/* -------------------------------------------------------------------- */
/* Responsive                                                            */
/* -------------------------------------------------------------------- */

@media (max-width: 900px) {
    .app-shell {
        flex-direction: column;
    }

    .sidebar {
        transform: translateX(-100%);
        box-shadow: var(--shadow);
    }

    .sidebar.open {
        transform: translateX(0);
    }

    .sidebar-overlay.open {
        display: block;
    }

    .main {
        margin-left: 0;
    }

    .topbar {
        display: flex;
    }

    .main-content {
        padding: 18px;
    }

    .card {
        padding: 16px;
    }

    .stat-grid {
        grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
        gap: 12px;
    }

    table {
        font-size: 13px;
    }

    .btn {
        padding: 9px 16px;
    }
}

@media (max-width: 600px) {
    .hero {
        padding: 48px 0;
    }

    .auth-card {
        padding: 24px;
    }

    .page-header {
        align-items: flex-start;
    }

    .page-header h1 {
        font-size: 20px;
    }

    .main-content {
        padding: 12px;
    }

    .card {
        padding: 14px;
        border-radius: var(--radius);
    }

    table th,
    table td {
        padding: 10px 12px;
        font-size: 12.5px;
    }

    form .btn {
        width: 100%;
    }

    .form-group {
        margin-bottom: 14px;
    }

    .bet-actions {
        gap: 8px;
    }

    .bet-actions .btn {
        flex: 1 1 calc(50% - 8px);
    }

    .slot-cabinet {
        --slot-symbol-size: 56px;
        padding: 12px;
    }

    .slot-lever {
        display: none;
    }
}

@media (max-width: 360px) {
    .slot-cabinet {
        --slot-symbol-size: 46px;
    }
}

/* -------------------------------------------------------------------- */
/* Utilities                                                             */
/* -------------------------------------------------------------------- */

.text-muted {
    color: var(--color-text-muted);
    font-size: 13px;
}

/* -------------------------------------------------------------------- */
/* Spielautomat                                                          */
/* -------------------------------------------------------------------- */

.slot-machine {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.slot-cabinet {
    --slot-symbol-size: 84px;
    position: relative;
    background: linear-gradient(160deg, #3a2f1f, #181410 65%);
    border: 4px solid #caa14a;
    border-radius: 22px;
    padding: 18px;
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.45), inset 0 0 30px rgba(0, 0, 0, 0.6);
}

.slot-marquee {
    display: flex;
    justify-content: space-evenly;
    align-items: center;
    padding: 4px 6px 14px;
}

.slot-marquee .bulb {
    width: 9px;
    height: 9px;
    border-radius: 50%;
    background: #ffd76b;
    box-shadow: 0 0 8px 2px rgba(255, 215, 107, 0.8);
    animation: slot-bulb-pulse 1.6s ease-in-out infinite;
}

.slot-marquee .bulb:nth-child(even) {
    animation-delay: 0.4s;
}

.slot-cabinet.spinning .slot-marquee .bulb {
    animation-duration: 0.35s;
}

@keyframes slot-bulb-pulse {
    0%, 100% { opacity: 0.3; }
    50% { opacity: 1; }
}

.slot-reels-wrapper {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 14px;
}

.slot-reels {
    position: relative;
    display: flex;
    justify-content: center;
    gap: 10px;
    background: #0b0a09;
    border-radius: 12px;
    padding: 10px;
    box-shadow: inset 0 4px 14px rgba(0, 0, 0, 0.65);
}

.slot-reel-window {
    position: relative;
    width: var(--slot-symbol-size);
    height: calc(var(--slot-symbol-size) * 3);
    overflow: hidden;
    background: linear-gradient(180deg, #1c1a18, #322c26 50%, #1c1a18);
    border-radius: 8px;
    border: 2px solid #4a4038;
}

.slot-reel-window::before,
.slot-reel-window::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    height: 32%;
    pointer-events: none;
    z-index: 2;
}

.slot-reel-window::before {
    top: 0;
    background: linear-gradient(180deg, rgba(0, 0, 0, 0.7), rgba(0, 0, 0, 0));
}

.slot-reel-window::after {
    bottom: 0;
    background: linear-gradient(0deg, rgba(0, 0, 0, 0.7), rgba(0, 0, 0, 0));
}

.slot-reel-strip {
    display: flex;
    flex-direction: column;
    will-change: transform;
}

.slot-symbol {
    width: var(--slot-symbol-size);
    height: var(--slot-symbol-size);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: calc(var(--slot-symbol-size) * 0.55);
    line-height: 1;
    flex-shrink: 0;
}

.slot-reel-strip.spinning {
    filter: blur(1.5px);
}

.slot-payline {
    position: absolute;
    left: 10px;
    right: 10px;
    top: 50%;
    height: var(--slot-symbol-size);
    transform: translateY(-50%);
    border-top: 2px dashed rgba(255, 214, 0, 0.7);
    border-bottom: 2px dashed rgba(255, 214, 0, 0.7);
    pointer-events: none;
    z-index: 3;
    box-sizing: border-box;
}

.slot-lever {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 22px;
    height: calc(var(--slot-symbol-size) * 3 + 20px);
    flex-shrink: 0;
}

.slot-lever::before {
    content: "";
    display: block;
    width: 8px;
    height: 70%;
    margin: 0 auto;
    background: linear-gradient(90deg, #8a8a8a, #e0e0e0, #8a8a8a);
    border-radius: 4px;
}

.slot-lever-knob {
    position: absolute;
    top: 0;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: radial-gradient(circle at 30% 30%, #ff6b6b, #b71c1c);
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.5);
}

.slot-controls {
    display: flex;
    flex-direction: column;
    gap: 12px;
    max-width: 360px;
    margin: 0 auto;
    width: 100%;
}

.slot-actionbar {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.slot-step-btn {
    flex: 0 0 auto;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: 1px solid var(--color-border);
    background: var(--color-surface-alt);
    color: var(--color-text);
    font-size: 22px;
    font-weight: 700;
    line-height: 1;
    cursor: pointer;
    transition: background-color var(--transition), border-color var(--transition);
}

.slot-step-btn:hover {
    background: var(--color-border);
}

.slot-step-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.slot-bet-display {
    flex: 1 1 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2px;
    min-width: 0;
    padding: 8px 10px;
    border-radius: 10px;
    background: #0b0a09;
    border: 2px solid #4a4038;
    box-shadow: inset 0 2px 8px rgba(0, 0, 0, 0.6);
    cursor: text;
}

.slot-bet-display-label {
    font-size: 10px;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: #caa14a;
}

.slot-bet-display-amount {
    display: flex;
    align-items: baseline;
    gap: 4px;
    font-family: "Courier New", monospace;
    color: #ffd76b;
    font-weight: 700;
    font-size: 18px;
}

.slot-bet-input {
    width: 4.5ch;
    border: none;
    background: transparent;
    color: inherit;
    font: inherit;
    text-align: right;
    padding: 0;
    -moz-appearance: textfield;
    appearance: textfield;
}

.slot-bet-input::-webkit-outer-spin-button,
.slot-bet-input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.slot-bet-input:focus {
    outline: none;
}

.slot-bet-display-suffix {
    font-size: 14px;
}

.slot-spin-btn {
    flex: 0 0 auto;
    width: 64px;
    height: 64px;
    border-radius: 50%;
    border: 3px solid #ffe9a8;
    background: radial-gradient(circle at 35% 30%, #ffe08a, #d4900f 60%, #8a5a08);
    color: #3a2407;
    font-size: 26px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 4px 14px rgba(212, 144, 15, 0.55), inset 0 2px 6px rgba(255, 255, 255, 0.4);
    transition: transform 0.15s ease, box-shadow var(--transition);
}

.slot-spin-btn:hover {
    box-shadow: 0 6px 18px rgba(212, 144, 15, 0.7), inset 0 2px 6px rgba(255, 255, 255, 0.4);
}

.slot-spin-btn:active {
    transform: scale(0.95);
}

.slot-spin-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.slot-spin-btn:disabled i {
    animation: slot-spin-rotate 0.8s linear infinite;
}

@keyframes slot-spin-rotate {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.slot-more-btn {
    display: none;
    flex: 0 0 auto;
    width: 44px;
    height: 44px;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    border: 1px solid var(--color-border);
    background: var(--color-surface-alt);
    color: var(--color-text);
    font-size: 18px;
    cursor: pointer;
    transition: background-color var(--transition), color var(--transition);
}

.slot-more-btn:hover,
.slot-more-btn[aria-expanded="true"] {
    background: var(--color-primary);
    color: var(--color-primary-contrast);
}

.slot-extra-panel {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.slot-bet-quick {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.slot-bet-quick .btn {
    flex: 1 1 auto;
}

.slot-result {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    min-height: 28px;
    padding: 10px 16px;
    border-radius: 10px;
    background: var(--color-surface-alt);
    border: 1px solid var(--color-border);
    font-size: 14px;
    max-width: 360px;
    margin: 0 auto;
    width: 100%;
}

.slot-result-label {
    color: var(--color-text-muted);
    font-weight: 600;
    white-space: nowrap;
}

.slot-result-value {
    flex: 1;
    text-align: right;
    font-weight: 600;
}

.slot-result.win .slot-result-value {
    color: var(--color-success);
}

.slot-result.loss .slot-result-value {
    color: var(--color-danger);
}

.slot-autospin {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding-top: 12px;
    border-top: 1px dashed var(--color-border);
}

.slot-autospin-row {
    display: flex;
    gap: 8px;
    align-items: stretch;
}

.slot-autospin-row .form-control {
    flex: 1 1 auto;
}

.slot-autospin-row .btn {
    flex: 0 0 auto;
    white-space: nowrap;
}

.slot-autospin-status {
    text-align: center;
}

@media (max-width: 600px) {
    .slot-more-btn {
        display: flex;
    }

    .slot-extra-panel {
        display: none;
    }

    .slot-extra-panel.open {
        display: flex;
    }
}
