/* Modern Glassmorphism & UI Accents */
.glass-header {
    background-color: rgba(18, 18, 18, 0.75);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

/* Premium Background Layers */
.hero-bg {
    position: relative;
    overflow: hidden;
}

.hero-bg::before {
    content: '';
    position: absolute;
    inset: 0;
    z-index: 1;
    /* Premium vignette and gradient overlay */
    background: 
        radial-gradient(circle at center, rgba(11, 36, 22, 0.1) 0%, rgba(11, 36, 22, 0.9) 100%),
        linear-gradient(to bottom, rgba(11, 36, 22, 0.3) 0%, rgba(11, 36, 22, 0.85) 85%, #0B2416 100%);
}

.hero-bg::after {
    content: '';
    position: absolute;
    inset: 0;
    z-index: -1;
    background-image: url('../assets/munnar.jpg');
    background-size: cover;
    background-position: center center;
    background-repeat: no-repeat;
    animation: kenBurns 20s ease-in-out infinite alternate;
}

.hero-video-wrap {
    position: absolute;
    inset: 0;
    overflow: hidden;
    z-index: 0;
    pointer-events: none;
    transform: translateZ(0);
    -webkit-transform: translateZ(0);
}

.hero-video-bg {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Scale & crop on desktop only to hide bottom-right watermark */
@media (min-width: 768px) {
    .hero-video-bg {
        transform: scale(1.08);
        transform-origin: top left;
    }
}

/* Adjust focal point for landscape video on portrait screens */
@media (max-width: 767px) {
    .hero-video-mobile {
        object-position: 30% center;
    }
}

@keyframes kenBurns {
    0% {
        transform: scale(1);
    }
    100% {
        transform: scale(1.1);
    }
}

/* Native Scroll-Driven Reveal Animations (Progressive Enhancement) */
@media (prefers-reduced-motion: no-preference) {
    @supports ((animation-timeline: view()) and (animation-range: entry)) {
        @keyframes revealUp {
            from {
                opacity: 0;
                transform: translateY(40px) scale(0.96);
            }
            to {
                opacity: 1;
                transform: translateY(0px) scale(1);
            }
        }
        .scroll-reveal {
            animation: revealUp auto linear backwards;
            animation-timeline: view();
            animation-range: entry 10% cover 30%;
        }
    }
}

/* Standalone Fallback for Scroll Reveals */
.scroll-reveal {
    will-change: opacity, transform;
}
.reveal-visible {
    opacity: 1 !important;
    transform: translateY(0px) scale(1) !important;
    transition: opacity 0.75s cubic-bezier(0.16, 1, 0.3, 1), transform 0.75s cubic-bezier(0.16, 1, 0.3, 1) !important;
}
.reveal-hidden {
    opacity: 0;
    transform: translateY(30px) scale(0.97);
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

/* Hide scrollbar for carousels */
.hide-scrollbar::-webkit-scrollbar {
    display: none;
}
.hide-scrollbar {
    -ms-overflow-style: none;
    scrollbar-width: none;
}
::-webkit-scrollbar-track {
    background: #0B2416;
}
::-webkit-scrollbar-thumb {
    background: #76A035;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #8ab73f;
}

/* Hide scrollbar for carousels */
.hide-scrollbar {
    -ms-overflow-style: none;  /* IE and Edge */
    scrollbar-width: none;  /* Firefox */
}
.hide-scrollbar::-webkit-scrollbar {
    display: none;
}

/* Carousel edge fading */
.carousel-fade-edges {
    -webkit-mask-image: linear-gradient(to right, transparent 0%, black 5%, black 95%, transparent 100%);
    mask-image: linear-gradient(to right, transparent 0%, black 5%, black 95%, transparent 100%);
    will-change: transform;
    transform: translateZ(0);
}

/* Page Loader */
#page-loader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-color: #0B2416; /* wilderness-deep */
    z-index: 99999;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    transition: opacity 0.4s cubic-bezier(0.4, 0, 0.2, 1), visibility 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    will-change: opacity, visibility;
}

#page-loader.loaded {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

/* SVG Drawing Animation */
.draw-logo-path {
    fill: transparent;
    stroke: #8ab73f; /* wilderness-moss */
    stroke-width: 6;
    stroke-dasharray: 4000;
    stroke-dashoffset: 4000;
    animation: drawPath 1s ease-in-out forwards, fillPath 0.1s ease-in-out 0.5s forwards;
}

@keyframes drawPath {
    to {
        stroke-dashoffset: 0;
    }
}

@keyframes fillPath {
    to {
        fill: #8ab73f;
    }
}
