/* SET YOUR GAME'S COLOR THEME HERE */
:root {
    --primary-color: #DE6C83;
    --primary-hover: #C95A71;
    --hero-gradient-start: rgba(222, 108, 131, 0.1);
    --hero-gradient-end: rgba(201, 90, 113, 0.1);
    --section-bg-start: rgba(222, 108, 131, 0.05);
    --section-bg-end: rgba(201, 90, 113, 0.05);
    --primary-shadow: rgba(222, 108, 131, 0.3);
    --feature-shadow: rgba(222, 108, 131, 0.15);
    --focus-shadow: rgba(222, 108, 131, 0.25);
    --mode-shadow: rgba(222, 108, 131, 0.2);
    --btn-shadow: rgba(222, 108, 131, 0.4);
    --summary-bg-start: rgba(222, 108, 131, 0.1);
    --summary-bg-end: rgba(201, 90, 113, 0.05);
    --accordion-icon-filter: invert(52%) sepia(38%) saturate(742%) hue-rotate(295deg) brightness(92%) contrast(90%);
    --btn-text-color: #ffffff;
}

/* ===== GAME STATS - FLEX OVERRIDE ===== */

.game-stats {
    display: flex !important;
    flex-wrap: nowrap !important;
    gap: 1rem;
}

.game-stats .stat-card {
    flex: 1;
    min-width: 0;
}

/* ===== TIME SELECTION PILLS (Settings) ===== */

.time-pills {
    display: flex;
    gap: 1.5rem;
    justify-content: center;
    margin: 2rem 0;
}

.time-pill {
    background: rgba(222, 108, 131, 0.05);
    border: 2px solid #e9ecef;
    border-radius: 1rem;
    padding: 2rem;
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: center;
    flex: 1;
    max-width: 200px;
}

.time-pill:hover {
    border-color: var(--primary-color);
    transform: translateY(-3px);
    box-shadow: 0 4px 12px var(--primary-shadow);
}

.time-pill.selected {
    border-color: var(--primary-color);
    background: linear-gradient(135deg, rgba(222, 108, 131, 0.15) 0%, rgba(201, 90, 113, 0.1) 100%);
    box-shadow: 0 4px 12px var(--primary-shadow);
}

.time-pill-icon {
    font-size: 2.5rem;
    margin-bottom: 0.75rem;
}

.time-pill-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: #212529;
    margin-bottom: 0.5rem;
}

.time-pill-description {
    font-size: 0.95rem;
    color: #6c757d;
}

/* ===== GAME CARD OVERFLOW ===== */

#gameView .content-card {
    overflow: visible !important;
    min-height: auto !important;
    max-height: none !important;
    padding-bottom: 3rem !important;
}

#gameView .quiz-content {
    overflow: visible !important;
}

/* ===== WORD DISPLAY (Game) ===== */

.speed-word-display {
    font-size: 4rem;
    font-weight: 700;
    color: var(--primary-color);
    text-align: center;
    padding: 2rem 1rem;
    margin: 1rem 0;
    animation: fadeIn 0.5s;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    line-height: 1.3;
    word-break: break-word;
}

/* ===== AUDIO PLAYER ===== */

.audio-player-section {
    text-align: center;
    margin-bottom: 2rem;
}

.audio-label {
    font-size: 1rem;
    font-weight: 600;
    color: #495057;
    margin-bottom: 0.75rem;
}

.audio-player-wrapper {
    max-width: 300px;
    margin: 0 auto;
}

.audio-player-wrapper audio {
    width: 100%;
}

/* Plyr customization */
.plyr {
    border-radius: 0.5rem;
    background: white;
    max-width: 100% !important;
    margin: 0 auto;
}

.audio-player-wrapper .plyr {
    width: 100%;
}

.plyr--audio .plyr__controls {
    background: rgba(222, 108, 131, 0.15);
    padding: 1rem;
    border-radius: 0.5rem;
}

.plyr__control--overlaid {
    display: none !important;
}

.plyr__controls .plyr__volume,
.plyr__controls [data-plyr="mute"],
.plyr__controls .plyr__time,
.plyr__controls .plyr__menu,
.plyr__controls [data-plyr="settings"],
.plyr__controls [data-plyr="fullscreen"],
.plyr__controls [data-plyr="download"] {
    display: none !important;
}

.plyr__control {
    color: var(--primary-color);
}

.plyr__control:hover {
    background: rgba(222, 108, 131, 0.2);
}

.plyr__control svg {
    fill: var(--primary-color);
}

/* ===== INPUT SECTION ===== */

.speed-input-container {
    max-width: 500px;
    margin: 0 auto 1.5rem;
}

.speed-input {
    width: 100%;
    padding: 1rem 1.5rem;
    font-size: 1.8rem;
    border: 3px solid var(--primary-color);
    border-radius: 1rem;
    text-align: center;
    transition: all 0.3s ease;
    text-transform: uppercase;
    font-weight: 600;
}

.speed-input:focus {
    outline: none;
    box-shadow: 0 0 0 4px var(--focus-shadow);
}

.speed-input:disabled {
    background: #f8f9fa;
    opacity: 0.7;
}

/* ===== SUBMIT BUTTON OVERRIDE ===== */

.btn-submit {
    background: var(--primary-color);
    color: white;
    border: 2px solid var(--primary-hover);
    padding: 1rem 3rem;
    border-radius: 1rem;
    font-size: 1.3rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px var(--primary-shadow);
}

.btn-submit:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px var(--primary-shadow);
    background: var(--primary-hover);
}

.btn-submit:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

/* ===== TIMER WARNING STATE ===== */

.stat-card.timer-critical {
    background: linear-gradient(135deg, rgba(220, 53, 69, 0.12) 0%, rgba(253, 126, 20, 0.12) 100%);
    border-color: rgba(220, 53, 69, 0.4);
    animation: timerPulse 1s ease infinite;
}

.stat-card.timer-critical .stat-value {
    background: linear-gradient(135deg, #dc3545 0%, #fd7e14 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

@keyframes timerPulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.03); }
}

/* ===== FLASH ANIMATIONS ===== */

@keyframes flash-correct {
    0%, 100% {
        background-color: transparent;
        border-color: transparent;
    }
    50% {
        background-color: rgba(76, 175, 80, 0.2);
        border: 3px solid #4caf50;
    }
}

@keyframes flash-wrong {
    0%, 100% {
        background-color: transparent;
        border-color: transparent;
    }
    50% {
        background-color: rgba(244, 67, 54, 0.2);
        border: 3px solid #f44336;
    }
}

.content-card.flash-correct {
    animation: flash-correct 0.6s ease;
}

.content-card.flash-wrong {
    animation: flash-wrong 0.6s ease;
}

.flash-correct {
    animation: flashCorrect 800ms ease;
}

.flash-wrong {
    animation: flashWrong 800ms ease;
}

@keyframes flashCorrect {
    0% { background: rgba(76,175,80,0); }
    50% { background: rgba(76,175,80,0.5); }
    100% { background: rgba(76,175,80,0); }
}

@keyframes flashWrong {
    0% { background: rgba(244,67,54,0); }
    50% { background: rgba(244,67,54,0.5); }
    100% { background: rgba(244,67,54,0); }
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ===== STEPPER - CLICKABLE / LOCKED ===== */

.step.clickable {
    cursor: pointer;
    transition: all 0.3s ease;
}

.step.clickable:hover {
    transform: scale(1.05);
}

.step.clickable:hover .step-circle {
    background: var(--primary-color);
    border-color: var(--primary-color);
    color: white;
}

.step.locked {
    cursor: not-allowed;
    opacity: 0.5;
}

.step.locked:hover {
    transform: none;
}

/* ===== REVIEW - WORD ACCURACY CARDS ===== */

.review-word-card {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0;
}

.review-word-name {
    font-size: 1.1rem;
    font-weight: 700;
    color: #212529;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    flex-shrink: 0;
}

.review-word-info {
    flex: 1;
    min-width: 0;
}

.review-word-stats {
    font-size: 0.85rem;
    color: #6c757d;
    margin-bottom: 0.5rem;
    font-weight: 500;
}

.review-accuracy-bar {
    height: 8px;
    background: #e9ecef;
    border-radius: 4px;
    overflow: hidden;
}

.review-accuracy-fill {
    height: 100%;
    border-radius: 4px;
    transition: width 0.5s ease;
}

.review-accuracy-fill.accuracy-perfect {
    background: linear-gradient(90deg, #28a745, #20c997);
}

.review-accuracy-fill.accuracy-good {
    background: linear-gradient(90deg, #ffc107, #fd7e14);
}

.review-accuracy-fill.accuracy-poor {
    background: linear-gradient(90deg, #dc3545, #fd7e14);
}

.review-accuracy-pct {
    font-size: 1.25rem;
    font-weight: 700;
    flex-shrink: 0;
    min-width: 50px;
    text-align: right;
}

.review-accuracy-pct.accuracy-perfect {
    color: #28a745;
}

.review-accuracy-pct.accuracy-good {
    color: #fd7e14;
}

.review-accuracy-pct.accuracy-poor {
    color: #dc3545;
}

/* ===== RESPONSIVE - TABLET ===== */

@media (max-width: 768px) {
    .time-pills {
        flex-direction: column;
    }

    .time-pill {
        max-width: 100%;
    }

    .speed-word-display {
        font-size: 3rem;
        padding: 1.5rem 0.5rem;
    }

    .speed-input {
        font-size: 1.5rem;
    }
}

/* ===== RESPONSIVE - MOBILE ===== */

@media (max-width: 576px) {
    .speed-word-display {
        font-size: 2.5rem;
        letter-spacing: 0.1em;
    }

    .speed-input {
        font-size: 1.3rem;
        padding: 0.75rem 1rem;
    }

    .btn-submit {
        font-size: 1.1rem;
        padding: 0.75rem 2rem;
    }
}