/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Orbitron', 'Arial', sans-serif;
    background: #000;
    color: #fff;
    overflow: hidden;
    height: 100vh;
    width: 100vw;
}

.hidden
{
    display: none;
}

/* Screen Management */
.screen {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    visibility: hidden;
    display: none;
    transition: all 1.5s ease-in-out;
}

.screen.active {
    opacity: 1;
    visibility: visible;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

/* Space Background */
.space-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(ellipse at center, #1a1a2e 0%, #16213e 35%, #0f0f23 100%);
    overflow: hidden;
}

/* Animated Stars */
.stars {
    position: absolute;
    width: 100%;
    height: 100%;
    background-image: 
        radial-gradient(2px 2px at 20px 30px, #eee, transparent),
        radial-gradient(2px 2px at 40px 70px, rgba(255,255,255,0.8), transparent),
        radial-gradient(1px 1px at 90px 40px, #fff, transparent),
        radial-gradient(1px 1px at 130px 80px, rgba(255,255,255,0.6), transparent),
        radial-gradient(2px 2px at 160px 30px, #ddd, transparent);
    background-repeat: repeat;
    background-size: 200px 100px;
    animation: twinkle 4s ease-in-out infinite alternate;
}

@keyframes twinkle {
    0% { opacity: 0.3; }
    100% { opacity: 1; }
}

/* Nebula Effect */
.nebula {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(ellipse 800px 400px at 20% 30%, rgba(138, 43, 226, 0.3) 0%, transparent 50%),
        radial-gradient(ellipse 600px 300px at 80% 70%, rgba(0, 191, 255, 0.2) 0%, transparent 50%),
        radial-gradient(ellipse 400px 200px at 50% 50%, rgba(255, 20, 147, 0.1) 0%, transparent 50%);
    animation: nebulaFloat 8s ease-in-out infinite;
}

@keyframes nebulaFloat {
    0%, 100% { transform: translate(0, 0) scale(1); }
    50% { transform: translate(-20px, -10px) scale(1.1); }
}

/* Galaxy Effect */
.galaxy {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 300px;
    height: 300px;
    background: 
        radial-gradient(circle, rgba(255, 255, 255, 0.1) 0%, transparent 70%),
        conic-gradient(from 0deg, transparent 0deg, rgba(138, 43, 226, 0.3) 60deg, transparent 120deg, rgba(0, 191, 255, 0.3) 180deg, transparent 240deg, rgba(255, 20, 147, 0.3) 300deg, transparent 360deg);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    animation: galaxyRotate 20s linear infinite;
}

@keyframes galaxyRotate {
    0% { transform: translate(-50%, -50%) rotate(0deg); }
    100% { transform: translate(-50%, -50%) rotate(360deg); }
}

/* SOFA Brand */
.sofa-brand {
    position: absolute;
    top: 20px;
    left: 20px;
    font-size: 14px;
    font-weight: 300;
    letter-spacing: 3px;
    color: rgba(255, 255, 255, 0.7);
    text-shadow: 0 0 10px rgba(0, 191, 255, 0.5);
    z-index: 10;
}

/* Intro Screen Styles */
.intro-content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    z-index: 5;
}

.game-title {
    font-size: clamp(3rem, 8vw, 6rem);
    font-weight: 900;
    letter-spacing: 8px;
    margin-bottom: 20px;
    background: linear-gradient(45deg, #00bfff, #8a2be2, #00ffff);
    background-size: 200% 200%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: titleGlow 3s ease-in-out infinite alternate, gradientShift 4s ease-in-out infinite;
    text-shadow: 0 0 30px rgba(0, 191, 255, 0.8);
}

.game-title.clickable {
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
}

.game-title.clickable:hover {
    transform: scale(1.05);
    text-shadow: 0 0 40px rgba(78, 205, 196, 1);
}

.game-title.clickable:active {
    transform: scale(0.98);
}

@keyframes titleGlow {
    0% { filter: brightness(1); }
    100% { filter: brightness(1.3); }
}

@keyframes gradientShift {
    0% { background-position: 0% 50%; }
    100% { background-position: 100% 50%; }
}

.subtitle {
    font-size: 1.2rem;
    font-weight: 300;
    letter-spacing: 2px;
    color: rgba(255, 255, 255, 0.8);
    margin-top: 20px;
    animation: subtitleFade 2s ease-in-out infinite alternate;
}

@keyframes subtitleFade {
    0% { opacity: 0.6; }
    100% { opacity: 1; }
}

.intro-overlay {
    position: absolute;
    bottom: 50px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 5;
}

.loading-text {
    font-size: 1rem;
    color: rgba(255, 255, 255, 0.6);
    letter-spacing: 1px;
    animation: pulse 2s ease-in-out infinite;
    cursor: pointer;
}

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

/* Main Menu Styles */
.menu-content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    z-index: 5;
}

.menu-title {
    font-size: clamp(2rem, 5vw, 3rem);
    font-weight: 700;
    letter-spacing: 4px;
    margin-bottom: 60px;
    color: #00bfff;
    text-shadow: 0 0 20px rgba(0, 191, 255, 0.6);
}

.menu-buttons {
    display: flex;
    flex-direction: column;
    gap: 30px;
    align-items: center;
    justify-content: center;
    margin-top: 50px;
}

.menu-btn {
    position: relative;
    background: linear-gradient(135deg, 
        rgba(25, 25, 112, 0.9) 0%,
        rgba(72, 61, 139, 0.9) 30%,
        rgba(138, 43, 226, 0.9) 70%,
        rgba(75, 0, 130, 0.9) 100%);
    border: 2px solid transparent;
    border-image: linear-gradient(45deg, #00bfff, #8a2be2, #4b0082) 1;
    color: #ffffff;
    padding: 25px 60px;
    font-size: 1.4rem;
    font-weight: 700;
    letter-spacing: 3px;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    overflow: hidden;
    width: 320px;
    backdrop-filter: blur(15px);
    border-radius: 15px;
    box-shadow: 
        0 8px 32px rgba(0, 0, 0, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.1),
        0 0 0 1px rgba(255, 255, 255, 0.05);
}

.menu-btn:hover {
    transform: translateY(-8px) scale(1.05);
    box-shadow: 
        0 15px 40px rgba(0, 191, 255, 0.4),
        0 5px 20px rgba(138, 43, 226, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.2),
        0 0 30px rgba(0, 191, 255, 0.6);
    background: linear-gradient(135deg, 
        rgba(0, 100, 200, 0.95) 0%,
        rgba(72, 61, 139, 0.95) 30%,
        rgba(138, 43, 226, 0.95) 70%,
        rgba(75, 0, 130, 0.95) 100%);
    border-image: linear-gradient(45deg, #00bfff, #8a2be2, #00ffff, #4b0082) 1;
}

.menu-btn:active {
    transform: translateY(-2px) scale(0.98);
    box-shadow: 
        0 5px 15px rgba(0, 191, 255, 0.3),
        inset 0 2px 4px rgba(0, 0, 0, 0.2);
}

.btn-text {
    position: relative;
    z-index: 2;
    transition: all 0.4s ease;
    text-shadow: 0 0 10px rgba(255, 255, 255, 0.5);
    font-family: 'Orbitron', 'Arial', sans-serif;
}

.menu-btn:hover .btn-text {
    color: #ffffff;
    text-shadow: 
        0 0 15px rgba(255, 255, 255, 0.8),
        0 0 30px rgba(0, 191, 255, 0.6),
        0 0 45px rgba(138, 43, 226, 0.4);
    transform: scale(1.05);
}

.btn-glow {
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, 
        transparent, 
        rgba(0, 191, 255, 0.4), 
        rgba(138, 43, 226, 0.3), 
        transparent);
    transition: left 0.6s ease;
}

.menu-btn:hover .btn-glow {
    left: 100%;
}

/* Звездные эффекты для кнопок */
.menu-btn::before {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    background: linear-gradient(45deg, 
        transparent, 
        rgba(0, 191, 255, 0.1), 
        transparent, 
        rgba(138, 43, 226, 0.1), 
        transparent);
    border-radius: 17px;
    opacity: 0;
    transition: opacity 0.4s ease;
    z-index: -1;
}

.menu-btn:hover::before {
    opacity: 1;
}

.menu-btn::after {
    content: '✦';
    position: absolute;
    top: 10px;
    right: 15px;
    color: rgba(255, 255, 255, 0.3);
    font-size: 1.2rem;
    opacity: 0;
    transform: scale(0);
    transition: all 0.4s ease;
    animation: starTwinkle 2s ease-in-out infinite;
}

.menu-btn:hover::after {
    opacity: 1;
    transform: scale(1);
}

@keyframes starTwinkle {
    0%, 100% { 
        opacity: 0.3;
        transform: scale(1) rotate(0deg);
    }
    50% { 
        opacity: 0.8;
        transform: scale(1.2) rotate(180deg);
    }
}

/* Мобильная адаптация для кнопок */
@media (max-width: 768px) {
    .menu-buttons {
        gap: 20px;
        margin-top: 30px;
    }
    
    .menu-btn {
        width: 280px;
        padding: 20px 50px;
        font-size: 1.2rem;
        letter-spacing: 2px;
    }
    
    .menu-btn:hover {
        transform: translateY(-4px) scale(1.02);
    }
    
    .menu-btn::after {
        top: 8px;
        right: 12px;
        font-size: 1rem;
    }
}

/* Modal Styles */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(10px);
    z-index: 1000;
    display: none;
    opacity: 0;
    transition: all 0.5s ease;
}

.modal.active {
    display: flex;
    opacity: 1;
    align-items: center;
    justify-content: center;
}

.modal-content {
    background: linear-gradient(135deg, rgba(0, 20, 40, 0.95) 0%, rgba(0, 40, 80, 0.95) 100%);
    border: 2px solid rgba(0, 191, 255, 0.6);
    border-radius: 15px;
    padding: 30px;
    max-width: 800px;
    max-height: 80vh;
    overflow-y: auto;
    position: relative;
    box-shadow: 
        0 0 50px rgba(0, 191, 255, 0.3),
        inset 0 0 50px rgba(0, 191, 255, 0.1);
    animation: modalSlideIn 0.5s ease-out;
}

@keyframes modalSlideIn {
    from {
        transform: translateY(-50px) scale(0.9);
        opacity: 0;
    }
    to {
        transform: translateY(0) scale(1);
        opacity: 1;
    }
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
    padding-bottom: 15px;
    border-bottom: 1px solid rgba(0, 191, 255, 0.3);
}

.modal-header h3 {
    color: #00bfff;
    font-size: 1.8rem;
    font-weight: 700;
    letter-spacing: 2px;
    text-shadow: 0 0 15px rgba(0, 191, 255, 0.6);
    margin: 0;
}

.close-btn {
    background: transparent;
    border: 2px solid rgba(0, 191, 255, 0.5);
    color: #00bfff;
    font-size: 1.5rem;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.close-btn:hover {
    background: rgba(0, 191, 255, 0.2);
    border-color: #00bfff;
    box-shadow: 0 0 15px rgba(0, 191, 255, 0.5);
}

.modal-body {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

/* Sound Controller Styles */
.sound-controller {
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(0, 191, 255, 0.3);
    border-radius: 10px;
    padding: 20px;
}

.sound-controller h4 {
    color: #00bfff;
    font-size: 1.3rem;
    font-weight: 600;
    letter-spacing: 1px;
    margin-bottom: 20px;
    text-shadow: 0 0 10px rgba(0, 191, 255, 0.5);
}

.sound-controls {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.control-group {
    display: flex;
    align-items: center;
    gap: 15px;
}

.control-group label {
    color: #fff;
    font-size: 1rem;
    font-weight: 500;
    min-width: 120px;
    text-shadow: 0 0 5px rgba(255, 255, 255, 0.3);
}

.control-group input[type="range"] {
    flex: 1;
    height: 6px;
    background: rgba(0, 191, 255, 0.2);
    border-radius: 3px;
    outline: none;
    -webkit-appearance: none;
    appearance: none;
}

.control-group input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 18px;
    height: 18px;
    background: #00bfff;
    border-radius: 50%;
    cursor: pointer;
    box-shadow: 0 0 10px rgba(0, 191, 255, 0.6);
    transition: all 0.3s ease;
}

.control-group input[type="range"]::-webkit-slider-thumb:hover {
    box-shadow: 0 0 15px rgba(0, 191, 255, 0.8);
    transform: scale(1.1);
}

.volume-value {
    color: #00bfff;
    font-weight: 600;
    min-width: 40px;
    text-align: right;
    text-shadow: 0 0 5px rgba(0, 191, 255, 0.5);
}

/* Game Information Styles */
.game-info {
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(0, 191, 255, 0.3);
    border-radius: 10px;
    padding: 20px;
}

.game-info h4 {
    color: #00bfff;
    font-size: 1.3rem;
    font-weight: 600;
    letter-spacing: 1px;
    margin-bottom: 20px;
    text-shadow: 0 0 10px rgba(0, 191, 255, 0.5);
}

.info-text {
    line-height: 1.8;
    color: rgba(255, 255, 255, 0.9);
}

.info-text p {
    margin-bottom: 20px;
    font-size: 1rem;
    text-align: justify;
    text-shadow: 0 0 5px rgba(255, 255, 255, 0.1);
}

.info-text p:first-child {
    font-weight: 600;
    color: #00bfff;
    text-shadow: 0 0 10px rgba(0, 191, 255, 0.3);
}

.info-text p:last-child {
    font-style: italic;
    color: rgba(0, 191, 255, 0.8);
    text-shadow: 0 0 8px rgba(0, 191, 255, 0.2);
}

/* Information Slides Styles */
#info-slides .space-background {
    background: #000 !important;
}

#info-slides .stars,
#info-slides .nebula {
    display: none;
}

.slide-content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    max-width: 900px;
    width: 90%;
    text-align: center;
    z-index: 5;
}

.slide {
    display: none;
    opacity: 0;
    transition: all 0.8s ease-in-out;
}

.slide.active {
    display: block !important;
    opacity: 1 !important;
}

.slide h2 {
    font-size: 3rem;
    font-weight: 700;
    letter-spacing: 4px;
    color: #00bfff;
    text-shadow: 0 0 30px rgba(0, 191, 255, 0.8);
    margin-bottom: 40px;
}

.slide-text {
    background: rgba(0, 0, 0, 0.6);
    border: 1px solid rgba(0, 191, 255, 0.3);
    border-radius: 15px;
    padding: 30px;
    margin-bottom: 30px;
    backdrop-filter: blur(10px);
}

.slide-text p {
    font-size: 1.4rem;
    line-height: 1.8;
    color: rgba(255, 255, 255, 0.95);
    margin-bottom: 25px;
    text-align: justify;
    text-shadow: 0 0 8px rgba(255, 255, 255, 0.2);
    font-weight: 400;
}

.next-btn {
    background: linear-gradient(45deg, #00bfff, #8a2be2);
    border: none;
    color: white;
    padding: 15px 40px;
    font-size: 1.1rem;
    font-weight: 600;
    letter-spacing: 2px;
    border-radius: 25px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 0 20px rgba(0, 191, 255, 0.4);
}

.next-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 0 30px rgba(0, 191, 255, 0.6);
}

/* Sun Game Styles */
#sun-game .space-background {
    background: #000 !important;
}

#sun-game .stars {
    display: none;
}

.sun-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    z-index: 5;
}

.sun {
    width: 80vh;
    height: 80vh;
    border-radius: 50%;
    background: radial-gradient(circle, #ff6b35 0%, #f7931e 30%, #ffd700 60%, #ff4500 100%);
    position: relative;
    margin: 0 auto;
    box-shadow: 
        0 0 50px rgba(255, 107, 53, 0.8),
        0 0 100px rgba(255, 107, 53, 0.4),
        inset 0 0 50px rgba(255, 215, 0, 0.3);
    animation: sunPulse 3s ease-in-out infinite;
}

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

.molecule {
    width: 20px;
    height: 20px;
    background: rgb(255, 0, 0);
    border-radius: 50%;
    position: absolute;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: rgba(255, 0, 0, 0.6) 0px 0px 10px;;
}

.molecule:hover {
    transform: scale(1.2);
    box-shadow: 0 0 15px rgba(0, 191, 255, 0.8);
}

.molecule.moving { animation: orbit1 2s linear infinite; }
.molecule.chaos { animation: chaos 0.3s linear infinite; }

@keyframes orbit1 {
    0% { transform: rotate(0deg) translateX(180px) rotate(0deg); }
    100% { transform: rotate(360deg) translateX(180px) rotate(-360deg); }
}

@keyframes chaos {
    0% { transform: translate(0, 0) rotate(0deg); }
    25% { transform: translate(50px, -30px) rotate(90deg); }
    50% { transform: translate(-30px, 50px) rotate(180deg); }
    75% { transform: translate(40px, 40px) rotate(270deg); }
    100% { transform: translate(-20px, -40px) rotate(360deg); }
}

.sun-instructions {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    text-align: center;
    color: #00bfff;
    text-shadow: 0 0 10px rgba(0, 191, 255, 0.6);
    z-index: 10;
    background: rgba(0, 0, 0, 0.8);
    padding: 15px 25px;
    border-radius: 8px;
    border: 2px solid rgba(0, 191, 255, 0.3);
    backdrop-filter: blur(5px);
    max-width: 80%;
    animation: instructionsFadeOut 6s ease-in-out forwards;
}

.sun-instructions h3 {
    font-size: 1.5rem;
    margin-bottom: 10px;
    letter-spacing: 1px;
}

.sun-instructions p {
    font-size: 1.1rem;
    opacity: 0.8;
}

.sun-comment {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    text-align: center;
    color: #fff;
    z-index: 10;
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.9), rgba(20, 20, 40, 0.9));
    padding: 25px 35px;
    border-radius: 15px;
    border: 3px solid rgba(255, 215, 0, 0.4);
    backdrop-filter: blur(10px);
    box-shadow: 
        0 0 25px rgba(255, 215, 0, 0.2),
        0 0 50px rgba(255, 215, 0, 0.1),
        inset 0 0 20px rgba(255, 215, 0, 0.1);
    max-width: 85%;
    opacity: 0;
    animation: commentFadeInOut 8s ease-in-out 6s forwards;
}

.sun-comment p {
    margin: 0;
    font-size: 19px;
    font-style: italic;
    line-height: 1.7;
    color: #f8f8f8;
    text-shadow: 
        0 0 15px rgba(255, 215, 0, 0.4),
        0 0 30px rgba(255, 215, 0, 0.2);
    font-weight: 400;
    letter-spacing: 0.5px;
}

@keyframes instructionsFadeOut {
    0% {
        opacity: 1;
    }
    80% {
        opacity: 1;
    }
    100% {
        opacity: 0;
    }
}

@keyframes commentFadeInOut {
    0% {
        opacity: 0;
        transform: translate(-50%, -50%) scale(0.8);
    }
    20% {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1);
    }
    80% {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1);
    }
    100% {
        opacity: 0;
        transform: translate(-50%, -50%) scale(0.8);
    }
}

/* Video Segment Styles */
.video-container {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 90%;
    max-width: 1000px;
    z-index: 5;
}

.video-wrapper {
    position: relative;
    width: 100%;
    height: 0;
    padding-bottom: 56.25%; /* 16:9 aspect ratio */
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 0 50px rgba(0, 191, 255, 0.3);
    border: 2px solid rgba(0, 191, 255, 0.5);
}

.video-wrapper iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border-radius: 15px;
}

.video-controls {
    text-align: center;
    margin-top: 30px;
}

/* Dialogue Box Styles */

.dialogue-box h3
{
    font-weight: 100;
}
.dialogue-box {
    position: absolute;
    display: flex;
    flex-direction: column;
    gap: 25px;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 0, 0, 0.95);
    border: 2px solid #4a90e2;
    border-radius: 15px;
    padding: 25px;
    max-width: 700px;
    width: 100%;
    box-shadow: 0 0 40px rgba(74, 144, 226, 0.6);
    backdrop-filter: blur(10px);
    z-index: 1000;
    text-align: left;
}

.character-name {
    color: #4a90e2;
    font-size: 18px;
    font-weight: bold;
    margin-bottom: 15px;
    text-shadow: 0 0 10px rgba(74, 144, 226, 0.5);
}

.dialogue-text {
    color: #fff;
    font-size: 16px;
    line-height: 1.6;
    margin-bottom: 20px;
}

.continue-btn {
    background: linear-gradient(45deg, #00bfff, #8a2be2);
    border: none;
    color: white;
    padding: 15px 40px;
    font-size: 1.1rem;
    font-weight: 600;
    letter-spacing: 2px;
    border-radius: 25px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 0 20px rgba(0, 191, 255, 0.4);
}

.continue-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 0 30px rgba(0, 191, 255, 0.6);
}

/* Solar Mass Ejection Styles */
#solar-ejection .space-background {
    background: #000 !important;
}

#solar-ejection .stars {
    display: none;
}

.solar-ejection-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 5;
}

.sun-ejection {
    position: relative;
    width: 450px;
    height: 450px;
    border-radius: 50%;
    background: radial-gradient(circle, #ff6b35 0%, #f7931e 30%, #ffd700 60%, #ff4500 100%);
    box-shadow: 
        0 0 50px rgba(255, 107, 53, 0.8),
        0 0 100px rgba(255, 107, 53, 0.4),
        inset 0 0 50px rgba(255, 215, 0, 0.3);
    animation: sunPulse 2s ease-in-out infinite;
    z-index: 10;
}

.sun-core {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 30px;
    height: 30px;
    background: #fff;
    border-radius: 50%;
    transform: translate(-50%, -50%);
    box-shadow: 0 0 30px rgba(255, 255, 255, 0.9);
    animation: coreIntensity 1s ease-in-out infinite alternate;
}

@keyframes coreIntensity {
    0% { 
        transform: translate(-50%, -50%) scale(1);
        box-shadow: 0 0 30px rgba(255, 255, 255, 0.9);
    }
    100% { 
        transform: translate(-50%, -50%) scale(1.3);
        box-shadow: 0 0 50px rgba(255, 255, 255, 1);
    }
}

.coronal-loops {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 400px;
    height: 400px;
    transform: translate(-50%, -50%);
    pointer-events: none;
}

.coronal-loops::before,
.coronal-loops::after {
    content: '';
    position: absolute;
    width: 2px;
    height: 100px;
    background: linear-gradient(to top, transparent, #ffd700, transparent);
    border-radius: 50px;
    animation: coronalLoop1 3s ease-in-out infinite;
}

.coronal-loops::before {
    top: 20%;
    left: 30%;
    transform: rotate(45deg);
    animation-delay: 0s;
}

.coronal-loops::after {
    top: 30%;
    right: 25%;
    transform: rotate(-30deg);
    animation-delay: 1.5s;
}

@keyframes coronalLoop1 {
    0%, 100% { 
        opacity: 0.3;
        transform: rotate(45deg) scaleY(1);
    }
    50% { 
        opacity: 1;
        transform: rotate(45deg) scaleY(1.5);
    }
}

.mass-ejection-particles {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 100%;
    height: 100%;
    transform: translate(-50%, -50%);
    pointer-events: none;
}

.mass-ejection-particles::before,
.mass-ejection-particles::after {
    content: '';
    position: absolute;
    width: 4px;
    height: 4px;
    background: #00bfff;
    border-radius: 50%;
    box-shadow: 0 0 10px rgba(0, 191, 255, 0.8);
    animation: particleEject 4s linear infinite;
}

.mass-ejection-particles::before {
    top: 20%;
    left: 60%;
    animation-delay: 0s;
}

.mass-ejection-particles::after {
    top: 40%;
    right: 20%;
    animation-delay: 2s;
}

@keyframes particleEject {
    0% {
        transform: translate(0, 0) scale(1);
        opacity: 1;
    }
    100% {
        transform: translate(300px, -200px) scale(0);
        opacity: 0;
    }
}

.radiation-waves {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border: 4px solid rgba(255, 0, 0, 0.9);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    animation: radiationPulse 1.2s ease-out infinite;
    z-index: 5;
}

.radiation-waves::before,
.radiation-waves::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border: 3px solid rgba(255, 0, 0, 0.7);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    animation: radiationPulse 1.2s ease-out infinite;
}

.radiation-waves::before {
    animation-delay: 0.4s;
}

.radiation-waves::after {
    animation-delay: 0.8s;
}

@keyframes radiationPulse {
    0% {
        width: 0;
        height: 0;
        opacity: 1;
    }
    100% {
        width: 1500px;
        height: 1500px;
        opacity: 0;
    }
}

.solar-wind {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(ellipse 200px 50px at 30% 40%, rgba(255, 255, 255, 0.1) 0%, transparent 50%),
        radial-gradient(ellipse 150px 30px at 70% 60%, rgba(255, 255, 255, 0.08) 0%, transparent 50%),
        radial-gradient(ellipse 180px 40px at 50% 30%, rgba(255, 255, 255, 0.06) 0%, transparent 50%);
    animation: solarWindFlow 4s ease-in-out infinite;
    pointer-events: none;
    z-index: 3;
}

@keyframes solarWindFlow {
    0%, 100% { 
        transform: translateX(0);
        opacity: 0.3;
    }
    50% { 
        transform: translateX(50px);
        opacity: 0.8;
    }
}

.ejection-info {
    position: absolute;
    bottom: 50px;
    left: 50%;
    transform: translateX(-50%);
    text-align: center;
    color: #00bfff;
    z-index: 15;
}

.ejection-info h3 {
    font-size: 1.8rem;
    font-weight: 700;
    letter-spacing: 2px;
    margin-bottom: 10px;
    text-shadow: 0 0 20px rgba(0, 191, 255, 0.6);
    animation: infoGlow 2s ease-in-out infinite alternate;
}

.ejection-info p {
    font-size: 1.1rem;
    opacity: 0.9;
    text-shadow: 0 0 10px rgba(0, 191, 255, 0.4);
}

@keyframes infoGlow {
    0% { text-shadow: 0 0 20px rgba(0, 191, 255, 0.6); }
    100% { text-shadow: 0 0 30px rgba(0, 191, 255, 0.9); }
}

.ejection-comment {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    text-align: center;
    color: #fff;
    z-index: 15;
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.9), rgba(40, 20, 20, 0.9));
    padding: 25px 35px;
    border-radius: 15px;
    border: 3px solid rgba(255, 100, 100, 0.4);
    backdrop-filter: blur(10px);
    box-shadow: 
        0 0 25px rgba(255, 100, 100, 0.2),
        0 0 50px rgba(255, 100, 100, 0.1),
        inset 0 0 20px rgba(255, 100, 100, 0.1);
    max-width: 85%;
    opacity: 0;
    animation: ejectionCommentFadeInOut 60s ease-in-out 0s forwards;
}

.ejection-comment p {
    margin: 0;
    font-size: 19px;
    font-style: italic;
    line-height: 1.7;
    color: #f8f8f8;
    text-shadow: 
        0 0 15px rgba(255, 100, 100, 0.4),
        0 0 30px rgba(255, 100, 100, 0.2);
    font-weight: 400;
    letter-spacing: 0.5px;
}

@keyframes ejectionCommentFadeInOut {
    0% {
        opacity: 0;
        transform: translateX(-50%) scale(0.8);
    }
    5% {
        opacity: 1;
        transform: translateX(-50%) scale(1);
    }
    95% {
        opacity: 1;
        transform: translateX(-50%) scale(1);
    }
    100% {
        opacity: 0;
        transform: translateX(-50%) scale(0.8);
    }
}

.radar-comment {
    position: absolute;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    text-align: center;
    color: #fff;
    z-index: 15;
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.9), rgba(20, 40, 20, 0.9));
    padding: 25px 35px;
    border-radius: 15px;
    border: 3px solid rgba(0, 255, 0, 0.4);
    backdrop-filter: blur(10px);
    box-shadow: 
        0 0 25px rgba(0, 255, 0, 0.2),
        0 0 50px rgba(0, 255, 0, 0.1),
        inset 0 0 20px rgba(0, 255, 0, 0.1);
    max-width: 85%;
    opacity: 0;
    animation: radarCommentFadeInOut 8s ease-in-out 3s forwards;
}

.radar-comment p {
    margin: 0;
    font-size: 19px;
    font-style: italic;
    line-height: 1.7;
    color: #f8f8f8;
    text-shadow: 
        0 0 15px rgba(0, 255, 0, 0.4),
        0 0 30px rgba(0, 255, 0, 0.2);
    font-weight: 400;
    letter-spacing: 0.5px;
}

@keyframes radarCommentFadeInOut {
    0% {
        opacity: 0;
        transform: translateX(-50%) scale(0.8);
    }
    20% {
        opacity: 1;
        transform: translateX(-50%) scale(1);
    }
    80% {
        opacity: 1;
        transform: translateX(-50%) scale(1);
    }
    100% {
        opacity: 0;
        transform: translateX(-50%) scale(0.8);
    }
}

/* Connection Lost Comment */
.connection-lost-comment {
    position: absolute;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    text-align: center;
    color: #fff;
    z-index: 20;
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.9), rgba(40, 20, 20, 0.9));
    padding: 30px 40px;
    border-radius: 15px;
    border: 3px solid rgba(255, 0, 0, 0.6);
    backdrop-filter: blur(10px);
    box-shadow: 
        0 0 30px rgba(255, 0, 0, 0.3),
        0 0 60px rgba(255, 0, 0, 0.1),
        inset 0 0 25px rgba(255, 0, 0, 0.1);
    max-width: 90%;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.8s ease-in-out, visibility 0.8s ease-in-out;
}

.connection-lost-comment.show {
    opacity: 1;
    visibility: visible;
}

.connection-lost-comment p {
    margin: 0;
    font-size: 22px;
    font-weight: bold;
    line-height: 1.6;
    color: #00bfff;
        text-shadow: 
        0 0 20px rgba(0, 191, 255, 0.6),
        0 0 40px rgba(0, 191, 255, 0.3);
    font-family: 'Arial', sans-serif;
    letter-spacing: 0.5px;
}

/* Connection Restored Comment */
.connection-restored-comment {
    position: absolute;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    text-align: center;
    color: #fff;
    z-index: 20;
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.9), rgba(20, 40, 20, 0.9));
    padding: 30px 40px;
    border-radius: 15px;
    border: 3px solid rgba(0, 255, 0, 0.6);
    backdrop-filter: blur(10px);
    box-shadow: 
        0 0 30px rgba(0, 255, 0, 0.3),
        0 0 60px rgba(0, 255, 0, 0.1),
        inset 0 0 25px rgba(0, 255, 0, 0.1);
    max-width: 90%;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.8s ease-in-out, visibility 0.8s ease-in-out;
}

.connection-restored-comment.show {
    opacity: 1;
    visibility: visible;
}

.connection-restored-comment p {
    margin: 0;
    font-size: 22px;
    font-weight: bold;
    line-height: 1.6;
    color: #44ff44;
    text-shadow: 
        0 0 20px rgba(0, 255, 0, 0.6),
        0 0 40px rgba(0, 255, 0, 0.3);
    font-family: 'Arial', sans-serif;
    letter-spacing: 0.5px;
}

.calculator-comment {
    position: absolute;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    text-align: center;
    color: #fff;
    z-index: 15;
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.9), rgba(20, 40, 20, 0.9));
    padding: 25px 35px;
    border-radius: 15px;
    border: 3px solid rgba(0, 255, 0, 0.4);
    backdrop-filter: blur(10px);
    box-shadow: 
        0 0 25px rgba(0, 255, 0, 0.2),
        0 0 50px rgba(0, 255, 0, 0.1),
        inset 0 0 20px rgba(0, 255, 0, 0.1);
    max-width: 85%;
    opacity: 0;
    animation: calculatorCommentFadeInOut 8s ease-in-out 2s forwards;
}

.calculator-comment p {
    margin: 0;
    font-size: 19px;
    font-style: italic;
    line-height: 1.7;
    color: #f8f8f8;
    text-shadow: 
        0 0 15px rgba(0, 255, 0, 0.4),
        0 0 30px rgba(0, 255, 0, 0.2);
    font-weight: 400;
    letter-spacing: 0.5px;
}

@keyframes calculatorCommentFadeInOut {
    0% {
        opacity: 0;
        transform: translateX(-50%) scale(0.8);
    }
    20% {
        opacity: 1;
        transform: translateX(-50%) scale(1);
    }
    80% {
        opacity: 1;
        transform: translateX(-50%) scale(1);
    }
    100% {
        opacity: 0;
        transform: translateX(-50%) scale(0.8);
    }
}


/* CSS Spacecraft */
.spacecraft {
    position: absolute;
    top: 40%;
    right: 10%;
    width: 300px;
    height: 180px;
    z-index: 8;
    animation: spacecraftFloat 4s ease-in-out infinite;
}

.spacecraft-image {
    width: 100%;
    height: 100%;
    object-fit: contain;
    filter: drop-shadow(0 0 15px rgba(255, 100, 0, 0.6));
    animation: spacecraftGlow 3s ease-in-out infinite alternate;
}

.spacecraft-body {
    position: relative;
    width: 100%;
    height: 100%;
}

.craft-core {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 60px;
    height: 30px;
    background: linear-gradient(135deg, #2a2a2a, #4a4a4a, #2a2a2a);
    border-radius: 15px;
    transform: translate(-50%, -50%);
    box-shadow: 
        0 0 20px rgba(0, 191, 255, 0.4),
        inset 0 0 15px rgba(255, 255, 255, 0.1);
    border: 2px solid rgba(0, 191, 255, 0.6);
}

.craft-wings {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 100%;
    height: 100%;
    transform: translate(-50%, -50%);
}

.wing {
    position: absolute;
    top: 50%;
    width: 25px;
    height: 15px;
    background: linear-gradient(135deg, #1a1a1a, #3a3a3a);
    border: 1px solid rgba(0, 191, 255, 0.4);
    border-radius: 8px;
    transform: translateY(-50%);
    box-shadow: 0 0 10px rgba(0, 191, 255, 0.3);
}

.wing-left {
    left: -15px;
    transform: translateY(-50%) rotate(-20deg);
}

.wing-right {
    right: -15px;
    transform: translateY(-50%) rotate(20deg);
}

.craft-lights {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 100%;
    height: 100%;
    transform: translate(-50%, -50%);
}

.craft-light {
    position: absolute;
    width: 4px;
    height: 4px;
    background: #00bfff;
    border-radius: 50%;
    box-shadow: 0 0 8px rgba(0, 191, 255, 0.8);
    animation: craftLightBlink 2s ease-in-out infinite;
}

.craft-light:nth-child(1) {
    top: 20%;
    left: 30%;
    animation-delay: 0s;
}

.craft-light:nth-child(2) {
    top: 70%;
    right: 25%;
    animation-delay: 0.7s;
}

.craft-light:nth-child(3) {
    top: 50%;
    left: 70%;
    animation-delay: 1.4s;
}

@keyframes craftLightBlink {
    0%, 100% { 
        opacity: 0.4;
        transform: scale(1);
    }
    50% { 
        opacity: 1;
        transform: scale(1.3);
    }
}

.spacecraft-shield {
    position: absolute;
    top: -10px;
    left: -10px;
    right: -10px;
    bottom: -10px;
    border: 2px solid rgba(0, 191, 255, 0.3);
    border-radius: 50%;
    animation: shieldPulse 2s ease-in-out infinite;
    pointer-events: none;
}

@keyframes spacecraftFloat {
    0%, 100% { 
        transform: translateY(0) rotate(0deg);
    }
    50% { 
        transform: translateY(-10px) rotate(1deg);
    }
}

@keyframes spacecraftGlow {
    0% { 
        filter: drop-shadow(0 0 20px rgba(0, 191, 255, 0.6));
    }
    100% { 
        filter: drop-shadow(0 0 30px rgba(0, 191, 255, 0.9));
    }
}

@keyframes shieldPulse {
    0%, 100% { 
        opacity: 0.3;
        transform: scale(1);
    }
    50% { 
        opacity: 0.8;
        transform: scale(1.1);
    }
}

/* Spacecraft interaction with radiation */
.spacecraft:hover {
    animation: spacecraftShake 0.3s ease-in-out infinite;
}

@keyframes spacecraftShake {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    25% { transform: translateY(-3px) rotate(0.5deg); }
    75% { transform: translateY(3px) rotate(-0.5deg); }
}

@keyframes spacecraftGlow {
    0% { 
        filter: drop-shadow(0 0 15px rgba(255, 100, 0, 0.6));
        transform: scale(1);
    }
    100% { 
        filter: drop-shadow(0 0 25px rgba(255, 100, 0, 0.9));
        transform: scale(1.02);
    }
}

@keyframes satelliteGlow {
    0% { 
        filter: drop-shadow(0 0 20px rgba(0, 191, 255, 0.6));
        transform: scale(1);
    }
    100% { 
        filter: drop-shadow(0 0 30px rgba(0, 191, 255, 0.9));
        transform: scale(1.02);
    }
}

.cloud-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10;
    display: flex;
    justify-content: center;
    align-items: center;
}

.cloud-overlay-image {
    width: 100%;
    max-width: 500px;
    height: auto;
    object-fit: contain;
    opacity: 0.7;
    mix-blend-mode: screen;
    filter: drop-shadow(0 0 20px rgba(255, 255, 255, 0.3));
}

/* Radar Scene */
#radar-scene .space-background {
    background: #000 !important;
}

#radar-scene .stars {
    display: none;
}

.radar-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 5;
}

/* Damage indicators */
.radar-cracks {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.5s ease;
}

.radar-cracks.visible {
    opacity: 1;
}

.crack {
    position: absolute;
    background: linear-gradient(45deg, #00bfff, #4a90e2);
    border-radius: 2px;
    box-shadow: 0 0 10px rgba(0, 191, 255, 0.5);
}

.crack-1 {
    top: 20%;
    left: 10%;
    width: 60%;
    height: 3px;
    transform: rotate(15deg);
}

.crack-2 {
    top: 60%;
    left: 30%;
    width: 40%;
    height: 2px;
    transform: rotate(-25deg);
}

.crack-3 {
    top: 40%;
    left: 5%;
    width: 50%;
    height: 2px;
    transform: rotate(45deg);
}

/* Warning lights */
.warning-lights {
    position: absolute;
    top: 10px;
    right: 10px;
    display: flex;
    gap: 10px;
    opacity: 0;
    transition: opacity 0.5s ease;
}

.warning-lights.active {
    opacity: 1;
}

.warning-light {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: #00bfff;
    box-shadow: 0 0 15px rgba(0, 191, 255, 0.8);
    animation: warningBlink 1s infinite;
}

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

/* Repair button */
.repair-btn {
    background: linear-gradient(145deg, #ff6b6b, #ff5252) !important;
    border: 2px solid rgba(255, 107, 107, 0.8) !important;
    box-shadow: 0 0 20px rgba(255, 107, 107, 0.4) !important;
    animation: repairPulse 2s infinite;
}

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

.radar-screen {
    position: relative;
    width: 500px;
    height: 500px;
    border: 3px solid #00ff00;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(0, 255, 0, 0.1), rgba(0, 0, 0, 0.9));
    box-shadow: 
        0 0 50px rgba(0, 255, 0, 0.5),
        inset 0 0 50px rgba(0, 255, 0, 0.2);
    overflow: hidden;
}

.radar-screen.disrupted {
    border-color: #00bfff;
    background: radial-gradient(circle, rgba(255, 0, 0, 0.1), rgba(0, 0, 0, 0.9));
    box-shadow: 
        0 0 50px rgba(255, 0, 0, 0.5),
        inset 0 0 50px rgba(255, 0, 0, 0.2);
    animation: radarDisruption 0.5s ease-in-out infinite;
}

.radar-screen.restoring {
    border-color: #00ff00;
    background: radial-gradient(circle, rgba(0, 255, 0, 0.1), rgba(0, 0, 0, 0.9));
    box-shadow: 
        0 0 50px rgba(0, 255, 0, 0.5),
        inset 0 0 50px rgba(0, 255, 0, 0.2);
    animation: radarRestoration 2s ease-in-out;
}

@keyframes radarRestoration {
    0% {
        border-color: #00bfff;
        box-shadow: 
            0 0 50px rgba(0, 191, 255, 0.5),
            inset 0 0 50px rgba(255, 0, 0, 0.2);
    }
    50% {
        border-color: #ffff00;
        box-shadow: 
            0 0 50px rgba(255, 255, 0, 0.5),
            inset 0 0 50px rgba(255, 255, 0, 0.2);
    }
    100% {
        border-color: #00ff00;
        box-shadow: 
            0 0 50px rgba(0, 255, 0, 0.5),
            inset 0 0 50px rgba(0, 255, 0, 0.2);
    }
}

@keyframes radarDisruption {
    0%, 100% { 
        opacity: 1;
        transform: scale(1);
    }
    50% { 
        opacity: 0.7;
        transform: scale(1.02);
    }
}

/* Radar Grid */
.radar-grid {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.grid-circle {
    position: absolute;
    top: 50%;
    left: 50%;
    border: 1px solid rgba(0, 255, 0, 0.3);
    border-radius: 50%;
    transform: translate(-50%, -50%);
}

.grid-1 {
    width: 100px;
    height: 100px;
}

.grid-2 {
    width: 200px;
    height: 200px;
}

.grid-3 {
    width: 300px;
    height: 300px;
}

.grid-line {
    position: absolute;
    background: rgba(0, 255, 0, 0.3);
}

.grid-line-1 {
    top: 50%;
    left: 0;
    width: 100%;
    height: 1px;
    transform: translateY(-50%);
}

.grid-line-2 {
    top: 0;
    left: 50%;
    width: 1px;
    height: 100%;
    transform: translateX(-50%);
}

.grid-line-3 {
    top: 50%;
    left: 0;
    width: 100%;
    height: 1px;
    transform: translateY(-50%) rotate(45deg);
}

.grid-line-4 {
    top: 50%;
    left: 0;
    width: 100%;
    height: 1px;
    transform: translateY(-50%) rotate(-45deg);
}

/* Radar Sweep */
.radar-sweep {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 2px;
    height: 250px;
    background: linear-gradient(to bottom, #00ff00, transparent);
    transform-origin: bottom center;
    transform: translate(-50%, -100%);
    animation: radarSweep 3s linear infinite;
    z-index: 3;
}

@keyframes radarSweep {
    0% { transform: translate(-50%, -100%) rotate(0deg); }
    100% { transform: translate(-50%, -100%) rotate(360deg); }
}

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

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

/* Chapter Conclusion Styles */
.conclusion-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    padding: 40px 20px;
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
}

.conclusion-title {
    font-size: clamp(2.5rem, 6vw, 4rem);
    font-weight: 900;
    color: #4ecdc4;
    margin-bottom: 40px;
    text-shadow: 0 0 20px rgba(78, 205, 196, 0.7);
}

.completion-message {
    background: rgba(15, 23, 42, 0.8);
    border: 2px solid rgba(78, 205, 196, 0.3);
    border-radius: 20px;
    padding: 40px;
    margin-bottom: 40px;
    backdrop-filter: blur(10px);
}

.completion-message p {
    font-size: 18px;
    color: #fff;
    margin-bottom: 20px;
    line-height: 1.6;
}

.achievements-list {
    list-style: none;
    padding: 0;
    margin: 20px 0;
}

.achievements-list li {
    font-size: 16px;
    color: #4ecdc4;
    margin: 10px 0;
    padding: 10px;
    background: rgba(78, 205, 196, 0.1);
    border-radius: 10px;
    border-left: 4px solid #4ecdc4;
}

.next-adventure {
    font-size: 20px;
    font-weight: bold;
    color: #ffd700;
    margin-top: 30px;
}

.conclusion-buttons {
    display: flex;
    gap: 20px;
    justify-content: center;
}

.conclusion-buttons button {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 15px 30px;
    border: none;
    border-radius: 10px;
    font-size: 16px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.menu-btn {
    background: linear-gradient(45deg, #4a90e2, #0066cc);
    color: white;
}

.chapter-btn {
    background: linear-gradient(45deg, #4ecdc4, #44a08d);
    color: white;
}

.next-btn {
    background: linear-gradient(45deg, #ffd700, #ffed4e);
    color: #333;
}

.conclusion-buttons button:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
}

.btn-icon {
    font-size: 20px;
}

/* Satellite Interior & Calculator Styles */
.satellite-interior-container {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    padding: 20px;
}

.interior-panel {
    background: rgba(15, 23, 42, 0.95);
    border: 2px solid rgba(78, 205, 196, 0.5);
    border-radius: 20px;
    padding: 40px;
    max-width: 800px;
    width: 100%;
    backdrop-filter: blur(15px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.5);
    position: relative;
}

.panel-header {
    text-align: center;
    margin-bottom: 30px;
}

.panel-header h3 {
    color: #4ecdc4;
    font-size: 24px;
    margin-bottom: 10px;
    text-shadow: 0 0 10px rgba(78, 205, 196, 0.7);
}

.panel-subtitle {
    color: rgba(255, 255, 255, 0.8);
    font-size: 16px;
}

.calculator-section {
    display: flex;
    gap: 30px;
    align-items: flex-start;
}

.calculator {
    flex: 1;
    background: rgba(0, 0, 0, 0.6);
    border: 1px solid rgba(78, 205, 196, 0.3);
    border-radius: 15px;
    padding: 20px;
}

.calculator-display {
    background: rgba(0, 0, 0, 0.8);
    color: #00ff00;
    font-family: 'Courier New', monospace;
    font-size: 24px;
    font-weight: bold;
    text-align: right;
    padding: 15px;
    margin-bottom: 15px;
    border: 1px solid rgba(0, 255, 0, 0.3);
    border-radius: 8px;
    min-height: 30px;
    display: flex;
    align-items: center;
    justify-content: flex-end;
}

.password-input-field {
    margin-bottom: 15px;
}

.password-input {
    width: 100%;
    background: rgba(0, 0, 0, 0.8);
    color: #4ecdc4;
    border: 1px solid rgba(78, 205, 196, 0.3);
    border-radius: 8px;
    padding: 10px;
    font-size: 16px;
    text-align: center;
    font-family: 'Courier New', monospace;
}

.status-indicators {
    display: flex;
    gap: 5px;
    margin-bottom: 20px;
    justify-content: center;
}

.indicator {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(255, 107, 107, 0.3);
    transition: all 0.3s ease;
}

.indicator.active {
    background: #4ecdc4;
    box-shadow: 0 0 10px rgba(78, 205, 196, 0.7);
}

.calculator-buttons {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    margin-bottom: 15px;
}

.control-buttons {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 10px;
}

.calc-btn {
    background: linear-gradient(45deg, #4ecdc4, #44a08d);
    border: none;
    color: white;
    font-size: 18px;
    font-weight: bold;
    padding: 15px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
}

.calc-btn:hover {
    background: linear-gradient(45deg, #5ed8d1, #54b09d);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(78, 205, 196, 0.4);
}

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

.calc-btn#clear-btn {
    background: linear-gradient(45deg, #4a90e2, #0066cc);
}

.calc-btn#enter-btn {
    background: linear-gradient(45deg, #2ecc71, #27ae60);
}

.code-sheet {
    flex: 1;
    background: rgba(0, 0, 0, 0.6);
    border: 1px solid rgba(78, 205, 196, 0.3);
    border-radius: 15px;
    padding: 20px;
    text-align: center;
}

.sheet-header h4 {
    color: #4ecdc4;
    font-size: 18px;
    margin-bottom: 20px;
}

.code-display {
    display: flex;
    justify-content: center;
    gap: 5px;
    margin-bottom: 20px;
}

.code-digit {
    background: rgba(78, 205, 196, 0.2);
    color: #4ecdc4;
    font-size: 20px;
    font-weight: bold;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 5px;
    border: 1px solid rgba(78, 205, 196, 0.5);
}

.code-hint p {
    color: #ffd700;
    font-size: 14px;
    font-style: italic;
}

.feedback-overlay {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(0, 0, 0, 0.9);
    border: 2px solid;
    border-radius: 15px;
    padding: 30px;
    text-align: center;
    z-index: 1000;
    animation: feedbackAppear 0.5s ease-in-out;
}

.feedback-overlay.success {
    border-color: #2ecc71;
}

.feedback-overlay.error {
    border-color: #e74c3c;
}

.feedback-icon {
    font-size: 48px;
    margin-bottom: 15px;
}

.feedback-text {
    color: white;
    font-size: 18px;
    font-weight: bold;
}

@keyframes feedbackAppear {
    0% {
        opacity: 0;
        transform: translate(-50%, -50%) scale(0.8);
    }
    100% {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1);
    }
}

.connection-lost-message {
    position: absolute;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(255, 107, 107, 0.9);
    color: white;
    padding: 15px 30px;
    border-radius: 10px;
    font-weight: bold;
    text-align: center;
    z-index: 100;
    animation: warningPulse 2s infinite;
}

@keyframes warningPulse {
    0%, 100% { opacity: 0.8; }
    50% { opacity: 1; }
}

/* Astronaut Scene Styles */
.nasa-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.nasa-background-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: brightness(0.3) contrast(1.2);
}

.astronaut-container {
    position: relative;
    z-index: 10;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    min-height: 100vh;
    padding: 40px 20px 80px;
    max-width: 1000px;
    margin: 0 auto;
    overflow-y: auto;
}

.astronaut-image {
    width: 300px;
    height: 400px;
    object-fit: contain;
    margin-bottom: 40px;
    filter: drop-shadow(0 10px 30px rgba(78, 205, 196, 0.3));
    animation: astronautFloat 6s ease-in-out infinite;
}

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

.astronaut-text {
    background: rgba(15, 23, 42, 0.9);
    border: 2px solid rgba(78, 205, 196, 0.5);
    border-radius: 20px;
    padding: 30px;
    margin-bottom: 20px;
    backdrop-filter: blur(15px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.5);
    text-align: center;
    max-width: 600px;
    animation: textSlideUp 1.5s ease-in-out both;
}

.astronaut-text h3 {
    color: #fff;
    font-size: 18px;
    line-height: 1.6;
    margin-bottom: 20px;
    font-weight: 400;
}

.astronaut-quiz {
    background: rgba(15, 23, 42, 0.9);
    border: 2px solid rgba(255, 215, 0, 0.5);
    border-radius: 20px;
    padding: 30px;
    margin-bottom: 20px;
    backdrop-filter: blur(15px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.5);
    text-align: center;
    max-width: 600px;
    animation: textSlideUp 1.5s ease-in-out both;
}

.astronaut-quiz h3 {
    color: #ffd700;
    font-size: 20px;
    margin-bottom: 15px;
    text-shadow: 0 0 10px rgba(255, 215, 0, 0.7);
}

.astronaut-quiz p {
    color: #fff;
    font-size: 16px;
    margin-bottom: 25px;
    font-style: italic;
}

.quiz-options {
    display: flex;
    flex-direction: column;
    gap: 15px;
    align-items: center;
}

.quiz-btn {
    background: linear-gradient(45deg, #4ecdc4, #44a08d);
    border: none;
    color: white;
    font-size: 16px;
    font-weight: bold;
    padding: 15px 25px;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s ease;
    width: 100%;
    max-width: 400px;
    text-align: center;
}

.quiz-btn:hover {
    background: linear-gradient(45deg, #5ed8d1, #54b09d);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(78, 205, 196, 0.4);
}

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

.quiz-btn:disabled {
    background: linear-gradient(45deg, #666, #555);
    cursor: not-allowed;
    opacity: 0.6;
    transform: none;
}

.quiz-btn:disabled:hover {
    background: linear-gradient(45deg, #666, #555);
    transform: none;
    box-shadow: none;
}

.astronaut-feedback {
    position: absolute;

    background: rgba(15, 23, 42, 0.9);
    border: 2px solid rgba(46, 204, 113, 0.5);
    border-radius: 20px;
    /* padding: 30px; */
    /* margin-bottom: 20px; */
    backdrop-filter: blur(15px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.5);
    text-align: center;
    max-width: 600px;
    animation: textSlideUp 1.5s ease-in-out both;
    position: relative;
    z-index: 1000;
    /* margin-left: auto;
    margin-right: auto;
    margin-top: 20px; */
}

.astronaut-feedback h3 {
    color: #2ecc71;
    font-size: 18px;
    line-height: 1.6;
    margin-bottom: 20px;
    text-shadow: 0 0 10px rgba(46, 204, 113, 0.7);
}

.next-btn {
    background: linear-gradient(45deg, #ffd700, #ffed4e);
    border: none;
    color: #333;
    font-size: 16px;
    font-weight: bold;
    padding: 15px 30px;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
    box-shadow: 0 5px 15px rgba(255, 215, 0, 0.3);
}

.next-btn:hover {
    background: linear-gradient(45deg, #ffff00, #ffed4e);
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(255, 215, 0, 0.5);
}

.next-btn:active {
    transform: translateY(-1px);
}

/* Final Test Styles */
.final-test-container {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    padding: 40px 20px;
}

.final-test-panel {
    background: rgba(15, 23, 42, 0.95);
    border: 2px solid rgba(255, 215, 0, 0.6);
    border-radius: 25px;
    padding: 40px;
    max-width: 700px;
    width: 100%;
    backdrop-filter: blur(15px);
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.6);
    text-align: center;
    position: relative;
}

.test-header {
    margin-bottom: 30px;
}

.test-title {
    font-size: clamp(2rem, 5vw, 3rem);
    font-weight: 900;
    color: #ffd700;
    margin-bottom: 15px;
    text-shadow: 0 0 20px rgba(255, 215, 0, 0.7);
    animation: titleGlow 3s ease-in-out infinite alternate;
}

.test-subtitle {
    color: rgba(255, 255, 255, 0.8);
    font-size: 18px;
    font-style: italic;
}

.test-question {
    margin-bottom: 30px;
}

.test-question h3 {
    color: #fff;
    font-size: 20px;
    line-height: 1.6;
    margin-bottom: 25px;
    font-weight: 400;
}

.test-options {
    display: flex;
    flex-direction: column;
    gap: 15px;
    align-items: center;
}

.final-test-btn {
    background: linear-gradient(45deg, #4ecdc4, #44a08d);
    border: none;
    color: white;
    font-size: 16px;
    font-weight: bold;
    padding: 18px 30px;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    width: 100%;
    max-width: 500px;
    text-align: left;
    position: relative;
}

.final-test-btn:hover {
    background: linear-gradient(45deg, #5ed8d1, #54b09d);
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(78, 205, 196, 0.4);
}

.final-test-btn:active {
    transform: translateY(-1px);
}

.final-test-btn:disabled {
    background: linear-gradient(45deg, #666, #555);
    cursor: not-allowed;
    opacity: 0.6;
    transform: none;
}

.final-test-btn:disabled:hover {
    background: linear-gradient(45deg, #666, #555);
    transform: none;
    box-shadow: none;
}

.final-test-feedback {
    background: rgba(15, 23, 42, 0.9);
    border: 2px solid rgba(46, 204, 113, 0.5);
    border-radius: 20px;
    padding: 30px;
    backdrop-filter: blur(15px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.5);
    text-align: center;
    animation: textSlideUp 1.5s ease-in-out both;
}

.final-test-feedback h3 {
    color: #2ecc71;
    font-size: 18px;
    line-height: 1.6;
    margin-bottom: 20px;
    text-shadow: 0 0 10px rgba(46, 204, 113, 0.7);
}

/* Calculator Mobile Styles */
@media (max-width: 768px) {
    .satellite-interior-container {
        padding: 10px;
    }
    
    .interior-panel {
        padding: 20px;
    }
    
    .calculator-section {
        flex-direction: column;
        gap: 20px;
    }
    
    .calculator, .code-sheet {
        flex: none;
    }
    
    .calc-btn {
        padding: 12px;
        font-size: 16px;
    }
    
    .calculator-display {
        font-size: 20px;
        padding: 12px;
    }
    
    .panel-header h3 {
        font-size: 20px;
    }
    
    .feedback-overlay {
        padding: 20px;
        margin: 0 20px;
    }
    
    .feedback-icon {
        font-size: 36px;
    }
    
    .feedback-text {
        font-size: 16px;
    }
}

/* Astronaut Scene Mobile Styles */
@media (max-width: 768px) {
    .astronaut-container {
        padding: 20px 10px 60px;
        justify-content: flex-start;
    }
    
    .astronaut-image {
        width: 250px;
        height: 320px;
        margin-bottom: 30px;
    }
    
    .astronaut-text, .astronaut-quiz, .astronaut-feedback {
        padding: 20px;
        margin-bottom: 15px;
    }
    
    .astronaut-text h3 {
        font-size: 16px;
    }
    
    .astronaut-quiz h3 {
        font-size: 18px;
    }
    
    .astronaut-quiz p {
        font-size: 14px;
    }
    
    .quiz-btn {
        padding: 12px 20px;
        font-size: 14px;
    }
    
    .next-btn {
        padding: 12px 25px;
        font-size: 14px;
    }
}

/* Final Test Mobile Styles */
@media (max-width: 768px) {
    .final-test-container {
        padding: 20px 10px;
    }
    
    .final-test-panel {
        padding: 25px;
    }
    
    .test-title {
        font-size: 1.8rem;
    }
    
    .test-question h3 {
        font-size: 16px;
    }
    
    .final-test-btn {
        padding: 15px 20px;
        font-size: 14px;
    }
    
    .final-test-feedback {
        padding: 20px;
    }
    
    .final-test-feedback h3 {
        font-size: 16px;
    }
}

.radar-sweep.disrupted {
    animation: radarSweepDisrupted 0.2s ease-in-out infinite;
}

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

/* Radar Targets */
.radar-targets {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 2;
}

.target {
    position: absolute;
    width: 8px;
    height: 8px;
    background: #00ff00;
    border-radius: 50%;
    box-shadow: 0 0 10px rgba(0, 255, 0, 0.8);
    animation: targetBlink 2s ease-in-out infinite;
}

.target-1 {
    top: 30%;
    left: 40%;
    animation-delay: 0s;
}

.target-2 {
    top: 60%;
    left: 70%;
    animation-delay: 0.5s;
}

.target-3 {
    top: 20%;
    left: 80%;
    animation-delay: 1s;
}

.target-4 {
    top: 70%;
    left: 30%;
    animation-delay: 1.5s;
}

@keyframes targetBlink {
    0%, 100% { 
        opacity: 0.6;
        transform: scale(1);
    }
    50% { 
        opacity: 1;
        transform: scale(1.2);
    }
}

.target.disrupted {
    background: #00bfff;
    box-shadow: 0 0 10px rgba(255, 0, 0, 0.8);
    animation: targetDisrupted 0.3s ease-in-out infinite;
}

.target.restoring {
    background: #00ff00;
    box-shadow: 0 0 10px rgba(0, 255, 0, 0.8);
    animation: targetRestoration 1s ease-in-out;
}

@keyframes targetRestoration {
    0% {
        background: #00bfff;
        box-shadow: 0 0 10px rgba(255, 0, 0, 0.8);
        transform: scale(0.8);
    }
    50% {
        background: #ffff00;
        box-shadow: 0 0 15px rgba(255, 255, 0, 0.8);
        transform: scale(1.2);
    }
    100% {
        background: #00ff00;
        box-shadow: 0 0 10px rgba(0, 255, 0, 0.8);
        transform: scale(1);
    }
}

@keyframes targetDisrupted {
    0%, 100% { 
        opacity: 0.3;
        transform: scale(0.8);
    }
    50% { 
        opacity: 1;
        transform: scale(1.5);
    }
}

/* Radar Center */
.radar-center {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    transform: translate(-50%, -50%);
    z-index: 4;
}

.center-dot {
    width: 100%;
    height: 100%;
    background: #00ff00;
    border-radius: 50%;
    box-shadow: 0 0 15px rgba(0, 255, 0, 0.8);
    animation: centerPulse 1s ease-in-out infinite;
}

@keyframes centerPulse {
    0%, 100% { 
        transform: scale(1);
        opacity: 1;
    }
    50% { 
        transform: scale(1.2);
        opacity: 0.8;
    }
}

/* Radar Info */
.radar-info {
    position: absolute;
    top: 20px;
    left: 20px;
    color: #00ff00;
    font-family: 'Courier New', monospace;
    font-size: 14px;
    text-shadow: 0 0 10px rgba(0, 255, 0, 0.8);
    z-index: 5;
}

.radar-status {
    font-weight: bold;
    margin-bottom: 5px;
}

.radar-status.disrupted {
        color: #00bfff;
    text-shadow: 0 0 10px rgba(255, 0, 0, 0.8);
    animation: statusFlicker 0.5s ease-in-out infinite;
}

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

/* Radar Controls */
.radar-controls {
    position: absolute;
    bottom: 50px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 5;
}

.control-panel {
    display: flex;
    gap: 20px;
}

.control-button {
    padding: 10px 20px;
    background: rgba(0, 0, 0, 0.8);
    border: 2px solid #00ff00;
    border-radius: 5px;
    color: #00ff00;
    font-family: 'Courier New', monospace;
    font-size: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 0 10px rgba(0, 255, 0, 0.3);
}

.control-button:hover {
    background: rgba(0, 255, 0, 0.2);
    box-shadow: 0 0 20px rgba(0, 255, 0, 0.6);
}

.control-button.disrupted {
    border-color: #00bfff;
        color: #00bfff;
    box-shadow: 0 0 10px rgba(0, 191, 255, 0.3);
}

/* Satellite Peaceful Flight Scene */
#satellite-flight .space-background {
    background: linear-gradient(135deg, #000428, #004e92, #000428) !important;
}

#satellite-flight .stars {
    display: block;
    animation: starTwinkle 4s ease-in-out infinite;
}

.nebula {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(ellipse at 30% 20%, rgba(138, 43, 226, 0.3), transparent 50%),
                radial-gradient(ellipse at 70% 80%, rgba(75, 0, 130, 0.2), transparent 50%),
                radial-gradient(ellipse at 20% 70%, rgba(25, 25, 112, 0.3), transparent 50%);
    animation: nebulaDrift 20s ease-in-out infinite;
}

@keyframes nebulaDrift {
    0%, 100% { 
        transform: translateX(0) translateY(0) rotate(0deg);
        opacity: 0.7;
    }
    50% { 
        transform: translateX(-20px) translateY(-10px) rotate(1deg);
        opacity: 1;
    }
}

.satellite-flight-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 5;
}

.peaceful-satellite {
    position: absolute;
    width: 400px;
    height: 200px;
    animation: horizontalFlight 8s ease-in-out infinite;
    transform-style: preserve-3d;
    perspective: 1000px;
    z-index: 10;
}

.satellite-image {
    width: 100% ;
    height: 100%;
    object-fit: contain;
    filter: drop-shadow(0 0 20px rgba(0, 191, 255, 0.6));
    animation: satelliteGlow 3s ease-in-out infinite alternate;
    /* animation: horizontalFlight 8s ease-in-out infinite; */
}

@keyframes horizontalFlight {
    0% { 
        transform: translateX(-200px) translateY(0) rotate(0deg) scale(0.8);
        opacity: 0.7;
    }
    25% { 
        transform: translateX(-100px) translateY(-10px) rotate(1deg) scale(0.9);
        opacity: 0.9;
    }
    50% { 
        transform: translateX(0) translateY(0) rotate(0deg) scale(1);
        opacity: 1;
    }
    75% { 
        transform: translateX(100px) translateY(-5px) rotate(-0.5deg) scale(0.95);
        opacity: 0.9;
    }
    100% { 
        transform: translateX(200px) translateY(0) rotate(0deg) scale(0.8);
        opacity: 0.7;
    }
}

@keyframes satelliteGlow {
    0% { 
        filter: drop-shadow(0 0 20px rgba(0, 191, 255, 0.6));
    }
    100% { 
        filter: drop-shadow(0 0 30px rgba(0, 191, 255, 0.9));
    }
}

.flight-info {
    position: absolute;
    bottom: 100px;
    left: 50%;
    transform: translateX(-50%);
    text-align: center;
    color: #00bfff;
    font-family: 'Courier New', monospace;
    z-index: 15;
    background: rgba(0, 0, 0, 0.7);
    padding: 20px 30px;
    border-radius: 15px;
    border: 2px solid rgba(0, 191, 255, 0.5);
    box-shadow: 0 0 30px rgba(0, 191, 255, 0.3);
    backdrop-filter: blur(10px);
    animation: infoGlow 3s ease-in-out infinite;
}

.flight-info h3 {
    margin: 0 0 10px 0;
    font-size: 18px;
    text-shadow: 0 0 10px rgba(0, 191, 255, 0.8);
}

.flight-info p {
    margin: 0;
    font-size: 14px;
    opacity: 0.9;
}

/* Cloud of Thoughts Scene */
#cloud-scene .space-background {
    background: linear-gradient(135deg, #000428, #004e92, #000428) !important;
}

#cloud-scene .stars {
    display: block;
    animation: starTwinkle 4s ease-in-out infinite;
}

.cloud-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 5;
}

.cloud-thoughts {
    position: relative;
    width: 300px;
    height: 200px;
    margin: 0 auto;
    animation: cloudAppear 3s ease-out;
}

.thought-bubble {
    position: absolute;
    background: rgba(255, 255, 255, 0.1);
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    animation: thoughtFloat 4s ease-in-out infinite;
}

.thought-1 {
    width: 80px;
    height: 80px;
    top: 20px;
    left: 50px;
    animation-delay: 0s;
}

.thought-2 {
    width: 60px;
    height: 60px;
    top: 60px;
    right: 40px;
    animation-delay: 1s;
}

.thought-3 {
    width: 100px;
    height: 100px;
    bottom: 30px;
    left: 30px;
    animation-delay: 2s;
}

.thought-4 {
    width: 70px;
    height: 70px;
    top: 100px;
    left: 120px;
    animation-delay: 0.5s;
}

.thought-5 {
    width: 50px;
    height: 50px;
    bottom: 60px;
    right: 60px;
    animation-delay: 1.5s;
}

@keyframes thoughtFloat {
    0%, 100% { 
        transform: translateY(0) scale(1);
        opacity: 0.7;
    }
    50% { 
        transform: translateY(-10px) scale(1.1);
        opacity: 1;
    }
}

.cloud-image {
    width: 100%;
    max-width: 500px;
    height: auto;
    object-fit: contain;
    animation: cloudAppear 3s ease-in-out;
    filter: drop-shadow(0 0 20px rgba(255, 255, 255, 0.3));
    opacity: 0.7;
    mix-blend-mode: screen;
}

@keyframes cloudAppear {
    0% {
        opacity: 0;
        transform: scale(0.8);
    }
    100% {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes cloudFromEdges {
    0% {
        transform: scale(0.1);
        opacity: 0;
        clip-path: circle(0% at 50% 50%);
    }
    100% {
        transform: scale(1);
        opacity: 1;
        clip-path: circle(100% at 50% 50%);
    }
}

@keyframes cloudShrink {
    0% {
        transform: scale(1);
        opacity: 0.8;
    }
    100% {
        transform: scale(0.1);
        opacity: 0;
    }
}

@keyframes spaceFadeOut {
    0% {
        opacity: 1;
        transform: scale(1);
    }
    100% {
        opacity: 0;
        transform: scale(0.8);
    }
}

@keyframes satelliteFadeOut {
    0% {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1);
    }
    100% {
        opacity: 0;
        transform: translate(-50%, -50%) scale(0.5);
    }
}

.space-inside-cloud {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.stars-inside {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(2px 2px at 20px 30px, #eee, transparent),
                radial-gradient(2px 2px at 40px 70px, rgba(255,255,255,0.8), transparent),
                radial-gradient(1px 1px at 90px 40px, #fff, transparent),
                radial-gradient(1px 1px at 130px 80px, rgba(255,255,255,0.6), transparent),
                radial-gradient(2px 2px at 160px 30px, #ddd, transparent);
    background-repeat: repeat;
    background-size: 200px 100px;
    animation: starsTwinkle 3s ease-in-out infinite;
}

.nebula-inside {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(ellipse at center, rgba(138, 43, 226, 0.3) 0%, transparent 70%);
    animation: nebulaFloat 4s ease-in-out infinite;
}

.satellite-inside-cloud {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 10;
    animation: satelliteInsideCloud 3s ease-in-out infinite;
}

.satellite-inside-image {
    width: 200px;
    height: 120px;
    object-fit: contain;
    filter: drop-shadow(0 0 15px rgba(0, 191, 255, 0.8));
    animation: satelliteGlow 2s ease-in-out infinite alternate;
}

@keyframes starsTwinkle {
    0%, 100% { opacity: 0.8; }
    50% { opacity: 1; }
}

@keyframes nebulaFloat {
    0%, 100% { 
        transform: scale(1) rotate(0deg);
        opacity: 0.3;
    }
    50% { 
        transform: scale(1.1) rotate(180deg);
        opacity: 0.6;
    }
}

@keyframes satelliteInsideCloud {
    0% { 
        transform: translate(-50%, -50%) scale(0.8);
        opacity: 0.7;
    }
    50% { 
        transform: translate(-50%, -50%) scale(1.1);
        opacity: 1;
    }
    100% { 
        transform: translate(-50%, -50%) scale(0.9);
        opacity: 0.8;
    }
}

.cloud-text-part {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: #fff;
    font-size: 18px;
    font-family: 'Courier New', monospace;
    text-align: center;
    max-width: 80%;
    line-height: 1.6;
    background: rgba(0, 0, 0, 0.7);
    padding: 20px 30px;
    border-radius: 10px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    backdrop-filter: blur(5px);
    z-index: 15;
}

.astronaut-dialogue {
    position: absolute;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    color: #fff;
    font-size: 16px;
    font-family: 'Courier New', monospace;
    text-align: center;
    max-width: 90%;
    line-height: 1.5;
    background: rgba(0, 0, 0, 0.8);
    padding: 15px 25px;
    border-radius: 8px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    backdrop-filter: blur(5px);
    z-index: 15;
    margin-bottom: 10px;
}

@keyframes textFadeIn {
    0% {
        opacity: 0;
        transform: translate(-50%, -50%) scale(0.8);
    }
    100% {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1);
    }
}

@keyframes textFadeOut {
    0% {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1);
    }
    100% {
        opacity: 0;
        transform: translate(-50%, -50%) scale(0.8);
    }
}

@keyframes dialogueFadeIn {
    0% {
        opacity: 0;
        transform: translateX(-50%) translateY(20px);
    }
    100% {
        opacity: 1;
        transform: translateX(-50%) translateY(0);
    }
}


.cloud-text {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    color: #fff;
    font-family: 'Courier New', monospace;
    z-index: 10;
    background: rgba(0, 0, 0, 0.7);
    padding: 30px 40px;
    border-radius: 20px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    box-shadow: 0 0 30px rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
    animation: textFadeIn 2s ease-in-out 1s both;
}

@keyframes textFadeIn {
    0% {
        opacity: 0;
        transform: translate(-50%, -50%) translateY(20px);
    }
    100% {
        opacity: 1;
        transform: translate(-50%, -50%) translateY(0);
    }
}

.cloud-text h3 {
    margin: 0 0 15px 0;
    font-size: 24px;
    text-shadow: 0 0 10px rgba(255, 255, 255, 0.8);
}

.cloud-text p {
    margin: 0;
    font-size: 16px;
    opacity: 0.9;
}

/* Astronaut Scene */
.nasa-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
    animation: nasaBackgroundReveal 2s ease-in-out;
    overflow: hidden;
}

.nasa-background-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    filter: brightness(0.9) contrast(1.1);
    animation: nasaBackgroundReveal 2s ease-in-out;
}

@keyframes nasaBackgroundReveal {
    0% {
        opacity: 0;
        transform: scale(1.05);
        filter: brightness(0.9) contrast(1.1) blur(3px);
    }
    100% {
        opacity: 1;
        transform: scale(1);
        filter: brightness(0.9) contrast(1.1) blur(0px);
    }
}

/* Smooth transition from space to Earth */
.screen {
    transition: opacity 2s ease-in-out;
}

#satellite-flight {
    transition: opacity 2s ease-in-out;
}

#astronaut-scene {
    transition: opacity 2s ease-in-out;
    background-image: url('../../chapters/chapter1/images/nasa.jpg');
}

/* Compass twitching */
@keyframes compassTwitch {
    0% { transform: rotate(0deg); }
    25% { transform: rotate(5deg); }
    50% { transform: rotate(-3deg); }
    75% { transform: rotate(7deg); }
    100% { transform: rotate(0deg); }
}

/* Compass jerky movement */
@keyframes compassJerky {
    0% { transform: rotate(0deg); }
    10% { transform: rotate(15deg); }
    20% { transform: rotate(-10deg); }
    30% { transform: rotate(25deg); }
    40% { transform: rotate(-5deg); }
    50% { transform: rotate(20deg); }
    60% { transform: rotate(-15deg); }
    70% { transform: rotate(10deg); }
    80% { transform: rotate(-20deg); }
    90% { transform: rotate(5deg); }
    100% { transform: rotate(0deg); }
}

/* Map unfold animation */
@keyframes mapUnfold {
    0% { 
        transform: scale(0.1) rotate(-45deg);
        opacity: 0;
    }
    50% {
        transform: scale(0.8) rotate(-10deg);
        opacity: 0.7;
    }
    100% { 
        transform: scale(1) rotate(0deg);
        opacity: 1;
    }
}

/* Landmark appear */
@keyframes landmarkAppear {
    0% { 
        opacity: 0;
        transform: translateY(20px);
    }
    100% { 
        opacity: 1;
        transform: translateY(0);
    }
}

/* Flight path drawing */
@keyframes pathDraw {
    0% { 
        stroke-dasharray: 0, 1000;
    }
    100% { 
        stroke-dasharray: 1000, 0;
    }
}

/* Fade in effect */
@keyframes fadeIn {
    0% { opacity: 0; }
    100% { opacity: 1; }
}

/* Chapter 2 specific styles */

/* ===== PILOT INTERVIEW STYLES ===== */
.interview-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
}

.cockpit-bg {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: brightness(0.4) blur(2px);
}

.interview-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(0, 20, 40, 0.8), rgba(20, 40, 80, 0.6));
}

.character-introduction {
    position: relative;
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 40px;
    height: 100vh;
    max-width: 1200px;
    margin: 0 auto;
}

.pilot-portrait {
    display: flex;
    align-items: center;
    gap: 30px;
    flex: 1;
}

.pilot-image {
    width: 200px;
    height: 200px;
    border-radius: 50%;
    border: 4px solid #00d4ff;
    box-shadow: 0 0 30px rgba(0, 212, 255, 0.5);
    object-fit: cover;
}

.pilot-info h2 {
    color: #00d4ff;
    font-size: 2.5em;
    margin-bottom: 10px;
    text-shadow: 0 0 10px rgba(0, 212, 255, 0.8);
}

.pilot-title {
    color: #ffffff;
    font-size: 1.3em;
    margin-bottom: 20px;
    opacity: 0.9;
}

.pilot-stats {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.pilot-stats span {
    color: #a0d4ff;
    font-size: 1.1em;
    padding: 5px 0;
}

.interview-content {
    flex: 1;
    max-width: 600px;
    margin-left: 40px;
}

.interview-question {
    background: rgba(0, 20, 40, 0.9);
    border: 2px solid #00d4ff;
    border-radius: 15px;
    padding: 30px;
    margin-bottom: 20px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
}

.interviewer-bubble {
    background: rgba(255, 255, 255, 0.1);
    border-left: 4px solid #ff6b35;
    padding: 20px;
    margin-bottom: 20px;
    border-radius: 10px;
}

.interviewer-bubble p {
    color: #ffffff;
    font-size: 1.1em;
    margin: 0;
}

.pilot-response {
    background: rgba(0, 212, 255, 0.1);
    border-left: 4px solid #00d4ff;
    padding: 20px;
    border-radius: 10px;
}

.pilot-response p {
    color: #ffffff;
    font-size: 1.1em;
    margin-bottom: 20px;
    line-height: 1.6;
}

.continue-btn {
    background: linear-gradient(45deg, #00d4ff, #0099cc);
    color: white;
    border: none;
    padding: 15px 30px;
    border-radius: 25px;
    font-size: 1.1em;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 5px 15px rgba(0, 212, 255, 0.3);
}

.continue-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 212, 255, 0.5);
    background: linear-gradient(45deg, #33ddff, #00aadd);
}

/* ===== BLITZ QUESTIONS STYLES ===== */
.blitz-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at center, #001122, #000511);
    overflow: hidden;
}

.space-weather-visual {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 800px;
    height: 800px;
}

.sun-corona {
    position: absolute;
    top: 20%;
    left: 20%;
    width: 200px;
    height: 200px;
    background: radial-gradient(circle, #ffaa00, #ff6600);
    border-radius: 50%;
    box-shadow: 0 0 100px #ffaa00, 0 0 200px #ff6600;
    animation: sunPulse 3s ease-in-out infinite;
}

.solar-particles {
    position: absolute;
    top: 30%;
    left: 40%;
    width: 400px;
    height: 200px;
    background: linear-gradient(45deg, transparent, rgba(255, 170, 0, 0.3), transparent);
    border-radius: 50%;
    animation: particleFlow 4s linear infinite;
}

.earth-magnetosphere {
    position: absolute;
    bottom: 20%;
    right: 20%;
    width: 150px;
    height: 150px;
    background: radial-gradient(circle, #0066cc, #003366);
    border-radius: 50%;
    box-shadow: 0 0 50px #0066cc;
    animation: earthRotate 8s linear infinite;
}

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

@keyframes particleFlow {
    0% { opacity: 0; transform: translateX(-100px); }
    50% { opacity: 1; }
    100% { opacity: 0; transform: translateX(300px); }
}

@keyframes earthRotate {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.blitz-content {
    position: relative;
    z-index: 10;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100vh;
    padding: 40px;
    max-width: 800px;
    margin: 0 auto;
}

.blitz-title {
    color: #ffaa00;
    font-size: 3em;
    text-align: center;
    margin-bottom: 10px;
    text-shadow: 0 0 20px #ffaa00;
    animation: titleGlow 2s ease-in-out infinite alternate;
}

@keyframes titleGlow {
    0% { text-shadow: 0 0 20px #ffaa00; }
    100% { text-shadow: 0 0 30px #ffaa00, 0 0 40px #ff6600; }
}

.blitz-subtitle {
    color: #ffffff;
    font-size: 1.3em;
    text-align: center;
    margin-bottom: 40px;
    opacity: 0.9;
}

.question-container {
    background: rgba(0, 20, 40, 0.9);
    border: 2px solid #ffaa00;
    border-radius: 20px;
    padding: 40px;
    width: 100%;
    max-width: 700px;
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.6);
}

.question-number {
    color: #ffaa00;
    font-size: 1.1em;
    font-weight: bold;
    margin-bottom: 15px;
    text-align: center;
}

.question-text {
    color: #ffffff;
    font-size: 1.5em;
    text-align: center;
    margin-bottom: 30px;
    line-height: 1.4;
}

.answer-options {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
    margin-bottom: 20px;
}

.answer-btn {
    background: rgba(255, 255, 255, 0.1);
    color: #ffffff;
    border: 2px solid #666;
    padding: 15px 20px;
    border-radius: 10px;
    font-size: 1em;
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: left;
}

.answer-btn:hover {
    background: rgba(255, 255, 255, 0.2);
    border-color: #00d4ff;
    transform: translateY(-2px);
}

.answer-btn.correct {
    background: rgba(0, 255, 0, 0.2);
    border-color: #00ff00;
    color: #00ff00;
}

.answer-btn.incorrect {
    background: rgba(255, 0, 0, 0.2);
    border-color: #00bfff;
        color: #00bfff;
}

.explanation {
    background: rgba(0, 255, 0, 0.1);
    border: 2px solid #00ff00;
    border-radius: 10px;
    padding: 20px;
    margin-top: 20px;
}

.explanation p {
    color: #ffffff;
    font-size: 1.1em;
    margin: 0;
    line-height: 1.5;
}

.blitz-results {
    text-align: center;
}

.blitz-results h3 {
    color: #ffaa00;
    font-size: 2.5em;
    margin-bottom: 20px;
    text-shadow: 0 0 15px #ffaa00;
}

.score-display {
    color: #ffffff;
    font-size: 1.8em;
    margin-bottom: 15px;
}

.score-message {
    color: #a0d4ff;
    font-size: 1.2em;
    margin-bottom: 30px;
}

/* ===== AVIATION FACTS STYLES ===== */
.facts-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
}

.facts-bg {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: brightness(0.3) blur(1px);
}

.facts-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(0, 30, 60, 0.8), rgba(30, 60, 120, 0.6));
}

.facts-content {
    position: relative;
    z-index: 10;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100vh;
    padding: 40px;
    max-width: 900px;
    margin: 0 auto;
}

.facts-title {
    color: #00d4ff;
    font-size: 2.8em;
    text-align: center;
    margin-bottom: 40px;
    text-shadow: 0 0 20px #00d4ff;
}

.fact-card {
    background: rgba(0, 20, 40, 0.95);
    border: 2px solid #00d4ff;
    border-radius: 20px;
    padding: 40px;
    width: 100%;
    max-width: 700px;
    text-align: center;
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.6);
}

.fact-icon {
    font-size: 4em;
    margin-bottom: 20px;
    animation: iconFloat 3s ease-in-out infinite;
}

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

.fact-card h3 {
    color: #00d4ff;
    font-size: 1.8em;
    margin-bottom: 20px;
}

.fact-card p {
    color: #ffffff;
    font-size: 1.2em;
    line-height: 1.6;
    margin-bottom: 25px;
}

.fact-stats {
    display: flex;
    justify-content: space-around;
    margin-bottom: 30px;
    flex-wrap: wrap;
    gap: 15px;
}

.fact-stats span {
    background: rgba(0, 212, 255, 0.2);
    color: #00d4ff;
    padding: 10px 20px;
    border-radius: 25px;
    font-size: 1em;
    border: 1px solid #00d4ff;
}

.next-fact-btn {
    background: linear-gradient(45deg, #00d4ff, #0099cc);
    color: white;
    border: none;
    padding: 15px 40px;
    border-radius: 25px;
    font-size: 1.2em;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 5px 15px rgba(0, 212, 255, 0.3);
}

.next-fact-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 212, 255, 0.5);
    background: linear-gradient(45deg, #33ddff, #00aadd);
}
.cockpit-background {
    position: relative;
    width: 100%;
    height: 100%;
}

.cockpit-background-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Flight scene styles */
.flight-scene {
    position: relative;
    width: 100%;
    height: 100%;
    background: linear-gradient(to bottom, #87CEEB 0%, #98FB98 40%, #F0E68C 100%);
    overflow: hidden;
}

.sky-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('chapter2/images/sky.jpeg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

.clouds-layer {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

/* Individual cloud elements */
.cloud {
    position: absolute;
    background: white;
    border-radius: 50px;
    opacity: 0.8;
}

.cloud:before,
.cloud:after {
    content: '';
    position: absolute;
    background: white;
    border-radius: 50px;
}

.cloud-1 {
    width: 100px;
    height: 40px;
    top: 20%;
    left: 10%;
    animation: cloudFloat 20s linear infinite;
    animation-delay: 0s;
}

.cloud-1:before {
    width: 50px;
    height: 50px;
    top: -25px;
    left: 10px;
}

.cloud-1:after {
    width: 60px;
    height: 20px;
    top: -10px;
    right: 10px;
}

.cloud-2 {
    width: 80px;
    height: 30px;
    top: 15%;
    left: 20%;
    animation: cloudFloat 25s linear infinite;
    animation-delay: -8s;
}

.cloud-2:before {
    width: 40px;
    height: 40px;
    top: -20px;
    left: 15px;
}

.cloud-2:after {
    width: 50px;
    height: 15px;
    top: -5px;
    right: 15px;
}

.cloud-3 {
    width: 120px;
    height: 50px;
    top: 30%;
    left: 60%;
    animation: cloudFloat 18s linear infinite;
    animation-delay: -15s;
}

.cloud-3:before {
    width: 60px;
    height: 60px;
    top: -30px;
    left: 20px;
}

.cloud-3:after {
    width: 70px;
    height: 25px;
    top: -15px;
    right: 20px;
}

@keyframes cloudFloat {
    0% { 
        transform: translateX(-200px) translateY(0px);
    }
    100% { 
        transform: translateX(100vw) translateY(-10px);
    }
}


@keyframes cloudsMove {
    0% { transform: translateX(-100px); }
    100% { transform: translateX(100px); }
}

.aircraft-exterior {
    position: absolute;
    top: 50%;
    left: 0%;
    transform: translateY(-50%);
    z-index: 10;
    animation: aircraftHorizontalFlight 15s linear infinite;
}

@keyframes aircraftHorizontalFlight {
    0% { 
        left: 110%;
        transform: translateY(-50%) scale(0.8);
    }
    50% { 
        left: 50%;
        transform: translateY(-50%) scale(1);
    }
    100% { 
        left: -10%;
        transform: translateY(-50%) scale(0.8);
    }
}

.aircraft-image {
    width: 300px;
    height: auto;
    filter: drop-shadow(0 15px 30px rgba(0, 0, 0, 0.4));
    animation: aircraftFly 8s ease-in-out infinite;
    position: relative;
    background: transparent;
    /* Ensure PNG transparency is preserved */
    mix-blend-mode: normal;
}

@keyframes aircraftFly {
    0%, 100% { 
        transform: translateY(0px) rotate(0deg);
    }
    25% { 
        transform: translateY(-15px) rotate(1deg);
    }
    50% { 
        transform: translateY(-8px) rotate(0deg);
    }
    75% { 
        transform: translateY(-20px) rotate(-1deg);
    }
}

/* Engine trail effect */
.aircraft-exterior::after {
    content: '';
    position: absolute;
    top: 52%;
    left: -60px;
    width: 50px;
    height: 4px;
    background: linear-gradient(to left, 
        rgba(255, 255, 255, 0.9) 0%,
        rgba(200, 220, 255, 0.7) 30%,
        rgba(150, 180, 255, 0.4) 60%,
        transparent 100%);
    transform: translateY(-50%);
    animation: engineTrail 2s ease-in-out infinite;
    border-radius: 2px;
}

@keyframes engineTrail {
    0%, 100% { 
        opacity: 0.6;
        width: 40px;
    }
    50% { 
        opacity: 1;
        width: 60px;
    }
}

/* Propeller blur effect */
.propeller-blur {
    position: absolute;
    top: 48%;
    right: 82%;
    width: 25px;
    height: 25px;
    background: radial-gradient(circle, rgba(200, 200, 200, 0.4) 0%, rgba(150, 150, 150, 0.2) 50%, transparent 70%);
    border-radius: 50%;
    animation: propellerSpin 0.08s linear infinite;
}

@keyframes propellerSpin {
    0% { transform: rotate(0deg) scale(1); }
    50% { transform: rotate(180deg) scale(1.2); }
    100% { transform: rotate(360deg) scale(1); }
}

.flight-path {
    position: absolute;
    top: 60%;
    left: 0;
    width: 100%;
    height: 2px;
    background: linear-gradient(to right, transparent 0%, rgba(255, 255, 255, 0.5) 20%, rgba(255, 255, 255, 0.8) 50%, rgba(255, 255, 255, 0.5) 80%, transparent 100%);
    animation: pathGlow 3s ease-in-out infinite;
}

@keyframes pathGlow {
    0%, 100% { opacity: 0.3; }
    50% { opacity: 0.8; }
}

/* Sky gradient for different times */
.sky-gradient {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to bottom, 
        rgba(135, 206, 235, 0.3) 0%,
        rgba(152, 251, 152, 0.2) 40%,
        rgba(240, 230, 140, 0.1) 100%);
    pointer-events: none;
}

/* Sun effect */
.sun-effect {
    position: absolute;
    top: 20%;
    right: 15%;
    width: 100px;
    height: 100px;
    background: radial-gradient(circle, rgba(255, 255, 0, 0.8) 0%, rgba(255, 165, 0, 0.4) 40%, transparent 70%);
    border-radius: 50%;
    animation: sunGlow 4s ease-in-out infinite;
}

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

/* Horizon line */
.horizon-line {
    position: absolute;
    bottom: 30%;
    left: 0;
    width: 100%;
    height: 1px;
    background: linear-gradient(to right, transparent 0%, rgba(255, 255, 255, 0.6) 50%, transparent 100%);
}

/* Ground/landscape - only for first scene */
.landscape {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 30%;
    background: linear-gradient(to bottom, 
        rgba(34, 139, 34, 0.8) 0%,
        rgba(107, 142, 35, 0.9) 50%,
        rgba(85, 107, 47, 1) 100%);
}

/* Hide landscape in storm scenes - high altitude flight */
.flight-scene.storm-active .landscape,
#compass-minigame .flight-scene .landscape,
#map-transition .flight-scene .landscape,
#map-minigame .flight-scene .landscape,
#navigation-success .flight-scene .landscape {
    display: none;
}

/* Adjust horizon line for storm scenes */
.flight-scene.storm-active .horizon-line,
#compass-minigame .flight-scene .horizon-line,
#map-transition .flight-scene .horizon-line,
#map-minigame .flight-scene .horizon-line,
#navigation-success .flight-scene .horizon-line {
    display: none;
}

/* Storm effects */
.flight-scene.storm-active {
    animation: stormShake 0.3s ease-in-out infinite;
}

@keyframes stormShake {
    0%, 100% { transform: translateX(0px); }
    25% { transform: translateX(-2px); }
    50% { transform: translateX(2px); }
    75% { transform: translateX(-1px); }
}

.storm-sky {
    filter: brightness(0.7) contrast(1.3) hue-rotate(20deg);
}

.storm-gradient {
    background: linear-gradient(to bottom, 
        rgba(135, 206, 235, 0.1) 0%,
        rgba(255, 165, 0, 0.3) 40%,
        rgba(255, 69, 0, 0.2) 100%);
}

.storm-sun {
    animation: stormSunFlare 2s ease-in-out infinite;
    background: radial-gradient(circle, rgba(255, 69, 0, 1) 0%, rgba(255, 165, 0, 0.6) 40%, transparent 70%);
}

@keyframes stormSunFlare {
    0%, 100% { 
        transform: scale(1);
        opacity: 0.8;
    }
    50% { 
        transform: scale(1.5);
        opacity: 1;
    }
}

.storm-cloud {
    animation: stormCloudTurbulence 3s ease-in-out infinite;
    filter: brightness(0.6) contrast(1.2);
}

@keyframes stormCloudTurbulence {
    0%, 100% { 
        transform: translateX(0px) translateY(0px) scale(1);
    }
    25% { 
        transform: translateX(-15px) translateY(-8px) scale(1.1);
    }
    50% { 
        transform: translateX(10px) translateY(-12px) scale(0.95);
    }
    75% { 
        transform: translateX(-8px) translateY(-5px) scale(1.05);
    }
}

.storm-aircraft {
    animation: aircraftStormFly 2s ease-in-out infinite, aircraftHorizontalFlight 15s linear infinite;
}

@keyframes aircraftStormFly {
    0%, 100% { 
        transform: translateY(0px) rotate(0deg);
    }
    25% { 
        transform: translateY(-25px) rotate(3deg);
    }
    50% { 
        transform: translateY(-10px) rotate(-2deg);
    }
    75% { 
        transform: translateY(-30px) rotate(4deg);
    }
}

.storm-propeller {
    animation: stormPropellerSpin 0.05s linear infinite;
}

@keyframes stormPropellerSpin {
    0% { transform: rotate(0deg) scale(1.2); }
    100% { transform: rotate(360deg) scale(1.2); }
}

.storm-path {
    animation: stormPathFlicker 1s ease-in-out infinite;
}

@keyframes stormPathFlicker {
    0%, 100% { opacity: 0.2; }
    50% { opacity: 0.6; }
}

.storm-effects {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

.lightning-effect {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(45deg, transparent 0%, rgba(255, 255, 255, 0.1) 48%, rgba(255, 255, 255, 0.8) 50%, rgba(255, 255, 255, 0.1) 52%, transparent 100%);
    opacity: 0;
    animation: lightningFlash 4s ease-in-out infinite;
}

@keyframes lightningFlash {
    0%, 90%, 100% { opacity: 0; }
    91%, 93%, 95% { opacity: 1; }
    92%, 94% { opacity: 0.3; }
}

.electromagnetic-interference {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: repeating-linear-gradient(
        0deg,
        transparent,
        transparent 2px,
        rgba(255, 0, 255, 0.03) 2px,
        rgba(255, 0, 255, 0.03) 4px
    );
    animation: interferenceMove 0.1s linear infinite;
}

@keyframes interferenceMove {
    0% { transform: translateY(0px); }
    100% { transform: translateY(4px); }
}

.screen-flicker {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.1);
    opacity: 0;
}

.sunlight-flare {
    position: absolute;
    top: 20%;
    right: 10%;
    width: 200px;
    height: 200px;
    background: radial-gradient(circle, rgba(255, 255, 0, 0.8) 0%, transparent 70%);
    border-radius: 50%;
    opacity: 0;
}

.cockpit-instruments {
    position: absolute;
    bottom: 20px;
    left: 20px;
    display: flex;
    gap: 20px;
}

.instrument {
    background: rgba(0, 0, 0, 0.8);
    border: 2px solid #4ecdc4;
    border-radius: 10px;
    padding: 15px;
    min-width: 120px;
    text-align: center;
}

.compass-face {
    position: relative;
    width: 80px;
    height: 80px;
    border: 2px solid #4ecdc4;
    border-radius: 50%;
    margin: 0 auto 10px;
    background: radial-gradient(circle, #1a1a2e 0%, #0f0f23 100%);
}

.compass-needle {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: #ff6b6b;
    font-weight: bold;
    font-size: 18px;
}

.compass-needle.twitching {
    animation: compassTwitch 0.3s infinite;
}

.compass-needle.jerky {
    animation: compassJerky 0.2s infinite;
}

.gps-screen {
    background: #000;
    color: #00ff00;
    padding: 10px;
    border-radius: 5px;
    font-family: 'Courier New', monospace;
    font-size: 12px;
}

.gps-screen.error {
        color: #00bfff;
    animation: screenFlicker 0.5s infinite;
}

.radio-display {
    background: #000;
    color: #00ff00;
    padding: 10px;
    border-radius: 5px;
    font-family: 'Courier New', monospace;
}

.signal-strength {
    display: flex;
    gap: 2px;
    margin-top: 5px;
}

.signal-bar {
    width: 8px;
    height: 20px;
    background: #333;
    border-radius: 2px;
}

.signal-bar.active {
    background: #00ff00;
}

.instrument-label {
    font-size: 10px;
    color: #4ecdc4;
    margin-top: 5px;
}

.instrument-label.error {
    color: #ff6b6b;
    animation: screenFlicker 1s infinite;
}

/* Pilot dialogue styles */
/* .pilot-dialogue {
    position: absolute;
    bottom: 100px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 0, 0, 0.8);
    border: 2px solid #4ecdc4;
    border-radius: 15px;
    padding: 20px;
    max-width: 600px;
    text-align: center;
}

.dialogue-box h3 {
    color: #4ecdc4;
    margin-bottom: 15px;
    font-size: 18px;
} */

.pilot-thoughts {
    font-style: italic;
    color: #aaa;
    font-size: 14px;
    margin-top: 10px;
}

/* Interactive Compass Game Area */
.compass-game-area {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 30px;
    padding: 20px;
    background: rgba(0, 0, 0, 0.8);
    border-radius: 15px;
    margin: 20px;
    position: relative;
}

/* Compass Radar Container */
.compass-radar-container {
    position: relative;
    width: 300px;
    height: 300px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Compass Background */
.compass-background {
    position: relative;
    width: 250px;
    height: 250px;
    border-radius: 50%;
    overflow: hidden;
    box-shadow: 0 0 30px rgba(0, 255, 0, 0.3);
}

.compass-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
}

/* Green Target Sector */
.green-sector {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 100%;
    height: 100%;
    transform: translate(-50%, -50%);
    border-radius: 50%;
    background: conic-gradient(
        transparent 0deg,
        transparent 80deg,
        rgba(0, 255, 0, 0.4) 90deg,
        rgba(0, 255, 0, 0.6) 100deg,
        rgba(0, 255, 0, 0.4) 110deg,
        transparent 120deg,
        transparent 360deg
    );
    pointer-events: none;
    animation: greenSectorPulse 2s ease-in-out infinite;
}

@keyframes greenSectorPulse {
    0%, 100% { opacity: 0.6; }
    50% { opacity: 1; }
}

/* Aircraft Needle */
.aircraft-needle {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 2px;
    height: 100px;
    background: linear-gradient(to top, transparent 0%, #ff4444 20%, #ff0000 100%);
    transform-origin: bottom center;
    transform: translate(-50%, -100%);
    animation: aircraftNeedleRotate 3s linear infinite;
    z-index: 10;
}

.aircraft-icon {
    position: absolute;
    top: -15px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 20px;
    filter: drop-shadow(0 0 5px rgba(255, 255, 255, 0.8));
}

@keyframes aircraftNeedleRotate {
    0% { transform: translate(-50%, -100%) rotate(0deg); }
    100% { transform: translate(-50%, -100%) rotate(360deg); }
}

/* Compass Center */
.compass-center {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 12px;
    height: 12px;
    background: radial-gradient(circle, #ffffff 0%, #cccccc 100%);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    z-index: 15;
    box-shadow: 0 0 10px rgba(255, 255, 255, 0.5);
}

/* Radar Rings */
.radar-rings {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    pointer-events: none;
}

.radar-ring {
    position: absolute;
    border: 1px solid rgba(0, 255, 0, 0.3);
    border-radius: 50%;
    animation: radarPulse 4s ease-in-out infinite;
}

.ring-1 {
    width: 280px;
    height: 280px;
    top: -140px;
    left: -140px;
    animation-delay: 0s;
}

.ring-2 {
    width: 320px;
    height: 320px;
    top: -160px;
    left: -160px;
    animation-delay: 1s;
}

.ring-3 {
    width: 360px;
    height: 360px;
    top: -180px;
    left: -180px;
    animation-delay: 2s;
}

@keyframes radarPulse {
    0% { 
        opacity: 0;
        transform: scale(0.8);
    }
    50% { 
        opacity: 0.6;
        transform: scale(1);
    }
    100% { 
        opacity: 0;
        transform: scale(1.2);
    }
}

/* Radar Sweep */
.radar-sweep {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 250px;
    height: 250px;
    border-radius: 50%;
    background: conic-gradient(
        transparent 0deg,
        transparent 340deg,
        rgba(0, 255, 0, 0.3) 350deg,
        rgba(0, 255, 0, 0.6) 360deg
    );
    transform: translate(-50%, -50%);
    animation: radarSweep 4s linear infinite;
    pointer-events: none;
}

@keyframes radarSweep {
    0% { transform: translate(-50%, -50%) rotate(0deg); }
    100% { transform: translate(-50%, -50%) rotate(360deg); }
}

/* Game Controls */
.catch-needle-btn {
    background: linear-gradient(45deg, #ff4444, #ff6666);
    color: white;
    border: none;
    padding: 15px 30px;
    font-size: 18px;
    font-weight: bold;
    border-radius: 10px;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(255, 68, 68, 0.4);
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.catch-needle-btn:hover {
    background: linear-gradient(45deg, #ff6666, #ff8888);
    box-shadow: 0 6px 20px rgba(255, 68, 68, 0.6);
    transform: translateY(-2px);
}

.catch-needle-btn:active {
    transform: translateY(0px);
    box-shadow: 0 2px 10px rgba(255, 68, 68, 0.4);
}

/* Timing Indicator */
.timing-indicator {
    width: 100%;
    height: 8px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 4px;
    overflow: hidden;
    margin: 10px 0;
}

.timing-bar {
    height: 100%;
    background: linear-gradient(90deg, #ff4444, #ffff44, #44ff44);
    width: 0%;
    border-radius: 4px;
    transition: width 0.1s ease;
}

/* Success/Failure Effects */
.compass-success {
    animation: compassSuccess 1s ease-in-out;
}

.compass-failure {
    animation: compassFailure 0.5s ease-in-out;
}

@keyframes compassSuccess {
    0%, 100% { transform: scale(1); }
    50% { 
        transform: scale(1.1);
        box-shadow: 0 0 50px rgba(0, 255, 0, 0.8);
    }
}

@keyframes compassFailure {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-10px); }
    75% { transform: translateX(10px); }
}

/* Aircraft needle speed variations */
.aircraft-needle.slow {
    animation-duration: 5s;
}

.aircraft-needle.fast {
    animation-duration: 1.5s;
}

.aircraft-needle.normal {
    animation-duration: 3s;
}

.compass-container {
    position: relative;
    width: 200px;
    height: 200px;
}

.compass-outer-ring {
    position: absolute;
    width: 100%;
    height: 100%;
    border: 3px solid #4ecdc4;
    border-radius: 50%;
}

.compass-marking {
    position: absolute;
    font-weight: bold;
    color: #4ecdc4;
    font-size: 18px;
}

.compass-marking.north {
    top: -10px;
    left: 50%;
    transform: translateX(-50%);
}

.compass-marking.east {
    right: -15px;
    top: 50%;
    transform: translateY(-50%);
}

.compass-marking.south {
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
}

.compass-marking.west {
    left: -15px;
    top: 50%;
    transform: translateY(-50%);
}

.compass-inner {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 150px;
    height: 150px;
    background: radial-gradient(circle, #1a1a2e 0%, #0f0f23 100%);
    border-radius: 50%;
    border: 2px solid #333;
}

.truth-window-indicator {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 120px;
    height: 120px;
    border: 3px solid #2ecc71;
    border-radius: 50%;
    display: none;
}

.stability-ring {
    width: 100%;
    height: 100%;
    border: 2px dashed #2ecc71;
    border-radius: 50%;
    animation: rotate 2s linear infinite;
}

.stability-text {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: #2ecc71;
    font-weight: bold;
    font-size: 12px;
}

@keyframes rotate {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.environmental-clues {
    display: flex;
    gap: 40px;
    align-items: center;
    margin-bottom: 30px;
}

.sun-position {
    display: flex;
    align-items: center;
    gap: 10px;
    background: rgba(255, 165, 0, 0.2);
    padding: 15px;
    border-radius: 10px;
    border: 2px solid #ffa500;
}

.sun-icon {
    font-size: 30px;
}

.sun-info {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.sun-direction, .time-info {
    color: #ffa500;
    font-weight: bold;
}

.analog-clock {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
}

.clock-face {
    position: relative;
    width: 60px;
    height: 60px;
    border: 3px solid #4ecdc4;
    border-radius: 50%;
    background: #1a1a2e;
}

.clock-hand {
    position: absolute;
    background: #4ecdc4;
    transform-origin: bottom center;
    border-radius: 2px;
}

.hour-hand {
    width: 3px;
    height: 20px;
    top: 10px;
    left: 50%;
    margin-left: -1.5px;
}

.minute-hand {
    width: 2px;
    height: 25px;
    top: 5px;
    left: 50%;
    margin-left: -1px;
}

.clock-center {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 6px;
    height: 6px;
    background: #4ecdc4;
    border-radius: 50%;
    transform: translate(-50%, -50%);
}

.clock-label {
    color: #4ecdc4;
    font-size: 12px;
    font-weight: bold;
}

/* Game controls */
.game-controls {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
}

.lock-course-btn {
    background: linear-gradient(45deg, #2ecc71, #27ae60);
    color: white;
    border: none;
    padding: 15px 30px;
    border-radius: 10px;
    font-size: 16px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    opacity: 0.5;
}

.lock-course-btn:not(:disabled) {
    opacity: 1;
    box-shadow: 0 0 20px rgba(46, 204, 113, 0.5);
}

.lock-course-btn:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 5px 25px rgba(46, 204, 113, 0.7);
}

.game-status {
    text-align: center;
    background: rgba(0, 0, 0, 0.7);
    padding: 15px;
    border-radius: 10px;
    border: 1px solid #4ecdc4;
    width: 510px;
}

.status-text {
    color: #4ecdc4;
    font-size: 16px;
    margin-bottom: 5px;
}

.attempts-counter {
    color: #ffa500;
    font-size: 14px;
}

/* Map game styles */
.map-game-area {
    display: flex;
    gap: 30px;
    align-items: flex-start;
}

.paper-map-container {
    background: #f4f1e8;
    border: 3px solid #8b4513;
    border-radius: 10px;
    padding: 20px;
    position: relative;
}

.map-grid {
    position: relative;
    width: 400px;
    height: 300px;
    background: linear-gradient(to bottom, #87ceeb 0%, #98fb98 100%);
    border: 2px solid #654321;
}

.grid-lines {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.grid-line {
    position: absolute;
    background: rgba(0, 0, 0, 0.2);
}

.grid-line.vertical {
    width: 1px;
    height: 100%;
}

.grid-line.horizontal {
    width: 100%;
    height: 1px;
}

.map-landmark {
    position: absolute;
    display: flex;
    flex-direction: column;
    align-items: center;
    cursor: pointer;
    transition: transform 0.3s ease;
}

.map-landmark:hover {
    transform: scale(1.1);
}

.landmark-icon {
    font-size: 20px;
    margin-bottom: 2px;
}

.landmark-name {
    font-size: 10px;
    color: #333;
    font-weight: bold;
    text-shadow: 1px 1px 2px rgba(255, 255, 255, 0.8);
}

.current-position {
    position: absolute;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.position-marker {
    font-size: 24px;
        color: #00bfff;
    animation: pulse 2s infinite;
}

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

.position-label {
    font-size: 10px;
        color: #00bfff;
    font-weight: bold;
    margin-top: 2px;
}

.navigation-controls {
    display: flex;
    flex-direction: column;
    gap: 20px;
    min-width: 300px;
}

.flight-data-panel {
    background: rgba(0, 0, 0, 0.8);
    border: 2px solid #4ecdc4;
    border-radius: 10px;
    padding: 15px;
}

.data-section h4, .landmarks-section h4 {
    color: #4ecdc4;
    margin-bottom: 10px;
}

.data-item {
    display: flex;
    justify-content: space-between;
    margin-bottom: 5px;
}

.data-label {
    color: #aaa;
}

.data-value {
    color: #fff;
    font-weight: bold;
}

.landmark-list {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.landmark-item {
    color: #ffa500;
    font-size: 14px;
}

.coordinate-inputs, .heading-inputs {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.input-group {
    display: flex;
    align-items: center;
    gap: 10px;
}

.input-group label {
    color: #4ecdc4;
    min-width: 120px;
}

.input-group input {
    background: #1a1a2e;
    border: 2px solid #4ecdc4;
    border-radius: 5px;
    padding: 8px;
    color: #fff;
    width: 100px;
}

.unit {
    color: #aaa;
    font-size: 12px;
}

.action-buttons {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.plot-course-btn, .validate-navigation-btn {
    background: linear-gradient(45deg, #4ecdc4, #44a08d);
    color: white;
    border: none;
    padding: 12px 20px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
}

.plot-course-btn:hover, .validate-navigation-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(78, 205, 196, 0.4);
}

.validate-navigation-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.navigation-feedback {
    padding: 10px;
    border-radius: 5px;
    text-align: center;
    font-weight: bold;
}

.navigation-feedback.success {
    background: rgba(46, 204, 113, 0.2);
    border: 1px solid #2ecc71;
    color: #2ecc71;
}

.navigation-feedback.error {
    background: rgba(231, 76, 60, 0.2);
    border: 1px solid #e74c3c;
    color: #e74c3c;
}

/* Commentary box */
.pilot-commentary {
    position: absolute;
    top: 20px;
    left: 20px;
    background: rgba(0, 0, 0, 0.8);
    border: 2px solid #4ecdc4;
    border-radius: 10px;
    padding: 15px;
    /* max-width: 400px; */
}

.commentary-box p {
    color: #4ecdc4;
    font-style: italic;
    margin: 0;
}

/* Chapter Selection Styles */
.chapter-selection-content {
    text-align: center;
    padding: 40px 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.chapter-selection-title {
    font-size: clamp(2.5rem, 6vw, 4rem);
    font-weight: 900;
    color: #fff;
    margin-bottom: 40px;
    text-shadow: 0 0 20px rgba(78, 205, 196, 0.7);
}

.chapters-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    margin-bottom: 40px;
    max-width: 1200px;
    margin-left: auto;
    margin-right: auto;
}

.chapter-card {
    background: rgba(15, 23, 42, 0.8);
    border: 2px solid rgba(78, 205, 196, 0.3);
    border-radius: 20px;
    padding: 30px;
    text-align: center;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
    position: relative;
    overflow: hidden;
}

.chapter-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(78, 205, 196, 0.1), rgba(139, 69, 19, 0.1));
    opacity: 0;
    transition: opacity 0.3s ease;
    z-index: -1;
}

.chapter-card:hover::before {
    opacity: 1;
}

.chapter-card:hover:not(.locked) {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(78, 205, 196, 0.3);
    border-color: rgba(78, 205, 196, 0.6);
}

.chapter-card.locked {
    opacity: 0.6;
    border-color: rgba(255, 107, 107, 0.3);
}

.chapter-card.unlocked {
    border-color: rgba(78, 205, 196, 0.6);
}

.chapter-card.completed {
    border-color: rgba(34, 197, 94, 0.6);
    background: rgba(34, 197, 94, 0.1);
}

.chapter-number {
    font-size: 24px;
    font-weight: bold;
    color: #4ecdc4;
    margin-bottom: 10px;
}

.chapter-title {
    font-size: 20px;
    font-weight: bold;
    margin-bottom: 15px;
    color: #fff;
}

.chapter-description {
    font-size: 14px;
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 20px;
    line-height: 1.5;
}

.chapter-status {
    font-size: 12px;
    text-transform: uppercase;
    margin-bottom: 20px;
    font-weight: bold;
}

.chapter-card.unlocked .chapter-status {
    color: #4ecdc4;
}

.chapter-card.locked .chapter-status {
    color: #ff6b6b;
}

.chapter-btn {
    background: linear-gradient(45deg, #4ecdc4, #44a08d);
    border: none;
    padding: 12px 30px;
    border-radius: 8px;
    color: white;
    font-size: 16px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    width: 100%;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.chapter-btn:hover:not(.disabled) {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(78, 205, 196, 0.4);
    background: linear-gradient(45deg, #5ed8d1, #54b09d);
}

.chapter-btn.disabled {
    background: linear-gradient(45deg, #666, #555);
    cursor: not-allowed;
    opacity: 0.7;
}

.chapter-selection-footer {
    margin-top: 40px;
}

.back-btn {
    background: linear-gradient(45deg, #4a90e2, #0066cc);
    border: none;
    padding: 15px 40px;
    border-radius: 10px;
    color: white;
    font-size: 18px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.back-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(255, 107, 107, 0.4);
    background: linear-gradient(45deg, #ff7b7b, #ff6a62);
}

.chapter-selection-controls {
    margin-top: 40px;
}

.back-btn {
    background: linear-gradient(45deg, #ff6b6b, #ff8e8e);
    border: none;
    padding: 15px 40px;
    border-radius: 8px;
    color: white;
    font-size: 16px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.back-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(255, 107, 107, 0.4);
}

/* Directory and Information Styles */
.directory-content,
.information-content {
    text-align: center;
    z-index: 10;
    max-width: 800px;
    padding: 0 20px;
}

.directory-title,
.information-title {
    font-size: 48px;
    margin-bottom: 40px;
    background: linear-gradient(45deg, #4ecdc4, #44a08d);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.directory-sections {
    margin-bottom: 40px;
}

.directory-section {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 15px;
    padding: 30px;
    margin-bottom: 20px;
    text-align: left;
}

.directory-section h3 {
    color: #4ecdc4;
    margin-bottom: 15px;
    font-size: 20px;
}

.directory-section p {
    color: rgba(255, 255, 255, 0.9);
    line-height: 1.6;
}

.information-text {
    text-align: left;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 15px;
    padding: 30px;
    margin-bottom: 40px;
}

.information-text p {
    margin-bottom: 20px;
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.9);
}

.information-text strong {
    color: #4ecdc4;
}

/* Chapter Completion Styles */
.completion-content {
    text-align: center;
    z-index: 10;
    max-width: 600px;
    padding: 0 20px;
}

.completion-title {
    font-size: 48px;
    margin-bottom: 30px;
    background: linear-gradient(45deg, #4ecdc4, #44a08d);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.completion-text {
    margin-bottom: 40px;
}

.completion-text p {
    font-size: 18px;
    margin-bottom: 15px;
    color: rgba(255, 255, 255, 0.9);
}

.completion-controls {
    margin-top: 40px;
}

.continue-btn {
    background: linear-gradient(45deg, #4ecdc4, #44a08d);
    border: none;
    padding: 15px 40px;
    border-radius: 8px;
    color: white;
    font-size: 18px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.continue-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(78, 205, 196, 0.4);
}

/* Responsive Design */
@media (max-width: 768px) {
    .chapters-grid {
        flex-direction: column;
        gap: 20px;
    }
    
    .chapter-card {
        min-width: 100%;
        max-width: 100%;
    }
    
    .chapter-selection-title,
    .directory-title,
    .information-title,
    .completion-title {
        font-size: 36px;
    }
    
    .chapter-card {
        padding: 20px;
    }
    
    .welcome-description {
        font-size: 16px;
    }
}

/* ===== WELCOME SCREEN STYLES ===== */
.welcome-content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    z-index: 10;
    color: white;
    max-width: 600px;
    padding: 20px;
}

.welcome-content .game-title {
    font-size: 3.5rem;
    font-weight: bold;
    margin-bottom: 20px;
    text-shadow: 0 0 30px rgba(78, 205, 196, 0.8);
    letter-spacing: 4px;
}

.welcome-content .subtitle {
    font-size: 1.4rem;
    font-weight: 300;
    letter-spacing: 3px;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 30px;
    text-shadow: 0 0 20px rgba(255, 215, 0, 0.6);
    animation: subtitleGlow 3s ease-in-out infinite alternate;
    text-align: center;
    width: 100%;
}

@keyframes subtitleGlow {
    0% { 
        opacity: 0.8;
        text-shadow: 0 0 20px rgba(255, 215, 0, 0.6);
    }
    100% { 
        opacity: 1;
        text-shadow: 0 0 30px rgba(255, 215, 0, 0.8), 0 0 40px rgba(255, 165, 0, 0.4);
    }
}

.welcome-description {
    font-size: 1.1rem;
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 40px;
    text-shadow: 0 0 10px rgba(255, 255, 255, 0.3);
}

.welcome-description p {
    margin-bottom: 15px;
}

.welcome-overlay {
    position: absolute;
    bottom: 50px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10;
    text-align: center;
}

.loading-text {
    color: rgba(255, 255, 255, 0.7);
    font-size: 1rem;
    font-style: italic;
    animation: loadingPulse 2s ease-in-out infinite;
}

@keyframes loadingPulse {
    0%, 100% { opacity: 0.5; }
    50% { opacity: 1; }
}

/* Mobile responsive for welcome screen */
@media (max-width: 768px) {
    .welcome-content .game-title {
        font-size: 2.5rem;
        letter-spacing: 2px;
    }
    
    .welcome-content .subtitle {
        font-size: 1.1rem;
        letter-spacing: 2px;
        text-align: center;
        width: 100%;
    }
    
    .welcome-description {
        font-size: 1rem;
    }
    
    .loading-text {
        font-size: 0.9rem;
    }
}

/* ===== CHAPTER 3 PREMIUM STYLES WITH IMAGES ===== */

/* Control room background images */
.control-room-bg-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.4;
    filter: brightness(0.6) contrast(1.2);
    z-index: 1;
}

.control-room-bg-image.storm-affected {
    filter: brightness(0.3) contrast(1.5) hue-rotate(20deg);
    animation: stormFlicker 0.5s infinite;
}

@keyframes stormFlicker {
    0%, 100% { opacity: 0.4; }
    50% { opacity: 0.2; }
}

.control-room-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, 
        rgba(0, 50, 100, 0.7) 0%, 
        rgba(0, 20, 60, 0.8) 50%, 
        rgba(0, 10, 40, 0.9) 100%);
    z-index: 2;
}

.storm-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, 
        rgba(100, 0, 0, 0.6) 0%, 
        rgba(60, 0, 20, 0.7) 50%, 
        rgba(40, 0, 10, 0.8) 100%);
    z-index: 2;
    animation: stormPulse 2s ease-in-out infinite;
}

@keyframes stormPulse {
    0%, 100% { opacity: 0.6; }
    50% { opacity: 0.9; }
}

/* Engineer character styles */
.engineer-character {
    position: absolute;
    bottom: 50px;
    right: 100px;
    z-index: 15;
    transform-origin: bottom center;
}

.engineer-avatar {
    width: 200px;
    height: auto;
    filter: drop-shadow(0 10px 30px rgba(0, 0, 0, 0.5));
    transition: all 0.4s ease;
}

.engineer-character.crisis-mode .engineer-avatar {
    filter: drop-shadow(0 10px 30px rgba(255, 0, 0, 0.5)) brightness(0.8) contrast(1.3);
    animation: characterAlert 1s ease-in-out infinite;
}

.engineer-character.monitoring-mode .engineer-avatar {
    filter: drop-shadow(0 10px 30px rgba(0, 255, 255, 0.5)) brightness(1.1);
    animation: characterFocus 2s ease-in-out infinite;
}

.engineer-character.wire-mode .engineer-avatar {
    filter: drop-shadow(0 10px 30px rgba(255, 255, 0, 0.5)) brightness(1.2);
    animation: characterWiring 1.5s ease-in-out infinite;
}

@keyframes characterAlert {
    0%, 100% { transform: scale(1) rotate(0deg); }
    50% { transform: scale(1.05) rotate(-2deg); }
}

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

@keyframes characterWiring {
    0%, 100% { transform: scale(1) translateY(0px); }
    50% { transform: scale(1.03) translateY(-5px); }
}

/* Character glow effects */
.character-glow {
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 150px;
    height: 30px;
    background: radial-gradient(ellipse, rgba(0, 255, 255, 0.3) 0%, transparent 70%);
    border-radius: 50%;
    animation: glowPulse 3s ease-in-out infinite;
}

.character-alert-glow {
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 150px;
    height: 30px;
    background: radial-gradient(ellipse, rgba(255, 0, 0, 0.4) 0%, transparent 70%);
    border-radius: 50%;
    animation: alertGlowPulse 1s ease-in-out infinite;
}

.character-focus-glow {
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 150px;
    height: 30px;
    background: radial-gradient(ellipse, rgba(0, 255, 255, 0.4) 0%, transparent 70%);
    border-radius: 50%;
    animation: focusGlowPulse 2s ease-in-out infinite;
}

.character-wire-glow {
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 150px;
    height: 30px;
    background: radial-gradient(ellipse, rgba(255, 255, 0, 0.4) 0%, transparent 70%);
    border-radius: 50%;
    animation: wireGlowPulse 1.5s ease-in-out infinite;
}

@keyframes glowPulse {
    0%, 100% { opacity: 0.6; transform: translateX(-50%) scale(1); }
    50% { opacity: 1; transform: translateX(-50%) scale(1.1); }
}

@keyframes alertGlowPulse {
    0%, 100% { opacity: 0.7; transform: translateX(-50%) scale(1); }
    50% { opacity: 1; transform: translateX(-50%) scale(1.2); }
}

@keyframes focusGlowPulse {
    0%, 100% { opacity: 0.6; transform: translateX(-50%) scale(1); }
    50% { opacity: 0.9; transform: translateX(-50%) scale(1.15); }
}

@keyframes wireGlowPulse {
    0%, 100% { opacity: 0.7; transform: translateX(-50%) scale(1); }
    50% { opacity: 1; transform: translateX(-50%) scale(1.3); }
}

/* Power grid background */
.power-grid-bg-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.2;
    filter: brightness(0.4) contrast(1.5) hue-rotate(180deg);
    z-index: 1;
}

.transformer-field-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(circle at 30% 30%, rgba(255, 0, 0, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 70% 70%, rgba(255, 100, 0, 0.1) 0%, transparent 50%),
        linear-gradient(135deg, rgba(0, 20, 40, 0.8) 0%, rgba(20, 0, 40, 0.9) 100%);
    z-index: 2;
}

/* Among Us wire panel background */
.among-us-bg-image {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 80%;
    height: 80%;
    object-fit: contain;
    opacity: 0.15;
    filter: brightness(0.3) contrast(2) blur(1px);
    z-index: 1;
}

.among-us-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(circle at center, rgba(0, 30, 60, 0.7) 0%, rgba(0, 10, 30, 0.9) 100%);
    z-index: 2;
}

/* ===== CHAPTER 3 PREMIUM WIRE MINI-GAME STYLES ===== */

/* Wire game scene with premium cyberpunk aesthetic */
.wire-game-scene {
    position: relative;
    width: 100%;
    height: 100vh;
    background: 
        radial-gradient(ellipse at top, #0a0a23 0%, #000000 100%),
        linear-gradient(135deg, #1a0033 0%, #000011 50%, #001122 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.electrical-panel-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(circle at 15% 25%, rgba(0, 255, 255, 0.15) 0%, transparent 40%),
        radial-gradient(circle at 85% 75%, rgba(255, 0, 255, 0.12) 0%, transparent 45%),
        radial-gradient(circle at 50% 10%, rgba(255, 255, 0, 0.08) 0%, transparent 35%),
        conic-gradient(from 0deg at 50% 50%, 
            transparent 0deg, 
            rgba(0, 255, 255, 0.03) 90deg, 
            transparent 180deg, 
            rgba(255, 0, 255, 0.03) 270deg, 
            transparent 360deg);
    animation: backgroundPulse 8s ease-in-out infinite;
}

@keyframes backgroundPulse {
    0%, 100% { opacity: 0.6; }
    50% { opacity: 0.9; }
}

/* Premium wire connection panel */
.wire-connection-panel {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 95%;
    max-width: 1400px;
    height: 500px;
    background: 
        linear-gradient(135deg, rgba(0, 10, 30, 0.95) 0%, rgba(10, 0, 30, 0.95) 100%),
        radial-gradient(circle at 50% 50%, rgba(0, 255, 255, 0.05) 0%, transparent 70%);
    border: 3px solid transparent;
    border-radius: 25px;
    padding: 30px;
    position: relative;
    backdrop-filter: blur(20px);
    box-shadow: 
        0 25px 80px rgba(0, 0, 0, 0.6),
        0 0 0 1px rgba(255, 255, 255, 0.1),
        inset 0 1px 0 rgba(255, 255, 255, 0.2),
        inset 0 -1px 0 rgba(0, 0, 0, 0.3);
}

.wire-connection-panel::before {
    content: '';
    position: absolute;
    top: -3px;
    left: -3px;
    right: -3px;
    bottom: -3px;
    background: linear-gradient(45deg, 
        #00ffff 0%, 
        #ff00ff 25%, 
        #ffff00 50%, 
        #00ff00 75%, 
        #00ffff 100%);
    border-radius: 25px;
    z-index: -1;
    animation: borderGlow 4s linear infinite;
}

@keyframes borderGlow {
    0% { filter: hue-rotate(0deg) brightness(1); }
    50% { filter: hue-rotate(180deg) brightness(1.2); }
    100% { filter: hue-rotate(360deg) brightness(1); }
}

.wire-connection-panel::after {
    content: '';
    position: absolute;
    top: 10px;
    left: 10px;
    right: 10px;
    bottom: 10px;
    background: 
        radial-gradient(circle at 20% 20%, rgba(0, 255, 255, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(255, 0, 255, 0.1) 0%, transparent 50%);
    border-radius: 20px;
    pointer-events: none;
    animation: innerGlow 6s ease-in-out infinite;
}

@keyframes innerGlow {
    0%, 100% { opacity: 0.3; }
    50% { opacity: 0.7; }
}

/* Premium wire sources (left side) */
.wire-sources {
    display: flex;
    flex-direction: column;
    gap: 20px;
    width: 320px;
    z-index: 10;
}

.source-terminal {
    display: flex;
    align-items: center;
    gap: 20px;
    padding: 18px 24px;
    background: 
        linear-gradient(135deg, rgba(0, 30, 60, 0.9) 0%, rgba(0, 15, 40, 0.9) 100%),
        radial-gradient(circle at 10% 50%, rgba(0, 255, 255, 0.1) 0%, transparent 60%);
    border: 2px solid rgba(0, 255, 255, 0.3);
    border-radius: 16px;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    position: relative;
    backdrop-filter: blur(10px);
    box-shadow: 
        0 8px 32px rgba(0, 0, 0, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.source-terminal::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, 
        rgba(0, 255, 255, 0.1) 0%, 
        transparent 50%, 
        rgba(255, 255, 255, 0.05) 100%);
    border-radius: 14px;
    opacity: 0;
    transition: opacity 0.4s ease;
}

.source-terminal:hover {
    background: 
        linear-gradient(135deg, rgba(0, 50, 100, 0.95) 0%, rgba(0, 25, 60, 0.95) 100%),
        radial-gradient(circle at 10% 50%, rgba(0, 255, 255, 0.2) 0%, transparent 60%);
    border-color: rgba(0, 255, 255, 0.6);
    box-shadow: 
        0 12px 48px rgba(0, 255, 255, 0.2),
        0 0 0 1px rgba(0, 255, 255, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
    transform: translateY(-2px) scale(1.02);
}

.source-terminal:hover::before {
    opacity: 1;
}

.source-terminal.active {
    background: 
        linear-gradient(135deg, rgba(0, 255, 255, 0.2) 0%, rgba(0, 150, 255, 0.2) 100%),
        radial-gradient(circle at 10% 50%, rgba(0, 255, 255, 0.3) 0%, transparent 60%);
    border-color: #00ffff;
    box-shadow: 
        0 0 40px rgba(0, 255, 255, 0.6),
        0 0 0 2px rgba(0, 255, 255, 0.4),
        inset 0 0 20px rgba(0, 255, 255, 0.1);
    animation: activeTerminalPulse 2s ease-in-out infinite;
}

.source-terminal.connected {
    background: 
        linear-gradient(135deg, rgba(0, 255, 100, 0.2) 0%, rgba(0, 200, 50, 0.2) 100%),
        radial-gradient(circle at 10% 50%, rgba(0, 255, 0, 0.2) 0%, transparent 60%);
    border-color: #00ff88;
    box-shadow: 
        0 0 30px rgba(0, 255, 136, 0.4),
        inset 0 0 15px rgba(0, 255, 0, 0.1);
}

.source-terminal.hint {
    animation: premiumHintPulse 1.5s ease-in-out infinite;
}

@keyframes activeTerminalPulse {
    0%, 100% { 
        box-shadow: 
            0 0 40px rgba(0, 255, 255, 0.6),
            0 0 0 2px rgba(0, 255, 255, 0.4),
            inset 0 0 20px rgba(0, 255, 255, 0.1);
    }
    50% { 
        box-shadow: 
            0 0 60px rgba(0, 255, 255, 0.8),
            0 0 0 3px rgba(0, 255, 255, 0.6),
            inset 0 0 30px rgba(0, 255, 255, 0.2);
    }
}

@keyframes premiumHintPulse {
    0%, 100% { 
        box-shadow: 
            0 8px 32px rgba(0, 0, 0, 0.4),
            0 0 0 2px rgba(255, 255, 0, 0.4);
    }
    50% { 
        box-shadow: 
            0 12px 48px rgba(255, 255, 0, 0.3),
            0 0 0 4px rgba(255, 255, 0, 0.8);
        transform: translateY(-3px) scale(1.05);
    }
}

/* Premium terminal connectors */
.terminal-connector {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    border: 3px solid transparent;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    background-clip: padding-box;
}

.terminal-connector::before {
    content: '';
    position: absolute;
    top: -3px;
    left: -3px;
    right: -3px;
    bottom: -3px;
    border-radius: 50%;
    padding: 3px;
    background: linear-gradient(45deg, currentColor, transparent, currentColor);
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: exclude;
    mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    mask-composite: exclude;
}

.terminal-connector::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 8px;
    height: 8px;
    background: currentColor;
    border-radius: 50%;
    transform: translate(-50%, -50%);
    box-shadow: 0 0 10px currentColor;
    animation: connectorPulse 2s ease-in-out infinite;
}

@keyframes connectorPulse {
    0%, 100% { 
        transform: translate(-50%, -50%) scale(1);
        opacity: 0.8;
    }
    50% { 
        transform: translate(-50%, -50%) scale(1.2);
        opacity: 1;
    }
}

.terminal-connector.red {
    background: radial-gradient(circle, #ff6666 0%, #ff0000 100%);
        color: #00bfff;
    box-shadow: 
        0 0 20px rgba(255, 0, 0, 0.6),
        inset 0 2px 4px rgba(255, 255, 255, 0.3),
        inset 0 -2px 4px rgba(0, 0, 0, 0.3);
}

.terminal-connector.blue {
    background: radial-gradient(circle, #6666ff 0%, #0000ff 100%);
    color: #0000ff;
    box-shadow: 
        0 0 20px rgba(0, 0, 255, 0.6),
        inset 0 2px 4px rgba(255, 255, 255, 0.3),
        inset 0 -2px 4px rgba(0, 0, 0, 0.3);
}

.terminal-connector.yellow {
    background: radial-gradient(circle, #ffff66 0%, #ffdd00 100%);
    color: #ffdd00;
    box-shadow: 
        0 0 20px rgba(255, 221, 0, 0.6),
        inset 0 2px 4px rgba(255, 255, 255, 0.3),
        inset 0 -2px 4px rgba(0, 0, 0, 0.3);
}

.terminal-connector.green {
    background: radial-gradient(circle, #66ff66 0%, #00ff00 100%);
    color: #00ff00;
    box-shadow: 
        0 0 20px rgba(0, 255, 0, 0.6),
        inset 0 2px 4px rgba(255, 255, 255, 0.3),
        inset 0 -2px 4px rgba(0, 0, 0, 0.3);
}

.terminal-connector.purple {
    background: radial-gradient(circle, #ff66ff 0%, #ff00ff 100%);
    color: #ff00ff;
    box-shadow: 
        0 0 20px rgba(255, 0, 255, 0.6),
        inset 0 2px 4px rgba(255, 255, 255, 0.3),
        inset 0 -2px 4px rgba(0, 0, 0, 0.3);
}

.terminal-connector:hover {
    transform: scale(1.15);
    filter: brightness(1.3);
}

.terminal-connector:hover::after {
    animation-duration: 1s;
}

.terminal-label {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.power-icon {
    font-size: 18px;
}

.power-name, .infrastructure-name {
    font-weight: bold;
    color: #ffffff;
    font-size: 14px;
}

.power-capacity, .power-need {
    color: #aaaaaa;
    font-size: 12px;
}

/* Premium wire connection area (center) */
.wire-connection-area {
    position: relative;
    width: 500px;
    height: 380px;
    background: 
        radial-gradient(ellipse at center, rgba(0, 20, 40, 0.9) 0%, rgba(0, 5, 15, 0.95) 100%),
        linear-gradient(45deg, transparent 0%, rgba(0, 255, 255, 0.02) 50%, transparent 100%);
    border: 2px solid rgba(0, 255, 255, 0.2);
    border-radius: 20px;
    overflow: hidden;
    backdrop-filter: blur(15px);
    box-shadow: 
        0 0 40px rgba(0, 0, 0, 0.6),
        inset 0 0 40px rgba(0, 255, 255, 0.05),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.wire-connection-area::before {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    background: linear-gradient(45deg, 
        rgba(0, 255, 255, 0.3) 0%, 
        rgba(255, 0, 255, 0.3) 25%,
        rgba(255, 255, 0, 0.3) 50%,
        rgba(0, 255, 0, 0.3) 75%,
        rgba(0, 255, 255, 0.3) 100%);
    border-radius: 20px;
    z-index: -1;
    animation: connectionAreaGlow 6s linear infinite;
}

@keyframes connectionAreaGlow {
    0% { filter: hue-rotate(0deg) brightness(0.8); }
    50% { filter: hue-rotate(180deg) brightness(1.2); }
    100% { filter: hue-rotate(360deg) brightness(0.8); }
}

.wire-canvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10;
    cursor: crosshair;
    border-radius: 18px;
}

.tangled-wires {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
    opacity: 0.3;
}

.background-wires {
    width: 100%;
    height: 100%;
    filter: drop-shadow(0 0 5px rgba(255, 255, 255, 0.1));
}

/* Premium electrical sparks */
.electrical-sparks {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 5;
    pointer-events: none;
}

.spark {
    position: absolute;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: radial-gradient(circle, #ffffff 0%, #ffff00 50%, transparent 100%);
    box-shadow: 
        0 0 15px #ffff00,
        0 0 30px #ffff00,
        0 0 45px rgba(255, 255, 0, 0.5);
    animation: premiumSparkle 0.8s ease-in-out infinite;
}

.spark::before {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.8) 0%, transparent 70%);
    border-radius: 50%;
    animation: sparkHalo 1.2s ease-in-out infinite;
}

.spark-1 {
    top: 25%;
    left: 35%;
    animation-delay: 0s;
}

.spark-2 {
    top: 65%;
    left: 75%;
    animation-delay: 0.3s;
}

.spark-3 {
    top: 85%;
    left: 25%;
    animation-delay: 0.6s;
}

.spark-4 {
    top: 15%;
    left: 80%;
    animation-delay: 0.9s;
}

.spark-5 {
    top: 45%;
    left: 15%;
    animation-delay: 1.2s;
}

@keyframes premiumSparkle {
    0%, 100% { 
        opacity: 0;
        transform: scale(0.5);
    }
    50% { 
        opacity: 1;
        transform: scale(1.5);
    }
}

@keyframes sparkHalo {
    0%, 100% { 
        opacity: 0;
        transform: scale(1);
    }
    50% { 
        opacity: 0.6;
        transform: scale(2);
    }
}

/* Energy flow particles */
.energy-particles {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 3;
    pointer-events: none;
}

.energy-particle {
    position: absolute;
    width: 3px;
    height: 3px;
    background: radial-gradient(circle, #00ffff 0%, transparent 70%);
    border-radius: 50%;
    animation: particleFlow 4s linear infinite;
}

@keyframes particleFlow {
    0% {
        opacity: 0;
        transform: translateX(-50px) translateY(0px);
    }
    10% {
        opacity: 1;
    }
    90% {
        opacity: 1;
    }
    100% {
        opacity: 0;
        transform: translateX(550px) translateY(-20px);
    }
}

/* Premium wire targets (right side) */
.wire-targets {
    display: flex;
    flex-direction: column;
    gap: 20px;
    width: 320px;
    z-index: 10;
}

.target-terminal {
    display: flex;
    align-items: center;
    gap: 20px;
    padding: 18px 24px;
    background: 
        linear-gradient(135deg, rgba(60, 30, 0, 0.9) 0%, rgba(40, 15, 0, 0.9) 100%),
        radial-gradient(circle at 90% 50%, rgba(255, 136, 0, 0.1) 0%, transparent 60%);
    border: 2px solid rgba(255, 136, 0, 0.3);
    border-radius: 16px;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    flex-direction: row-reverse;
    position: relative;
    backdrop-filter: blur(10px);
    box-shadow: 
        0 8px 32px rgba(0, 0, 0, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.target-terminal::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, 
        rgba(255, 136, 0, 0.1) 0%, 
        transparent 50%, 
        rgba(255, 255, 255, 0.05) 100%);
    border-radius: 14px;
    opacity: 0;
    transition: opacity 0.4s ease;
}

.target-terminal:hover {
    background: 
        linear-gradient(135deg, rgba(100, 50, 0, 0.95) 0%, rgba(60, 25, 0, 0.95) 100%),
        radial-gradient(circle at 90% 50%, rgba(255, 136, 0, 0.2) 0%, transparent 60%);
    border-color: rgba(255, 136, 0, 0.6);
    box-shadow: 
        0 12px 48px rgba(255, 136, 0, 0.2),
        0 0 0 1px rgba(255, 136, 0, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
    transform: translateY(-2px) scale(1.02);
}

.target-terminal:hover::before {
    opacity: 1;
}

.target-terminal.highlight {
    background: 
        linear-gradient(135deg, rgba(255, 255, 0, 0.2) 0%, rgba(255, 200, 0, 0.2) 100%),
        radial-gradient(circle at 90% 50%, rgba(255, 255, 0, 0.3) 0%, transparent 60%);
    border-color: #ffff00;
    box-shadow: 
        0 0 40px rgba(255, 255, 0, 0.6),
        0 0 0 2px rgba(255, 255, 0, 0.4),
        inset 0 0 20px rgba(255, 255, 0, 0.1);
    animation: targetHighlight 1s ease-in-out infinite;
}

.target-terminal.connected {
    background: 
        linear-gradient(135deg, rgba(0, 255, 100, 0.2) 0%, rgba(0, 200, 50, 0.2) 100%),
        radial-gradient(circle at 90% 50%, rgba(0, 255, 0, 0.2) 0%, transparent 60%);
    border-color: #00ff88;
    box-shadow: 
        0 0 30px rgba(0, 255, 136, 0.4),
        inset 0 0 15px rgba(0, 255, 0, 0.1);
}

.target-terminal.hint {
    animation: premiumHintPulse 1.5s ease-in-out infinite;
}

@keyframes targetHighlight {
    0%, 100% { 
        box-shadow: 
            0 0 40px rgba(255, 255, 0, 0.6),
            0 0 0 2px rgba(255, 255, 0, 0.4),
            inset 0 0 20px rgba(255, 255, 0, 0.1);
    }
    50% { 
        box-shadow: 
            0 0 60px rgba(255, 255, 0, 0.9),
            0 0 0 4px rgba(255, 255, 0, 0.7),
            inset 0 0 30px rgba(255, 255, 0, 0.2);
        transform: translateY(-1px) scale(1.03);
    }
}

.infrastructure-icon {
    font-size: 18px;
}

/* Game status */
.wire-game-status {
    position: absolute;
    top: 20px;
    right: 20px;
    background: rgba(0, 0, 0, 0.8);
    padding: 15px;
    border-radius: 10px;
    border: 1px solid #00ffff;
    min-width: 200px;
}

.status-section {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 15px;
}

.status-section:last-child {
    margin-bottom: 0;
}

.connections-status, .power-status {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.status-label {
    color: #aaaaaa;
    font-size: 12px;
}

.status-value {
    color: #ffffff;
    font-weight: bold;
    font-size: 14px;
}

/* Stability meter */
.stability-meter {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.meter-label {
    color: #aaaaaa;
    font-size: 12px;
}

.stability-bar {
    width: 100%;
    height: 8px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    overflow: hidden;
}

.stability-fill {
    height: 100%;
    background: linear-gradient(90deg, #ff4444 0%, #ffff44 50%, #44ff44 100%);
    transition: width 0.5s ease;
    border-radius: 4px;
}

.stability-percentage {
    color: #ffffff;
    font-weight: bold;
    font-size: 12px;
    text-align: center;
}

/* Premium wire controls */
.wire-controls {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 20px;
    z-index: 20;
}

.wire-btn {
    padding: 14px 28px;
    background: 
        linear-gradient(135deg, rgba(0, 30, 60, 0.9) 0%, rgba(0, 15, 40, 0.9) 100%),
        radial-gradient(circle at center, rgba(0, 255, 255, 0.1) 0%, transparent 70%);
    border: 2px solid rgba(0, 255, 255, 0.4);
    border-radius: 12px;
    color: #ffffff;
    font-weight: bold;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    backdrop-filter: blur(10px);
    box-shadow: 
        0 8px 25px rgba(0, 0, 0, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.wire-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, 
        rgba(255, 255, 255, 0.1) 0%, 
        transparent 50%, 
        rgba(0, 255, 255, 0.1) 100%);
    border-radius: 10px;
    opacity: 0;
    transition: opacity 0.4s ease;
}

.wire-btn:hover {
    background: 
        linear-gradient(135deg, rgba(0, 50, 100, 0.95) 0%, rgba(0, 25, 60, 0.95) 100%),
        radial-gradient(circle at center, rgba(0, 255, 255, 0.2) 0%, transparent 70%);
    border-color: rgba(0, 255, 255, 0.8);
    box-shadow: 
        0 12px 35px rgba(0, 255, 255, 0.3),
        0 0 0 1px rgba(0, 255, 255, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.3);
    transform: translateY(-3px) scale(1.05);
}

.wire-btn:hover::before {
    opacity: 1;
}

.wire-btn:active {
    transform: translateY(-1px) scale(1.02);
    box-shadow: 
        0 6px 20px rgba(0, 255, 255, 0.2),
        inset 0 2px 4px rgba(0, 0, 0, 0.2);
}

.wire-btn:disabled {
    background: 
        linear-gradient(135deg, rgba(50, 50, 50, 0.7) 0%, rgba(30, 30, 30, 0.7) 100%);
    border-color: rgba(100, 100, 100, 0.3);
    color: rgba(150, 150, 150, 0.7);
    cursor: not-allowed;
    transform: none;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.wire-btn:disabled::before {
    opacity: 0;
}

.wire-btn.reset-btn {
    background: 
        linear-gradient(135deg, rgba(60, 30, 0, 0.9) 0%, rgba(40, 15, 0, 0.9) 100%),
        radial-gradient(circle at center, rgba(255, 136, 0, 0.1) 0%, transparent 70%);
    border-color: rgba(255, 136, 0, 0.4);
}

.wire-btn.reset-btn:hover {
    background: 
        linear-gradient(135deg, rgba(100, 50, 0, 0.95) 0%, rgba(60, 25, 0, 0.95) 100%),
        radial-gradient(circle at center, rgba(255, 136, 0, 0.2) 0%, transparent 70%);
    border-color: rgba(255, 136, 0, 0.8);
    box-shadow: 
        0 12px 35px rgba(255, 136, 0, 0.3),
        0 0 0 1px rgba(255, 136, 0, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

.wire-btn.hint-btn {
    background: 
        linear-gradient(135deg, rgba(60, 60, 0, 0.9) 0%, rgba(40, 40, 0, 0.9) 100%),
        radial-gradient(circle at center, rgba(255, 255, 0, 0.1) 0%, transparent 70%);
    border-color: rgba(255, 255, 0, 0.4);
}

.wire-btn.hint-btn:hover {
    background: 
        linear-gradient(135deg, rgba(100, 100, 0, 0.95) 0%, rgba(60, 60, 0, 0.95) 100%),
        radial-gradient(circle at center, rgba(255, 255, 0, 0.2) 0%, transparent 70%);
    border-color: rgba(255, 255, 0, 0.8);
    box-shadow: 
        0 12px 35px rgba(255, 255, 0, 0.3),
        0 0 0 1px rgba(255, 255, 0, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

.wire-btn.complete-btn {
    background: 
        linear-gradient(135deg, rgba(0, 60, 30, 0.9) 0%, rgba(0, 40, 15, 0.9) 100%),
        radial-gradient(circle at center, rgba(0, 255, 100, 0.1) 0%, transparent 70%);
    border-color: rgba(0, 255, 100, 0.4);
}

.wire-btn.complete-btn:hover {
    background: 
        linear-gradient(135deg, rgba(0, 100, 50, 0.95) 0%, rgba(0, 60, 25, 0.95) 100%),
        radial-gradient(circle at center, rgba(0, 255, 100, 0.2) 0%, transparent 70%);
    border-color: rgba(0, 255, 100, 0.8);
    box-shadow: 
        0 12px 35px rgba(0, 255, 100, 0.3),
        0 0 0 1px rgba(0, 255, 100, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

/* Urgency indicator */
.urgency-indicator {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 10px;
    padding: 10px;
    background: rgba(255, 0, 0, 0.2);
    border: 1px solid #ff4444;
    border-radius: 5px;
}

.urgency-text {
    color: #00bfff;
    font-weight: bold;
    animation: urgentBlink 1s infinite;
}

.time-pressure {
    color: #ffffff;
    font-weight: bold;
}

/* Premium success effects */
.source-terminal.success-glow,
.target-terminal.success-glow {
    background: 
        linear-gradient(135deg, rgba(0, 255, 100, 0.4) 0%, rgba(0, 200, 50, 0.4) 100%),
        radial-gradient(circle at center, rgba(0, 255, 0, 0.3) 0%, transparent 70%);
    border-color: #00ff88;
    box-shadow: 
        0 0 50px rgba(0, 255, 136, 0.8),
        0 0 0 3px rgba(0, 255, 136, 0.6),
        inset 0 0 30px rgba(0, 255, 0, 0.2);
    animation: premiumSuccessPulse 2s ease-in-out infinite;
}

@keyframes premiumSuccessPulse {
    0%, 100% { 
        box-shadow: 
            0 0 50px rgba(0, 255, 136, 0.8),
            0 0 0 3px rgba(0, 255, 136, 0.6),
            inset 0 0 30px rgba(0, 255, 0, 0.2);
        transform: scale(1);
    }
    50% { 
        box-shadow: 
            0 0 80px rgba(0, 255, 136, 1),
            0 0 0 5px rgba(0, 255, 136, 0.8),
            inset 0 0 50px rgba(0, 255, 0, 0.4);
        transform: scale(1.02);
    }
}

/* Animations */
@keyframes hintPulse {
    0%, 100% {
        box-shadow: 0 0 15px rgba(255, 255, 0, 0.3);
    }
    50% {
        box-shadow: 0 0 30px rgba(255, 255, 0, 0.8);
    }
}

@keyframes electricalSpark {
    0%, 100% {
        opacity: 0;
        transform: scale(0.5);
    }
    50% {
        opacity: 1;
        transform: scale(1.5);
    }
}

@keyframes urgentBlink {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.5;
    }
}

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

@keyframes successPulse {
    0%, 100% {
        box-shadow: 0 0 25px rgba(0, 255, 0, 0.6);
    }
    50% {
        box-shadow: 0 0 40px rgba(0, 255, 0, 1);
    }
}

/* Responsive design for wire game */
@media (max-width: 1200px) {
    .wire-connection-panel {
        width: 95%;
        height: 350px;
        padding: 15px;
    }
    
    .wire-sources, .wire-targets {
        width: 200px;
    }
    
    .wire-connection-area {
        width: 300px;
        height: 250px;
    }
}

@media (max-width: 900px) {
    .wire-connection-panel {
        flex-direction: column;
        height: auto;
        gap: 20px;
    }
    
    .wire-sources, .wire-targets {
        width: 100%;
        flex-direction: row;
        justify-content: space-around;
    }
    
    .wire-connection-area {
        width: 100%;
        height: 200px;
    }
    
    .source-terminal, .target-terminal {
        flex-direction: column;
        text-align: center;
        min-width: 80px;
    }
    
    /* Engineer character mobile adjustments */
    .engineer-character {
        bottom: 20px;
        right: 20px;
        transform: scale(0.7);
    }
    
    .engineer-avatar {
        width: 150px;
    }
    
    .among-us-bg-image {
        width: 95%;
        height: 95%;
        opacity: 0.1;
    }
}

/* ===== MOBILE OPTIMIZATIONS ===== */
@media (max-width: 480px) {
    .engineer-character {
        bottom: 10px;
        right: 10px;
        transform: scale(0.5);
    }
    
    .engineer-avatar {
        width: 120px;
    }
    
    .control-room-bg-image,
    .power-grid-bg-image {
        opacity: 0.2;
    }
    
    .among-us-bg-image {
        opacity: 0.08;
    }
    
    .source-terminal,
    .target-terminal {
        padding: 10px 15px;
        gap: 12px;
    }
    
    .terminal-connector {
        width: 20px;
        height: 20px;
    }
    
    .wire-btn {
        padding: 10px 20px;
        font-size: 12px;
    }
}

/* ===== CHAPTER 4: AURORA HUNTER - LILA ===== */

/* Camera Vision Game Styles */
.camera-vision-game {
    position: relative;
    width: 100vw;
    height: 100vh;
    overflow: hidden;
    background: #000;
}

.aurora-background-layer {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.aurora-source-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

.camera-vision-interface {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10;
}

/* Black overlay covering the entire screen */
.camera-black-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #000;
    z-index: 2;
}

/* Circular viewfinder in the center */
.camera-viewfinder-circle {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 400px;
    height: 400px;
    border-radius: 50%;
    overflow: hidden;
    border: 4px solid #fff;
    box-shadow: 
        0 0 0 8px rgba(255, 255, 255, 0.3),
        0 0 0 16px rgba(255, 255, 255, 0.1),
        inset 0 0 30px rgba(0, 0, 0, 0.3);
    z-index: 3;
    background: #000;
}

.viewfinder-content {
    position: relative;
    width: 100%;
    height: 100%;
}

.viewfinder-aurora {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

/* Blur overlay for incorrect camera settings */
.camera-blur-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: transparent;
    backdrop-filter: blur(0px) brightness(1) contrast(1);
    transition: all 0.3s ease;
    z-index: 1;
}

/* Camera UI elements inside viewfinder */
.viewfinder-ui {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 2;
}

.crosshairs {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 60px;
    height: 60px;
}

.crosshair-line {
    position: absolute;
    background: rgba(255, 255, 255, 0.8);
}

.crosshair-line.horizontal {
    top: 50%;
    left: 20%;
    right: 20%;
    height: 1px;
    transform: translateY(-50%);
}

.crosshair-line.vertical {
    left: 50%;
    top: 20%;
    bottom: 20%;
    width: 1px;
    transform: translateX(-50%);
}

.focus-indicator {
    position: absolute;
    top: 20px;
    left: 20px;
    color: #00ff00;
    font-size: 16px;
    font-weight: bold;
    text-shadow: 0 0 4px rgba(0, 255, 0, 0.5);
    transition: color 0.3s ease;
}

.focus-indicator.poor {
    color: #00bfff;
    text-shadow: 0 0 4px rgba(255, 68, 68, 0.5);
}

.focus-indicator.good {
    color: #ffaa00;
    text-shadow: 0 0 4px rgba(255, 170, 0, 0.5);
}

.focus-indicator.perfect {
    color: #00ff00;
    text-shadow: 0 0 4px rgba(0, 255, 0, 0.5);
}

/* Exposure meter */
.exposure-meter {
    position: absolute;
    top: 20px;
    right: 20px;
    width: 80px;
    height: 20px;
    background: rgba(0, 0, 0, 0.7);
    border: 1px solid rgba(255, 255, 255, 0.5);
    border-radius: 10px;
    padding: 2px;
}

.meter-segments {
    display: flex;
    width: 100%;
    height: 100%;
    gap: 1px;
}

.meter-segment {
    flex: 1;
    height: 100%;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 1px;
    transition: background-color 0.3s ease;
}

.meter-segment.active {
    background: #00ff00;
}

.meter-segment.overexposed {
    background: #ff4444;
}

.meter-segment.underexposed {
    background: #4444ff;
}

/* Camera Settings Sidebar */
.camera-settings-sidebar {
    position: absolute;
    top: 20px;
    left: 20px;
    width: 280px;
    background: rgba(0, 0, 0, 0.9);
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 15px;
    padding: 20px;
    backdrop-filter: blur(10px);
    z-index: 4;
}

.camera-settings-sidebar h3 {
    color: #fff;
    text-align: center;
    margin: 0 0 20px 0;
    font-size: 18px;
    text-shadow: 0 0 4px rgba(255, 255, 255, 0.3);
}

.setting-group {
    margin-bottom: 20px;
}

.setting-group label {
    display: block;
    color: #fff;
    font-size: 14px;
    font-weight: bold;
    margin-bottom: 8px;
    text-shadow: 0 0 2px rgba(255, 255, 255, 0.3);
}

.setting-slider {
    width: 100%;
    height: 6px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 3px;
    outline: none;
    appearance: none;
    margin-bottom: 8px;
}

.setting-slider::-webkit-slider-thumb {
    appearance: none;
    width: 20px;
    height: 20px;
    background: linear-gradient(135deg, #4a90e2, #2171b5);
    border-radius: 50%;
    cursor: pointer;
    box-shadow: 0 0 8px rgba(74, 144, 226, 0.5);
    transition: all 0.2s ease;
}

.setting-slider::-webkit-slider-thumb:hover {
    transform: scale(1.1);
    box-shadow: 0 0 12px rgba(74, 144, 226, 0.8);
}

.setting-value {
    display: inline-block;
    color: #4a90e2;
    font-weight: bold;
    font-size: 14px;
    min-width: 50px;
    text-align: right;
}

.feedback-section {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    padding: 15px;
    margin: 20px 0;
}

.feedback-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}

.feedback-item:last-child {
    margin-bottom: 0;
}

.feedback-label {
    color: #ccc;
    font-size: 13px;
}

.feedback-value {
    font-weight: bold;
    font-size: 13px;
    padding: 2px 8px;
    border-radius: 4px;
}

.feedback-value.poor {
    color: #00bfff;
    background: rgba(255, 68, 68, 0.2);
}

.feedback-value.good {
    color: #ffaa00;
    background: rgba(255, 170, 0, 0.2);
}

.feedback-value.perfect {
    color: #00ff00;
    background: rgba(0, 255, 0, 0.2);
}

.capture-button {
    width: 100%;
    padding: 15px;
    background: linear-gradient(135deg, #ff6b35, #f7931e);
    color: #fff;
    border: none;
    border-radius: 10px;
    font-size: 16px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
    box-shadow: 0 4px 15px rgba(255, 107, 53, 0.3);
    margin: 20px 0;
}

.capture-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(255, 107, 53, 0.4);
}

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

.timer-display {
    text-align: center;
    color: #fff;
    font-size: 14px;
    font-weight: bold;
}

/* Photo Result Modal */
.photo-result-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.9);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    backdrop-filter: blur(5px);
}

.photo-result-modal.hidden {
    display: none;
}

.modal-content {
    background: rgba(20, 20, 20, 0.95);
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 20px;
    padding: 30px;
    max-width: 600px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
    text-align: center;
}

.captured-photo-frame {
    position: relative;
    margin-bottom: 20px;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.5);
}

.captured-photo {
    width: 100%;
    height: 300px;
    object-fit: cover;
    display: block;
}

.photo-quality-overlay {
    position: absolute;
    top: 10px;
    left: 10px;
    right: 10px;
    background: rgba(0, 0, 0, 0.8);
    border-radius: 8px;
    padding: 10px;
}

.quality-text {
    color: #fff;
    font-size: 18px;
    font-weight: bold;
    margin-bottom: 5px;
}

.score-text {
    color: #4a90e2;
    font-size: 14px;
}

.photo-feedback {
    margin-bottom: 20px;
}

.feedback-text {
    color: #ccc;
    font-size: 16px;
    line-height: 1.5;
    margin-bottom: 20px;
}

.science-fact-section {
    background: rgba(74, 144, 226, 0.1);
    border: 1px solid rgba(74, 144, 226, 0.3);
    border-radius: 10px;
    padding: 20px;
    margin: 20px 0;
    text-align: left;
}

.science-fact-section h4 {
    color: #4a90e2;
    margin: 0 0 10px 0;
}

.science-fact-section p {
    color: #ccc;
    line-height: 1.6;
    margin: 0;
}

/* Science Summary Section */
.science-summary {
    background: rgba(0, 150, 255, 0.1);
    border: 2px solid rgba(0, 150, 255, 0.3);
    border-radius: 15px;
    padding: 25px;
    margin: 30px 0;
    backdrop-filter: blur(10px);
    box-shadow: 0 0 20px rgba(0, 150, 255, 0.2);
}

.science-summary h3 {
    color: #00aaff;
    font-size: 24px;
    font-weight: bold;
    margin: 0 0 20px 0;
    text-align: center;
    text-shadow: 0 0 10px rgba(0, 170, 255, 0.8);
    background: linear-gradient(45deg, #00aaff, #ffffff);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.science-fact {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 15px;
    margin: 10px 0;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 10px;
    border-left: 4px solid #00aaff;
    transition: all 0.3s ease;
}

.science-fact:hover {
    background: rgba(0, 150, 255, 0.1);
    border-left-color: #00ff88;
    transform: translateX(5px);
    box-shadow: 0 0 15px rgba(0, 150, 255, 0.2);
}

.fact-icon {
    font-size: 24px;
    min-width: 30px;
    text-align: center;
}

.fact-text {
    color: #ffffff;
    font-size: 16px;
    line-height: 1.5;
    font-weight: 500;
    text-shadow: 0 0 5px rgba(0, 150, 255, 0.5);
}

/* Responsive styles for science summary */
@media (max-width: 768px) {
    .science-summary {
        padding: 20px;
        margin: 20px 0;
    }
    
    .science-summary h3 {
        font-size: 20px;
    }
    
    .science-fact {
        padding: 12px;
        gap: 12px;
    }
    
    .fact-icon {
        font-size: 20px;
        min-width: 25px;
    }
    
    .fact-text {
        font-size: 14px;
    }
}

.medal-section {
    background: rgba(255, 215, 0, 0.1);
    border: 1px solid rgba(255, 215, 0, 0.3);
    border-radius: 10px;
    padding: 20px;
    margin: 20px 0;
}

.medal-display {
    font-size: 48px;
    margin-bottom: 10px;
    animation: medalGlow 2s ease-in-out infinite alternate;
}

@keyframes medalGlow {
    from {
        text-shadow: 0 0 10px rgba(255, 215, 0, 0.5);
        transform: scale(1);
    }
    to {
        text-shadow: 0 0 20px rgba(255, 215, 0, 0.8);
        transform: scale(1.05);
    }
}

.medal-section p {
    color: #ffd700;
    font-weight: bold;
    margin: 0;
}

/* Arctic Scene Base */
.arctic-scene {
    position: relative;
    width: 100%;
    height: 100vh;
    overflow: hidden;
    background: linear-gradient(to bottom, #0a0f23 0%, #1a1a2e 50%, #2a2a3e 100%);
}

.arctic-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.arctic-sky {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 70%;
    background: linear-gradient(to bottom, 
        #0a0f23 0%, 
        #1a1a2e 30%, 
        #2a2a3e 60%, 
        #3a3a4e 100%);
    animation: skyShimmer 8s ease-in-out infinite;
}

.arctic-ground {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 30%;
    background: linear-gradient(to bottom, 
        #e8f4f8 0%, 
        #d0e8f0 50%, 
        #b8dce8 100%);
    border-radius: 50% 50% 0 0;
    transform: scaleX(1.2);
}

.arctic-trees {
    position: absolute;
    bottom: 25%;
    left: 0;
    width: 100%;
    height: 15%;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 20"><polygon points="10,20 15,5 20,20" fill="%23003300"/><polygon points="30,20 35,3 40,20" fill="%23004400"/><polygon points="60,20 65,7 70,20" fill="%23002200"/><polygon points="80,20 85,4 90,20" fill="%23003300"/></svg>') repeat-x;
    opacity: 0.6;
}

.arctic-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(ellipse at center, transparent 30%, rgba(10, 15, 35, 0.3) 100%);
    z-index: 2;
}

.storm-overlay {
    background: radial-gradient(ellipse at center, rgba(255, 200, 0, 0.1) 20%, rgba(10, 15, 35, 0.5) 100%);
    animation: stormPulse 3s ease-in-out infinite;
}

/* Photographer Character */
.photographer-character {
    margin-top: 250px;
    position: relative;
    display: flex;
    z-index: 10;
    

    flex-direction: column;
    height: 750px;
    align-items: center;

    
    /* transition: all 0.5s ease; */
}

.photographer-avatar {
    position: relative;
    width: 500px;
    height: 500px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
}

.photographer-image {
    width: 100%;
    height: 100%;
    object-fit: contain;
    border-radius: 10px;
    /* box-shadow: 0 0 20px rgba(74, 144, 226, 0.3); */
    transition: all 0.5s ease;
}

.interview-mode .photographer-image {
    box-shadow: 0 0 25px rgba(200, 150, 255, 0.5);
    filter: brightness(1.1) saturate(1.2);
    transform: scale(1.1);
}

.photographer-character:hover .photographer-image {
    transform: scale(1.05);
    /* box-shadow: 0 0 30px rgba(74, 144, 226, 0.6); */
}

.photographer-body {
    width: 60px;
    height: 80px;
    background: linear-gradient(to bottom, #4a90e2 0%, #2c5aa0 100%);
    border-radius: 30px 30px 10px 10px;
    position: relative;
    box-shadow: 0 0 20px rgba(74, 144, 226, 0.3);
}

.photographer-body::before {
    content: '';
    position: absolute;
    top: -25px;
    left: 50%;
    transform: translateX(-50%);
    width: 30px;
    height: 30px;
    background: #ffdbac;
    border-radius: 50%;
    box-shadow: 0 0 10px rgba(255, 219, 172, 0.5);
}

.photographer-body::after {
    content: '';
    position: absolute;
    top: -15px;
    left: 50%;
    transform: translateX(-50%);
    width: 35px;
    height: 20px;
    background: #8b4513;
    border-radius: 20px 20px 0 0;
}

.photographer-camera {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    width: 25px;
    height: 15px;
    background: #333;
    border-radius: 3px;
    box-shadow: 0 0 10px rgba(255, 255, 255, 0.3);
}

.photographer-camera::before {
    content: '';
    position: absolute;
    top: -5px;
    left: 50%;
    transform: translateX(-50%);
    width: 12px;
    height: 8px;
    background: #555;
    border-radius: 50%;
    border: 2px solid #777;
}

.photographer-tripod {
    position: absolute;
    bottom: -20px;
    left: 50%;
    transform: translateX(-50%);
    width: 3px;
    height: 40px;
    background: #666;
    border-radius: 2px;
}

.photographer-tripod::before,
.photographer-tripod::after {
    content: '';
    position: absolute;
    bottom: 0;
    width: 20px;
    height: 2px;
    background: #666;
    border-radius: 1px;
}

.photographer-tripod::before {
    left: -8px;
    transform: rotate(-30deg);
}

.photographer-tripod::after {
    right: -8px;
    transform: rotate(30deg);
}

.photographer-glow {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 120px;
    height: 120px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(100, 200, 255, 0.3) 0%, transparent 70%);
    animation: photographerGlow 4s ease-in-out infinite;
    z-index: -1;
}

.alert-glow {
    background: radial-gradient(circle, rgba(255, 200, 0, 0.4) 0%, transparent 70%);
    animation: alertGlow 2s ease-in-out infinite;
}

.interview-glow {
    background: radial-gradient(circle, rgba(200, 150, 255, 0.3) 0%, transparent 70%);
    animation: interviewGlow 5s ease-in-out infinite;
}

/* Camera Equipment */
.camera-equipment {
    position: absolute;
    top: 20%;
    left: 10%;
    z-index: 5;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.camera-display {
    background: rgba(0, 0, 0, 0.8);
    border: 2px solid #4a90e2;
    border-radius: 10px;
    padding: 15px;
    box-shadow: 0 0 20px rgba(74, 144, 226, 0.3);
}

.camera-screen {
    width: 200px;
    height: 150px;
    background: #111;
    border-radius: 5px;
    position: relative;
    overflow: hidden;
}

.viewfinder {
    width: 100%;
    height: 100%;
    position: relative;
    background: linear-gradient(45deg, #001122 0%, #002244 100%);
}

.viewfinder-grid {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        linear-gradient(rgba(255, 255, 255, 0.2) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.2) 1px, transparent 1px);
    background-size: 33.33% 33.33%;
    opacity: 0.3;
}

.camera-settings {
    position: absolute;
    bottom: 10px;
    left: 10px;
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.setting {
    background: rgba(0, 0, 0, 0.7);
    padding: 3px 8px;
    border-radius: 3px;
    font-size: 12px;
    color: #00ff88;
    font-family: 'Courier New', monospace;
}

.weather-station {
    background: rgba(0, 0, 0, 0.8);
    border: 2px solid #00ff88;
    border-radius: 10px;
    padding: 15px;
    box-shadow: 0 0 20px rgba(0, 255, 136, 0.3);
}

.weather-display {
    display: flex;
    flex-direction: column;
    gap: 8px;
    color: #00ff88;
    font-family: 'Courier New', monospace;
    font-size: 14px;
}

/* Space Weather Alert */
.space-weather-alert {
    position: absolute;
    top: 10%;
    right: 10%;
    background: rgba(255, 100, 0, 0.1);
    border: 2px solid #ff6400;
    border-radius: 15px;
    padding: 20px;
    box-shadow: 0 0 30px rgba(255, 100, 0, 0.4);
    z-index: 15;
    min-width: 250px;
}

.alert-header {
    font-size: 18px;
    font-weight: bold;
    color: #ff6400;
    text-align: center;
    margin-bottom: 15px;
    text-shadow: 0 0 10px rgba(255, 100, 0, 0.5);
}

.alert-content {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.alert-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.alert-label {
    color: #ccc;
    font-size: 14px;
}

.alert-value {
    color: #fff;
    font-weight: bold;
    font-size: 14px;
}

.kp-high {
    color: #00bfff;
    text-shadow: 0 0 5px rgba(255, 68, 68, 0.5);
    animation: kpPulse 1s ease-in-out infinite;
}

/* Aurora Background */
.aurora-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to bottom, #0a0f23 0%, #1a1a2e 100%);
    overflow: hidden;
}

.aurora-layer {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0.7;
    mix-blend-mode: screen;
}

.aurora-green {
    background: radial-gradient(ellipse 80% 30% at 50% 20%, 
        rgba(0, 255, 100, 0.4) 0%, 
        rgba(0, 255, 100, 0.2) 30%, 
        transparent 60%);
    animation: auroraWave 8s ease-in-out infinite;
}

.aurora-red {
    background: radial-gradient(ellipse 60% 20% at 30% 15%, 
        rgba(255, 50, 50, 0.3) 0%, 
        rgba(255, 50, 50, 0.1) 40%, 
        transparent 70%);
    animation: auroraWave 12s ease-in-out infinite reverse;
}

.aurora-purple {
    background: radial-gradient(ellipse 70% 25% at 70% 25%, 
        rgba(150, 50, 255, 0.3) 0%, 
        rgba(150, 50, 255, 0.1) 35%, 
        transparent 65%);
    animation: auroraWave 10s ease-in-out infinite;
    animation-delay: -2s;
}

.aurora-particles {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        radial-gradient(2px 2px at 20px 30px, rgba(255, 255, 255, 0.8), transparent),
        radial-gradient(2px 2px at 40px 70px, rgba(0, 255, 100, 0.6), transparent),
        radial-gradient(1px 1px at 90px 40px, rgba(255, 50, 50, 0.5), transparent),
        radial-gradient(1px 1px at 130px 80px, rgba(150, 50, 255, 0.4), transparent),
        radial-gradient(2px 2px at 160px 30px, rgba(255, 255, 255, 0.7), transparent);
    background-repeat: repeat;
    background-size: 200px 100px;
    animation: particleDrift 15s linear infinite;
}

/* Real Aurora Background for Game */
.real-aurora-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.real-aurora-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

.aurora-game-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        to bottom,
        rgba(0, 0, 0, 0.3) 0%,
        rgba(0, 0, 0, 0.1) 50%,
        rgba(0, 0, 0, 0.4) 100%
    );
    z-index: 2;
}

.dynamic-aurora {
    opacity: 0.3;
    mix-blend-mode: screen;
    z-index: 3;
}

/* Photography Game Interface */
.photography-game-scene {
    position: relative;
    width: 100%;
    height: 100vh;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
}

.camera-interface {
    background: rgba(0, 0, 0, 0.9);
    border: 2px solid #4a90e2;
    border-radius: 15px;
    padding: 20px;
    box-shadow: 0 0 30px rgba(74, 144, 226, 0.4);
    z-index: 10;
    max-width: 500px;
    position: relative;
    backdrop-filter: blur(10px);
}

.camera-viewfinder {
    margin-bottom: 20px;
}

.viewfinder-frame {
    position: relative;
    width: 400px;
    height: 300px;
    border: 3px solid #4a90e2;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: inset 0 0 20px rgba(74, 144, 226, 0.3);
}

.aurora-preview {
    width: 100%;
    height: 100%;
    background: #0a0f23;
    position: relative;
    overflow: hidden;
}

.viewfinder-aurora-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.viewfinder-aurora-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    opacity: 0.8;
}

#auroraCanvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 2;
    mix-blend-mode: screen;
    opacity: 0.7;
}

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

.focus-points {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 60px;
    height: 60px;
    border: 2px solid rgba(255, 255, 255, 0.8);
    border-radius: 50%;
    animation: focusPulse 2s ease-in-out infinite;
}

.focus-points::before,
.focus-points::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(255, 255, 255, 0.6);
}

.focus-points::before {
    width: 20px;
    height: 2px;
}

.focus-points::after {
    width: 2px;
    height: 20px;
}

.exposure-meter {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 20px;
    height: 100px;
}

.exposure-bar {
    width: 100%;
    height: 100%;
    background: linear-gradient(to bottom, 
        #ff4444 0%, 
        #ffaa00 25%, 
        #00ff88 50%, 
        #ffaa00 75%, 
        #ff4444 100%);
    border-radius: 10px;
    position: relative;
}

.exposure-indicator {
    position: absolute;
    left: -5px;
    width: 30px;
    height: 4px;
    background: #fff;
    border-radius: 2px;
    box-shadow: 0 0 5px rgba(255, 255, 255, 0.8);
    transition: top 0.3s ease;
    top: 48%;
}

/* Camera Controls */
.camera-controls {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-bottom: 20px;
}

.control-group {
    display: flex;
    align-items: center;
    gap: 15px;
}

.control-group label {
    min-width: 100px;
    color: #4a90e2;
    font-weight: bold;
}

.control-slider {
    display: flex;
    align-items: center;
    gap: 10px;
    flex: 1;
}

.control-slider input[type="range"] {
    flex: 1;
    height: 8px;
    background: #333;
    border-radius: 4px;
    outline: none;
    -webkit-appearance: none;
    appearance: none;
}

.control-slider input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 20px;
    height: 20px;
    background: #4a90e2;
    border-radius: 50%;
    cursor: pointer;
    box-shadow: 0 0 10px rgba(74, 144, 226, 0.5);
}

.control-slider input[type="range"]::-moz-range-thumb {
    width: 20px;
    height: 20px;
    background: #4a90e2;
    border-radius: 50%;
    cursor: pointer;
    border: none;
    box-shadow: 0 0 10px rgba(74, 144, 226, 0.5);
}

.control-slider span {
    min-width: 60px;
    color: #00ff88;
    font-family: 'Courier New', monospace;
    font-weight: bold;
}

/* Game Stats */
.game-stats {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 20px;
    padding: 15px;
    background: rgba(0, 0, 0, 0.5);
    border-radius: 8px;
}

.stat {
    display: flex;
    align-items: center;
    gap: 10px;
}

.stat-label {
    min-width: 120px;
    color: #ccc;
    font-size: 14px;
}

.quality-bar {
    flex: 1;
    height: 8px;
    background: #333;
    border-radius: 4px;
    overflow: hidden;
    position: relative;
}

.quality-fill {
    height: 100%;
    background: linear-gradient(90deg, #ff4444, #ffaa00, #00ff88);
    border-radius: 4px;
    transition: width 0.3s ease;
    width: 0%;
}

.stat-value {
    min-width: 60px;
    color: #00ff88;
    font-family: 'Courier New', monospace;
    font-weight: bold;
    text-align: right;
}

/* Capture Controls */
.capture-controls {
    text-align: center;
}

.capture-btn {
    background: linear-gradient(45deg, #4a90e2, #2c5aa0);
    border: none;
    color: white;
    padding: 15px 30px;
    font-size: 18px;
    font-weight: bold;
    border-radius: 10px;
    cursor: pointer;
    box-shadow: 0 0 20px rgba(74, 144, 226, 0.4);
    transition: all 0.3s ease;
    text-transform: uppercase;
}

.capture-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 0 30px rgba(74, 144, 226, 0.6);
}

.capture-btn:active {
    transform: scale(0.95);
}

/* Aurora Intensity Meter */
.aurora-intensity-meter {
    position: absolute;
    top: 20px;
    right: 20px;
    background: rgba(0, 0, 0, 0.8);
    border: 2px solid #00ff88;
    border-radius: 10px;
    padding: 15px;
    box-shadow: 0 0 20px rgba(0, 255, 136, 0.3);
    z-index: 15;
}

.intensity-label {
    color: #00ff88;
    font-size: 14px;
    font-weight: bold;
    margin-bottom: 10px;
    text-align: center;
}

.intensity-bars {
    display: flex;
    gap: 5px;
    justify-content: center;
}

/* Achievement Scene */
.achievement-scene {
    position: relative;
    width: 100%;
    height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 20px;
}

.science-wrapper
{
    display: flex;
    flex-direction: column;
    gap: 80px;
    align-items: end;
}

.celebration-aurora {
    animation: celebrationPulse 3s ease-in-out infinite;
}

.celebration-particles {
    background-image: 
        radial-gradient(3px 3px at 20px 30px, rgba(255, 215, 0, 0.9), transparent),
        radial-gradient(3px 3px at 40px 70px, rgba(0, 255, 100, 0.8), transparent),
        radial-gradient(2px 2px at 90px 40px, rgba(255, 50, 50, 0.7), transparent),
        radial-gradient(2px 2px at 130px 80px, rgba(150, 50, 255, 0.6), transparent),
        radial-gradient(3px 3px at 160px 30px, rgba(255, 255, 255, 0.9), transparent);
    animation: celebrationParticles 2s ease-in-out infinite;
}

.photo-result {
    background: rgba(0, 0, 0, 0.9);
    border: 3px solid #4a90e2;
    border-radius: 15px;
    padding: 20px;
    box-shadow: 0 0 40px rgba(74, 144, 226, 0.5);
    margin-bottom: 30px;
    z-index: 10;
}

.photo-frame {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
}

.captured-photo {
    border: 2px solid #fff;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 0 20px rgba(255, 255, 255, 0.3);
    position: relative;
}

.result-photo-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.result-photo-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

#resultCanvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 2;
    mix-blend-mode: screen;
}

.photo-metadata {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
    justify-content: center;
}

.metadata-item {
    background: rgba(0, 0, 0, 0.7);
    padding: 8px 12px;
    border-radius: 5px;
    color: #00ff88;
    font-family: 'Courier New', monospace;
    font-size: 12px;
    border: 1px solid #00ff88;
}

.achievement-notification {
    background: linear-gradient(45deg, rgba(255, 215, 0, 0.2), rgba(255, 140, 0, 0.2));
    border: 2px solid #ffd700;
    border-radius: 15px;
    padding: 30px;
    text-align: center;
    box-shadow: 0 0 30px rgba(255, 215, 0, 0.4);
    margin-bottom: 30px;
    z-index: 10;
}

.achievement-icon {
    font-size: 48px;
    margin-bottom: 15px;
    animation: achievementBounce 2s ease-in-out infinite;
}

.achievement-title {
    font-size: 24px;
    font-weight: bold;
    color: #ffd700;
    margin-bottom: 10px;
    text-shadow: 0 0 10px rgba(255, 215, 0, 0.5);
}

.achievement-description {
    color: #fff;
    font-size: 16px;
    line-height: 1.4;
}

/* Science Scene */
.science-scene {
    position: relative;
    width: 100%;
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 40px;
    background: linear-gradient(135deg, #0a0f23 0%, #1a1a2e 100%);
}

.aurora-diagram {
    flex: 1;
    max-width: 500px;
    position: relative;
    height: 80vh;
    background: linear-gradient(to bottom, 
        rgba(0, 0, 0, 0.8) 0%, 
        rgba(20, 20, 40, 0.8) 100%);
    border: 2px solid #4a90e2;
    border-radius: 15px;
    overflow: hidden;
    margin-right: 40px;
}

.atmosphere-layers {
    position: relative;
    width: 100%;
    height: 100%;
}

.layer {
    position: absolute;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 20px;
    border-bottom: 2px dashed rgba(255, 255, 255, 0.3);
}

.thermosphere {
    top: 10%;
    height: 40%;
    background: linear-gradient(to bottom, 
        rgba(255, 50, 50, 0.1) 0%, 
        rgba(255, 50, 50, 0.05) 100%);
}

.mesosphere {
    top: 50%;
    height: 40%;
    background: linear-gradient(to bottom, 
        rgba(0, 255, 100, 0.1) 0%, 
        rgba(150, 50, 255, 0.1) 100%);
}

.layer-label {
    background: rgba(0, 0, 0, 0.8);
    padding: 8px 12px;
    border-radius: 5px;
    color: #4a90e2;
    font-size: 14px;
    font-weight: bold;
    border: 1px solid #4a90e2;
}

.particle-collision {
    background: rgba(255, 255, 255, 0.1);
    border: 2px solid;
    border-radius: 10px;
    padding: 10px;
    text-align: center;
    min-width: 150px;
}

.red-collision {
    border-color: #ff3232;
    color: #ff3232;
}

.green-collision {
    border-color: #00ff64;
    color: #00ff64;
}

.purple-collision {
    border-color: #9632ff;
    color: #9632ff;
}

.collision-label {
    font-size: 12px;
    font-family: 'Courier New', monospace;
    font-weight: bold;
}

.solar-particles {
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100px;
    height: 50px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.particle-stream {
    width: 4px;
    height: 100px;
    background: linear-gradient(to bottom, 
        rgba(255, 215, 0, 0.9) 0%, 
        rgba(255, 140, 0, 0.7) 50%, 
        transparent 100%);
    border-radius: 2px;
    position: relative;
}

.particle-stream::before {
    content: '';
    position: absolute;
    top: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 0;
    border-left: 8px solid transparent;
    border-right: 8px solid transparent;
    border-top: 15px solid #ffd700;
}

.particle-label {
    background: rgba(0, 0, 0, 0.8);
    padding: 5px 8px;
    border-radius: 3px;
    color: #ffd700;
    font-size: 10px;
    font-weight: bold;
    margin-top: 10px;
    border: 1px solid #ffd700;
}

.science-facts-panel {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 20px;
    max-height: 80vh;
    overflow-y: auto;
}

.fact-card {
    background: rgba(0, 0, 0, 0.8);
    border: 2px solid;
    border-radius: 12px;
    padding: 20px;
    display: flex;
    align-items: flex-start;
    gap: 15px;
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.5);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.fact-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 30px rgba(0, 0, 0, 0.7);
}

.fact-card:nth-child(1) {
    border-color: #00ff64;
}

.fact-card:nth-child(2) {
    border-color: #ff3232;
}

.fact-card:nth-child(3) {
    border-color: #9632ff;
}

.fact-card:nth-child(4) {
    border-color: #ffd700;
}

.fact-icon {
    font-size: 24px;
    min-width: 30px;
    text-align: center;
}

.fact-content h3 {
    color: #4a90e2;
    font-size: 18px;
    margin-bottom: 8px;
    font-weight: bold;
}

.fact-content p {
    color: #ccc;
    font-size: 14px;
    line-height: 1.4;
}

/* Lila Full-Screen Background */
.lila-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.lila-fullscreen-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

.interview-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        135deg, 
        rgba(0, 0, 0, 0.7) 0%, 
        rgba(0, 0, 0, 0.4) 50%, 
        rgba(0, 0, 0, 0.8) 100%
    );
    z-index: 2;
}

/* Interview Scene */
.interview-scene {
    position: relative;
    width: 100%;
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 40px;
}

.interview-bg {
    opacity: 0.3;
}

.soft-aurora {
    opacity: 0.4;
    animation: softAuroraWave 15s ease-in-out infinite;
}

.interview-setup {
    display: flex;
    justify-content: space-around;
    align-items: center;
    width: 100%;
    max-width: 800px;
    margin-bottom: 40px;
    z-index: 10;
    position: relative;
}

.interviewer-side,
.interviewee-side {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
}

.interviewer-avatar {
    width: 80px;
    height: 80px;
    background: linear-gradient(45deg, #333, #555);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 3px solid #4a90e2;
    box-shadow: 0 0 20px rgba(74, 144, 226, 0.4);
}

.microphone-icon {
    font-size: 32px;
    color: #4a90e2;
}

.interviewer-label,
.interviewee-label {
    background: rgba(0, 0, 0, 0.8);
    padding: 8px 16px;
    border-radius: 20px;
    color: #4a90e2;
    font-weight: bold;
    border: 2px solid #4a90e2;
    text-align: center;
}

.interview-mode {
    transform: scale(1.2);
}

.interview-dialogue {
    background: rgba(0, 0, 0, 0.9);
    border: 2px solid #4a90e2;
    border-radius: 15px;
    padding: 30px;
    max-width: 800px;
    box-shadow: 0 0 30px rgba(74, 144, 226, 0.4);
    z-index: 10;
    position: relative;
    backdrop-filter: blur(10px);
}

.dialogue-step {
    display: none;
}

.dialogue-step.active {
    display: block;
}

.speaker {
    font-size: 16px;
    font-weight: bold;
    margin-bottom: 10px;
    color: #4a90e2;
}

.speaker.interviewer {
    color: #4a90e2;
}

.speaker.interviewee {
    color: #00ff88;
}

.dialogue-text {
    font-size: 16px;
    line-height: 1.6;
    color: #fff;
    margin-bottom: 20px;
}

/* Quiz Scene */
.quiz-scene {
    position: relative;
    width: 100%;
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
}

.quiz-bg {
    opacity: 0.2;
}

.quiz-aurora {
    animation: quizAuroraWave 6s ease-in-out infinite;
}

.quiz-particles {
    animation: quizParticleFlow 8s linear infinite;
}

.quiz-container {
    background: rgba(0, 0, 0, 0.95);
    border: 3px solid #4a90e2;
    border-radius: 20px;
    padding: 40px;
    max-width: 700px;
    width: 100%;
    box-shadow: 0 0 40px rgba(74, 144, 226, 0.5);
    z-index: 10;
}

.quiz-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
}

.quiz-title {
    font-size: 24px;
    font-weight: bold;
    color: #ffd700;
    text-shadow: 0 0 10px rgba(255, 215, 0, 0.5);
}

.quiz-timer {
    position: relative;
}

.timer-circle {
    width: 60px;
    height: 60px;
    border: 4px solid #333;
    border-top: 4px solid #ff4444;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: timerSpin 1s linear infinite;
}

.timer-circle span {
    font-size: 18px;
    font-weight: bold;
    color: #00bfff;
}

.question-container {
    margin-bottom: 30px;
}

.question-text {
    font-size: 20px;
    color: #fff;
    margin-bottom: 25px;
    text-align: center;
    line-height: 1.4;
}

.answer-options {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.answer-btn {
    background: rgba(0, 0, 0, 0.7);
    border: 2px solid #4a90e2;
    border-radius: 10px;
    padding: 15px 20px;
    color: #fff;
    font-size: 16px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 15px;
    text-align: left;
}

.answer-btn:hover {
    background: rgba(74, 144, 226, 0.2);
    border-color: #6bb6ff;
    transform: translateX(5px);
}

.option-letter {
    background: #4a90e2;
    color: #fff;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    flex-shrink: 0;
}

.option-text {
    flex: 1;
    line-height: 1.3;
}

/* Completion Scene */
.completion-scene {
    position: relative;
    width: 100%;
    height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 40px;
}

.finale {
    opacity: 0.4;
}

.finale-aurora {
    animation: finaleAuroraWave 12s ease-in-out infinite;
}

.finale-particles {
    animation: finaleParticleFlow 10s linear infinite;
}

.completion-content {
    background: rgba(0, 0, 0, 0.9);
    border: 3px solid #4a90e2;
    border-radius: 20px;
    padding: 40px;
    max-width: 800px;
    width: 100%;
    box-shadow: 0 0 50px rgba(74, 144, 226, 0.6);
    z-index: 10;
    text-align: center;
}

.completion-header {
    margin-bottom: 30px;
}

.completion-icon {
    font-size: 64px;
    margin-bottom: 15px;
    animation: completionPulse 3s ease-in-out infinite;
}

.completion-title {
    font-size: 32px;
    font-weight: bold;
    color: #4a90e2;
    margin-bottom: 10px;
    text-shadow: 0 0 15px rgba(74, 144, 226, 0.5);
}

.completion-subtitle {
    font-size: 18px;
    color: #00ff88;
    font-weight: bold;
}

.chapter-summary {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-bottom: 30px;
    padding: 20px;
    background: rgba(0, 0, 0, 0.5);
    border-radius: 10px;
}

.summary-item {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 10px;
    background: rgba(74, 144, 226, 0.1);
    border-radius: 8px;
    border-left: 4px solid #4a90e2;
}

.summary-icon {
    font-size: 24px;
    min-width: 30px;
    text-align: center;
}

.summary-text {
    color: #fff;
    font-size: 16px;
}

.final-quote {
    background: rgba(0, 255, 136, 0.1);
    border: 2px solid #00ff88;
    border-radius: 15px;
    padding: 25px;
    margin-bottom: 30px;
    position: relative;
}

.final-quote::before {
    content: '"';
    position: absolute;
    top: -10px;
    left: 20px;
    font-size: 48px;
    color: #00ff88;
    line-height: 1;
}

.final-quote::after {
    content: '"';
    position: absolute;
    bottom: -20px;
    right: 20px;
    font-size: 48px;
    color: #00ff88;
    line-height: 1;
}

.quote-text {
    color: #fff;
    font-size: 16px;
    line-height: 1.6;
    font-style: italic;
    margin-bottom: 15px;
}

.quote-author {
    color: #00ff88;
    font-size: 14px;
    font-weight: bold;
    text-align: right;
}

.completion-actions {
    display: flex;
    gap: 20px;
    justify-content: center;
}

.action-btn {
    padding: 15px 30px;
    border: none;
    border-radius: 10px;
    font-size: 16px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
}

.action-btn.primary {
    background: linear-gradient(45deg, #4a90e2, #2c5aa0);
    color: white;
    box-shadow: 0 0 20px rgba(74, 144, 226, 0.4);
}

.action-btn.primary:hover {
    transform: scale(1.05);
    box-shadow: 0 0 30px rgba(74, 144, 226, 0.6);
}

.action-btn.secondary {
    background: rgba(0, 0, 0, 0.7);
    color: #4a90e2;
    border: 2px solid #4a90e2;
}

.action-btn.secondary:hover {
    background: rgba(74, 144, 226, 0.2);
    transform: scale(1.05);
}

/* Animations */
@keyframes skyShimmer {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.8; }
}

@keyframes stormPulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

@keyframes photographerGlow {
    0%, 100% { transform: translate(-50%, -50%) scale(1); opacity: 0.6; }
    50% { transform: translate(-50%, -50%) scale(1.1); opacity: 0.8; }
}

@keyframes alertGlow {
    0%, 100% { transform: translate(-50%, -50%) scale(1); opacity: 0.7; }
    50% { transform: translate(-50%, -50%) scale(1.2); opacity: 1; }
}

@keyframes interviewGlow {
    0%, 100% { transform: translate(-50%, -50%) scale(1); opacity: 0.5; }
    50% { transform: translate(-50%, -50%) scale(1.05); opacity: 0.7; }
}

@keyframes kpPulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.6; }
}

@keyframes auroraWave {
    0%, 100% { transform: translateY(0) scaleY(1); }
    25% { transform: translateY(-10px) scaleY(1.1); }
    50% { transform: translateY(0) scaleY(0.9); }
    75% { transform: translateY(10px) scaleY(1.1); }
}

@keyframes particleDrift {
    0% { transform: translateX(0) translateY(0); }
    25% { transform: translateX(-20px) translateY(-10px); }
    50% { transform: translateX(0) translateY(-20px); }
    75% { transform: translateX(20px) translateY(-10px); }
    100% { transform: translateX(0) translateY(0); }
}

@keyframes focusPulse {
    0%, 100% { opacity: 0.8; transform: translate(-50%, -50%) scale(1); }
    50% { opacity: 1; transform: translate(-50%, -50%) scale(1.1); }
}

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

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

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

@keyframes softAuroraWave {
    0%, 100% { transform: translateY(0) scaleX(1); opacity: 0.4; }
    33% { transform: translateY(-5px) scaleX(1.05); opacity: 0.5; }
    66% { transform: translateY(5px) scaleX(0.95); opacity: 0.3; }
}

@keyframes quizAuroraWave {
    0%, 100% { transform: translateY(0) scaleY(1); opacity: 0.3; }
    50% { transform: translateY(-8px) scaleY(1.1); opacity: 0.5; }
}

@keyframes quizParticleFlow {
    0% { transform: translateX(0); }
    100% { transform: translateX(-200px); }
}

@keyframes timerSpin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

@keyframes finaleAuroraWave {
    0%, 100% { transform: translateY(0) scaleY(1); opacity: 0.4; }
    25% { transform: translateY(-15px) scaleY(1.2); opacity: 0.6; }
    50% { transform: translateY(0) scaleY(0.8); opacity: 0.3; }
    75% { transform: translateY(15px) scaleY(1.2); opacity: 0.6; }
}

@keyframes finaleParticleFlow {
    0% { transform: translateX(0) translateY(0) rotate(0deg); }
    25% { transform: translateX(-30px) translateY(-15px) rotate(90deg); }
    50% { transform: translateX(0) translateY(-30px) rotate(180deg); }
    75% { transform: translateX(30px) translateY(-15px) rotate(270deg); }
    100% { transform: translateX(0) translateY(0) rotate(360deg); }
}

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

/* Mobile Responsiveness for Chapter 4 */
@media (max-width: 768px) {
    /* Camera Vision Game Mobile */
    .camera-viewfinder-circle {
        width: 280px;
        height: 280px;
    }
    
    .camera-settings-sidebar {
        width: calc(100vw - 40px);
        left: 20px;
        right: 20px;
        top: auto;
        bottom: 20px;
        max-height: 40vh;
        overflow-y: auto;
        padding: 15px;
    }
    
    .setting-group {
        margin-bottom: 15px;
    }
    
    .capture-button {
        padding: 12px;
        font-size: 14px;
        margin: 15px 0;
    }
    
    .modal-content {
        padding: 20px;
        width: 95%;
        margin: 20px;
    }
    
    .captured-photo {
        height: 200px;
    }
    
    .modal-actions {
        flex-direction: column;
        gap: 10px;
    }
    
    .photography-game-scene {
        flex-direction: column;
        padding: 10px;
        gap: 20px;
    }
    
    .camera-interface {
        max-width: 100%;
        padding: 15px;
    }
    
    .viewfinder-frame {
        width: 300px;
        height: 225px;
    }
    
    .science-scene {
        flex-direction: column;
        padding: 20px;
        gap: 20px;
    }
    
    .aurora-diagram {
        margin-right: 0;
        max-width: 100%;
        height: 50vh;
    }
    
    .interview-setup {
        flex-direction: column;
        gap: 30px;
    }
    
    .completion-content {
        padding: 20px;
    }
    
    .completion-actions {
        flex-direction: column;
        align-items: center;
    }
    
    .photographer-character {
        bottom: 10%;
        right: 10%;
        transform: scale(0.8);
    }
    
    .photographer-avatar {
        width: 100px;
        height: 125px;
    }
    
    .camera-equipment {
        top: 10%;
        left: 5%;
    }
    
    .camera-display {
        padding: 10px;
    }
    
    .camera-screen {
        width: 150px;
        height: 112px;
    }
    
    .space-weather-alert {
        top: 5%;
        right: 5%;
        padding: 15px;
        min-width: 200px;
    }
    
    .aurora-intensity-meter {
        top: 10px;
        right: 10px;
        padding: 10px;
    }
    
    .lila-fullscreen-image,
    .real-aurora-image,
    .viewfinder-aurora-image {
        object-position: center center;
    }
}

@media (max-width: 480px) {
    .photographer-character {
        transform: scale(0.6);
        bottom: 5%;
        right: 5%;
    }
    
    .photographer-avatar {
        width: 80px;
        height: 100px;
    }
    
    .camera-equipment {
        top: 5%;
        left: 2%;
    }
    
    .camera-screen {
        width: 120px;
        height: 90px;
    }
    
    .viewfinder-frame {
        width: 250px;
        height: 187px;
    }
    
    .control-group {
        flex-direction: column;
        gap: 8px;
        align-items: flex-start;
    }
    
    .control-group label {
        min-width: auto;
    }
    
    .quiz-container {
        padding: 20px;
    }
    
    .question-text {
        font-size: 16px;
    }
    
    .answer-btn {
        padding: 12px 15px;
        font-size: 14px;
    }
    
    .completion-title {
        font-size: 24px;
    }
    
    .completion-icon {
        font-size: 48px;
    }
    
    .dialogue-box {
        top: 10px;
        padding: 15px;
        max-width: 95%;
    }
    
    .character-name {
        font-size: 16px;
    }
    
    .dialogue-text {
        font-size: 14px;
    }
}

/* Chapter Selection Mobile Styles */
@media (max-width: 1024px) {
    .chapters-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
    }
    
    .chapter-card {
        padding: 20px;
    }
    
    .chapter-title {
        font-size: 16px;
    }
    
    .chapter-description {
        font-size: 12px;
    }
}

@media (max-width: 768px) {
    .chapters-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .chapter-selection-content {
        padding: 20px 10px;
    }
    
    .chapter-selection-title {
        font-size: 2rem;
        margin-bottom: 20px;
    }
    
    .chapter-card {
        padding: 15px;
    }
    
    .chapter-number {
        font-size: 20px;
    }
    
    .chapter-title {
        font-size: 14px;
        margin-bottom: 10px;
    }
    
    .chapter-description {
        font-size: 11px;
        margin-bottom: 15px;
    }
    
    .chapter-btn {
        padding: 10px 20px;
        font-size: 14px;
    }
}
