/* Gallery Page Styles */
.gallery-section {
    padding: 80px 0;
    background-color: #fff;
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 30px;
    padding: 20px 0;
}

.gallery-item {
    position: relative;
    border-radius: 12px;
    overflow: hidden;
    aspect-ratio: 4/3;
    cursor: pointer;
    background-color: #f0f0f0;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.gallery-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
}

.gallery-thumb {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.gallery-item:hover .gallery-thumb {
    transform: scale(1.05);
}

/* Media Icon */
.media-icon {
    position: absolute;
    top: 15px;
    right: 15px;
    width: 35px;
    height: 35px;
    background: rgb(192 255 0);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #000;
    font-size: 14px;
    z-index: 2;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
}

/* Overlay */
.gallery-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.4), transparent);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.gallery-item:hover .gallery-overlay {
    opacity: 1;
}

/* Modal Styles */
.gallery-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.95);
    z-index: 9999;
    justify-content: center;
    align-items: center;
}

.gallery-modal.active {
    display: flex;
}

.modal-container {
    position: relative;
    width: 90%;
    max-width: 1200px;
    height: 80vh;
    display: flex;
    justify-content: center;
    align-items: center;
}

.modal-content-media {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    border-radius: 4px;
    animation: zoomIn 0.3s ease;
}

@keyframes zoomIn {
    from {
        transform: scale(0.9);
        opacity: 0;
    }

    to {
        transform: scale(1);
        opacity: 1;
    }
}

/* Navigation */
.modal-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 20px;
    transition: all 0.3s;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.modal-nav:hover {
    background: var(--primary-color);
    color: #000;
}

.nav-prev {
    left: -70px;
}

.nav-next {
    right: -70px;
}

.modal-close {
    position: absolute;
    top: -50px;
    right: 0;
    color: #fff;
    font-size: 30px;
    cursor: pointer;
    transition: color 0.3s;
}

.modal-close:hover {
    color: var(--primary-color);
}

/* Responsive */
@media (max-width: 1350px) {
    .nav-prev {
        left: 20px;
    }

    .nav-next {
        right: 20px;
    }

    .modal-nav {
        background: rgba(0, 0, 0, 0.5);
    }
}

@media (max-width: 768px) {
    .gallery-section {
        padding: 33px 0;
    }

    .gallery-grid {
        grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
        gap: 15px;
    }

    .modal-container {
        width: 100%;
        height: 60vh;
    }

    .modal-nav {
        width: 40px;
        height: 40px;
        font-size: 16px;
    }
}