.dropdown-/* Gallery Page Styles */

/* Container utility */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Gallery Hero Banner */
.galeria-hero {
    position: relative;
    width: 100%;
    height: 60vh;
    min-height: 400px;
    max-height: 400px;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-top: 60px; /* Kompensacja wysokości navbar */
}

.galeria-hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.hero-bg-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    filter: brightness(0.6) contrast(1.1);
}

.galeria-hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(44, 95, 111, 0.4);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2;
}

.galeria-hero-content {
    text-align: center;
    color: white;
    max-width: 800px;
    padding: 0 20px;
}

.galeria-hero-content h1 {
    font-size: clamp(2.5rem, 5vw, 4rem);
    font-weight: 700;
    margin-bottom: 1rem;
    text-shadow: 0 2px 16px rgba(0,0,0,0.5);
}

.galeria-hero-content p {
    font-size: clamp(1.1rem, 2.5vw, 1.4rem);
    font-weight: 400;
    opacity: 0.95;
    text-shadow: 0 2px 12px rgba(0,0,0,0.4);
    max-width: 600px;
    margin: 0 auto;
}

/* Gallery Section */
.gallery-section {
    padding: 80px 0;
    background: #181c22;
}

.gallery-header {
    text-align: center;
    margin-bottom: 50px;
}
    
.gallery-header h2 {
    font-size: clamp(2rem, 4vw, 2.8rem);
    font-weight: 700;
    color: #4a90a4;
    margin-bottom: 1rem;
}

.gallery-header p {
    font-size: 1.1rem;
    color: #3a5a66;
    max-width: 700px;
    margin: 0 auto;
    line-height: 1.6;
}

/* Gallery Filters */
.gallery-filters {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-bottom: 40px;
    flex-wrap: wrap;
}

.filter-btn {
    background: #fff;
    color: #31989e;
    border: 2px solid #31989e;
    padding: 10px 20px;
    border-radius: 25px;
    font-size: 0.95rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    outline: none;
}

.filter-btn:hover,
.filter-btn.active {
    background: #31989e;
    color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(49, 152, 158, 0.18);
}

/* Gallery Grid */
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 25px;
    margin: 40px;
}

.gallery-item {
    position: relative;
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(49, 152, 158, 0.08);
    transition: all 0.3s ease;
    cursor: pointer;
    height: 280px;
}

.gallery-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 30px rgba(49, 152, 158, 0.18);
}

.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(transparent, rgba(49, 152, 158, 0.85));
    color: #fff;
    padding: 30px 20px 20px;
    transform: translateY(100%);
    transition: transform 0.3s ease;
}

.gallery-item:hover .gallery-overlay {
    transform: translateY(0);
}

.gallery-overlay h3 {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 5px;
    color: #fff;
}

.gallery-overlay p {
    font-size: 0.9rem;
    opacity: 0.95;
    margin: 0;
    color: #eafcff;
}

/* Hidden items for filtering */
.gallery-item.hidden {
    display: none;
}

/* Modal Styles */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(49, 152, 158, 0.95);
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.modal-content {
    position: relative;
    margin: 5% auto;
    padding: 20px;
    max-width: 90%;
    max-height: 90%;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.modal-content img {
    max-width: 100%;
    max-height: 70vh;
    object-fit: contain;
    border-radius: 8px;
    box-shadow: 0 4px 30px rgba(0,0,0,0.5);
}

.modal-info {
    text-align: center;
    color: #fff;
    margin-top: 20px;
}

.modal-info h3 {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 10px;
    color: #4fb3b3;
}

.modal-info p {
    font-size: 1rem;
    opacity: 0.9;
    color: #eafcff;
}

.close {
    position: absolute;
    top: 20px;
    right: 35px;
    color: #fff;
    font-size: 40px;
    font-weight: bold;
    cursor: pointer;
    z-index: 1001;
    transition: color 0.3s ease;
}

.close:hover {
    color: #31989e;
}

/* Responsive Design */
@media (max-width: 768px) {
    .galeria-hero {
        height: 50vh;
        min-height: 300px;
        margin-top: 50px;
    }
    
    .galeria-hero-content h1 {
        font-size: 2.2rem;
    }
    
    .galeria-hero-content p {
        font-size: 1.1rem;
    }
    
    .gallery-section {
        padding: 60px 0;
    }
    
    .gallery-grid {
        grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
        gap: 20px;
    }
    
    .gallery-item {
        height: 220px;
    }
    
    .gallery-filters {
        gap: 10px;
    }
    
    .filter-btn {
        padding: 8px 16px;
        font-size: 0.9rem;
    }
    
    .modal-content {
        margin: 10% auto;
        padding: 15px;
    }
    
    .modal-content img {
        max-height: 60vh;
    }
    
    .close {
        top: 15px;
        right: 25px;
        font-size: 30px;
    }
}

@media (max-width: 480px) {
    .galeria-hero {
        height: 40vh;
        min-height: 250px;
        margin-top: 50px;
    }
    
    .galeria-hero-content h1 {
        font-size: 1.8rem;
    }
    
    .galeria-hero-content p {
        font-size: 1rem;
    }
    
    .container {
        padding: 0 15px;
    }
    
    .gallery-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .gallery-item {
        height: 200px;
    }
    
    .gallery-filters {
        flex-direction: column;
        align-items: center;
    }
    
    .filter-btn {
        width: 200px;
        text-align: center;
    }
    
    .modal-content {
        margin: 15% auto;
        padding: 10px;
    }
    
    .modal-content img {
        max-height: 50vh;
    }
    
    .modal-info h3 {
        font-size: 1.2rem;
    }
    
    .modal-info p {
        font-size: 0.9rem;
    }
}

/* Additional hover effects for better UX */
.gallery-item {
    position: relative;
    overflow: hidden;
}

.gallery-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(45deg, transparent, rgba(44, 95, 111, 0.1));
    opacity: 0;
    transition: opacity 0.3s ease;
    z-index: 1;
}

.gallery-item:hover::before {
    opacity: 1;
}

/* Loading animation for images */
.gallery-item img {
    transition: opacity 0.3s ease;
}

.gallery-item img[loading="lazy"] {
    opacity: 0;
}

.gallery-item img.loaded {
    opacity: 1;
}

/* Smooth transitions for filter changes */
.gallery-item {
    transition: all 0.3s ease, opacity 0.5s ease, transform 0.5s ease;
}

.gallery-item.fade-out {
    opacity: 0;
    transform: scale(0.8);
}

.gallery-item.fade-in {
    opacity: 1;
    transform: scale(1);
}

/* Focus styles for accessibility */
.filter-btn:focus {
    outline: 2px solid #2c5f6f;
    outline-offset: 2px;
}

.gallery-item:focus {
    outline: 2px solid #2c5f6f;
    outline-offset: 2px;
}

/* Print styles */
@media print {
    .gallery-filters,
    .modal {
        display: none;
    }
    
    .gallery-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
    }
    
    .gallery-item {
        height: auto;
        box-shadow: none;
        border: 1px solid #ddd;
    }
    
    .gallery-overlay {
        position: static;
        background: white;
        color: black;
        transform: none;
        padding: 10px;
    }
}