﻿
/* =========================================
           2. GALERİ / PORTFOLYO ÖZEL CSS
           ========================================= */

.gallery-header {
    padding: 80px 0 40px;
    text-align: center;
}

    .gallery-header h1 {
        font-size: 2.5rem;
        color: var(--dark-blue);
        margin-bottom: 15px;
    }

    .gallery-header p {
        font-size: 1.1rem;
        color: var(--text-muted);
        max-width: 600px;
        margin: 0 auto;
    }

/* Galeri Izgarası */
.gallery-grid {
    padding-bottom: 100px;
}

/* Kare Resim Kutusu */
.gallery-item {
    position: relative;
    display: block;
    width: 100%;
    /* Aspect Ratio 1/1 ile tam kare olmasını sağlıyoruz */
    aspect-ratio: 1 / 1;
    border-radius: var(--card-radius);
    overflow: hidden;
    cursor: pointer;
    box-shadow: 0 10px 20px rgba(0,0,0,0.05);
    transition: all 0.3s ease;
}

    .gallery-item img {
        width: 100%;
        height: 100%;
        object-fit: cover; /* Resmi kutuya doldur */
        transition: transform 0.5s ease;
    }

    /* Hover Efekti */
    .gallery-item:hover {
        transform: translateY(-5px);
        box-shadow: 0 15px 30px rgba(0,0,0,0.15);
    }

        .gallery-item:hover img {
            transform: scale(1.1); /* Resim yakınlaşsın */
        }

/* Hover Overlay (Üzerine gelince çıkan yazı) */
.gallery-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to top, rgba(15, 43, 70, 0.9) 0%, rgba(15, 43, 70, 0.1) 100%);
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 25px;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.gallery-item:hover .gallery-overlay {
    opacity: 1;
}

.gallery-overlay h5 {
    color: white;
    font-size: 1.2rem;
    margin-bottom: 5px;
    transform: translateY(20px);
    transition: transform 0.3s ease;
}

.gallery-overlay span {
    color: var(--accent-orange);
    font-size: 0.9rem;
    font-weight: 600;
    transform: translateY(20px);
    transition: transform 0.3s ease 0.1s;
}

.gallery-item:hover .gallery-overlay h5,
.gallery-item:hover .gallery-overlay span {
    transform: translateY(0);
}

/* BÜYÜK RESİM (LIGHTBOX) MODALI */
.lightbox-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    z-index: 2000;
    display: none; /* Başlangıçta gizli */
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

    .lightbox-modal.active {
        display: flex;
        opacity: 1;
    }

.lightbox-content {
    position: relative;
    max-width: 90%;
    max-height: 90vh;
}

    .lightbox-content img {
        max-width: 100%;
        max-height: 85vh;
        border-radius: 8px;
        box-shadow: 0 0 50px rgba(0,0,0,0.5);
        object-fit: contain;
    }

/* Lightbox Bilgi Çubuğu (Resim Altı) */
.lightbox-caption {
    color: white;
    text-align: center;
    margin-top: 15px;
    font-size: 1.1rem;
    font-weight: 500;
}

/* Navigasyon Okları */
.lightbox-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255,255,255,0.1);
    color: white;
    border: none;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    font-size: 1.5rem;
    cursor: pointer;
    transition: 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
}

    .lightbox-nav:hover {
        background: var(--accent-orange);
        color: white;
    }

.lightbox-prev {
    left: 30px;
}

.lightbox-next {
    right: 30px;
}

.lightbox-close {
    position: absolute;
    top: 30px;
    right: 30px;
    background: transparent;
    border: none;
    color: white;
    font-size: 2rem;
    cursor: pointer;
    z-index: 2001;
    transition: 0.3s;
}

    .lightbox-close:hover {
        color: var(--accent-orange);
        transform: rotate(90deg);
    }

@media (max-width: 768px) {
    .lightbox-nav {
        width: 40px;
        height: 40px;
        font-size: 1.2rem;
    }

    .lightbox-prev {
        left: 10px;
    }

    .lightbox-next {
        right: 10px;
    }
}
