﻿/* =========================================
   GALLERY PAGE
   DR. SHYAM SINGH PUBLIC ACADEMY
   ========================================= */

.gallery-page {
    background: #fbf6ec;
    color: #2a2320;
}


/* =========================================
   HERO
   ========================================= */

.gallery-hero {
    min-height: 460px;
    position: relative;
    display: flex;
    align-items: center;
    background: linear-gradient( rgba(70, 7, 19, 0.82), rgba(110, 20, 35, 0.88) ), url('/images/Banner-Image.jpeg') center center / cover no-repeat;
    overflow: hidden;
}

    .gallery-hero::before {
        content: "";
        position: absolute;
        width: 350px;
        height: 350px;
        right: -120px;
        top: -130px;
        border: 1px solid rgba(225, 180, 94, 0.35);
        border-radius: 50%;
    }

    .gallery-hero::after {
        content: "";
        position: absolute;
        width: 180px;
        height: 180px;
        left: -80px;
        bottom: -80px;
        border: 25px solid rgba(225, 180, 94, 0.08);
        border-radius: 50%;
    }

.gallery-hero-content {
    position: relative;
    z-index: 2;
    padding: 90px 15px;
    color: #fff;
}

.gallery-eyebrow {
    color: #e1b45e;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 3px;
    display: inline-block;
    margin-bottom: 15px;
}

.gallery-hero h1 {
    font-size: clamp(48px, 7vw, 78px);
    line-height: 1;
    margin: 0 0 25px;
    font-weight: 700;
}

    .gallery-hero h1 span {
        color: #e1b45e;
    }

.gallery-hero p {
    max-width: 680px;
    color: rgba(255,255,255,0.85);
    font-size: 18px;
    line-height: 1.75;
    margin: 0;
}


/* =========================================
   INTRO
   ========================================= */

.gallery-intro {
    padding: 90px 0 55px;
}

.gallery-intro-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 70px;
    align-items: end;
}

.gallery-label {
    display: inline-block;
    color: #b88625;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 2.5px;
    margin-bottom: 12px;
}

.gallery-intro h2 {
    color: #6e1423;
    font-size: clamp(36px, 4vw, 52px);
    line-height: 1.12;
    margin: 0;
}

    .gallery-intro h2 span {
        color: #d9a441;
    }

.gallery-line {
    width: 75px;
    height: 4px;
    background: #d9a441;
    border-radius: 10px;
    margin-top: 23px;
}

.gallery-intro p {
    color: #655d58;
    font-size: 16px;
    line-height: 1.85;
    margin: 0;
}


/* =========================================
   FEATURED SECTION
   ========================================= */

.gallery-featured {
    padding: 45px 0 100px;
}

.featured-gallery {
    display: grid;
    grid-template-columns: 1.15fr 0.85fr;
    background: #fff;
    border-radius: 28px;
    overflow: hidden;
    box-shadow: 0 25px 60px rgba(57,25,20,0.12);
}

.featured-image {
    min-height: 500px;
    position: relative;
    overflow: hidden;
}

    .featured-image img {
        width: 100%;
        height: 100%;
        object-fit: cover;
        display: block;
        transition: transform 0.7s ease;
    }

.featured-gallery:hover .featured-image img {
    transform: scale(1.04);
}

.featured-overlay {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    padding: 70px 40px 35px;
    color: #fff;
    background: linear-gradient( transparent, rgba(40,5,12,0.90) );
}

    .featured-overlay span {
        color: #e1b45e;
        font-size: 11px;
        letter-spacing: 2px;
        font-weight: 700;
    }

    .featured-overlay h3 {
        font-size: 29px;
        line-height: 1.25;
        margin: 8px 0 0;
    }

.featured-content {
    padding: 55px 45px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

    .featured-content h2 {
        color: #6e1423;
        font-size: 38px;
        line-height: 1.15;
        margin: 0;
    }

        .featured-content h2 span {
            color: #d9a441;
        }

    .featured-content > p {
        color: #665e58;
        font-size: 16px;
        line-height: 1.85;
        margin: 25px 0;
    }

.featured-points {
    display: flex;
    flex-direction: column;
    gap: 13px;
}

    .featured-points div {
        display: flex;
        align-items: center;
        gap: 12px;
        color: #514a45;
        font-size: 14px;
        font-weight: 600;
    }

    .featured-points i {
        width: 38px;
        height: 38px;
        display: flex;
        align-items: center;
        justify-content: center;
        background: rgba(110,20,35,0.08);
        color: #6e1423;
        border-radius: 10px;
        font-size: 17px;
    }


/* =========================================
   MAIN GALLERY
   ========================================= */

.gallery-section {
    padding: 100px 0;
    background: #f4ecdf;
}

.gallery-heading {
    max-width: 750px;
    margin: 0 auto 45px;
}

    .gallery-heading h2 {
        color: #6e1423;
        font-size: clamp(34px, 4vw, 50px);
        line-height: 1.15;
        margin: 0 0 18px;
    }

        .gallery-heading h2 span {
            color: #d9a441;
        }

    .gallery-heading p {
        color: #706761;
        line-height: 1.7;
        margin: 0;
    }


/* =========================================
   FILTERS
   ========================================= */

.gallery-filters {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 45px;
}

.gallery-filter {
    border: 1px solid rgba(110,20,35,0.16);
    background: #fff;
    color: #6e1423;
    padding: 10px 20px;
    border-radius: 50px;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
}

    .gallery-filter:hover,
    .gallery-filter.active {
        background: #6e1423;
        color: #fff;
        border-color: #6e1423;
        box-shadow: 0 8px 20px rgba(110,20,35,0.18);
    }


/* =========================================
   MASONRY STYLE GRID
   ========================================= */

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    grid-auto-rows: 300px;
    gap: 18px;
}

.gallery-item {
    position: relative;
    border-radius: 18px;
    overflow: hidden;
    background: #ddd;
    transition: opacity 0.25s ease, transform 0.3s ease;
}

    .gallery-item.gallery-large {
        grid-column: span 2;
        grid-row: span 2;
    }

    .gallery-item.gallery-wide {
        grid-column: span 2;
    }

    .gallery-item.gallery-tall {
        grid-row: span 2;
    }

    .gallery-item img {
        width: 100%;
        height: 100%;
        object-fit: cover;
        display: block;
        transition: transform 0.6s ease;
    }

    .gallery-item:hover img {
        transform: scale(1.08);
    }


/* =========================================
   PHOTO OVERLAY
   ========================================= */

.gallery-card-overlay {
    position: absolute;
    inset: 0;
    padding: 25px;
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 15px;
    color: #fff;
    opacity: 0;
    background: linear-gradient( transparent 20%, rgba(35,4,10,0.92) );
    transition: opacity 0.35s ease;
}

.gallery-item:hover .gallery-card-overlay {
    opacity: 1;
}

.gallery-card-overlay > div {
    max-width: 80%;
}

.gallery-card-overlay span {
    color: #e1b45e;
    font-size: 10px;
    letter-spacing: 1.8px;
    font-weight: 700;
}

.gallery-card-overlay h3 {
    font-size: 21px;
    margin: 6px 0 5px;
}

.gallery-card-overlay p {
    color: rgba(255,255,255,0.75);
    font-size: 12px;
    line-height: 1.5;
    margin: 0;
}

.gallery-view {
    width: 42px;
    height: 42px;
    flex-shrink: 0;
    border: 1px solid rgba(255,255,255,0.35);
    background: rgba(255,255,255,0.12);
    color: #fff;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(8px);
    transition: all 0.3s ease;
}

    .gallery-view:hover {
        background: #d9a441;
        border-color: #d9a441;
        color: #4b0c18;
    }

.gallery-hidden {
    opacity: 0;
    transform: scale(0.96);
}


/* =========================================
   MEMORY SECTION
   ========================================= */

.gallery-memory {
    padding: 105px 0;
    background: linear-gradient( 135deg, #5c0e1c, #781b2c );
    color: #fff;
    text-align: center;
}

.memory-content {
    max-width: 800px;
    margin: auto;
}

    .memory-content h2 {
        font-size: clamp(36px, 5vw, 58px);
        line-height: 1.15;
        margin: 5px 0 20px;
    }

        .memory-content h2 span {
            color: #e1b45e;
        }

    .memory-content p {
        max-width: 700px;
        margin: auto;
        color: rgba(255,255,255,0.76);
        font-size: 16px;
        line-height: 1.8;
    }


/* =========================================
   LIGHTBOX
   ========================================= */

.gallery-lightbox {
    position: fixed;
    inset: 0;
    z-index: 99999;
    background: rgba(25,4,8,0.96);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 35px;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

    .gallery-lightbox.show {
        opacity: 1;
        visibility: visible;
    }

.lightbox-content {
    max-width: 1000px;
    width: 90%;
    max-height: 90vh;
    text-align: center;
}

    .lightbox-content img {
        max-width: 100%;
        max-height: 72vh;
        object-fit: contain;
        border-radius: 12px;
        box-shadow: 0 30px 80px rgba(0,0,0,0.45);
    }

.lightbox-caption {
    color: #fff;
    margin-top: 15px;
}

    .lightbox-caption span {
        color: #e1b45e;
        font-size: 10px;
        letter-spacing: 2px;
    }

    .lightbox-caption h3 {
        margin: 5px 0 0;
        font-size: 22px;
    }

.lightbox-close,
.lightbox-prev,
.lightbox-next {
    position: absolute;
    border: 1px solid rgba(255,255,255,0.25);
    background: rgba(255,255,255,0.08);
    color: #fff;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(8px);
    transition: all 0.25s ease;
}

.lightbox-close {
    width: 48px;
    height: 48px;
    right: 25px;
    top: 25px;
    border-radius: 50%;
    font-size: 18px;
}

.lightbox-prev,
.lightbox-next {
    width: 52px;
    height: 52px;
    top: 50%;
    transform: translateY(-50%);
    border-radius: 50%;
    font-size: 20px;
}

.lightbox-prev {
    left: 25px;
}

.lightbox-next {
    right: 25px;
}

    .lightbox-close:hover,
    .lightbox-prev:hover,
    .lightbox-next:hover {
        background: #d9a441;
        color: #4b0c18;
        border-color: #d9a441;
    }

.gallery-lock {
    overflow: hidden;
}


/* =========================================
   RESPONSIVE
   ========================================= */

@media (max-width: 991px) {

    .gallery-intro-grid {
        grid-template-columns: 1fr;
        gap: 25px;
    }

    .featured-gallery {
        grid-template-columns: 1fr;
    }

    .featured-image {
        min-height: 420px;
    }

    .gallery-grid {
        grid-template-columns: repeat(2, 1fr);
        grid-auto-rows: 240px;
    }
}


@media (max-width: 767px) {

    .gallery-hero {
        min-height: 380px;
    }

    .gallery-hero-content {
        padding: 65px 20px;
    }

    .gallery-hero h1 {
        font-size: 50px;
    }

    .gallery-hero p {
        font-size: 15px;
    }

    .gallery-intro,
    .gallery-section {
        padding: 65px 15px;
    }

    .gallery-featured {
        padding: 20px 15px 65px;
    }

    .featured-image {
        min-height: 330px;
    }

    .featured-overlay {
        padding: 60px 25px 25px;
    }

    .featured-content {
        padding: 35px 25px;
    }

        .featured-content h2 {
            font-size: 32px;
        }

    .gallery-grid {
        grid-template-columns: 1fr;
        grid-auto-rows: 280px;
    }

    .gallery-item.gallery-large,
    .gallery-item.gallery-wide,
    .gallery-item.gallery-tall {
        grid-column: span 1;
        grid-row: span 1;
    }

    .gallery-card-overlay {
        opacity: 1;
        padding: 20px;
        background: linear-gradient( transparent 25%, rgba(35,4,10,0.88) );
    }

    .gallery-lightbox {
        padding: 15px;
    }

    .lightbox-prev {
        left: 10px;
    }

    .lightbox-next {
        right: 10px;
    }

    .lightbox-close {
        right: 12px;
        top: 12px;
    }
}
