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

body {
    font-family: 'Orbitron', monospace;
    background: linear-gradient(135deg, #0c0c0c 0%, #1a1a2e 50%, #16213e 100%);
    background-size: 400% 400%;
    animation: gradientFlow 8s ease infinite;
    min-height: 100vh;
    overflow-x: hidden;
    overflow-y: auto;
}

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

.stars {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1;
}

.star {
    position: absolute;
    background: white;
    border-radius: 50%;
    opacity: 0.8;
    animation: twinkle 2s infinite;
}

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

.container {
    position: relative;
    z-index: 10;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 20px;
    width: 100vw;
}

#mainScreen {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 100%;
    max-width: 800px;
    margin: 0 auto;
}

.loading-animation {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #0c0c0c 0%, #1a1a2e 50%, #16213e 100%);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    animation: fadeOut 3s ease-in-out 2s forwards;
}

@keyframes fadeOut {
    0% { opacity: 1; }
    100% { opacity: 0; visibility: hidden; }
}

.loading-title {
    font-size: clamp(2.5rem, 8vw, 4rem);
    font-weight: 900;
    color: #ffffff;
    text-shadow: 0 0 30px rgba(0, 191, 255, 0.8);
    margin-bottom: 2rem;
    animation: titleGlow 2s ease-in-out infinite alternate;
    text-align: center;
    padding: 0 20px;
}

@keyframes titleGlow {
    0% { text-shadow: 0 0 30px rgba(0, 191, 255, 0.8); }
    100% { text-shadow: 0 0 50px rgba(0, 191, 255, 1), 0 0 70px rgba(0, 191, 255, 0.5); }
}

.loading-subtitle {
    font-size: clamp(1rem, 3vw, 1.2rem);
    color: #b3b3b3;
    margin-bottom: 3rem;
    animation: pulse 1.5s ease-in-out infinite;
    text-align: center;
    padding: 0 20px;
}

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

.quantum-loader {
    width: 80px;
    height: 80px;
    border: 3px solid rgba(0, 191, 255, 0.3);
    border-top: 3px solid #00bfff;
    border-radius: 50%;
    animation: quantumSpin 1s linear infinite;
    position: relative;
}

.quantum-loader::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 40px;
    height: 40px;
    border: 2px solid rgba(0, 255, 127, 0.4);
    border-top: 2px solid #00ff7f;
    border-radius: 50%;
    transform: translate(-50%, -50%);
    animation: quantumSpin 0.8s linear infinite reverse;
}

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

.main-screen-enter {
    animation: slideInUp 1s ease-out 2.5s both;
}

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

.welcome-section {
    text-align: center;
    margin-bottom: 3rem;
    width: 100%;
}

.door-section {
    text-align: center;
    margin-bottom: 3rem;
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
}

.info-section {
    text-align: center;
    width: 100%;
}

.door-container {
    position: relative;
    width: min(300px, 80vw);
    height: min(400px, 60vh);
    cursor: pointer;
    transition: all 0.3s ease;
}

.door-container:hover {
    transform: scale(1.02);
}

.door {
    width: 100%;
    height: 100%;
    background: linear-gradient(45deg, #2a2a2a, #1a1a1a);
    border: 3px solid #00bfff;
    border-radius: 15px;
    position: relative;
    transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 
        0 0 30px rgba(0, 191, 255, 0.3),
        inset 0 0 30px rgba(0, 191, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
}

.door.open {
    transform: perspective(400px) rotateY(-30deg);
    box-shadow: 
        0 0 50px rgba(0, 255, 127, 0.4),
        inset 0 0 30px rgba(0, 255, 127, 0.2);
    border-color: #00ff7f;
}

.door-number {
    font-size: clamp(1rem, 4vw, 1.2rem);
    font-weight: 700;
    color: #ffffff;
    text-shadow: 0 0 15px rgba(0, 191, 255, 0.8);
    letter-spacing: 2px;
    text-align: center;
    transition: all 0.3s ease;
    z-index: 10;
}

.door.open .door-number {
    color: #ffffff;
    text-shadow: 0 0 20px rgba(0, 255, 127, 0.8);
}

.door::before {
    content: '';
    position: absolute;
    top: 50%;
    right: 20px;
    width: 20px;
    height: 20px;
    background: #00bfff;
    border-radius: 50%;
    transform: translateY(-50%);
    box-shadow: 0 0 15px rgba(0, 191, 255, 0.8);
    transition: all 0.3s ease;
}

.door.open::before {
    background: #00ff7f;
    box-shadow: 0 0 20px rgba(0, 255, 127, 0.8);
}

.door-light {
    position: absolute;
    top: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 10px;
    background: linear-gradient(90deg, transparent, #00bfff, transparent);
    border-radius: 10px;
    opacity: 0.6;
    transition: all 0.3s ease;
}

.door.open .door-light {
    background: linear-gradient(90deg, transparent, #00ff7f, transparent);
    opacity: 1;
}

.status-indicator {
    display: none;
}

.status-indicator.open {
    display: none;
}

.cooldown {
    pointer-events: none;
    opacity: 0.5;
}

.cooldown-timer {
    position: absolute;
    top: 35%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: clamp(1.2rem, 5vw, 1.5rem);
    font-weight: 900;
    color: #ff4757;
    text-shadow: 0 0 20px rgba(255, 71, 87, 0.8);
    z-index: 20;
}

.welcome-text {
    color: #ffffff;
    font-size: clamp(1.2rem, 5vw, 1.8rem);
    font-weight: 700;
    margin-bottom: 2rem;
    text-shadow: 0 0 20px rgba(0, 191, 255, 0.8);
    text-align: center;
    padding: 0 20px;
}

.info-text {
    color: #cccccc;
    font-size: clamp(0.8rem, 3vw, 0.9rem);
    margin-top: 1.5rem;
    text-shadow: 0 0 5px rgba(255, 255, 255, 0.2);
    text-align: center;
    padding: 0 20px;
}

@media (min-width: 1024px) {
    .container {
        padding: 40px;
    }
    
    #mainScreen {
        max-width: 600px;
    }
    
    .door-container {
        width: 300px;
        height: 400px;
    }
    
    .welcome-section {
        margin-bottom: 4rem;
    }
    
    .door-section {
        margin-bottom: 4rem;
    }
}

@media (max-width: 768px) {
    .door-container {
        width: min(280px, 85vw);
        height: min(380px, 55vh);
    }
    
    .door-container:hover {
        transform: scale(1.01);
    }
}

@media (max-width: 480px) {
    .door-container {
        width: min(250px, 90vw);
        height: min(350px, 50vh);
    }
}

@media (max-width: 768px) {
    .welcome-section {
        margin-bottom: 2rem;
    }
    
    .door-section {
        margin-bottom: 2.5rem;
    }
    
    .info-section {
        margin-top: 2rem;
    }
}

@media (max-width: 480px) {
    .welcome-section {
        margin-bottom: 1.5rem;
    }
    
    .door-section {
        margin-bottom: 2rem;
    }
    
    .info-section {
        margin-top: 1.5rem;
    }
}

@media (hover: none) and (pointer: coarse) {
    .door-container {
        transition: all 0.2s ease;
    }
    
    .door-container:active {
        transform: scale(0.98);
    }
}

.hidden {
    display: none;
}