/* CSS Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    max-width: 100%;
}

html, body {
    font-family: 'Montserrat', sans-serif;
    line-height: 1.6;
    color: #333;
    overflow-x: hidden;
    width: 100%;
    max-width: 100%;
}

html {
    scroll-behavior: smooth;
}

body {
    position: relative;
    overscroll-behavior-x: none;
}

[data-aos] {
    contain: layout;  /* 👈 contains layout shifts */
    backface-visibility: hidden;
    transform: translateZ(0); /* trigger GPU compositing */
    min-height: 1px;
}

[data-aos]:not(.timeline-item) {
    overflow: hidden;
    overflow-anchor: none;  /* Prevent scroll jump */
}

/* let the gallery tiles pop out while keeping other AOS sections clipped */
.about-gallery[data-aos]{
    contain: none;         /* ← remove paint containment      */
    overflow: visible;     /* ← and allow overflow            */
}

/* let timeline cards draw outside their box again */
.timeline-item[data-aos]{
    contain: none;        /* or `contain: paint` if you still want GPU boost */
    overflow: visible;    /* be explicit */
}

/* Color Variables */
:root {
    --sky-blue: #4DB3FF;
    --white: #FFFFFF;
    --black: #000000;
    --red: #E53935;
    --dark-red: #800001;
    --light-gray: #f8f9fa;
    --dark-gray: #666;
    --overlay-dark-little: rgba(0, 0, 0, 0.2);
    --overlay-dark: rgba(0, 0, 0, 0.4);
    --overlay-blue: rgba(77, 179, 255, 0.3);
    --overlay-white: rgba(255, 255, 255, 0.8);
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    font-family: 'Playfair Display', serif;
    font-weight: 600;
    margin-bottom: 1rem;
}

/* Container */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    width: 100%;
    overflow-x: hidden;
}

/* Image transitions */
img {
    transition: opacity 0.3s ease;
}



/* Navigation */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
    transform: translateY(-100%);
    opacity: 0;
}

.navbar.visible {
    transform: translateY(0);
    opacity: 1;
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem 2rem;
}

.nav-brand {
    display: flex;
    align-items: center;
}

.nav-logo {
    height: 40px;
    width: auto;
    object-fit: contain;
}

.nav-menu {
    display: flex;
    gap: 2rem;
}

.nav-link {
    text-decoration: none;
    color: var(--black);
    font-weight: 500;
    position: relative;
    transition: color 0.3s ease;
}

.nav-link:hover {
    color: var(--red);
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--red);
    transition: width 0.3s ease;
}

.nav-link:hover::after {
    width: 100%;
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.language-toggle {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.lang-option {
    cursor: pointer;
    font-weight: 500;
    color: var(--dark-gray);
    transition: color 0.3s ease;
}

.lang-option.active {
    color: var(--red);
}

.lang-separator {
    color: var(--dark-gray);
}

.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
}

.hamburger span {
    width: 25px;
    height: 3px;
    background: var(--black);
    margin: 3px 0;
    transition: 0.3s;
}

/* Section Styles */
section {
    padding: 3rem 0;
    width: 100%;
    overflow-x: hidden;
    scroll-margin-top: 80px;
}

.section-header {
    text-align: center;
    margin-bottom: 3rem;
}

.section-title {
    font-size: 3rem;
    color: var(--black);
    margin-bottom: 1rem;
}

.section-subtitle {
    font-size: 1.2rem;
    color: var(--dark-gray);
    max-width: 600px;
    margin: 0 auto;
}


/* HERO SECTION ITSELF */
.hero {
    min-height: 100vh;         /* full viewport */
    position: relative;
    display: flex;             /* keeps .hero-content centered */
    align-items: center;
    justify-content: center;
    text-align: center;
    color: var(--white);
    overflow:hidden;
}

/* the moving picture */
.hero-background {
    position: absolute; 
    inset: 0;
    height:125vh;
    top:-12.5vh;
    background: url("../assets/hero-front.webp") center / cover no-repeat;
    will-change: transform;
    z-index: -2;
}

/* optional overlay kept from your code */
.hero::before{
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg,var(--overlay-dark-little));
    z-index: 0;
}

.hero-content {
    width: max-content;
    max-width: 90vw;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    position: relative;
    z-index: 1;
}

.hero-title {
    font-size: 4rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.hero-subtitle {
    font-size: 1.25rem;
    margin-bottom: 2rem;
    opacity: 0.9;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.3);
}

.hero-cta {
    padding: 1rem 2.5rem;
    font: 450 1.1rem/1 'Montserrat', sans-serif;
    background: transparent;
    border: 2px solid var(--red);
    border-radius: 5px;
    color: var(--white);
    transition: background .2s, transform .2s, box-shadow .2s;
    cursor: pointer;
}

.hero-cta:hover,
.hero-cta:focus-visible {
  background: var(--red);
  box-shadow: 0 5px 15px rgba(229,57,53,.4);
  transform: translateY(-2px);
}



/* About Section */
.about {
    background: var(--light-gray);
}

/* let the gallery tiles pop out while keeping other AOS sections clipped */
.about-gallery[data-aos]{
    overflow: visible;        /* turn the clipping back off only here */
}

.about-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.about-text p {
    margin-bottom: 1.5rem;
    color: var(--dark-gray);
    line-height: 1.8;
}

.about-gallery {
    position: relative;
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
    width: 100%;
    overflow: visible;
}

.gallery-item {
    width: 100%;
    height: 200px;
    object-fit: cover;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
}

.gallery-item:hover {
    transform: scale(1.05);
    z-index:2;
}


/* Guest Program Section */
.guest-program {
    position:relative;
    background:url("../assets/program-background.webp") center/cover no-repeat;
    color:var(--white);
}

.guest-program::before {
    content: "";
    position: absolute; 
    inset: 0;
    background: linear-gradient(135deg,var(--overlay-dark));
    z-index: 0; 
    pointer-events: none;
}

.guest-program > .container {
    position:relative;                /* lifts real content */
    z-index:1;
}

.guest-program .section-title {
    color: var(--white);
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.guest-program .section-subtitle {
    color: var(--white);
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.3);
}

.program-features {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-bottom: 3rem;
}

.feature-card {
    background: var(--overlay-white);
    padding: 2.5rem 2rem;
    border-radius: 15px;
    text-align: center;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.feature-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.feature-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 1.5rem;
    background: var(--red);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--white);
    font-size: 2rem;
}

.feature-title {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: var(--black);
}

.feature-description {
    color: var(--dark-gray);
    line-height: 1.6;
}

.program-note {
    background: var(--red);
    padding: 1.5rem;
    border-radius: 10px;
    text-align: center;
}

.note-content {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    color: var(--white);
}

.note-content i {
    font-size: 1.5rem;
}



/* Awards Timeline */
.awards {
    background: var(--light-gray);
}

.timeline {
    position: relative;
    max-width: 1000px;
    margin: 0 auto;
}

.timeline::before {
    content: '';
    position: absolute;
    width: 4px;
    background: var(--red);
    top: 0;
    bottom: 0;
    left: 50%;
    margin-left: -2px;
}

.timeline-item {
    padding: 1rem 0;
    position: relative;
    background-color: inherit;
    width: 50%;
}

.timeline-item:nth-child(odd) {
    left: 0;
}

.timeline-item:nth-child(even) {
    left: 50%;
}

.timeline-item::after{
    content:'';
    position:absolute;
    width:25px;               /* inner circle */
    height:25px;
    background:var(--red);
    border:4px solid var(--white);   /* makes total size 33 × 33 px */
    top:50%;
    left:100%;                /* start at the item’s right edge … */
    transform:translate(-50%,-50%);  /* … then shift left/up by ½ dot */
    border-radius:50%;
    z-index:1;
}

.timeline-item:nth-child(even)::after{
    left:0;                   /* item’s left edge */
    transform:translate(-50%,-50%);
}

.timeline-year {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    font-family: 'Playfair Display', serif;
    font-size: 2rem;
    font-weight: 700;
    color: var(--red);
}

.timeline-item:nth-child(odd) .timeline-year {
    right: -120px;
}

.timeline-item:nth-child(even) .timeline-year {
    left: -120px;
}

.timeline-content {
    padding: 2rem;
    background: var(--white);
    border-radius: 15px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    margin: 0 2rem;
}

.timeline-image {
    width: 100%;
    height: 200px;
    object-fit: cover;
    border-radius: 10px;
    margin-bottom: 1rem;
}

.timeline-content h3 {
    color: var(--black);
    margin-bottom: 0.5rem;
}

.timeline-content p {
    color: var(--dark-gray);
    line-height: 1.6;
}

/* Medium screen adjustments for timeline */
@media (max-width: 1024px) and (min-width: 769px) {
    .timeline-item::after,
    .timeline-item:nth-child(even)::after {
        width: 20px;
        height: 20px;
        border: 3px solid var(--white);
    }
}



/* Listen Section */
.listen {
    background: var(--dark-red);
    color: var(--white);
}

.listen .section-title {
    color: var(--white);
}

.listen .section-subtitle {
    color: rgba(255, 255, 255, 0.9);
}

.music-player {
    max-width: 800px;
    margin: 0 auto;
}

.playlist-container {
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.player-controls {
    text-align: center;
    margin-top: 1.5rem;
}

.player-note {
    color: rgba(255, 255, 255, 0.8);
    font-style: italic;
}




/* References Section */
.references {
    background: var(--light-gray);
}

.references-carousel {
    position: relative;
    max-width: 800px;
    margin: 0 auto;
}

.glider-contain {
    position: relative;
    overflow: hidden;
    border-radius: 15px;
}

.glider {
    margin: 0;
    position: relative;
    overflow: hidden;
}

.reference-slide {
    background: var(--white);
    padding: 3rem 2rem;
    text-align: center;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    border-radius: 15px;
}

/* Override Glider.js default styles to match our design */
.glider-track {
    width: 100%;
}

.glider > * {
    user-select: none;
    outline: none;
}

.reference-logo {
    width: 120px;
    height: 120px;
    margin: 0 auto 2rem;
    border-radius: 50%;
    overflow: hidden;
    background: var(--light-gray);
    display: flex;
    align-items: center;
    justify-content: center;
}

.reference-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.reference-slide h3 {
    color: var(--black);
    margin-bottom: 1rem;
}

.reference-slide p {
    color: var(--dark-gray);
    font-style: italic;
    line-height: 1.8;
    max-width: 500px;
    margin: 0 auto;
}

.carousel-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: var(--red);
    color: var(--white);
    border: none;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    font-size: 1.2rem;
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 2;
}

.carousel-btn:hover {
    background: #2196F3;
    transform: translateY(-50%) scale(1.1);
}

.carousel-prev {
    left: -25px;
}

.carousel-next {
    right: -25px;
}

/* Carousel Dots Styling */
.carousel-dots {
    display: flex;
    justify-content: center;
    gap: 12px;
    margin-top: 2rem;
    padding: 0;
}

.glider-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.3);
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
    padding: 0;
}

.glider-dot:hover {
    background: rgba(229, 57, 53, 0.7);
    transform: scale(1.2);
}

.glider-dot.active {
    background: var(--red);
    transform: scale(1.3);
}

/* Ensure single slide visibility */
.glider {
    overflow: hidden;
}

.glider-track {
    width: 100%;
    transition: transform 0.5s ease;
}

.reference-slide {
    width: 100%;
    flex-shrink: 0;
}





/* Contact & Footer Combined Section */
.contact-footer {
    position: relative;
    color: var(--white);
    overflow: hidden;
    padding: 5rem 0 3rem 0;
}

.contact-footer-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('../assets/hero-back.webp');
    background-size: cover;
    background-position: center;
    z-index: -2;
}

.contact-footer-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    z-index: -1;
}

.contact-content {
    position: relative;
    text-align: center;
    max-width: 600px;
    margin: 0 auto 4rem auto;
    z-index: 1;
}

.contact-title {
    font-size: 3rem;
    color: var(--white);
    margin-bottom: 1rem;
}

.contact-subtitle {
    font-size: 1.2rem;
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 3rem;
}

.contact-details {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.contact-item {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    font-size: 1.1rem;
}

.contact-item i {
    color: var(--red);
    font-size: 1.3rem;
    width: 20px;
}

.contact-item a {
    color: var(--white);
    text-decoration: none;
    transition: color 0.3s ease;
}

.contact-item a:hover {
    color: var(--red);
}

/* Footer Content within Contact-Footer Section */
.footer-content {
    position: relative;
    text-align: center;
    z-index: 1;
}

.footer-social {
    margin-bottom: 1.5rem;
}

.social-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 50px;
    height: 50px;
    background: var(--red);
    color: var(--white);
    border-radius: 50%;
    font-size: 1.5rem;
    text-decoration: none;
    transition: all 0.3s ease;
}

.social-link:hover {
    background: var(--white);
    color: var(--red);
    transform: translateY(-3px);
}

.footer-copyright {
    color: rgba(255, 255, 255, 0.8);
}




/* Responsive Design */
@media (max-width: 768px) {
    /* Prevent horizontal scrolling */
    html, body {
        overflow-x: hidden !important;
        width: 100% !important;
        max-width: 100% !important;
    }
    
    .hamburger {
        display: flex;
    }
    
    .nav-menu {
        position: fixed;
        left: 0;
        top: 70px;
        flex-direction: column;
        background-color: rgba(255, 255, 255, 0.98);
        width: 100%;
        text-align: center;
        transform: translateX(-100%);   /* slide OUT to the left */
        transition: transform .3s ease;
        box-shadow: 0 10px 27px rgba(0, 0, 0, 0.05);
        padding: 2rem 0;
    }
    
    .nav-menu.active{
      transform:translateX(0);       /* slide IN */
    }

    /* Ensure all containers stay within viewport */
    .container,
    .nav-container,
    .about-content,
    .program-features,
    .gallery-grid,
    .timeline-container {
        max-width: 100% !important;
        overflow-x: hidden !important;
    }

    .section-title {
        font-size: 2rem;
    }

    .hero-title {
        font-size: 2.5rem;
    }

    /* Make sure grid items don't overflow */
    .about-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .program-features {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .timeline-content {
        margin: 0;
    }
    
    /* Ensure all timeline dots align with spine on smaller screens */
    .timeline-item::after, 
    .timeline-item:nth-child(even)::after,
    .timeline-item:nth-child(odd)::after {
        left: 20px !important;
        transform: translate(-50%, -50%) !important;
        width: 18px !important;
        height: 18px !important;
        border: 2px solid var(--white) !important;
    }

    /* spine at 20 px from edge */
    .timeline::before{
      left:20px;
    }

    /* full-width cards */
    .timeline-item {
      width: 100%;
      left: 0 !important;
      padding-left: 70px;
    }

    .timeline-item::after, 
    .timeline-item:nth-child(even)::after,
    .timeline-item:nth-child(odd)::after {
        left: 20px !important;
        transform: translate(-50%, -50%) !important;
        width: 20px !important;
        height: 20px !important;
        border: 3px solid var(--white) !important;
    }

    .timeline-year{
      display:none;
    }

    .carousel-prev,
    .carousel-next {
        display: none;
    }

    .carousel-dots {
        margin-top: 1.5rem;
        gap: 10px;
    }

    .glider-dot {
        width: 10px;
        height: 10px;
    }

    .contact-details {
        align-items: flex-start;
    }

    .contact-item {
        justify-content: flex-start;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 1rem;
    }
    
    .nav-container {
        padding: 1rem;
    }
    
    .hero-title {
        font-size: 2rem;
    }
    
    .hero-subtitle {
        font-size: 1rem;
    }
    
    .section-title {
        font-size: 1.8rem;
    }
    
    .feature-card {
        padding: 2rem 1.5rem;
    }
    
    .timeline-item {
        padding-left: 3rem;
    }
    
    .timeline-year {
        left: -50px !important;
        font-size: 1.2rem;
    }
}


/* Focus states for accessibility */
.nav-link:focus,
.btn:focus,
.lang-option:focus {
    outline: 2px solid var(--red);
    outline-offset: 2px;
}