/* --- Roulette Page Styles (Premium Winter Edition) --- */

.roulette-container {
    max-width: 500px;
    margin: 0 auto;
    position: relative;
}

/* --- Balance Display --- */
.balance-display {
    background: rgba(15, 23, 42, 0.8);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 1rem;
    padding: 1rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    box-shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.5);
    position: relative;
    overflow: hidden;
}

.balance-display::before {
    content: '';
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.03), transparent);
    animation: shimmer 3s infinite;
}

.balance-label {
    font-size: 0.75rem;
    text-transform: uppercase;
    color: #94a3b8;
    font-weight: 700;
    letter-spacing: 0.05em;
}

.balance-amount {
    font-family: 'Fira Code', monospace;
    font-size: 1.5rem;
    font-weight: 700;
    color: #fff;
    text-shadow: 0 0 20px rgba(59, 130, 246, 0.5);
}

/* --- The Wheel Wrapper --- */
.roulette-viewport {
    height: 220px; /* Видимая высота (3 элемента по 70px + отступы) */
    background: #0b1120;
    border-radius: 1.5rem;
    border: 2px solid rgba(59, 130, 246, 0.3);
    position: relative;
    overflow: hidden;
    margin-bottom: 2rem;
    box-shadow: inset 0 0 50px rgba(0,0,0,0.8);
}

/* 3D Shadows for cylinder effect */
.roulette-viewport::before, .roulette-viewport::after {
    content: '';
    position: absolute;
    left: 0; right: 0;
    height: 80px;
    z-index: 20;
    pointer-events: none;
}
.roulette-viewport::before {
    top: 0;
    background: linear-gradient(to bottom, #0b1120 10%, transparent 100%);
}
.roulette-viewport::after {
    bottom: 0;
    background: linear-gradient(to top, #0b1120 10%, transparent 100%);
}

/* Winning Line (Pointer) */
.selector-line {
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 4px;
    background: #ef4444;
    transform: translateY(-50%);
    z-index: 30;
    box-shadow: 0 0 15px #ef4444, 0 0 30px #ef4444;
    border-radius: 2px;
}

.selector-arrow-left, .selector-arrow-right {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    font-size: 1.5rem;
    color: #ef4444;
    z-index: 30;
    text-shadow: 0 0 10px #ef4444;
}
.selector-arrow-left { left: 10px; }
.selector-arrow-right { right: 10px; }

/* --- The Track & Items --- */
.roulette-track {
    width: 100%;
    position: relative;
    will-change: transform;
}

.roulette-card {
    height: 100px; /* Фиксированная высота элемента */
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    margin: 0 1rem; /* Отступы по бокам */
    border-radius: 1rem;
    opacity: 0.4; /* Затемняем неактивные */
    transition: opacity 0.2s, transform 0.2s;
    transform: scale(0.9);
    font-weight: 800;
    font-size: 1.2rem;
    text-transform: uppercase;
    border: 1px solid transparent;
}

/* Central item highlighting */
.roulette-card.active {
    opacity: 1;
    transform: scale(1);
    text-shadow: 0 0 15px currentColor;
    border-color: currentColor;
    background: rgba(255, 255, 255, 0.05);
    z-index: 10;
}

/* Item Colors */
.item-money { color: #4ade80; }   /* Green */
.item-time { color: #60a5fa; }    /* Blue */
.item-container { color: #f472b6; } /* Pink */
.item-nothing { color: #64748b; } /* Gray */
.item-freespin { color: #fbbf24; } /* Gold */

.card-icon {
    font-size: 1.8rem;
    filter: drop-shadow(0 0 5px currentColor);
}

/* --- Controls --- */
.controls-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

.spin-btn {
    background: linear-gradient(145deg, rgba(30, 41, 59, 0.8), rgba(15, 23, 42, 0.9));
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 1rem;
    padding: 1.5rem;
    text-align: center;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.spin-btn:hover:not(:disabled) {
    transform: translateY(-4px);
    border-color: rgba(255, 255, 255, 0.2);
    box-shadow: 0 10px 20px -5px rgba(0, 0, 0, 0.5);
}

.spin-btn:active:not(:disabled) {
    transform: translateY(-2px);
}

.spin-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    filter: grayscale(1);
}

.spin-cost {
    font-size: 0.75rem;
    color: #94a3b8;
    margin-bottom: 0.25rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.spin-label {
    font-size: 1.25rem;
    font-weight: 800;
    color: #fff;
}

/* Free Spin Badge */
.free-spin-badge {
    position: absolute;
    top: 0.5rem;
    right: 0.5rem;
    background: #ec4899;
    color: white;
    font-size: 0.6rem;
    font-weight: bold;
    padding: 0.15rem 0.4rem;
    border-radius: 0.25rem;
    box-shadow: 0 0 10px #ec4899;
    animation: pulse 2s infinite;
}

/* Multi-Spin Button (Purple) */
.spin-multi {
    border-color: rgba(168, 85, 247, 0.3);
}
.spin-multi:hover:not(:disabled) {
    box-shadow: 0 0 20px rgba(168, 85, 247, 0.2);
}
.spin-multi .spin-label { color: #c084fc; }

/* Single Spin Button (Gold) */
.spin-single {
    border-color: rgba(234, 179, 8, 0.3);
}
.spin-single:hover:not(:disabled) {
    box-shadow: 0 0 20px rgba(234, 179, 8, 0.2);
}
.spin-single .spin-label { color: #facc15; }

/* History Link */
.history-link {
    display: block;
    text-align: center;
    margin-top: 2rem;
    color: #64748b;
    font-size: 0.85rem;
    transition: color 0.2s;
}
.history-link:hover { color: #cbd5e1; }

@keyframes shimmer {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(100%); }
}