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

/* Base Reset */
*, *::before, *::after { box-sizing: border-box; }
body { overflow-x: hidden; }
.banner, .banner * { max-width: 100%; }

/* Banner Container - REDUCED Z-INDEX TO NOT INTERFERE WITH NAVBAR */
.banner { 
    position: relative; 
    width: 100%; 
    height: 100vh; 
    min-height: 620px; 
    display: flex; 
    align-items: center; 
    justify-content: center; 
    overflow: hidden; 
    background: var(--color-purple); 
    z-index: 1; /* CRITICAL: Low z-index so navbar dropdown appears above */
}

/* Loading Screen - Shown until video is ready */
.banner-loading { 
    position: absolute; 
    top: 0; 
    left: 0; 
    width: 100%; 
    height: 100%; 
    background: var(--color-purple); 
    display: flex; 
    align-items: center; 
    justify-content: center; 
    z-index: 100; /* Local z-index within banner context */
    transition: opacity 0.3s ease; 
}

/* Loading Spinner */
.loading-spinner { 
    width: 50px; 
    height: 50px; 
    border: 4px solid rgba(246, 155, 9, 0.2); 
    border-top-color: var(--color-orange); 
    border-radius: 50%; 
    animation: spin 0.8s linear infinite; 
}

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

/* Video Container - Hidden until loaded */
.video-container { 
    position: absolute; 
    top: 0; 
    left: 0; 
    width: 100%; 
    height: 100%; 
    opacity: 0; 
    visibility: hidden; 
    z-index: 0; /* Local z-index within banner */
}

.banner.loaded .video-container { transition: opacity 0.8s ease-in-out; }
.banner.loaded .video-container.active { opacity: 1; visibility: visible; z-index: 1; }

/* Video Element */
.banner-video { 
    position: absolute; 
    top: 50%; 
    left: 50%; 
    min-width: 100%; 
    min-height: 100%; 
    width: auto; 
    height: auto; 
    transform: translate(-50%, -50%); 
    object-fit: cover; 
    will-change: transform; 
}

/* Video Overlays */
.video-overlay { 
    position: absolute; 
    top: 0; 
    left: 0; 
    width: 100%; 
    height: 100%; 
    z-index: 1; /* Local z-index within video container */
    pointer-events: none; 
}

.overlay-orange { background: linear-gradient(110deg, rgba(170, 111, 17, 0.7) 0%, rgba(24, 8, 43, 0.85) 100%); }
.overlay-purple { background: linear-gradient(160deg, rgba(76, 13, 135, 0.65) 0%, rgba(24, 8, 43, 0.88) 100%); }

/* Banner Content - Hidden until video loads */
.banner-content { 
    position: relative; 
    z-index: 10; /* Local z-index within banner context */
    text-align: center; 
    padding: 0 20px; 
    width: 100%; 
    max-width: 1200px; 
    opacity: 0; 
    transform: translateY(20px); 
    transition: opacity 0.6s ease 0.2s, transform 0.6s ease 0.2s; 
}

.banner.loaded .banner-content { opacity: 1; transform: translateY(0); }

/* Banner Title */
.banner-title { 
    font-family: 'Caveat', cursive; 
    font-size: 8rem; 
    font-weight: 700; 
    line-height: 1.2; 
    margin: 0; 
    padding: 0; 
    display: block; 
    text-align: center; 
    text-shadow: 3px 3px 10px rgba(0, 0, 0, 0.4); 
}

/* Text Colors */
.text-orange { color: var(--color-orange); display: inline; }
.text-dark { color: var(--color-white) !important; display: inline; }

/* Banner Subtitle */
.banner-subtitle { 
    font-family: 'Caveat', cursive; 
    font-size: 4rem; 
    font-weight: 600; 
    line-height: 1.3; 
    margin: 20px 0 0 0; 
    padding: 0; 
    color: var(--color-white); 
    text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.4); 
}

.banner-subtitle .text-light { color: var(--color-orange) !important; }

/* Scroll Indicator */
.scroll-indicator { 
    position: absolute; 
    bottom: 30px; 
    left: 50%; 
    transform: translateX(-50%); 
    z-index: 20; /* Local z-index within banner */
    opacity: 0; 
    transition: opacity 0.6s ease 0.4s; 
}

.banner.loaded .scroll-indicator { opacity: 1; }

.scroll-icon { 
    animation: bounce 2s infinite; 
    cursor: pointer; 
    transition: transform 0.3s ease; 
    filter: drop-shadow(0 3px 6px rgba(0, 0, 0, 0.4)); 
}

.scroll-icon:hover { transform: scale(1.15); }

@keyframes bounce { 
    0%, 20%, 50%, 80%, 100% { transform: translateY(0); } 
    40% { transform: translateY(-15px); } 
    60% { transform: translateY(-7px); } 
}

/* Tablet */
@media (max-width: 1024px) { 
    .banner { min-height: 500px; } 
    .banner-title { font-size: 6rem; } 
    .banner-subtitle { font-size: 3rem; margin-top: 15px; } 
}

/* Mobile Landscape */
@media (max-width: 768px) { 
    .banner { min-height: 300px; height: 30vh; } 
    .banner-title { font-size: 4.5rem; } 
    .banner-subtitle { font-size: 2.2rem; margin-top: 10px; } 
    .scroll-indicator { bottom: 20px; } 
    .loading-spinner { width: 40px; height: 40px; border-width: 3px; }
}

/* Mobile Portrait */
@media (max-width: 480px) { 
    .banner-title { font-size: 3rem; line-height: 1.1; } 
    .banner-subtitle { font-size: 1.5rem; margin-top: 8px; } 
    .banner-content { padding: 0 15px; } 
    .scroll-indicator { bottom: 15px; } 
    .scroll-icon { height: 35px; width: 22px; } 
    .loading-spinner { width: 35px; height: 35px; }
}

/* Small Mobile */
@media (max-width: 360px) { 
    .banner-title { font-size: 2.5rem; } 
    .banner-subtitle { font-size: 1.3rem; margin-top: 5px; } 
}

/* Reduced Motion Accessibility */
@media (prefers-reduced-motion: reduce) { 
    *, *::before, *::after { 
        animation-duration: 0.01ms !important; 
        animation-iteration-count: 1 !important; 
        transition-duration: 0.01ms !important; 
    } 
    .loading-spinner { 
        animation: none; 
        border-top-color: var(--color-orange); 
        border-right-color: var(--color-orange); 
    }
}