/* ============================================================
   Kart Carousel (cardcarousel) — mağaza (storefront) stilleri
   Yükleme: cardcarousel.twig içinde <link> ile (tema CSS'ine dokunulmaz).
   ============================================================ */

.cardcarousel-module {
    width: 100%;
}

/* --- Görünürlük yardımcıları (992px kırılımı; yalnız GİZLER, display tipini zorlamaz) --- */
@media (max-width: 991.98px) {
    .cc-only-desktop { display: none !important; }
}
@media (min-width: 992px) {
    .cc-only-mobile { display: none !important; }
}
/* Mobilde (telefon) modülü tamamen gizle */
@media (max-width: 767.98px) {
    .cc-hide-phone { display: none !important; }
}

/* --- Kart: oran kartta; görsel kartı TAM doldurur (cover), üst/alt boşluk kalmaz --- */
.cc-card {
    position: relative;
    display: block;
    overflow: hidden;
    border-radius: 10px;
    aspect-ratio: var(--cc-ar, 600 / 800);
    text-decoration: none;
    color: #fff;
    background: #1a1a1a;
}

.cc-img-el {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    display: block;
    z-index: 1;
}

/* Yükleme iskeleti (bootstrap placeholder-glow) — görsel yüklenince JS kaldırır.
   Lazy kartlarda görsel scroll'da yüklenene kadar shimmer görünür. */
.cc-skeleton {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border-radius: inherit;
    background-color: #cfd4da;
    pointer-events: none;
    z-index: 0;
}

/* --- İçerik (başlık + açıklama) overlay --- */
.cc-caption {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 2;
    padding: 40px 18px 18px;
    background: linear-gradient(to top, rgba(0, 0, 0, .78) 0%, rgba(0, 0, 0, .45) 45%, rgba(0, 0, 0, 0) 100%);
}

.cc-title {
    margin: 0 0 4px;
    font-size: 18px;
    font-weight: 700;
    line-height: 1.25;
    color: #fff;
}

.cc-desc {
    margin: 0;
    font-size: 13px;
    line-height: 1.4;
    color: rgba(255, 255, 255, .85);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* --- Düz liste (grid): mobil / tablet / masaüstü sütun sayısı CSS değişkeniyle --- */
.cc-grid {
    display: grid;
    grid-template-columns: repeat(var(--cc-m, 1), minmax(0, 1fr));
    gap: 16px;
    align-items: start;
}

@media (min-width: 768px) {
    .cc-grid {
        grid-template-columns: repeat(var(--cc-t, 2), minmax(0, 1fr));
    }
}

@media (min-width: 992px) {
    .cc-grid {
        grid-template-columns: repeat(var(--cc-d, 3), minmax(0, 1fr));
    }
}

/* --- Swiper (carousel) --- */
.cc-swiper {
    padding-top: 4px;
    padding-bottom: 10px;
}

.cc-swiper .swiper-slide {
    height: auto;
}

/* Navigation okları */
.cc-swiper .swiper-button-prev,
.cc-swiper .swiper-button-next {
    color: #fff;
    width: 40px;
    height: 40px;
    background: rgba(0, 0, 0, .45);
    border-radius: 50%;
    transition: background .2s ease;
}

.cc-swiper .swiper-button-prev:hover,
.cc-swiper .swiper-button-next:hover {
    background: rgba(0, 0, 0, .7);
}

.cc-swiper .swiper-button-prev::after,
.cc-swiper .swiper-button-next::after {
    font-size: 16px;
    font-weight: 700;
}

/* Pagination noktaları (kartların altında) */
.cc-swiper .swiper-pagination {
    position: static;
    margin-top: 10px;
}

.cc-swiper .swiper-pagination-bullet-active {
    background: #212529;
}
