html {
    scroll-behavior: smooth;
}

/* ==========================================
   HEADER — Frosted glass on events page only
========================================== */

#header{
    background:rgba(0,0,0,.35);
    backdrop-filter:blur(12px);
    border-bottom:none;
    box-shadow:none;

    /* Intro animation — does NOT lock styles after finishing */
    animation:navReveal 1s ease;
    animation-fill-mode:none;
}

@keyframes navReveal{
    from{
        opacity:0;
        transform:translateY(-10px);
        backdrop-filter:blur(0px);
        background:rgba(0,0,0,0);
    }
    to{
        opacity:1;
        transform:translateY(0);
        backdrop-filter:blur(12px);
        background:rgba(0,0,0,.35);
    }
}

/* ==========================================
   EVENTS PAGE
========================================== */

.events-page{
    position:relative;
    z-index:10;

    background:#111;

    min-height:100vh;
}

/* ==========================================
   EVENTS HERO BANNER
========================================== */

.ep-hero{
    position:relative;

    height:100vh;
    min-height:500px;

    background:#1c1c1c;

    display:flex;
    align-items:flex-end;

    overflow:hidden;
}

.ep-hero-upcpi{
    background:url('../image/UPCPI.jpg') center center / cover no-repeat;
}

.ep-poster-apyc{
    background:url('../image/APYC.png') center center / cover no-repeat;
}

.ep-poster-hyphen{
    background:url('../image/Hyphen.png') center center / cover no-repeat;
}

.ep-hero-overlay{
    position:absolute;
    inset:0;

    background:linear-gradient(
        180deg,
        rgba(0,0,0,.15) 0%,
        rgba(0,0,0,.88) 100%
    );
}

.ep-hero-content{
    position:relative;
    z-index:2;

    padding:0 8% 70px;
}

.ep-hero-content h2{
    font-size:clamp(1.8rem, 4vw, 2.8rem);
    font-weight:800;

    line-height:1.15;

    margin-bottom:.6rem;
}

.ep-hero-content{
    position:relative;
    z-index:2;

    padding:0 8% 70px;

    width:100%;
    display:flex;
    align-items:flex-end;
    justify-content:space-between;
    gap:30px;
}


.ep-hero-btns{
    display:flex;
    gap:12px;
    margin-top:24px;
    flex-wrap:wrap;
}

.ep-hero-btn-primary{
    padding:14px 32px;
    border-radius:50px;
    background:#fff;
    color:#111;
    font-weight:700;
    font-size:.9rem;
    text-decoration:none;
    transition:.3s;
}

.ep-hero-btn-primary:hover{
    background:#ff5a00;
    color:#fff;
}

.ep-hero-btn-ghost{
    padding:14px 32px;
    border-radius:50px;
    background:rgba(255,255,255,.12);
    border:1px solid rgba(255,255,255,.2);
    color:#fff;
    font-weight:600;
    font-size:.9rem;
    text-decoration:none;
    transition:.3s;
}

.ep-hero-btn-ghost:hover{
    background:rgba(255,255,255,.22);
}

/* ==========================================
   EVENTS BODY
========================================== */

.ep-body{
    padding:50px 8%;

    display:flex;
    justify-content:center;
}

.ep-list{
    width:100%;
    max-width:1100px;
}

/* ==========================================
   FEATURED BANNER
========================================== */

.ep-featured{
    position:relative;

    border-radius:14px;
    overflow:hidden;

    margin-bottom:65px;

    min-height:160px;
}

.ep-featured-bg{
    position:absolute;
    inset:0;

    background:linear-gradient(135deg, #1a1a1a 0%, #252525 100%);

    border:1px solid rgba(255,255,255,.08);
    border-radius:14px;
}

.ep-featured-inner{
    position:relative;
    z-index:2;

    padding:45px 50px;

    display:flex;
    justify-content:space-between;
    align-items:center;

    gap:30px;

    flex-wrap:wrap;
}

.ep-featured-info h3{
    font-size:1.9rem;
    font-weight:800;

    margin-bottom:.4rem;
}

.ep-featured-info p{
    color:rgba(255,255,255,.55);
    font-size:.95rem;
}

.ep-featured-actions{
    display:flex;
    gap:14px;
    flex-shrink:0;
    flex-wrap:wrap;
}

.ep-btn-white{
    padding:14px 28px;
    border-radius:8px;

    background:#fff;
    color:#111;

    text-decoration:none;

    font-weight:700;
    font-size:.88rem;

    transition:.3s;
}

.ep-btn-white:hover{
    background:#ff5a00;
    color:#fff;
}

.ep-btn-ghost{
    padding:14px 28px;
    border-radius:8px;

    background:rgba(255,255,255,.07);

    border:1px solid rgba(255,255,255,.15);

    color:#fff;

    text-decoration:none;

    font-weight:600;
    font-size:.88rem;

    transition:.3s;
}

.ep-btn-ghost:hover{
    background:rgba(255,255,255,.12);
}

/* ==========================================
   LIST TITLE
========================================== */

.ep-list-title{
    font-size:1.6rem;
    font-weight:800;
    margin-bottom:35px;
    padding-left:16px;
    border-left:4px solid #ff5a00;
}

/* ==========================================
   EVENTS GRID
========================================== */

.ep-grid{
    display:grid;
    grid-template-columns:repeat(3, 1fr);
    gap:20px;
}

/* ==========================================
   EVENT CARD
========================================== */

.ep-card{
    border-radius:14px;
    overflow:hidden;

    background:#111;

    cursor:pointer;

    transition:
        transform .3s ease,
        box-shadow .3s ease;
}

.ep-card:hover{
    transform:translateY(-5px);

    box-shadow:
        0 0 0 1px #ff5a00,
        0 16px 40px rgba(255,90,0,.18);
}

/* ==========================================
   CARD POSTER
========================================== */

.ep-card-poster{
    position:relative;

    width:calc(100% - 20px);
    height:200px;

    margin:15px auto 0;

    border-radius:23px;

    display:flex;
    flex-direction:column;
    justify-content:center;
    align-items:center;

    gap:10px;

    overflow:hidden;
}

.ep-card-poster img{
    width:100%;
    height:100%;
    object-fit:contain;
    background:#111;
    display:block;
}

/* ==========================================
   CARD INFO (below poster)
========================================== */

.ep-card-info{
    padding:12px 14px 16px;

    background:transparent;
}

.ep-card-info h4{
    font-size:.9rem;
    font-weight:800;

    margin-bottom:2px;
}

.ep-card-location{
    color:rgba(255,255,255,.5);

    font-size:.75rem;

    margin-bottom:10px;
}

.ep-card-meta{
    display:flex;
    flex-direction:column;
    gap:8px;
}

.ep-card-meta span{
    display:flex;
    align-items:center;
    gap:8px;

    color:rgba(255,255,255,.6);

    font-size:.75rem;
}

.ep-card-meta i{
    width:13px;
    color:rgba(255,255,255,.4);
}

/* ==========================================
   EVENT DETAIL MODAL
========================================== */

.event-modal{
    position:fixed;
    inset:0;

    z-index:10000;

    display:flex;
    justify-content:center;
    align-items:center;

    opacity:0;
    visibility:hidden;

    transition:.4s ease;
}

.event-modal.active{
    opacity:1;
    visibility:visible;
}

.event-modal-overlay{
    position:absolute;
    inset:0;

    background:rgba(0,0,0,.80);
    backdrop-filter:blur(4px);
}

.event-modal-panel{
    position:relative;
    z-index:2;

    width:96vw;
    max-width:96vw;
    height:92vh;
    max-height:92vh;

    background:#111;
    border-radius:16px;

    overflow:hidden;

    display:grid;
    grid-template-columns:60% 1fr;

    transform:translateY(40px);
    opacity:0;

    transition:.4s cubic-bezier(.25,.8,.25,1);
}

.event-modal.active .event-modal-panel{
    transform:translateY(0);
    opacity:1;
}

/* ==========================================
   MODAL CLOSE BUTTON
========================================== */

.event-modal-close{
    position:absolute;
    top:18px;
    right:18px;

    z-index:10;

    width:42px;
    height:42px;

    border-radius:50%;
    border:none;
    outline:none;

    cursor:pointer;

    display:flex;
    justify-content:center;
    align-items:center;

    color:#fff;

    background:rgba(255,255,255,.12);
    backdrop-filter:blur(10px);

    transition:.3s;
}

.event-modal-close:hover{
    background:#ff5a00;
}

/* ==========================================
   MODAL — RIGHT COLUMN (info, scrollable)
========================================== */

.event-modal-left{
    padding:40px 40px 40px 36px;
    height:100%;
    overflow-y:auto;
    grid-column:2;
}

.event-modal-title{
    font-size:1.75rem;
    font-weight:900;

    margin-bottom:16px;

    line-height:1.15;

    padding-right:50px;
}

.event-modal-desc{
    color:rgba(255,255,255,.65);

    font-size:.88rem;
    line-height:1.75;

    margin-bottom:28px;
}

/* ==========================================
   MODAL — LEFT COLUMN (poster, fixed)
========================================== */

.event-modal-right{
    position:relative;
    grid-column:1;

    height:100%;

    align-self:stretch;

    overflow:hidden;
}

.event-modal-poster{
    width:100%;
    height:100%;

    background-size:cover;
    background-position:center center;

    border-radius:16px 0 0 16px;
}

/* ==========================================
   VENUE CARD
========================================== */

.event-modal-venue-card{
    background:rgba(255,255,255,.04);
    border:1px solid rgba(255,255,255,.09);

    border-radius:12px;

    padding:20px;

    margin-bottom:24px;
}

.event-modal-venue-top{
    display:flex;
    align-items:center;
    gap:14px;

    margin-bottom:16px;
}

.event-modal-venue-icon{
    width:38px;
    height:38px;

    border-radius:8px;

    background:rgba(255,90,0,.12);

    display:flex;
    justify-content:center;
    align-items:center;

    color:#ff5a00;

    flex-shrink:0;
}

.event-modal-venue-info{
    flex:1;
    min-width:0;

    display:flex;
    flex-direction:column;
    gap:3px;
}

.event-modal-venue-name{
    font-size:.95rem;
    font-weight:800;

    color:#fff;

    white-space:nowrap;
    overflow:hidden;
    text-overflow:ellipsis;
}

.event-modal-venue-address{
    font-size:.8rem;
    color:rgba(255,255,255,.5);

    white-space:nowrap;
    overflow:hidden;
    text-overflow:ellipsis;
}

/* ==========================================
   VENUE ACTIONS
========================================== */

.event-modal-venue-actions{
    display:flex;
    flex-direction:row;
    gap:16px;
    flex-shrink:0;
}

/* ==========================================
   DIRECTIONS BUTTON
========================================== */

.event-modal-directions-btn,
.event-modal-copy-btn{
    display:flex;
    flex-direction:column;
    align-items:center;
    gap:6px;

    padding:6px;

    border:none;
    border-radius:0;

    background:transparent;

    color:rgba(255,255,255,.5);

    font-family:'Montserrat', sans-serif;
    font-size:.7rem;
    font-weight:600;

    text-decoration:none;

    cursor:pointer;

    transition:.3s;
}

.event-modal-directions-btn i,
.event-modal-copy-btn i{
    font-size:1rem;
    color:#fff;
}

.event-modal-directions-btn:hover,
.event-modal-copy-btn:hover{
    background:transparent;
    border-color:transparent;
    color:#fff;
}

.event-modal-copy-btn.copied{
    background:#22c55e;
    border-color:#22c55e;
    color:#fff;
}

.event-modal-venue-row{
    display:flex;
    align-items:center;
    gap:12px;

    color:rgba(255,255,255,.6);
    font-size:.83rem;

    padding-top:10px;
    border-top:1px solid rgba(255,255,255,.06);

    margin-top:10px;
}

.event-modal-venue-row i{
    color:#ff5a00;
    width:14px;
    flex-shrink:0;
}

/* ==========================================
   META ROWS
========================================== */

.event-modal-meta{
    display:flex;
    flex-direction:column;

    gap:16px;

    padding:20px;

    background:rgba(255,255,255,.04);
    border:1px solid rgba(255,255,255,.08);

    border-radius:12px;

    margin-bottom:24px;
}

.event-modal-row{
    display:flex;
    align-items:flex-start;
    gap:14px;
}

.event-modal-row > i{
    width:14px;
    margin-top:3px;

    color:#ff5a00;
    flex-shrink:0;
}

.event-modal-row > div{
    display:flex;
    flex-direction:column;
    gap:2px;
}

.event-modal-meta-label{
    font-size:.68rem;
    font-weight:700;

    letter-spacing:2px;
    text-transform:uppercase;

    color:rgba(255,255,255,.4);
}

.event-modal-meta-value{
    font-size:.88rem;
    font-weight:600;

    color:#fff;
}

/* ==========================================
   PROVIDES SECTION
========================================== */

.event-modal-provides{
    margin-bottom:24px;
}

.event-modal-provides h4,
.event-modal-faqs h4{
    font-size:.72rem;
    font-weight:700;

    letter-spacing:2px;
    text-transform:uppercase;

    color:rgba(255,255,255,.4);

    margin-bottom:12px;
}

.event-modal-tags{
    display:flex;
    flex-wrap:wrap;
    gap:10px;
}

.event-modal-tags span{
    display:flex;
    align-items:center;
    gap:8px;

    padding:9px 16px;

    border-radius:50px;

    background:rgba(255,255,255,.06);
    border:1px solid rgba(255,255,255,.1);

    font-size:.8rem;
    font-weight:600;

    color:rgba(255,255,255,.75);
}

.event-modal-tags span i{
    color:#ff5a00;
    font-size:.75rem;
}

/* ==========================================
   FAQs
========================================== */

.event-modal-faqs{
    margin-bottom:28px;
}

.event-faq-item{
    border-top:1px solid rgba(255,255,255,.08);
}

.event-faq-item:last-child{
    border-bottom:1px solid rgba(255,255,255,.08);
}

.event-faq-toggle{
    width:100%;

    display:flex;
    justify-content:space-between;
    align-items:center;
    gap:12px;

    padding:16px 0;

    background:transparent;
    border:none;
    outline:none;

    cursor:pointer;

    color:#fff;

    font-family:'Montserrat', sans-serif;
    font-size:.88rem;
    font-weight:600;

    text-align:left;

    transition:.3s;
}

.event-faq-toggle:hover{
    color:#ff5a00;
}

.event-faq-toggle i{
    flex-shrink:0;

    font-size:.75rem;

    color:rgba(255,255,255,.4);

    transition:transform .3s ease;
}

.event-faq-item.open .event-faq-toggle i{
    transform:rotate(180deg);
}

.event-faq-answer{
    max-height:0;
    overflow:hidden;

    transition:max-height .35s ease;
}

.event-faq-item.open .event-faq-answer{
    max-height:200px;
}

.event-faq-answer p{
    padding-bottom:16px;

    color:rgba(255,255,255,.6);
    font-size:.84rem;
    line-height:1.7;
}

/* ==========================================
   CTA BUTTON
========================================== */

.event-modal-cta{
    width:100%;

    padding:17px;

    border:none;
    outline:none;

    cursor:pointer;

    border-radius:8px;

    background:#fff;
    color:#111;

    font-family:'Montserrat', sans-serif;
    font-size:.92rem;
    font-weight:800;

    letter-spacing:1px;

    display:flex;
    justify-content:center;
    align-items:center;

    gap:10px;

    transition:.3s;
}

.event-modal-cta:hover{
    background:#ff5a00;
    color:#fff;

    transform:translateY(-3px);

    box-shadow:0 12px 35px rgba(255,90,0,.35);
}

/* ==========================================
   FOOTER BOTTOM (LOWERED)
========================================== */

/* BOTTOM SECTION */
.footer-bottom{
    position:relative;
    z-index:2;

    max-width:1500px;

    margin:90px auto 0;

    padding:18px 60px 0; /* add left and right spacing */

    border-top:1px solid rgba(255,255,255,.08);

    display:flex;
    justify-content:space-between;
    align-items:center;

    box-sizing:border-box;
}

.footer-bottom p{
    color:#bdbdbd;
    font-size:.95rem;

    margin:0;

    padding-left:15px;
}

.footer-bottom span{
    color:#ff5a00;
    font-weight:700;
}

/* ==========================================
   RESPONSIVE — Events
========================================== */

@media(max-width:991px){

    .ep-grid{
        grid-template-columns:repeat(2, 1fr);
    }

    .ep-featured-inner{
        flex-direction:column;
        align-items:flex-start;
        padding:35px;
    }

}

@media(max-width:700px){

    /* Modal panel — full screen, single scrollable column */
    .event-modal-panel{
        width:100vw;
        max-width:100vw;
        height:100vh;
        max-height:100vh;

        border-radius:0;

        display:flex;
        flex-direction:column;

        grid-template-columns:unset;

        overflow-y:auto;
        overflow-x:hidden;
        -webkit-overflow-scrolling:touch;
    }

    /* Close button — stays on top of everything */
    .event-modal-close{
        position:fixed;
        top:12px;
        right:12px;
        z-index:100000;
    }

    /* Poster — normal block at top, scrolls away with content */
    .event-modal-right{
        position:relative;
        grid-column:unset;
        order:-1;

        width:100%;
        height:280px;
        min-height:280px;
        flex-shrink:0;

        overflow:hidden;
        z-index:2;
    }

    /* Poster fade at bottom */
    .event-modal-right::after{
    content:'';
    position:absolute;
    bottom:0;
    left:0;
    width:100%;
    height:160px;
    background:linear-gradient(
        to bottom,
        rgba(17,17,17,0)   0%,
        rgba(17,17,17,.08) 20%,
        rgba(17,17,17,.25) 40%,
        rgba(17,17,17,.55) 60%,
        rgba(17,17,17,.82) 80%,
        rgba(17,17,17,1)   100%
    );
    pointer-events:none;
    z-index:3;
    }

    /* Poster image */
    .event-modal-poster{
        width:100%;
        height:280px;
        border-radius:0;
        background-size:cover;
        background-position:center center;
    }

    /* Info column — normal block below poster */
    .event-modal-left{
        position:relative;
        grid-column:unset;

        width:100%;
        height:auto;
        overflow:visible;

        padding:24px 20px 48px;
        margin-top:0;
        z-index:2;
        background:#111;
        top:unset;
        left:unset;
    }

}

@media(max-width:600px){

    .ep-grid{
        grid-template-columns:1fr;
    }

    .ep-hero{
    height:100vh;
    min-height:500px;
    flex-direction:column;
    align-items:stretch;
    justify-content:flex-end;
    }

    .ep-hero-apyc{
        background:url('../image/APYC.png') center center / cover no-repeat;
    }

    .ep-hero::before{
        content:'';
        display:block;
        width:100%;
        height:55vw;
        min-height:240px;
        max-height:360px;
    }

    .ep-hero-overlay{
    background:linear-gradient(
        180deg,
        rgba(0,0,0,.3) 0%,
        rgba(0,0,0,.95) 100%
        );
    }

    .ep-hero-content{
    position:relative;
    z-index:2;
    padding:24px 6% 48px;
    background:transparent;
    width:100%;
    flex-direction:column;
    align-items:flex-start;
    gap:0;
    }

    .ep-hero-content h2{
        font-size:1.2rem;
    }

    .ep-body{
        padding:40px 6%;
    }

    .ep-featured-actions{
        width:100%;
    }

    .ep-btn-white,
    .ep-btn-ghost{
        flex:1;
        text-align:center;
        justify-content:center;
    }
    

    /* HERO BUTTONS — stack vertically on mobile */
    .ep-hero-btns{
    flex-direction:column;
    gap:10px;
    margin-top:20px;
    width:100%;
    }

    .ep-hero-btn-primary,
    .ep-hero-btn-ghost{
    text-align:center;
    width:100%;
    padding:16px;
    justify-content:center;
    display:flex;
    }
    
    /* ==========================================
   EVENT MODAL — MOBILE POSTER FIX
    ========================================== */

    @media (max-width: 768px) {

    .event-modal-panel {
        display: flex;
        flex-direction: column;
    }

    .event-modal-right {
        order: -1; /* Pull poster to the top */
    }
    
    .event-modal-right {
        order: -1;
        width: 100%;
    }

    .event-modal-poster {
        width: 100%;
        height: 260px; /* adjust to taste */
        border-radius: 12px 12px 0 0;
    }
}

}
