/* ═══════════════════════════════════════════════════════════════
   ROCEN HOMESTEADY — GAMES-BASE.CSS
   Shared styles for all game pages
   ═══════════════════════════════════════════════════════════════

   TABLE OF CONTENTS
   ────────────────
   1.  Games Listing Page
   2.  Shared Game Layout
   3.  Tab Navigation
   4.  Season Display
   5.  Game Header & How-to-Play
   6.  Stats & Progress
   7.  Question System
   8.  Answer Buttons
   9.  Feedback & Banners
   10. Game Over
   11. Plant Cards
   12. Comparison Cards
   13. Quiz Settings
   14. Lives & Level Progress
   15. Achievements
   16. Buttons
   17. Toasts & Loading
   18. Safety Reminder
   19. Power-ups
   20. Shared Animations
   21. Responsive
   ═══════════════════════════════════════════════════════════════ */


/* ═══════════════════════════════════════════════════════════════
   1. GAMES LISTING PAGE
   ═══════════════════════════════════════════════════════════════ */

.games-page {
    max-width: 960px;
    margin: 0 auto;
    padding: 2rem 1rem 3rem;
}

.games-hero {
    text-align: center;
    margin-bottom: 2.5rem;
}

.page-title {
    font-family: 'Crimson Text', Georgia, serif;
    font-size: 2.2rem;
    color: var(--cream);
    margin-bottom: 0.4rem;
}

.page-subtitle {
    color: var(--cream-dim);
    font-size: 1rem;
    line-height: 1.6;
    max-width: 520px;
    margin: 0 auto;
}

/* ── Card Themes ── */
.game-card-item[data-theme="forest"] {
    --accent: #4CAF50;
    --accent-soft: rgba(76,175,80,0.12);
    --accent-border: rgba(76,175,80,0.35);
    --accent-glow: rgba(76,175,80,0.25);
}

.game-card-item[data-theme="danger"] {
    --accent: #EF5350;
    --accent-soft: rgba(239,83,80,0.12);
    --accent-border: rgba(239,83,80,0.35);
    --accent-glow: rgba(239,83,80,0.25);
}

.game-card-item[data-theme="gold"] {
    --accent: #FFD600;
    --accent-soft: rgba(255,214,0,0.12);
    --accent-border: rgba(255,214,0,0.35);
    --accent-glow: rgba(255,214,0,0.25);
}

.game-card-item[data-theme="amber"] {
    --accent: #FFA726;
    --accent-soft: rgba(255,167,38,0.12);
    --accent-border: rgba(255,167,38,0.35);
    --accent-glow: rgba(255,167,38,0.25);
}

.game-card-item[data-theme="flame"] {
    --accent: #FF7043;
    --accent-soft: rgba(255,112,67,0.12);
    --accent-border: rgba(255,112,67,0.35);
    --accent-glow: rgba(255,112,67,0.25);
}

.game-card-item[data-theme="honey"] {
    --accent: #FFB300;
    --accent-soft: rgba(255,179,0,0.12);
    --accent-border: rgba(255,179,0,0.35);
    --accent-glow: rgba(255,179,0,0.25);
}

.game-card-item[data-theme="crop"] {
    --accent: #66BB6A;
    --accent-soft: rgba(102,187,106,0.12);
    --accent-border: rgba(102,187,106,0.35);
    --accent-glow: rgba(102,187,106,0.25);
}

.game-card-item[data-theme="teal"] {
    --accent: #26A69A;
    --accent-soft: rgba(38,166,154,0.12);
    --accent-border: rgba(38,166,154,0.35);
    --accent-glow: rgba(38,166,154,0.25);
}

/* ── Games Grid ── */
.all-games-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
    gap: 1.2rem;
    margin: 0 0 2rem;
}

.game-card-link {
    text-decoration: none;
    color: inherit;
    display: block;
}

.game-card-link:hover .game-card-item {
    transform: translateY(-5px);
    border-color: var(--accent);
    box-shadow: 0 12px 35px rgba(0,0,0,0.35), 0 0 25px var(--accent-glow);
}

.game-card-link:hover .gci-icon-ring {
    transform: scale(1.08);
    box-shadow: 0 0 20px var(--accent-glow);
    border-color: var(--accent);
}

.game-card-link:hover .gci-emoji {
    transform: scale(1.15);
}

.game-card-link:focus-visible {
    outline: none;
}

.game-card-link:focus-visible .game-card-item {
    outline: 2px solid var(--green-light);
    outline-offset: 3px;
    transform: translateY(-3px);
}

.game-card-item {
    background: var(--bg-card);
    border: 2px solid #3d5a3d;
    border-top: 3px solid var(--accent);
    border-radius: 14px;
    padding: 1.5rem 1.2rem 1.2rem;
    text-align: center;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    animation: gciEnter 0.5s ease backwards;
}

.game-card-link:nth-child(1) .game-card-item { animation-delay: 0.05s; }
.game-card-link:nth-child(2) .game-card-item { animation-delay: 0.1s; }
.game-card-link:nth-child(3) .game-card-item { animation-delay: 0.15s; }
.game-card-link:nth-child(4) .game-card-item { animation-delay: 0.2s; }
.game-card-link:nth-child(5) .game-card-item { animation-delay: 0.25s; }
.game-card-link:nth-child(6) .game-card-item { animation-delay: 0.3s; }
.game-card-link:nth-child(7) .game-card-item { animation-delay: 0.35s; }
.game-card-link:nth-child(8) .game-card-item { animation-delay: 0.4s; }

.game-card-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 90px;
    background: linear-gradient(180deg, var(--accent-soft) 0%, transparent 100%);
    pointer-events: none;
    border-radius: 12px 12px 0 0;
}

.game-card-item::after {
    content: '→';
    position: absolute;
    bottom: 14px;
    right: 14px;
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--accent);
    opacity: 0;
    transition: opacity 0.3s ease, transform 0.3s ease;
    transform: translateX(-6px);
}

.game-card-link:hover .game-card-item::after {
    opacity: 0.6;
    transform: translateX(0);
}

.gci-icon-ring {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: var(--accent-soft);
    border: 2px solid var(--accent-border);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 0.9rem;
    transition: all 0.3s ease;
    position: relative;
    z-index: 1;
    color: var(--accent);
}

.gci-icon-ring svg {
    width: 28px;
    height: 28px;
    stroke: currentColor;
    stroke-width: 1.5;
    fill: none;
    transition: transform 0.3s ease;
}

.game-card-link:hover .gci-icon-ring svg {
    transform: scale(1.1);
}

.gci-name {
    font-family: 'Crimson Text', Georgia, serif;
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--cream);
    margin: 0 0 0.5rem;
    position: relative;
    z-index: 1;
}

.gci-badge {
    display: inline-block;
    padding: 0.15rem 0.65rem;
    border-radius: 12px;
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 0.6rem;
    position: relative;
    z-index: 1;
}

.gci-type-adventure {
    background: rgba(76,175,80,0.15);
    color: #66BB6A;
    border: 1px solid rgba(76,175,80,0.3);
}

.gci-type-challenge {
    background: rgba(239,83,80,0.15);
    color: #EF5350;
    border: 1px solid rgba(239,83,80,0.3);
}

.gci-type-quiz {
    background: rgba(255,214,0,0.15);
    color: #FFD600;
    border: 1px solid rgba(255,214,0,0.3);
}

.gci-type-simulation {
    background: rgba(255,167,38,0.15);
    color: #FFA726;
    border: 1px solid rgba(255,167,38,0.3);
}

.gci-type-cooking {
    background: rgba(255,112,67,0.15);
    color: #FF7043;
    border: 1px solid rgba(255,112,67,0.3);
}

.gci-type-strategy {
    background: rgba(102,187,106,0.15);
    color: #81C784;
    border: 1px solid rgba(102,187,106,0.3);
}

.gci-desc {
    color: var(--cream-dim);
    font-size: 0.85rem;
    line-height: 1.5;
    margin-bottom: 0.8rem;
    position: relative;
    z-index: 1;
}

.gci-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 0.6rem;
    border-top: 1px solid rgba(61,90,61,0.4);
    position: relative;
    z-index: 1;
}

.gci-age {
    color: var(--cream-dim);
    font-size: 0.75rem;
    font-weight: 600;
}

.gci-curriculum {
    color: rgba(245,240,225,0.35);
    font-size: 0.65rem;
    letter-spacing: 0.3px;
}

/* ── Card entrance animation ── */
@keyframes gciEnter {
    from { opacity: 0; transform: translateY(18px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* ── More Games Section (legacy cards inside game pages) ── */
.more-games-section {
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 1px solid #3d5a3d;
}

.section-heading {
    font-family: 'Crimson Text', Georgia, serif;
    font-size: 1.5rem;
    color: var(--cream);
    text-align: center;
    margin-bottom: 1rem;
}

.more-games-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 0.8rem;
}

.more-game-card {
    background: var(--bg-card);
    border: 1px solid #3d5a3d;
    border-radius: 12px;
    padding: 1.2rem 1rem;
    text-align: center;
    text-decoration: none;
    transition: all 0.2s;
    display: block;
}

.more-game-card:hover {
    border-color: var(--green-light);
    transform: translateY(-2px);
    background: #1a2e1a;
}

.more-game-card.coming-soon {
    opacity: 0.5;
    cursor: default;
}

.more-game-card.coming-soon:hover {
    transform: none;
    border-color: #3d5a3d;
    background: var(--bg-card);
}

.mg-icon {
    font-size: 2rem;
    margin-bottom: 0.4rem;
}

.mg-name {
    color: var(--cream);
    font-weight: 700;
    font-size: 0.95rem;
    font-family: 'Crimson Text', Georgia, serif;
}

.mg-desc {
    color: var(--cream-dim);
    font-size: 0.75rem;
    margin-top: 0.3rem;
    line-height: 1.3;
}


/* ═══════════════════════════════════════════════════════════════
   2. SHARED GAME LAYOUT
   ═══════════════════════════════════════════════════════════════ */

.game-container { display: none; }
.game-container.active { display: block; }

.game-header h2 {
    font-family: 'Crimson Text', Georgia, serif;
    font-size: 1.8rem;
    color: var(--cream);
    margin-bottom: 0.2rem;
}

.game-caption {
    color: var(--cream-dim);
    font-size: 0.9rem;
    margin-bottom: 1rem;
}

.game-divider {
    border: none;
    border-top: 1px solid #3d5a3d;
    margin: 1.5rem 0;
}


/* ═══════════════════════════════════════════════════════════════
   3. TAB NAVIGATION
   ═══════════════════════════════════════════════════════════════ */

.game-tabs {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
    justify-content: center;
}

.tab-btn {
    background: var(--bg-card);
    color: var(--cream-dim);
    border: 2px solid #3d5a3d;
    border-radius: 10px;
    padding: 0.7rem 1.2rem;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    font-family: 'Inter', sans-serif;
}

.tab-btn:hover {
    border-color: var(--green-light);
    color: var(--cream);
    background: #1a2e1a;
}

.tab-btn.active {
    background: linear-gradient(135deg, #0a2a0a, #1a3d1a);
    border-color: var(--green-leaf);
    color: var(--green-light);
    box-shadow: 0 0 12px rgba(76,175,80,0.2);
}


/* ═══════════════════════════════════════════════════════════════
   4. SEASON DISPLAY
   ═══════════════════════════════════════════════════════════════ */

.season-display {
    background: linear-gradient(135deg, #1a2e1a, #2a4a2a);
    border: 2px solid var(--green-light);
    border-radius: 10px;
    padding: 0.6rem 1rem;
    text-align: center;
    margin-bottom: 0.8rem;
    color: var(--cream);
    font-weight: 700;
    font-size: 1.1rem;
}

.season-buttons {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.season-btn {
    background: var(--bg-card);
    color: var(--cream-dim);
    border: 2px solid #3d5a3d;
    border-radius: 8px;
    padding: 0.6rem;
    cursor: pointer;
    font-size: 0.95rem;
    font-weight: 600;
    transition: all 0.2s;
    font-family: 'Inter', sans-serif;
}

.season-btn:hover {
    border-color: var(--green-light);
    color: var(--cream);
}

.season-btn.active {
    background: linear-gradient(135deg, #0a2a0a, #1a3d1a);
    border-color: var(--green-leaf);
    color: var(--green-light);
}


/* ═══════════════════════════════════════════════════════════════
   5. GAME HEADER & HOW-TO-PLAY
   ═══════════════════════════════════════════════════════════════ */

.how-to-play {
    background: var(--bg-card);
    border: 1px solid #3d5a3d;
    border-radius: 10px;
    margin-bottom: 1rem;
    overflow: hidden;
}

.how-to-play summary {
    padding: 0.8rem 1rem;
    cursor: pointer;
    font-weight: 600;
    color: var(--green-light);
    font-size: 0.95rem;
}

.how-to-play-content {
    padding: 0 1rem 1rem;
    color: var(--cream-dim);
    font-size: 0.9rem;
    line-height: 1.6;
}

.how-to-play-content ol,
.how-to-play-content ul {
    padding-left: 1.5rem;
    margin: 0.5rem 0;
}

.how-to-play-content li { margin-bottom: 0.3rem; }

.htp-section {
    background: var(--bg-card);
    border: 1px solid #3d5a3d;
    border-radius: 10px;
    margin-bottom: 1rem;
    overflow: hidden;
}

.htp-section summary {
    padding: 0.8rem 1rem;
    cursor: pointer;
    font-weight: 600;
    color: var(--green-light);
    font-size: 0.95rem;
}

.htp-content {
    padding: 0 1rem 1rem;
    color: var(--cream-dim);
    font-size: 0.9rem;
    line-height: 1.6;
}

.htp-content ol,
.htp-content ul {
    padding-left: 1.5rem;
    margin: 0.5rem 0;
}

.htp-content li { margin-bottom: 0.3rem; }


/* ═══════════════════════════════════════════════════════════════
   6. STATS & PROGRESS
   ═══════════════════════════════════════════════════════════════ */

.stats-row {
    display: flex;
    gap: 0.8rem;
    margin-bottom: 1rem;
    flex-wrap: wrap;
}

.stat-box {
    border-radius: 10px;
    padding: 0.6rem 1rem;
    text-align: center;
    flex: 1;
    min-width: 80px;
}

.stat-box .stat-label {
    font-size: 0.75rem;
    font-weight: 600;
    margin-bottom: 0.2rem;
}

.stat-box .stat-value {
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--cream);
}

.stat-box.score {
    background: linear-gradient(135deg, #1a1a00, #2a2a00);
    border: 2px solid var(--amber-dark);
}

.stat-box.score .stat-label { color: var(--amber); }

.stat-box.lives {
    background: var(--danger-bg);
    border: 2px solid var(--danger);
}

.stat-box.lives .stat-label { color: var(--danger); }

.stat-box.streak {
    background: linear-gradient(135deg, #1a0a00, #2a1a00);
    border: 2px solid #FF8F00;
}

.stat-box.streak .stat-label { color: #FF8F00; }

.stat-box.herbarium {
    background: var(--bg-card);
    border: 2px solid var(--green-leaf);
}

.stat-box.herbarium .stat-label { color: var(--green-leaf); }

.stat-box.cases {
    background: var(--bg-card);
    border: 2px solid #3d5a3d;
}

.stat-box.cases .stat-label { color: var(--green-leaf); }

.stat-box.question-num {
    background: var(--bg-card);
    border: 2px solid #3d5a3d;
}

.stat-box.question-num .stat-label { color: var(--green-leaf); }

.progress-bar-container { margin-bottom: 1rem; }

.progress-bar-label {
    font-size: 0.85rem;
    color: var(--cream-dim);
    margin-bottom: 0.3rem;
}

.progress-bar {
    background: #1a2e1a;
    border-radius: 10px;
    height: 20px;
    overflow: hidden;
    border: 1px solid #3d5a3d;
}

.progress-bar-fill {
    background: linear-gradient(90deg, var(--green-leaf), var(--green-light));
    height: 100%;
    border-radius: 10px;
    transition: width 0.5s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.7rem;
    font-weight: 600;
    color: #0a2a0a;
    min-width: 2rem;
}

.level-progress {
    background: var(--bg-card);
    border: 1px solid #3d5a3d;
    border-radius: 10px;
    padding: 0.8rem 1rem;
    margin-bottom: 0.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.level-progress .level-name {
    color: var(--amber);
    font-family: 'Crimson Text', Georgia, serif;
    font-size: 1.1rem;
    font-weight: 700;
}

.level-progress .level-count {
    color: var(--cream-dim);
    font-size: 0.85rem;
}

.case-count-label {
    color: var(--cream-dim);
    font-size: 0.85rem;
    text-align: center;
    margin-top: 0.5rem;
}


/* ═══════════════════════════════════════════════════════════════
   7. QUESTION SYSTEM
   ═══════════════════════════════════════════════════════════════ */

.question-layout {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 1rem;
    margin-bottom: 1rem;
}

.question-text {
    font-family: 'Crimson Text', Georgia, serif;
    font-size: 1.3rem;
    color: var(--cream);
    margin-bottom: 1rem;
}

.question-text strong { color: var(--green-light); }

.q-type-header {
    background: var(--bg-card);
    border-left: 4px solid #4CAF50;
    border-radius: 0 10px 10px 0;
    padding: 0.8rem 1rem;
    margin-bottom: 0.8rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.q-type-header .q-type-left {
    display: flex;
    align-items: center;
    gap: 0.3rem;
}

.q-type-header .q-type-icon { font-size: 1.2rem; }
.q-type-header .q-type-name { font-weight: 700; font-size: 1.1rem; }

.q-type-header .q-points {
    padding: 0.15rem 0.6rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    border: 1px solid;
}

.clue-box {
    background: linear-gradient(135deg, #1a1a0a, #2a2a10);
    border: 1px solid var(--green-light);
    border-radius: 10px;
    padding: 0.8rem;
    margin-bottom: 0.8rem;
}

.clue-box .clue-label {
    color: var(--green-light);
    font-weight: 600;
    font-size: 0.85rem;
    margin-bottom: 0.3rem;
}

.clue-box .clue-text {
    color: var(--cream);
    font-size: 0.95rem;
}

.plant-fact-box {
    background: var(--bg-card);
    border: 1px solid #3d5a3d;
    border-radius: 10px;
    padding: 0.8rem 1rem;
    margin-top: 0.8rem;
    color: var(--cream);
    font-size: 0.9rem;
    line-height: 1.5;
}

.plant-fact-box strong { color: var(--green-light); }


/* ═══════════════════════════════════════════════════════════════
   8. ANSWER BUTTONS
   ═══════════════════════════════════════════════════════════════ */

.answer-grid { display: grid; gap: 0.6rem; }
.answer-grid.cols-2 { grid-template-columns: 1fr 1fr; }

.answer-btn {
    background: var(--bg-card);
    color: var(--cream);
    border: 1px solid #555;
    border-radius: 8px;
    padding: 0.8rem 1rem;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.15s;
    font-family: 'Inter', sans-serif;
    text-align: center;
    width: 100%;
}

.answer-btn:hover {
    border-color: var(--green-light);
    background: #1a2e1a;
    transform: scale(1.02);
}

.answer-btn:active { transform: scale(0.98); }

.answer-btn.correct {
    background: linear-gradient(135deg, #0a2a0a, #1a3d1a);
    border-color: var(--green-leaf);
    color: var(--green-light);
}

.answer-btn.wrong {
    background: linear-gradient(135deg, #2a1010, #3d1515);
    border-color: var(--danger);
    color: #ff8a80;
}

.answer-btn.eliminated {
    opacity: 0.2;
    pointer-events: none;
    text-decoration: line-through;
    border-color: #333 !important;
    color: #555 !important;
    background: #111 !important;
}


/* ═══════════════════════════════════════════════════════════════
   9. FEEDBACK & BANNERS
   ═══════════════════════════════════════════════════════════════ */

/* ── Correct ── */
.feedback-correct {
    background: linear-gradient(135deg, #0a2a0a, #1a3d1a);
    border: 2px solid var(--green-leaf);
    border-radius: 12px;
    padding: 1.5rem;
    text-align: center;
    margin: 1rem 0;
    animation: fadeIn 0.3s ease;
}

.feedback-correct .feedback-icon { font-size: 2rem; }

.feedback-correct .feedback-text {
    color: var(--green-leaf);
    font-family: 'Crimson Text', Georgia, serif;
    font-size: 1.3rem;
    font-weight: 700;
}

.feedback-correct .feedback-detail {
    color: var(--cream-dim);
    font-size: 0.9rem;
    margin-top: 0.3rem;
}

/* ── Wrong ── */
.feedback-wrong {
    background: linear-gradient(135deg, #1a0000, #2a0a0a);
    border: 2px solid var(--danger);
    border-radius: 12px;
    padding: 1.5rem;
    text-align: center;
    margin: 1rem 0;
    animation: fadeIn 0.3s ease;
}

.feedback-wrong .feedback-icon { font-size: 2rem; }

.feedback-wrong .feedback-text {
    color: var(--danger);
    font-family: 'Crimson Text', Georgia, serif;
    font-size: 1.3rem;
    font-weight: 700;
}

.feedback-wrong .feedback-detail {
    color: var(--cream-dim);
    font-size: 0.9rem;
    margin-top: 0.3rem;
}

/* ── Bonus Round ── */
.bonus-banner {
    background: linear-gradient(135deg, #2a1a00, #3d2a00);
    border: 2px solid #FFD700;
    border-radius: 12px;
    padding: 1.5rem;
    text-align: center;
    margin: 1rem 0;
    animation: pulse 1.5s infinite;
}

.bonus-banner .bonus-icon { font-size: 2rem; }

.bonus-banner .bonus-title {
    color: #FFD700;
    font-family: 'Crimson Text', Georgia, serif;
    font-size: 1.5rem;
    font-weight: 700;
}

.bonus-banner .bonus-desc {
    color: var(--cream);
    font-size: 0.95rem;
    margin-top: 0.3rem;
}

/* ── Challenge ── */
.challenge-banner {
    background: linear-gradient(135deg, #2a0a0a, #3d1515);
    border: 2px solid var(--danger);
    border-radius: 12px;
    padding: 1rem;
    text-align: center;
    margin-bottom: 1rem;
}

.challenge-banner .challenge-icon { font-size: 1.5rem; }

.challenge-banner .challenge-title {
    color: var(--danger);
    font-family: 'Crimson Text', Georgia, serif;
    font-size: 1.2rem;
    font-weight: 700;
}

.challenge-banner .challenge-desc {
    color: var(--cream-dim);
    font-size: 0.85rem;
    margin-top: 0.3rem;
}

/* ── Level-Up ── */
.level-up-banner {
    background: linear-gradient(135deg, #2a1a00, #3d2a00);
    border: 2px solid var(--amber);
    border-radius: 12px;
    padding: 1.5rem;
    text-align: center;
    margin: 1rem 0;
    animation: pulse 1.5s infinite;
}

.level-up-banner .lu-icon { font-size: 2rem; }

.level-up-banner .lu-title {
    color: var(--amber);
    font-family: 'Crimson Text', Georgia, serif;
    font-size: 1.5rem;
    font-weight: 700;
}

.level-up-banner .lu-text {
    color: var(--cream);
    font-size: 1rem;
    margin-top: 0.3rem;
}

.level-up-banner .lu-sub {
    color: var(--cream-dim);
    font-size: 0.85rem;
    margin-top: 0.3rem;
}


/* ═══════════════════════════════════════════════════════════════
   10. GAME OVER
   ═══════════════════════════════════════════════════════════════ */

.game-over {
    background: linear-gradient(135deg, #1a0000, #2a0a0a);
    border: 2px solid var(--danger);
    border-radius: 12px;
    padding: 2rem;
    text-align: center;
    margin: 1rem 0;
}

.game-over .go-icon { font-size: 3rem; }

.game-over .go-title {
    color: var(--danger);
    font-family: 'Crimson Text', Georgia, serif;
    font-size: 1.8rem;
    font-weight: 700;
}

.game-over .go-text {
    color: var(--cream-dim);
    font-size: 1rem;
    margin-top: 0.5rem;
}

.game-over .go-score {
    color: var(--cream);
    font-size: 0.9rem;
    margin-top: 0.5rem;
}

.game-over.success {
    background: linear-gradient(135deg, #0a2a0a, #1a3d1a);
    border-color: var(--green-leaf);
}

.game-over.success .go-title { color: var(--green-leaf); }


/* ═══════════════════════════════════════════════════════════════
   11. PLANT CARDS
   ═══════════════════════════════════════════════════════════════ */

.plant-card {
    background: linear-gradient(145deg, var(--bg-card), var(--bg-deep));
    border: 2px solid var(--green-leaf);
    border-radius: 12px;
    padding: 1.2rem;
    text-align: center;
}

.plant-card.poisonous { border-color: var(--danger); }

.plant-card .plant-icon {
    font-size: 3rem;
    margin-bottom: 0.3rem;
}

.plant-card .plant-name {
    color: var(--cream);
    font-size: 1.2rem;
    font-weight: 700;
    font-family: 'Crimson Text', Georgia, serif;
}

.plant-card .plant-latin {
    color: var(--cream-dim);
    font-size: 0.9rem;
    font-style: italic;
    margin: 0.3rem 0;
}

.plant-card .plant-keys {
    font-size: 0.85rem;
    text-align: left;
    color: var(--cream-dim);
    border-top: 1px solid #3d5a3d;
    padding-top: 0.5rem;
    margin-top: 0.5rem;
}

.plant-card .plant-keys b { color: var(--cream); }

.plants-seen-list {
    color: var(--cream-dim);
    font-size: 0.9rem;
    line-height: 1.8;
}


/* ═══════════════════════════════════════════════════════════════
   12. COMPARISON CARDS (shared)
   ═══════════════════════════════════════════════════════════════ */

.comparison-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    margin: 1rem 0;
}

.safe-card,
.danger-card {
    border-radius: 12px;
    padding: 1.2rem;
    text-align: center;
}

.safe-card {
    background: linear-gradient(135deg, #0a2a0a, #1a3d1a);
    border: 2px solid var(--green-leaf);
}

.danger-card {
    background: linear-gradient(135deg, #2a1010, #3d1515);
    border: 2px solid var(--danger);
}

.safe-card .card-icon { font-size: 2rem; }
.safe-card .card-name { color: var(--green-leaf); font-weight: 700; font-size: 1.1rem; margin: 0.3rem 0; }
.safe-card .card-status { color: var(--green-light); font-size: 0.8rem; font-weight: 600; margin-bottom: 0.5rem; }

.danger-card .card-icon { font-size: 2rem; }
.danger-card .card-name { color: var(--danger); font-weight: 700; font-size: 1.1rem; margin: 0.3rem 0; }
.danger-card .card-status { color: #ff8a80; font-size: 0.8rem; font-weight: 600; margin-bottom: 0.5rem; }


/* ═══════════════════════════════════════════════════════════════
   13. QUIZ SETTINGS
   ═══════════════════════════════════════════════════════════════ */

.quiz-settings {
    background: var(--bg-card);
    border: 1px solid #3d5a3d;
    border-radius: 10px;
    padding: 1rem;
    margin-bottom: 1rem;
    display: grid;
    grid-template-columns: 1fr 1fr 1fr 1fr;
    gap: 1rem;
    align-items: end;
}

.quiz-settings-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    margin-bottom: 1rem;
}

.setting-group label {
    display: block;
    font-size: 0.85rem;
    color: var(--cream-dim);
    font-weight: 600;
    margin-bottom: 0.3rem;
}

.setting-group select,
.setting-group input[type="number"] {
    width: 100%;
    background: var(--bg-deep);
    color: var(--cream);
    border: 1px solid #3d5a3d;
    border-radius: 8px;
    padding: 0.5rem;
    font-size: 0.9rem;
}

.setting-group .radio-group {
    display: flex;
    gap: 0.8rem;
}

.setting-group .radio-group label {
    display: flex;
    align-items: center;
    gap: 0.3rem;
    font-size: 0.9rem;
    color: var(--cream);
    cursor: pointer;
}

.checkbox-label {
    display: flex !important;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
    color: var(--cream);
    font-size: 0.9rem;
}

.settings-checkbox {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
    color: var(--cream);
    font-size: 0.9rem;
    margin-top: 0.5rem;
}


/* ═══════════════════════════════════════════════════════════════
   14. LIVES & LEVEL PROGRESS
   ═══════════════════════════════════════════════════════════════ */

.lives-display {
    background: var(--danger-bg);
    border: 2px solid var(--danger);
    border-radius: 10px;
    padding: 0.5rem 1rem;
    text-align: center;
    margin-bottom: 1rem;
}

.lives-display .lives-label { color: var(--danger); font-weight: 600; }
.lives-display .lives-hearts { color: var(--cream); font-size: 1.2rem; font-weight: 700; }


/* ═══════════════════════════════════════════════════════════════
   15. ACHIEVEMENTS
   ═══════════════════════════════════════════════════════════════ */

.achievements-section {
    background: var(--bg-card);
    border: 1px solid #3d5a3d;
    border-radius: 10px;
    margin-top: 0.5rem;
    overflow: hidden;
}

.achievements-section summary {
    padding: 0.8rem 1rem;
    cursor: pointer;
    font-weight: 600;
    color: var(--green-light);
    font-size: 0.95rem;
}

.achievements-grid {
    padding: 0 1rem 1rem;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.achievement-card {
    background: var(--bg-card);
    border: 2px solid #444;
    border-radius: 10px;
    padding: 0.8rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.achievement-card.unlocked {
    background: linear-gradient(135deg, #0a2a0a, #1a3d1a);
    border-color: var(--green-leaf);
}

.achievement-card .ach-left {
    display: flex;
    align-items: center;
    gap: 0.3rem;
}

.achievement-card .ach-icon { font-size: 1.2rem; }
.achievement-card .ach-name { font-weight: 700; color: var(--cream-dim); }
.achievement-card.unlocked .ach-name { color: var(--green-leaf); }
.achievement-card .ach-progress { color: var(--cream-dim); font-size: 0.8rem; }
.achievement-card .ach-desc { color: var(--cream-dim); font-size: 0.85rem; margin-top: 0.3rem; }

.learn-more {
    background: var(--bg-card);
    border: 1px solid #3d5a3d;
    border-radius: 10px;
    margin-top: 1rem;
    overflow: hidden;
}

.learn-more summary {
    padding: 0.8rem 1rem;
    cursor: pointer;
    font-weight: 600;
    color: var(--green-light);
    font-size: 0.95rem;
}

.learn-more-content {
    padding: 0 1rem 1rem;
    color: var(--cream-dim);
    font-size: 0.9rem;
    line-height: 1.6;
}


/* ═══════════════════════════════════════════════════════════════
   16. BUTTONS
   ═══════════════════════════════════════════════════════════════ */

.reset-all-container { text-align: center; margin-top: 2rem; }

.btn-primary {
    background: linear-gradient(135deg, var(--green-leaf), var(--green-dark));
    color: var(--cream);
    border: none;
    border-radius: 10px;
    padding: 0.7rem 1.5rem;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    font-family: 'Inter', sans-serif;
    transition: all 0.2s;
}

.btn-primary:hover {
    filter: brightness(1.1);
    transform: scale(1.02);
}

.btn-danger {
    background: linear-gradient(135deg, #c62828, #b71c1c);
    color: var(--cream);
    border: none;
    border-radius: 10px;
    padding: 0.7rem 1.5rem;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    font-family: 'Inter', sans-serif;
    transition: all 0.2s;
}

.btn-danger:hover { filter: brightness(1.1); }

.btn-next-case {
    background: linear-gradient(135deg, var(--amber-dark), var(--amber));
    color: var(--cream);
    border: none;
    border-radius: 10px;
    padding: 0.8rem 1.5rem;
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    font-family: 'Inter', sans-serif;
    width: 100%;
    margin-top: 1rem;
    transition: all 0.2s;
}

.btn-next-case:hover {
    filter: brightness(1.15);
    transform: scale(1.02);
}

.btn-restart {
    background: linear-gradient(135deg, var(--green-leaf), var(--green-dark));
    color: var(--cream);
    border: none;
    border-radius: 10px;
    padding: 0.8rem 1.5rem;
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    font-family: 'Inter', sans-serif;
    width: 100%;
    margin-top: 1rem;
    transition: all 0.2s;
}

.btn-restart:hover { filter: brightness(1.15); }

.btn-share {
    background: var(--bg-card);
    color: var(--cream);
    border: 2px solid #3d5a3d;
    border-radius: 10px;
    padding: 0.8rem 1.5rem;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    font-family: 'Inter', sans-serif;
    transition: all 0.2s;
    flex: 1;
}

.btn-share:hover {
    border-color: var(--green-light);
    background: #1a2e1a;
}

.btn-daily {
    background: linear-gradient(135deg, #2a2a00, #3d3d00);
    color: #FFD600;
    border: 2px solid #FFD600;
    border-radius: 10px;
    padding: 0.7rem 1.5rem;
    font-size: 0.95rem;
    font-weight: 700;
    cursor: pointer;
    font-family: 'Inter', sans-serif;
    transition: all 0.2s;
    width: 100%;
    margin-top: 0.5rem;
}

.btn-daily:hover {
    background: linear-gradient(135deg, #3d3d00, #4a4a00);
    transform: scale(1.02);
}


/* ═══════════════════════════════════════════════════════════════
   17. TOASTS & LOADING
   ═══════════════════════════════════════════════════════════════ */

.toast {
    position: fixed;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    background: linear-gradient(135deg, #0a2a0a, #1a3d1a);
    border: 2px solid var(--green-leaf);
    color: var(--cream);
    padding: 0.8rem 1.5rem;
    border-radius: 12px;
    font-weight: 600;
    font-size: 0.95rem;
    z-index: 9999;
    box-shadow: 0 4px 20px rgba(0,0,0,0.4);
    animation: slideUp 0.3s ease;
}

.toast.hidden { display: none; }

.loading-spinner {
    text-align: center;
    padding: 3rem 1rem;
    color: var(--cream-dim);
    font-size: 1.2rem;
}

.loading-spinner::after {
    content: '';
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid var(--green-leaf);
    border-top-color: transparent;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
    margin-left: 0.5rem;
    vertical-align: middle;
}

.hidden { display: none !important; }


/* ═══════════════════════════════════════════════════════════════
   18. SAFETY REMINDER
   ═══════════════════════════════════════════════════════════════ */

.safety-reminder {
    background: var(--bg-card);
    border: 1px solid #3d5a3d;
    border-radius: 12px;
    padding: 1.5rem;
    margin-top: 2rem;
}

.safety-reminder h2 {
    color: var(--danger);
    font-family: 'Crimson Text', Georgia, serif;
    font-size: 1.3rem;
    margin-bottom: 0.5rem;
}

.safety-reminder ul {
    color: var(--cream-dim);
    font-size: 0.9rem;
    line-height: 1.6;
    padding-left: 1.5rem;
}

.safety-reminder li { margin-bottom: 0.3rem; }


/* ═══════════════════════════════════════════════════════════════
   19. POWER-UPS
   ═══════════════════════════════════════════════════════════════ */

.powerup-row {
    display: flex;
    gap: 0.6rem;
    justify-content: center;
    margin-bottom: 0.8rem;
    flex-wrap: wrap;
}

.powerup-btn {
    background: var(--bg-card);
    border: 2px solid #3d5a3d;
    border-radius: 10px;
    padding: 0.5rem 1rem;
    color: var(--cream);
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    font-family: 'Inter', sans-serif;
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.powerup-btn:hover:not(:disabled) {
    border-color: var(--green-light);
    background: #1a2e1a;
    transform: scale(1.03);
}

.powerup-btn:disabled {
    opacity: 0.35;
    cursor: not-allowed;
    transform: none;
}

.powerup-btn.powerup-fifty { border-color: #FF9800; color: #FFB74D; }
.powerup-btn.powerup-fifty:hover:not(:disabled) { border-color: #FFB74D; background: #2a1a00; }
.powerup-btn.powerup-freeze { border-color: #42A5F5; color: #90CAF9; }
.powerup-btn.powerup-freeze:hover:not(:disabled) { border-color: #90CAF9; background: #0a1a2e; }
.powerup-btn.powerup-skip { border-color: #AB47BC; color: #CE93D8; }
.powerup-btn.powerup-skip:hover:not(:disabled) { border-color: #CE93D8; background: #1a0a2e; }

.powerup-btn .pu-count {
    background: rgba(255,255,255,0.15);
    border-radius: 8px;
    padding: 0.1rem 0.4rem;
    font-size: 0.75rem;
    min-width: 1.2rem;
    text-align: center;
}

.freeze-active { animation: freeze-pulse 0.8s ease infinite; }

@keyframes freeze-pulse {
    0%, 100% { box-shadow: 0 0 8px rgba(66,165,245,0.3); }
    50% { box-shadow: 0 0 20px rgba(66,165,245,0.7); }
}


/* ═══════════════════════════════════════════════════════════════
   20. SHARED ANIMATIONS
   ═══════════════════════════════════════════════════════════════ */

@keyframes fadeIn {
    from { opacity: 0; }
    to   { opacity: 1; }
}

@keyframes pulse {
    0%, 100% { box-shadow: 0 0 5px rgba(255,215,0,0.3); }
    50%      { box-shadow: 0 0 20px rgba(255,215,0,0.6); }
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

@keyframes slideUp {
    from { opacity: 0; transform: translateX(-50%) translateY(20px); }
    to   { opacity: 1; transform: translateX(-50%) translateY(0); }
}


/* ═══════════════════════════════════════════════════════════════
   21. RESPONSIVE (shared rules)
   ═══════════════════════════════════════════════════════════════ */

@media (max-width: 600px) {
    /* ── Listing page ── */
    .games-page { padding: 1rem 0.5rem 2rem; }
    .page-title { font-size: 1.6rem; }
    .all-games-grid { grid-template-columns: 1fr 1fr; gap: 0.8rem; }
    .game-card-item { padding: 1.2rem 0.8rem 1rem; }
    .gci-icon-ring { width: 52px; height: 52px; }
    .gci-icon-ring svg { width: 22px; height: 22px; }
    .gci-name { font-size: 1.1rem; }
    .gci-desc { font-size: 0.78rem; }
    .gci-footer { flex-direction: column; gap: 0.2rem; align-items: flex-start; }

    /* ── Shared game layout ── */
    .game-header h2 { font-size: 1.4rem; }
    .season-buttons { grid-template-columns: 1fr 1fr; }
    .stats-row { gap: 0.5rem; }
    .stat-box { padding: 0.5rem 0.6rem; min-width: 70px; }
    .stat-box .stat-value { font-size: 1.1rem; }
    .quiz-settings { grid-template-columns: 1fr; }
    .quiz-settings-grid { grid-template-columns: 1fr; }
    .comparison-grid { grid-template-columns: 1fr; }
    .answer-grid.cols-2 { grid-template-columns: 1fr; }
    .tab-btn { font-size: 0.85rem; padding: 0.5rem 0.8rem; }
    .question-layout { grid-template-columns: 1fr; }

    /* ── Power-ups ── */
    .powerup-btn { padding: 0.4rem 0.7rem; font-size: 0.8rem; }
}
