/**
 * Dropdown "Shop" di menu
 * (functions.php bagian 28 + inc/class-teesful-menu-walker.php)
 */

/* ---------- Dropdown Shop di menu ---------- */

/* Baris "Shop": ikon tas + tulisan di kiri, panah di kanan (sejajar item menu lain).
   Padding bawah dikecilkan (12px → 6px) khusus untuk tombol ini, supaya jarak ke
   "By Product" tidak terlalu jauh, TANPA mengubah padding judul kelompok itu sendiri. */
.people-mobile-has-sub--shop > .people-mobile-nav-toggle {
    padding: 12px 30px;
}
.people-mobile-nav-toggle__label.has-icon {
    display: flex;
    align-items: center;
    gap: 10px;
}

/* Isi dropdown: tinggi maksimal, sisanya di-scroll di dalam dropdown */
.people-mobile-has-sub--shop > .people-mobile-submenu {
    max-height: 240px;               /* ± 6 baris; ubah angka ini untuk batas lain */
}
.people-mobile-has-sub--shop.is-open > .people-mobile-submenu {
    overflow-y: auto !important;     /* nav.js memasang overflow:hidden untuk animasi */
    overscroll-behavior: contain;    /* scroll dropdown tidak ikut menggulir menu */
    -webkit-overflow-scrolling: touch;
}

/* Satu baris kategori/tag: nama di kiri (sejajar tulisan "Shop"), jumlah di kanan */
.tf-term-link {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 8px 30px 4px calc(62px + var(--depth, 0) * 14px); /* 30 + ikon 22 + jarak 10 */
}
.tf-term-link__name {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.tf-term-link__count {
    flex: none;
    opacity: .6;
    font-weight: 400;
    font-size: 13px;
    font-variant-numeric: tabular-nums;
}

/* Judul kelompok "By Product" / "By Theme": sama persis untuk semua kelompok,
   tebal hitam, sejajar nama kategori, menempel di atas saat daftar di-scroll */
.tf-term-heading {
    position: sticky;
    top: 0;
    z-index: 1;
    padding: 10px 30px 4px 62px;
    background: #fff;
    font-family: "Inter", var(--utility);
    font-size: 14px;
    font-weight: 700;
    color: var(--ink);
}

.tf-term-heading + .people-mobile-submenu-item .tf-term-link {
    padding-top: 8px;                /* sama dengan baris lain (dulu 4px, terlalu rapat ke judul) */
}

/* Judul kelompok = tombol buka/tutup: tulisan di kiri, panah di kanan (sejajar jumlah produk) */
.tf-term-heading__btn {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    padding: 0;
    border: 0;
    background: none;
    color: inherit;
    font: inherit;
    text-align: left;
    cursor: pointer;
}
.tf-term-heading__chevron {
    flex: none;
    transform: rotate(90deg);        /* terbuka: panah ke bawah */
    transition: transform 0.25s ease;
}
.tf-term-heading__btn[aria-expanded="false"] .tf-term-heading__chevron {
    transform: none;                 /* tertutup: panah ke kanan */
}
/* Kids: satu baris link bergaya judul */
.tf-term-heading__link {
    display: block;
    color: inherit;
    text-decoration: none;
}
/* Kids dengan isi: nama (link) di kiri, panah buka/tutup di kanan */
.tf-term-heading--split {
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.tf-term-heading--split .tf-term-heading__link {
    flex: 1;
    min-width: 0;
}
.tf-term-heading__btn--icon {
    width: auto;
    flex: none;
    padding: 6px 0 6px 16px;         /* area ketuk lebih luas dari ikonnya */
    margin: -6px 0;
}
.tf-term-heading__btn:focus-visible,
.tf-term-heading__link:focus-visible {
    outline: 2px solid var(--ink);
    outline-offset: 2px;
}
@media (prefers-reduced-motion: reduce) {
    .tf-term-heading__chevron {
        transition: none;
    }
}

/* Semua panah dihilangkan: kelompok selalu terbuka (judul tidak lagi bisa ditutup) */
.tf-term-heading__chevron,
.tf-term-heading__btn--icon {
    display: none;
}
.tf-term-heading__btn {
    pointer-events: none;
    cursor: default;
}