/* =============================================
   GALLERY PAGE STYLES - COMPREHENSIVE DESIGN
   ============================================= */

:root {
    --primary-dark: #1a3948;
    --secondary-dark: #0f2128;
    --accent-orange: #f59834;
    --sage-green: #a1b27e;
    --sage-dark: #92a574;
    --light-bg: #f1e6c7;
    --white: #ffffff;
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.1);
    --shadow-md: 0 4px 15px rgba(0, 0, 0, 0.15);
    --shadow-lg: 0 8px 25px rgba(0, 0, 0, 0.2);
}

/* ===================== PAGE HEADER ===================== */

.page-header {
    background: linear-gradient(135deg, var(--primary-dark) 0%, var(--secondary-dark) 100%);
    color: var(--white);
    padding: 100px 0;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.page-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at 20% 50%, rgba(161, 178, 126, 0.1) 0%, transparent 50%);
    pointer-events: none;
}

.page-header h1 {
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
    position: relative;
    z-index: 1;
}

.page-header p {
    font-size: 1.3rem;
    color: rgba(255, 255, 255, 0.85);
    max-width: 600px;
    margin: 0 auto;
    position: relative;
    z-index: 1;
}

/* ===================== SECTION HEADING ===================== */

.section-heading {
    text-align: center;
    font-size: 2.5rem;
    color: var(--primary-dark);
    margin-bottom: 60px;
    font-weight: 700;
    position: relative;
}

.section-heading::after {
    content: '';
    display: block;
    width: 60px;
    height: 4px;
    background: var(--accent-orange);
    margin: 15px auto 0;
    border-radius: 2px;
}

/* ===================== GALLERY FILTER SECTION ===================== */

.gallery-filter-section {
    padding: 50px 0;
    background: var(--light-bg);
}

.filter-controls {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
    max-width: 900px;
    margin: 0 auto;
}

.filter-btn {
    padding: 0.8rem 1.8rem;
    border: 2px solid var(--primary-dark);
    background: var(--white);
    color: var(--primary-dark);
    border-radius: 50px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    font-size: 0.95rem;
}

.filter-btn:hover {
    background: var(--primary-dark);
    color: var(--white);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.filter-btn.active {
    background: var(--accent-orange);
    border-color: var(--accent-orange);
    color: var(--white);
}

/* ===================== GALLERY GRID ===================== */

.gallery-section {
    padding: 80px 0;
    background: var(--white);
}

.gallery-section:nth-child(even) {
    background: var(--light-bg);
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 2.5rem;
    max-width: 1400px;
    margin: 0 auto;
}

/* ===================== GALLERY ITEM ===================== */

.gallery-item {
    position: relative;
    overflow: hidden;
    border-radius: 12px;
    box-shadow: var(--shadow-md);
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    aspect-ratio: 1 / 1;
    width: 100%;
}

.gallery-item:hover {
    box-shadow: var(--shadow-lg);
}

.gallery-image-wrapper {
    position: relative;
    width: 100%;
    height: 100%;
    overflow: hidden;
    background: #f0ebe1;
}

.gallery-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.gallery-item:hover .gallery-image {
    transform: scale(1.1) rotate(2deg);
}

.gallery-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(26, 57, 72, 0.9) 0%, rgba(15, 33, 40, 0.95) 100%);
    display: flex;
    align-items: flex-end;
    padding: 2rem;
    transform: translateY(100%);
    transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.gallery-item:hover .gallery-overlay {
    transform: translateY(0);
}

.overlay-content {
    width: 100%;
}

.overlay-content h3 {
    color: var(--accent-orange);
    font-size: 1.3rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.overlay-content p {
    color: rgba(255, 255, 255, 0.85);
    font-size: 0.9rem;
    line-height: 1.6;
}

/* ===================== GALLERY ITEM BORDER ACCENTS ===================== */

.gallery-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(90deg, var(--accent-orange), var(--sage-green), var(--accent-orange));
    opacity: 0;
    transition: opacity 0.3s ease;
    z-index: 10;
}

.gallery-item:hover::before {
    opacity: 1;
}

/* ===================== CALL TO ACTION SECTION ===================== */

.cta-section {
    padding: 80px 0;
    background: linear-gradient(135deg, var(--primary-dark) 0%, var(--secondary-dark) 100%);
    text-align: center;
    position: relative;
    overflow: hidden;
}

.cta-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at 30% 50%, rgba(161, 178, 126, 0.15) 0%, transparent 50%),
                radial-gradient(circle at 70% 50%, rgba(245, 152, 52, 0.1) 0%, transparent 50%);
    pointer-events: none;
}

.cta-section .container {
    position: relative;
    z-index: 1;
}

.cta-section h2 {
    font-size: 3rem;
    color: var(--white);
    margin-bottom: 1rem;
    font-weight: 700;
}

.cta-section p {
    font-size: 1.2rem;
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 2.5rem;
}

.cta-buttons {
    display: flex;
    gap: 2rem;
    justify-content: center;
    flex-wrap: wrap;
}

.btn {
    padding: 1rem 2.5rem;
    font-size: 1rem;
    font-weight: 600;
    border-radius: 50px;
    text-decoration: none;
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    cursor: pointer;
    border: 2px solid transparent;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.btn-primary {
    background: var(--accent-orange);
    color: var(--white);
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(245, 152, 52, 0.3);
    background: #ff9d4d;
}

.btn-secondary {
    background: transparent;
    color: var(--accent-orange);
    border: 2px solid var(--accent-orange);
}

.btn-secondary:hover {
    background: var(--accent-orange);
    color: var(--white);
    transform: translateY(-3px);
}

/* ===================== FOOTER ===================== */

.footer {
    background: var(--primary-dark);
    color: rgba(255, 255, 255, 0.8);
    padding: 50px 0 30px;
    border-top: 3px solid var(--accent-orange);
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 3rem;
    margin-bottom: 3rem;
}

.footer-section h4 {
    color: var(--white);
    margin-bottom: 1.5rem;
    font-size: 1.1rem;
    font-weight: 700;
}

.footer-section h3.footer-title {
    color: var(--white);
    margin-bottom: 1.5rem;
    font-size: 1.1rem;
    font-weight: 700;
}

.footer-section p {
    line-height: 1.7;
    margin-bottom: 1rem;
}

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    margin-bottom: 0.8rem;
}

.footer-section a {
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    transition: color 0.3s ease;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.footer-section a:hover {
    color: var(--accent-orange);
}

.footer-logo-wrapper {
    margin-bottom: 1rem;
}

.footer-logo {
    height: 80px;
    width: auto;
    transition: all 0.3s ease;
}

.footer-text {
    color: rgba(255, 255, 255, 0.7);
    line-height: 1.7;
}

.footer-contact {
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
}

.footer-contact p {
    margin: 0;
    color: rgba(255, 255, 255, 0.7);
    display: flex;
    align-items: center;
    gap: 0.8rem;
}

.footer-contact i {
    color: var(--accent-orange);
    width: 20px;
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 2rem;
    text-align: center;
}

.footer-copyright {
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.9rem;
}

/* ===================== RESPONSIVE DESIGN ===================== */

@media (max-width: 1024px) {
    .gallery-grid {
        grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
        gap: 2rem;
    }
}

@media (max-width: 768px) {
    .page-header {
        padding: 60px 0;
    }

    .page-header h1 {
        font-size: 2.5rem;
    }

    .section-heading {
        font-size: 2rem;
        margin-bottom: 40px;
    }

    .gallery-grid {
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
        gap: 1.5rem;
    }

    .filter-controls {
        gap: 0.8rem;
    }

    .filter-btn {
        padding: 0.6rem 1.2rem;
        font-size: 0.85rem;
    }

    .cta-section h2 {
        font-size: 2rem;
    }

    .cta-buttons {
        gap: 1rem;
    }

    .btn {
        padding: 0.8rem 1.5rem;
        font-size: 0.9rem;
    }

    .footer-content {
        grid-template-columns: 1fr;
        gap: 2rem;
        margin-bottom: 2rem;
    }

    .footer-section h4 {
        font-size: 1rem;
        margin-bottom: 1rem;
        border-bottom: 2px solid var(--accent-orange);
        padding-bottom: 0.5rem;
    }

    .footer-section p,
    .footer-section ul li {
        font-size: 0.9rem;
    }

    .footer-social {
        gap: 1rem;
    }

    .footer-bottom {
        padding-top: 1.5rem;
        margin-top: 1.5rem;
    }

    .footer-copyright {
        font-size: 0.8rem;
    }
}

@media (max-width: 480px) {
    .page-header {
        padding: 50px 0;
    }

    .page-header h1 {
        font-size: 2rem;
    }

    .page-header p {
        font-size: 1rem;
    }

    .section-heading {
        font-size: 1.5rem;
        margin-bottom: 30px;
    }

    .gallery-grid {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
        gap: 1rem;
    }

    .gallery-item {
        aspect-ratio: 1;
    }

    .gallery-overlay {
        padding: 1.5rem 1rem;
    }

    .overlay-content h3 {
        font-size: 1rem;
    }

    .overlay-content p {
        font-size: 0.8rem;
    }

    .filter-controls {
        flex-direction: column;
        gap: 0.6rem;
    }

    .filter-btn {
        width: 100%;
        padding: 0.7rem 1rem;
    }

    .cta-section {
        padding: 50px 0;
    }

    .cta-section h2 {
        font-size: 1.5rem;
    }

    .cta-section p {
        font-size: 1rem;
    }

    .cta-buttons {
        flex-direction: column;
        gap: 1rem;
    }

    .btn {
        width: 100%;
        padding: 0.8rem 1rem;
        font-size: 0.9rem;
    }

    .footer-content {
        gap: 1.5rem;
        margin-bottom: 1.5rem;
    }

    .footer {
        padding: 40px 12px 20px;
    }

    .footer-section h4 {
        font-size: 0.95rem;
        margin-bottom: 0.8rem;
        text-align: center;
        border-bottom: 2px solid var(--accent-orange);
        padding-bottom: 0.4rem;
    }

    .footer-section p,
    .footer-section ul li,
    .footer-section a {
        font-size: 0.85rem;
        text-align: center;
    }

    .footer-section ul {
        display: flex;
        flex-direction: column;
        align-items: center;
    }

    .footer-social {
        justify-content: center;
        gap: 0.8rem;
    }

    .footer-social a {
        width: 38px;
        height: 38px;
        font-size: 0.9rem;
    }

    .footer-bottom {
        padding-top: 1.2rem;
        margin-top: 1.2rem;
    }

    .footer-copyright {
        font-size: 0.75rem;
        line-height: 1.3;
    }

    .footer-tagline {
        font-size: 0.85rem;
    }
}

/* ===================== GALLERY ANIMATION ENHANCEMENTS ===================== */

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

.gallery-item {
    animation: fadeIn 0.6s ease-out;
}

.gallery-item:nth-child(1) { animation-delay: 0.05s; }
.gallery-item:nth-child(2) { animation-delay: 0.1s; }
.gallery-item:nth-child(3) { animation-delay: 0.15s; }
.gallery-item:nth-child(4) { animation-delay: 0.2s; }
.gallery-item:nth-child(5) { animation-delay: 0.25s; }
.gallery-item:nth-child(6) { animation-delay: 0.3s; }
/* ===================== FILTER VISIBILITY STYLES ===================== */

.gallery-item {
    position: relative;
    overflow: hidden;
    border-radius: 12px;
    box-shadow: var(--shadow-md);
    transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
    aspect-ratio: 1 / 1;
    width: 100%;
    display: block !important;
    opacity: 1 !important;
}

.gallery-item.hidden {
    display: none !important;
    opacity: 0;
}

.gallery-item.visible {
    display: block !important;
    opacity: 1;
    animation: fadeIn 0.4s ease-out;
}
