/* Warner Robins Baseball - Continuous Auto-Play Animation */

/* Custom Font Imports */
@font-face {
    font-family: 'HypebuzzDemo';
    src: url('./fonts/HypebuzzDemo.otf') format('opentype');
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'Milker';
    src: url('./fonts/Milker.otf') format('opentype');
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}

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

html {
    scroll-behavior: smooth;
    overflow: hidden;
}

body {
    font-family: 'HypebuzzDemo', Arial, sans-serif;
    background: #000;
    color: #fff;
    overflow: hidden;
    height: 100vh;
    cursor: default;
    user-select: none;
    perspective: 1000px;
    perspective-origin: center center;
}

/* Loading Screen */
.loader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #0a0a0a 0%, #1a1a1a 50%, #0a0a0a 100%);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    opacity: 1;
    transition: opacity 0.5s ease-out;
}

.loader-content {
    text-align: center;
    color: #fff;
}

.loader-spinner {
    width: 80px;
    height: 80px;
    border: 6px solid rgba(255, 255, 255, 0.1);
    border-top: 6px solid #fff;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 30px;
}

.loader-content p {
    font-family: 'Milker', sans-serif;
    font-size: 20px;
    opacity: 0.9;
    margin-bottom: 20px;
}

.loader-progress {
    width: 200px;
    height: 4px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 2px;
    overflow: hidden;
    margin: 0 auto;
}

.loader-bar {
    height: 100%;
    background: linear-gradient(90deg, #0033a0 0%, #004acc 100%);
    width: 0%;
    border-radius: 2px;
    animation: loadProgress 3s ease-out forwards;
}

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

@keyframes loadProgress {
    0% { width: 0%; }
    100% { width: 100%; }
}

/* Main Container */
.main-container {
    position: relative;
    width: 100%;
    height: 100vh;
    opacity: 0;
    transition: opacity 0.5s ease-in;
    transform-style: preserve-3d;
}

/* Cinematic atmosphere overlay */
.main-container::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(circle at 30% 20%, rgba(0, 150, 255, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 70% 80%, rgba(255, 100, 0, 0.05) 0%, transparent 50%),
        linear-gradient(45deg, transparent 0%, rgba(255, 255, 255, 0.02) 50%, transparent 100%);
    pointer-events: none;
    z-index: 2;
    animation: atmosphereShift 20s ease-in-out infinite;
}

@keyframes atmosphereShift {
    0%, 100% { opacity: 0.3; transform: translateX(0px); }
    50% { opacity: 0.6; transform: translateX(10px); }
}

.main-container.loaded {
    opacity: 1;
}

/* Page Base Styles */
.page {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transform-style: preserve-3d;
    will-change: transform, opacity;
}

/* Cinematic depth layers */
.page::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(ellipse at center, transparent 0%, rgba(0, 0, 0, 0.3) 100%),
        linear-gradient(0deg, rgba(0, 0, 0, 0.2) 0%, transparent 20%, transparent 80%, rgba(0, 0, 0, 0.2) 100%);
    pointer-events: none;
    z-index: 5;
    opacity: 0;
    transition: opacity 1s ease;
}

.page.active::before {
    opacity: 1;
}

.page.active {
    opacity: 1;
    visibility: visible;
}

.page-content {
    position: relative;
    z-index: 10;
    text-align: center;
    max-width: 1200px;
    width: 100%;
    padding: 0 40px;
}

/* Background Styles */
.hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 110%;
    height: 110%;
    background: url('./images/hero-backgrounds.png') center/cover no-repeat;
    z-index: 1;
    transform: translateX(-5%) translateY(-5%);
    transition: transform 8s ease-out;
    will-change: transform;
}

.hero-bg::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(circle at 50% 50%, transparent 0%, rgba(0, 0, 0, 0.4) 100%),
        linear-gradient(135deg, rgba(0, 51, 160, 0.1) 0%, transparent 50%, rgba(255, 215, 0, 0.05) 100%);
    z-index: 2;
}

.page-1.active .hero-bg {
    transform: translateX(0%) translateY(0%) scale(1.05);
}

.blue-solid-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(circle at 30% 30%, #004acc 0%, #0033a0 70%),
        linear-gradient(135deg, #0033a0 0%, #002d8f 100%);
    z-index: 1;
}

.blue-solid-bg::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(circle at 70% 20%, rgba(255, 255, 255, 0.1) 0%, transparent 40%),
        radial-gradient(circle at 20% 80%, rgba(255, 215, 0, 0.05) 0%, transparent 60%);
    z-index: 2;
    animation: blueShimmer 15s ease-in-out infinite;
}

@keyframes blueShimmer {
    0%, 100% { opacity: 0.3; transform: translateX(0px) translateY(0px); }
    50% { opacity: 0.7; transform: translateX(5px) translateY(-5px); }
}

/* Page 1: Hero Section with Dramatic Lighting */
.hero-title {
    position: relative;
    z-index: 10;
    transform-style: preserve-3d;
}

.hero-title::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(ellipse at center, rgba(255, 255, 255, 0.1) 0%, transparent 70%);
    z-index: -1;
    animation: spotlightPulse 4s ease-in-out infinite;
}

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

.title-word {
    display: block;
    font-family: 'HypebuzzDemo', Arial, sans-serif;
    font-size: clamp(2.5rem, 7vw, 6.5rem);
    font-weight: normal;
    line-height: 0.9;
    margin-bottom: 10px;
    text-transform: uppercase;
    white-space: nowrap;
}

.title-word.word-3 {
    font-size: clamp(2rem, 6vw, 5.5rem);
    letter-spacing: 0.15em;
}

/* Magic Animate Digital styles - Clean White Text with Scanline Interference */
.animated-title span,
.final-message span {
    display: inline-block;
    color: #fff;
    text-shadow: 
        3px 3px 0px rgba(0, 0, 0, 0.8),
        5px 5px 15px rgba(0, 0, 0, 0.6);
    transform-style: preserve-3d;
    will-change: transform;
    position: relative;
}

/* Scanline Interference Effect for Glitch Phases */
.scanline-interference {
    position: relative;
    overflow: hidden;
}

.scanline-interference::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        0deg,
        transparent 48%,
        rgba(255, 255, 255, 0.05) 49%,
        rgba(255, 255, 255, 0.05) 51%,
        transparent 52%
    );
    background-size: 100% 4px;
    animation: scanlines 0.08s linear infinite;
    pointer-events: none;
    z-index: 1;
    opacity: 0;
}

.scanline-interference.active::before {
    opacity: 1;
}

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

/* Enhanced digital noise pattern for cinematic effect */
.digital-noise {
    position: relative;
}

.digital-noise::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(circle at 20% 80%, rgba(255, 255, 255, 0.03) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(255, 255, 255, 0.03) 0%, transparent 50%),
        radial-gradient(circle at 40% 40%, rgba(255, 255, 255, 0.02) 0%, transparent 30%);
    background-size: 200px 200px, 150px 150px, 100px 100px;
    animation: digitalNoise 0.1s linear infinite;
    pointer-events: none;
    z-index: 1;
    opacity: 0;
}

.digital-noise.active::after {
    opacity: 1;
}

@keyframes digitalNoise {
    0% {
        transform: translate(0px, 0px);
        filter: hue-rotate(0deg);
    }
    25% {
        transform: translate(-1px, 1px);
        filter: hue-rotate(90deg);
    }
    50% {
        transform: translate(1px, -1px);
        filter: hue-rotate(180deg);
    }
    75% {
        transform: translate(-1px, -1px);
        filter: hue-rotate(270deg);
    }
    100% {
        transform: translate(0px, 0px);
        filter: hue-rotate(360deg);
    }
}

/* Neon flickering effect */
.neon-flicker {
    animation: neonFlicker 0.15s ease-in-out infinite alternate;
}

@keyframes neonFlicker {
    0%, 100% {
        opacity: 1;
        text-shadow: 
            0 0 5px currentColor,
            0 0 10px currentColor,
            0 0 20px currentColor,
            0 0 40px #fff,
            0 0 80px #fff,
            0 0 100px #fff,
            4px 4px 0px rgba(0, 0, 0, 0.8);
    }
    50% {
        opacity: 0.8;
        text-shadow: 
            0 0 2px currentColor,
            0 0 5px currentColor,
            0 0 10px currentColor,
            0 0 20px #fff,
            0 0 40px #fff,
            0 0 60px #fff,
            4px 4px 0px rgba(0, 0, 0, 0.8);
    }
}

/* Neon pulsation effect */
.neon-pulse {
    animation: neonPulse 2s ease-in-out infinite;
}

@keyframes neonPulse {
    0%, 100% {
        text-shadow: 
            0 0 5px currentColor,
            0 0 10px currentColor,
            0 0 20px currentColor,
            0 0 40px #fff,
            0 0 80px #fff,
            0 0 100px #fff,
            4px 4px 0px rgba(0, 0, 0, 0.8);
    }
    50% {
        text-shadow: 
            0 0 10px currentColor,
            0 0 20px currentColor,
            0 0 30px currentColor,
            0 0 60px #fff,
            0 0 100px #fff,
            0 0 120px #fff,
            4px 4px 0px rgba(0, 0, 0, 0.8);
    }
}

/* Page 2: Typewriter Effect */
.mission-text {
    position: relative;
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    flex-wrap: wrap;
}

.typewriter-text {
    font-family: 'Milker', sans-serif;
    font-size: clamp(1rem, 3vw, 2rem);
    font-weight: normal;
    color: #fff;
    text-shadow: 2px 2px 10px rgba(0, 0, 0, 0.5);
    overflow: visible;
    white-space: nowrap;
    max-width: 98vw;
    letter-spacing: 0.02em;
    width: auto;
    padding: 0 10px;
    text-align: center;
}

.typewriter-cursor {
    font-family: 'Milker', sans-serif;
    font-size: clamp(1rem, 3vw, 2rem);
    color: #fff;
    animation: blink 1s infinite;
    opacity: 1;
}

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

/* Page 3: Clarify Effect */
.coming-soon-text {
    position: relative;
    z-index: 10;
}

.clarify-text {
    font-family: 'HypebuzzDemo', sans-serif;
    font-size: clamp(2.5rem, 6vw, 5rem);
    font-weight: normal;
    color: #fff;
    text-shadow: 
        3px 3px 0px rgba(0, 0, 0, 0.8),
        6px 6px 20px rgba(0, 0, 0, 0.6);
    letter-spacing: -0.1em;
    text-transform: uppercase;
    white-space: nowrap;
    text-align: center;
    max-width: 90vw;
    width: fit-content;
    margin: 0 auto;
}

.clarify-letter {
    display: inline-block;
    opacity: 0;
    filter: blur(20px);
    transform: scale(0.9);
}

/* Page 4: Merge Effect */
.brand-closure {
    position: relative;
    z-index: 10;
}

.merge-text {
    font-family: 'HypebuzzDemo', Arial, sans-serif;
    font-size: clamp(2.5rem, 7vw, 6.5rem);
    font-weight: normal;
    color: #fff;
    text-shadow: 
        3px 3px 0px rgba(0, 0, 0, 0.8),
        6px 6px 15px rgba(0, 0, 0, 0.6);
    line-height: 0.9;
}

.merge-word {
    display: block;
    margin-bottom: 10px;
    position: relative;
    white-space: nowrap;
}

.merge-word.word-3 {
    color: #fff;
    text-shadow: 
        3px 3px 0px rgba(0, 0, 0, 0.8),
        6px 6px 15px rgba(0, 0, 0, 0.6);
    font-size: clamp(2rem, 6vw, 5.5rem);
    letter-spacing: 0.15em;
}

/* Particle Effects */
.particles {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1;
}

.particle {
    position: absolute;
    width: 2px;
    height: 2px;
    background: rgba(255, 255, 255, 0.6);
    border-radius: 50%;
    animation: float 20s linear infinite;
}

.particle:nth-child(1) { left: 10%; animation-delay: 0s; animation-duration: 25s; }
.particle:nth-child(2) { left: 20%; animation-delay: 2s; animation-duration: 18s; }
.particle:nth-child(3) { left: 30%; animation-delay: 4s; animation-duration: 22s; }
.particle:nth-child(4) { left: 40%; animation-delay: 6s; animation-duration: 28s; }
.particle:nth-child(5) { left: 50%; animation-delay: 8s; animation-duration: 15s; }
.particle:nth-child(6) { left: 60%; animation-delay: 10s; animation-duration: 20s; }
.particle:nth-child(7) { left: 70%; animation-delay: 12s; animation-duration: 24s; }
.particle:nth-child(8) { left: 80%; animation-delay: 14s; animation-duration: 19s; }
.particle:nth-child(9) { left: 90%; animation-delay: 16s; animation-duration: 26s; }
.particle:nth-child(10) { left: 95%; animation-delay: 18s; animation-duration: 21s; }

@keyframes float {
    0% { 
        transform: translateY(100vh) rotate(0deg);
        opacity: 0;
    }
    10% { 
        opacity: 1;
    }
    90% { 
        opacity: 1;
    }
    100% { 
        transform: translateY(-100vh) rotate(360deg);
        opacity: 0;
    }
}

/* Cinematic Enhancement Classes for Dynamic Application */
.glitch-phase-1 {
    animation: glitchPhase1 0.04s ease-out;
}

.glitch-phase-2 {
    animation: glitchPhase2 0.03s ease-in-out;
}

.glitch-phase-3 {
    animation: glitchPhase3 0.05s ease-out;
}

@keyframes glitchPhase1 {
    0% { filter: contrast(1) brightness(1); }
    50% { filter: contrast(1.3) brightness(1.2) hue-rotate(180deg); }
    100% { filter: contrast(1.1) brightness(1.1) hue-rotate(90deg); }
}

@keyframes glitchPhase2 {
    0% { filter: contrast(1.1) brightness(1.1) hue-rotate(90deg); }
    50% { filter: contrast(1.2) brightness(1.15) hue-rotate(270deg); }
    100% { filter: contrast(1.2) brightness(1.1) hue-rotate(45deg); }
}

@keyframes glitchPhase3 {
    0% { filter: contrast(1.2) brightness(1.1) hue-rotate(45deg); }
    50% { filter: contrast(1.5) brightness(1.5) hue-rotate(270deg) saturate(3); }
    100% { filter: none; }
}

/* Movie trailer style RGB separation */
.rgb-separation {
    position: relative;
}

.rgb-separation::before {
    content: attr(data-text);
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    color: rgba(255, 0, 0, 0.7);
    transform: translate(2px, 0);
    z-index: -1;
    opacity: 0;
}

.rgb-separation::after {
    content: attr(data-text);
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    color: rgba(0, 255, 255, 0.7);
    transform: translate(-2px, 0);
    z-index: -1;
    opacity: 0;
}

.rgb-separation.active::before,
.rgb-separation.active::after {
    opacity: 1;
}

/* Styles for Magic Animate Digital effect - spans are created dynamically */

/* Responsive Design */
@media (max-width: 768px) {
    .page-content {
        padding: 0 20px;
    }
    
    .title-word {
        font-size: clamp(2.5rem, 10vw, 4rem);
        line-height: 0.85;
    }
    
    .title-word.word-3 {
        font-size: clamp(2rem, 8vw, 3.5rem);
    }
    
    .typewriter-text,
    .typewriter-cursor {
        font-size: clamp(0.9rem, 2.5vw, 1.8rem);
        padding: 0 5px;
    }
    
    .mission-text {
        flex-direction: column;
        gap: 5px;
    }
    
    .clarify-text {
        font-size: clamp(1.8rem, 5vw, 3rem);
        max-width: 95vw;
    }
    
    .merge-text {
        font-size: clamp(2rem, 8vw, 3rem);
    }
    
    .merge-word.word-3 {
        font-size: clamp(1.8rem, 6vw, 3rem);
    }
    
    .controls {
        bottom: 20px;
        left: 20px;
    }
    
    .control-btn {
        width: 45px;
        height: 45px;
        font-size: 16px;
    }
}

@media (max-width: 480px) {
    .title-word {
        font-size: clamp(1.8rem, 12vw, 3rem);
        line-height: 0.8;
    }
    
    .title-word.word-3 {
        font-size: clamp(1.5rem, 10vw, 2.5rem);
    }
    
    .typewriter-text,
    .typewriter-cursor {
        font-size: clamp(0.8rem, 3.5vw, 1.3rem);
        padding: 0 2px;
    }
    
    .clarify-text {
        font-size: clamp(1.5rem, 4.5vw, 2.5rem);
        max-width: 98vw;
    }
    
    .merge-text {
        font-size: clamp(1.5rem, 10vw, 2.5rem);
    }
    
    .merge-word.word-3 {
        font-size: clamp(1.3rem, 8vw, 2rem);
    }
    
    .controls {
        bottom: 15px;
        left: 15px;
        gap: 10px;
    }
    
    .control-btn {
        width: 40px;
        height: 40px;
        font-size: 14px;
    }
    
    .control-btn::before {
        font-size: 11px;
        padding: 6px 10px;
    }
}

/* Landscape orientation adjustments */
@media (orientation: landscape) and (max-height: 600px) {
    .title-word {
        font-size: clamp(2rem, 6vh, 4rem);
    }
    
    .typewriter-text,
    .typewriter-cursor {
        font-size: clamp(1.2rem, 4vh, 2rem);
    }
    
    .clarify-text {
        font-size: clamp(1.8rem, 6vh, 3rem);
    }
    
    .merge-text {
        font-size: clamp(1.8rem, 5vh, 2.5rem);
    }
}

/* Accessibility */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    
    .neon-letter,
    .clarify-text,
    .merge-letter {
        animation: none !important;
    }
}

/* Controls */
.controls {
    position: fixed;
    bottom: 30px;
    left: 30px;
    z-index: 1000;
    display: flex;
    gap: 15px;
}

.control-btn {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    border: 2px solid rgba(255, 255, 255, 0.2);
    background: rgba(0, 0, 0, 0.3);
    color: rgba(255, 255, 255, 0.6);
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    backdrop-filter: blur(10px);
    opacity: 0.5;
}

.control-btn:hover {
    border-color: rgba(255, 255, 255, 0.8);
    background: rgba(0, 0, 0, 0.8);
    color: rgba(255, 255, 255, 1);
    transform: scale(1.1);
    opacity: 1;
}

.control-btn:active {
    transform: scale(0.95);
}

.control-btn .pause-icon {
    display: none;
}

.control-btn.paused .play-icon {
    display: none;
}

.control-btn.paused .pause-icon {
    display: block;
}

/* Tooltip styling */
.control-btn::before {
    content: attr(title);
    position: absolute;
    bottom: 60px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 0, 0, 0.8);
    color: white;
    padding: 8px 12px;
    border-radius: 4px;
    font-size: 12px;
    font-family: 'Milker', sans-serif;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
    pointer-events: none;
}

.control-btn::after {
    content: '';
    position: absolute;
    bottom: 52px;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 0;
    border-left: 5px solid transparent;
    border-right: 5px solid transparent;
    border-top: 5px solid rgba(0, 0, 0, 0.8);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
    pointer-events: none;
}

.control-btn:hover::before,
.control-btn:hover::after {
    opacity: 1;
    visibility: visible;
}

/* Print styles */
@media print {
    .controls {
        display: none;
    }
    
    .page {
        position: static;
        opacity: 1;
        visibility: visible;
        height: auto;
        page-break-after: always;
    }
}