/* Custom Styles */
body {
    overflow-x: hidden;
    scroll-behavior: smooth;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}
::-webkit-scrollbar-track {
    background: #f1f1f1; 
}
::-webkit-scrollbar-thumb {
    background: #c1c1c1; 
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #a8a8a8; 
}

/* Utilities */
.text-balance {
    text-wrap: balance;
}

.swiper-pagination-bullet-active {
    background-color: #3b82f6 !important;
}

/* ─── HERO BANNER RESPONSIVE SYSTEM ─────────────────── */
.hero-banner-wrapper {
    width: 100%;
    overflow: hidden;
    border-radius: 1rem;
    box-shadow: 0 1px 3px rgba(0,0,0,0.08);
    position: relative;
}

.hero-banner-wrapper .swiper {
    width: 100%;
    aspect-ratio: 3 / 1; /* Exactly matches 1200x400 image sizes */
}

.hero-banner-wrapper .swiper-slide {
    overflow: hidden;
    position: relative;
    background: #f3f4f6;
}

.hero-banner-wrapper .swiper-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    display: block;
    transition: transform 0.4s ease;
}

/* Lazy loading placeholder skeleton */
.hero-banner-wrapper .swiper-slide img[loading="lazy"] {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
}
@keyframes shimmer {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

/* Pagination styling */
.hero-banner-wrapper .swiper-pagination {
    bottom: 10px !important;
}
.hero-banner-wrapper .swiper-pagination-bullet {
    width: 8px;
    height: 8px;
    background: rgba(255,255,255,0.6);
    opacity: 1;
    transition: all 0.3s ease;
}
.hero-banner-wrapper .swiper-pagination-bullet-active {
    background: #fff !important;
    width: 24px;
    border-radius: 4px;
}

/* Navigation arrows */
.hero-banner-wrapper .swiper-button-next,
.hero-banner-wrapper .swiper-button-prev {
    width: 40px !important;
    height: 40px !important;
    background: rgba(0,0,0,0.25);
    backdrop-filter: blur(4px);
    border-radius: 50%;
    color: #fff !important;
    transition: background 0.3s ease;
}
.hero-banner-wrapper .swiper-button-next:hover,
.hero-banner-wrapper .swiper-button-prev:hover {
    background: rgba(0,0,0,0.5);
}
.hero-banner-wrapper .swiper-button-next::after,
.hero-banner-wrapper .swiper-button-prev::after {
    font-size: 14px !important;
    font-weight: bold;
}

/* Tablet / Desktop Overrides that only change pagination sizes */
@media (min-width: 768px) {
    .hero-banner-wrapper .swiper-pagination-bullet {
        width: 10px;
        height: 10px;
    }
    .hero-banner-wrapper .swiper-pagination-bullet-active {
        width: 28px;
    }
}

/* ─── SIDEBAR KATEGORI POPULER ─────────────────────── */
.sidebar-kategori-box {
    max-height: none;
    /* Match the hero banner height: the banner uses aspect-ratio 3/1
       on a flex-1 container (~calc(100% - 16rem - 1.5rem)).
       We cap the sidebar so it never exceeds the banner visually. */
    align-self: flex-start;
}

/* Category list scroll area */
.sidebar-cat-scroll {
    transition: max-height 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}
.sidebar-cat-scroll.is-scrollable {
    overflow-y: auto;
}

/* Thin modern scrollbar for the category list */
.sidebar-cat-scroll::-webkit-scrollbar {
    width: 4px;
}
.sidebar-cat-scroll::-webkit-scrollbar-track {
    background: transparent;
}
.sidebar-cat-scroll::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 99px;
}
.sidebar-cat-scroll::-webkit-scrollbar-thumb:hover {
    background: #94a3b8;
}
/* Firefox thin scrollbar */
.sidebar-cat-scroll {
    scrollbar-width: thin;
    scrollbar-color: #cbd5e1 transparent;
}

/* Category item hover effects */
.sidebar-cat-link {
    position: relative;
    border-left: 3px solid transparent;
}
.sidebar-cat-link:hover {
    background-color: #eff6ff;
    color: #3b82f6;
    border-left-color: #3b82f6;
    transform: translateX(2px);
}
.sidebar-cat-link:hover i {
    color: #3b82f6;
}
.sidebar-cat-link:active {
    background-color: #dbeafe;
}

/* Hidden category items animation */
.sidebar-cat-item {
    transition: opacity 0.3s ease, transform 0.3s ease;
}
.sidebar-cat-hidden {
    opacity: 0;
    transform: translateY(-8px);
}
.sidebar-cat-hidden.is-visible {
    display: list-item !important;
    opacity: 1;
    transform: translateY(0);
}

/* Toggle icon rotation */
#toggle-cat-icon.is-rotated {
    transform: rotate(180deg);
}

/* Hide Scrollbar */
.hide-scrollbar::-webkit-scrollbar { display: none; }
.hide-scrollbar { -ms-overflow-style: none; scrollbar-width: none; }

/* Interactive elements */
a, button, [role="button"], .cursor-pointer, select, label[for], 
input[type="checkbox"], input[type="radio"] {
    cursor: pointer;
}

/* Ensure pointer-events on interactive overlays */
.modal-overlay { pointer-events: auto; }

