/* 2026-10-31 (audit UX Fable gelombang 2): dipindah dari <style> di app/toko/index.php supaya tersimpan di cache HP.
   Urutan tetap: file ini dimuat di posisi <style> lama, SEBELUM toko-elegan.css. */
    /* -----------------------------------------------------------------
       BLOCK_STYLE: CSS untuk header, logo, tombol, cart badge, qty mini
       ----------------------------------------------------------------- */

.toko-header-wrap { background: transparent; border-bottom: 1px solid rgba(255,255,255,0.12); }
.toko-header {
    min-height: 140px;
    padding: 1.1rem 0 0.85rem;
    position: relative;
    display: flex;
    align-items: flex-start;
    justify-content: center;
    color: #fff;
    width: 100%;
    margin: 0;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}
    .toko-header .overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to bottom,
        rgba(0, 0, 0, 0.15),
        rgba(0, 0, 0, 0.45)
    );
    z-index: 1;
}
    .toko-profile { position: relative; z-index: 2; text-align: center; width: 100%; padding-top: 0; }
    .toko-profile h3 { font-size: 1.05rem; margin-top: 14px; }
    .toko-logo-anchor { position: relative; display: inline-block; margin: 0 auto; }
    .toko-logo-ring { display: block; padding: 3px; border-radius: 50%; box-shadow: 0 6px 18px rgba(0,0,0,0.18); }
    .toko-logo-ring.role-seller { background: linear-gradient(135deg, #22c55e, #0d7a3a); }
    .toko-logo-ring.role-affiliator { background: linear-gradient(135deg, #fbbf24, #d97706); }
    .toko-logo-ring.role-founder { background: linear-gradient(135deg, #fde68a, #b8860b 60%, #fde68a); }
    .toko-logo-ring.role-both { background: linear-gradient(135deg, #22c55e 0%, #22c55e 45%, #fbbf24 55%, #fbbf24 100%); }
    .toko-logo { width: 84px; height: 84px; border-radius: 50%; overflow: hidden; background: #fff; display: flex; align-items: center; justify-content: center; }
    .toko-logo img { width:100%; height:100%; object-fit:cover; display:block; }
    .toko-actions { margin-top:7px; display:flex; gap:.4rem; justify-content:center; align-items:center; flex-wrap:wrap; }
    .toko-actions .btn img { height:18px; width:18px; object-fit:contain; margin-right:8px; display:inline-block; vertical-align:middle; }
    /* 2026-10-08: tombol keranjang melayang disembunyikan selama pop-up (modal) terbuka -- dulu menutupi isi pop-up testimoni */
    body.modal-open #cart-button { display:none !important; }
    /* 2026-10-22: bar keranjang bawah */
    #bar-keranjang { position:fixed; left:12px; right:12px; bottom:12px; z-index:2000; max-width:560px; margin:0 auto; display:none; align-items:center; gap:12px; padding:9px 14px 9px 9px; border-radius:16px; background:linear-gradient(135deg,#12925f,#0b5e3c); color:#fff; text-decoration:none; box-shadow:0 12px 28px rgba(11,94,60,.4); }
    body.ada-keranjang #bar-keranjang { display:flex; }
    body.ada-keranjang #cart-button { display:none !important; }
    body.ada-keranjang { padding-bottom:78px; }
    body.ada-keranjang .tp-testi { bottom:82px; }
    body.ada-keranjang .tp-fab-dasbor { bottom:84px !important; }
    body.modal-open #bar-keranjang, body.cat-panel-open #bar-keranjang, body.offcanvas-terbuka #bar-keranjang { display:none !important; }
    /* 2026-10-23: bar keranjang menyingkir saat layar digulir ke bawah (dulu menutupi tombol Tambah di kartu baris bawah) */
    #bar-keranjang { transition:transform .25s ease, opacity .25s ease; }
    body.bk-sembunyi #bar-keranjang { transform:translateY(calc(100% + 24px)); opacity:0; pointer-events:none; }
    body.ada-keranjang.bk-sembunyi .tp-fab-dasbor { bottom:20px !important; }
    .tp-fab-dasbor { transition:bottom .25s ease; }
    /* 2026-10-29 alur Gratis -> Mentor -> Mitra: tombol "Upgrade Jadi Mitra" (pemilik akun Gratis melihat tokonya sendiri)
       menumpuk tepat DI ATAS tombol Kelola Toko (jarak 60px) dan ikut bergeser bersamanya saat bar keranjang muncul/sembunyi,
       jadi tidak pernah menutupi bar keranjang, keranjang bulat, atau Kelola Toko. */
    .tp-fab-dasbor.tp-fab-upgrade { bottom:148px; background:#f59e0b; color:#1f1300; }
    body.ada-keranjang .tp-fab-dasbor.tp-fab-upgrade { bottom:144px !important; }
    body.ada-keranjang.bk-sembunyi .tp-fab-dasbor.tp-fab-upgrade { bottom:80px !important; }
    body.modal-open .tp-fab-dasbor.tp-fab-upgrade { display:none !important; }
    #bar-keranjang .bk-ikon { position:relative; width:40px; height:40px; border-radius:12px; background:rgba(255,255,255,.18); display:flex; align-items:center; justify-content:center; font-size:1.2rem; flex:0 0 auto; }
    #bk-jumlah { position:absolute; top:-6px; right:-6px; min-width:20px; height:20px; padding:0 5px; border-radius:999px; background:#fff; color:#0b5e3c; font-size:.72rem; font-weight:800; display:flex; align-items:center; justify-content:center; }
    #bar-keranjang .bk-teks { flex:1; min-width:0; display:flex; flex-direction:column; line-height:1.2; }
    #bar-keranjang .bk-judul { font-weight:800; font-size:.95rem; }
    #bar-keranjang .bk-info { font-size:.78rem; opacity:.9; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
    #bar-keranjang .bk-panah { font-size:1.1rem; }
    .toko-stats { margin-top:8px; display:flex; gap:.4rem; justify-content:center; align-items:center; flex-wrap:wrap; }
    .toko-stat { display:inline-flex; align-items:center; gap:.32rem; background:rgba(255,255,255,0.16); border:1px solid rgba(255,255,255,0.3); backdrop-filter:blur(4px); -webkit-backdrop-filter:blur(4px); color:#fff; font-size:.75rem; font-weight:600; padding:.32rem .65rem; border-radius:999px; }
    .toko-stat i { font-size:.85rem; }
    #cart-button {position: fixed;bottom: 20px;right: 20px;z-index: 2000; font-size: 20px;background: #198754;color: #fff; border-radius: 50%; width:56px; height:56px; display:flex;  align-items:center;justify-content:center; box-shadow: 0 6px 18px rgba(0,0,0,0.25);}
    #menu-button {
        position: absolute; top: 14px; left: 14px; z-index: 3;
        width: 44px; height: 44px; border-radius: 50%;
        background: rgba(0,0,0,0.38);
        backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px);
        display: flex; align-items: center; justify-content: center;
        color: #fff; font-size: 22px;
        box-shadow: 0 4px 14px rgba(0,0,0,0.3);
        border: 1px solid rgba(255,255,255,0.25);
        transition: background .15s, transform .1s;
    }
    #menu-button:active { transform: scale(0.94); background: rgba(0,0,0,0.5); }
    #install-button {
        position: absolute; top: 14px; right: 14px; z-index: 3;
        width: 40px; height: 40px; padding: 0; border-radius: 50%;
        background: rgba(0,0,0,0.55);
        backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px);
        align-items: center; justify-content: center;
        color: #fff; font-size: 18px;
        box-shadow: 0 4px 14px rgba(0,0,0,0.3);
        border: 1px solid rgba(255,255,255,0.25);
        transition: background .15s, transform .1s, opacity .3s, visibility .3s;
        opacity: 0; visibility: hidden;
    }
    #install-button.show { opacity: 1; visibility: visible; }
    #install-button:active { transform: scale(0.94); background: rgba(0,0,0,0.65); }
    #install-tooltip {
        position: absolute; top: 58px; right: 14px; z-index: 4;
        background: #dc2626; color: #fff; font-size: 12px; font-weight: 600; font-style: italic;
        padding: 8px 12px; border-radius: 10px; max-width: 200px;
        box-shadow: 0 4px 14px rgba(0,0,0,0.3);
        opacity: 0; visibility: hidden; transform: translateY(-6px);
        transition: opacity .3s, visibility .3s, transform .3s;
        pointer-events: none;
    }
    #install-tooltip.show { opacity: 1; visibility: visible; transform: translateY(0); }
    #install-tooltip::after {
        content: ""; position: absolute; top: -6px; right: 24px;
        width: 0; height: 0;
        border-left: 6px solid transparent; border-right: 6px solid transparent;
        border-bottom: 6px solid #dc2626;
    }
#cart-count-badge { position:absolute; top:-6px; right:-6px; min-width:22px; height:22px; display:flex; align-items:center; justify-content:center; font-size:12px; }
    @media (max-width:420px) { .toko-logo { width: 62px; height: 62px; } }
@keyframes cartBounce {
  0%   { transform: scale(1); }
  30%  { transform: scale(1.25); }
  50%  { transform: scale(0.95); }
  70%  { transform: scale(1.15); }
  100% { transform: scale(1); }
}

.cart-bounce {
  animation: cartBounce 0.6s ease;
}

.affiliate-landing {
    background: linear-gradient(135deg, #ecfdf5 0%, #ffffff 55%, #f0fdf4 100%);
    border: 1px solid rgba(25,135,84,.12);
    border-radius: 28px;
    padding: 28px;
    box-shadow: 0 16px 40px rgba(15,23,42,.08);
    overflow: hidden;
    position: relative;
}
.affiliate-landing:after {
    content: "";
    position: absolute;
    right: -70px;
    top: -90px;
    width: 220px;
    height: 220px;
    border-radius: 999px;
    background: rgba(25,135,84,.10);
}
.affiliate-landing > * { position: relative; z-index: 2; }
.affiliate-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: #dcfce7;
    color: #166534;
    border-radius: 999px;
    padding: 7px 12px;
    font-size: .82rem;
    font-weight: 800;
}
.affiliate-benefit {
    background: #fff;
    border: 1px solid rgba(15,23,42,.08);
    border-radius: 18px;
    padding: 14px;
    height: 100%;
}
.role-tag {
    position: absolute;
    display: inline-flex;
    align-items: center;
    z-index: 3;
}
.role-tag-icon {
    position: relative;
    z-index: 2;
    flex: 0 0 auto;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: .75rem;
    color: #fff;
    box-shadow: 0 2px 6px rgba(0,0,0,.35);
}
.role-tag-label {
    position: relative;
    z-index: 1;
    margin-left: -11px;
    padding: 3px 10px 3px 16px;
    border-radius: 999px;
    font-size: .75rem;
    font-weight: 800;
    letter-spacing: .01em;
    color: #fff;
    white-space: nowrap;
    box-shadow: 0 2px 6px rgba(0,0,0,.25);
}
.role-tag.role-seller .role-tag-icon,
.role-tag.role-seller .role-tag-label { background: linear-gradient(135deg, #22c55e, #0d7a3a); }
.role-tag.role-affiliator .role-tag-icon,
.role-tag.role-affiliator .role-tag-label { background: linear-gradient(135deg, #fbbf24, #d97706); }
.role-tag.role-affiliator .role-tag-label { color: #3a2405; }
.role-tag.role-founder .role-tag-icon,
.role-tag.role-founder .role-tag-label { background: linear-gradient(135deg, #1f2937, #0b1220); color: #fde68a; }
.role-tag.role-founder .role-tag-icon { color: #fbbf24; }

.role-tag.pos-center { left: 50%; top: 100%; transform: translate(-50%, -50%); }
.role-tag.pos-jam2 { left: 88%; top: 22%; transform: translate(0, -50%); }
.role-tag.pos-jam4 { left: 88%; top: 78%; transform: translate(0, -50%); }

/* ---------- BADGE PAKET (Gratis / Mitra) DI SAMPING NAMA TOKO ---------- */
.toko-nama-wrap {
    display: inline-flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    column-gap: 6px;
    row-gap: 2px;
    max-width: 100%;
}
.toko-nama-text { min-width: 0; overflow-wrap: break-word; }
.toko-verified-icon { flex-shrink: 0; font-size: .8em; color: #3b9bff; vertical-align: middle; }
.toko-paket-badge {
    flex-shrink: 0;
    display: inline-block;
    padding: 2px 10px;
    border-radius: 999px;
    font-size: .75rem;
    font-weight: 800;
    letter-spacing: .03em;
    text-transform: uppercase;
    line-height: 1.5;
    white-space: nowrap;
    background: #ecfdf5;
    color: #047857;
    box-shadow: 0 2px 6px rgba(0,0,0,.2);
}

/* ---------- OFFCANVAS MENU KIRI (hamburger) ---------- */
.menu-section-label {
    font-size: .75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .05em;
    color: #94a3b8;
    margin: 0 0 6px 4px;
}
#menuKiri .list-group-item i { width: 20px; display: inline-block; text-align: center; margin-right: 6px; color: #198754; }
#menuKiri .list-group-item.text-danger i { color: #dc3545; }
.menu-cta-mitra {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px;
    border-radius: 12px;
    background: linear-gradient(135deg, #22c55e, #0d7a3a);
    color: #fff;
    text-decoration: none;
    box-shadow: 0 4px 14px rgba(0,0,0,.15);
}
.menu-cta-mitra:hover { color: #fff; opacity: .92; }
.menu-cta-mitra i { font-size: 1.6rem; }
.menu-cta-mitra .small { color: rgba(255,255,255,0.85); }

/* ---------- QTY MINI DI KARTU PRODUK ---------- */
.product-card { cursor: default; }
/* kartu produk Seller lain di toko affiliator: gambar & nama bisa diklik -> detail (2026-09-28) */
.js-lintas-card .card-img-top, .js-lintas-card h6 { cursor: pointer; }
.product-media { cursor: pointer; }
.grosir-label {
  display: inline-block; align-self: flex-start;
  background: #e8f5e9; color: #1b5e20; border-radius: 6px;
  padding: 1px 6px; font-weight: 600; font-size: .75rem; line-height: 1.5;
}
/* 2026-10-11 pilihan satuan (Sachet / Renceng / Dus) */
.satuan-chips{display:flex;flex-wrap:wrap;gap:.3rem}
.satuan-chip{border:1px solid #ced4da;background:#fff;border-radius:999px;padding:.15rem .6rem;font-size:.78rem;line-height:1.4;color:#374151}
.satuan-chip.aktif{background:#198754;border-color:#198754;color:#fff;font-weight:600}
/* 2026-10-16 varian (warna/rasa/ukuran) */
.varian-chips{display:flex;flex-wrap:wrap;gap:.3rem}
.varian-chip{border:1px solid #ced4da;background:#fff;border-radius:.4rem;padding:.15rem .55rem;font-size:.78rem;line-height:1.4;color:#374151}
.varian-chip.aktif{border-color:#198754;color:#198754;background:#e8f5ee;font-weight:600;box-shadow:inset 0 0 0 1px #198754}
.varian-chip.habis{color:#9ca3af;text-decoration:line-through;background:#f3f4f6}
/* 2026-10-28: varian berfoto -> gambar kecil di tombol pilihan (jendela detail) */
.varian-chip.ada-foto{display:inline-flex;align-items:center;gap:.35rem;padding:.15rem .55rem .15rem .2rem}
.varian-chip-foto{width:30px;height:30px;object-fit:cover;border-radius:.3rem;flex:none;background:#f3f4f6}
.varian-chip.habis .varian-chip-foto{opacity:.45}
.qty-mini {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-top: 8px;
}
.qty-mini button {
    width: 28px;
    height: 28px;
    border-radius: 8px;
    border: 1px solid #ced4da;
    background: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    line-height: 1;
    padding: 0;
    color: #198754;
}
.qty-mini button:active { background: #f1f3f5; }
.qty-mini input {
    width: 40px;
    height: 28px;
    text-align: center;
    border: 1px solid #ced4da;
    border-radius: 8px;
    padding: 0;
    font-size: 14px;
}
.qty-mini input::-webkit-outer-spin-button,
.qty-mini input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.qty-mini input[type=number] { -moz-appearance: textfield; }
/* 2026-10-08: bubble testimoni kiri bawah (gaya pop-up mascahyo.com), tidak menutupi tombol keranjang kanan bawah */
.tp-testi { position:fixed; left:12px; bottom:20px; z-index:1990; width:260px; max-width:calc(100vw - 104px); background:#fff; border:1px solid #e3ece6; border-radius:14px; padding:9px 28px 8px 12px; box-shadow:0 10px 28px -10px rgba(0,0,0,.28); font-size:12px; line-height:1.4; color:#33403a; opacity:0; transform:translateY(10px); transition:opacity .35s ease, transform .35s ease; }
.tp-testi.tp-tampil { opacity:1; transform:translateY(0); }
.tp-testi.tp-ganti .tp-testi-isi, .tp-testi.tp-ganti .tp-testi-bintang, .tp-testi.tp-ganti .tp-testi-nama { opacity:0; }
.tp-testi-isi, .tp-testi-bintang, .tp-testi-nama { transition:opacity .18s ease; }
.tp-testi-tutup { position:absolute; top:3px; right:5px; border:0; background:none; color:#9aa79f; font-size:16px; line-height:1; padding:4px; cursor:pointer; }
.tp-testi-kepala { font-size:12px; font-weight:700; color:#15803d; text-transform:uppercase; letter-spacing:.3px; }
.tp-testi-bintang { color:#f59e0b; font-size:12px; letter-spacing:1px; margin-top:1px; }
.tp-testi-bintang span { color:#d1d5db; }
.tp-testi-isi { margin:2px 0 4px; display:-webkit-box; -webkit-line-clamp:3; -webkit-box-orient:vertical; overflow:hidden; }
.tp-testi-kaki { display:flex; align-items:center; justify-content:space-between; gap:6px; }
.tp-testi-nama { font-size:12px; color:#6b7280; font-weight:600; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.tp-testi-next { border:0; background:#ecfdf3; color:#15803d; font-size:12px; font-weight:600; border-radius:999px; padding:3px 9px; white-space:nowrap; cursor:pointer; }
.tp-testi-urut { color:#6b9a7d; font-weight:500; margin-right:2px; }
body.modal-open .tp-testi, body:has(.offcanvas.show) .tp-testi { display:none !important; }
.testimoni-scroll { display:flex; gap:10px; overflow-x:auto; padding-bottom:6px; scroll-snap-type:x mandatory; }
.testimoni-card { flex:0 0 78%; max-width:320px; scroll-snap-align:start; background:#f6fbf7; border:1px solid #d6eedd; border-radius:14px; padding:12px 14px; }
.testimoni-bintang { color:#f59e0b; font-size:.95rem; letter-spacing:1px; }
.testimoni-bintang span { color:#d1d5db; }
.testimoni-isi { font-size:.9rem; margin:4px 0 6px; display:-webkit-box; -webkit-line-clamp:4; -webkit-box-orient:vertical; overflow:hidden; }
.testimoni-nama { font-size:.8rem; color:#6b7280; font-weight:600; }
.share-produk-btn {
    position: absolute; top: 8px; left: 8px; z-index: 3;
    width: 30px; height: 30px; padding: 0; border: 0; border-radius: 50%;
    display: inline-flex; align-items: center; justify-content: center;
    background: rgba(255,255,255,.92); color: #2f855a; font-size: .85rem;
    box-shadow: 0 2px 6px rgba(0,0,0,.18); cursor: pointer;
}
.share-produk-btn:active { transform: scale(.92); }
.stok-habis-badge {
    position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%);
    background: rgba(17,24,39,.82); color: #fff; font-weight: 700; font-size: .85rem;
    padding: 6px 14px; border-radius: 999px; pointer-events: none; white-space: nowrap;
}
.btn-quick-add {
    flex: 1 1 auto;
    white-space: nowrap;
}
#quick-add-toast {
    position: fixed;
    top: 16px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 3000;
    padding: 10px 18px;
    border-radius: 999px;
    color: #fff;
    font-size: 14px;
    font-weight: 600;
    box-shadow: 0 6px 18px rgba(0,0,0,.2);
    transition: opacity .2s;
    opacity: 0;
    pointer-events: none;
}

/* ---------- KATEGORI SCROLL HORIZONTAL ---------- */
.category-scroll-wrap {
    position: sticky;
    top: 0;
    z-index: 900;
    background: #f8f9fa;
    transition: box-shadow .15s;
}
.category-scroll-wrap.is-stuck {
    box-shadow: 0 4px 10px rgba(0,0,0,.08);
}
.category-scroll {
    display: flex;
    gap: 12px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    padding: 6px 2px 6px;
    scroll-snap-type: x proximity;
}

/* tanda bisa digeser: fade + panah di tepi kiri/kanan, cuma tampil
   kalau memang masih ada kategori tersembunyi ke arah itu */
.scroll-hint {
    position: absolute;
    top: 0;
    bottom: 0;
    width: 34px;
    border: none;
    padding: 0;
    z-index: 5;
    display: flex;
    align-items: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity .2s;
}
.scroll-hint.show { opacity: 1; pointer-events: auto; }
.scroll-hint-left { left: 0; justify-content: flex-start; background: linear-gradient(to right, #f8f9fa 45%, rgba(248,249,250,0)); }
.scroll-hint-right { right: 0; justify-content: flex-end; background: linear-gradient(to left, #f8f9fa 45%, rgba(248,249,250,0)); }
.scroll-hint i {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    background: #fff;
    box-shadow: 0 2px 6px rgba(0,0,0,.18);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #078c4b;
    font-size: 13px;
}
@media (min-width: 1600px) {
    main.container { max-width: 1520px; }
}

/* ---------- SEARCH PRODUK ---------- */
.produk-search-group {
    border-radius: 999px;
    overflow: hidden;
    box-shadow: 0 1px 4px rgba(15,23,42,.08);
    border: 1px solid #dee2e6;
}
.produk-search-group .input-group-text,
.produk-search-group .form-control {
    border: 0;
    padding-top: .45rem;
    padding-bottom: .45rem;
}
.produk-search-group .form-control:focus {
    box-shadow: none;
}

/* ---------- FOOTER TOKO ---------- */
.tp-footer {
    background: #0b3d24;
    color: #cbd5e1;
    padding: 32px 0 22px;
    margin-top: 40px;
}
.tp-footer-brand { display: flex; align-items: center; gap: 12px; margin-bottom: 16px; }
.tp-footer-brand img { width: 44px; height: 44px; border-radius: 50%; object-fit: cover; background: #fff; flex: 0 0 auto; }
.tp-footer-name { font-weight: 700; color: #fff; }
.tp-footer-slogan { font-size: .82rem; color: #9fb8ab; }
.tp-footer-info { display: flex; flex-wrap: wrap; gap: 8px 20px; font-size: .88rem; color: #cbd5e1; margin-bottom: 4px; }
.tp-footer-link { color: #6ee7b7; text-decoration: none; font-weight: 600; }
.tp-footer-link:hover { color: #a7f3d0; }
.tp-footer-divider { border-color: rgba(255,255,255,.12); margin: 18px 0 14px; }
.tp-footer-bottom { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px; font-size: .78rem; color: #8ba396; }
.tp-footer-bottom a { color: #8ba396; text-decoration: none; }
.tp-footer-bottom a:hover { color: #fff; text-decoration: underline; }
.category-scroll::-webkit-scrollbar { display: none; }
.category-chip {
    display: flex;
    flex-direction: column;
    align-items: center;
    flex: 0 0 auto;
    width: 54px;
    text-decoration: none;
    scroll-snap-align: start;
}
.category-chip .category-icon {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 4px;
    transition: .15s;
    box-shadow: 0 0 0 2px transparent;
}
.category-chip .category-icon img {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    display: block;
    object-fit: cover;
}
.category-chip.active .category-icon {
    box-shadow: 0 0 0 2px #078c4b;
}
.category-chip .category-label {
    font-size: 12px;
    line-height: 1.15;
    font-weight: 600;
    color: #17382a;
    text-align: center;
    white-space: normal;
    max-width: 54px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    min-height: 20px;
}
.category-chip.active .category-label { color: #078c4b; }

/* ---------- SUB-KATEGORI (2026-10-12) ---------- */
.subcat-bar { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; padding: 2px 0 10px; margin-bottom: 2px; }
.subcat-bar::-webkit-scrollbar { display: none; }
.subcat-pill { flex: 0 0 auto; padding: 5px 12px; border-radius: 999px; border: 1px solid #cfe7da; background: #fff; color: #17382a;
    font-size: 12px; font-weight: 600; text-decoration: none; white-space: nowrap; }
.subcat-pill.active { background: #078c4b; border-color: #078c4b; color: #fff; }
.subcat-pill { display: inline-flex; align-items: center; gap: 6px; }
.subcat-ikon { width: 20px; height: 20px; border-radius: 50%; object-fit: cover; margin-left: -6px; background: #fff; }

/* ---------- PANEL "LIHAT SEMUA" KATEGORI ---------- */
.category-scroll-wrap.has-cat-more .category-scroll { padding-right: 72px; }
.category-scroll-wrap.has-cat-more:not(.no-overflow) .scroll-hint-right { display: none; }
.cat-more-btn {
    position: absolute; top: 0; right: 0; bottom: 0; width: 68px;
    border: 0; padding: 6px 0 6px 12px; z-index: 6; cursor: pointer;
    display: flex; flex-direction: column; align-items: center; justify-content: flex-start;
    background: linear-gradient(to left, #f8f9fa 78%, rgba(248,249,250,0));
}
.cat-more-icon {
    width: 42px; height: 42px; border-radius: 50%; margin-bottom: 4px;
    display: flex; align-items: center; justify-content: center;
    background: #e3f4ea; color: #078c4b; font-size: 17px; transition: .15s;
}
.cat-more-label { font-size: 12px; line-height: 1.15; font-weight: 700; color: #078c4b; text-align: center; min-height: 20px; }
.cat-more-label i { font-size: 8px; display: inline-block; transition: transform .15s; }
.cat-more-btn[aria-expanded="true"] .cat-more-icon { background: #078c4b; color: #fff; }
.cat-more-btn[aria-expanded="true"] .cat-more-label i { transform: rotate(180deg); }
.category-scroll-wrap.no-overflow .cat-more-btn { display: none; }
.category-scroll-wrap.no-overflow .category-scroll { padding-right: 2px; }
.cat-panel {
    position: absolute; left: 0; right: 0; top: 100%; z-index: 7;
    background: #fff; border-radius: 0 0 16px 16px;
    box-shadow: 0 14px 28px rgba(15,23,42,.18);
    padding: 12px 14px 16px; max-height: 68vh; overflow-y: auto; overscroll-behavior: contain;
    animation: catPanelIn .18s ease-out;
}
@keyframes catPanelIn { from { opacity: 0; transform: translateY(-8px); } to { opacity: 1; transform: none; } }
.cat-panel-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px; }
.cat-panel-title { font-weight: 700; color: #17382a; font-size: .95rem; }
.cat-panel-title span { color: #6c757d; font-weight: 500; }
.cat-panel-close { border: 0; background: #f1f3f5; width: 32px; height: 32px; border-radius: 50%; color: #495057; }
.cat-panel-search { border-radius: 999px; margin-bottom: 14px; font-size: .9rem; }
.cat-panel-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px 6px; }
@media (min-width: 576px) { .cat-panel-grid { grid-template-columns: repeat(6, 1fr); } }
@media (min-width: 992px) { .cat-panel-grid { grid-template-columns: repeat(8, 1fr); } }
.cat-panel-item { display: flex; flex-direction: column; align-items: center; text-align: center; text-decoration: none; }
.cat-panel-item .category-icon {
    width: 50px; height: 50px; border-radius: 50%; margin-bottom: 5px;
    box-shadow: 0 0 0 2px transparent; transition: .15s;
}
.cat-panel-item .category-icon img { width: 100%; height: 100%; border-radius: 50%; object-fit: cover; display: block; }
.cat-panel-item span {
    font-size: 12px; line-height: 1.2; font-weight: 600; color: #17382a;
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.cat-panel-item.active .category-icon { box-shadow: 0 0 0 2px #078c4b; }
.cat-panel-item.active span { color: #078c4b; }
.cat-panel-empty { text-align: center; color: #6c757d; font-size: .9rem; padding: 16px 0 4px; }
.cat-backdrop { position: fixed; inset: 0; background: rgba(15,23,42,.35); z-index: 899; }
/* tombol melayang (keranjang/dasbor) disembunyikan selama panel terbuka supaya tidak menutupi kategori */
#cart-button, .tp-fab-dasbor { transition: opacity .15s, transform .15s; }
body.cat-panel-open #cart-button, body.cat-panel-open .tp-fab-dasbor { opacity: 0; transform: scale(.85); pointer-events: none; }

/* -----------------------------------------------------------------
   BLOCK_STYLE: Badge Poin (pojok kanan-atas gambar produk)
   ----------------------------------------------------------------- */
.poin-badge {
    position: absolute;
    top: 8px;
    right: 8px;
    z-index: 2;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 3px 9px 3px 7px;
    border-radius: 999px;
    background: linear-gradient(135deg, #2b2f38, #14161b);
    color: #ffd166;
    font-size: .75rem;
    font-weight: 700;
    letter-spacing: 0.02em;
    box-shadow: 0 3px 8px rgba(0, 0, 0, 0.28);
    border: 1px solid rgba(255, 209, 102, 0.35);
}
/* 2026-10-23: pita sudut Ready / Pre-Order, keluar dari sudut kanan atas kartu */
.pita-sudut {
    position: absolute; top: 0; right: 0; z-index: 4;
    width: 96px; height: 96px; overflow: hidden; pointer-events: none;
}
.pita-sudut span {
    position: absolute; top: 20px; right: -36px; width: 150px;
    transform: rotate(45deg);
    display: flex; align-items: center; justify-content: center; gap: 3px;
    padding: 3px 0; color: #fff;
    font-size: .62rem; font-weight: 800; letter-spacing: .07em; text-transform: uppercase;
    text-shadow: 0 1px 1px rgba(0,0,0,.25);
    box-shadow: 0 4px 10px rgba(0,0,0,.28);
    border-top: 1px dashed rgba(255,255,255,.55);
    border-bottom: 1px dashed rgba(255,255,255,.55);
    background-clip: padding-box; overflow: hidden;
}
.pita-sudut span .bi { font-size: .7rem; }
.pita-ready span { background: linear-gradient(90deg, #0f9f4f, #22c55e 50%, #0f9f4f); outline: 3px solid #0f9f4f; }
.pita-po span { background: linear-gradient(90deg, #e2530b, #fb923c 50%, #e2530b); outline: 3px solid #e2530b; }
/* kilau lewat sesekali */
.pita-sudut span::after {
    content: ""; position: absolute; top: 0; bottom: 0; left: -40%; width: 30%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,.65), transparent);
    animation: pita-kilau 3.2s ease-in-out infinite;
}
@keyframes pita-kilau { 0%, 55% { left: -40%; } 100% { left: 130%; } }
@media (prefers-reduced-motion: reduce) { .pita-sudut span::after { animation: none; display: none; } }
/* poin pindah ke kiri (di bawah tombol share) supaya tak tertutup pita */
.product-media:has(.pita-sudut) .poin-badge { right: auto; left: 8px; top: 48px; }
.po-teks { color: #c2410c; font-weight: 600; font-size: .75rem; }
.po-teks .bi { margin-right: 2px; }
#detail-stock.po-detail { color: #c2410c !important; font-weight: 600; }

.poin-badge .bi-star-fill {
    font-size: .75rem;
    color: #ffd166;
}

/* -----------------------------------------------------------------
   BLOCK_STYLE: Bar Flash Sale (api besar + countdown) di bawah gambar produk
   ----------------------------------------------------------------- */
.flashsale-bar {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 2;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    padding: 4px 8px 4px 60px;
    background: linear-gradient(90deg, #b3001b, #ff4b2b 55%, #ff7a00);
    background-size: 200% 100%;
    animation: flashsaleBarUrgent 0.7s linear infinite;
}
.flashsale-fire-big {
    position: absolute;
    left: -20px;
    bottom: -24px;
    z-index: 3;
    filter: drop-shadow(0 3px 4px rgba(0, 0, 0, 0.5));
    pointer-events: none;
    transform-origin: 50% 100%;
    animation: flashsaleFireFlicker 1.6s ease-in-out infinite;
}
.flashsale-fire-big .fire-core {
    transform-origin: 50% 100%;
    animation: flashsaleFireCoreGlow 1s ease-in-out infinite;
}
.flashsale-countdown {
    color: #fff;
    font-weight: 700;
    font-size: 0.82rem;
    letter-spacing: 0.01em;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.4);
    white-space: nowrap;
    overflow: hidden;
    display: inline-flex;
    align-items: baseline;
}
.flashsale-countdown .cd-days {
    font-style: italic;
    font-weight: 600;
    font-size: 0.82em;
    opacity: 0.92;
    margin-right: 3px;
}
.flashsale-countdown .cd-num {
    font-weight: 800;
    font-size: 1.15em;
    font-variant-numeric: tabular-nums;
    font-feature-settings: "tnum" 1;
}
.flashsale-countdown .cd-sep {
    font-weight: 600;
    opacity: 0.7;
    font-size: 0.9em;
    margin: 0 1px;
}
/* Api diam di tempat (tidak bounce/lompat), yang "bergerak" cuma
   kobarannya: bentuk sedikit melenting + inti nyala berkedip. */
@keyframes flashsaleFireFlicker {
    0%   { transform: scaleY(1)    scaleX(1)    skewX(0deg); }
    22%  { transform: scaleY(1.06) scaleX(0.96) skewX(-1.5deg); }
    45%  { transform: scaleY(0.95) scaleX(1.04) skewX(1.5deg); }
    68%  { transform: scaleY(1.05) scaleX(0.97) skewX(-1deg); }
    86%  { transform: scaleY(0.97) scaleX(1.02) skewX(1deg); }
    100% { transform: scaleY(1)    scaleX(1)    skewX(0deg); }
}
@keyframes flashsaleFireCoreGlow {
    0%, 100% { opacity: 0.65; transform: scale(0.95); }
    50%      { opacity: 1;    transform: scale(1.08); }
}
@keyframes flashsaleBarUrgent {
    0%   { background-position: 0% 50%; filter: brightness(1); }
    50%  { background-position: 100% 50%; filter: brightness(1.2); }
    100% { background-position: 0% 50%; filter: brightness(1); }
}
@media (prefers-reduced-motion: reduce) {
    .flashsale-bar, .flashsale-fire-big, .flashsale-fire-big .fire-core { animation: none; }
}

    