/* 
===============================================
    GALLERY PAGE SPECIFIC STYLES
===============================================
*/

/* 1. HERO BANNER */
.gal-hero {
    height: 60vh;
    min-height: 400px;
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: #fff;
}

.gal-hero .hero-bg {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    object-fit: cover;
    z-index: -1;
    filter: brightness(0.6);
    transform: scale(1.1);
}

.gal-hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to bottom, rgba(2, 6, 23, 0.4), var(--bg-body));
    z-index: 0;
}

.gal-hero-content {
    position: relative;
    z-index: 10;
}

.gal-hero-content h1 {
    font-size: clamp(3rem, 8vw, 5.5rem);
    margin-bottom: 1rem;
}

.gal-hero-content h1 span {
    color: var(--primary);
    background: linear-gradient(to right, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* 2. FILTERS */
.gal-filters {
    display: flex;
    justify-content: center;
    gap: 12px;
    margin-bottom: 4rem;
    flex-wrap: wrap;
}

.gal-filter-btn {
    padding: 10px 24px;
    border-radius: 50px;
    background: var(--bg-surface);
    border: 1px solid var(--border);
    color: var(--text-main);
    cursor: pointer;
    font-weight: 600;
    transition: var(--transition);
}

.gal-filter-btn:hover, .gal-filter-btn.active {
    background: var(--primary);
    color: #fff;
    border-color: var(--primary);
    box-shadow: 0 5px 15px rgba(37, 99, 235, 0.3);
}

/* 3. GALLERY GRID */
.gal-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
}

.gal-item {
    position: relative;
    border-radius: 20px;
    overflow: hidden;
    cursor: pointer;
    aspect-ratio: 4/3;
    border: 1px solid var(--border);
    transition: var(--transition);
}

.gal-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.gal-overlay {
    position: absolute;
    inset: 0;
    background: rgba(15, 23, 42, 0.8);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    opacity: 0;
    transition: var(--transition);
    padding: 20px;
    text-align: center;
}

.gal-overlay i {
    font-size: 2rem;
    color: var(--secondary);
    transform: scale(0.5);
    transition: var(--transition);
}

.gal-overlay span {
    color: #fff;
    font-family: var(--font-body);
    font-weight: 600;
    font-size: 1.25rem;
    transform: translateY(20px);
    transition: var(--transition);
}

.gal-item:hover img { transform: scale(1.1); }
.gal-item:hover .gal-overlay { opacity: 1; }
.gal-item:hover .gal-overlay i { transform: scale(1); }
.gal-item:hover .gal-overlay span { transform: translateY(0); }

/* 4. VIDEO SECTION */
.video-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    margin-top: 3rem;
}

.video-card {
    background: var(--bg-surface);
    border-radius: 25px;
    overflow: hidden;
    border: 1px solid var(--border);
    transition: var(--transition);
}

.video-card:hover { border-color: var(--primary); box-shadow: var(--shadow-xl); }

.vid-thumb {
    height: 350px;
    position: relative;
    cursor: pointer;
}

.vid-thumb img { width: 100%; height: 100%; object-fit: cover; }

.play-btn-circle {
    position: absolute;
    top: 50%; left: 50%;
    transform: translate(-50%, -50%);
    width: 80px; height: 80px;
    background: #fff;
    color: var(--primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    box-shadow: 0 0 0 10px rgba(255,255,255,0.2);
    transition: var(--transition);
}

.video-card:hover .play-btn-circle {
    background: var(--primary);
    color: #fff;
    transform: translate(-50%, -50%) scale(1.1);
    box-shadow: 0 0 0 15px rgba(59, 130, 246, 0.2);
}

.video-card h4 {
    padding: 20px;
    text-align: center;
    margin: 0;
}

/* 5. INFRASTRUCTURE */
.sec-header-split {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    margin-bottom: 4rem;
    gap: 40px;
}

.sec-header-split p {
    max-width: 500px;
    color: var(--text-muted);
}

.infra-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.infra-item {
    position: relative;
    border-radius: 25px;
    overflow: hidden;
}

.infra-item img {
    height: 400px;
    width: 100%;
    object-fit: cover;
    filter: grayscale(0.5);
    transition: var(--transition);
}

.infra-item h3 {
    position: absolute;
    bottom: 30px;
    left: 30px;
    color: #fff;
    margin: 0;
    font-size: 1.5rem;
    z-index: 2;
}

.infra-item::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(2, 6, 23, 0.8), transparent);
}

.infra-item:hover img { filter: grayscale(0); transform: scale(1.05); }

/* 6. LIGHTBOX */
.lightbox {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.95);
    z-index: 3000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
}

.lightbox.active { opacity: 1; visibility: visible; }

.close-lightbox {
    position: absolute;
    top: 30px;
    right: 30px;
    color: #fff;
    font-size: 3rem;
    cursor: pointer;
}

.lightbox-content {
    position: relative;
    max-width: 90%;
    max-height: 80vh;
}

.lightbox-content img {
    max-width: 100%;
    max-height: 80vh;
    border-radius: 10px;
    box-shadow: 0 20px 50px rgba(0,0,0,0.5);
}

.lightbox-caption {
    color: #fff;
    text-align: center;
    margin-top: 20px;
    font-size: 1.25rem;
    font-family: var(--font-body);
}

.nav-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255,255,255,0.1);
    border: none;
    color: #fff;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 1.5rem;
}

.nav-arrow:hover { background: var(--primary); }
.prev { left: -100px; }
.next { right: -100px; }

/* RESPONSIVE */
@media (max-width: 1200px) {
    .prev { left: 20px; }
    .next { right: 20px; }
}

@media (max-width: 992px) {
    .video-grid, .infra-grid {
        grid-template-columns: 1fr;
    }
    .sec-header-split {
        flex-direction: column;
        align-items: flex-start;
        text-align: left;
        gap: 20px;
    }
    .gal-hero-content h1 {
        font-size: 3rem;
    }
}

@media (max-width: 768px) {
    .gal-hero {
        height: 50vh;
    }
    .gal-filters {
        gap: 10px;
        margin-bottom: 3rem;
    }
    .gal-filter-btn {
        padding: 8px 18px;
        font-size: 0.9rem;
    }
    .vid-thumb {
        height: 250px;
    }
    .lightbox-content {
        max-width: 95%;
    }
    .nav-arrow {
        width: 50px;
        height: 50px;
        font-size: 1.2rem;
    }
    .prev { left: 10px; }
    .next { right: 10px; }
}

@media (max-width: 480px) {
    .gal-grid {
        grid-template-columns: 1fr;
    }
    .infra-item img {
        height: 300px;
    }
}

/* =========================================
   COMPREHENSIVE RESPONSIVE STYLES
   ========================================= */

/* Large Tablets & Small Desktops (max-width: 1024px) */
@media (max-width: 1024px) {
    .gal-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 20px;
    }

    .gallery-hero-content h1 {
        font-size: clamp(2rem, 4vw, 3rem);
    }

    .gallery-filters {
        flex-wrap: wrap;
        justify-content: center;
    }

    .filter-btn {
        margin: 5px;
    }
}

/* Medium Tablets (max-width: 768px) */
@media (max-width: 768px) {
    .gal-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .gallery-hero {
        height: 400px;
    }

    .gallery-hero-content h1 {
        font-size: 2rem;
    }

    .section-padding {
        padding: 3rem 0;
    }

    .lightbox-content {
        max-height: 70vh;
    }
}

/* Small Mobile Devices (max-width: 600px) */
@media (max-width: 600px) {
    .gal-grid {
        grid-template-columns: 1fr;
    }

    .gallery-hero {
        height: 350px;
    }

    .gallery-hero-content h1 {
        font-size: 1.8rem;
    }

    .gallery-hero-content p {
        font-size: 0.9rem;
    }

    .card {
        padding: 20px;
    }

    .card-title {
        font-size: 1.2rem;
    }

    .btn {
        padding: 12px 20px;
        font-size: 0.9rem;
    }

    .footer {
        padding: 60px 0 20px;
    }

    .footer-col h3 {
        font-size: 1.1rem;
    }

    .lightbox-content {
        max-height: 60vh;
    }

    .thumb {
        width: 70px;
        height: 50px;
    }
}

/* Extra Small Devices (max-width: 480px) */
@media (max-width: 480px) {
    .gallery-hero-content h1 {
        font-size: 1.5rem;
    }

    .gallery-main-slider {
        height: 250px;
    }

    .thumb {
        width: 60px;
        height: 40px;
    }
}
