
@font-face {
    font-family: 'Waldorf_PC';
    src: url('/font/Waldorf_PC TrueType/WALDA___.TTF') format('truetype');
    font-weight: normal;
    font-style: normal;
}

.gallery-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem;
}

.gallery-header {
    text-align: center;
    margin-bottom: 3rem;
}

.gallery-title {
    font-size: 2.5rem;
    font-weight: 700;
    color: #86b472;
    margin-bottom: 1rem;
    font-family: 'Waldorf_PC', sans-serif;
}

.gallery-description {
    font-size: 1.125rem;
    color: hsl(20, 15%, 50%);
    max-width: 600px;
    margin: 0 auto;
    line-height: 1.6;
}


.breadcrumb {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 2rem;
    padding: 1rem 2rem;
    font-size: 0.875rem;
    color: hsl(20, 15%, 50%);
}

.breadcrumb a {
    color: hsl(115, 25%, 65%);
    text-decoration: none;
    transition: color 0.15s ease;
}

.breadcrumb a:hover {
    color: hsl(115, 25%, 55%);
}

.breadcrumb-separator {
    color: hsl(20, 15%, 50%);
    margin: 0 0.25rem;
}


.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.5rem;
    margin-bottom: 3rem;
}

@media (max-width: 768px) {
    .gallery-grid {
        grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
        gap: 1rem;
    }
}

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


.gallery-item {
    position: relative;
    aspect-ratio: 4/3;
    border-radius: 0.75rem;
    overflow: hidden;
    cursor: pointer;
    transition: all 0.3s ease;
    background: hsl(45, 50%, 90%);
    border: 1px solid hsl(30, 20%, 75%);
}

.gallery-item:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

.gallery-item:focus {
    outline: 2px solid hsl(115, 25%, 65%);
    outline-offset: 2px;
}

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

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


.gallery-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(
        to top,
        rgba(0, 0, 0, 0.8) 0%,
        rgba(0, 0, 0, 0.4) 50%,
        transparent 100%
    );
    padding: 1rem;
    opacity: 0;
    transition: opacity 0.3s ease;
}

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

.gallery-overlay-text {
    color: white;
    font-size: 0.875rem;
    font-weight: 500;
    text-align: center;
}


.gallery-image {
    position: relative;
    overflow: hidden;
    border-radius: 0.75rem;
    transition: all 0.3s ease;
}

.gallery-image:hover {
    transform: translateY(-2px);
}

.gallery-image .image-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to bottom,
        transparent 0%,
        rgba(0, 0, 0, 0.6) 100%
    );
    display: flex;
    align-items: flex-end;
    padding: 1rem;
    opacity: 0;
    transition: opacity 0.3s ease;
}

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


.pswp {
    --pswp-bg: rgba(0, 0, 0, 0.9);
    --pswp-placeholder-bg: hsl(60, 45%, 88%);
}

.pswp__button {
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: 0.375rem;
    transition: background-color 0.15s ease;
}

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

.pswp__counter {
    background-color: rgba(0, 0, 0, 0.5);
    border-radius: 1rem;
    padding: 0.5rem 1rem;
    font-size: 0.875rem;
}


.gallery-loading {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 200px;
    color: hsl(20, 15%, 50%);
}

.gallery-loading::after {
    content: '';
    width: 2rem;
    height: 2rem;
    border: 2px solid hsl(30, 20%, 75%);
    border-top: 2px solid hsl(115, 25%, 65%);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}


.gallery-empty {
    text-align: center;
    padding: 3rem;
    color: hsl(20, 15%, 50%);
}

.gallery-empty h3 {
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
    color: hsl(20, 26%, 40%);
}


@media (max-width: 768px) {
    .gallery-container {
        padding: 1rem;
    }
    
    .gallery-title {
        font-size: 2rem;
    }
    
    .gallery-description {
        font-size: 1rem;
    }
    
    .breadcrumb {
        padding: 0.5rem 1rem;
    }
}


.gallery-item {
    
    opacity: 1;
    
}

.gallery-item:nth-child(1) { animation-delay: 0.1s; }
.gallery-item:nth-child(2) { animation-delay: 0.2s; }
.gallery-item:nth-child(3) { animation-delay: 0.3s; }
.gallery-item:nth-child(4) { animation-delay: 0.4s; }
.gallery-item:nth-child(5) { animation-delay: 0.5s; }
.gallery-item:nth-child(6) { animation-delay: 0.6s; }

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


.custom-lightbox {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.custom-lightbox.active {
    opacity: 1;
    visibility: visible;
}

.custom-lightbox-content {
    position: relative;
    max-width: 90vw;
    max-height: 90vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.custom-lightbox-image {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    border-radius: 0.5rem;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

.custom-lightbox-close {
    position: absolute;
    top: -50px;
    right: -10px;
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: white;
    font-size: 2rem;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    transition: background-color 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10001;
}

.custom-lightbox-close:hover {
    background: rgba(255, 255, 255, 0.3);
}

.custom-lightbox-prev,
.custom-lightbox-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: white;
    font-size: 1.5rem;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    cursor: pointer;
    transition: background-color 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10001;
}

.custom-lightbox-prev {
    left: -70px;
}

.custom-lightbox-next {
    right: -70px;
}

.custom-lightbox-prev:hover,
.custom-lightbox-next:hover {
    background: rgba(255, 255, 255, 0.3);
}

.custom-lightbox-counter {
    position: absolute;
    bottom: -50px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 0, 0, 0.7);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 1rem;
    font-size: 0.875rem;
    white-space: nowrap;
}

@media (max-width: 768px) {
    .custom-lightbox-close {
        top: 20px;
        right: 20px;
        font-size: 1.5rem;
        width: 35px;
        height: 35px;
    }
    
    .custom-lightbox-prev,
    .custom-lightbox-next {
        width: 40px;
        height: 40px;
        font-size: 1.25rem;
    }
    
    .custom-lightbox-prev {
        left: 20px;
    }
    
    .custom-lightbox-next {
        right: 20px;
    }
    
    .custom-lightbox-counter {
        bottom: 20px;
        font-size: 0.75rem;
        padding: 0.375rem 0.75rem;
    }
}
