/* =========================================
   İskilip Medya - Fotoğraf Galerisi CSS
   ========================================= */

/* Masonry Grid */
.gallery-grid {
    columns: 3;
    column-gap: 16px;
}
@media (max-width: 992px) { .gallery-grid { columns: 2; } }
@media (max-width: 576px) { .gallery-grid { columns: 1; } }

/* Gallery Item */
.gallery-item {
    break-inside: avoid;
    margin-bottom: 16px;
    border-radius: 14px;
    overflow: hidden;
    position: relative;
    cursor: pointer;
    box-shadow: 0 3px 12px rgba(0,0,0,0.08);
    transition: all 0.3s ease;
    background: #f0f0f0;
}

.gallery-item:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 30px rgba(11, 61, 44, 0.2);
}

.gallery-item img {
    width: 100%;
    display: block;
    transition: transform 0.4s ease;
    object-fit: cover;
}

.gallery-item:hover img {
    transform: scale(1.04);
}

/* Overlay */
.gallery-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(11,61,44,0.85) 0%, transparent 55%);
    opacity: 0;
    transition: opacity 0.3s ease;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 16px;
}

.gallery-item:hover .gallery-overlay {
    opacity: 1;
}

.gallery-overlay .zoom-icon {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -60%) scale(0.8);
    width: 48px;
    height: 48px;
    background: rgba(255,255,255,0.2);
    border: 2px solid rgba(255,255,255,0.6);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 1.2rem;
    transition: all 0.3s ease;
    backdrop-filter: blur(4px);
}

.gallery-item:hover .zoom-icon {
    transform: translate(-50%, -50%) scale(1);
}

.gallery-overlay .img-title {
    color: #fff;
    font-size: 0.88rem;
    font-weight: 600;
    margin: 0;
    line-height: 1.4;
}

.gallery-overlay .img-meta {
    color: rgba(255,255,255,0.7);
    font-size: 0.75rem;
    margin-top: 3px;
}

/* Category Filter Pills */
.filter-pills .btn {
    border-radius: 30px;
    font-size: 0.85rem;
    font-weight: 600;
    transition: all 0.2s;
    border: 1.5px solid #dee2e6;
    color: #64748b;
}

.filter-pills .btn.active,
.filter-pills .btn:hover {
    background: #0b3d2c;
    color: #fff;
    border-color: #0b3d2c;
}

/* Lightbox Overlay */
#lightbox-overlay {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 9999;
    background: rgba(0,0,0,0.93);
    align-items: center;
    justify-content: center;
    flex-direction: column;
}

#lightbox-overlay.active {
    display: flex;
}

#lightbox-img {
    max-width: 90vw;
    max-height: 80vh;
    object-fit: contain;
    border-radius: 10px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.6);
    transition: opacity 0.2s ease;
}

#lightbox-caption {
    color: rgba(255,255,255,0.85);
    margin-top: 16px;
    font-size: 0.95rem;
    font-weight: 500;
    text-align: center;
}

#lightbox-meta {
    color: rgba(255,255,255,0.5);
    font-size: 0.8rem;
    margin-top: 4px;
    text-align: center;
}

#lightbox-close {
    position: absolute;
    top: 20px;
    right: 24px;
    color: #fff;
    font-size: 2rem;
    cursor: pointer;
    opacity: 0.7;
    line-height: 1;
    transition: opacity 0.2s;
    background: none;
    border: none;
    padding: 0;
}

#lightbox-close:hover { opacity: 1; }

#lightbox-prev,
#lightbox-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255,255,255,0.1);
    border: none;
    color: #fff;
    font-size: 1.6rem;
    width: 52px;
    height: 52px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background 0.2s;
    backdrop-filter: blur(4px);
}

#lightbox-prev { left: 20px; }
#lightbox-next { right: 20px; }

#lightbox-prev:hover,
#lightbox-next:hover { background: rgba(255,255,255,0.25); }

#lightbox-counter {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    color: rgba(255,255,255,0.5);
    font-size: 0.85rem;
}
