/* ===== Gallery Specific Styles ===== */

/* Page Header Styling */
.page-header {
    position: relative;
    height: 40vh;
    min-height: 300px;
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: #fff;
    margin-bottom: 2rem;
}

.page-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 1;
}

.page-header .container {
    position: relative;
    z-index: 2;
}

.page-header h1 {
    font-family: 'Playfair Display', serif;
    font-size: 3.5rem;
    margin-bottom: 1rem;
    animation: fadeInUp 1s ease;
}

.page-header p {
    font-family: 'Open Sans', sans-serif;
    font-size: 1.2rem;
    max-width: 600px;
    margin: 0 auto;
    animation: fadeInUp 1.2s ease;
}

/* Gallery Filter Styles */
.gallery-filter {
    margin-bottom: 2rem;
}

.filter-controls {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 2rem;
}



/* Gallery Grid Styles - MODIFIED FOR 4 IMAGES PER ROW */
.gallery-container {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.5rem;
    padding: 1rem 0;
    width: 100%;
    animation: fadeIn 0.6s ease;
}

.gallery-item {
    position: relative;
    overflow: hidden;
    border-radius: 5px;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.1);
    transition: transform 0.4s ease, box-shadow 0.4s ease;
    cursor: pointer;
    animation: fadeIn 0.6s ease;
}

.gallery-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 15px rgba(0, 0, 0, 0.15);
}

.gallery-image {
    position: relative;
    overflow: hidden;
    padding-top: 75%; /* 4:3 Aspect Ratio */
    background-color: #f0f0f0;
}

.gallery-image img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.gallery-item:hover .gallery-image img {
    transform: scale(1.05);
}

.image-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(transparent, rgba(0, 0, 0, 0.8));
    color: #fff;
    opacity: 0;
    transition: opacity 0.3s ease;
    padding: 1.5rem;
    display: flex;
    align-items: flex-end;
    height: 100%;
}

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

.overlay-content {
    width: 100%;
    transform: translateY(20px);
    transition: transform 0.4s ease;
}

.gallery-item:hover .overlay-content {
    transform: translateY(0);
}

.overlay-content h3 {
    margin: 0 0 0.5rem;
    font-family: 'Playfair Display', serif;
    font-size: 1.3rem;
}

.overlay-content p {
    margin: 0 0 1rem;
    font-family: 'Open Sans', sans-serif;
    font-size: 0.9rem;
    opacity: 0.9;
}

.btn-view {
    background: none;
    border: 1px solid #fff;
    color: #fff;
    padding: 0.5rem 1rem;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.8rem;
    cursor: pointer;
    transition: all 0.3s ease;
    border-radius: 3px;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.btn-view:hover {
    background-color: #fff;
    color: #000;
}

/* Load More Button Styles */
.load-more-container {
    display: flex;
    justify-content: center;
    margin: 2rem 0;
}

/* Modal Styles */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.9);
    z-index: 1000;
    overflow: hidden;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.modal.show {
    display: block;
    opacity: 1;
}

.modal-content {
    position: relative;
    width: 80%;
    max-width: 1200px;
    margin: 2% auto;
    height: 90vh;
    display: flex;
    flex-direction: column;
    background-color: #000;
    border-radius: 5px;
    overflow: hidden;
}

.close-modal {
    position: absolute;
    top: 15px;
    right: 15px;
    color: #fff;
    font-size: 2rem;
    cursor: pointer;
    z-index: 10;
    width: 35px;
    height: 35px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: rgba(0, 0, 0, 0.5);
    border-radius: 50%;
    transition: all 0.3s ease;
}

.close-modal:hover {
    background-color: rgba(255, 255, 255, 0.2);
}

#modal-image {
    max-height: 70vh;
    width: 100%;
    object-fit: contain;
    flex: 1;
}

.modal-info {
    padding: 1.5rem;
    background-color: #111;
    color: #fff;
}

.modal-info h3 {
    font-family: 'Playfair Display', serif;
    font-size: 1.5rem;
    margin: 0 0 0.5rem;
}

.modal-info p {
    font-family: 'Open Sans', sans-serif;
    font-size: 1rem;
    margin: 0;
    opacity: 0.9;
}

.modal-nav {
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    transform: translateY(-50%);
    display: flex;
    justify-content: space-between;
    padding: 0 1rem;
    pointer-events: none;
}

.nav-btn {
    background-color: rgba(0, 0, 0, 0.5);
    color: #fff;
    border: none;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    pointer-events: auto;
    font-size: 1.2rem;
}

.nav-btn:hover {
    background-color: rgba(255, 255, 255, 0.2);
}

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

/* Dark Theme Adjustments */
body.dark-theme .gallery-item {
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.3);
}

body.dark-theme .gallery-image {
    background-color: #333;
}

body.dark-theme .gallery-nav-btn {
    background-color: #333;
    color: #fff;
}

body.dark-theme .gallery-nav-btn:hover {
    background-color: #444;
}

body.dark-theme .modal-content {
    background-color: #1a1a1a;
}

body.dark-theme .modal-info {
    background-color: #222;
}
.close-modal-btn {
    position: absolute;
    top: 15px;
    right: 15px;
    width: 40px;
    height: 40px;
    background-color: rgba(0, 0, 0, 0.6);
    border: none;
    border-radius: 50%;
    color: white;
    font-size: 1.2rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 20;
    transition: all 0.3s ease;
}

.close-modal-btn:hover {
    background-color: #E0A800;
    transform: scale(1.1);
}
/* Responsive Styles */
@media (max-width: 1200px) {
    .gallery-container {
        grid-template-columns: repeat(3, 1fr);
    }
}

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

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