/**
 * Aras WEB Pazaryeri - Sonsuz Kaydırma & Lazy Load Stilleri
 * Facebook tarzı akıcı ürün akışı, iskelet (skeleton) yükleyiciler ve geçiş animasyonları.
 */

/* Yeni Yüklenen Kartlar İçin Yumuşak Giriş Animasyonu */
@keyframes infiniteCardFadeIn {
    0% {
        opacity: 0;
        transform: translateY(25px) scale(0.97);
    }
    100% {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.infinite-card-item {
    animation: infiniteCardFadeIn 0.45s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

/* Yükleniyor Göstergesi Konteyneri */
.infinite-scroll-status-wrapper {
    grid-column: 1 / -1;
    width: 100%;
    margin: 2.5rem 0 3.5rem 0;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 80px;
}

/* Facebook Tarzı Pulsating Loader */
.infinite-loader-dots {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(10, 10, 20, 0.75);
    border: 1px solid rgba(5, 217, 232, 0.3);
    padding: 10px 22px;
    border-radius: 30px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(12px);
}

.infinite-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: linear-gradient(135deg, #05d9e8, #00ff88);
    display: inline-block;
    animation: infinitePulseDot 1.4s infinite ease-in-out both;
}

.infinite-dot:nth-child(1) { animation-delay: -0.32s; }
.infinite-dot:nth-child(2) { animation-delay: -0.16s; }
.infinite-dot:nth-child(3) { animation-delay: 0s; }

@keyframes infinitePulseDot {
    0%, 80%, 100% {
        transform: scale(0.4);
        opacity: 0.3;
    }
    40% {
        transform: scale(1.15);
        opacity: 1;
        box-shadow: 0 0 12px rgba(5, 217, 232, 0.8);
    }
}

.infinite-loading-text {
    color: #fff;
    font-size: 0.92rem;
    font-weight: 600;
    margin-left: 8px;
    letter-spacing: 0.3px;
    font-family: 'Inter', sans-serif;
}

/* Daha Fazla Göster Butonu (Manual / Fallback Modu) */
.infinite-load-more-btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    background: linear-gradient(135deg, rgba(5, 217, 232, 0.15) 0%, rgba(0, 255, 136, 0.15) 100%);
    border: 1px solid rgba(5, 217, 232, 0.5);
    color: #fff;
    font-size: 1rem;
    font-weight: 700;
    padding: 0.85rem 2rem;
    border-radius: 30px;
    cursor: pointer;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    font-family: 'Outfit', sans-serif;
}

.infinite-load-more-btn:hover {
    background: linear-gradient(135deg, #05d9e8 0%, #00ff88 100%);
    color: #050508;
    box-shadow: 0 0 25px rgba(5, 217, 232, 0.6);
    transform: translateY(-2px);
    border-color: transparent;
}

.infinite-load-more-btn:active {
    transform: translateY(1px);
}

.infinite-load-more-btn.loading {
    pointer-events: none;
    opacity: 0.8;
}

/* Liste Bitti Rozeti */
.infinite-finished-badge {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--text-secondary, #aaa);
    padding: 10px 20px;
    border-radius: 20px;
    font-size: 0.88rem;
    font-weight: 600;
}

.infinite-finished-badge strong {
    color: #00ff88;
}

/* İskelet (Skeleton Shimmer) Kartları */
@keyframes skeletonShimmer {
    0% {
        background-position: -200% 0;
    }
    100% {
        background-position: 200% 0;
    }
}

.infinite-skeleton-card {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 16px;
    overflow: hidden;
    padding: 1rem;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.skeleton-box {
    background: linear-gradient(90deg, rgba(255,255,255,0.03) 25%, rgba(255,255,255,0.09) 50%, rgba(255,255,255,0.03) 75%);
    background-size: 200% 100%;
    animation: skeletonShimmer 1.6s infinite;
    border-radius: 8px;
}

.skeleton-img {
    width: 100%;
    aspect-ratio: 1 / 1;
    border-radius: 12px;
}

.skeleton-meta {
    width: 40%;
    height: 12px;
}

.skeleton-title {
    width: 85%;
    height: 20px;
}

.skeleton-price-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 6px;
}

.skeleton-price {
    width: 45%;
    height: 24px;
}

.skeleton-btn {
    width: 35%;
    height: 32px;
    border-radius: 8px;
}

/* Başa Dön Butonu (Floating Back To Top) */
.infinite-back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 46px;
    height: 46px;
    background: rgba(10, 10, 20, 0.85);
    border: 1px solid var(--accent-cyan, #05d9e8);
    color: var(--accent-cyan, #05d9e8);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    z-index: 990;
}

.infinite-back-to-top.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.infinite-back-to-top:hover {
    background: var(--accent-cyan, #05d9e8);
    color: #000;
    box-shadow: 0 0 20px rgba(5, 217, 232, 0.6);
    transform: translateY(-3px);
}
