/* ===== Navbar (floating, same width as .content) ===== */
.navbar {
    position: fixed;
    top: 16px;
    left: 0;
    right: 0;
    display: flex;
    justify-content: center;
    z-index: 10000;

    background: transparent;
    margin: 0;
    pointer-events: none;
    /* hanya kontainer dalam yang klik-able */
}

.nav-shell {
    display: flex;
    justify-content: space-between;
    align-items: center;

    /* Samakan ukuran dengan .content */
    max-width: 1000px;
    width: 95%;
    margin: 0 auto;

    background: rgba(0, 0, 0, 0.5);
    padding: 12px 20px;
    border-radius: 8px;
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.25);
    backdrop-filter: blur(4px);

    pointer-events: auto;
}

.nav-shell ul {
    list-style: none;
    display: flex;
    gap: 20px;
    margin: 0;
    padding: 0;
}

.nav-shell a {
    color: #fff;
    text-decoration: none;
    font-weight: 600;
    transition: color 0.2s, background-color 0.2s;
    padding: 6px 10px;
    border-radius: 4px;
    background: transparent;
}

.nav-shell a:hover {
    color: #FFD54F;
}

.nav-shell a.active {
    color: #FFD54F;
    text-decoration: underline;
    text-underline-offset: 4px;
    background: rgba(255, 213, 79, 0.15);
}

/* badge untuk counter keranjang */
.cart-badge {
    display: inline-block;
    min-width: 18px;
    padding: 2px 6px;
    border-radius: 999px;
    font-size: 12px;
    line-height: 1;
    vertical-align: middle;
    margin-left: 6px;
    background: #e11d48;
    color: #fff;
}

/* Responsive */
@media (max-width: 768px) {
    .nav-shell {
        flex-direction: column;
        gap: 10px;
        padding: 10px 16px;
    }

    .nav-shell ul {
        justify-content: center;
        flex-wrap: wrap;
        gap: 14px;
    }

    .nav-shell a {
        font-size: 0.95rem;
    }

    .navbar {
        display: none;
    }

    body {
        padding-bottom: 70px;
    }
}

/* ===== Mobile Bottom Tabbar ===== */
.mobile-tabbar {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 10001;
    display: none;
    /* default hidden on desktop */
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(6px);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding: 8px 6px;
    pointer-events: auto;
}

.mobile-tabbar .tab-item {
    flex: 1 1 0;
    text-align: center;
    color: #fff;
    text-decoration: none;
    font-weight: 600;
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    position: relative;
    /* for badge positioning */
}

.mobile-tabbar .tab-item i {
    font-size: 20px;
    line-height: 1;
}

.mobile-tabbar .tab-item .label {
    font-size: 11px;
    line-height: 1;
    opacity: 0.9;
}

.mobile-tabbar .tab-item.active,
.mobile-tabbar .tab-item:hover {
    color: #FFD54F;
}

/* position badge over cart icon */
.mobile-tabbar .cart-badge {
    position: absolute;
    top: 2px;
    right: 22px;
    transform: translate(50%, -50%);
}

/* Show tabbar only on mobile */
@media (max-width: 768px) {
    .mobile-tabbar {
        display: flex;
        justify-content: space-around;
    }
}