/* ===================================================
   ART GALLERY – Styles
   =================================================== */

/* Nav active state */
.nav-active {
    text-decoration: underline !important;
    text-underline-offset: 4px;
}

/* Header divider line (matches other pages) */
.header-divider {
    width: 100%;
    height: 2px;
    background-color: #df4e8b;
    margin-top: 20px;
}

/* ===== PAGE LAYOUT ===== */
.gallery-main {
    max-width: 1100px;
    margin: 0 auto;
    padding: 50px 20px 60px;
}

/* ===== TITLE ===== */
.gallery-title {
    font-size: 2.4rem;
    font-weight: 800;
    text-align: center;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--text-dark);
    margin-bottom: 32px;
}

/* ===== GALLERY GRID ===== */
.gallery-grid-section {
    width: 100%;
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
}

/* ===== GALLERY ITEM ===== */
.gallery-item {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    animation: fadeInUp 0.4s ease both;
}

.gallery-item.hidden {
    display: none;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(16px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Image wrapper */
.gallery-img-wrap {
    position: relative;
    width: 100%;
    aspect-ratio: 1 / 1;
    border-radius: 20px;
    overflow: hidden;
    background-color: #f5f5f5;
    cursor: pointer;
}

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

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

/* Overlay on hover */
.gallery-overlay {
    position: absolute;
    inset: 0;
    background: rgba(223, 78, 139, 0.45);
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.gallery-img-wrap:hover .gallery-overlay {
    opacity: 1;
}

.gallery-zoom-btn {
    background: rgba(255, 255, 255, 0.9);
    border: none;
    border-radius: 50%;
    width: 54px;
    height: 54px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: var(--text-dark);
    transition: transform 0.2s ease, background-color 0.2s ease;
}

.gallery-zoom-btn:hover {
    transform: scale(1.15);
    background-color: #ffffff;
}

/* Label below image */
.gallery-label {
    margin-top: 10px;
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-dark);
    padding-left: 4px;
}

/* ===== LIGHTBOX ===== */
.lightbox-overlay {
    position: fixed;
    inset: 0;
    background: rgba(18, 18, 18, 0.92);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 24px;
    padding: 20px;
    animation: fadeIn 0.25s ease;
}

.lightbox-overlay[hidden] {
    display: none;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.lightbox-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
    max-width: 700px;
    width: 100%;
}

.lightbox-img {
    max-width: 100%;
    max-height: 75vh;
    border-radius: 20px;
    object-fit: contain;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    animation: zoomIn 0.3s ease;
}

@keyframes zoomIn {
    from { transform: scale(0.9); opacity: 0; }
    to { transform: scale(1); opacity: 1; }
}

.lightbox-caption {
    font-size: 1.2rem;
    font-weight: 700;
    color: #ffffff;
    text-align: center;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.lightbox-close {
    position: fixed;
    top: 20px;
    right: 24px;
    background: rgba(255, 255, 255, 0.15);
    border: none;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: #ffffff;
    transition: background-color 0.2s ease, transform 0.2s ease;
    z-index: 1001;
}

.lightbox-close:hover {
    background-color: rgba(255, 255, 255, 0.3);
    transform: rotate(90deg);
}

.lightbox-nav {
    background: rgba(255, 255, 255, 0.15);
    border: none;
    border-radius: 50%;
    width: 54px;
    height: 54px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: #ffffff;
    transition: background-color 0.2s ease, transform 0.15s ease;
    flex-shrink: 0;
}

.lightbox-nav:hover {
    background-color: rgba(255, 255, 255, 0.3);
    transform: scale(1.1);
}

/* ===== RESPONSIVE ===== */
@media (max-width: 900px) {
    .gallery-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 768px) {
    .gallery-main {
        margin: 20px auto 40px;
        padding: 0 15px;
    }

    .gallery-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 16px;
    }

    .gallery-title {
        font-size: 1.8rem;
        margin-bottom: 24px;
    }

    .lightbox-nav {
        width: 42px;
        height: 42px;
    }
}
