/* ZFS Product Booster — yapışkan sepete ekle çubuğu (sadece mobil)
   Minimalist: tek satır asistan teaser + fiyat + tek buton. */

.zfspb-sticky-wrap {
    display: none;
}

@media (max-width: 820px) {
    .zfspb-sticky-wrap {
        display: block;
        position: fixed;
        left: 0;
        right: 0;
        bottom: 0;
        z-index: 9999;
    }

    .zfspb-assist-teaser {
        display: flex;
        align-items: center;
        gap: 8px;
        background: #fff6ee;
        border-top: 1px solid #ffd9b3;
        padding: 8px 14px;
        font: 600 12px/1.3 'Open Sans', sans-serif;
        color: #a24700;
        text-decoration: none;
    }

    .zfspb-assist-teaser svg {
        width: 16px;
        height: 16px;
        stroke: var(--zfspb-accent, #ff6a00);
        fill: none;
        stroke-width: 2.2;
        flex-shrink: 0;
    }

    .zfspb-sticky-bar {
        display: flex;
        align-items: center;
        gap: 12px;
        background: #fff;
        border-top: 1px solid #ece7dd;
        padding: 10px 14px;
        box-shadow: 0 -8px 24px rgba(0, 0, 0, .08);
    }

    .zfspb-sticky-price {
        font: 800 15px/1 'Montserrat', sans-serif;
        color: #171310;
        white-space: nowrap;
    }

    .zfspb-sticky-btn {
        flex: 1;
        text-align: center;
        background: var(--zfspb-accent, #ff6a00);
        color: #fff !important;
        font: 700 13px/1 'Open Sans', sans-serif;
        text-decoration: none;
        border-radius: 10px;
        padding: 12px 16px;
    }

    /* Sayfanın en altındaki içerik, sabit çubuğun arkasında kalmasın. */
    body.single-product {
        padding-bottom: 96px;
    }
}

/* --- Ürün özeti içindeki zengin asistan satırı (mobil + masaüstü) --- */
.zfspb-assist-inline {
    display: flex !important;
    align-items: center !important;
    gap: 12px;
    padding: 13px 15px !important;
    margin: 14px 0 !important;
    border: 1px solid #d7ecd9;
    border-radius: var(--zfspb-radius, 12px);
    background: linear-gradient(135deg, #f2fbf3, #fff) !important;
    text-decoration: none !important;
    box-sizing: border-box;
    transition: border-color .15s ease;
}

.zfspb-assist-inline:hover {
    border-color: #25d366;
}

.zfspb-assist-icon {
    flex-shrink: 0;
    width: 36px;
    height: 36px;
    border-radius: 999px;
    background: #25d366;
    display: flex;
    align-items: center;
    justify-content: center;
}

.zfspb-assist-icon svg {
    width: 19px;
    height: 19px;
    stroke: #fff;
    fill: none;
    stroke-width: 2;
}

.zfspb-assist-body {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

.zfspb-assist-body b {
    font: 700 12.5px/1.3 'Open Sans', sans-serif !important;
    color: #171310 !important;
}

.zfspb-assist-body em {
    font-style: normal;
    font: 400 11px/1.3 'Open Sans', sans-serif !important;
    color: #5f7a62 !important;
}

.zfspb-assist-arrow {
    flex-shrink: 0;
    font-size: 22px;
    line-height: 1;
    color: #a9bfab;
}

@media (max-width: 420px) {
    .zfspb-assist-inline { padding: 11px 12px !important; gap: 9px; }
    .zfspb-assist-icon { width: 30px; height: 30px; }
    .zfspb-assist-icon svg { width: 16px; height: 16px; }
    .zfspb-assist-body b { font-size: 11.5px !important; }
    .zfspb-assist-body em { font-size: 10px !important; }
}

/* ===== Canlı asistan teaser'ı ===== */

.zfspb-assist-teaser {
    display: flex !important;
    align-items: center;
    gap: 10px;
}

/* Avatar + nabız halkası */
.zfspb-assist-avatar {
    position: relative;
    flex-shrink: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: #25D366;
}

.zfspb-assist-avatar svg {
    width: 17px;
    height: 17px;
    fill: #fff !important;
    stroke: none;
}

/* Çevrimiçi noktası */
.zfspb-assist-dot {
    position: absolute;
    right: -1px;
    bottom: -1px;
    width: 9px;
    height: 9px;
    border-radius: 50%;
    background: #2ecc71;
    border: 2px solid #fff;
}

.zfspb-assist-msg {
    flex: 1 1 auto;
    min-width: 0;
}

/* "Yazıyor…" noktaları */
.zfspb-assist-typing {
    flex-shrink: 0;
    display: none;
    align-items: center;
    gap: 3px;
    padding-right: 2px;
}
.zfspb-assist-typing i {
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: currentColor;
    opacity: .35;
}

/* --- Animasyonlar (yalnızca panelden açıksa) --- */
.zfspb-assist-teaser.has-anim .zfspb-assist-typing { display: flex; }

.zfspb-assist-teaser.has-anim .zfspb-assist-typing i {
    animation: zfspb-typing 1.4s infinite ease-in-out;
}
.zfspb-assist-teaser.has-anim .zfspb-assist-typing i:nth-child(2) { animation-delay: .2s; }
.zfspb-assist-teaser.has-anim .zfspb-assist-typing i:nth-child(3) { animation-delay: .4s; }

@keyframes zfspb-typing {
    0%, 60%, 100% { opacity: .25; transform: translateY(0); }
    30%           { opacity: .9;  transform: translateY(-3px); }
}

/* Nabız halkası — sürekli ama çok hafif */
.zfspb-assist-teaser.has-anim .zfspb-assist-avatar::before {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: 50%;
    border: 2px solid #25D366;
    animation: zfspb-pulse 2.6s infinite ease-out;
}

@keyframes zfspb-pulse {
    0%   { transform: scale(1);    opacity: .55; }
    70%  { transform: scale(1.55); opacity: 0; }
    100% { transform: scale(1.55); opacity: 0; }
}

/* Arada bir dikkat çeken kısa sallanma (JS tetikler) */
.zfspb-assist-teaser.is-nudging .zfspb-assist-avatar {
    animation: zfspb-nudge .7s ease;
}

@keyframes zfspb-nudge {
    0%, 100% { transform: rotate(0)     scale(1); }
    20%      { transform: rotate(-12deg) scale(1.12); }
    45%      { transform: rotate(10deg)  scale(1.12); }
    70%      { transform: rotate(-6deg)  scale(1.06); }
}

/* Hareket azaltma tercihine saygı */
@media (prefers-reduced-motion: reduce) {
    .zfspb-assist-teaser.has-anim .zfspb-assist-typing i,
    .zfspb-assist-teaser.has-anim .zfspb-assist-avatar::before,
    .zfspb-assist-teaser.is-nudging .zfspb-assist-avatar {
        animation: none !important;
    }
}
