/* === RESET & BASE === */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --neon-pink: #ff006e;
    --neon-cyan: #00f5ff;
    --neon-yellow: #ffea00;
    --neon-purple: #8338ec;
    --retro-blue: #3a86ff;
    --dark-bg: #1a1a2e;
    --light-text: #f8f9fa;
}

body {
    font-family: 'Courier New', monospace;
    background: linear-gradient(135deg, var(--dark-bg) 0%, #16213e 100%);
    color: var(--light-text);
    min-height: 100vh;
    overflow-x: hidden;
    position: relative;
}

body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: repeating-linear-gradient(
        0deg,
        transparent,
        transparent 2px,
        rgba(0, 245, 255, 0.03) 2px,
        rgba(0, 245, 255, 0.03) 4px
    );
    pointer-events: none;
    z-index: 0;
}

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

@keyframes glitch {
    0%, 100% {
        text-shadow: 2px 2px var(--neon-cyan), -2px -2px var(--neon-pink);
    }
    25% {
        text-shadow: -2px 2px var(--neon-cyan), 2px -2px var(--neon-pink);
    }
    50% {
        text-shadow: 2px -2px var(--neon-cyan), -2px 2px var(--neon-pink);
    }
    75% {
        text-shadow: -2px -2px var(--neon-cyan), 2px 2px var(--neon-pink);
    }
}

@keyframes float {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-10px);
    }
}

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

@keyframes fall {
    0% {
        transform: translateY(-10px);
        opacity: 0;
    }
    10% {
        opacity: 1;
    }
    90% {
        opacity: 1;
    }
    100% {
        transform: translateY(100vh);
        opacity: 0;
    }
}

/* === SCREEN MANAGEMENT === */
.screen {
    display: none;
    min-height: 100vh;
    padding: 2rem;
    position: relative;
    z-index: 1;
}

.screen.active {
    display: flex;
    animation: fadeIn 0.5s ease;
}

.container-center {
    width: 100%;
    max-width: 800px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
}

.container-full {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
}

/* === BUTTONS === */
.btn-primary {
    background: linear-gradient(45deg, var(--neon-pink), var(--neon-purple));
    color: var(--light-text);
    border: 2px solid var(--neon-cyan);
    padding: 1rem 3rem;
    font-size: 1.2rem;
    font-weight: bold;
    font-family: 'Courier New', monospace;
    text-transform: uppercase;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 0 20px rgba(255, 0, 110, 0.5);
    letter-spacing: 0.1em;
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 30px rgba(255, 0, 110, 0.7);
    border-color: var(--neon-yellow);
}

.btn-primary:active {
    transform: translateY(0);
}

.btn-reset {
    background: transparent;
    color: var(--neon-cyan);
    border: 2px solid var(--neon-cyan);
    padding: 0.5rem 1.5rem;
    font-size: 1rem;
    font-weight: bold;
    font-family: 'Courier New', monospace;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-reset:hover {
    background: var(--neon-cyan);
    color: var(--dark-bg);
}

/* === HOME SCREEN === */
.penguin-icon {
    font-size: 6rem;
    animation: float 3s ease-in-out infinite;
    margin-bottom: 2rem;
}

.title {
    font-size: 4rem;
    font-weight: bold;
    margin-bottom: 1rem;
    color: var(--neon-cyan);
    letter-spacing: 0.2em;
}

.title.glitch {
    animation: glitch 2s infinite;
}

.subtitle {
    font-size: 1.2rem;
    color: var(--neon-pink);
    margin-bottom: 3rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
}

/* === MAP SCREEN === */
.map-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    flex-wrap: wrap;
    gap: 1rem;
}

.map-info {
    text-align: center;
}

.current-year {
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--neon-yellow);
    letter-spacing: 0.1em;
}

.controls-hint {
    font-size: 0.875rem;
    color: var(--neon-cyan);
    margin-top: 0.25rem;
}

.spacer {
    width: 120px;
}

.game-map {
    position: relative;
    border: 4px solid var(--neon-cyan);
    border-radius: 1rem;
    overflow: hidden;
    background: linear-gradient(to top, #1e3a5f 0%, #2c5f7f 30%, #5a8fb4 70%, #87ceeb 100%);
    box-shadow: 0 0 40px rgba(0, 245, 255, 0.4);
    min-height: 500px;
    height: 70vh;
}

.frozen-sea {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 25%;
    background: linear-gradient(to top, #1a4d6d, transparent);
    opacity: 0.6;
}

.snowflake {
    position: absolute;
    background: #fff;
    border-radius: 50%;
    pointer-events: none;
}

.decor-iceberg,
.decor-snow {
    position: absolute;
    opacity: 0.35;
    font-size: 2.5rem;
    pointer-events: none;
}

.path-svg {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1;
}

.stage {
    position: absolute;
    transform: translate(-50%, -50%);
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 5;
}

.stage-checkpoint {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    border: 4px solid;
    font-weight: bold;
    transition: all 0.3s ease;
    color: #fff;
    backdrop-filter: blur(5px);
}

.stage-label {
    position: absolute;
    bottom: -2rem;
    left: 50%;
    transform: translateX(-50%);
    font-size: 0.875rem;
    font-weight: bold;
    white-space: nowrap;
    padding: 0.25rem 0.5rem;
    border-radius: 0.25rem;
    color: #fff;
    backdrop-filter: blur(5px);
}

.penguin-player {
    position: absolute;
    transform: translate(-50%, -50%);
    font-size: 3.5rem;
    filter: drop-shadow(0 0 15px rgba(255, 0, 110, 1));
    animation: float 2s ease-in-out infinite;
    z-index: 10;
    transition: all 0.7s ease-out;
    pointer-events: none;
}

.mobile-hint {
    text-align: center;
    margin-top: 1.5rem;
    font-size: 0.875rem;
    color: var(--neon-cyan);
    display: none;
}

/* === QUESTION SCREEN === */
.question-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 3rem;
    gap: 1rem;
    flex-wrap: wrap;
}

.progress-bar {
    flex: 1;
    min-width: 200px;
    height: 20px;
    background: rgba(255, 255, 255, 0.1);
    border: 2px solid var(--neon-cyan);
    border-radius: 10px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--neon-cyan), var(--neon-purple));
    transition: width 0.5s ease;
    width: 0%;
}

.question-container {
    background: rgba(255, 255, 255, 0.05);
    border: 3px solid var(--neon-pink);
    padding: 3rem;
    border-radius: 15px;
    box-shadow: 0 0 30px rgba(255, 0, 110, 0.3);
    position: relative;
}

.penguin-small {
    position: absolute;
    top: -30px;
    right: 20px;
    font-size: 3rem;
    animation: float 2s ease-in-out infinite;
}

.question-text {
    font-size: 1.8rem;
    color: var(--neon-yellow);
    margin-bottom: 3rem;
    line-height: 1.4;
}

.answers {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.answer-btn {
    background: rgba(255, 255, 255, 0.05);
    border: 2px solid var(--neon-cyan);
    color: var(--light-text);
    padding: 1.5rem;
    font-size: 1.1rem;
    font-family: 'Courier New', monospace;
    text-align: left;
    cursor: pointer;
    transition: all 0.3s ease;
    border-radius: 10px;
}

.answer-btn:hover {
    background: rgba(0, 245, 255, 0.1);
    border-color: var(--neon-yellow);
    transform: translateX(10px);
}

.answer-btn:active {
    transform: scale(0.98);
}

/* === REWARD SCREEN === */
.reward-container {
    text-align: center;
    padding: 2rem;
    width: 100%;
}

.reward-title {
    font-size: 2.5rem;
    color: var(--neon-pink);
    margin-bottom: 3rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
}

.media-container {
    display: flex;
    flex-direction: column;
    gap: 2rem;
    margin-bottom: 3rem;
    align-items: center;
}

.media-item {
    max-width: 100%;
    width: 600px;
    border: 3px solid var(--neon-cyan);
    border-radius: 10px;
    box-shadow: 0 0 30px rgba(0, 245, 255, 0.3);
    overflow: hidden;
}

.media-item img,
.media-item video {
    display: block;
    max-width: 100%;
    width: 100%;
    height: auto;
}

.love-message {
    background: rgba(255, 0, 110, 0.1);
    border: 2px solid var(--neon-pink);
    padding: 2rem;
    border-radius: 10px;
    font-size: 1.3rem;
    line-height: 1.6;
    color: var(--neon-yellow);
    margin-bottom: 3rem;
    font-style: italic;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
}

/* === RESULTS SCREEN === */
.results-container {
    text-align: center;
    padding: 2rem;
}

.results-title {
    font-size: 3rem;
    color: var(--neon-cyan);
    margin-bottom: 3rem;
    text-transform: uppercase;
    animation: pulse 2s infinite;
}

.score-display {
    background: rgba(255, 255, 255, 0.05);
    border: 3px solid var(--neon-purple);
    padding: 3rem;
    border-radius: 15px;
    margin-bottom: 3rem;
}

.score-number {
    font-size: 4rem;
    font-weight: bold;
    color: var(--neon-yellow);
    margin-bottom: 1rem;
}

.score-label {
    font-size: 1.2rem;
    color: var(--neon-cyan);
    text-transform: uppercase;
}

.heart-badge {
    display: inline-block;
    background: linear-gradient(45deg, var(--neon-pink), var(--neon-purple));
    border: 3px solid var(--neon-cyan);
    padding: 2rem 3rem;
    border-radius: 50px;
    margin-bottom: 3rem;
    animation: pulse 2s infinite;
}

.heart {
    font-size: 3rem;
    margin-bottom: 0.5rem;
}

.badge-text {
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--light-text);
    letter-spacing: 0.2em;
}

/* === ERROR MODAL === */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    z-index: 1000;
    justify-content: center;
    align-items: center;
}

.modal.active {
    display: flex;
    animation: fadeIn 0.3s ease;
}

.modal-content {
    background: var(--dark-bg);
    border: 3px solid var(--neon-pink);
    padding: 3rem;
    border-radius: 15px;
    text-align: center;
    max-width: 400px;
    box-shadow: 0 0 50px rgba(255, 0, 110, 0.5);
    animation: pulse 0.5s ease;
}

.modal-icon {
    font-size: 4rem;
    margin-bottom: 1rem;
}

.modal-content h3 {
    font-size: 1.8rem;
    color: var(--neon-yellow);
    margin-bottom: 1rem;
}

.modal-content p {
    font-size: 1.2rem;
    color: var(--neon-cyan);
    margin-bottom: 2rem;
}

/* === RESPONSIVE === */
@media (max-width: 768px) {
    .title {
        font-size: 2.5rem;
    }
    
    .penguin-icon {
        font-size: 4rem;
    }
    
    .question-text {
        font-size: 1.3rem;
    }
    
    .reward-title {
        font-size: 1.8rem;
    }
    
    .results-title {
        font-size: 2rem;
    }
    
    .score-number {
        font-size: 3rem;
    }
    
    .btn-primary {
        padding: 0.8rem 2rem;
        font-size: 1rem;
    }

    .current-year {
        font-size: 1.2rem;
    }

    .controls-hint {
        display: none;
    }

    .mobile-hint {
        display: block;
    }
}

@media (max-width: 480px) {
    .screen {
        padding: 1rem;
    }
    
    .title {
        font-size: 2rem;
        letter-spacing: 0.1em;
    }
    
    .penguin-icon {
        font-size: 3rem;
    }
    
    .question-container {
        padding: 2rem;
    }
    
    .penguin-small {
        font-size: 2rem;
        top: -20px;
        right: 10px;
    }

    .spacer {
        display: none;
    }
}
