/* Variables */
:root {
    --font-heading: 'Playfair Display', serif;
    --font-body: 'Lato', sans-serif;
    --spacing-sm: 0.3rem;
    --spacing-md: 1rem;
    --spacing-lg: 2rem;
    --spacing-xl: 4rem;
}

@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:wght@400;700&family=Lato:wght@300;400;700&display=swap');

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    display: flex;
    flex-direction: column;
    font-family: var(--font-body);
    line-height: 1.6;
    background-color: #fdeed6;
    min-height: 100vh;
}

a {
    text-decoration: none;
    color: inherit;
}

/* Header */
header {
    background-color: rgb(253, 253, 252);
    padding: var(--spacing-md);
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(8px);
    color: #b78261;
    display: flex;
    justify-content: space-between;
    align-items: center;
}


header h3 {
    font-family: var(--font-heading);
    font-size: 1.2rem;
    margin-left: 5%;
}



nav  {
    display: flex;
    justify-content: center;
    gap: var(--spacing-lg);
    list-style: none;
    margin-right: 8%;
}

nav a {
    color: #b78261;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
    cursor: pointer;
}

nav a:hover {
    color: #b35209;
}

/* Main Content */
main {
    flex: 1;
    margin-top: 80px;
    padding: 2rem;
}

h1 {
    font-family: var(--font-heading);
    font-size: 4rem;
    font-weight: bold;
    color: #77350f;
    text-align: center;
    margin-bottom: 3rem;
}

/* Gallery Categories */
.gallery-category {
    margin-bottom: 4rem;
}

.gallery-category h2 {
    font-family: var(--font-heading);
    font-size: 2.2rem;
    color: #b35209;
    text-align: center;
    margin-bottom: 2rem;
    padding: 1rem;
    background: linear-gradient(135deg, #fdf7ea, #fbf5e8);
    border-radius: 15px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

/* Gallery Grid */
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.gallery-item {
    position: relative;
    aspect-ratio: 4/3;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
    transition: all 0.3s ease;
    cursor: pointer;
    background: #f8f8f8;
}

.gallery-item:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.25);
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

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

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

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

.overlay-text {
    color: white;
    font-size: 1.1rem;
    font-weight: 500;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.5);
}

/* Placeholder for missing images */
.gallery-item.placeholder {
    background: linear-gradient(135deg, #f0f0f0, #e8e8e8);
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px dashed #ccc;
}

.placeholder-text {
    color: #999;
    font-size: 1.1rem;
    text-align: center;
    padding: 1rem;
}

/* Modal/Lightbox */
.modal {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.9);
    backdrop-filter: blur(5px);
}

.modal-content {
    position: relative;
    max-width: 90%;
    max-height: 90%;
    margin: auto;
    top: 50%;
    transform: translateY(-50%);
    animation: modalFadeIn 0.3s ease-out;
}

.modal-content img {
    max-width: 100%;
    max-height: 90vh;
    width: auto;
    height: auto;
    border-radius: 10px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    display: block;
    margin: 0 auto;
    object-fit: contain;
}

.modal-close {
    position: absolute;
    top: -50px;
    right: 0;
    color: white;
    font-size: 2.5rem;
    font-weight: bold;
    cursor: pointer;
    background: rgba(0, 0, 0, 0.5);
    border-radius: 50%;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

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

.modal-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0, 0, 0, 0.5);
    color: white;
    border: none;
    font-size: 2rem;
    padding: 10px 15px;
    cursor: pointer;
    border-radius: 5px;
    transition: all 0.3s ease;
}

.modal-nav:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-50%) scale(1.1);
}

.modal-prev {
    left: 20px;
}

.modal-next {
    right: 20px;
}

.modal-info {
    position: absolute;
    bottom: -60px;
    left: 0;
    right: 0;
    text-align: center;
    color: white;
    font-size: 1.2rem;
    background: rgba(0, 0, 0, 0.5);
    padding: 10px;
    border-radius: 5px;
}

@keyframes modalFadeIn {
    from { opacity: 0; transform: translateY(-50%) scale(0.8); }
    to { opacity: 1; transform: translateY(-50%) scale(1); }
}

/* Footer */
footer {
    background-color: #77350f;
    padding: 20px;
    color: #fbe489;
    text-align: center;
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-top: auto;
}

footer h4 {
    color: white;
}

footer p {
    margin-bottom: var(--spacing-sm);
}

.Bebaz {
    color: rgba(251, 228, 137, 0.21);
    font-weight: 600;
    scale: 0.8;
}

footer a {
    color: rgba(251, 228, 137, 0.21);
    text-decoration: none;
    transition: color 0.3s ease;
}

/* Estilos para navegação das categorias */
.category-nav {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin: 2rem 0 3rem 0;
    flex-wrap: wrap;
}

.category-nav a {
    background: linear-gradient(135deg, #b78261, #b35209);
    color: white;
    padding: 12px 24px;
    border-radius: 25px;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(183, 130, 97, 0.3);
}

.category-nav a:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(183, 130, 97, 0.4);
    background: linear-gradient(135deg, #b35209, #77350f);
}

@media (max-width: 1080px) {
    header {
        flex-direction: row;
        padding: 1rem;
        text-align: center;
    }

    header h3 {
        margin-left: 0;
        margin-bottom: 1rem;
    }

    /* Beautiful mobile navigation for gallery page */
    nav {
        margin-right: 0;
        display: flex;
    }

    nav li{
        list-style: none;
    }

    /* Style the home button to look amazing on mobile */
    nav a {
        background: linear-gradient(135deg, #b78261, #b35209);
        color: white !important;
        padding: 10px 20px;
        border-radius: 25px;
        font-weight: 600;
        font-size: 0.8rem;
        box-shadow: 0 4px 15px rgba(183, 130, 97, 0.3);
        transition: all 0.3s ease;
        text-transform: uppercase;
        letter-spacing: 0.5px;
        border: 2px solid transparent;
    }

    nav a:hover {
        transform: translateY(-2px);
        box-shadow: 0 6px 20px rgba(183, 130, 97, 0.4);
        background: linear-gradient(135deg, #b35209, #77350f);
        border-color: rgba(255, 255, 255, 0.2);
    }

    nav a:active {
        transform: translateY(0);
        box-shadow: 0 2px 10px rgba(183, 130, 97, 0.3);
    }

    main {
        margin-top: 140px; /* Increased to accommodate larger header */
        padding: 1rem;
    }

    h1 {
        font-size: 2.5rem;
    }

    .gallery-category h2 {
        font-size: 1.8rem;
    }

    .gallery-grid {
        grid-template-columns: repeat(1, minmax(250px, 1fr));
        gap: 1rem;
    }

    .modal-nav {
        font-size: 1.5rem;
        padding: 8px 12px;
    }

    .modal-prev {
        left: 10px;
    }

    .modal-next {
        right: 10px;
    }

    .category-nav {
        gap: 1rem;
        margin: 1.5rem 0;
    }

    .category-nav a {
        padding: 10px 20px;
        font-size: 0.9rem;
    }
}