﻿:root {
    --brand: #2f3db6
}

.prod-card {
    overflow: hidden; /* Taşmaları gizlemek için visible yerine hidden daha güvenli olabilir, tasarıma göre visible kalsın dersen elleme */
    overflow: visible;
    cursor: pointer;
    position: relative; /* relative olduğundan emin olalım */
}

/* Maske */
.prod-mask {
    position: absolute;
    inset: 0;
    opacity: 0;
    transition: opacity .3s ease;
    z-index: 1;
    pointer-events: none;
    background: linear-gradient(90deg,rgba(0,0,0,.55) 0,rgba(0,0,0,.35) 40%,rgba(0,0,0,.12) 70%,rgba(0,0,0,0) 100%);
    border-radius: inherit; /* Kartın oval köşelerini takip etsin */
}

/* Animasyon */
@keyframes packFloatY {
    0% {
        transform: translateY(-50%);
    }

    50% {
        transform: translateY(calc(-50% + 10px));
    }

    100% {
        transform: translateY(calc(-50% - 6px));
    }
}

/* Hover Ortası (Gizli Metin) */
.hover-center {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 0 1rem;
    opacity: 0;
    transition: opacity .25s ease;
    z-index: 3;
}

/* Ürün Resmi Ayarları */
.pack-protocol-img {
    position: absolute;
    top: 50%;
    right: -10px; /* EKLENDİ: Resmi sağa yaslar, yazıların üstüne binmesini engeller */
    transform: translateY(-50%);
    height: clamp(260px, 100%, 360px) !important;
    width: auto;
    object-fit: contain;
    z-index: 2;
    animation: packFloatY 2s ease-in-out infinite;
    transition: opacity .12s ease;
}

/* DÜZELTME: HTML'deki class ismiyle eşleşti (.pack-img yerine .pack-protocol-img) */
.prod-card:hover .pack-protocol-img {
    opacity: 0;
    animation-play-state: paused;
}

/* Başlık */
.prod-title {
    line-height: 35px;
    font-style: italic !important;
    position: absolute;
    top: 12px;
    left: 14px;
    margin: 0;
    z-index: 4;
    text-shadow: 0 2px 8px rgba(0,0,0,.35);
    max-width: 60%; /* Başlığın resmin altına girmesini engeller */
}

/* Buton ve Fiyat Alanı */
.prod-actions {
    position: absolute;
    left: 14px;
    bottom: 14px;
    z-index: 4; /* Z-index artırıldı */
}

/* Buton Stilleri */
.btn-outline-brand {
    border: 2px solid #fff; /* Varsayılan beyaz sınır */
    color: #fff;
    background: transparent;
    transition: all .2s ease;
}

    .btn-outline-brand:hover {
        background: var(--brand);
        color: #fff;
        border-color: var(--brand);
    }

/* Arama Butonu (Yuvarlak) */
.btn-icon-outline {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    border: 2px solid #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    background: transparent;
    transition: all .2s ease;
}

/* Kart Hover Efektleri */
.prod-card:hover .prod-mask {
    opacity: 1;
}

.prod-card:hover .hover-center {
    opacity: 1;
}

/* Hover durumunda butonların rengini koru veya değiştir */
.prod-card:hover .btn-outline-brand,
.prod-card:hover .btn-icon-outline {
    border-color: #fff;
    color: #fff;
    background: transparent;
}

/* MOBİL AYARI */
@media (max-width: 576.98px) {
    /* DÜZELTME: Class ismi güncellendi */
    .pack-protocol-img {
        right: -10px;
        height: min(38vw, 130px) !important;
    }
}
