/*
|--------------------------------------------------------------------------
| Modern Storefront UI Theme Architecture (ecommerce-ui.css)
|--------------------------------------------------------------------------
|
| WEB SPL Primary Ecommerce Theme
| Author: Al Shimbil Khan
|
*/

/* Alpine.js: hide x-cloak elements before Alpine initializes (prevents FOUC) */
[x-cloak] {
    display: none !important;
}

/* Announcement bar: hidden instantly via sync script when previously dismissed */
[data-announcement-dismissed="1"] .announcement-bar {
    display: none !important;
}

/* ==========================================================================
   1. Dynamic CSS Variables & Design System Tokens
   ========================================================================== */
:root {
    /* Color Palette Defaults */
    --body-bg-color: #f8f9fa;
    --primary-bg-color: #ffc376;
    --primary-fg-color: #212529;
    --primary-link-hover: #212121;
    --secondary-bg-color: #6c757d;
    --secondary-fg-color: #ffffff;
    --secondary-link-hover: #495057;

    /* Header & Navigation Colors */
    --main-nav-bg-color: #e74079;
    --main-nav-text-color: #ffffff;
    --sub-nav-bg-color: #dddddd;
    --sub-nav-text-color: #212529;

    /* Primary Buttons & Interactive Elements */
    --btn-primary-bg-color: #ffc376;
    --btn-primary-text-color: #212529;
    --btn-primary-hover-bg-color: #e0ab5b;
    --btn-primary-hover-text-color: #212529;

    /* Secondary Buttons */
    --btn-secondary-bg-color: #6c757d;
    --btn-secondary-text-color: #ffffff;
    --btn-secondary-hover-bg-color: #5a6268;
    --btn-secondary-hover-text-color: #ffffff;

    /* Footer Colors */
    --footer-section-bg-color: #dddddd;
    --footer-section-text-color: #212529;

    /* Design Tokens */
    --ecom-font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    --ecom-font-family-bn: "Hind Siliguri", "SolaimanLipi", system-ui, sans-serif;
    --ecom-border-radius-sm: 0.375rem;
    --ecom-border-radius-md: 0.5rem;
    --ecom-border-radius-lg: 0.75rem;
    --ecom-border-radius-pill: 50rem;
    --ecom-border-color: #e3e8ee;
    --ecom-card-bg: #ffffff;
    --ecom-box-shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.05);
    --ecom-box-shadow-md: 0 4px 16px rgba(0, 0, 0, 0.08);
    --ecom-box-shadow-lg: 0 8px 30px rgba(0, 0, 0, 0.12);
    --ecom-transition-fast: all 0.15s cubic-bezier(0.4, 0, 0.2, 1);
    --ecom-transition-base: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    --mobile-nav-height: 62px;
}

/* ==========================================================================
   Storefront Theme Custom Utility Classes (ecom-bg-primary, ecom-bg-secondary, etc.)
   ========================================================================== */
.ecom-bg-primary {
    background-color: var(--primary-bg-color, #ffc376) !important;
    color: var(--primary-fg-color, #212529) !important;
}

.ecom-bg-primary-subtle,
.ecom-bg-primary-tint {
    background-color: color-mix(in srgb, var(--primary-bg-color, #ffc376) 20%, transparent) !important;
}

.ecom-bg-secondary {
    background-color: var(--secondary-bg-color, #6c757d) !important;
    color: var(--secondary-fg-color, #ffffff) !important;
}

.ecom-bg-secondary-subtle,
.ecom-bg-secondary-tint {
    background-color: color-mix(in srgb, var(--secondary-bg-color, #6c757d) 20%, transparent) !important;
}

.ecom-text-primary {
    color: var(--primary-bg-color, #ffc376) !important;
}

a.ecom-text-primary:hover,
.ecom-text-primary:hover,
a.text-primary:hover,
.ecom-link-primary:hover {
    color: var(--primary-link-hover, #212121) !important;
}

.ecom-text-secondary {
    color: var(--secondary-bg-color, #6c757d) !important;
}

a.ecom-text-secondary:hover,
.ecom-text-secondary:hover,
a.text-secondary:hover,
.ecom-link-secondary:hover {
    color: var(--secondary-link-hover, #495057) !important;
}

.ecom-border-primary {
    border-color: var(--primary-bg-color, #ffc376) !important;
}

.ecom-border-secondary {
    border-color: var(--secondary-bg-color, #6c757d) !important;
}

.ecom-badge-primary {
    background-color: var(--primary-bg-color, #ffc376) !important;
    color: var(--primary-fg-color, #212529) !important;
}

.ecom-badge-primary-subtle {
    background-color: color-mix(in srgb, var(--primary-bg-color, #ffc376) 25%, transparent) !important;
    color: var(--primary-fg-color, #212529) !important;
}

/* ==========================================================================
   2. Typography & Multi-Language Bangla Support
   ========================================================================== */
html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: var(--ecom-font-family);
    background-color: var(--body-bg-color);
    color: #212529;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    margin: 0;
    padding: 0;
    overflow-x: hidden;
}

/* Conditionally Applied Bangla Typography Rules */
html[lang^="bn"] body,
body.lang-bn,
.lang-bn {
    font-family: var(--ecom-font-family-bn) !important;
    line-height: 1.6;
}

html[lang^="bn"] h1,
html[lang^="bn"] h2,
html[lang^="bn"] h3,
html[lang^="bn"] h4,
html[lang^="bn"] h5,
html[lang^="bn"] h6,
html[lang^="bn"] .btn,
html[lang^="bn"] .nav-link {
    font-family: var(--ecom-font-family-bn) !important;
}

main.main-content {
    flex: 1 0 auto;
    padding-top: 1rem;
    padding-bottom: 2rem;
}

/* ==========================================================================
   3. Top Announcement Bar — Premium Animated Marquee
   ========================================================================== */
.announcement-bar {
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: center;
    background: linear-gradient(90deg, #111318 0%, #1e2130 40%, #252a3a 70%, #111318 100%);
    background-size: 200% 100%;
    animation: announcement-gradient 8s ease infinite;
    color: #e8eaf0;
    font-size: 0.82rem;
    font-weight: 500;
    height: 34px;
    letter-spacing: 0.3px;
    z-index: 1040;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.announcement-bar::before {
    content: '';
    position: absolute;
    top: 0;
    left: -60%;
    width: 40%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 215, 100, 0.08), transparent);
    animation: announcement-shimmer 3.5s ease-in-out infinite;
    pointer-events: none;
}

.announcement-bar__marquee {
    flex: 1;
    overflow: hidden;
    white-space: nowrap;
}

.announcement-bar__track {
    display: inline-flex;
    gap: 4rem;
    animation: announcement-scroll 22s linear infinite;
    will-change: transform;
}

.announcement-bar:hover .announcement-bar__track {
    animation-play-state: paused;
}

.announcement-bar__text {
    display: inline-block;
    padding: 0 0.5rem;
}

.announcement-bar__text a {
    color: #fff;
    text-decoration: underline;
    text-underline-offset: 2px;
}

.announcement-bar__close {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    margin-right: 8px;
    border: none;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.12);
    color: #fff;
    cursor: pointer;
    transition: background 0.2s ease, transform 0.2s ease;
    padding: 0;
}

.announcement-bar__close:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: rotate(90deg);
}

/* Alpine.js leave transition */
.announcement-bar-leave {
    transition: max-height 0.35s ease, opacity 0.35s ease;
}

.announcement-bar-leave-start {
    max-height: 34px;
    opacity: 1;
}

.announcement-bar-leave-end {
    max-height: 0;
    opacity: 0;
}

@keyframes announcement-scroll {
    0% {
        transform: translateX(0);
    }

    100% {
        transform: translateX(-33.333%);
    }
}

@keyframes announcement-gradient {
    0% {
        background-position: 0% 50%;
    }

    50% {
        background-position: 100% 50%;
    }

    100% {
        background-position: 0% 50%;
    }
}

@keyframes announcement-shimmer {
    0% {
        left: -60%;
    }

    100% {
        left: 120%;
    }
}

@media (prefers-reduced-motion: reduce) {
    .announcement-bar__track {
        animation: none;
    }

    .announcement-bar {
        animation: none;
        background: #111318;
    }

    .announcement-bar::before {
        display: none;
    }
}


/* ==========================================================================
   4. Header & Navigation Architecture
   ========================================================================== */
.main-navbar {
    border-bottom: 1px solid rgba(0, 0, 0, 0.08);
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.1);
    z-index: 1030;
}

/* ── Top Navbar ── */
.main-navbar .top-navbar {
    background-color: var(--main-nav-bg-color);
    padding: 6px 0;
}

/* ── Logo ── */
.navbar-logo-img {
    height: 46px;
    max-width: 160px;
    width: auto;
    object-fit: contain;
    transition: opacity 0.2s ease;
}

.navbar-brand:hover .navbar-logo-img {
    opacity: 0.88;
}

/* ── Search Bar ── */
.nav-search-wrap {
    display: flex;
    align-items: center;
    background: rgba(255, 255, 255, 0.97);
    border-radius: 50rem;
    border: none;
    overflow: hidden;
    transition: box-shadow 0.2s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12), 0 0 0 2px rgba(255, 255, 255, 0.3);
    height: 44px;
}

.nav-search-wrap:focus-within {
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.14), 0 0 0 3px rgba(255, 255, 255, 0.85);
}

.nav-search-icon {
    display: flex;
    align-items: center;
    padding: 0 4px 0 15px;
    color: #aaa;
    font-size: 0.88rem;
    pointer-events: none;
    flex-shrink: 0;
}

.nav-search-input {
    flex: 1;
    border: none;
    background: transparent;
    padding: 0 0.5rem;
    font-size: 0.88rem;
    color: #1a1a2e;
    min-width: 0;
    height: 100%;
    /* Kill ALL browser and Bootstrap focus rings on the raw input */
    outline: 0 !important;
    box-shadow: none !important;
    -webkit-appearance: none;
    appearance: none;
}

.nav-search-wrap .nav-search-input:focus,
.nav-search-wrap .nav-search-input:focus-visible {
    outline: 0 !important;
    box-shadow: none !important;
    border: none !important;
}

.nav-search-input::placeholder {
    color: #aaa;
}

.nav-search-input::-webkit-search-cancel-button {
    display: none;
}

/* Shortcut badge — hidden when user is typing (no placeholder visible = has value) */
.nav-search-kbd {
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
    gap: 2px;
    font-family: inherit;
    font-size: 0.68rem;
    font-weight: 600;
    color: #999;
    background: #f0f0f0;
    border: 1px solid #ddd;
    border-radius: 4px;
    padding: 2px 5px;
    margin-right: 6px;
    cursor: pointer;
    user-select: none;
    white-space: nowrap;
    transition: opacity 0.15s ease;
    letter-spacing: 0.3px;
}

/* Hide shortcut when input has a value */
.nav-search-input:not(:placeholder-shown)~.nav-search-kbd,
.nav-search-input:focus~.nav-search-kbd {
    opacity: 0;
    pointer-events: none;
}

.nav-search-btn {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    gap: 5px;
    border: none;
    /* Right side rounds to match the pill wrapper — don't rely on parent overflow:hidden */
    border-radius: 0 50rem 50rem 0;
    background-color: var(--btn-primary-bg-color);
    color: var(--btn-primary-text-color);
    padding: 0 1.3rem;
    font-size: 0.85rem;
    font-weight: 700;
    cursor: pointer;
    height: 100%;
    /* Reserve fixed width so Bootstrap Icon font loading doesn't cause layout shift */
    min-width: 100px;
    transition: background-color 0.18s ease, transform 0.15s ease;
    white-space: nowrap;
    letter-spacing: 0.2px;
    outline: none;
}

/* Reserve icon width before Bootstrap Icons @font-face loads — prevents CLS */
.nav-search-btn .bi {
    display: inline-block;
    width: 1em;
    text-align: center;
}

/* ── Icon CLS prevention for nav action buttons ── */
/* Pre-reserves 1em width so Bootstrap Icons font load doesn't shift layout */
.nav-action-pill .bi,
.nav-user-btn .bi,
.nav-cart-btn .bi,
.nav-cart-icon-wrap .bi,
.nav-icon-btn .bi {
    display: inline-block;
    width: 1em;
    text-align: center;
    flex-shrink: 0;
}

/* Reserve cart icon circle size before content arrives */
.nav-cart-icon-wrap {
    min-width: 28px;
}

.nav-search-btn:hover {
    background-color: var(--btn-primary-hover-bg-color);
    color: var(--btn-primary-hover-text-color);
}

.nav-search-btn:active {
    transform: scale(0.97);
}

/* ── Search Results Dropdown ── */
.nav_search_result_container {
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    right: 0;
    z-index: 9999;
}

.nav_search_result_body {
    border-radius: var(--ecom-border-radius-lg);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.14);
    background: #ffffff;
    border: 1px solid var(--ecom-border-color);
    max-height: 440px;
    overflow-y: auto;
    min-height: 60px;
}

/* ── Search result items ── */
.nav-search-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 14px;
    text-decoration: none;
    color: #1a1a2e;
    transition: background 0.15s ease;
    border-bottom: 1px solid rgba(0, 0, 0, 0.04);
}

.nav-search-item:last-of-type {
    border-bottom: none;
}

.nav-search-item:hover,
.nav-search-item.active {
    background: rgba(0, 0, 0, 0.035);
    color: #1a1a2e;
}

.nav-search-item-img {
    flex-shrink: 0;
    width: 44px;
    height: 44px;
    border-radius: 6px;
    overflow: hidden;
    background: #f5f5f5;
    display: flex;
    align-items: center;
    justify-content: center;
}

.nav-search-item-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.nav-search-item-img-placeholder {
    color: #ccc;
    font-size: 1.1rem;
}

.nav-search-item-info {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.nav-search-item-name {
    font-size: 0.875rem;
    font-weight: 500;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    color: #1a1a2e;
}

.nav-search-item-price {
    font-size: 0.8rem;
    display: flex;
    align-items: center;
    gap: 6px;
}

.nav-search-item-price .disc {
    font-weight: 700;
    color: var(--primary-bg-color);
}

.nav-search-item-price .orig {
    color: #aaa;
    font-weight: 400;
    text-decoration: line-through;
}

.nav-search-item-arrow {
    flex-shrink: 0;
    font-size: 0.85rem;
    color: #ccc;
    transition: transform 0.15s ease, color 0.15s ease;
}

.nav-search-item:hover .nav-search-item-arrow,
.nav-search-item.active .nav-search-item-arrow {
    color: var(--primary-bg-color);
    transform: translateX(3px);
}

/* View all footer link */
.nav-search-view-all {
    display: flex;
    align-items: center;
    padding: 10px 14px;
    font-size: 0.83rem;
    font-weight: 600;
    color: var(--primary-bg-color);
    text-decoration: none;
    border-top: 1px solid rgba(0, 0, 0, 0.06);
    background: rgba(0, 0, 0, 0.015);
    transition: background 0.15s ease;
}

.nav-search-view-all:hover,
.nav-search-view-all.active {
    background: rgba(0, 0, 0, 0.04);
    color: var(--primary-bg-color);
}

/* No results */
.nav-search-no-result {
    padding: 20px 16px;
    text-align: center;
    font-size: 0.88rem;
    color: #999;
}

/* Loading state */
.nav-search-loading {
    padding: 16px;
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.85rem;
    color: #888;
}

.nav-search-spinner {
    display: inline-block;
    width: 16px;
    height: 16px;
    border: 2px solid rgba(0, 0, 0, 0.1);
    border-top-color: var(--primary-bg-color);
    border-radius: 50%;
    animation: nav-search-spin 0.6s linear infinite;
    flex-shrink: 0;
}

@keyframes nav-search-spin {
    to {
        transform: rotate(360deg);
    }
}

/* ── Desktop nav button shared height ── */
.nav-action-pill,
.nav-user-btn,
.nav-cart-btn {
    height: 36px;
}

/* ── Offers Pill ── */
.nav-action-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0 0.95rem;
    border-radius: 50rem;
    font-size: 0.83rem;
    font-weight: 600;
    text-decoration: none;
    transition: var(--ecom-transition-fast);
    white-space: nowrap;
}

.offers-pill {
    background: rgba(255, 255, 255, 0.15);
    color: #fff;
    border: 1px solid rgba(255, 255, 255, 0.25);
}

.offers-pill:hover {
    background: rgba(255, 255, 255, 0.28);
    color: #fff;
}

.track-pill {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    border: 1px solid rgba(255, 255, 255, 0.2);
    cursor: pointer;
}

.track-pill:hover {
    background: rgba(255, 255, 255, 0.22);
    color: #fff;
    border-color: rgba(255, 255, 255, 0.4);
}


/* ── User Account Button ── */
.nav-user-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0 1rem;
    border: none;
    border-radius: 50rem;
    background-color: var(--btn-primary-bg-color);
    color: var(--btn-primary-text-color);
    font-size: 0.84rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--ecom-transition-fast);
    white-space: nowrap;
}

.nav-user-btn:hover {
    background-color: var(--btn-primary-hover-bg-color);
    color: var(--btn-primary-hover-text-color);
    transform: translateY(-1px);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
}

.nav-user-btn:focus {
    background-color: var(--btn-primary-hover-bg-color);
    color: var(--btn-primary-hover-text-color);
    outline: none;
}

.nav-user-btn.dropdown-toggle::after {
    margin-left: 0.2rem;
    vertical-align: middle;
}

/* ── Mobile Icon Buttons ── */
.nav-icon-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border: none;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.15);
    color: var(--main-nav-text-color);
    font-size: 1.05rem;
    cursor: pointer;
    transition: background 0.2s ease;
    padding: 0;
}

/* ── Modern Mobile Hamburger (clean, no bg/border) ── */
.custom-navbar-toggler {
    position: relative;
    width: 40px;
    height: 40px;
    border: none;
    background: transparent;
    border-radius: 10px;
    transition: transform 0.2s ease, background 0.2s ease;
}

.custom-navbar-toggler:active {
    transform: scale(0.9);
}

.custom-navbar-toggler:focus-visible {
    outline: 2px solid var(--btn-primary-bg-color);
    outline-offset: 2px;
}

/* Active state when the mobile search drawer is open */
.custom-navbar-toggler.is-search-active {
    background: var(--btn-primary-bg-color);
    color: var(--btn-primary-text-color);
}

.custom-navbar-toggler.is-search-active:hover {
    background: var(--btn-primary-bg-color);
    color: var(--btn-primary-text-color);
}

/* Animated bars */
.toggler-bars {
    position: relative;
    display: block;
    width: 20px;
    height: 14px;
}

.toggler-bars span {
    position: absolute;
    left: 0;
    width: 100%;
    height: 2px;
    border-radius: 2px;
    background: currentColor;
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.2s ease, top 0.3s ease;
}

.toggler-bars span:nth-child(1) {
    top: 0;
}

.toggler-bars span:nth-child(2) {
    top: 6px;
}

.toggler-bars span:nth-child(3) {
    top: 12px;
}

/* Morph to X once expanded */
.custom-navbar-toggler[aria-expanded="true"] {
    color: var(--btn-primary-bg-color);
}

.custom-navbar-toggler[aria-expanded="true"] .toggler-bars span:nth-child(1) {
    top: 6px;
    transform: rotate(45deg);
}

.custom-navbar-toggler[aria-expanded="true"] .toggler-bars span:nth-child(2) {
    opacity: 0;
    transform: scaleX(0.4);
}

.custom-navbar-toggler[aria-expanded="true"] .toggler-bars span:nth-child(3) {
    top: 6px;
    transform: rotate(-45deg);
}

/* ── Mobile bar polish (glass + spacing) ── */
.main-navbar .top-navbar .row>.col-12.col-md-7.d-md-none {
    padding-top: 2px;
    padding-bottom: 2px;
}

.main-navbar .top-navbar .col-12.col-md-7.d-md-none .navbar-logo-img {
    height: 42px;
    max-width: 130px;
}

/* ── Mobile Navigation Drawer (off-canvas) ── */
.mobile-nav-drawer {
    width: min(86vw, 340px);
    border: none;
    background: #fff;
    box-shadow: 0 0 50px rgba(0, 0, 0, 0.28);
}

.mobile-nav-drawer-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 11px 14px;
    background: linear-gradient(135deg,
            var(--main-nav-bg-color) 0%,
            color-mix(in srgb, var(--main-nav-bg-color) 72%, #2a0a1a) 100%);
    color: var(--main-nav-text-color);
}

.mobile-nav-brand {
    display: inline-flex;
    align-items: center;
}

.mobile-nav-drawer-logo {
    height: 45px;
    max-height: 45px;
    width: auto;
    max-width: 150px;
    object-fit: contain;
    filter: brightness(0) invert(1);
}

.mobile-nav-drawer-close {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border: none;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.16);
    color: #fff;
    font-size: 0.95rem;
    cursor: pointer;
    transition: background 0.2s ease, transform 0.25s ease;
}

.mobile-nav-header-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.mobile-nav-header-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    border: none;
    border-radius: 50rem;
    padding: 7px 14px;
    background: rgba(255, 255, 255, 0.18);
    color: #fff;
    font-size: 0.8rem;
    font-weight: 700;
    text-decoration: none;
    cursor: pointer;
    transition: background 0.2s ease, transform 0.15s ease;
}

.mobile-nav-header-btn:hover {
    background: rgba(255, 255, 255, 0.32);
    color: #fff;
}

.mobile-nav-header-btn:active {
    transform: scale(0.96);
}

.mobile-nav-header-btn--offer {
    background: #fff;
    color: var(--main-nav-bg-color);
}

.mobile-nav-header-btn--offer:hover {
    background: #fff;
    color: var(--main-nav-bg-color);
    filter: brightness(0.96);
}

.mobile-nav-drawer-close:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: rotate(90deg);
}

.mobile-nav-drawer-body {
    flex: 1 1 auto;
    overflow-y: auto;
    padding: 16px 14px 20px;
    background:
        radial-gradient(120% 60% at 100% 0%, color-mix(in srgb, var(--btn-primary-bg-color) 7%, #fff) 0%, transparent 60%),
        #fff;
}

/* Custom scrollbar */
.mobile-nav-drawer-body::-webkit-scrollbar {
    width: 6px;
}

.mobile-nav-drawer-body::-webkit-scrollbar-thumb {
    background: #d7dae1;
    border-radius: 50rem;
}

/* Welcome / account card */
.mobile-nav-welcome {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px;
    border-radius: 18px;
    background: color-mix(in srgb, var(--btn-primary-bg-color) 9%, #fff);
    box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--btn-primary-bg-color) 16%, #fff);
    margin-bottom: 14px;
}

.mobile-nav-avatar {
    flex: 0 0 auto;
    width: 46px;
    height: 46px;
    border-radius: 14px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--btn-primary-bg-color), color-mix(in srgb, var(--btn-primary-bg-color) 70%, #000));
    color: var(--btn-primary-text-color);
    font-size: 1.25rem;
    font-weight: 700;
    text-transform: uppercase;
}

.mobile-nav-welcome-text {
    display: flex;
    flex-direction: column;
    line-height: 1.25;
    min-width: 0;
}

.mobile-nav-welcome-text small {
    color: #8a90a0;
    font-size: 0.72rem;
}

.mobile-nav-welcome-text strong {
    color: #1f2430;
    font-size: 0.98rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.mobile-nav-welcome-btn {
    margin-left: auto;
    flex: 0 0 auto;
    border: none;
    border-radius: 50rem;
    padding: 8px 16px;
    background: var(--btn-primary-bg-color);
    color: var(--btn-primary-text-color);
    font-size: 0.82rem;
    font-weight: 700;
    cursor: pointer;
    transition: transform 0.15s ease, filter 0.15s ease;
}

.mobile-nav-welcome-btn:hover {
    filter: brightness(1.05);
}

.mobile-nav-welcome-btn:active {
    transform: scale(0.96);
}

/* Nav list */
.mobile-nav-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.mobile-nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    width: 100%;
    padding: 9px 12px;
    border: none;
    border-radius: 12px;
    background: transparent;
    color: #1f2430;
    font-size: 0.92rem;
    font-weight: 600;
    text-decoration: none;
    text-align: left;
    cursor: pointer;
    transition: background 0.18s ease, color 0.18s ease, transform 0.18s ease;
}

.mobile-nav-item:hover,
.mobile-nav-item.active {
    background: color-mix(in srgb, var(--btn-primary-bg-color) 10%, #fff);
    color: var(--btn-primary-bg-color);
}

.mobile-nav-item:active {
    transform: scale(0.98);
}

.mobile-nav-ic {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    flex: 0 0 auto;
    border-radius: 10px;
    background: color-mix(in srgb, var(--btn-primary-bg-color) 13%, #fff);
    color: var(--btn-primary-bg-color);
    font-size: 1rem;
    transition: background 0.2s ease, color 0.2s ease, box-shadow 0.2s ease;
}

.mobile-nav-item:hover .mobile-nav-ic {
    background: var(--btn-primary-bg-color);
    color: var(--btn-primary-text-color);
    box-shadow: 0 4px 10px color-mix(in srgb, var(--btn-primary-bg-color) 40%, transparent);
}

.mobile-nav-label {
    flex: 0 1 auto;
}

.mobile-nav-arrow {
    margin-left: auto;
    color: #c2c7d0;
    font-size: 0.85rem;
    transition: transform 0.18s ease, color 0.18s ease;
}

.mobile-nav-item:hover .mobile-nav-arrow {
    color: var(--btn-primary-bg-color);
    transform: translateX(3px);
}

.mobile-nav-chevron {
    margin-left: auto;
    color: #c2c7d0;
    transition: transform 0.25s ease, color 0.25s ease;
}

.mobile-nav-chevron.rotate-180 {
    transform: rotate(180deg);
    color: var(--btn-primary-bg-color);
}

/* Collapsible sub-list */
.mobile-nav-sublist {
    list-style: none;
    margin: 4px 0 6px 14px;
    padding: 4px 0 4px 12px;
    border-left: 2px solid color-mix(in srgb, var(--btn-primary-bg-color) 25%, #fff);
}

.mobile-nav-subitem {
    display: flex;
    align-items: center;
    gap: 9px;
    padding: 8px 10px;
    border-radius: 10px;
    color: #4a5160;
    font-size: 0.86rem;
    font-weight: 500;
    text-decoration: none;
    transition: background 0.18s ease, color 0.18s ease;
}

.mobile-nav-subitem:hover {
    background: color-mix(in srgb, var(--btn-primary-bg-color) 8%, #fff);
    color: var(--btn-primary-bg-color);
}

/* Social links */
.mobile-nav-socials {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    padding: 4px 2px 2px;
}

.mobile-nav-social {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: color-mix(in srgb, var(--btn-primary-bg-color) 10%, #fff);
    color: var(--btn-primary-bg-color);
    font-size: 1.05rem;
    text-decoration: none;
    transition: background 0.18s ease, color 0.18s ease, transform 0.18s ease;
}

.mobile-nav-social:hover {
    background: var(--btn-primary-bg-color);
    color: var(--btn-primary-text-color);
    transform: translateY(-2px);
}

.mobile-nav-subdot {
    width: 6px;
    height: 6px;
    flex: 0 0 auto;
    border-radius: 50%;
    background: var(--btn-primary-bg-color);
    opacity: 0.55;
}

/* Group label */
.mobile-nav-group-label {
    margin: 4px 6px 8px;
    font-size: 0.7rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #a3a9b5;
}

.mobile-nav-divider {
    height: 1px;
    margin: 14px 6px;
    background: linear-gradient(90deg, transparent, #eceef2 30%, #eceef2 70%, transparent);
}

/* Footer hotline & language */
.mobile-nav-drawer-footer {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 14px calc(12px + env(safe-area-inset-bottom));
    border-top: 1px solid #eceef2;
    background: #fff;
}

.mobile-nav-drawer-footer .mobile-nav-hotline {
    flex: 1 1 auto;
    min-width: 0;
    gap: 8px;
    padding: 8px 10px;
    margin: 0;
}

.mobile-nav-drawer-footer .mobile-nav-hotline-ic {
    width: 36px;
    height: 36px;
    font-size: 1rem;
    border-radius: 10px;
}

.mobile-nav-drawer-footer .mobile-nav-hotline-text strong {
    font-size: 0.85rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.mobile-nav-drawer-footer .mobile-nav-hotline-call {
    display: none;
}

/* Drawer Language Switcher */
.mobile-drawer-lang {
    position: relative;
    flex-shrink: 0;
}

.mobile-drawer-lang-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    height: 52px;
    padding: 0 14px;
    border-radius: 16px;
    border: none;
    background: color-mix(in srgb, var(--btn-primary-bg-color) 8%, #fff);
    box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--btn-primary-bg-color) 14%, #fff);
    color: #1f2430;
    font-size: 0.84rem;
    font-weight: 700;
    text-decoration: none;
    transition: background 0.2s ease, box-shadow 0.2s ease;
    cursor: pointer;
    white-space: nowrap;
}

.mobile-drawer-lang-btn:hover,
.mobile-drawer-lang-btn:focus,
.mobile-drawer-lang.show .mobile-drawer-lang-btn {
    background: color-mix(in srgb, var(--btn-primary-bg-color) 14%, #fff);
    box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--btn-primary-bg-color) 20%, #fff);
    color: #1f2430;
    outline: none;
}

.dropup.mobile-drawer-lang .ecom-lang-menu {
    margin-bottom: 0.4rem !important;
    margin-top: 0 !important;
    min-width: 140px;
}

.mobile-drawer-lang-btn .bi-translate {
    font-size: 1rem;
    color: var(--btn-primary-bg-color);
}

.mobile-drawer-lang-btn.dropdown-toggle::after {
    margin-left: 2px;
    vertical-align: middle;
    font-size: 0.65rem;
    color: var(--btn-primary-bg-color);
    opacity: 0.75;
}

.mobile-nav-hotline {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 14px;
    border-radius: 16px;
    background: color-mix(in srgb, var(--btn-primary-bg-color) 8%, #fff);
    box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--btn-primary-bg-color) 14%, #fff);
    color: #1f2430;
    text-decoration: none;
    transition: background 0.2s ease;
}

.mobile-nav-hotline:hover {
    background: color-mix(in srgb, var(--btn-primary-bg-color) 14%, #fff);
}

.mobile-nav-hotline-ic {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    flex: 0 0 auto;
    border-radius: 12px;
    background: var(--btn-primary-bg-color);
    color: var(--btn-primary-text-color);
    font-size: 1.15rem;
}

.mobile-nav-hotline-text {
    display: flex;
    flex-direction: column;
    line-height: 1.2;
}

.mobile-nav-hotline-text small {
    color: #8a90a0;
}

.mobile-nav-hotline-text strong {
    font-size: 1rem;
}

.mobile-nav-hotline-call {
    margin-left: auto;
    color: var(--btn-primary-bg-color);
    font-size: 1.05rem;
}

.nav-cart-badge {
    position: absolute;
    top: -5px;
    right: -6px;
    min-width: 18px;
    height: 18px;
    padding: 0 4px;
    border-radius: 50rem;
    background: var(--btn-primary-bg-color);
    color: var(--btn-primary-text-color);
    font-size: 0.62rem;
    font-weight: 800;
    line-height: 18px;
    text-align: center;
    box-shadow: 0 0 0 2px var(--main-nav-bg-color, #1a1a2e);
    pointer-events: none;
}

/* ── Desktop Cart Button ── */
.nav-cart-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    padding: 0.4rem 1rem 0.4rem 0.4rem;
    border: 1.5px solid rgba(255, 255, 255, 0.22);
    border-radius: 50rem;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(6px);
    color: #fff;
    cursor: pointer;
    transition: background 0.2s ease, border-color 0.2s ease;
    white-space: nowrap;
    line-height: 1;
}

.nav-cart-btn:hover {
    background: rgba(255, 255, 255, 0.2);
    border-color: rgba(255, 255, 255, 0.5);
    color: #fff;
}

.nav-cart-icon-wrap {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: var(--btn-primary-bg-color);
    color: var(--btn-primary-text-color);
    font-size: 0.95rem;
    flex-shrink: 0;
}

.nav-cart-label {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 1px;
    white-space: nowrap;
}

.nav-cart-label-top {
    display: block;
    text-align: left;
    font-size: 0.7rem;
    font-weight: 500;
    opacity: 0.75;
    line-height: 1;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

.nav-cart-label-price {
    display: block;
    text-align: left;
    font-size: 0.84rem;
    font-weight: 700;
    line-height: 1;
    white-space: nowrap;
}

/* Cart update shake animation */
@keyframes cart-shake {

    0%,
    100% {
        transform: translateX(0) rotate(0);
    }

    15% {
        transform: translateX(-4px) rotate(-7deg);
    }

    30% {
        transform: translateX(4px) rotate(7deg);
    }

    45% {
        transform: translateX(-3px) rotate(-5deg);
    }

    60% {
        transform: translateX(3px) rotate(5deg);
    }

    75% {
        transform: translateX(-2px) rotate(-2deg);
    }

    90% {
        transform: translateX(1px) rotate(1deg);
    }
}

.cart-shake {
    animation: cart-shake 0.55s ease-in-out;
}


/* ── Mobile Search Drawer ── */
.mobile-search-drawer {
    padding: 8px 0 10px;
    border-top: 1px solid rgba(255, 255, 255, 0.12);
    margin-top: 4px;
}

/* Slimmer "Go" button in the mobile drawer */
.mobile-search-drawer .nav-search-btn {
    min-width: auto;
    padding: 0 1.5rem;
    border-radius: 0 50rem 50rem 0;
}

/* Brand-colored spinner inside the leading search icon */
.mobile-search-drawer .nav-search-spinner {
    border-top-color: var(--btn-primary-bg-color);
}

.mobile-search-drawer .nav-search-icon {
    min-width: 40px;
    justify-content: center;
}

/* ── Dropdown Menu ── */
.dropdown-menu.ecom-dropdown {
    border: 1px solid rgba(0, 0, 0, 0.07);
    border-radius: 14px;
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.14);
    padding: 0.3rem 0 0.4rem;
    margin-top: 0.5rem;
    min-width: 220px;
    overflow: hidden;
    animation: ecom-dropdown-in 0.18s ease;
}

@keyframes ecom-dropdown-in {
    from {
        opacity: 0;
        transform: translateY(-6px) scale(0.98);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

/* ── Profile header (clickable → dashboard) ── */
.ecom-dropdown-profile-link {
    display: block;
    text-decoration: none;
    color: inherit;
    border-radius: 13px 13px 0 0;
    transition: background 0.15s ease;
}

.ecom-dropdown-profile-link:hover .ecom-dropdown-header {
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.06), rgba(0, 0, 0, 0.03));
}

.ecom-dropdown-header {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 14px 10px;
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.03), rgba(0, 0, 0, 0.01));
    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
    user-select: none;
}

.ecom-dropdown-avatar {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--btn-primary-bg-color, #e63c6d), var(--btn-primary-hover-bg-color, #c0305a));
    color: #fff;
    font-size: 0.85rem;
    font-weight: 800;
    flex-shrink: 0;
    letter-spacing: 0;
}

.ecom-dashboard-avatar {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--btn-primary-bg-color, #e63c6d), var(--btn-primary-hover-bg-color, #c0305a));
    color: #fff;
    font-size: 1.5rem;
    font-weight: 800;
    flex-shrink: 0;
}

.ecom-dropdown-info {
    min-width: 0;
}

.ecom-dropdown-name {
    font-size: 0.87rem;
    font-weight: 700;
    color: #1a1a2e;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    line-height: 1.3;
}

.ecom-dropdown-email {
    font-size: 0.73rem;
    color: #aaa;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    line-height: 1.4;
}

.ecom-dropdown-phone {
    font-size: 0.73rem;
    color: #6c757d;
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    line-height: 1.4;
}

/* ── Dropdown items ── */
.dropdown-menu.ecom-dropdown .dropdown-item {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    padding: 0.52rem 1rem;
    font-size: 0.86rem;
    font-weight: 500;
    color: #333;
    transition: background 0.15s ease, padding-left 0.15s ease;
    border-radius: 0;
}

.dropdown-menu.ecom-dropdown .dropdown-item .bi {
    display: inline-block;
    width: 16px;
    text-align: center;
    font-size: 0.92rem;
    color: #aaa;
    flex-shrink: 0;
    transition: color 0.15s ease;
}

.dropdown-menu.ecom-dropdown .dropdown-item:hover {
    background: rgba(0, 0, 0, 0.05);
    color: var(--primary-link-hover, #212121);
}

.dropdown-menu.ecom-dropdown .dropdown-item:hover .bi {
    color: var(--primary-link-hover, #212121);
}

/* ── Logout item ── */
.dropdown-menu.ecom-dropdown .ecom-dropdown-logout {
    color: #dc3545;
}

.dropdown-menu.ecom-dropdown .ecom-dropdown-logout .bi {
    color: #dc3545;
}

.dropdown-menu.ecom-dropdown .ecom-dropdown-logout:hover {
    background: rgba(220, 53, 69, 0.06);
    color: #b02a37;
    padding-left: 1.25rem;
}

.dropdown-menu.ecom-dropdown .ecom-dropdown-logout:hover .bi {
    color: #b02a37;
}

/* ── Main Content Area Spacing ── */
.main-content {
    padding-top: 0.25rem;
}

/* ── Sub Navigation Strip ── */
.main-navbar .sub-nav {
    background-color: var(--sub-nav-bg-color);
    padding: 0;
    min-height: 44px;
}

.main-navbar .sub-nav .nav-link {
    position: relative;
    color: var(--sub-nav-text-color);
    font-weight: 500;
    font-size: 0.875rem;
    padding: 0.7rem 1rem;
    white-space: nowrap;
    transition: color 0.2s ease;
}

/* ── Category Mega Menu Viewer Styling ── */
.cat-nav-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    padding: 0.45rem 1rem;
    border-radius: 6px;
    background: rgba(0, 0, 0, 0.04);
    color: var(--sub-nav-text-color, #212529);
    font-weight: 600;
    font-size: 0.88rem;
    text-decoration: none;
    border: 1px solid rgba(0, 0, 0, 0.08);
    transition: var(--ecom-transition-fast);
    line-height: 1.4;
}

.cat-nav-btn:hover {
    background: rgba(0, 0, 0, 0.08);
    color: var(--primary-link-hover, #212121);
    border-color: rgba(0, 0, 0, 0.15);
}

.cat-menu-dropdown {
    min-width: 260px;
    border-radius: 12px !important;
    box-shadow: 0 16px 45px rgba(0, 0, 0, 0.13) !important;
    border: 1px solid rgba(0, 0, 0, 0.08) !important;
    background: #ffffff !important;
    margin-top: 6px;
    padding: 8px !important;
}

/* Invisible Top Hover Safe Bridge for Main Category Dropdown */
.cat-menu-dropdown::before {
    content: '';
    position: absolute;
    top: -12px;
    left: 0;
    right: 0;
    height: 14px;
    background: transparent;
    z-index: 1061;
}

.cat-menu-item {
    border: none !important;
    border-radius: 8px !important;
    padding: 0 !important;
    margin-bottom: 2px;
    transition: background 0.15s ease;
}

.cat-menu-link {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 9px 12px;
    border-radius: 8px;
    color: #2b2f38;
    text-decoration: none;
    font-weight: 500;
    font-size: 0.88rem;
    transition: all 0.18s cubic-bezier(0.4, 0, 0.2, 1);
}

.cat-menu-link:hover,
.cat-menu-item.is-active .cat-menu-link {
    background: rgba(0, 0, 0, 0.05);
    color: var(--primary-link-hover, #212121);
}

.cat-menu-link .bi-chevron-right {
    transition: transform 0.2s ease, color 0.2s ease;
}

.cat-menu-link:hover .bi-chevron-right {
    transform: translateX(2px);
    color: var(--primary-link-hover, #212121) !important;
}

.cat-badge-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 2px 7px;
    font-size: 0.68rem;
    font-weight: 700;
    border-radius: 50rem;
    background: rgba(0, 0, 0, 0.05);
    color: #6c757d;
    margin-left: 6px;
    transition: all 0.15s ease;
}

.cat-menu-link:hover .cat-badge-count {
    background: var(--primary-bg-color, #0d6efd);
    color: #ffffff;
}

.cat-flyout-panel {
    width: 760px;
    min-height: 480px;
    max-height: 750px;
    overflow-y: auto;
    left: 100%;
    top: -8px;
    margin-left: 2px;
    border-radius: 14px !important;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.15) !important;
    border: 1px solid rgba(0, 0, 0, 0.08) !important;
    background: #ffffff !important;
    z-index: 1060;
    position: absolute;
    scrollbar-width: none;
    /* Firefox */
    -ms-overflow-style: none;
    /* IE & Edge */
}

/* Hide scrollbar completely across Webkit browsers */
.cat-flyout-panel::-webkit-scrollbar,
.cat-menu-dropdown::-webkit-scrollbar {
    display: none !important;
    width: 0 !important;
    height: 0 !important;
}

/* Invisible Hover Safe Area Bridge to prevent panel hiding on accidental mouse movement */
.cat-flyout-panel::before {
    content: '';
    position: absolute;
    top: -10px;
    bottom: -10px;
    left: -25px;
    width: 30px;
    background: transparent;
    z-index: 1061;
}

.cat-sub-card {
    background: #f8f9fa;
    border-radius: 10px;
    padding: 12px 14px;
    height: 100%;
    border: 1px solid rgba(0, 0, 0, 0.04);
    border-top: 3px solid var(--primary-bg-color, #0d6efd);
    transition: all 0.2s ease;
}

.cat-sub-card:hover {
    background: #ffffff;
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.07);
    border-color: rgba(0, 0, 0, 0.08);
    border-top-color: var(--btn-primary-bg-color, #ffc376);
}

.cat-sub-title {
    font-weight: 700;
    font-size: 0.92rem;
    color: #1a1a2e;
    text-decoration: none;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-bottom: 6px;
    margin-bottom: 8px;
    border-bottom: 1px dashed rgba(0, 0, 0, 0.1);
    transition: color 0.15s ease;
}

.cat-sub-title:hover {
    color: var(--primary-link-hover, #212121);
}

.cat-child-link {
    display: inline-flex;
    align-items: center;
    padding: 4px 8px;
    border-radius: 6px;
    color: #555963;
    text-decoration: none;
    font-size: 0.82rem;
    font-weight: 500;
    width: 100%;
    transition: background 0.15s ease, color 0.15s ease;
}

.cat-child-link:hover {
    background: rgba(0, 0, 0, 0.05);
    color: var(--primary-link-hover, #212121);
}

.main-navbar .sub-nav .nav-link {
    font-weight: 600;
    transition: color 0.15s ease;
}

.main-navbar .sub-nav .nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%) scaleX(0);
    width: 70%;
    height: 2px;
    background: var(--primary-link-hover, #212121);
    border-radius: 2px 2px 0 0;
    transition: transform 0.22s ease;
}

.main-navbar .sub-nav .nav-link:hover,
.main-navbar .sub-nav .nav-link.active {
    color: var(--primary-link-hover, #212121);
}

.main-navbar .sub-nav .nav-link:hover::after,
.main-navbar .sub-nav .nav-link.active::after {
    transform: translateX(-50%) scaleX(1);
}

/* ── Sub-nav Hotline ── */
.sub-nav-hotline {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.83rem;
    font-weight: 600;
    color: var(--sub-nav-text-color);
    text-decoration: none;
    padding: 0.4rem 0.75rem;
    border-radius: 50rem;
    border: 1px solid rgba(0, 0, 0, 0.1);
    transition: var(--ecom-transition-fast);
    white-space: nowrap;
}

.sub-nav-hotline:hover {
    background: rgba(0, 0, 0, 0.08);
    color: var(--primary-link-hover, #212121);
}

/* ── Sub-nav Language Dropdown (Desktop) ── */
.sub-nav-lang-dropdown {
    position: relative;
}

.sub-nav-lang-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.83rem;
    font-weight: 600;
    color: var(--sub-nav-text-color);
    background: transparent;
    text-decoration: none;
    padding: 0.4rem 0.75rem;
    border-radius: 50rem;
    border: 1px solid rgba(0, 0, 0, 0.1);
    transition: var(--ecom-transition-fast);
    white-space: nowrap;
    cursor: pointer;
}

.sub-nav-lang-btn:hover,
.sub-nav-lang-btn:focus,
.sub-nav-lang-dropdown.show .sub-nav-lang-btn {
    background: rgba(0, 0, 0, 0.08);
    color: var(--primary-link-hover, #212121);
    border-color: rgba(0, 0, 0, 0.15);
}

.sub-nav-lang-btn.dropdown-toggle::after {
    margin-left: 0.25rem;
    vertical-align: middle;
    font-size: 0.7rem;
}

.ecom-lang-menu {
    border-radius: 12px;
    border: 1px solid rgba(0, 0, 0, 0.08);
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
    padding: 0.4rem;
    min-width: 140px;
    margin-top: 0.35rem !important;
}

.ecom-lang-menu .dropdown-item {
    padding: 0.45rem 0.75rem;
    border-radius: 8px;
    font-size: 0.84rem;
    font-weight: 500;
    color: #333;
    transition: var(--ecom-transition-fast);
}

.ecom-lang-menu .dropdown-item:hover {
    background: rgba(0, 0, 0, 0.05);
    color: #000;
}

.ecom-lang-menu .dropdown-item.active {
    background: rgba(0, 0, 0, 0.06);
    color: var(--primary-link-hover, #111);
    font-weight: 700;
}

.ecom-lang-menu .lang-flag {
    font-size: 1rem;
    line-height: 1;
}

/* ── Mobile Language Dropdown (Top Header) ── */
.mobile-lang-dropdown {
    position: relative;
}

.mobile-lang-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    height: 36px;
    padding: 0 0.65rem;
    border: none;
    border-radius: 50rem;
    background: rgba(255, 255, 255, 0.18);
    color: var(--main-nav-text-color);
    font-size: 0.78rem;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.2s ease;
    white-space: nowrap;
}

.mobile-lang-btn:hover,
.mobile-lang-btn:focus,
.mobile-lang-dropdown.show .mobile-lang-btn {
    background: rgba(255, 255, 255, 0.32);
    color: var(--main-nav-text-color);
    outline: none;
}

.mobile-lang-btn .bi {
    font-size: 0.85rem;
}

.mobile-lang-btn.dropdown-toggle::after {
    margin-left: 0.15rem;
    vertical-align: middle;
    font-size: 0.65rem;
}

/* ── Modern Premium Hero Slider Styling ── */
.hero-slider-wrapper {
    position: relative;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
    border: 1px solid rgba(0, 0, 0, 0.06);
    background: transparent;
}

.hero-slider-wrapper .carousel-inner,
.hero-slider-wrapper .carousel-item {
    height: 100%;
}

.hero-slider-img {
    width: 100%;
    height: auto;
    display: block;
}

.hero-slider-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.88);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    color: #1e293b;
    border: 1px solid rgba(255, 255, 255, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.12);
    z-index: 10;
    transition: all 0.25s ease;
    opacity: 0;
    visibility: hidden;
}

.hero-slider-wrapper:hover .hero-slider-btn {
    opacity: 0.9;
    visibility: visible;
}

.hero-slider-btn:hover {
    background: var(--main-nav-bg-color, var(--primary-bg-color, #e74079));
    color: var(--main-nav-text-color, #ffffff);
    border-color: var(--main-nav-bg-color, var(--primary-bg-color, #e74079));
    transform: translateY(-50%) scale(1.08);
    opacity: 1;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.2);
}

.hero-slider-btn.prev-btn {
    left: 1rem;
}

.hero-slider-btn.next-btn {
    right: 1rem;
}

.hero-slider-indicators {
    bottom: 1rem;
    margin-bottom: 0;
    gap: 8px;
}

.hero-slider-indicators [data-bs-target] {
    width: 10px;
    height: 10px;
    border-radius: 20px;
    background-color: rgba(255, 255, 255, 0.6);
    border: none;
    opacity: 0.7;
    margin: 0;
    transition: all 0.3s ease;
}

.hero-slider-indicators .active {
    width: 28px;
    background-color: var(--main-nav-bg-color, var(--primary-bg-color, #e74079));
    opacity: 1;
    border-radius: 20px;
}

/* ── Iconic Facebook-Style Content Skeleton Loader ── */
@keyframes fb-shimmer {
    0% {
        background-position: -468px 0;
    }

    100% {
        background-position: 468px 0;
    }
}

.fb-skeleton-card {
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid rgba(0, 0, 0, 0.05);
    background: #ffffff;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.03);
    padding: 0.75rem;
    display: flex;
    flex-direction: column;
    aspect-ratio: 1 / 1;
    justify-content: space-between;
}

.fb-skeleton-line {
    background: #f0f2f5;
    background-image: linear-gradient(90deg,
            #f0f2f5 0%,
            #e4e6eb 20%,
            #f0f2f5 40%,
            #f0f2f5 100%);
    background-repeat: no-repeat;
    background-size: 800px 100%;
    animation: fb-shimmer 1.2s linear infinite forwards;
    border-radius: 6px;
}

.fb-skeleton-img {
    width: 100%;
    height: 60%;
    border-radius: 8px;
}

.fb-skeleton-title {
    width: 85%;
    height: 12px;
    border-radius: 4px;
}

.fb-skeleton-subtitle {
    width: 55%;
    height: 10px;
    border-radius: 4px;
}

.quick-carousel-card {
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid rgba(0, 0, 0, 0.06);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.04);
    transition: all 0.25s ease;
    display: block;
    aspect-ratio: 1 / 1;
    background-color: #f8fafc;
}

.quick-carousel-card img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
}

.quick-carousel-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.08);
}

/* ==========================================================================
   4.8. Promotional Banners (Mid-Page Highlights)
   ========================================================================== */
.promo-banner-wrapper {
    margin-top: 1.5rem;
    margin-bottom: 1.5rem;
}

.promo-banner-card {
    position: relative;
    display: block;
    width: 100%;
    border-radius: 12px;
    overflow: hidden;
    background-color: #f1f5f9;
    border: 1px solid rgba(0, 0, 0, 0.06);
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.05);
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1), box-shadow 0.3s ease;
    text-decoration: none;
}

.promo-banner-card .promo-banner-img {
    width: 100%;
    height: auto;
    aspect-ratio: 800 / 300;
    max-height: 300px;
    object-fit: cover;
    object-position: center;
    display: block;
    transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.promo-banner-card.promo-banner-single .promo-banner-img {
    aspect-ratio: 1600 / 300;
    max-height: 300px;
}

.promo-banner-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

.promo-banner-card:hover .promo-banner-img {
    transform: scale(1.02);
}

@media (max-width: 575.98px) {
    .promo-banner-card {
        border-radius: 8px;
    }
}

/* ==========================================================================
   4.9. Custom Collection Split Showcase (Hero + Carousel)
   ========================================================================== */
.custom-collection-container {
    position: relative;
}

.custom-collection-hero {
    min-height: 380px;
    background: linear-gradient(135deg, #1e293b 0%, #0f172a 100%);
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.custom-collection-hero:hover {
    transform: translateY(-2px);
    box-shadow: 0 16px 36px rgba(0, 0, 0, 0.14);
}

.custom-collection-hero-bg {
    transition: transform 0.8s cubic-bezier(0.4, 0, 0.2, 1);
    filter: brightness(0.85);
}

.custom-collection-hero:hover .custom-collection-hero-bg {
    transform: scale(1.04);
}

.custom-collection-hero-overlay {
    background: linear-gradient(180deg, rgba(15, 23, 42, 0.35) 0%, rgba(15, 23, 42, 0.75) 50%, rgba(15, 23, 42, 0.94) 100%);
    pointer-events: none;
}

.custom-collection-badge {
    background-color: var(--main-nav-bg-color, #e74079);
    color: #ffffff;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
    letter-spacing: 0.02em;
    font-size: 0.75rem;
}

.custom-collection-title {
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.4);
    letter-spacing: -0.01em;
}

.btn-collection-explore {
    background-color: var(--main-nav-bg-color, #e74079);
    border: 1px solid rgba(255, 255, 255, 0.2);
    font-size: 0.85rem;
    transition: all 0.25s ease;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.2);
}

.btn-collection-explore:hover {
    background-color: #ffffff;
    color: #0f172a !important;
    transform: translateX(2px);
    box-shadow: 0 6px 18px rgba(255, 255, 255, 0.25);
}

.btn-collection-explore:hover .explore-arrow {
    transform: translateX(4px);
}

.explore-arrow {
    transition: transform 0.2s ease;
}

.custom-col-arrow-btn {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, 0.3);
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(4px);
    color: #ffffff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.85rem;
    cursor: pointer;
    transition: all 0.2s ease;
}

.custom-col-arrow-btn:hover:not(:disabled) {
    background: var(--main-nav-bg-color, #e74079);
    border-color: var(--main-nav-bg-color, #e74079);
    color: #ffffff;
    transform: scale(1.08);
}

.custom-col-arrow-btn:disabled {
    opacity: 0.35;
    cursor: not-allowed;
}

.custom-collection-carousel-track {
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    padding-top: 6px;
    padding-bottom: 12px;
    padding-left: 2px;
    padding-right: 18px;
    scroll-padding-right: 16px;
}

.custom-collection-carousel-track::-webkit-scrollbar {
    display: none;
}

.custom-collection-product-item {
    width: 220px;
    min-width: 220px;
    max-width: 220px;
}

.custom-collection-product-item:last-of-type {
    margin-right: 8px;
}

.collection-product-card-wrapper {
    width: 100%;
    height: 100%;
}

.collection-product-card {
    transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
    border-color: #e2e8f0 !important;
}

.collection-product-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.08) !important;
    border-color: var(--main-nav-bg-color, #e74079) !important;
}

.collection-product-img-box {
    aspect-ratio: 1 / 1;
    width: 100%;
}

.collection-product-img {
    transition: transform 0.5s ease;
}

.collection-product-card:hover .collection-product-img {
    transform: scale(1.05);
}

.collection-product-title {
    font-size: 0.9rem;
    line-height: 1.35;
    transition: color 0.2s ease;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    height: 2.7em;
}

.collection-product-title:hover {
    color: var(--main-nav-bg-color, #e74079) !important;
}

.collection-action-btn {
    height: 30px !important;
    min-height: 30px !important;
    max-height: 30px !important;
    padding: 0 8px !important;
    font-size: 0.75rem !important;
    font-weight: 600 !important;
    line-height: 1 !important;
    border-radius: 6px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 4px !important;
    transition: all 0.2s ease;
}

.collection-action-btn i {
    font-size: 0.8rem;
    line-height: 1;
}

.collection-action-btn .spinner-border {
    width: 0.75rem;
    height: 0.75rem;
    border-width: 0.12em;
}

@media (max-width: 991.98px) {
    .custom-collection-hero {
        min-height: 220px;
    }

    .custom-collection-product-item {
        width: 195px;
        min-width: 195px;
    }

    .custom-col-arrow-btn {
        background: #f1f5f9;
        color: #334155;
        border-color: #cbd5e1;
    }

    .collection-product-title {
        font-size: 0.825rem;
    }
}

@media (max-width: 575.98px) {
    .custom-collection-hero {
        min-height: 180px;
        padding: 1.25rem !important;
    }

    .custom-collection-product-item {
        width: 170px;
        min-width: 170px;
    }

    .collection-product-title {
        font-size: 0.8rem;
    }
}

/* ==========================================================================
   4.10. Home Blog / Clean Minimalist Editorial Section
   ========================================================================== */
.home-blog-clean-card {
    border: 1px solid #e2e8f0 !important;
    background: #ffffff;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.03) !important;
    transition: box-shadow 0.3s ease;
}

.home-blog-clean-card:hover {
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.06) !important;
}

.home-blog-pill-badge {
    background-color: #f1f5f9;
    color: var(--main-nav-bg-color, #e74079);
    border: 1px solid #e2e8f0;
    font-size: 0.78rem;
    letter-spacing: 0.2px;
}

.home-blog-clean-title,
.home-blog-seo-title {
    color: #0f172a;
    letter-spacing: -0.015em;
    line-height: 1.35;
}

.home-blog-content {
    font-size: 0.95rem;
    color: #475569;
    transition: max-height 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.home-blog-content.home-blog-clamped {
    max-height: 260px;
    overflow: hidden;
}

.home-blog-fade-overlay {
    height: 100px;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0) 0%, rgba(255, 255, 255, 0.95) 80%, #ffffff 100%);
    pointer-events: none;
}

.btn-clean-expand {
    background-color: #ffffff;
    color: #334155;
    border: 1px solid #cbd5e1;
    font-size: 0.85rem;
    transition: all 0.25s ease;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.04);
}

.btn-clean-expand:hover {
    background-color: var(--main-nav-bg-color, #e74079);
    color: #ffffff;
    border-color: var(--main-nav-bg-color, #e74079);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(231, 64, 121, 0.25);
}

.home-blog-content p {
    margin-bottom: 1.15rem;
    line-height: 1.85;
}

.home-blog-content p:last-child {
    margin-bottom: 0;
}

.home-blog-content h1,
.home-blog-content h2,
.home-blog-content h3,
.home-blog-content h4,
.home-blog-content h5,
.home-blog-content h6 {
    color: #0f172a;
    font-weight: 700;
    margin-top: 1.5rem;
    margin-bottom: 0.75rem;
    letter-spacing: -0.01em;
}

.home-blog-content h1:first-child,
.home-blog-content h2:first-child,
.home-blog-content h3:first-child,
.home-blog-content h4:first-child {
    margin-top: 0;
}

.home-blog-content blockquote {
    border-left: 3px solid var(--main-nav-bg-color, #e74079);
    background: #f8fafc;
    padding: 0.875rem 1.25rem;
    margin: 1.25rem 0;
    border-radius: 0 6px 6px 0;
    font-style: italic;
    color: #334155;
}

.home-blog-content a {
    color: var(--main-nav-bg-color, #e74079);
    text-decoration: underline;
    text-underline-offset: 3px;
    font-weight: 500;
}

.home-blog-content a:hover {
    color: var(--theme-color-dark, #c02d60);
}

.home-blog-content img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    margin: 1rem 0;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

.home-blog-content ul,
.home-blog-content ol {
    padding-left: 1.5rem;
    margin-bottom: 1.15rem;
}

.home-blog-content li {
    margin-bottom: 0.5rem;
    line-height: 1.75;
}


/* ==========================================================================
   5. Footer & Mobile Navigation Architecture
   ========================================================================== */
.footer-section {
    background-color: var(--footer-section-bg-color, #dddddd);
    color: var(--footer-section-text-color, #212529);
}

.footer-heading {
    color: var(--footer-section-text-color, #212529);
    font-weight: 700;
}

.footer-nav-links a {
    color: var(--footer-section-text-color, #212529);
    text-decoration: none;
    font-size: 0.88rem;
    font-weight: 500;
    transition: color 0.15s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
}

.footer-nav-links a i {
    font-size: 0.72rem;
    transition: color 0.15s ease;
    color: rgba(33, 37, 41, 0.5);
}

.footer-nav-links a:hover {
    color: var(--primary-link-hover, #212121) !important;
}

.footer-nav-links a:hover i {
    color: var(--primary-link-hover, #212121) !important;
}

.footer-social-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background-color: rgba(0, 0, 0, 0.06);
    color: var(--footer-section-text-color, #212529);
    text-decoration: none;
    transition: all 0.22s ease-in-out;
}

.footer-social-btn:hover {
    background-color: var(--primary-bg-color, #ffc376);
    color: var(--primary-fg-color, #212529);
    transform: translateY(-3px);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
}

.footer-bottom-bar a {
    color: var(--footer-section-text-color, #212529);
    transition: color 0.2s ease;
}

.footer-bottom-bar a:hover {
    color: var(--primary-link-hover, #212121) !important;
    text-decoration: underline !important;
}

.mobile-bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    height: var(--mobile-nav-height);
    background-color: #ffffff;
    border-top: 1px solid var(--ecom-border-color);
    box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.08);
    display: flex;
    justify-content: space-evenly;
    align-items: center;
    z-index: 1045;
    padding: 4px 0;
}

.mobile-bottom-nav-item {
    display: flex;
    flex: 1 1 0;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-width: 0;
    color: #6c757d;
    text-decoration: none;
    font-size: 0.72rem;
    font-weight: 500;
    background: transparent;
    border: none;
    padding: 2px 0;
    position: relative;
    transition: var(--ecom-transition-fast);
}

.mobile-bottom-nav-item i {
    font-size: 1.25rem;
    margin-bottom: 2px;
}

.mobile-bottom-nav-item.active,
.mobile-bottom-nav-item:hover {
    color: var(--main-nav-bg-color);
}

/* Special design for the cart button — elevated circular FAB */
.mobile-bottom-nav-cart {
    margin-top: calc(var(--mobile-nav-height) * -0.30);
}

.mobile-bottom-nav-cart .nav-icon-btn {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    background: linear-gradient(145deg, var(--btn-primary-bg-color), var(--btn-primary-hover-bg-color, var(--btn-primary-bg-color)));
    color: var(--btn-primary-text-color);
    font-size: 1.4rem;
    border: 2px solid #ffffff;
    box-shadow:
        0 6px 16px rgba(0, 0, 0, 0.22),
        0 0 0 4px color-mix(in srgb, var(--btn-primary-bg-color) 18%, transparent);
    transition: var(--ecom-transition-fast);
}

.mobile-bottom-nav-cart .nav-icon-btn:hover,
.mobile-bottom-nav-cart:hover .nav-icon-btn {
    transform: translateY(-3px) scale(1.04);
    box-shadow:
        0 10px 22px rgba(0, 0, 0, 0.28),
        0 0 0 6px color-mix(in srgb, var(--btn-primary-bg-color) 22%, transparent);
}

/* Live total amount shown as a sleek pill tag floating on top of the FAB */
.nav-cart-amount-pill {
    position: absolute;
    top: 0;
    left: 50%;
    transform: translate(-50%, -90%);
    padding: 3px 10px;
    border-radius: 50rem;
    background: linear-gradient(145deg, var(--main-nav-bg-color), color-mix(in srgb, var(--main-nav-bg-color) 80%, #000 20%));
    color: #ffffff;
    font-size: 0.64rem;
    font-weight: 800;
    letter-spacing: 0.2px;
    line-height: 1.2;
    white-space: nowrap;
    box-shadow: 0 3px 8px rgba(0, 0, 0, 0.28);
    pointer-events: none;
}

/* Little downward pointer on the amount pill for a tag-like look */
.nav-cart-amount-pill::after {
    content: "";
    position: absolute;
    bottom: -4px;
    left: 50%;
    transform: translateX(-50%);
    border-left: 5px solid transparent;
    border-right: 5px solid transparent;
    border-top: 5px solid var(--main-nav-bg-color);
}

/* Distinct count badge so it pops on the gradient circle */
.mobile-bottom-nav-cart .nav-cart-badge {
    background: #e74049;
    box-shadow: 0 0 0 2px #ffffff;
}

.mobile-bottom-nav-badge {
    position: absolute;
    top: 0;
    right: 50%;
    transform: translateX(12px);
    background-color: #dc3545;
    color: #ffffff;
    font-size: 0.65rem;
    font-weight: 700;
    border-radius: 10px;
    padding: 1px 5px;
    min-width: 16px;
    text-align: center;
}

/* Add bottom padding to body on mobile to avoid fixed bottom nav overlaying content */
@media (max-width: 767.98px) {
    body {
        padding-bottom: var(--mobile-nav-height);
    }
}

/* ==========================================================================
   6. Product Cards & Grid Layouts
   ========================================================================== */
.product-card {
    background-color: var(--ecom-card-bg);
    border: 1px solid var(--ecom-border-color);
    border-radius: var(--ecom-border-radius-md);
    box-shadow: var(--ecom-box-shadow-sm);
    transition: var(--ecom-transition-base);
    height: 100%;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    position: relative;
}

.product-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--ecom-box-shadow-md);
    border-color: rgba(13, 110, 253, 0.25);
}

.product-card .card-img-wrapper {
    position: relative;
    width: 100%;
    padding-top: 100%;
    /* 1:1 Aspect Ratio */
    background-color: #f8f9fa;
    overflow: hidden;
}

.product-card .card-img-wrapper img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: contain;
    transition: transform 0.3s ease;
}

.product-card:hover .card-img-wrapper img {
    transform: scale(1.05);
}

.product-card .badge-discount {
    position: absolute;
    top: 10px;
    left: 10px;
    background-color: #dc3545;
    color: #ffffff;
    font-size: 0.75rem;
    font-weight: 700;
    padding: 4px 8px;
    border-radius: var(--ecom-border-radius-sm);
    z-index: 2;
}

.product-card .card-body {
    padding: 1rem;
    display: flex;
    flex-direction: column;
    flex: 1 1 auto;
}

.product-card .product-title-wrapper {
    position: relative;
    min-height: 4rem;
}

.product-card .product-title {
    font-size: 0.95rem;
    font-weight: 600;
    color: #212529;
    text-decoration: none;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    min-height: 4rem;
    width: 100%;
}

.product-card .product-title:hover {
    color: var(--primary-bg-color);
}

.product-card .product-title.has-overflow:hover {
    -webkit-line-clamp: unset;
    overflow: visible;
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    z-index: 20;
    background: #ffffff;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
}

.product-card .product-price {
    font-size: 1.1rem;
    font-weight: 700;
    color: #111111;
}

.product-card .product-price-old {
    font-size: 0.85rem;
    color: #6c757d;
    text-decoration: line-through;
    margin-left: 0.4rem;
}

.product-card .btn-card-action {
    font-size: 0.8rem;
    font-weight: 600;
    padding: 0.35rem 0.25rem;
    white-space: nowrap;
}

@media (min-width: 576px) {
    .product-card .btn-cart-col {
        width: 55% !important;
    }

    .product-card .btn-buy-col {
        width: 45% !important;
    }
}

/* ==========================================================================
   7. Buttons & Form Components
   ========================================================================== */
.btn-primary,
.btn-ecom-primary {
    background-color: var(--btn-primary-bg-color);
    border-color: var(--btn-primary-bg-color);
    color: var(--btn-primary-text-color);
    font-weight: 600;
    border-radius: var(--ecom-border-radius-sm);
    padding: 0.5rem 1.25rem;
    transition: var(--ecom-transition-base);
}

.btn-primary:hover,
.btn-primary:focus,
.btn-ecom-primary:hover,
.btn-ecom-primary:focus {
    background-color: var(--btn-primary-hover-bg-color);
    border-color: var(--btn-primary-hover-bg-color);
    color: var(--btn-primary-hover-text-color);
    box-shadow: var(--ecom-box-shadow-sm);
}

.btn-secondary,
.btn-ecom-secondary {
    background-color: var(--btn-secondary-bg-color);
    border-color: var(--btn-secondary-bg-color);
    color: var(--btn-secondary-text-color);
    font-weight: 500;
    border-radius: var(--ecom-border-radius-sm);
    padding: 0.5rem 1.25rem;
    transition: var(--ecom-transition-base);
}

.btn-secondary:hover,
.btn-secondary:focus,
.btn-ecom-secondary:hover,
.btn-ecom-secondary:focus {
    background-color: var(--btn-secondary-hover-bg-color);
    border-color: var(--btn-secondary-hover-bg-color);
    color: var(--btn-secondary-hover-text-color);
}

/* ==========================================================================
   8. Floating Back to Top Button
   ========================================================================== */
.back-to-top-btn {
    position: fixed;
    bottom: calc(var(--mobile-nav-height) + 16px);
    right: 20px;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background-color: var(--main-nav-bg-color);
    color: var(--main-nav-text-color);
    border: none;
    box-shadow: var(--ecom-box-shadow-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transition: var(--ecom-transition-base);
    z-index: 1040;
}

@media (min-width: 768px) {
    .back-to-top-btn {
        bottom: 30px;
        right: 30px;
    }
}

.back-to-top-btn.show {
    opacity: 1;
    visibility: visible;
}

.back-to-top-btn:hover {
    transform: translateY(-3px);
    box-shadow: var(--ecom-box-shadow-lg);
    color: #ffffff;
}

/* ==========================================================================
   9. Footer Architecture
   ========================================================================== */
.footer-content {
    background-color: var(--footer-section-bg-color);
    color: var(--footer-section-text-color);
    padding-top: 3rem;
    padding-bottom: 1.5rem;
    margin-top: 4rem;
    border-top: 1px solid var(--ecom-border-color);
}

.footer-content a {
    color: var(--footer-section-text-color);
    text-decoration: none;
    transition: var(--ecom-transition-fast);
}

.footer-content a:hover {
    opacity: 0.8;
    text-decoration: underline;
}

.footer-bottom-bar {
    background-color: transparent;
    padding: 1rem 0;
    font-size: 0.85rem;
}

/* ==========================================================================
   10. Utility & Focus Accessibility Classes
   ========================================================================== */
.cursor-pointer {
    cursor: pointer !important;
}

:focus-visible {
    outline: 2px solid var(--btn-primary-hover-bg-color);
    outline-offset: 2px;
}

/* ==========================================================================
   11. Track Order Modal
   ========================================================================== */

.track-order-modal-dialog {
    max-width: 480px;
}

.track-order-modal-content {
    border: none;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.22);
}

.track-order-modal-header {
    background: linear-gradient(135deg, var(--main-nav-bg-color, #1a1a2e), #2d2d5e);
    border-bottom: none;
    padding: 14px 18px;
    color: #fff;
}

.track-order-modal-header .modal-title {
    font-size: 0.95rem;
    font-weight: 700;
    color: #fff;
    margin: 0;
}

/* ── Form / Hero ── */
.track-order-form {
    padding: 24px 22px 20px;
}

.track-order-hero {
    text-align: center;
    margin-bottom: 22px;
}

.track-order-hero-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: linear-gradient(135deg, #0ea5e9, #7dd3fc);
    color: #fff;
    font-size: 1.6rem;
    margin-bottom: 12px;
    box-shadow: 0 6px 20px rgba(14, 165, 233, 0.35);
}

.track-order-hero-title {
    font-size: 1rem;
    font-weight: 700;
    color: #1a1a2e;
    margin-bottom: 4px;
}

.track-order-hero-sub {
    font-size: 0.83rem;
    color: #888;
    margin: 0;
    line-height: 1.5;
}

.track-order-input-group {
    display: flex;
    gap: 8px;
}

.track-order-input {
    flex: 1;
    height: 42px;
    padding: 0 14px;
    border: 1.5px solid #e0e0e0;
    border-radius: 50rem;
    font-size: 0.88rem;
    color: #1a1a2e;
    outline: none;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
    background: #f8f9fa;
}

.track-order-input:focus {
    border-color: #0ea5e9;
    box-shadow: 0 0 0 3px rgba(14, 165, 233, 0.15);
    background: #fff;
}

.track-order-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    height: 42px;
    padding: 0 20px;
    border: none;
    border-radius: 50rem;
    background: linear-gradient(135deg, #0ea5e9, #0284c7);
    color: #fff;
    font-size: 0.88rem;
    font-weight: 700;
    cursor: pointer;
    white-space: nowrap;
    transition: opacity 0.2s ease, transform 0.15s ease;
}

.track-order-btn:hover {
    opacity: 0.9;
    transform: translateY(-1px);
}

.track-order-btn:disabled {
    opacity: 0.7;
}

.track-order-spinner {
    display: inline-block;
    width: 14px;
    height: 14px;
    border: 2px solid rgba(255, 255, 255, 0.4);
    border-top-color: #fff;
    border-radius: 50%;
    animation: nav-search-spin 0.6s linear infinite;
}

.track-order-error {
    margin-top: 10px;
    font-size: 0.82rem;
    color: #dc3545;
    padding-left: 4px;
}

/* ── Not found ── */
.track-order-notfound {
    padding: 36px 22px;
    text-align: center;
    color: #888;
}

.track-order-notfound-icon {
    font-size: 2.5rem;
    color: #ddd;
    margin-bottom: 12px;
    display: block;
}

.track-order-notfound h6 {
    color: #333;
    font-weight: 700;
    margin-bottom: 6px;
}

.track-order-notfound p {
    font-size: 0.85rem;
    margin-bottom: 18px;
}

/* ── Result ── */
.track-order-result {
    padding: 20px 22px 22px;
}

.track-order-result-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 20px;
}

.track-order-result-label {
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #999;
    margin-bottom: 2px;
}

.track-order-result-no {
    font-size: 1.1rem;
    font-weight: 800;
    color: #1a1a2e;
}

.track-order-status-badge {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 50rem;
    font-size: 0.78rem;
    font-weight: 700;
    background: color-mix(in srgb, var(--badge-color, #6c757d) 15%, transparent);
    color: var(--badge-color, #6c757d);
    border: 1px solid color-mix(in srgb, var(--badge-color, #6c757d) 30%, transparent);
}

/* ── Timeline ── */
.track-order-timeline {
    display: flex;
    align-items: flex-start;
    gap: 0;
    margin-bottom: 20px;
    overflow-x: auto;
    padding-bottom: 4px;
}

.track-timeline-step {
    display: flex;
    flex-direction: column;
    align-items: center;
    flex: 1;
    position: relative;
    min-width: 64px;
}

.track-timeline-line {
    position: absolute;
    top: 15px;
    left: 50%;
    width: 100%;
    height: 2px;
    background: #e5e7eb;
    z-index: 0;
    transition: background 0.3s ease;
}

.track-timeline-line.done {
    background: #0ea5e9;
}

.track-timeline-icon {
    position: relative;
    z-index: 1;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: #e5e7eb;
    color: #aaa;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.85rem;
    margin-bottom: 6px;
    transition: background 0.3s ease, color 0.3s ease, box-shadow 0.3s ease;
}

.track-timeline-step.done .track-timeline-icon {
    background: #e0f2fe;
    color: #0ea5e9;
}

.track-timeline-step.active .track-timeline-icon {
    background: #0ea5e9;
    color: #fff;
    box-shadow: 0 0 0 4px rgba(14, 165, 233, 0.2);
}

.track-timeline-label {
    font-size: 0.67rem;
    color: #aaa;
    text-align: center;
    font-weight: 500;
    line-height: 1.2;
}

.track-timeline-step.done .track-timeline-label {
    color: #0ea5e9;
}

.track-timeline-step.active .track-timeline-label {
    color: #0284c7;
    font-weight: 700;
}

/* ── Cancelled banner ── */
.track-order-cancelled {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 14px;
    border-radius: 10px;
    background: rgba(220, 53, 69, 0.07);
    border: 1px solid rgba(220, 53, 69, 0.2);
    color: #dc3545;
    font-size: 0.87rem;
    font-weight: 500;
    margin-bottom: 20px;
}

.track-order-cancelled .bi {
    font-size: 1.2rem;
    flex-shrink: 0;
}

/* ── Summary rows ── */
.track-order-summary {
    border-radius: 10px;
    border: 1px solid #f0f0f0;
    overflow: hidden;
    margin-bottom: 14px;
}

.track-order-summary-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 9px 14px;
    font-size: 0.84rem;
    gap: 16px;
}

.track-order-summary-row:not(:last-child) {
    border-bottom: 1px solid #f5f5f5;
}

.track-order-summary-row span:first-child {
    color: #999;
    flex-shrink: 0;
}

.track-order-summary-row span:last-child {
    color: #1a1a2e;
    text-align: right;
}

/* ── Items list ── */
.track-order-items {
    border-radius: 10px;
    border: 1px solid #f0f0f0;
    overflow: hidden;
    margin-bottom: 4px;
}

.track-order-items-title {
    padding: 8px 14px;
    font-size: 0.76rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.4px;
    color: #999;
    background: #fafafa;
    border-bottom: 1px solid #f0f0f0;
}

.track-order-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 14px;
    font-size: 0.83rem;
}

.track-order-item:not(:last-child) {
    border-bottom: 1px solid #f8f8f8;
}

.track-order-item-name {
    color: #333;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    flex: 1;
}

.track-order-item-qty {
    color: #999;
    font-size: 0.8rem;
    flex-shrink: 0;
    margin-left: 8px;
}

.track-order-item-more {
    padding: 7px 14px;
    font-size: 0.78rem;
    color: #0ea5e9;
    background: #f0f9ff;
    text-align: center;
}

/* ── Retry / back button ── */
.track-order-retry-btn {
    display: inline-flex;
    align-items: center;
    padding: 6px 16px;
    border: 1.5px solid #e0e0e0;
    border-radius: 50rem;
    background: transparent;
    color: #555;
    font-size: 0.83rem;
    font-weight: 600;
    cursor: pointer;
    transition: border-color 0.2s ease, color 0.2s ease;
}

.track-order-retry-btn:hover {
    border-color: #0ea5e9;
    color: #0ea5e9;
}

/* -----------------------------------------------
   Auth Modal Premium Two-Panel Design
----------------------------------------------- */

.auth-modal-dialog {
    max-width: 780px;
}

.auth-modal-content {
    border: none;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 28px 70px rgba(0, 0, 0, 0.2);
    display: flex;
    flex-direction: row;
    min-height: 440px;
    position: relative;
}

/* -- Left branding panel -- */
.auth-panel-left {
    position: relative;
    width: 320px;
    flex-shrink: 0;
    background: linear-gradient(160deg, var(--main-nav-bg-color, #1a1a2e) 0%, #2d2d5e 100%);
    padding: 40px 28px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    overflow: hidden;
}

.auth-panel-left-inner {
    position: relative;
    z-index: 1;
}

.auth-brand-icon {
    width: 60px;
    height: 60px;
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.12);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    color: #fff;
    margin-bottom: 18px;
    backdrop-filter: blur(6px);
    border: 1px solid rgba(255, 255, 255, 0.18);
}

.auth-brand-title {
    color: #fff;
    font-size: 1.25rem;
    font-weight: 800;
    margin-bottom: 8px;
    line-height: 1.3;
}

.auth-brand-sub {
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.83rem;
    line-height: 1.6;
    margin-bottom: 24px;
}

.auth-brand-features {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.auth-brand-features li {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.83rem;
    color: rgba(255, 255, 255, 0.8);
}

.auth-brand-features li .bi-check-circle-fill {
    color: #7dd3fc;
    font-size: 0.9rem;
    flex-shrink: 0;
}

/* Decorative circles */
.auth-panel-deco {
    position: absolute;
    border-radius: 50%;
    opacity: 0.07;
    background: #fff;
}

.auth-panel-deco-1 {
    width: 200px;
    height: 200px;
    top: -60px;
    right: -60px;
}

.auth-panel-deco-2 {
    width: 130px;
    height: 130px;
    bottom: -30px;
    left: -30px;
}

/* -- Right form panel -- */
.auth-panel-right {
    flex: 1;
    padding: 32px 28px 28px;
    position: relative;
    overflow-y: auto;
    background: #fff;
}

.auth-modal-close {
    position: absolute;
    top: 14px;
    right: 14px;
    z-index: 30;
    width: 34px;
    height: 34px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.92);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.18);
    opacity: 1;
    transition: background-color 0.18s ease, transform 0.18s ease;
}

.auth-modal-close:hover {
    background-color: #fff;
    transform: scale(1.06);
}

.auth-modal-close:focus {
    box-shadow: 0 0 0 0.2rem rgba(0, 0, 0, 0.12);
}

/* -- Tab group -- */
.auth-tab-group {
    display: flex;
    gap: 6px;
    background: #f4f4f6;
    border-radius: 50rem;
    padding: 4px;
    margin-bottom: 22px;
}

.auth-tab-btn {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    height: 36px;
    border: none;
    border-radius: 50rem;
    background: transparent;
    color: #888;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s ease, color 0.2s ease, box-shadow 0.2s ease;
}

.auth-tab-btn.active {
    background: #fff;
    color: var(--btn-primary-bg-color, #e63c6d);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.auth-tab-btn .bi {
    font-size: 0.9rem;
}

/* -- Form headline -- */
.auth-form-headline {
    font-size: 1.05rem;
    font-weight: 700;
    color: #1a1a2e;
    margin-bottom: 18px;
}

.auth-form-sub {
    font-size: 0.83rem;
    color: #888;
    margin-top: -14px;
    margin-bottom: 18px;
    line-height: 1.5;
}

/* -- Field + Input -- */
.auth-field {
    margin-bottom: 14px;
}

.auth-label {
    display: block;
    font-size: 0.8rem;
    font-weight: 600;
    color: #555;
    margin-bottom: 5px;
    letter-spacing: 0.2px;
}

.auth-input-wrap {
    position: relative;
}

.auth-input-icon {
    position: absolute;
    left: 13px;
    top: 50%;
    transform: translateY(-50%);
    color: #bbb;
    font-size: 0.92rem;
    pointer-events: none;
    transition: color 0.2s ease;
}

.auth-input {
    width: 100%;
    height: 42px;
    padding: 0 14px 0 38px;
    border: 1.5px solid #e8e8e8;
    border-radius: 10px;
    font-size: 0.88rem;
    color: #1a1a2e;
    background: #fafafa;
    outline: none;
    transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.auth-input:focus {
    border-color: var(--btn-primary-bg-color, #e63c6d);
    box-shadow: 0 0 0 3px color-mix(in srgb, var(--btn-primary-bg-color, #e63c6d) 15%, transparent);
    background: #fff;
}

.auth-input:focus+.auth-input-icon,
.auth-input-wrap:focus-within .auth-input-icon {
    color: var(--btn-primary-bg-color, #e63c6d);
}

.auth-input.is-invalid {
    border-color: #dc3545;
}

.auth-error {
    font-size: 0.78rem;
    color: #dc3545;
    margin: 4px 0 0 2px;
}

/* -- Submit button -- */
.auth-submit-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    height: 44px;
    border: none;
    border-radius: 10px;
    background: linear-gradient(135deg, var(--btn-primary-bg-color, #e63c6d), var(--btn-primary-hover-bg-color, #c0305a));
    color: #fff;
    font-size: 0.92rem;
    font-weight: 700;
    cursor: pointer;
    margin-top: 6px;
    transition: opacity 0.2s ease, transform 0.15s ease;
    letter-spacing: 0.2px;
}

.auth-submit-btn:hover {
    opacity: 0.92;
    transform: translateY(-1px);
}

.auth-submit-btn:disabled {
    opacity: 0.7;
    transform: none;
}

.auth-spinner {
    display: inline-block;
    width: 16px;
    height: 16px;
    border: 2px solid rgba(255, 255, 255, 0.35);
    border-top-color: #fff;
    border-radius: 50%;
    animation: nav-search-spin 0.65s linear infinite;
}

/* -- Footer links -- */
.auth-footer-links {
    margin-top: 16px;
    text-align: center;
    font-size: 0.82rem;
    color: #888;
}

.auth-link-btn {
    border: none;
    background: none;
    padding: 0;
    color: var(--btn-primary-bg-color, #e63c6d);
    font-size: 0.82rem;
    font-weight: 600;
    cursor: pointer;
}

.auth-link-btn:hover {
    text-decoration: underline;
}

/* -- Back button (password reset) -- */
.auth-back-btn {
    display: inline-flex;
    align-items: center;
    border: none;
    background: none;
    padding: 0;
    color: #888;
    font-size: 0.82rem;
    font-weight: 600;
    cursor: pointer;
    margin-bottom: 14px;
    transition: color 0.15s ease;
}

.auth-back-btn:hover {
    color: var(--btn-primary-bg-color, #e63c6d);
}

/* -- Alert -- */
.auth-alert {
    display: flex;
    align-items: center;
    padding: 10px 14px;
    border-radius: 10px;
    font-size: 0.83rem;
    font-weight: 500;
    margin-bottom: 14px;
}

.auth-alert-danger {
    background: rgba(220, 53, 69, 0.08);
    color: #dc3545;
    border: 1px solid rgba(220, 53, 69, 0.2);
}

.auth-alert-success {
    background: rgba(25, 135, 84, 0.08);
    color: #198754;
    border: 1px solid rgba(25, 135, 84, 0.2);
}

/* -- Mobile: collapse left panel -- */
@media (max-width: 600px) {
    .auth-modal-dialog {
        max-width: 96vw;
    }

    .auth-modal-content {
        flex-direction: column;
        min-height: unset;
    }

    .auth-panel-left {
        width: 100%;
        padding: 22px 20px;
        flex-direction: row;
        align-items: center;
        gap: 14px;
    }

    .auth-brand-icon {
        width: 44px;
        height: 44px;
        font-size: 1.3rem;
        margin-bottom: 0;
        flex-shrink: 0;
    }

    .auth-brand-title {
        font-size: 1rem;
        margin-bottom: 0;
    }

    .auth-brand-sub,
    .auth-brand-features,
    .auth-panel-deco {
        display: none;
    }

    .auth-panel-right {
        padding: 20px 16px 24px;
    }
}

/* -- Auth Modal Loading Overlay -- */
.auth-loading-overlay {
    position: absolute;
    inset: 0;
    background: rgba(255, 255, 255, 0.72);
    backdrop-filter: blur(3px);
    -webkit-backdrop-filter: blur(3px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 20;
    border-radius: inherit;
    animation: auth-overlay-in 0.1s ease;
}

@keyframes auth-overlay-in {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

.auth-loading-spinner {
    width: 30px;
    height: 30px;
    border: 3px solid rgba(0, 0, 0, 0.08);
    border-top-color: var(--btn-primary-bg-color, #e63c6d);
    border-radius: 50%;
    animation: nav-search-spin 0.65s linear infinite;
}

/* Prevent tab btn cursor during disabled state */
.auth-tab-btn:disabled {
    cursor: not-allowed;
    opacity: 0.6;
}

/* ── Cart Success Notification ── */
.cart-success-notification {
    position: fixed;
    bottom: 1.5rem;
    right: 1.5rem;
    z-index: 10000;
    width: 340px;
    max-width: calc(100vw - 2rem);
    background: #ffffff;
    border-radius: 1rem;
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.18);
    padding: 1rem 1rem 1rem 1.1rem;
    border: 1px solid rgba(0, 0, 0, 0.06);
    border-left: 4px solid #198754;
}

.csn-close {
    position: absolute;
    top: 0.5rem;
    right: 0.65rem;
    background: none;
    border: none;
    font-size: 1.25rem;
    line-height: 1;
    color: #9aa0a6;
    cursor: pointer;
    padding: 0;
    transition: color 0.15s ease;
}

.csn-close:hover {
    color: #495057;
}

.csn-body {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
}

.csn-icon {
    flex-shrink: 0;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: #198754;
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.35rem;
    box-shadow: 0 4px 10px rgba(25, 135, 84, 0.35);
}

.csn-content {
    flex: 1;
    min-width: 0;
}

.csn-title {
    margin: 0;
    font-size: 0.95rem;
    font-weight: 700;
    color: #212529;
}

.csn-product {
    margin: 0.15rem 0 0;
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--main-nav-bg-color, #e74079);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.csn-meta {
    margin: 0.2rem 0 0;
    font-size: 0.78rem;
    color: #6c757d;
}

.csn-actions {
    display: flex;
    gap: 0.5rem;
    margin-top: 0.9rem;
}

/* Depleting progress bar (auto-close countdown) */
.csn-progress {
    position: absolute;
    left: 0;
    bottom: 0;
    width: 100%;
    height: 3px;
    background: rgba(0, 0, 0, 0.06);
    border-bottom-left-radius: 1rem;
    border-bottom-right-radius: 1rem;
    overflow: hidden;
}

.csn-progress-bar {
    height: 100%;
    width: 100%;
    background: var(--btn-primary-bg-color, #ffc376);
}

.csn-progress-run {
    animation: csn-progress-anim 4s linear forwards;
}

@keyframes csn-progress-anim {
    from {
        width: 100%;
    }

    to {
        width: 0%;
    }
}

.csn-btn {
    flex: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.5rem 0.75rem;
    border-radius: 0.6rem;
    font-size: 0.82rem;
    font-weight: 700;
    text-decoration: none;
    cursor: pointer;
    border: 1.5px solid transparent;
    transition: transform 0.12s ease, background 0.15s ease, box-shadow 0.15s ease;
}

.csn-btn:active {
    transform: scale(0.97);
}

.csn-btn-ghost {
    background: #f1f3f5;
    color: #495057;
    border-color: #e9ecef;
}

.csn-btn-ghost:hover {
    background: #e9ecef;
    color: #212529;
}

.csn-btn-primary {
    background: var(--btn-primary-bg-color, #ffc376);
    color: var(--btn-primary-text-color, #212529);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.12);
}

.csn-btn-primary:hover {
    background: var(--btn-primary-hover-bg-color, #e0ab5b);
    color: var(--btn-primary-hover-text-color, #212529);
}

/* Slide-in / fade animation */
.csn-anim {
    transition-property: transform, opacity;
    transition-timing-function: cubic-bezier(0.22, 1, 0.36, 1);
    transition-duration: 0.35s;
}

.csn-anim-enter-start {
    opacity: 0;
    transform: translateY(16px) scale(0.96);
}

.csn-anim-enter-end {
    opacity: 1;
    transform: translateY(0) scale(1);
}

.csn-anim-leave-start {
    opacity: 1;
    transform: translateY(0) scale(1);
}

.csn-anim-leave-end {
    opacity: 0;
    transform: translateY(16px) scale(0.96);
}

@media (max-width: 575.98px) {
    .cart-success-notification {
        left: 1rem;
        right: 1rem;
        bottom: calc(var(--mobile-nav-height, 64px) + 2rem);
        width: auto;
    }
}

/* ── Modern Premium Footer Styling with Theme Support ── */
.footer-section {
    background-color: var(--footer-section-bg-color, #ffffff);
    color: var(--footer-section-text-color, #212529);
    border-top: 1px solid var(--footer-border-color, rgba(125, 125, 125, 0.15));
    padding-top: 0;
    position: relative;
}

.footer-features-strip {
    background: color-mix(in srgb, var(--footer-section-text-color, #212529) 3%, transparent);
    border-bottom: 1px solid var(--footer-border-color, rgba(125, 125, 125, 0.15));
}

.footer-feature-icon {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    background: rgba(13, 110, 253, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.footer-heading {
    font-weight: 700;
    font-size: 0.95rem;
    color: var(--footer-section-text-color, #1e293b);
    letter-spacing: -0.2px;
    position: relative;
    padding-bottom: 8px;
}

.footer-heading::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 24px;
    height: 2px;
    background: var(--primary-bg-color, #0d6efd);
    border-radius: 2px;
}

.footer-text-title {
    color: var(--footer-section-text-color, #1e293b);
}

.footer-text-muted {
    color: var(--footer-section-text-color, #475569);
    opacity: 0.82;
}

.footer-nav-links a {
    color: var(--footer-section-text-color, #475569);
    opacity: 0.85;
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 500;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    transition: all 0.2s ease;
}

.footer-nav-links a i {
    font-size: 0.7rem;
    opacity: 0.6;
    transition: transform 0.2s ease, color 0.2s ease;
}

.footer-nav-links a:hover {
    color: var(--primary-bg-color, #0d6efd);
    opacity: 1;
    transform: translateX(3px);
}

.footer-nav-links a:hover i {
    opacity: 1;
    color: var(--primary-bg-color, #0d6efd);
}

.footer-social-btn {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    background: color-mix(in srgb, var(--footer-section-text-color, #212529) 5%, transparent);
    color: var(--footer-section-text-color, #475569);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    transition: all 0.2s ease;
    border: 1px solid var(--footer-border-color, rgba(125, 125, 125, 0.15));
}

.footer-social-btn:hover {
    background: var(--primary-bg-color, #0d6efd);
    color: #ffffff;
    border-color: var(--primary-bg-color, #0d6efd);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(13, 110, 253, 0.25);
}

.footer-contact-box {
    background: color-mix(in srgb, var(--footer-section-text-color, #212529) 3%, transparent);
    border: 1px solid var(--footer-border-color, rgba(125, 125, 125, 0.15));
}

.footer-contact-box a {
    transition: color 0.2s ease;
}

.footer-contact-box a:hover {
    color: var(--primary-bg-color, #0d6efd) !important;
}

.footer-payment-card {
    background: color-mix(in srgb, var(--footer-section-text-color, #212529) 2%, transparent);
    border: 1px solid var(--footer-border-color, rgba(125, 125, 125, 0.15));
}

.footer-contact-icon {
    width: 32px;
    height: 32px;
    border-radius: 8px;
    background: color-mix(in srgb, var(--footer-section-text-color, #212529) 5%, transparent);
    color: var(--footer-section-text-color, #475569);
    border: 1px solid var(--footer-border-color, rgba(125, 125, 125, 0.15));
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 0.85rem;
    transition: all 0.2s ease;
}

.footer-contact-box li:hover .footer-contact-icon {
    background: var(--primary-bg-color, #0d6efd);
    color: #ffffff;
    border-color: var(--primary-bg-color, #0d6efd);
    transform: scale(1.05);
}

.footer-bottom-bar {
    background: transparent;
    border-top: 1px solid var(--footer-border-color, rgba(125, 125, 125, 0.15)) !important;
}

/* ==========================================================================
   Product Showcase & Card Component Ecosystem
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. Section View-More Micro-Animations
   -------------------------------------------------------------------------- */
.view-more-link {
    transition: color 0.2s ease;
}

.view-more-link:hover {
    color: var(--main-nav-bg-color, #e74079) !important;
}

.view-more-link .view-more-arrow {
    transition: transform 0.2s ease;
}

.view-more-link:hover .view-more-arrow {
    transform: translateX(4px);
}

/* --------------------------------------------------------------------------
   2. Horizontal Product Carousel Track
   -------------------------------------------------------------------------- */
.product-carousel-wrapper {
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    /* Firefox */
    -ms-overflow-style: none;
    /* IE and Edge */
    padding-bottom: 0.5rem;
    padding-left: 2px;
    padding-right: 2px;
}

.product-carousel-wrapper::-webkit-scrollbar {
    display: none;
    /* Chrome, Safari, Opera */
}

.product-carousel-wrapper>[class*="col-"] {
    flex: 0 0 auto !important;
    width: 165px !important;
    scroll-snap-align: start;
}

@media (min-width: 576px) {
    .product-carousel-wrapper>[class*="col-"] {
        width: 200px !important;
    }
}

@media (min-width: 768px) {
    .product-carousel-wrapper>[class*="col-"] {
        width: 235px !important;
    }
}

/* --------------------------------------------------------------------------
   3. Carousel Interactive Navigation Arrow Buttons
   -------------------------------------------------------------------------- */
.carousel-arrow-btn {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    border: 1px solid var(--ecom-border-color, #e3e8ee);
    background: #ffffff;
    color: #333333;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.06);
    padding: 0;
    line-height: 1;
}

@media (min-width: 576px) {
    .carousel-arrow-btn {
        width: 32px;
        height: 32px;
        font-size: 0.8rem;
    }
}

.carousel-arrow-btn:not(:disabled) {
    border-color: rgba(0, 0, 0, 0.08);
    animation: carousel-border-pulse 4s cubic-bezier(0.4, 0, 0.2, 1) infinite;
}

.carousel-arrow-btn:hover:not(:disabled) {
    background: var(--main-nav-bg-color, #e74079);
    color: #ffffff;
    border-color: var(--main-nav-bg-color, #e74079);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    transform: translateY(-1px);
    animation: none;
}

.carousel-arrow-btn:disabled {
    opacity: 0.25;
    cursor: not-allowed;
    box-shadow: none;
    animation: none;
}

@keyframes carousel-border-pulse {
    0% {
        border-color: rgba(0, 0, 0, 0.08);
        box-shadow: 0 0 0 0 rgba(0, 0, 0, 0);
    }

    50% {
        border-color: rgba(231, 64, 121, 0.25);
        box-shadow: 0 0 0 2px rgba(231, 64, 121, 0.06);
    }

    100% {
        border-color: rgba(0, 0, 0, 0.08);
        box-shadow: 0 0 0 0 rgba(0, 0, 0, 0);
    }
}

/* --------------------------------------------------------------------------
   4. Product Card Component (DOM Flow Order)
   -------------------------------------------------------------------------- */
/* 4.1 Card Container & Base Layout */
.product-card {
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

/* 4.2 Media Image Wrapper */
.product-card .card-img-wrapper {
    position: relative;
    overflow: hidden;
}

/* 4.3 Overlay Badges Container (Top-Left Stack) */
.product-badges-wrapper {
    position: absolute !important;
    top: 8px !important;
    left: 8px !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: flex-start !important;
    gap: 4px !important;
    z-index: 5 !important;
    pointer-events: none;
}

/* 4.4 Overlay Badge Pills (Base & Variants) */
.product-card .badge-discount,
.product-card .badge-featured,
.badge.badge-discount,
.badge.badge-featured {
    position: static !important;
    top: auto !important;
    left: auto !important;
    font-size: 0.68rem;
    font-weight: 700;
    padding: 0.35em 0.65em;
    border-radius: 50rem;
    line-height: 1;
    letter-spacing: 0.2px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.12);
}

.product-card .badge-discount,
.badge.badge-discount {
    background: linear-gradient(135deg, #ff4757, #ff6b81) !important;
    color: #ffffff !important;
}

.product-card .badge-featured,
.badge.badge-featured {
    background: linear-gradient(135deg, #ffa502, #ff7f50) !important;
    color: #ffffff !important;
}

/* 4.5 Product Title & Typography */
.product-card .product-title {
    color: var(--text-color, #212529);
    transition: color 0.2s ease;
}

.product-card:hover .product-title {
    color: var(--main-nav-bg-color, #e74079);
}

/* 4.6 Pricing & Unit Tags */
.product-card .product-price {
    font-weight: 700;
    color: var(--main-nav-bg-color, #e74079);
}

.product-card .product-price-old {
    color: #888888;
    text-decoration: line-through;
}

/* 4.7 Inline Action Buttons */
.product-card .btn-ecom-secondary,
.product-card .btn-ecom-primary {
    transition: all 0.2s ease;
}

/* ==========================================================================
   5. E-COMMERCE MOBILE-RESPONSIVE BREADCRUMB SYSTEM
   ========================================================================== */
nav[aria-label="breadcrumb"],
.ecom-breadcrumb-nav {
    position: relative;
    width: 100%;
}

.breadcrumb,
.ecom-breadcrumb-nav .breadcrumb {
    display: flex !important;
    flex-wrap: nowrap !important;
    align-items: center !important;
    overflow-x: auto !important;
    overflow-y: hidden !important;
    white-space: nowrap !important;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none !important;
    /* Firefox */
    -ms-overflow-style: none !important;
    /* IE/Edge */
    padding: 0.5rem 0.85rem !important;
    margin-bottom: 0 !important;
    background-color: #ffffff;
    border: 1px solid rgba(226, 232, 240, 0.9);
    border-radius: 0.75rem;
    box-shadow: 0 2px 6px rgba(15, 23, 42, 0.03);
}

.breadcrumb::-webkit-scrollbar,
.ecom-breadcrumb-nav .breadcrumb::-webkit-scrollbar {
    display: none !important;
    /* Chrome, Safari, Opera */
    width: 0 !important;
    height: 0 !important;
}

.breadcrumb-item {
    display: inline-flex !important;
    align-items: center !important;
    font-size: 0.8125rem;
    line-height: 1.4;
    flex-shrink: 0;
    color: #64748b;
}

.breadcrumb-item+.breadcrumb-item::before {
    content: "\F285" !important;
    /* Bootstrap Icon bi-chevron-right */
    font-family: "bootstrap-icons" !important;
    font-size: 0.65rem;
    color: #94a3b8;
    padding: 0 0.5rem;
    flex-shrink: 0;
}

.breadcrumb-item a {
    color: #475569;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.15s ease-in-out;
    display: inline-flex;
    align-items: center;
    max-width: 160px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.breadcrumb-item a:hover {
    color: var(--main-nav-bg-color, #e74079);
    text-decoration: none;
}

.breadcrumb-item.active {
    color: #0f172a;
    font-weight: 600;
    max-width: 220px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* Home link sizing override */
.breadcrumb-item .home-link,
.breadcrumb-item:first-child a {
    max-width: none !important;
}

/* Screen size breakpoint adjustments */
@media (max-width: 576px) {

    .breadcrumb,
    .ecom-breadcrumb-nav .breadcrumb {
        padding: 0.4rem 0.65rem !important;
        border-radius: 0.6rem;
    }

    .breadcrumb-item {
        font-size: 0.775rem;
    }

    .breadcrumb-item a {
        max-width: 110px;
    }

    .breadcrumb-item.active {
        max-width: 135px;
    }

    .breadcrumb-item+.breadcrumb-item::before {
        padding: 0 0.35rem;
    }
}

@media (min-width: 768px) {
    .breadcrumb-item a {
        max-width: 220px;
    }

    .breadcrumb-item.active {
        max-width: 350px;
    }
}