/* ==========================================================================
   Mahbuba Shop Storefront
   ========================================================================== */
:root {
    --primary: #2563eb;
    --primary-dark: #1d4ed8;
    --primary-soft: #dbeafe;
    --accent: #0ea5e9;
    --accent-dark: #0284c7;
    --accent-soft: #e0f2fe;
    --ink: #0f172a;
    --text: #334155;
    --muted: #64748b;
    --line: #e2e8f0;
    --bg: #f4f6f8;
    --card: #ffffff;
    --danger: #dc2626;
    --success: #16a34a;
    --warning: #d97706;
    --radius: 14px;
    --radius-sm: 9px;
    --shadow: 0 1px 2px rgba(15, 23, 42, .05), 0 4px 14px rgba(15, 23, 42, .06);
    --shadow-lg: 0 12px 34px rgba(15, 23, 42, .14);
    --container: 1280px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
    margin: 0;
    font-family: 'Hind Siliguri', system-ui, -apple-system, 'Segoe UI', sans-serif;
    font-size: 15px;
    line-height: 1.55;
    color: var(--text);
    background: var(--bg);
}
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
button, input, select, textarea { font: inherit; color: inherit; }
h1, h2, h3, h4 { color: var(--ink); line-height: 1.25; margin: 0 0 .5em; }
.container { width: 100%; max-width: var(--container); margin: 0 auto; padding: 0 16px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.muted { color: var(--muted); }
.text-danger { color: var(--danger); }
.text-success { color: var(--success); }

/* ---------- Buttons & forms ---------- */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    padding: 10px 18px; border-radius: var(--radius-sm); border: 1px solid transparent;
    font-weight: 600; cursor: pointer; transition: .2s; white-space: nowrap; background: none;
}
.btn-primary { background: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--primary-dark); }
.btn-accent { background: var(--accent); color: #fff; }
.btn-accent:hover { background: var(--accent-dark); }
.btn-outline { border-color: var(--line); background: #fff; color: var(--ink); }
.btn-outline:hover { border-color: var(--primary); color: var(--primary); }
.btn-block { width: 100%; }
.btn-lg { padding: 13px 24px; font-size: 16px; }
.btn-sm { padding: 6px 12px; font-size: 13px; }
.btn:disabled { opacity: .55; cursor: not-allowed; }

.form-group { margin-bottom: 14px; }
.form-label { display: block; font-weight: 600; color: var(--ink); margin-bottom: 6px; font-size: 14px; }
.form-control {
    width: 100%; padding: 11px 14px; border: 1px solid var(--line); border-radius: var(--radius-sm);
    background: #fff; transition: .2s; outline: none;
}
.form-control:focus { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(37, 99, 235, .15); }
.pass-wrap { position: relative; }
.pass-wrap .form-control { padding-right: 46px; }
.pass-toggle { position: absolute; top: 50%; right: 6px; transform: translateY(-50%); width: 36px; height: 36px; border: 0; border-radius: 8px; background: transparent; color: var(--muted); cursor: pointer; display: grid; place-items: center; transition: .2s; }
.pass-toggle:hover { color: var(--primary); background: var(--primary-soft); }
.form-error { color: var(--danger); font-size: 13px; margin-top: 4px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }

/* ---------- Top bar ---------- */
.topbar { background: var(--ink); color: #cbd5e1; font-size: 13px; }
.topbar .container { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 36px; }
.topbar-notice { overflow: hidden; white-space: nowrap; flex: 1; }
.topbar-notice span { display: inline-block; padding-left: 100%; animation: ticker 22s linear infinite; }
@keyframes ticker { to { transform: translateX(-100%); } }
.topbar-links { display: flex; align-items: center; gap: 16px; }
.topbar-links a:hover { color: #fff; }
.lang-switch { display: inline-flex; background: rgba(255, 255, 255, .08); border-radius: 30px; padding: 2px; }
.lang-switch a { padding: 2px 10px; border-radius: 30px; font-weight: 600; }
.lang-switch a.active { background: var(--accent); color: #fff; }

/* ---------- Header ---------- */
.site-header { background: #fff; position: sticky; top: 0; z-index: 50; box-shadow: 0 1px 0 var(--line); }
.header-main { display: flex; align-items: center; gap: 22px; padding: 14px 0; }
.logo { display: flex; align-items: center; gap: 10px; flex-shrink: 0; }
.logo-mark {
    width: 42px; height: 42px; border-radius: 12px; display: grid; place-items: center; color: #fff; font-size: 20px;
    background: linear-gradient(135deg, var(--primary), #3b82f6 60%, var(--accent));
    box-shadow: 0 6px 16px rgba(37, 99, 235, .35);
}
.logo-text { display: flex; flex-direction: column; line-height: 1.05; }
.logo-text strong { font-size: 22px; color: var(--ink); letter-spacing: -.3px; }
.logo-text small { font-size: 11px; color: var(--muted); }
.logo img { max-height: 48px; height: auto; object-fit: contain; }

.search { flex: 1; position: relative; max-width: 680px; }
.search form { display: flex; border: 2px solid var(--primary); border-radius: 40px; overflow: hidden; background: #fff; }
.search input { flex: 1; border: 0; padding: 10px 18px; outline: none; min-width: 0; background: transparent; }
.search button { border: 0; background: var(--primary); color: #fff; padding: 0 22px; cursor: pointer; font-weight: 600; }
.search button:hover { background: var(--primary-dark); }
.search-suggest {
    position: absolute; left: 0; right: 0; top: calc(100% + 6px); background: #fff; border-radius: var(--radius);
    box-shadow: var(--shadow-lg); overflow: hidden; display: none; z-index: 60;
}
.search-suggest.show { display: block; }
.search-suggest a { display: flex; align-items: center; gap: 12px; padding: 9px 14px; border-bottom: 1px solid var(--line); }
.search-suggest a:hover { background: var(--bg); }
.search-suggest img { width: 42px; height: 42px; object-fit: cover; border-radius: 8px; }
.search-suggest .s-price { color: var(--accent); font-weight: 700; margin-left: auto; }

.header-actions { display: flex; align-items: center; gap: 6px; }
.h-action { display: flex; align-items: center; gap: 8px; padding: 8px 10px; border-radius: var(--radius-sm); position: relative; color: var(--ink); }
.h-action:hover { background: var(--bg); }
.h-action i { font-size: 20px; }
.h-action .h-label { display: flex; flex-direction: column; font-size: 12px; line-height: 1.15; color: var(--muted); }
.h-action .h-label b { color: var(--ink); font-size: 14px; }
.badge-count {
    position: absolute; top: 2px; left: 22px; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 10px;
    background: var(--accent); color: #fff; font-size: 11px; font-weight: 700; display: grid; place-items: center;
}
.menu-toggle { display: none; border: 0; background: none; font-size: 22px; padding: 6px; cursor: pointer; color: var(--ink); }

/* Category nav */
.nav-bar { border-top: 1px solid var(--line); }
.nav-bar .container { display: flex; align-items: center; gap: 4px; }
.all-cats-btn {
    display: flex; align-items: center; gap: 10px; background: var(--primary); color: #fff; padding: 11px 18px;
    font-weight: 600; border: 0; cursor: pointer; border-radius: 0; min-width: 240px;
}
.nav-links { display: flex; align-items: center; overflow-x: auto; scrollbar-width: none; }
.nav-links::-webkit-scrollbar { display: none; }
.nav-item { position: relative; }
.nav-item > a { display: flex; align-items: center; gap: 6px; padding: 11px 14px; font-weight: 500; white-space: nowrap; color: var(--ink); }
.nav-item > a:hover { color: var(--primary); }
.nav-item .nav-hot { color: var(--accent); font-weight: 700; }
.dropdown {
    position: absolute; top: 100%; left: 0; background: #fff; min-width: 220px; border-radius: 0 0 var(--radius) var(--radius);
    box-shadow: var(--shadow-lg); padding: 8px; opacity: 0; visibility: hidden; transform: translateY(8px); transition: .2s; z-index: 55;
}
.dropdown a { display: block; padding: 8px 12px; border-radius: 8px; }
.dropdown a:hover { background: var(--primary-soft); color: var(--primary-dark); }

/* Off-canvas drawer (mobile) */
.drawer-backdrop { position: fixed; inset: 0; background: rgba(15, 23, 42, .5); opacity: 0; visibility: hidden; transition: .25s; z-index: 90; }
.drawer {
    position: fixed; top: 0; bottom: 0; left: 0; width: min(320px, 86vw); background: #fff; z-index: 95;
    transform: translateX(-100%); transition: .3s; overflow-y: auto; display: flex; flex-direction: column;
}
body.drawer-open .drawer { transform: none; }
body.drawer-open .drawer-backdrop { opacity: 1; visibility: visible; }
.drawer-head { display: flex; align-items: center; justify-content: space-between; padding: 14px 16px; background: var(--primary); color: #fff; }
.drawer-head button { background: none; border: 0; color: #fff; font-size: 22px; cursor: pointer; }
.drawer-cat > a, .drawer-cat > button {
    width: 100%; display: flex; align-items: center; gap: 12px; padding: 12px 16px; border: 0; background: none;
    border-bottom: 1px solid var(--line); text-align: left; cursor: pointer; color: var(--ink); font-weight: 500;
}
.drawer-cat i.cat-ico { width: 22px; color: var(--primary); }
.drawer-cat .chev { margin-left: auto; transition: .2s; font-size: 12px; color: var(--muted); }
.drawer-cat.open .chev { transform: rotate(180deg); }
.drawer-sub { display: none; background: var(--bg); }
.drawer-cat.open .drawer-sub { display: block; }
.drawer-sub a { display: block; padding: 10px 16px 10px 50px; font-size: 14px; border-bottom: 1px solid var(--line); }
.drawer-foot { margin-top: auto; padding: 16px; display: flex; flex-direction: column; gap: 10px; }

/* Mobile bottom nav */
.mobile-nav {
    display: none; position: fixed; bottom: 0; left: 0; right: 0; background: #fff; z-index: 80;
    box-shadow: 0 -2px 14px rgba(15, 23, 42, .1); padding-bottom: env(safe-area-inset-bottom);
}
.mobile-nav a, .mobile-nav button {
    flex: 1; display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 8px 0 6px;
    font-size: 11px; color: var(--muted); background: none; border: 0; position: relative; cursor: pointer;
}
.mobile-nav i { font-size: 19px; }
.mobile-nav .active { color: var(--primary); }
.mobile-nav .badge-count { left: 50%; margin-left: 4px; top: 2px; }

/* ---------- Flash toast ---------- */
.toast-wrap { position: fixed; top: 90px; right: 16px; z-index: 120; display: flex; flex-direction: column; gap: 10px; }
.toast {
    background: #fff; border-left: 4px solid var(--success); box-shadow: var(--shadow-lg); padding: 12px 16px;
    border-radius: var(--radius-sm); display: flex; align-items: center; gap: 10px; min-width: 260px; max-width: 360px;
    animation: toastIn .3s ease;
}
.toast.error { border-color: var(--danger); }
.toast i { font-size: 18px; color: var(--success); }
.toast.error i { color: var(--danger); }
@keyframes toastIn { from { opacity: 0; transform: translateX(30px); } }

/* ---------- Sections ---------- */
main { min-height: 50vh; }
.section { margin: 26px 0; }
.section-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 14px; flex-wrap: wrap; }
.section-title { font-size: 22px; margin: 0; display: flex; align-items: center; gap: 10px; }
.section-title::before { content: ''; width: 5px; height: 24px; border-radius: 4px; background: linear-gradient(var(--primary), var(--accent)); }
.see-all { color: var(--primary); font-weight: 600; display: inline-flex; align-items: center; gap: 6px; }
.see-all:hover { color: var(--accent); }
.panel { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); padding: 18px; }

/* ---------- Hero Section (Slider + Right 3 Figures) ---------- */
.hero {
    display: grid;
    grid-template-columns: 1fr 290px;
    gap: 14px;
    margin-top: 16px;
    align-items: stretch;
}
.hero-cats { display: none; }
.hero-side { display: none; }

.slider {
    position: relative;
    border-radius: var(--radius);
    overflow: hidden;
    min-height: 380px;
    height: 100%;
    box-shadow: var(--shadow);
    background: #f8fafc;
    width: 100%;
}

/* Right Side Column (3 Figures) */
.hero-banners {
    display: flex;
    flex-direction: column;
    gap: 10px;
    height: 100%;
    justify-content: space-between;
}

.hero-banner-card {
    display: block;
    border-radius: var(--radius-sm);
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: transform .25s ease, box-shadow .25s ease;
    background: #fff;
    position: relative;
}
.hero-banner-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.hero-banner-card.banner-top,
.hero-banner-card.banner-mid {
    flex: 1;
    min-height: 110px;
}

.hero-banner-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.hero-banner-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    flex: 1.15;
    min-height: 130px;
}

.hero-banner-card.banner-half {
    height: 100%;
}
.slide {
    position: absolute; inset: 0; display: flex; align-items: center; padding: 40px 48px; color: #fff;
    opacity: 0; pointer-events: none; transition: opacity .6s ease-in-out; background-size: cover; background-position: center;
}
.slide.active { opacity: 1; pointer-events: auto; z-index: 1; }
.slide:not(.slide-banner)::after {
    content: ''; position: absolute; right: -60px; bottom: -60px; width: 320px; height: 320px; border-radius: 50%;
    background: rgba(255, 255, 255, .12); box-shadow: -120px -80px 0 -40px rgba(255, 255, 255, .08);
}
.slide.slide-banner {
    padding: 0;
    display: block;
    cursor: pointer;
    text-decoration: none;
}
.slide.slide-banner::after { display: none; }
.slide-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
.slide-content { position: relative; z-index: 2; max-width: 460px; }
.slide-tag { display: inline-block; background: rgba(255, 255, 255, .2); padding: 4px 12px; border-radius: 30px; font-size: 13px; margin-bottom: 12px; backdrop-filter: blur(4px); }
.slide h2 { color: #fff; font-size: 38px; margin-bottom: 10px; }
.slide p { font-size: 17px; opacity: .92; margin: 0 0 20px; }
.slide .btn { background: #fff; color: var(--ink); }
.slide .btn:hover { background: var(--accent); color: #fff; }
.slider-dots { position: absolute; bottom: 14px; left: 50%; transform: translateX(-50%); display: flex; gap: 8px; z-index: 3; }
.slider-dots button { width: 10px; height: 10px; border-radius: 10px; border: 0; background: rgba(255, 255, 255, .6); box-shadow: 0 1px 3px rgba(0,0,0,.3); cursor: pointer; transition: .3s; padding: 0; }
.slider-dots button.active { width: 28px; background: #fff; }
.slider-arrow {
    position: absolute; top: 50%; transform: translateY(-50%); z-index: 3; width: 38px; height: 38px; border-radius: 50%;
    border: 0; background: rgba(255, 255, 255, .25); color: #fff; cursor: pointer; backdrop-filter: blur(4px);
}
.slider-arrow:hover { background: rgba(255, 255, 255, .45); }
.slider-arrow.prev { left: 12px; } .slider-arrow.next { right: 12px; }

.hero-side { display: grid; gap: 16px; }
.promo-card {
    border-radius: var(--radius); padding: 22px; color: #fff; position: relative; overflow: hidden; display: flex;
    flex-direction: column; justify-content: center; min-height: 162px;
}
.promo-card h3 { color: #fff; font-size: 20px; margin-bottom: 4px; }
.promo-card p { margin: 0 0 12px; opacity: .9; font-size: 14px; }
.promo-card .promo-ico { position: absolute; right: -8px; bottom: -14px; font-size: 92px; opacity: .2; }
.promo-card a { font-weight: 700; display: inline-flex; gap: 6px; align-items: center; }
.promo-1 { background: linear-gradient(135deg, #f97316, #db2777); }
.promo-2 { background: linear-gradient(135deg, #0ea5e9, #1d4ed8); }

/* Features strip */
.features { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin-top: 18px; }
.feature { background: #fff; border-radius: var(--radius); padding: 16px; display: flex; align-items: center; gap: 14px; box-shadow: var(--shadow); }
.feature-ico { width: 46px; height: 46px; border-radius: 12px; display: grid; place-items: center; font-size: 20px; background: var(--primary-soft); color: var(--primary); flex-shrink: 0; }
.feature:nth-child(2) .feature-ico { background: var(--accent-soft); color: var(--accent); }
.feature:nth-child(3) .feature-ico { background: #ede9fe; color: #7c3aed; }
.feature:nth-child(4) .feature-ico { background: #dbeafe; color: #2563eb; }
.feature b { display: block; color: var(--ink); }
.feature small { color: var(--muted); }

/* Category grid */
.cat-grid { display: grid; grid-template-columns: repeat(8, 1fr); gap: 14px; }
.cat-tile { background: #fff; border-radius: var(--radius); padding: 18px 10px; text-align: center; box-shadow: var(--shadow); transition: .25s; }
.cat-tile:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.cat-tile .cat-ico {
    width: 64px; height: 64px; margin: 0 auto 10px; border-radius: 50%; display: grid; place-items: center; font-size: 26px;
    background: linear-gradient(135deg, var(--primary-soft), var(--accent-soft)); color: var(--primary-dark);
}
.cat-tile b { display: block; color: var(--ink); font-size: 14px; }
.cat-tile small { color: var(--muted); font-size: 12px; }

/* Flash sale */
.flash { background: linear-gradient(120deg, #2563eb, #1e3a8a); border-radius: var(--radius); padding: 18px; }
.flash .section-title { color: #fff; }
.flash .section-title::before { background: var(--accent); }
.flash .see-all { color: #fff; }
.countdown { display: flex; align-items: center; gap: 6px; color: #fff; font-weight: 600; }
.countdown span { background: var(--accent); min-width: 40px; padding: 5px 6px; border-radius: 8px; text-align: center; font-size: 17px; }

/* Product grid & card */
.product-grid { display: grid; grid-template-columns: repeat(6, 1fr); gap: 14px; }
.product-grid.cols-5 { grid-template-columns: repeat(5, 1fr); }
.product-grid.cols-4 { grid-template-columns: repeat(4, 1fr); }
.scroller { display: grid; grid-auto-flow: column; grid-auto-columns: calc((100% - 70px) / 6); gap: 14px; overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: 6px; scrollbar-width: thin; }
.scroller > * { scroll-snap-align: start; }

.p-card { background: #fff; border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); display: flex; flex-direction: column; transition: .25s; position: relative; }
.p-card:hover { box-shadow: var(--shadow-lg); transform: translateY(-3px); }
.p-thumb { position: relative; aspect-ratio: 1; background: #f8fafc; overflow: hidden; }
.p-thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s; }
.p-card:hover .p-thumb img { transform: scale(1.06); }
.p-badge { position: absolute; top: 10px; left: 10px; background: var(--accent); color: #fff; font-size: 12px; font-weight: 700; padding: 3px 9px; border-radius: 20px; z-index: 2; }
.p-badge.out { background: var(--muted); }
.p-wish {
    position: absolute; top: 8px; right: 8px; z-index: 2; width: 34px; height: 34px; border-radius: 50%; border: 0;
    background: #fff; color: var(--muted); box-shadow: var(--shadow); cursor: pointer; display: grid; place-items: center;
}
.p-wish:hover, .p-wish.on { color: #e11d48; }
.p-body { padding: 12px; display: flex; flex-direction: column; gap: 5px; flex: 1; }
.p-name { color: var(--ink); font-weight: 500; font-size: 14px; line-height: 1.35; height: 2.7em; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.p-name:hover { color: var(--primary); }
.p-rating { color: #f59e0b; font-size: 12px; display: flex; align-items: center; gap: 4px; }
.p-rating span { color: var(--muted); }
.p-price { display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; margin-top: auto; }
.p-price b { color: var(--accent); font-size: 18px; }
.p-price del { color: var(--muted); font-size: 13px; }
.p-cart {
    margin-top: 8px; width: 100%; border: 1px solid var(--primary); color: var(--primary); background: #fff;
    border-radius: var(--radius-sm); padding: 7px; font-weight: 600; cursor: pointer; transition: .2s;
    display: flex; align-items: center; justify-content: center; gap: 6px;
}
.p-cart:hover { background: var(--primary); color: #fff; }
.p-cart:disabled { border-color: var(--line); color: var(--muted); background: var(--bg); cursor: not-allowed; }

/* Promo banners */
.banner-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.banner {
    border-radius: var(--radius); padding: 28px; color: #fff; display: flex; align-items: center; justify-content: space-between;
    gap: 16px; min-height: 150px; overflow: hidden; position: relative;
}
.banner h3 { color: #fff; font-size: 24px; margin-bottom: 4px; }
.banner p { margin: 0 0 12px; opacity: .9; }
.banner .big-ico { font-size: 80px; opacity: .3; }
.banner-1 { background: linear-gradient(120deg, #7c3aed, #c026d3); }
.banner-2 { background: linear-gradient(120deg, #ea580c, #f59e0b); }

/* Tabs */
.tabs { display: flex; gap: 6px; background: #fff; padding: 5px; border-radius: 40px; box-shadow: var(--shadow); }
.tabs button { border: 0; background: none; padding: 7px 16px; border-radius: 30px; cursor: pointer; font-weight: 600; color: var(--muted); }
.tabs button.active { background: var(--primary); color: #fff; }
.tab-pane { display: none; }
.tab-pane.active { display: block; }

/* Brands */
.brand-strip { display: grid; grid-template-columns: repeat(10, 1fr); gap: 12px; }
.brand-chip {
    background: #fff; border-radius: var(--radius); height: 74px; display: grid; place-items: center; box-shadow: var(--shadow);
    font-weight: 700; font-size: 16px; color: var(--ink); letter-spacing: .5px; transition: .2s; padding: 8px;
}
.brand-chip:hover { color: var(--primary); transform: translateY(-3px); }
.brand-chip img { max-height: 50px; object-fit: contain; }

/* Newsletter */
.newsletter {
    background: linear-gradient(120deg, var(--ink), #1e293b); color: #e2e8f0; border-radius: var(--radius); padding: 30px;
    display: flex; align-items: center; justify-content: space-between; gap: 20px; flex-wrap: wrap;
}
.newsletter h3 { color: #fff; font-size: 24px; }
.newsletter form { display: flex; gap: 8px; flex: 1; max-width: 460px; }
.newsletter input { flex: 1; min-width: 0; border-radius: 40px; border: 0; padding: 12px 18px; }
.newsletter .btn { border-radius: 40px; }

/* ---------- Breadcrumb ---------- */
.breadcrumb { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; font-size: 14px; color: var(--muted); padding: 14px 0; }
.breadcrumb a:hover { color: var(--primary); }
.breadcrumb i { font-size: 10px; }

/* ---------- Shop listing ---------- */
.shop-layout { display: grid; grid-template-columns: 260px 1fr; gap: 20px; align-items: start; }
.filters { position: sticky; top: 140px; }
.filter-block { border-bottom: 1px solid var(--line); padding: 14px 0; }
.filter-block:first-child { padding-top: 0; }
.filter-block:last-child { border: 0; }
.filter-block h4 { font-size: 15px; margin-bottom: 10px; }
.filter-block label { display: flex; align-items: center; gap: 8px; padding: 4px 0; cursor: pointer; font-size: 14px; }
.filter-block input[type=checkbox] { accent-color: var(--primary); width: 16px; height: 16px; }
.filter-cats a { display: block; padding: 5px 0; font-size: 14px; }
.filter-cats a.active, .filter-cats a:hover { color: var(--primary); font-weight: 600; }
.filter-cats .sub { padding-left: 14px; }
.price-inputs { display: flex; gap: 8px; }
.price-inputs input { padding: 8px 10px; }
.shop-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 14px; flex-wrap: wrap; }
.shop-toolbar select { width: auto; padding: 8px 12px; }
.filter-toggle { display: none; }
.empty-state { text-align: center; padding: 60px 20px; }
.empty-state i { font-size: 56px; color: var(--line); margin-bottom: 14px; }

/* Pagination */
.pagination { display: flex; justify-content: center; gap: 6px; margin: 24px 0; flex-wrap: wrap; }
.pagination a, .pagination span {
    min-width: 38px; height: 38px; padding: 0 10px; display: grid; place-items: center; border-radius: var(--radius-sm);
    background: #fff; box-shadow: var(--shadow); font-weight: 600;
}
.pagination .active { background: var(--primary); color: #fff; }
.pagination .disabled { opacity: .45; }

/* ---------- Product detail ---------- */
.pd { display: grid; grid-template-columns: 1fr 1fr; gap: 28px; }
.pd-gallery .main-img { border-radius: var(--radius); overflow: hidden; background: #f8fafc; aspect-ratio: 1; }
.pd-gallery .main-img img { width: 100%; height: 100%; object-fit: cover; transition: transform .35s ease; }
@media (hover: hover) {
    .pd-gallery .main-img { cursor: zoom-in; }
    .pd-gallery .main-img:hover img { transform: scale(1.1); }
}
.thumbs { display: flex; gap: 10px; margin-top: 12px; overflow-x: auto; }
.thumbs img { width: 74px; height: 74px; object-fit: cover; border-radius: var(--radius-sm); cursor: pointer; border: 2px solid transparent; }
.thumbs img.active { border-color: var(--primary); }
.pd-info h1 { font-size: 26px; }
.pd-meta { display: flex; flex-wrap: wrap; gap: 16px; font-size: 14px; color: var(--muted); margin-bottom: 12px; }
.pd-meta b { color: var(--ink); }
.pd-price { display: flex; align-items: baseline; gap: 12px; margin: 14px 0; padding: 14px 16px; background: var(--accent-soft); border-radius: var(--radius-sm); flex-wrap: wrap; }
.pd-price b { font-size: 30px; color: var(--accent-dark); }
.pd-price del { color: var(--muted); }
.pd-price .save { background: var(--accent); color: #fff; font-size: 13px; padding: 2px 10px; border-radius: 20px; font-weight: 700; }
.stock-pill { display: inline-flex; align-items: center; gap: 6px; padding: 4px 12px; border-radius: 20px; font-size: 13px; font-weight: 600; }
.stock-pill.in { background: #dcfce7; color: var(--success); }
.stock-pill.low { background: #fef3c7; color: var(--warning); }
.stock-pill.out { background: #fee2e2; color: var(--danger); }
.qty { display: inline-flex; border: 1px solid var(--line); border-radius: var(--radius-sm); overflow: hidden; background: #fff; }
.qty button { width: 40px; border: 0; background: var(--bg); cursor: pointer; font-size: 16px; }
.qty input { width: 54px; text-align: center; border: 0; padding: 9px 0; outline: none; -moz-appearance: textfield; }
.qty input::-webkit-outer-spin-button, .qty input::-webkit-inner-spin-button { -webkit-appearance: none; }
.pd-actions { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin: 18px 0; }
.pd-perks { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 16px; }
.pd-perks div { display: flex; gap: 10px; align-items: center; font-size: 14px; padding: 10px; border: 1px dashed var(--line); border-radius: var(--radius-sm); }
.pd-perks i { color: var(--primary); font-size: 18px; }
.desc-content ul { padding-left: 20px; }

/* ---------- Cart / checkout ---------- */
.cart-layout { display: grid; grid-template-columns: 1fr 360px; gap: 20px; align-items: start; }
.cart-item { display: grid; grid-template-columns: 84px 1fr auto; gap: 14px; padding: 14px 0; border-bottom: 1px solid var(--line); align-items: center; }
.cart-item:last-child { border: 0; }
.cart-item img { width: 84px; height: 84px; object-fit: cover; border-radius: var(--radius-sm); }
.cart-item .ci-name { font-weight: 600; color: var(--ink); }
.cart-item .ci-controls { display: flex; align-items: center; gap: 10px; margin-top: 8px; flex-wrap: wrap; }
.cart-item .ci-total { font-weight: 700; color: var(--ink); text-align: right; }
.link-danger { color: var(--danger); background: none; border: 0; cursor: pointer; font-size: 13px; }
.summary-row { display: flex; justify-content: space-between; padding: 8px 0; }
.summary-row.total { border-top: 2px dashed var(--line); margin-top: 6px; padding-top: 14px; font-size: 18px; font-weight: 700; color: var(--ink); }
.sticky { position: sticky; top: 140px; }
.pay-options { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.pay-option { border: 2px solid var(--line); border-radius: var(--radius-sm); padding: 12px; cursor: pointer; display: flex; align-items: center; gap: 10px; font-weight: 600; transition: .2s; }
.pay-option input { accent-color: var(--primary); }
.pay-option:has(input:checked) { border-color: var(--primary); background: var(--primary-soft); }
.pay-option .pay-logo { width: 34px; height: 34px; border-radius: 8px; display: grid; place-items: center; color: #fff; font-size: 14px; flex-shrink: 0; }
.pay-note { background: #fdf2f8; border: 1px dashed #db2777; border-radius: var(--radius-sm); padding: 12px; margin-top: 12px; font-size: 14px; display: none; }
.pay-note.show { display: block; }
.mini-line { display: flex; gap: 10px; align-items: center; padding: 8px 0; border-bottom: 1px solid var(--line); font-size: 14px; }
.mini-line img { width: 48px; height: 48px; border-radius: 8px; object-fit: cover; }
.mini-line .ml-name { flex: 1; }

.success-box { max-width: 640px; margin: 30px auto; text-align: center; }
.success-ico { width: 84px; height: 84px; margin: 0 auto 16px; border-radius: 50%; background: #dcfce7; color: var(--success); display: grid; place-items: center; font-size: 40px; }

/* Order status timeline */
.timeline { display: flex; justify-content: space-between; position: relative; margin: 24px 0; }
.timeline::before { content: ''; position: absolute; top: 17px; left: 6%; right: 6%; height: 3px; background: var(--line); }
.timeline .step { position: relative; z-index: 1; text-align: center; flex: 1; font-size: 13px; color: var(--muted); }
.timeline .dot { width: 36px; height: 36px; border-radius: 50%; margin: 0 auto 6px; display: grid; place-items: center; background: #fff; border: 3px solid var(--line); }
.timeline .step.done { color: var(--ink); font-weight: 600; }
.timeline .step.done .dot { background: var(--primary); border-color: var(--primary); color: #fff; }

/* Tables */
.table-wrap { overflow-x: auto; }
.table { width: 100%; border-collapse: collapse; font-size: 14px; }
.table th, .table td { padding: 11px 12px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: middle; }
.table th { background: var(--bg); color: var(--ink); font-weight: 600; white-space: nowrap; }
.status { display: inline-block; padding: 3px 10px; border-radius: 20px; font-size: 12px; font-weight: 700; text-transform: capitalize; }
.status.warning { background: #fef3c7; color: #b45309; }
.status.info { background: #e0f2fe; color: #0369a1; }
.status.primary { background: #ede9fe; color: #6d28d9; }
.status.success { background: #dcfce7; color: #15803d; }
.status.danger { background: #fee2e2; color: #b91c1c; }

/* Auth & account */
.auth-card { max-width: 440px; margin: 40px auto; }
.auth-card .panel { padding: 30px; }
.auth-head { text-align: center; margin-bottom: 20px; }
.auth-head .logo { justify-content: center; margin-bottom: 18px; }
.auth-head .logo img { max-height: 56px; }
.account-layout { display: grid; grid-template-columns: 260px 1fr; gap: 20px; align-items: start; }
.account-nav a { display: flex; align-items: center; gap: 10px; padding: 11px 14px; border-radius: var(--radius-sm); font-weight: 500; }
.account-nav a:hover, .account-nav a.active { background: var(--primary-soft); color: var(--primary-dark); }
.account-nav button { width: 100%; display: flex; align-items: center; gap: 10px; padding: 11px 14px; border: 0; background: none; color: var(--danger); cursor: pointer; font-weight: 500; }
.user-head { display: flex; align-items: center; gap: 12px; padding-bottom: 14px; margin-bottom: 10px; border-bottom: 1px solid var(--line); }
.avatar { width: 48px; height: 48px; border-radius: 50%; background: linear-gradient(135deg, var(--primary), var(--accent)); color: #fff; display: grid; place-items: center; font-weight: 700; font-size: 18px; flex-shrink: 0; }
.stat-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin-bottom: 20px; }
.stat-card { background: #fff; border-radius: var(--radius); box-shadow: var(--shadow); padding: 16px; display: flex; align-items: center; gap: 14px; }

/* ---------- Footer ---------- */
.site-footer { background: #0b1220; color: #94a3b8; margin-top: 40px; }
.footer-top { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1.2fr; gap: 30px; padding: 44px 0 30px; }
.site-footer h4 { color: #fff; font-size: 16px; margin-bottom: 14px; }
.site-footer ul { list-style: none; margin: 0; padding: 0; }
.site-footer li { margin-bottom: 9px; }
.site-footer a:hover { color: #fff; }
.site-footer .logo-text strong { color: #fff; }
.footer-contact li { display: flex; gap: 10px; }
.footer-contact i { color: var(--accent); margin-top: 4px; }
.socials { display: flex; gap: 8px; margin-top: 14px; }
.socials a { width: 36px; height: 36px; border-radius: 50%; background: rgba(255, 255, 255, .08); display: grid; place-items: center; transition: .2s; }
.socials a:hover { background: var(--accent); color: #fff; }
.pay-badges { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.pay-badges span { background: #fff; color: var(--ink); font-weight: 700; font-size: 12px; padding: 5px 10px; border-radius: 6px; }
.footer-bottom { border-top: 1px solid rgba(255, 255, 255, .08); padding: 16px 0; font-size: 14px; }
.footer-bottom .container { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; }
.dev-credit { display: inline-flex; align-items: center; gap: 8px; }
.dev-credit a { color: #fff; font-weight: 600; }
.tg-btn { display: inline-flex; align-items: center; gap: 6px; background: #229ED9; color: #fff !important; padding: 5px 12px; border-radius: 30px; font-size: 13px; font-weight: 600; }
.tg-btn:hover { background: #1b8bc0; }
.back-top {
    position: fixed; right: 16px; bottom: 24px; width: 44px; height: 44px; border-radius: 50%; border: 0; background: var(--primary);
    color: #fff; box-shadow: var(--shadow-lg); cursor: pointer; opacity: 0; visibility: hidden; transition: .3s; z-index: 70;
}
.back-top.show { opacity: 1; visibility: visible; }
.tg-float {
    position: fixed; left: 20px; bottom: 82px; width: 48px; height: 48px; border-radius: 50%; background: #229ED9; color: #fff !important;
    display: grid; place-items: center; font-size: 24px; box-shadow: 0 6px 20px rgba(34, 158, 217, .45); z-index: 90; transition: all .25s ease;
}
.tg-float:hover {
    background: #1b8bc0; transform: translateY(-3px) scale(1.05); box-shadow: 0 8px 24px rgba(34, 158, 217, .55);
}

/* WhatsApp & Call To Order (Othoba style) */
.btn-whatsapp {
    background: #25D366 !important;
    color: #fff !important;
    border: none;
    font-weight: 700;
    font-size: 15px;
    box-shadow: 0 4px 14px rgba(37, 211, 102, .3);
    transition: all .2s ease;
}
.btn-whatsapp:hover {
    background: #20ba5a !important;
    transform: translateY(-1px);
    box-shadow: 0 6px 18px rgba(37, 211, 102, .4);
}
.quick-order-actions {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin: 14px 0 10px;
}
.call-order-pill {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 11px 16px;
    border-radius: var(--radius-sm);
    background: #fff;
    border: 1.5px dashed var(--primary);
    color: var(--ink);
    font-size: 14px;
    transition: all .2s ease;
}
.call-order-pill:hover {
    background: var(--primary-soft);
    border-color: var(--primary-dark);
}
.call-order-pill i {
    color: var(--primary);
    font-size: 18px;
    animation: phone-ring 2s infinite ease-in-out;
}
@keyframes phone-ring {
    0%, 100% { transform: rotate(0deg); }
    10%, 30% { transform: rotate(-12deg); }
    20%, 40% { transform: rotate(12deg); }
    50% { transform: rotate(0deg); }
}

/* Othoba Delivery & Guarantees Box */
.othoba-features-box {
    margin-top: 18px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: #fff;
    overflow: hidden;
    box-shadow: var(--shadow);
}
.ofb-title {
    padding: 10px 14px;
    background: #f8fafc;
    border-bottom: 1px solid var(--line);
    font-weight: 700;
    font-size: 13px;
    color: var(--ink);
    display: flex;
    align-items: center;
    gap: 8px;
}
.ofb-title i {
    color: var(--primary);
}
.ofb-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0;
}
.ofb-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 10px 14px;
    border-bottom: 1px solid #f1f5f9;
}
.ofb-item:last-child {
    border-bottom: none;
}
.ofb-item i {
    color: var(--primary);
    font-size: 18px;
    margin-top: 2px;
    width: 22px;
    flex-shrink: 0;
    text-align: center;
}
.ofb-item div {
    display: flex;
    flex-direction: column;
}
.ofb-item strong {
    font-size: 13px;
    color: var(--ink);
    line-height: 1.3;
}
.ofb-item span {
    font-size: 12px;
    color: var(--muted);
    line-height: 1.3;
}

/* Floating WhatsApp Button */
.wa-float {
    position: fixed;
    left: 20px;
    bottom: 24px;
    height: 48px;
    padding: 0 16px 0 14px;
    border-radius: 30px;
    background: #25D366;
    color: #fff !important;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    font-weight: 700;
    box-shadow: 0 6px 20px rgba(37, 211, 102, .45);
    z-index: 90;
    transition: all .25s ease;
    text-decoration: none;
}
.wa-float i {
    font-size: 24px;
}
.wa-float:hover {
    background: #20ba5a;
    transform: translateY(-3px) scale(1.02);
    box-shadow: 0 8px 24px rgba(37, 211, 102, .55);
}
@media (max-width: 992px) {
    .wa-float {
        bottom: 74px;
        left: 14px;
        padding: 0;
        width: 48px;
        height: 48px;
        border-radius: 50%;
        justify-content: center;
    }
    .wa-float .wa-float-text {
        display: none;
    }
    .tg-float {
        bottom: 128px;
        left: 14px;
    }
}

/* ---------- Responsive ---------- */
@media (hover: hover) and (min-width: 993px) {
    .nav-item:hover .dropdown { opacity: 1; visibility: visible; transform: none; }
}
@media (max-width: 1200px) {
    .product-grid { grid-template-columns: repeat(5, 1fr); }
    .scroller { grid-auto-columns: calc((100% - 56px) / 5); }
    .hero { grid-template-columns: 1fr; }
    .hero-side { display: grid; grid-template-columns: 1fr 1fr; }
    .brand-strip { grid-template-columns: repeat(5, 1fr); }
}
@media (max-width: 992px) {
    .menu-toggle { display: block; }
    .nav-bar, .hero-cats, .h-action .h-label, .topbar-links .hide-md { display: none; }
    .header-main { flex-wrap: wrap; gap: 10px; padding: 10px 0; }
    .search { order: 3; flex-basis: 100%; max-width: none; }
    .header-actions { margin-left: auto; }
    .hero { grid-template-columns: 1fr; margin-top: 12px; }
    .slider { min-height: 260px; height: auto; aspect-ratio: 2 / 1; }
    .hero-banners { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
    .hero-banner-row { grid-column: span 2; }
    .product-grid, .product-grid.cols-5 { grid-template-columns: repeat(4, 1fr); }
    .product-grid.cols-4 { grid-template-columns: repeat(3, 1fr); }
    .scroller { grid-auto-columns: calc((100% - 42px) / 4); }
    .cat-grid { grid-template-columns: repeat(4, 1fr); }
    .features { grid-template-columns: repeat(2, 1fr); }
    .shop-layout, .account-layout, .cart-layout, .pd { grid-template-columns: 1fr; }
    .filters { position: fixed; top: 0; bottom: 0; left: 0; width: min(320px, 88vw); z-index: 95; overflow-y: auto; border-radius: 0; transform: translateX(-100%); transition: .3s; }
    body.filters-open .filters { transform: none; }
    body.filters-open .drawer-backdrop { opacity: 1; visibility: visible; }
    .filter-toggle { display: inline-flex; }
    .sticky { position: static; }
    .footer-top { grid-template-columns: 1fr 1fr; }
    .mobile-nav { display: flex; }
    body { padding-bottom: 64px; }
    .back-top { bottom: 80px; }
    .tg-float { bottom: 80px; }
}
@media (max-width: 640px) {
    body { font-size: 14px; }
    .topbar-notice { display: none; }
    .topbar .container { justify-content: center; }
    .logo-text small { display: none; }
    .logo-mark { width: 36px; height: 36px; font-size: 17px; }
    .logo-text strong { font-size: 19px; }
    .h-action { padding: 6px; }
    .h-action.hide-sm { display: none; }
    .product-grid, .product-grid.cols-5, .product-grid.cols-4 { grid-template-columns: repeat(2, 1fr); gap: 10px; }
    .scroller { grid-auto-columns: 44%; gap: 10px; }
    .cat-grid { grid-template-columns: repeat(4, 1fr); gap: 8px; }
    .cat-tile { padding: 10px 4px; box-shadow: none; background: transparent; }
    .cat-tile .cat-ico { width: 54px; height: 54px; font-size: 22px; box-shadow: var(--shadow); background: #fff; }
    .cat-tile b { font-size: 12px; font-weight: 500; }
    .cat-tile small { display: none; }
    .features { gap: 10px; }
    .feature { padding: 12px; gap: 10px; flex-direction: column; text-align: center; }
    .slider { width: 100%; height: auto; min-height: 180px; aspect-ratio: 2 / 1; }
    .hero-banners { grid-template-columns: 1fr; }
    .hero-banner-row { grid-column: span 1; }
    .slide { padding: 24px; }
    .slide h2 { font-size: 24px; }
    .slide p { font-size: 14px; margin-bottom: 12px; }
    .slider-dots { left: 50%; transform: translateX(-50%); }
    .slider-arrow { display: none; }
    .banner-row { grid-template-columns: 1fr; }
    .brand-strip { grid-template-columns: repeat(3, 1fr); }
    .section-title { font-size: 18px; }
    .p-body { padding: 10px; }
    .p-price b { font-size: 16px; }
    .form-row, .pay-options, .pd-perks { grid-template-columns: 1fr; }
    .stat-cards { grid-template-columns: 1fr; }
    .footer-top { grid-template-columns: 1fr; gap: 22px; }
    .footer-bottom .container { flex-direction: column; text-align: center; }
    .pd-info h1 { font-size: 21px; }
    .pd-actions .btn { flex: 1; }
    .cart-item { grid-template-columns: 70px 1fr; }
    .cart-item img { width: 70px; height: 70px; }
    .cart-item .ci-total { grid-column: 2; text-align: left; }
    .timeline .step { font-size: 11px; }
    .newsletter { padding: 22px; }
    .newsletter form { flex-direction: column; }
    .toast-wrap { left: 16px; right: 16px; top: 76px; }
    .toast { max-width: none; }
}
