/* Clappy Trio VR - Styles */

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

body {
    font-family: 'Segoe UI', 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 50%, #0f3460 100%);
    overflow: hidden;
    color: white;
}

/* Intro Screen */
#intro-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #f5f5f5 0%, #e8e8e8 100%);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    transition: opacity 0.5s ease;
}

#intro-screen.hidden {
    opacity: 0;
    pointer-events: none;
}

.intro-content {
    text-align: center;
    max-width: 600px;
    padding: 2rem;
}

#intro-screen h1 {
    font-size: 3.5rem;
    color: #FF4444;
    margin-bottom: 0.5rem;
    text-shadow: 3px 3px 0 #FFD700, 6px 6px 0 rgba(0, 0, 0, 0.1);
    animation: titleBounce 2s ease-in-out infinite;
}

@keyframes titleBounce {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-10px);
    }
}

#intro-screen .subtitle {
    font-size: 1.3rem;
    color: #333;
    margin-bottom: 2rem;
    font-weight: 600;
}

.intro-image-container {
    margin: 2rem 0;
    animation: imageFloat 3s ease-in-out infinite;
}

@keyframes imageFloat {

    0%,
    100% {
        transform: translateY(0) rotate(0deg);
    }

    50% {
        transform: translateY(-15px) rotate(2deg);
    }
}

.intro-image {
    max-width: 400px;
    width: 100%;
    height: auto;
    filter: drop-shadow(0 10px 30px rgba(0, 0, 0, 0.2));
}

#intro-screen .instructions {
    font-size: 1.1rem;
    color: #555;
    margin: 2rem 0;
    line-height: 1.8;
}

#intro-screen .instructions p {
    margin: 0.5rem 0;
}

#intro-screen .instructions strong {
    color: #FF4444;
    font-weight: 700;
}

.enter-vr-btn {
    font-size: 1.5rem;
    padding: 1.2rem 3rem;
    background: #FF4444;
    color: white;
    border: 4px solid #FFD700;
    border-radius: 50px;
    cursor: pointer;
    font-weight: bold;
    transition: all 0.3s ease;
    box-shadow: 0 8px 0 #CC3333, 0 12px 30px rgba(255, 68, 68, 0.4);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.enter-vr-btn:hover {
    transform: translateY(-5px);
    box-shadow: 0 13px 0 #CC3333, 0 17px 40px rgba(255, 68, 68, 0.5);
}

.enter-vr-btn:active {
    transform: translateY(2px);
    box-shadow: 0 4px 0 #CC3333, 0 6px 20px rgba(255, 68, 68, 0.3);
}

.enter-vr-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

/* Intro action row (Start + VR icon) */
.intro-actions {
    display: flex;
    gap: 1rem;
    align-items: center;
    justify-content: center;
}

.vr-icon-btn {
    width: 64px;
    height: 64px;
    border-radius: 999px;
    border: 2px solid rgba(255, 255, 255, 0.15);
    background: rgba(0, 0, 0, 0.25);
    color: #FFFFFF;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.2rem;
    transition: transform 0.2s ease, background 0.2s ease, border-color 0.2s ease;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25);
}

.vr-icon-btn:hover {
    transform: translateY(-2px);
    background: rgba(0, 0, 0, 0.35);
    border-color: rgba(255, 255, 255, 0.25);
}

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

.vr-icon-btn svg {
    display: block;
}

.vr-icon-label {
    font-size: 0.7rem;
    letter-spacing: 0.1em;
    opacity: 0.9;
}

/* Desktop mode hint */
.desktop-hint {
    position: fixed;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 0, 0, 0.7);
    padding: 0.8rem 1.5rem;
    border-radius: 10px;
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.8);
    z-index: 100;
}

.desktop-hint kbd {
    background: rgba(255, 255, 255, 0.2);
    padding: 0.2rem 0.5rem;
    border-radius: 4px;
    font-family: monospace;
}

/* Score overlay (in VR) */
#score-overlay {
    position: fixed;
    top: 1rem;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 0, 0, 0.5);
    padding: 0.5rem 1.5rem;
    border-radius: 20px;
    font-size: 1rem;
    z-index: 50;
    pointer-events: none;
}

/* Hide A-Frame's default VR button */
.a-enter-vr-button {
    display: none !important;
}

/* Trio Timing sign animation */
@keyframes bounceIn {
    0% {
        transform: scale(0);
        opacity: 0;
    }

    50% {
        transform: scale(1.1);
    }

    100% {
        transform: scale(1);
        opacity: 1;
    }
}

.timing-sign {
    animation: bounceIn 0.5s ease-out;
}