/* ==========================
   Gallery Page Styles
   ========================== */

.page-content-section {
    padding: 60px 0;
    background: #fff;
}

/* --- Filter Controls --- */
.gallery-controls {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    justify-content: center;
    margin-bottom: 36px;
}

.gallery-filter {
    padding: 10px 22px;
    border: 2px solid #6dbfe8;
    background: transparent;
    color: #1a3a5c;
    border-radius: 30px;
    font-family: 'Raleway', sans-serif;
    font-weight: 600;
    font-size: 0.92rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.gallery-filter:hover,
.gallery-filter.active {
    background: #6dbfe8;
    color: #fff;
}

/* --- Gallery Grid --- */
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 18px;
}

.gallery-item {
    border-radius: 8px;
    overflow: hidden;
    transition: transform 0.3s ease;
}

.gallery-item:hover {
    transform: translateY(-4px);
}

.gallery-link {
    display: block;
    text-decoration: none;
}

.gallery-thumb {
    position: relative;
    overflow: hidden;
    aspect-ratio: 1 / 1;
    background: #f0f0f0;
}

.gallery-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.4s ease;
}

.gallery-item:hover .gallery-thumb img {
    transform: scale(1.06);
}

.gallery-overlay {
    position: absolute;
    inset: 0;
    background: rgba(26, 58, 92, 0.75);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.35s ease;
    padding: 16px;
    text-align: center;
}

.gallery-item:hover .gallery-overlay {
    opacity: 1;
}

.gallery-zoom {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: 2px solid #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 1.1rem;
    margin-bottom: 10px;
    transition: background 0.2s;
}

.gallery-item:hover .gallery-zoom {
    background: #6dbfe8;
    border-color: #6dbfe8;
}

.gallery-item-title {
    color: #fff;
    font-size: 0.88rem;
    font-weight: 600;
    margin: 0;
    line-height: 1.4;
}

/* --- Lightbox --- */
.gallery-lightbox {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 9999;
    align-items: center;
    justify-content: center;
}

.gallery-lightbox.active {
    display: flex;
}

.lightbox-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.88);
}

.lightbox-box {
    position: relative;
    z-index: 10000;
    max-width: 90vw;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.lightbox-img {
    max-width: 90vw;
    max-height: 80vh;
    object-fit: contain;
    border-radius: 4px;
    box-shadow: 0 8px 40px rgba(0,0,0,0.5);
}

.lightbox-caption {
    color: #fff;
    margin-top: 14px;
    font-size: 0.95rem;
    text-align: center;
}

.lightbox-close,
.lightbox-prev,
.lightbox-next {
    position: absolute;
    background: rgba(109, 191, 232, 0.85);
    border: none;
    color: #fff;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    font-size: 1rem;
}

.lightbox-close { top: -50px; right: 0; }
.lightbox-prev  { left: -54px; top: 50%; transform: translateY(-50%); }
.lightbox-next  { right: -54px; top: 50%; transform: translateY(-50%); }

.lightbox-close:hover,
.lightbox-prev:hover,
.lightbox-next:hover {
    background: #1a3a5c;
}

@media (max-width: 900px) {
    .gallery-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .lightbox-prev { left: 4px; }
    .lightbox-next { right: 4px; }
}

@media (max-width: 480px) {
    .gallery-grid {
        grid-template-columns: 1fr;
    }

    .page-content-section { padding: 32px 0; }
}