@import url('https://fonts.googleapis.com/css2?family=Fredoka:wght@400;600;700&display=swap');

:root {
    --sky-top: #87CEEB;
    --sky-bottom: #E0F4FF;
    --ground-color: #8B5A2B;
    --ground-top: #6B8E23;
    --player-color: #F5F5F5;
    --player-shadow: #D4D4D4;
    --accent-orange: #FF6B35;
    --accent-green: #4CAF50;
    --text-dark: #2D3436;
    --panel-bg: rgba(255, 255, 255, 0.95);
    --shadow-soft: 0 4px 20px rgba(0, 0, 0, 0.1);
    --shadow-medium: 0 8px 30px rgba(0, 0, 0, 0.15);
}

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

body {
    font-family: 'Fredoka', sans-serif;
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
    user-select: none;
    -webkit-user-select: none;
}

.game-wrapper {
    display: flex;
    gap: 20px;
    padding: 20px;
    max-width: 1200px;
    width: 100%;
}

.score-panel {
    display: flex;
    flex-direction: column;
    gap: 15px;
    min-width: 120px;
}

.score-box {
    background: var(--panel-bg);
    border-radius: 16px;
    padding: 15px 20px;
    text-align: center;
    box-shadow: var(--shadow-soft);
    transition: transform 0.3s ease;
}

.score-box:hover {
    transform: translateY(-3px);
}

.score-box .label {
    display: block;
    font-size: 12px;
    font-weight: 600;
    color: #636e72;
    letter-spacing: 1px;
    margin-bottom: 5px;
}

.score-box .value {
    display: block;
    font-size: 32px;
    font-weight: 700;
    color: var(--accent-orange);
}

.btn-sound {
    background: var(--panel-bg);
    border: none;
    border-radius: 16px;
    padding: 15px;
    cursor: pointer;
    font-size: 24px;
    box-shadow: var(--shadow-soft);
    transition: all 0.3s ease;
}

.btn-sound:hover {
    transform: scale(1.05);
}

.btn-sound .sound-off {
    display: none;
}

.btn-sound.muted .sound-on {
    display: none;
}

.btn-sound.muted .sound-off {
    display: inline;
}

.game-container {
    position: relative;
    width: 800px;
    height: 400px;
    background: linear-gradient(to bottom, var(--sky-top) 0%, var(--sky-bottom) 70%, var(--ground-top) 70%, var(--ground-color) 100%);
    border-radius: 20px;
    overflow: hidden;
    box-shadow: var(--shadow-medium);
    touch-action: manipulation;
}

.game-sky {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 70%;
    overflow: hidden;
}

.clouds {
    position: absolute;
    width: 100%;
    height: 100%;
    background-image: 
        radial-gradient(ellipse 80px 40px at 20% 30%, white 0%, transparent 70%),
        radial-gradient(ellipse 60px 30px at 50% 20%, white 0%, transparent 70%),
        radial-gradient(ellipse 70px 35px at 80% 35%, white 0%, transparent 70%);
    opacity: 0.8;
    animation: cloudsMove 30s linear infinite;
}

@keyframes cloudsMove {
    from { transform: translateX(0); }
    to { transform: translateX(-200px); }
}

.sun {
    position: absolute;
    top: 20px;
    right: 40px;
    width: 60px;
    height: 60px;
    background: radial-gradient(circle, #FFD93D 0%, #FF9F1C 100%);
    border-radius: 50%;
    box-shadow: 0 0 40px #FFD93D, 0 0 80px rgba(255, 217, 61, 0.5);
    animation: sunPulse 4s ease-in-out infinite;
}

@keyframes sunPulse {
    0%, 100% { transform: scale(1); box-shadow: 0 0 40px #FFD93D, 0 0 80px rgba(255, 217, 61, 0.5); }
    50% { transform: scale(1.05); box-shadow: 0 0 50px #FFD93D, 0 0 100px rgba(255, 217, 61, 0.6); }
}

.game-ground {
    position: absolute;
    bottom: 0;
    width: 100%;
    height: 30%;
    background: linear-gradient(to bottom, var(--ground-top) 0%, var(--ground-color) 30%, #654321 100%);
}

.game-ground::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(to bottom, rgba(255,255,255,0.3), transparent);
}

.player {
    position: absolute;
    bottom: 30%;
    left: 80px;
    width: 60px;
    height: 60px;
    z-index: 10;
}

.player-sprite {
    width: 100%;
    height: 100%;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 60 60'%3E%3Cellipse cx='30' cy='38' rx='18' ry='16' fill='%23F5F5F5'/%3E%3Cellipse cx='30' cy='38' rx='14' ry='12' fill='%23FFE4E1'/%3E%3Cellipse cx='20' cy='28' rx='6' ry='8' fill='%23F5F5F5'/%3E%3Cellipse cx='40' cy='28' rx='6' ry='8' fill='%23F5F5F5'/%3E%3Cellipse cx='20' cy='26' rx='3' ry='5' fill='%23FFB6C1'/%3E%3Cellipse cx='40' cy='26' rx='3' ry='5' fill='%23FFB6C1'/%3E%3Ccircle cx='24' cy='34' r='3' fill='%232D3436'/%3E%3Ccircle cx='36' cy='34' r='3' fill='%232D3436'/%3E%3Ccircle cx='25' cy='33' r='1' fill='white'/%3E%3Ccircle cx='37' cy='33' r='1' fill='white'/%3E%3Cellipse cx='30' cy='40' rx='3' ry='2' fill='%23FFB6C1'/%3E%3Cellipse cx='22' cy='50' rx='4' ry='6' fill='%23F5F5F5'/%3E%3Cellipse cx='38' cy='50' rx='4' ry='6' fill='%23F5F5F5'/%3E%3C/svg%3E");
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
    animation: run 0.3s steps(2) infinite;
}

.player.jumping .player-sprite {
    animation: jump 0.5s ease-out;
}

.player.underground {
    opacity: 0.6;
    filter: brightness(0.6) sepia(0.4);
    z-index: 5;
}

.player.invincible {
    animation: flash 0.2s infinite;
}

.player.slowed {
    filter: saturate(0.5) blur(1px);
}

.player.on-rocket::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: -10px;
    width: 80px;
    height: 40px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 80 40'%3E%3Cpath d='M10 10 L70 20 L10 30 Z' fill='%23FF4757'/%3E%3Crect x='5' y='12' width='10' height='16' fill='%232F3542'/%3E%3Cpath d='M0 20 L10 15 L10 25 Z' fill='%23FFA502'/%3E%3C/svg%3E");
    background-size: contain;
    background-repeat: no-repeat;
    z-index: -1;
}

.player.has-sword::after {
    content: '';
    position: absolute;
    top: 5px;
    right: -20px;
    width: 40px;
    height: 40px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 40 40'%3E%3Cpath d='M10 30 L30 10 L35 15 L15 35 Z' fill='%23dfe6e9'/%3E%3Cpath d='M30 10 L35 5 L40 10 L35 15 Z' fill='%23ffeaa7'/%3E%3Crect x='5' y='30' width='10' height='5' transform='rotate(-45 10 32)' fill='%23636e72'/%3E%3C/svg%3E");
    background-size: contain;
    background-repeat: no-repeat;
    animation: swordSwing 0.3s ease-in-out infinite alternate;
}

@keyframes swordSwing {
    from { transform: rotate(-10deg); }
    to { transform: rotate(20deg); }
}

@keyframes flash {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.3; }
}

/* Sky Level Styles */
body.sky-level .game-container {
    background: linear-gradient(to bottom, #4facfe 0%, #00f2fe 100%);
}

body.sky-level .game-ground {
    opacity: 0;
    visibility: hidden;
    transform: translateY(100%);
    transition: all 0.8s ease;
}

body.sky-level .game-sky {
    height: 100%;
}

body.sky-level .clouds {
    animation-duration: 10s;
    background-image: 
        radial-gradient(ellipse 100px 50px at 10% 20%, white 0%, transparent 80%),
        radial-gradient(ellipse 120px 60px at 40% 50%, white 0%, transparent 80%),
        radial-gradient(ellipse 90px 45px at 70% 30%, white 0%, transparent 80%),
        radial-gradient(ellipse 150px 70px at 90% 80%, white 0%, transparent 80%),
        radial-gradient(ellipse 80px 40px at 20% 70%, white 0%, transparent 80%);
}

/* Food - Rocket */
.food.rocket {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 45 45'%3E%3Cpath d='M10 10 L35 22.5 L10 35 Z' fill='%23FF4757'/%3E%3Cpath d='M5 22.5 L10 18 L10 27 Z' fill='%23FFA502'/%3E%3Ccircle cx='18' cy='22.5' r='3' fill='white'/%3E%3C/svg%3E");
    background-size: contain;
    background-repeat: no-repeat;
    animation: rocketGlow 0.5s infinite alternate;
    z-index: 15;
}

.food.rocket::before {
    display: none !important;
}

@keyframes rocketGlow {
    from { filter: drop-shadow(0 0 2px #FF4757); }
    to { filter: drop-shadow(0 0 10px #FFA502); }
}

/* Lava World Styles */
body.lava-world .game-container {
    background: linear-gradient(to bottom, #4a0000 0%, #800000 70%, #330000 70%, #1a0000 100%);
}

body.lava-world .game-ground {
    background: linear-gradient(to bottom, #ff4500 0%, #8b0000 30%, #330000 100%);
    box-shadow: inset 0 10px 20px rgba(255, 69, 0, 0.5);
}

body.lava-world .sun {
    background: radial-gradient(circle, #ff0000 0%, #ff8c00 100%);
    box-shadow: 0 0 50px #ff4500;
}

/* Food - Sword */
.food.sword {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 40 40'%3E%3Cpath d='M10 30 L30 10 L35 15 L15 35 Z' fill='%23dfe6e9'/%3E%3Cpath d='M30 10 L35 5 L40 10 L35 15 Z' fill='%23ffeaa7'/%3E%3C/svg%3E");
    background-size: contain;
    background-repeat: no-repeat;
    filter: drop-shadow(0 0 5px cyan);
    animation: foodBob 0.6s infinite alternate;
}

/* New Sky Obstacles */
.obstacle.plane {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 60 30'%3E%3Cpath d='M10 15 L50 15 L45 5 L15 5 Z' fill='%23ced4da'/%3E%3Cpath d='M25 15 L35 15 L30 25 Z' fill='%23adb5bd'/%3E%3C/svg%3E");
}

.obstacle.cloud-obstacle {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 70 40'%3E%3Ccircle cx='20' cy='25' r='15' fill='white'/%3E%3Ccircle cx='35' cy='20' r='15' fill='white'/%3E%3Ccircle cx='50' cy='25' r='15' fill='white'/%3E%3C/svg%3E");
    opacity: 0.8;
}

/* Night Mode Styles */
body.night-mode .game-container {
    background: linear-gradient(to bottom, #0c0c22 0%, #1a1a4e 70%, #2d5a27 70%, #3d2b1f 100%);
}

body.night-mode .sun {
    background: radial-gradient(circle, #e0e0e0 0%, #9e9e9e 100%);
    box-shadow: 0 0 40px #fff, 0 0 80px rgba(255, 255, 255, 0.3);
}

/* Space World Styles */
body.space-world .game-container {
    background: linear-gradient(to bottom, #000000 0%, #1a0033 70%, #333333 70%, #1a1a1a 100%);
}

body.space-world .game-ground {
    background: linear-gradient(to bottom, #444 0%, #222 30%, #111 100%);
}

body.space-world .sun {
    background: radial-gradient(circle, #ff00ff 0%, #00ffff 100%);
}

/* Transition Effect */
.world-transition .game-container {
    filter: brightness(2) white-space(10);
    transition: filter 1s ease;
}

/* New Obstacles */
.obstacle.worm {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 20'%3E%3Cpath d='M5 10 Q10 5 15 10 T25 10' stroke='%23FF6B6B' stroke-width='4' fill='none'/%3E%3Ccircle cx='25' cy='10' r='2' fill='%23000'/%3E%3C/svg%3E");
    animation: wormWiggle 0.4s ease-in-out infinite;
}

.obstacle.zombie {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 40 60'%3E%3Crect x='10' y='20' width='20' height='30' fill='%23455a64'/%3E%3Ccircle cx='20' cy='15' r='10' fill='%238bc34a'/%3E%3Crect x='5' y='25' width='10' height='5' fill='%238bc34a'/%3E%3Crect x='25' y='25' width='10' height='5' fill='%238bc34a'/%3E%3Crect x='12' y='12' width='3' height='3' fill='white'/%3E%3Crect x='25' y='12' width='3' height='3' fill='white'/%3E%3C/svg%3E");
}

.obstacle.asteroid {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 45 36'%3E%3Cellipse cx='22' cy='18' rx='20' ry='16' fill='%23424242'/%3E%3Ccircle cx='15' cy='12' r='4' fill='%23212121'/%3E%3Ccircle cx='28' cy='22' r='3' fill='%23212121'/%3E%3C/svg%3E");
    animation: rotate 2s linear infinite;
}

.obstacle.alien {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 55'%3E%3Cellipse cx='15' cy='15' rx='12' ry='10' fill='%239c27b0'/%3E%3Crect x='12' y='25' width='6' height='20' fill='%237b1fa2'/%3E%3Cellipse cx='10' cy='12' rx='3' ry='5' fill='black'/%3E%3Cellipse cx='20' cy='12' rx='3' ry='5' fill='black'/%3E%3C/svg%3E");
}

.obstacle.fireball {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 45 36'%3E%3Cpath d='M40 18 Q30 0 10 18 Q30 36 40 18' fill='%23ff4500'/%3E%3Ccircle cx='30' cy='18' r='8' fill='%23ffd700'/%3E%3C/svg%3E");
    animation: flicker 0.2s infinite;
}

.obstacle.lava-monster {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 55'%3E%3Crect x='5' y='10' width='20' height='40' rx='10' fill='%238b0000'/%3E%3Ccircle cx='10' cy='20' r='3' fill='%23ff4500'/%3E%3Ccircle cx='20' cy='20' r='3' fill='%23ff4500'/%3E%3Cpath d='M10 35 Q15 40 20 35' stroke='%23ff4500' stroke-width='2' fill='none'/%3E%3C/svg%3E");
}

.obstacle.bat {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 45 30'%3E%3Cpath d='M5 15 Q15 5 22 15 Q30 5 40 15 L22 25 Z' fill='%232d3436'/%3E%3Ccircle cx='20' cy='15' r='1.5' fill='red'/%3E%3Ccircle cx='24' cy='15' r='1.5' fill='red'/%3E%3C/svg%3E");
    animation: birdFly 0.2s infinite;
}

@keyframes flicker {
    0%, 100% { filter: brightness(1) drop-shadow(0 0 5px orange); }
    50% { filter: brightness(1.3) drop-shadow(0 0 15px red); }
}

@keyframes wormWiggle {
    0%, 100% { transform: scaleX(1); }
    50% { transform: scaleX(0.8); }
}

@keyframes rotate {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

@keyframes run {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    50% { transform: translateY(-3px) rotate(-2deg); }
}

@keyframes jump {
    0% { transform: translateY(0) rotate(0deg); }
    30% { transform: translateY(-5px) rotate(-10deg); }
    50% { transform: translateY(-100px) rotate(5deg); }
    70% { transform: translateY(-50px) rotate(-5deg); }
    100% { transform: translateY(0) rotate(0deg); }
}

.obstacles-container,
.food-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

.obstacle {
    position: absolute;
    bottom: 30%;
    width: 45px;
    height: 40px;
    background-size: contain;
    background-repeat: no-repeat;
    animation: obstacleMove 0.5s linear infinite;
}

.obstacle.rock {
    width: 45px;
    height: 36px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 45 36'%3E%3Cellipse cx='22' cy='28' rx='20' ry='10' fill='%236B5344'/%3E%3Cellipse cx='22' cy='20' rx='18' ry='14' fill='%2376543C'/%3E%3Cellipse cx='15' cy='15' rx='6' ry='4' fill='%238B6953' opacity='0.6'/%3E%3Cellipse cx='30' cy='22' rx='5' ry='3' fill='%235d4a35' opacity='0.5'/%3E%3Cellipse cx='18' cy='25' rx='4' ry='3' fill='%235d4a35' opacity='0.4'/%3E%3C/svg%3E");
}

.obstacle.cactus {
    width: 30px;
    height: 55px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 55'%3E%3Cellipse cx='15' cy='50' rx='12' ry='8' fill='%232D3436'/%3E%3Crect x='12' y='10' width='6' height='40' rx='3' fill='%232E7D32'/%3E%3Cellipse cx='12' cy='25' rx='5' ry='12' fill='%232E7D32'/%3E%3Cellipse cx='18' cy='20' rx='4' ry='10' fill='%232E7D32'/%3E%3Cellipse cx='10' cy='15' rx='3' ry='6' fill='%232E7D32'/%3E%3Cellipse cx='12' cy='25' rx='4' ry='10' fill='%234CAF50'/%3E%3Cellipse cx='18' cy='20' rx='3' ry='8' fill='%234CAF50'/%3E%3Cellipse cx='10' cy='15' rx='2' ry='5' fill='%234CAF50'/%3E%3Ccircle cx='14' cy='18' r='1.5' fill='%231B5E20'/%3E%3Ccircle cx='16' cy='24' r='1.5' fill='%231B5E20'/%3E%3C/svg%3E");
}

.obstacle.bird {
    width: 45px;
    height: 30px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 45 30'%3E%3Cellipse cx='22' cy='15' rx='12' ry='8' fill='%234A4A4A'/%3E%3Cellipse cx='22' cy='14' rx='10' ry='6' fill='%235D5D5D'/%3E%3Ccircle cx='16' cy='13' r='2.5' fill='%232D3436'/%3E%3Ccircle cx='17' cy='12.5' r='1' fill='white'/%3E%3Cellipse cx='32' cy='14' rx='8' ry='3' fill='%234A4A4A'/%3E%3Cellipse cx='30' cy='12' rx='6' ry='2' fill='%235D5D5D'/%3E%3Cellipse cx='10' cy='16' rx='5' ry='3' fill='%234A4A4A'/%3E%3Cellipse cx='12' cy='17' rx='4' ry='2' fill='%235D5D5D'/%3E%3Cpath d='M22 18 Q25 22 28 18' stroke='%23FFD700' stroke-width='1.5' fill='none'/%3E%3C/svg%3E");
    animation: birdFly 0.3s ease-in-out infinite;
}

@keyframes obstacleMove {
    0%, 100% { transform: translateX(0); }
    50% { transform: translateX(-2px); }
}

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

.food {
    position: absolute;
    width: 35px;
    height: 35px;
    animation: foodBob 0.8s ease-in-out infinite;
    filter: drop-shadow(0 2px 3px rgba(0,0,0,0.2));
}

.food::before {
    content: '';
    position: absolute;
    width: 100%;
    height: 100%;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 35 35'%3E%3Cellipse cx='17' cy='20' rx='10' ry='12' fill='%23FF6B35'/%3E%3Cellipse cx='17' cy='18' rx='7' ry='8' fill='%23FF8C5A'/%3E%3Cpath d='M17 8 Q20 0 22 5' stroke='%234CAF50' stroke-width='3' fill='none'/%3E%3Cpath d='M17 8 Q14 2 12 6' stroke='%234CAF50' stroke-width='2' fill='none'/%3E%3Cellipse cx='14' cy='6' rx='3' ry='2' fill='%235DBB63'/%3E%3Ccircle cx='13' cy='16' r='2' fill='%23FFE4B5' opacity='0.6'/%3E%3C/svg%3E");
    background-size: contain;
    background-repeat: no-repeat;
}

@keyframes foodBob {
    0%, 100% { transform: translateY(0) rotate(-5deg); }
    50% { transform: translateY(-8px) rotate(5deg); }
}

.particles {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 20;
}

.particle {
    position: absolute;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    animation: particleFade 0.6s ease-out forwards;
}

@keyframes particleFade {
    0% { 
        transform: scale(1); 
        opacity: 1; 
    }
    100% { 
        transform: scale(0) translateY(-30px); 
        opacity: 0; 
    }
}

.overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 100;
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
}

.overlay.hidden {
    display: none;
}

.overlay-content {
    text-align: center;
    color: white;
    animation: slideIn 0.5s ease-out;
}

@keyframes slideIn {
    from { 
        opacity: 0; 
        transform: translateY(-30px); 
    }
    to { 
        opacity: 1; 
        transform: translateY(0); 
    }
}

.overlay-content h1 {
    font-size: 42px;
    margin-bottom: 20px;
    text-shadow: 0 4px 15px rgba(0,0,0,0.3);
}

.overlay-content h2 {
    font-size: 36px;
    margin-bottom: 20px;
    color: var(--accent-orange);
}

.instructions {
    font-size: 16px;
    margin-bottom: 30px;
    line-height: 1.8;
    color: #dfe6e9;
}

.instructions kbd {
    display: inline-block;
    background: rgba(255,255,255,0.2);
    padding: 4px 12px;
    border-radius: 6px;
    font-family: inherit;
    margin: 0 4px;
}

.final-score {
    font-size: 24px;
    margin-bottom: 10px;
}

.final-score span {
    color: var(--accent-orange);
    font-weight: 700;
}

.new-record {
    font-size: 20px;
    color: var(--accent-green);
    margin-bottom: 20px;
    animation: bounce 0.5s ease infinite;
}

.new-record.hidden {
    display: none;
}

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

.btn-start {
    background: linear-gradient(135deg, var(--accent-orange) 0%, #E85A24 100%);
    color: white;
    border: none;
    padding: 15px 50px;
    font-size: 20px;
    font-family: inherit;
    font-weight: 700;
    border-radius: 50px;
    cursor: pointer;
    box-shadow: 0 6px 20px rgba(255, 107, 53, 0.4);
    transition: all 0.3s ease;
}

.btn-start:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(255, 107, 53, 0.5);
}

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

@media (max-width: 1000px) {
    .game-wrapper {
        flex-direction: column;
        align-items: center;
        padding: 10px;
    }
    
    .score-panel {
        flex-direction: row;
        justify-content: center;
        width: 100%;
        max-width: 800px;
    }
    
    .score-box {
        flex: 1;
        max-width: 150px;
    }
    
    .btn-sound {
        padding: 15px 25px;
    }
}

@media (max-width: 850px) {
    .game-container {
        width: 95vw;
        height: 50vh;
        min-height: 300px;
        max-height: 400px;
    }
    
    .player {
        left: 40px;
        width: 50px;
        height: 50px;
    }
    
    .obstacle {
        width: 35px;
        height: 45px;
    }
    
    .obstacle.small {
        width: 25px;
        height: 30px;
    }
    
    .obstacle.tall {
        width: 30px;
        height: 55px;
    }
    
    .food {
        width: 30px;
        height: 30px;
    }
    
    .overlay-content h1 {
        font-size: 32px;
    }
    
    .overlay-content h2 {
        font-size: 28px;
    }
    
    .btn-start {
        padding: 12px 40px;
        font-size: 18px;
    }
}

@media (max-width: 500px) {
    .score-panel {
        gap: 10px;
    }
    
    .score-box {
        padding: 10px 15px;
    }
    
    .score-box .value {
        font-size: 24px;
    }
    
    .player {
        left: 20px;
        width: 40px;
        height: 40px;
    }
}

.game-footer {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
    padding: 20px;
    text-align: center;
    border-top: 2px solid rgba(255, 107, 53, 0.3);
}

.footer-content {
    max-width: 800px;
    margin: 0 auto;
}

.developer {
    color: white;
    font-size: 16px;
    margin-bottom: 5px;
}

.dev-icon {
    margin-right: 5px;
}

.developer strong {
    color: #FF6B35;
}

.dev-title {
    color: #a0a0a0;
    font-size: 13px;
    margin-bottom: 12px;
}

.contact-info {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 15px;
    margin-bottom: 15px;
}

.contact-link {
    color: #87CEEB;
    text-decoration: none;
    font-size: 13px;
    transition: color 0.3s ease;
}

.contact-link:hover {
    color: #FF6B35;
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 12px;
}

.license {
    color: #636e72;
    font-size: 12px;
    margin-bottom: 5px;
}

.copyright {
    color: #a0a0a0;
    font-size: 11px;
}

.copyright strong {
    color: #FF6B35;
}

@media (max-width: 600px) {
    .game-footer {
        padding: 15px 10px;
    }
    
    .contact-info {
        flex-direction: column;
        gap: 8px;
    }
    
    .developer {
        font-size: 14px;
    }
    
    .dev-title {
        font-size: 11px;
    }
}
