/* =============================================================
   Quiz 4: ALERT OVERLOAD — Styles
   Design language matched to Quiz 5 (Chartplotter)
   ============================================================= */

/* Reset */
@import url('https://fonts.googleapis.com/css2?family=Manrope:wght@400;500;600;700;800&family=JetBrains+Mono:wght@400;600&display=swap');

* { margin: 0; padding: 0; box-sizing: border-box; }

:root {
    --navy: #1e3a5f;
    --orange: #FF9800;
    --text: #ffffff;
}

body {
    font-family: 'Manrope', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background: linear-gradient(160deg, #0a1628 0%, #122a4a 50%, #0d1f3c 100%);
    color: var(--text);
    min-height: 100vh;
    line-height: 1.5;
    overflow-x: hidden;
}

.container {
    max-width: 500px;
    margin: 0 auto;
    padding: 1.5rem 1.2rem;
}

/* --- SCREENS --- */
.screen { display: none; animation: fadeIn 0.3s ease; }
.screen.active { display: block; }
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }

/* --- LOGO --- */
.logo { text-align: center; margin-bottom: 1.5rem; }
.logo img { max-width: 200px; width: 100%; height: auto; }

/* ===== LANDING PAGE ===== */

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

@keyframes ctaGlow {
    0%, 100% { box-shadow: 0 0 15px rgba(255,107,53,0.4); }
    50% { box-shadow: 0 0 30px rgba(255,107,53,0.6), 0 0 60px rgba(255,107,53,0.2); }
}

.landing-badge {
    display: block;
    text-align: center;
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 3px;
    color: var(--orange);
    margin-bottom: 10px;
    animation: fadeSlideUp 0.5s ease both;
}

.landing-container {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.hero-section {
    background: linear-gradient(135deg, rgba(255,255,255,0.08) 0%, rgba(255,255,255,0.03) 100%);
    border: 1px solid rgba(255,255,255,0.12);
    border-radius: 20px;
    padding: 2rem 1.5rem 1.5rem;
    margin-bottom: 1.5rem;
    text-align: center;
    animation: fadeSlideUp 0.5s ease 0.1s both;
}

.hero-section h1 {
    font-size: 2.2rem;
    font-weight: 800;
    letter-spacing: -0.5px;
    line-height: 1.1;
    margin-bottom: 0.4rem;
    text-shadow: 0 0 60px rgba(255,255,255,0.06), 0 2px 4px rgba(0,0,0,0.3);
}

.hero-section h2 {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--orange);
}

.intro-text {
    text-align: center;
    margin-bottom: 1.5rem;
}

.intro-text p {
    font-size: 1rem;
    line-height: 1.6;
    color: rgba(255,255,255,0.7);
    margin-bottom: 8px;
}

.intro-text .highlight {
    color: var(--orange);
    font-weight: 700;
    font-size: 1.1rem;
}

/* How to play */
.how-to-play {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 1.2rem;
    padding: 1rem 1.2rem;
    background: rgba(255,255,255,0.04);
    border-radius: 14px;
    border: 1px solid rgba(255,255,255,0.08);
}

.how-step {
    font-size: 0.9rem;
    color: rgba(255,255,255,0.6);
    display: flex;
    align-items: center;
    gap: 10px;
}

.step-icon {
    color: var(--orange);
    font-size: 0.7rem;
}

/* ===== ANIMATED ALERT PREVIEW ===== */
.alert-preview {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin: 1.2rem 0 1rem;
}

.preview-card {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    border-radius: 10px;
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.08);
    opacity: 0;
    transform: translateX(-20px);
    animation: cardSlideIn 0.5s ease forwards;
}

.preview-card:nth-child(1) { animation-delay: 0.3s; }
.preview-card:nth-child(2) { animation-delay: 0.8s; }
.preview-card:nth-child(3) { animation-delay: 1.3s; }
.preview-card:nth-child(4) { animation-delay: 1.8s; }

@keyframes cardSlideIn {
    to { opacity: 1; transform: translateX(0); }
}

.pc-text {
    flex: 1;
    font-size: 0.78rem;
    color: rgba(255,255,255,0.7);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.pc-timer {
    width: 60px;
    height: 4px;
    background: rgba(255,255,255,0.1);
    border-radius: 2px;
    overflow: hidden;
    flex-shrink: 0;
}

.pc-fill {
    height: 100%;
    border-radius: 2px;
    animation: timerDrain 3s ease-in-out infinite;
}

.pc-fill-emergency { background: #ff2d2d; animation-delay: 0.3s; animation-duration: 2s; }
.pc-fill-alarm { background: var(--orange); animation-delay: 0.8s; animation-duration: 2.8s; }
.pc-fill-warning { background: #ffb300; animation-delay: 1.3s; animation-duration: 3.5s; }
.pc-fill-caution { background: #4fc3f7; animation-delay: 1.8s; animation-duration: 4.2s; }

@keyframes timerDrain {
    0% { width: 100%; }
    70% { width: 20%; }
    100% { width: 100%; }
}

/* Emergency card pulses urgently */
.pc-emergency {
    animation: cardSlideIn 0.5s ease forwards, cardUrgent 1.5s ease-in-out 2.5s infinite;
}

@keyframes cardUrgent {
    0%, 100% { border-color: rgba(255,255,255,0.08); }
    50% { border-color: rgba(255,45,45,0.4); box-shadow: 0 0 12px rgba(255,45,45,0.15); }
}

/* Severity legend */
.severity-legend {
    display: flex;
    justify-content: center;
    gap: 14px;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
}

.legend-item {
    font-size: 0.8rem;
    color: rgba(255,255,255,0.45);
    display: flex;
    align-items: center;
    gap: 5px;
}

/* Severity dots */
.dot {
    display: inline-block;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    flex-shrink: 0;
}

.dot-emergency { background: #ff2d2d; box-shadow: 0 0 6px rgba(255, 45, 45, 0.5); animation: dotPulseRed 1.2s ease-in-out infinite; }
.dot-alarm { background: var(--orange); box-shadow: 0 0 6px rgba(255, 107, 53, 0.4); animation: dotPulseOrange 1.6s ease-in-out infinite 0.2s; }
.dot-warning { background: #ffb300; animation: dotPulseYellow 2s ease-in-out infinite 0.4s; }
.dot-caution { background: #4fc3f7; animation: dotPulseBlue 2.5s ease-in-out infinite 0.6s; }

@keyframes dotPulseRed { 0%,100% { box-shadow: 0 0 4px rgba(255,45,45,0.3); } 50% { box-shadow: 0 0 10px rgba(255,45,45,0.7); } }
@keyframes dotPulseOrange { 0%,100% { box-shadow: 0 0 4px rgba(255,107,53,0.2); } 50% { box-shadow: 0 0 8px rgba(255,107,53,0.5); } }
@keyframes dotPulseYellow { 0%,100% { box-shadow: 0 0 3px rgba(255,179,0,0.1); } 50% { box-shadow: 0 0 7px rgba(255,179,0,0.4); } }
@keyframes dotPulseBlue { 0%,100% { box-shadow: 0 0 3px rgba(79,195,247,0.1); } 50% { box-shadow: 0 0 6px rgba(79,195,247,0.3); } }

/* Preview severity dots */
.preview-severity {
    display: flex;
    justify-content: center;
    gap: 16px;
    margin-top: 1.2rem;
}

.preview-severity .dot {
    width: 14px;
    height: 14px;
}

/* Feature pills */
.landing-features {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-top: 18px;
    animation: fadeSlideUp 0.5s ease 0.5s both;
}
.feature-pill {
    font-size: 0.8rem;
    color: rgba(255,255,255,0.5);
    font-weight: 600;
}
.feature-pill-dot {
    color: rgba(255,255,255,0.25);
    font-size: 0.7rem;
}
.cta-icon {
    font-size: 0.8rem;
    margin-right: 0.2rem;
    vertical-align: middle;
}

.sound-inline {
    cursor: pointer;
    vertical-align: middle;
}

.sound-inline input[type="checkbox"] {
    accent-color: var(--orange);
    vertical-align: middle;
    margin-left: 2px;
}

/* CTA — pill shape with glow */
.cta-button {
    display: block;
    width: 100%;
    max-width: 360px;
    margin: 0 auto 1rem;
    padding: 1.1rem 2rem;
    font-size: 1.25rem;
    font-weight: 700;
    color: #0a1628;
    background: linear-gradient(135deg, var(--orange) 0%, #ff8f5e 100%);
    border: none;
    border-radius: 50px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 20px rgba(255,107,53,0.35);
    -webkit-tap-highlight-color: transparent;
    animation: fadeSlideUp 0.5s ease 0.35s both, ctaGlow 3s ease-in-out 1.5s infinite;
}

@keyframes ctaPulse {
    0%, 100% { box-shadow: 0 4px 20px rgba(255,107,53,0.35); }
    50% { box-shadow: 0 4px 30px rgba(255,107,53,0.55), 0 0 40px rgba(255,107,53,0.15); }
}

.cta-button:hover {
    background: #ff8555;
    transform: translateY(-2px);
    box-shadow: 0 6px 24px rgba(255,107,53,0.45);
    animation: none;
}

.cta-button:active { transform: translateY(0); }

.sound-toggle-landing {
    text-align: center;
    margin-top: 0.3rem;
}

.sound-toggle-landing label {
    font-size: 0.82rem;
    color: rgba(255,255,255,0.35);
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.sound-toggle-landing input[type="checkbox"] {
    accent-color: var(--orange);
}

/* ===== GAME SCREEN ===== */
.game-container {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    padding-top: 12px;
}

/* HUD */
.hud {
    display: flex;
    justify-content: space-between;
    margin-bottom: 16px;
    padding: 10px 16px;
    background: rgba(255,255,255,0.04);
    border-radius: 14px;
    border: 1px solid rgba(255,255,255,0.08);
}

.hud-item {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.hud-label {
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: rgba(255,255,255,0.4);
    margin-bottom: 2px;
}

.hud-value {
    font-size: 1.4rem;
    font-weight: 800;
    color: #fff;
    font-variant-numeric: tabular-nums;
}

/* Round transition overlay */
.round-transition {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(8, 14, 26, 0.92);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 100;
}

.transition-text {
    font-size: 1.8rem;
    font-weight: 800;
    color: #fff;
    text-align: center;
    line-height: 1.5;
    animation: fadeIn 0.3s ease-out;
}

.transition-score {
    font-size: 1rem;
    color: var(--orange);
    font-weight: 600;
}

/* Alert area */
.alert-area {
    display: flex;
    flex-direction: column;
    gap: 10px;
    flex: 1;
}

/* Alert cards */
.alert-card {
    padding: 14px 16px 8px;
    background: rgba(255,255,255,0.06);
    border: 2px solid rgba(255,255,255,0.1);
    border-radius: 14px;
    cursor: pointer;
    transition: transform 0.1s, border-color 0.2s, background 0.2s, opacity 0.3s;
    -webkit-tap-highlight-color: transparent;
    user-select: none;
}

.alert-card:active {
    transform: scale(0.97);
}

/* Severity-specific left border */
.alert-emergency { border-left: 3px solid #ff2d2d; }
.alert-alarm { border-left: 3px solid var(--orange); }
.alert-warning { border-left: 3px solid #ffb300; }
.alert-caution { border-left: 3px solid #4fc3f7; }

.alert-content {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin-bottom: 10px;
}

.alert-text {
    font-size: 0.95rem;
    font-weight: 500;
    color: rgba(255,255,255,0.9);
    line-height: 1.4;
}

.alert-content .dot {
    margin-top: 3px;
}

/* Timer bar */
.timer-bar {
    height: 6px;
    background: rgba(255,255,255,0.1);
    border-radius: 3px;
    overflow: hidden;
    margin-top: 4px;
}

.timer-fill {
    height: 100%;
    width: 100%;
    border-radius: 3px;
    transition: width 0.05s linear;
}

.timer-emergency { background: #ff2d2d; }
.timer-alarm { background: var(--orange); }
.timer-warning { background: #ffb300; }
.timer-caution { background: #4fc3f7; }
.timer-low { background: var(--orange) !important; }
.timer-critical { background: #ff2d2d !important; animation: timerPulse 0.4s infinite; }

/* Alert animations */
.alert-enter {
    opacity: 0;
    transform: translateX(40px);
}

.alert-card {
    opacity: 1;
    transform: translateX(0);
    transition: opacity 0.25s ease-out, transform 0.25s ease-out, border-color 0.2s, background 0.2s;
}

.alert-correct {
    opacity: 0;
    transform: translateX(-40px) scale(0.95);
    border-color: #4caf50;
    background: rgba(76, 175, 80, 0.15);
    transition: all 0.3s ease-in;
}

.alert-wrong {
    border-color: #ff2d2d !important;
    background: rgba(255, 45, 45, 0.1) !important;
    animation: wrongShake 0.4s ease-out;
}

.alert-wrong-handled {
    opacity: 0;
    transform: translateX(-40px) scale(0.95);
    border-color: var(--orange);
    background: rgba(255, 107, 53, 0.1);
    transition: all 0.3s ease-in;
}

.alert-pulse {
    animation: alertPulse 0.8s infinite;
}

/* Priority hint */
.priority-hint {
    position: fixed;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(255, 45, 45, 0.9);
    color: #fff;
    padding: 10px 20px;
    border-radius: 14px;
    font-size: 0.9rem;
    font-weight: 600;
    z-index: 50;
    text-align: center;
    max-width: 90%;
}

.hint-flash {
    animation: fadeInUp 0.2s ease-out;
}

/* ===== GAME OVER SCREEN ===== */
.gameover-container {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    position: relative;
}

.gameover-flash {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 0, 0, 0.3);
    pointer-events: none;
    opacity: 0;
    z-index: 200;
}

.flash-active {
    animation: redFlash 0.6s ease-out;
}

.gameover-title {
    font-size: 2rem;
    font-weight: 800;
    color: #ff4444;
    margin-bottom: 24px;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.gameover-consequence {
    margin-bottom: 32px;
    max-width: 400px;
}

.expired-alert {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-size: 1rem;
    font-weight: 600;
    color: #ff6b6b;
    margin-bottom: 16px;
    padding: 12px;
    background: rgba(255, 68, 68, 0.12);
    border: 1px solid rgba(255, 68, 68, 0.3);
    border-radius: 14px;
}

.consequence-text {
    font-size: 1rem;
    color: rgba(255,255,255,0.7);
    line-height: 1.6;
}

.gameover-stats {
    display: flex;
    gap: 24px;
    margin-bottom: 28px;
}

.stat {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.stat-value {
    font-size: 2rem;
    font-weight: 800;
    color: var(--orange);
    font-variant-numeric: tabular-nums;
}

.stat-label {
    font-size: 0.75rem;
    color: rgba(255,255,255,0.4);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.gameover-message {
    margin-bottom: 28px;
    max-width: 400px;
}

.gameover-message p {
    font-size: 1rem;
    color: rgba(255,255,255,0.6);
    line-height: 1.6;
}

.shake {
    animation: shake 0.5s ease-out;
}

/* ===== RESULTS PAGE ===== */
.results-container {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    padding-top: 24px;
    padding-bottom: 40px;
}

.results-summary {
    text-align: center;
    margin-bottom: 1.5rem;
    padding: 1.5rem;
    background: rgba(255,255,255,0.06);
    border-radius: 16px;
}

.results-summary h2 {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 12px;
}

.orange { color: var(--orange); }

.results-summary p,
#result-message {
    font-size: 1rem;
    color: rgba(255,255,255,0.7);
    line-height: 1.6;
}

/* Explanation — left border accent */
.explanation {
    background: rgba(255,255,255,0.04);
    border-left: 4px solid var(--orange);
    border-radius: 10px;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}

.explanation h3 {
    color: var(--orange);
    margin-bottom: 0.8rem;
    font-size: 1.2rem;
    font-weight: 700;
}

.explanation p {
    font-size: 0.95rem;
    color: rgba(255,255,255,0.8);
    line-height: 1.6;
    margin-bottom: 0.8rem;
}

.explanation .highlight {
    color: var(--orange);
    font-weight: 700;
    font-size: 1.05rem;
}

/* 3AM Report gate — orange-tinted */
.report-gate {
    text-align: center;
    margin-bottom: 0.8rem;
    padding: 1.5rem;
    background: rgba(255,107,53,0.12);
    border: 2px solid rgba(255,107,53,0.5);
    border-radius: 16px;
}

.report-gate h3 {
    font-size: 1.2rem;
    font-weight: 700;
    color: #fff;
    margin-bottom: 0.3rem;
}

.report-gate > p {
    font-size: 0.9rem;
    color: rgba(255,255,255,0.6);
    line-height: 1.6;
    margin-bottom: 1rem;
}

#email-form {
    display: flex;
    flex-direction: column;
    gap: 0.7rem;
    max-width: 320px;
    margin: 0 auto;
}

#email-form input[type="email"],
.second-chance input[type="email"],
#email-form-2 input[type="email"] {
    padding: 0.85rem;
    font-size: 1rem;
    border: 1px solid rgba(255,255,255,0.2);
    border-radius: 10px;
    background: rgba(255,255,255,0.08);
    color: #fff;
    font-family: inherit;
}

#email-form input[type="email"]::placeholder,
.second-chance input[type="email"]::placeholder,
#email-form-2 input[type="email"]::placeholder {
    color: rgba(255,255,255,0.4);
}

#email-form input[type="email"]:focus,
.second-chance input[type="email"]:focus,
#email-form-2 input[type="email"]:focus {
    outline: none;
    border-color: var(--orange);
}

.subscribe-button {
    padding: 0.9rem 1.5rem;
    font-size: 1.05rem;
    font-weight: 700;
    color: #0a1628;
    background: var(--orange);
    border: none;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.2s ease;
    font-family: inherit;
}

.subscribe-button:hover:not(:disabled) { background: #ff8555; }
.subscribe-button:disabled { opacity: 0.6; cursor: default; }

.form-message { font-size: 0.9rem; margin-top: 0.6rem; }
.form-message.success { color: #4caf50; }
.form-message.error { color: #ff4444; }

.download-link { margin-top: 16px; }

.download-btn {
    display: inline-block;
    padding: 0.9rem 1.8rem;
    font-size: 1.05rem;
    font-weight: 700;
    color: #0a1628;
    background: var(--orange);
    border-radius: 10px;
    text-decoration: none;
    transition: all 0.2s ease;
    box-shadow: 0 4px 16px rgba(255,107,53,0.3);
}

.download-btn:hover {
    background: #ff8555;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(255,107,53,0.4);
}

.skip-link {
    display: block;
    text-align: center;
    margin: 0.5rem auto 1.5rem;
    padding: 8px;
    background: none;
    border: none;
    color: rgba(255,255,255,0.5);
    font-size: 0.85rem;
    cursor: pointer;
    text-decoration: underline;
    font-family: inherit;
}

.skip-link:hover { color: rgba(255,255,255,0.7); }

/* Social sharing — card style */
.social-sharing {
    background: rgba(255,255,255,0.04);
    border-radius: 14px;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}

.social-sharing h3 {
    text-align: center;
    margin-bottom: 1rem;
    font-size: 1.05rem;
    font-weight: 600;
    color: rgba(255,255,255,0.8);
}

.share-buttons {
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
}

.share-btn {
    padding: 0.85rem;
    font-size: 0.95rem;
    font-weight: 600;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.2s ease;
    font-family: inherit;
    -webkit-tap-highlight-color: transparent;
}

.share-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.3);
}

.share-btn.native { background: #FF9800; color: #0a1628; }
.share-btn.facebook { background: #1877f2; color: #fff; }
.share-btn.linkedin { background: #0a66c2; color: #fff; }
.share-btn.copy { background: rgba(255,255,255,0.12); color: #fff; border: 1px solid rgba(255,255,255,0.2); }

/* Second chance signup */
.second-chance {
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.15);
    border-radius: 16px;
    padding: 1.5rem;
    text-align: center;
    margin-bottom: 1.5rem;
}

.second-chance > p {
    font-size: 0.9rem;
    color: rgba(255,255,255,0.6);
    line-height: 1.6;
    margin-bottom: 1rem;
}

.second-chance form,
#email-form-2 {
    display: flex;
    flex-direction: column;
    gap: 0.7rem;
    max-width: 320px;
    margin: 0 auto;
}

/* Other quizzes cross-links */
.other-quizzes {
    margin-bottom: 1.5rem;
}

.other-quizzes h3 {
    font-size: 1rem;
    font-weight: 700;
    color: rgba(255,255,255,0.6);
    text-align: center;
    margin-bottom: 14px;
}

.quiz-card-link {
    text-decoration: none;
    display: block;
    margin-bottom: 10px;
}

.quiz-card {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 16px;
    background: rgba(255,255,255,0.05);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 14px;
    transition: background 0.2s, border-color 0.2s;
}

.quiz-card:hover {
    background: rgba(255,255,255,0.08);
    border-color: rgba(255,255,255,0.2);
}

.quiz-card-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    background: rgba(255,255,255,0.08);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    flex-shrink: 0;
    box-shadow: 0 4px 12px rgba(0,0,0,0.3);
}

.quiz-card-info {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.quiz-card-info strong {
    font-size: 0.95rem;
    font-weight: 700;
    color: #fff;
}

.quiz-card-info span {
    font-size: 0.82rem;
    color: rgba(255,255,255,0.5);
    line-height: 1.4;
}

/* Play again */
.play-again-btn {
    display: block;
    width: 100%;
    max-width: 240px;
    margin: 0 auto;
    padding: 0.9rem;
    font-size: 1rem;
    font-weight: 600;
    color: var(--orange);
    background: transparent;
    border: 2px solid rgba(255,107,53,0.3);
    border-radius: 50px;
    cursor: pointer;
    transition: border-color 0.2s, background 0.2s;
    font-family: inherit;
}

.play-again-btn:hover {
    border-color: var(--orange);
    background: rgba(255,107,53,0.08);
}

/* ===== GAMIFICATION ===== */

/* Streak counter */
.streak {
    display: block;
    text-align: center;
    font-size: 0.85rem;
    font-weight: 700;
    color: #4caf50;
    letter-spacing: 1px;
    opacity: 0;
    transition: all 0.3s ease;
    margin-bottom: 4px;
}
.streak.visible { opacity: 1; }
.streak.hot { color: #ff4444; animation: streakPulse 0.4s ease; }

@keyframes streakPulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.15); }
}

/* Reaction time */
.reaction-time {
    text-align: center;
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.5px;
    opacity: 0;
    transition: opacity 0.3s;
    margin-bottom: 8px;
}
.reaction-time.visible { opacity: 1; }
.reaction-time.fast { color: #4caf50; }
.reaction-time.medium { color: var(--orange); }
.reaction-time.slow { color: #ff6b6b; }

/* Particle burst */
.particle {
    position: fixed;
    width: 6px;
    height: 6px;
    background: #4caf50;
    border-radius: 50%;
    pointer-events: none;
    z-index: 9998;
    animation: particleBurst 0.6s ease-out forwards;
}

@keyframes particleBurst {
    0% { transform: translate(0, 0) scale(1); opacity: 1; }
    100% { transform: translate(var(--dx), var(--dy)) scale(0); opacity: 0; }
}

/* Score title */
.score-title {
    font-size: 0.85rem;
    letter-spacing: 3px;
    text-transform: uppercase;
    color: var(--orange);
    text-align: center;
    margin-bottom: 16px;
    font-weight: 700;
}

/* ===== ANIMATIONS ===== */
@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(12px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes alertPulse {
    0%, 100% { border-color: rgba(255, 68, 68, 0.3); }
    50% { border-color: rgba(255, 68, 68, 0.8); background: rgba(255, 68, 68, 0.08); }
}

@keyframes timerPulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.4; }
}

@keyframes wrongShake {
    0%, 100% { transform: translateX(0); }
    20% { transform: translateX(-8px); }
    40% { transform: translateX(8px); }
    60% { transform: translateX(-4px); }
    80% { transform: translateX(4px); }
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    15% { transform: translateX(-6px); }
    30% { transform: translateX(6px); }
    45% { transform: translateX(-4px); }
    60% { transform: translateX(4px); }
    75% { transform: translateX(-2px); }
}

@keyframes redFlash {
    0% { opacity: 0.6; }
    100% { opacity: 0; }
}

/* ===== RESPONSIVE ===== */
@media (max-width: 380px) {
    .container { padding: 1.2rem 1rem; }
    .hero-section h1 { font-size: 1.8rem; }
    .hero-section h2 { font-size: 1rem; }
    .alert-text { font-size: 0.88rem; }
    .gameover-stats { gap: 16px; }
    .stat-value { font-size: 1.6rem; }
}

@media (max-width: 480px) {
    .hud-value { font-size: 1.2rem; }
    .cta-button, .subscribe-button, .share-btn { min-height: 48px; }
    .alert-card { padding: 12px 14px 8px; }
}

.gdpr-consent {
    display: flex; align-items: flex-start; gap: 8px;
    font-size: 0.75rem; color: rgba(255,255,255,0.4);
    cursor: pointer; text-align: left; line-height: 1.4;
}
.gdpr-consent input[type="checkbox"] {
    margin-top: 2px; flex-shrink: 0; accent-color: var(--orange);
    width: 16px; height: 16px; cursor: pointer;
}
.gdpr-consent a { color: rgba(255,255,255,0.5); text-decoration: underline; }
.gdpr-consent a:hover { color: var(--orange); }
