/* ══════════════════════════════════════════════════════════════════
   DAHAN Premium E-Commerce Design System
   Inspired by Shwapno.com — Bangladesh's #1 E-Commerce UI Pattern
   আহাদ কনজ্যুমার প্রোডাক্টস্ | দহন সস্ না খাইলেই লস্
   ══════════════════════════════════════════════════════════════════ */

/* ── 1. GOOGLE FONTS: Bengali + English ── */
@import url('https://fonts.googleapis.com/css2?family=Hind+Siliguri:wght@300;400;500;600;700&family=Noto+Sans+Bengali:wght@400;500;600;700&family=Inter:wght@300;400;500;600;700;800&family=Poppins:wght@400;500;600;700;800&display=swap');

/* ── 2. DESIGN TOKENS ── */
:root {
    /* Brand Colors */
    --red:          #c62828;
    --red-dark:     #a61b1b;
    --red-mid:      #d32f2f;
    --red-light:    #ffebee;
    --red-xlight:   #fff5f5;

    /* Gold / Accent */
    --gold:         #f9a825;
    --gold-dark:    #f57f17;
    --gold-light:   #fff8e1;

    /* Neutrals */
    --dark:         #1a1a2e;
    --dark-2:       #212121;
    --text-primary: #212121;
    --text-secondary: #616161;
    --text-muted:   #9e9e9e;
    --divider:      #eeeeee;
    --bg:           #f5f5f5;
    --surface:      #ffffff;
    --border:       #e0e0e0;

    /* Semantic */
    --success:      #2e7d32;
    --success-bg:   #e8f5e9;
    --warning:      #e65100;
    --warning-bg:   #fff3e0;
    --info:         #1565c0;
    --info-bg:      #e3f2fd;

    /* Shadows */
    --shadow-xs:  0 1px 3px rgba(0,0,0,.06);
    --shadow-sm:  0 2px 8px rgba(0,0,0,.08);
    --shadow-md:  0 4px 16px rgba(0,0,0,.10);
    --shadow-lg:  0 8px 32px rgba(0,0,0,.12);
    --shadow-card: 0 2px 10px rgba(0,0,0,.07);
    --shadow-card-hover: 0 8px 28px rgba(0,0,0,.13);

    /* Border Radius */
    --r-xs: 4px;
    --r-sm: 8px;
    --r-md: 12px;
    --r-lg: 16px;
    --r-xl: 24px;
    --r-pill: 9999px;

    /* Transition */
    --ease: all .2s cubic-bezier(.4,0,.2,1);
}

/* ── 3. BASE ── */
*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }
@media (hover: hover) and (pointer: fine) { html { scrollbar-gutter: stable; } }   /* শুধু মাউসওয়ালা কম্পিউটারে, ফোনে ডানে ফাঁকা দাগ নয় */

body {
    font-family: 'Hind Siliguri', 'Noto Sans Bengali', sans-serif;
    color: var(--text-primary);
    background-color: var(--bg);
    line-height: 1.65;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* English mode switch */
body.lang-en,
body.lang-en p,
body.lang-en span,
body.lang-en a,
body.lang-en button,
body.lang-en label,
body.lang-en input,
body.lang-en select,
body.lang-en textarea {
    font-family: 'Inter', 'Poppins', sans-serif;
}

body.lang-en h1,
body.lang-en h2,
body.lang-en h3,
body.lang-en h4,
body.lang-en h5,
body.lang-en h6 {
    font-family: 'Poppins', 'Inter', sans-serif;
}

h1,h2,h3,h4,h5,h6 {
    font-family: 'Hind Siliguri', 'Noto Sans Bengali', sans-serif;
    font-weight: 700;
    letter-spacing: -0.01em;
    color: var(--dark-2);
}

a { color: var(--red); text-decoration: none; }
a:hover { color: var(--red-dark); }

/* ── 4. ANNOUNCEMENT TOP BAR ── */
.top-announcement-bar {
    background: linear-gradient(90deg, var(--red-dark) 0%, var(--red) 50%, var(--red-mid) 100%);
    font-size: 0.82rem;
    font-weight: 500;
    letter-spacing: 0.15px;
    padding: 7px 0;
}

/* Marquee-style ticker for announcements */
.ticker-wrapper {
    overflow: hidden;
    white-space: nowrap;
}

.ticker-content {
    display: inline-block;
    animation: ticker 30s linear infinite;
}

@keyframes ticker {
    0%   { transform: translateX(100%); }
    100% { transform: translateX(-100%); }
}

/* Language Toggle Button */
.lang-toggle-btn {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 4px 12px;
    border-radius: var(--r-pill);
    border: 1.5px solid rgba(255,255,255,0.4);
    background: rgba(255,255,255,0.1);
    color: #fff;
    font-size: 0.78rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--ease);
    white-space: nowrap;
    font-family: 'Inter', sans-serif;
    letter-spacing: 0.03em;
}

.lang-toggle-btn:hover {
    background: rgba(255,255,255,0.25);
    border-color: rgba(255,255,255,0.7);
    transform: scale(1.03);
}

.lang-toggle-btn .lang-flag {
    font-size: 0.95rem;
    line-height: 1;
}

/* ── 5. MAIN NAVBAR (Tier 2) ── */
.main-navbar {
    background: var(--surface);
    box-shadow: var(--shadow-sm);
    padding: 10px 0;
    position: sticky;
    top: 0;
    z-index: 1030;
}

/* Search Bar — Shwapno style: prominent, centered */
.navbar-search-form {
    flex: 1;
    max-width: 480px;
    margin: 0 1rem;
}

.search-wrapper {
    position: relative;
    width: 100%;
}

.search-input {
    width: 100%;
    padding: 11px 48px 11px 48px;
    border-radius: var(--r-pill);
    border: 2px solid var(--border);
    background: var(--bg);
    font-size: 0.92rem;
    color: var(--text-primary);
    font-family: inherit;
    transition: var(--ease);
    outline: none;
}

.search-input:focus {
    border-color: var(--red);
    background: var(--surface);
    box-shadow: 0 0 0 4px rgba(198,40,40,0.10);
}

.search-input::placeholder {
    color: var(--text-muted);
    font-size: 0.88rem;
}

.search-icon-inside {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    font-size: 0.95rem;
    pointer-events: none;
    transition: color 0.2s;
}

.search-wrapper:focus-within .search-icon-inside {
    color: var(--red);
}

.search-btn {
    position: absolute;
    right: 6px;
    top: 50%;
    transform: translateY(-50%);
    background: var(--red);
    color: #fff;
    border: none;
    border-radius: var(--r-pill);
    padding: 6px 16px;
    font-size: 0.82rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--ease);
    font-family: inherit;
}

.search-btn:hover {
    background: var(--red-dark);
}

/* ── 6. CATEGORY NAV BAR (Tier 3) ── */
.category-navbar {
    background: var(--red);
    padding: 0;
    overflow-x: auto;
    scrollbar-width: none;
}

.category-navbar::-webkit-scrollbar { display: none; }

.category-nav-list {
    display: flex;
    list-style: none;
    margin: 0;
    padding: 0;
    white-space: nowrap;
    justify-content: center;
}

.category-nav-item {
    position: relative;
}

.category-nav-link {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 12px 16px;
    color: rgba(255,255,255,0.92) !important;
    font-size: 0.88rem;
    font-weight: 600;
    text-decoration: none;
    transition: var(--ease);
    white-space: nowrap;
    letter-spacing: 0.01em;
}

.category-nav-link.active {
    color: #fff !important;
}

.category-nav-link i {
    font-size: 0.95rem;
}

/* Category Dropdown */
.category-dropdown {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    background: var(--surface);
    border-radius: 0 0 var(--r-md) var(--r-md);
    box-shadow: var(--shadow-lg);
    min-width: 200px;
    z-index: 1050;
    padding: 8px 0;
    border: 1px solid var(--divider);
}

.category-nav-item:hover .category-dropdown {
    display: block;
}

.category-dropdown a {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 16px;
    color: var(--text-secondary);
    font-size: 0.88rem;
    font-weight: 500;
    transition: var(--ease);
}

.category-dropdown a:hover {
    background: var(--red-xlight);
    color: var(--red);
    padding-left: 20px;
}

/* ── 7. BUTTONS ── */
.btn-primary-brand {
    background: linear-gradient(135deg, var(--red) 0%, var(--red-mid) 100%);
    color: #ffffff;
    border: none;
    font-weight: 600;
    font-family: inherit;
    transition: var(--ease);
    box-shadow: 0 2px 8px rgba(198,40,40,.25);
}

.btn-primary-brand:hover {
    background: linear-gradient(135deg, var(--red-dark) 0%, var(--red) 100%);
    color: #ffffff;
    transform: translateY(-1px);
    box-shadow: 0 4px 16px rgba(198,40,40,.35);
}

.btn-primary-brand:active { transform: translateY(0); }

.btn-outline-brand {
    border: 2px solid var(--red);
    color: var(--red);
    font-weight: 600;
    background: transparent;
    font-family: inherit;
    transition: var(--ease);
}

.btn-outline-brand:hover {
    background: var(--red);
    color: #ffffff;
    box-shadow: 0 4px 12px rgba(198,40,40,.25);
}

/* WhatsApp */
.whatsapp-float-btn {
    position: fixed;
    bottom: 25px;
    right: 25px;
    background: #25d366;
    color: #ffffff;
    width: 58px;
    height: 58px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 30px;
    box-shadow: 0 4px 18px rgba(37,211,102,.4);
    z-index: 9999;
    transition: var(--ease);
    text-decoration: none;
}

.whatsapp-float-btn:hover {
    transform: scale(1.12);
    color: #ffffff;
    box-shadow: 0 6px 24px rgba(37,211,102,.55);
}

.whatsapp-header-btn {
    background-color: #25d366;
    color: white !important;
    font-weight: 600;
    border: none;
    transition: var(--ease);
}

.whatsapp-header-btn:hover {
    background-color: #1db954;
    color: white !important;
    transform: translateY(-1px);
}

/* Seller Center */
.seller-center-pill {
    background: var(--gold-light);
    color: var(--gold-dark) !important;
    border: 1.5px solid var(--gold);
    font-weight: 700;
    transition: var(--ease);
}

.seller-center-pill:hover {
    background: var(--gold);
    color: var(--dark-2) !important;
    box-shadow: 0 4px 12px rgba(249,168,37,.3);
}

/* Slogan pill in top bar */
.slogan-pill {
    background: rgba(255,255,255,0.15);
    color: #fff;
    font-weight: 700;
    padding: 2px 10px;
    border-radius: var(--r-pill);
    font-size: 0.8rem;
    display: inline-block;
    border: 1px solid rgba(255,255,255,0.3);
    backdrop-filter: blur(4px);
}

/* ── 8. PRODUCT CARDS (Shwapno-style) ── */
.product-card {
    background: var(--surface);
    border: 1px solid var(--divider);
    border-radius: var(--r-lg);
    overflow: hidden;
    transition: var(--ease);
    box-shadow: var(--shadow-card);
    display: flex;
    flex-direction: column;
    height: 100%;
    position: relative;
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-card-hover);
    border-color: #ffcdd2;
}

.product-image-container {
    position: relative;
    padding-top: 75%;
    background: #fafafa;
    overflow: hidden;
    border-bottom: 1px solid var(--divider);
}

.product-image-container img {
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    object-fit: contain;
    padding: 12px;
    transition: transform .4s ease;
}

.product-card:hover .product-image-container img {
    transform: scale(1.07);
}

/* Quick Add Button — appears on hover */
.product-quick-add {
    position: absolute;
    bottom: 0; left: 0; right: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.65) 0%, transparent 100%);
    display: flex;
    align-items: flex-end;
    justify-content: center;
    padding: 12px 10px;
    opacity: 0;
    transform: translateY(4px);
    transition: var(--ease);
}

.product-card:hover .product-quick-add { opacity: 1; transform: translateY(0); }

.product-quick-add .btn {
    font-size: 0.8rem;
    padding: 6px 16px;
    border-radius: var(--r-pill);
    font-weight: 700;
    white-space: nowrap;
}

/* Badges */
.badge-discount {
    position: absolute;
    top: 10px; right: 10px;
    background: linear-gradient(135deg, var(--red), var(--red-mid));
    color: white;
    font-size: 0.72rem;
    font-weight: 800;
    padding: 3px 9px;
    border-radius: var(--r-pill);
    box-shadow: 0 2px 6px rgba(198,40,40,.35);
    font-family: 'Inter', sans-serif;
    letter-spacing: 0.02em;
}

.badge-featured {
    position: absolute;
    top: 10px; left: 10px;
    background: linear-gradient(135deg, var(--gold), var(--gold-dark));
    color: #fff;
    font-size: 0.72rem;
    font-weight: 800;
    padding: 3px 9px;
    border-radius: var(--r-pill);
    font-family: 'Inter', sans-serif;
}

.badge-new {
    position: absolute;
    top: 10px; left: 10px;
    background: linear-gradient(135deg, #1565c0, #1976d2);
    color: #fff;
    font-size: 0.7rem;
    font-weight: 700;
    padding: 3px 9px;
    border-radius: var(--r-pill);
}

.badge-flash {
    position: absolute;
    top: 10px; right: 10px;
    background: linear-gradient(135deg, #e65100, #f4511e);
    color: white;
    font-size: 0.72rem;
    font-weight: 800;
    padding: 3px 9px;
    border-radius: var(--r-pill);
    animation: flashPulse 1.4s ease-in-out infinite;
}

@keyframes flashPulse {
    0%, 100% { box-shadow: 0 0 0 0 rgba(230,81,0,.5); }
    50%       { box-shadow: 0 0 0 5px rgba(230,81,0,0); }
}

/* Product Card Body */
.product-card-body {
    padding: 12px 14px 14px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.category-tag {
    font-size: 0.72rem;
    color: var(--text-muted);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 4px;
}

.product-name {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-primary);
    line-height: 1.4;
    margin-bottom: 4px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.product-weight {
    font-size: 0.78rem;
    color: var(--text-muted);
    margin-bottom: 8px;
}

.product-price-row {
    display: flex;
    align-items: baseline;
    gap: 7px;
    margin-bottom: 10px;
}

.price-current {
    font-size: 1.1rem;
    font-weight: 800;
    color: var(--red);
    font-family: 'Inter', 'Poppins', sans-serif;
    letter-spacing: -0.02em;
}

.price-original {
    font-size: 0.82rem;
    color: var(--text-muted);
    text-decoration: line-through;
    font-family: 'Inter', sans-serif;
}

.product-rating {
    font-size: 0.75rem;
    color: var(--gold-dark);
    display: flex;
    align-items: center;
    gap: 3px;
    margin-bottom: 10px;
}

.product-rating span {
    color: var(--text-muted);
    font-size: 0.7rem;
}

/* Qty Stepper (Shwapno-style inline +/-) */
.qty-stepper {
    display: flex;
    align-items: center;
    gap: 6px;
    background: var(--red-xlight);
    border: 1.5px solid #ffcdd2;
    border-radius: var(--r-pill);
    padding: 4px;
    width: fit-content;
}

.qty-stepper button {
    width: 28px; height: 28px;
    border-radius: 50%;
    border: none;
    background: var(--red);
    color: #fff;
    font-size: 1rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--ease);
    padding: 0;
    line-height: 1;
}

.qty-stepper button:hover { background: var(--red-dark); }

.qty-stepper .qty-num {
    min-width: 28px;
    text-align: center;
    font-weight: 700;
    font-size: 0.9rem;
    color: var(--text-primary);
}

/* Add-to-cart block */
.add-to-cart-block {
    display: flex;
    gap: 8px;
    align-items: center;
    margin-top: auto;
}

.btn-add-cart {
    flex: 1;
    padding: 8px 12px;
    border-radius: var(--r-pill);
    background: var(--red);
    color: #fff;
    font-size: 0.82rem;
    font-weight: 700;
    border: none;
    cursor: pointer;
    transition: var(--ease);
    font-family: inherit;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
}

.btn-add-cart:hover {
    background: var(--red-dark);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(198,40,40,.3);
}

.btn-whatsapp-sm {
    width: 36px; height: 36px;
    min-width: 36px;
    border-radius: 50%;
    background: #e8f5e9;
    color: #2e7d32;
    border: 1.5px solid #c8e6c9;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    cursor: pointer;
    transition: var(--ease);
    text-decoration: none;
}

.btn-whatsapp-sm:hover {
    background: #25d366;
    color: #fff;
    border-color: #25d366;
    transform: scale(1.1);
}

/* ── 9. CATEGORY PILL FILTER ── */
.category-pill {
    padding: 7px 16px;
    border-radius: var(--r-pill);
    font-size: 0.85rem;
    font-weight: 600;
    text-decoration: none;
    border: 1.5px solid var(--border);
    background: var(--surface);
    color: var(--text-secondary);
    transition: var(--ease);
    display: inline-flex;
    align-items: center;
    gap: 6px;
    white-space: nowrap;
}

.category-pill:hover,
.category-pill.active {
    background: var(--red);
    color: #ffffff;
    border-color: var(--red);
    box-shadow: 0 4px 12px rgba(198,40,40,.25);
}

/* ── 10. SECTION HEADERS ── */
.section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1.25rem;
    flex-wrap: wrap;
    gap: 10px;
}

.section-title {
    font-size: 1.3rem;
    font-weight: 800;
    color: var(--dark-2);
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0;
    position: relative;
}

.section-title::after {
    content: '';
    display: block;
    position: absolute;
    bottom: -6px;
    left: 0;
    width: 36px;
    height: 3px;
    background: var(--red);
    border-radius: var(--r-pill);
}

.section-see-all {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--red);
    display: flex;
    align-items: center;
    gap: 4px;
    text-decoration: none;
    transition: var(--ease);
}

.section-see-all:hover {
    color: var(--red-dark);
    gap: 8px;
}

/* ── 11. HERO BANNER ── */
.hero-banner {
    border-radius: var(--r-xl);
    overflow: hidden;
    position: relative;
    min-height: 320px;
}

/* Flash Sale Section */
.flash-sale-section {
    background: linear-gradient(135deg, #fff8e1 0%, #fff3e0 100%);
    border: 2px solid var(--gold);
    border-radius: var(--r-xl);
    padding: 1.5rem;
    margin-bottom: 2rem;
}

.flash-timer-block {
    display: flex;
    align-items: center;
    gap: 6px;
}

.flash-timer-unit {
    background: var(--dark-2);
    color: #fff;
    padding: 6px 12px;
    border-radius: var(--r-sm);
    font-size: 1.3rem;
    font-weight: 800;
    min-width: 48px;
    text-align: center;
    font-family: 'Inter', 'Poppins', monospace;
    line-height: 1;
}

.flash-timer-unit small {
    display: block;
    font-size: 0.6rem;
    font-weight: 400;
    color: rgba(255,255,255,0.65);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-top: 2px;
    font-family: 'Inter', sans-serif;
}

.flash-timer-sep {
    font-size: 1.5rem;
    font-weight: 900;
    color: var(--red);
    animation: blink 1s step-end infinite;
}

@keyframes blink {
    0%, 100% { opacity: 1; }
    50%       { opacity: 0; }
}

/* ── 12. DASHBOARD / METRIC CARDS ── */
.metric-card {
    background: var(--surface);
    border-radius: var(--r-lg);
    padding: 1.4rem 1.5rem;
    border: 1px solid var(--divider);
    box-shadow: var(--shadow-card);
    transition: transform .2s ease;
    display: flex;
    align-items: center;
    gap: 1.1rem;
}

.metric-card:hover { transform: translateY(-3px); }

.metric-icon-box {
    width: 54px; height: 54px;
    border-radius: var(--r-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    flex-shrink: 0;
}

.metric-icon-revenue  { background: #e8f5e9; color: #2e7d32; }
.metric-icon-orders   { background: #e3f2fd; color: #1565c0; }
.metric-icon-pending  { background: #fff3e0; color: #e65100; }
.metric-icon-products { background: #f3e5f5; color: #7b1fa2; }
.metric-icon-alert    { background: var(--red-light); color: var(--red); }

/* ── 13. STATUS BADGES ── */
.status-pill {
    font-size: 0.75rem;
    font-weight: 700;
    padding: 4px 10px;
    border-radius: var(--r-pill);
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-family: 'Inter', sans-serif;
    letter-spacing: 0.03em;
}

.status-pending    { background: #fff8e1; color: #e65100; border: 1px solid #ffcc80; }
.status-processing { background: #e3f2fd; color: #1565c0; border: 1px solid #90caf9; }
.status-shipped    { background: #ede7f6; color: #4527a0; border: 1px solid #ce93d8; }
.status-delivered  { background: #e8f5e9; color: #2e7d32; border: 1px solid #a5d6a7; }
.status-cancelled  { background: var(--red-light); color: var(--red-dark); border: 1px solid #ef9a9a; }
.status-approved   { background: #e8f5e9; color: #2e7d32; border: 1px solid #a5d6a7; }
.status-rejected   { background: var(--red-light); color: var(--red-dark); border: 1px solid #ef9a9a; }

/* ── 14. ORDER STEPPER ── */
.order-stepper {
    display: flex;
    justify-content: space-between;
    position: relative;
    margin: 2rem 0;
}

.order-stepper::before {
    content: '';
    position: absolute;
    top: 20px; left: 20px; right: 20px;
    height: 3px;
    background: var(--divider);
    z-index: 0;
}

.stepper-step {
    position: relative; z-index: 1;
    text-align: center;
    flex: 1;
}

.step-circle {
    width: 42px; height: 42px;
    border-radius: 50%;
    background: var(--surface);
    border: 3px solid var(--border);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    color: var(--text-muted);
    margin-bottom: .5rem;
    transition: var(--ease);
}

.stepper-step.completed .step-circle { background: #2e7d32; border-color: #2e7d32; color: #fff; }
.stepper-step.active .step-circle { background: var(--red); border-color: var(--red); color: #fff; box-shadow: 0 0 0 4px rgba(198,40,40,.2); }

/* ── 15. TABLES ── */
.custom-table { border-collapse: separate; border-spacing: 0 6px; }
.custom-table tr { background: var(--surface); border-radius: var(--r-sm); }
.custom-table td { padding: 13px 15px; vertical-align: middle; border: none; }
.custom-table td:first-child { border-top-left-radius: var(--r-sm); border-bottom-left-radius: var(--r-sm); }
.custom-table td:last-child  { border-top-right-radius: var(--r-sm); border-bottom-right-radius: var(--r-sm); }
.custom-table th { background: transparent; border: none; font-size: 0.8rem; text-transform: uppercase; color: var(--text-muted); letter-spacing: 0.5px; padding: 8px 15px; font-family: 'Inter', sans-serif; }

/* ── 16. CART QTY BUTTONS ── */
.qty-btn {
    width: 32px; height: 32px;
    display: inline-flex; align-items: center; justify-content: center;
    border-radius: var(--r-sm);
    border: 1.5px solid var(--border);
    background: var(--surface);
    color: var(--text-primary);
    font-weight: 700;
    transition: var(--ease);
    text-decoration: none;
}

.qty-btn:hover { background: var(--red-xlight); border-color: var(--red); color: var(--red); }

/* ── 17. CART BADGE ── */
.cart-badge {
    position: absolute;
    top: -5px; right: -8px;
    background: var(--red);
    color: white;
    font-size: 0.68rem;
    font-weight: 800;
    width: 20px; height: 20px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 2px solid #fff;
    font-family: 'Inter', sans-serif;
}

/* ── 18. ALERTS ANIMATION ── */
.alert-slide { animation: slideDown .28s ease-out; }

@keyframes slideDown {
    from { opacity: 0; transform: translateY(-8px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* ── 19. FOOTER ── */
.site-footer {
    background: linear-gradient(180deg, #1a1a2e 0%, #0d0d1a 100%);
    color: rgba(255,255,255,0.75);
    padding: 3rem 0 0;
    margin-top: 2rem;
}

.footer-heading {
    font-size: 0.95rem;
    font-weight: 700;
    color: #fff;
    margin-bottom: 1rem;
    padding-bottom: 8px;
    border-bottom: 2px solid rgba(198,40,40,.5);
    display: inline-block;
}

.footer-link {
    display: block;
    color: rgba(255,255,255,0.65);
    font-size: 0.84rem;
    margin-bottom: 7px;
    text-decoration: none;
    transition: var(--ease);
}

.footer-link:hover {
    color: var(--gold);
    padding-left: 4px;
}

.footer-bottom {
    background: rgba(0,0,0,0.3);
    padding: 14px 0;
    margin-top: 2.5rem;
}

/* ── 20. MISC UTILITY ── */
.hover-danger:hover { color: var(--red) !important; }
.text-brand { color: var(--red); }
.bg-brand   { background: var(--red); }

.rounded-brand { border-radius: var(--r-lg); }

/* Shimmer loader placeholder */
.shimmer {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
}

@keyframes shimmer {
    0%   { background-position: -200% 0; }
    100% { background-position:  200% 0; }
}

/* Mobile fix */
@media (max-width: 991.98px) {
    .navbar-search-form { max-width: 100%; margin: 8px 0; }
    .category-nav-list  { justify-content: flex-start; }
    .flash-timer-unit   { font-size: 1.1rem; min-width: 40px; }
}

@media (max-width: 575.98px) {
    .product-quick-add { opacity: 1; transform: none; }
    .flash-timer-unit  { font-size: 0.95rem; padding: 5px 8px; }
}

/* ── Header auth buttons ── */
.auth-nav { white-space: nowrap; }
.auth-nav .btn-auth-login,
.auth-nav .btn-auth-register {
    font-weight: 700;
    font-size: 0.9rem;
    line-height: 1.2;
    border: 1.5px solid #c0392b;
    transition: all 0.2s ease;
}
.auth-nav .btn-auth-login { color: #c0392b; background: #fff; }
.auth-nav .btn-auth-login:hover { background: #fff5f5; color: #a93226; }
.auth-nav .btn-auth-register {
    color: #fff;
    background: linear-gradient(135deg, #c0392b 0%, #e74c3c 100%);
    box-shadow: 0 3px 10px rgba(192,57,43,0.28);
}
.auth-nav .btn-auth-register:hover {
    color: #fff;
    transform: translateY(-1px);
    box-shadow: 0 6px 16px rgba(192,57,43,0.4);
}
@media (max-width: 575.98px) {
    .auth-nav .btn-auth-login span,
    .auth-nav .btn-auth-register span { display: none; }
}

/* ── Green accent theme (red + green) ── */
:root { --green:#2e7d32; --green-dark:#1b5e20; --green-light:#e8f5e9; }
.btn-primary-brand { background: linear-gradient(135deg,#2e7d32,#43a047) !important; border-color:#2e7d32 !important; color:#fff !important; }
.btn-primary-brand:hover { background: linear-gradient(135deg,#1b5e20,#2e7d32) !important; }
.category-navbar { border-bottom: 4px solid var(--green); }
.category-pill.active { background: var(--green) !important; border-color: var(--green) !important; color:#fff !important; }
.product-card:hover { border-color: var(--green) !important; box-shadow: 0 8px 24px rgba(46,125,50,.18) !important; }
.search-btn { background: var(--green) !important; }
.search-wrapper:focus-within { border-color: var(--green) !important; }
.product-card .text-danger.fw-bold, .price-current { color: var(--green-dark) !important; }

/* ── Logo language swap ── */
.logo-en { display: none !important; }
body.lang-en .logo-en { display: inline-block !important; }
body.lang-en .logo-bn { display: none !important; }
img.logo-bn, img.logo-en { border-radius: 10px; object-fit: contain; }
.auth-brand-logo img, .offcanvas-header img[class^="logo-"], footer img[class^="logo-"] { background:#fff; padding:4px 8px; border-radius:12px; }

/* ── Red → light green → dark green fade ── */
:root { --fade: #c62828; --wine: #c62828; --wine-dark: #a61b1b; --leaf: #2e7d32; --leaf-dark: #1b5e20; }
.category-navbar { background: var(--wine) !important; border-bottom: 3px solid var(--wine-dark) !important; }
.category-nav-link { color:#fff !important; text-shadow: 0 1px 2px rgba(0,0,0,.25); }
/* nav hover effect removed */
.btn-primary-brand, .auth-submit-btn, .auth-nav .btn-auth-register, .search-btn { background: var(--fade) !important; color:#fff !important; border:none !important; }
.auth-nav .btn-auth-login { border-color:#2e7d32 !important; color:#2e7d32 !important; }
.btn-outline-brand { border-color:#2e7d32 !important; color:#2e7d32 !important; }
.btn-outline-brand:hover { background: var(--leaf) !important; color:#fff !important; }
.main-navbar { border-bottom: 1px solid #c8e6c9; }
.top-announcement-bar { background: var(--wine) !important; }

/* ── Popup messages ── */
.dp-overlay { position:fixed; inset:0; z-index:2000; background:rgba(15,23,15,.45); backdrop-filter: blur(3px); display:flex; align-items:center; justify-content:center; padding:16px; animation: dpFade .2s ease; }
.dp-overlay.dp-out { opacity:0; transition: opacity .2s; }
.dp-box { position:relative; background:#fff; border-radius:22px; width:100%; max-width:400px; padding:30px 26px 22px; text-align:center; box-shadow:0 24px 70px rgba(0,0,0,.3); animation: dpPop .35s cubic-bezier(.2,1.3,.4,1); overflow:hidden; }
.dp-icon { width:76px; height:76px; border-radius:50%; margin:0 auto 14px; display:flex; align-items:center; justify-content:center; font-size:2.2rem; color:#fff; animation: dpIcon .5s .1s both; }
.dp-success .dp-icon, .dp-order .dp-icon { background: linear-gradient(135deg,#66bb6a,#1b5e20); box-shadow:0 8px 20px rgba(46,125,50,.4); }
.dp-error .dp-icon { background: linear-gradient(135deg,#ef5350,#a61b1b); box-shadow:0 8px 20px rgba(198,40,40,.4); animation: dpIcon .5s .1s both, dpShake .5s .5s; }
.dp-warning .dp-icon { background: linear-gradient(135deg,#ffca28,#f57f17); }
.dp-info .dp-icon { background: linear-gradient(135deg,#42a5f5,#1565c0); }
.dp-title { font-weight:800; margin-bottom:6px; color:#1f2937; }
.dp-text { color:#4b5563; margin-bottom:18px; white-space:pre-line; font-size:.95rem; }
.dp-actions { display:flex; gap:10px; justify-content:center; flex-wrap:wrap; }
.dp-btn { border:0; border-radius:50px; padding:10px 26px; font-weight:700; color:#fff; text-decoration:none; background: var(--fade, #2e7d32); cursor:pointer; }
.dp-error .dp-btn { background: linear-gradient(135deg,#ef5350,#a61b1b); }
.dp-btn-alt { background:#fff; color:#2e7d32; border:2px solid #2e7d32; padding:8px 22px; }
.dp-bar { position:absolute; left:0; bottom:0; height:4px; width:100%; background: var(--fade, #2e7d32); transform-origin:left; animation: dpBar 3.5s linear forwards; }
@keyframes dpFade { from {opacity:0} to {opacity:1} }
@keyframes dpPop { from {transform:scale(.7) translateY(20px); opacity:0} to {transform:none; opacity:1} }
@keyframes dpIcon { from {transform:scale(0) rotate(-90deg)} to {transform:none} }
@keyframes dpShake { 0%,100%{transform:translateX(0)} 25%{transform:translateX(-8px)} 75%{transform:translateX(8px)} }
@keyframes dpBar { from {transform:scaleX(1)} to {transform:scaleX(0)} }

/* ── Wishlist heart ── */
.product-image-container, .col-lg-5 { position: relative; }
.wish-form { position:absolute; top:10px; right:10px; z-index:5; margin:0; }
.wish-btn { width:38px; height:38px; border-radius:50%; border:0; background:rgba(255,255,255,.95); color:#9e9e9e; box-shadow:0 2px 8px rgba(0,0,0,.18); transition:.2s; }
.wish-btn:hover { color:#c62828; transform:scale(1.12); }
.wish-btn.active { color:#c62828; }

/* ══ RESPONSIVE FIT (all languages / devices) ══
   English text is longer than Bangla, so every block must be allowed to
   shrink and wrap instead of pushing the page wider than the window. */
html {
    /* fluid root size: Bootstrap spacing/typography (rem) scales with the window */
    font-size: clamp(14px, 12.5px + 0.2vw, 16.5px);
    -webkit-text-size-adjust: 100%;
}
html, body { max-width: 100%; overflow-x: clip; }
img, video, iframe, canvas { max-width: 100%; }
.container, .container-fluid { padding-left: clamp(10px, 2vw, 16px); padding-right: clamp(10px, 2vw, 16px); }

/* flex/grid children may shrink below their content width */
.row > *, .d-flex > *, .flex-grow-1, .card, .card-body, .search-wrapper, .navbar-search-form { min-width: 0; }

/* long words / numbers / emails wrap instead of overflowing */
h1, h2, h3, h4, h5, h6, p, li, td, th, label, .card-title, .card-text, .btn, .badge, .alert {
    overflow-wrap: anywhere;
    word-break: normal;
}
/* tables scroll inside their own box rather than widening the page */
.table-responsive, .table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
table { max-width: 100%; }

/* fluid headings */
h1, .h1 { font-size: clamp(1.5rem, 1.1rem + 1.8vw, 2.5rem); }
h2, .h2 { font-size: clamp(1.3rem, 1rem + 1.3vw, 2rem); }
h3, .h3 { font-size: clamp(1.15rem, 0.95rem + 0.9vw, 1.6rem); }

/* header: top bar, search and controls share the row and shrink */
.top-announcement-bar .container > div { row-gap: 4px; }
.slogan-pill, .lang-toggle-btn { max-width: 100%; }
.main-navbar .container > div { flex-wrap: nowrap; min-width: 0; }
.main-navbar .search-input { min-width: 0; width: 100%; text-overflow: ellipsis; }
.main-navbar .search-btn { flex-shrink: 0; padding-left: clamp(8px, 1.2vw, 18px); padding-right: clamp(8px, 1.2vw, 18px); }
.main-navbar .d-flex.flex-shrink-0 { gap: clamp(4px, 0.8vw, 8px) !important; }
.main-navbar .btn { padding-left: clamp(8px, 1vw, 16px) !important; padding-right: clamp(8px, 1vw, 16px) !important; white-space: nowrap; }

/* category bar: wraps into extra rows instead of scrolling off screen */
.category-navbar { overflow-x: visible; }
.category-nav-list { flex-wrap: wrap; white-space: normal; }
.category-nav-link { padding: 10px clamp(8px, 1vw, 16px); font-size: clamp(0.78rem, 0.7rem + 0.2vw, 0.88rem); }

/* English labels are ~30% longer: tighten a little more */
body.lang-en .category-nav-link { padding: 10px clamp(6px, 0.8vw, 12px); font-size: clamp(0.74rem, 0.68rem + 0.18vw, 0.84rem); }
body.lang-en .main-navbar .btn { font-size: clamp(0.78rem, 0.72rem + 0.2vw, 0.9rem); }
body.lang-en .auth-nav .btn-auth-login,
body.lang-en .auth-nav .btn-auth-register { font-size: clamp(0.76rem, 0.7rem + 0.2vw, 0.9rem); padding-left: 10px; padding-right: 10px; }
body.lang-en .btn { white-space: normal; }
body.lang-en .main-navbar .btn, body.lang-en .lang-toggle-btn, body.lang-en .category-nav-link { white-space: nowrap; }

/* small screens */
@media (max-width: 767.98px) {
    .top-announcement-bar { font-size: 0.74rem; }
    .main-navbar .container > div { flex-wrap: wrap; }
    .navbar-search-form { order: 5; flex-basis: 100%; margin: 4px 0 6px; }
    .logo-bn, .logo-en { height: 42px !important; }
}
@media (max-width: 575.98px) {
    .main-navbar .btn { padding-left: 8px !important; padding-right: 8px !important; }
    .auth-nav { white-space: normal; }
}

/* ══ MEGA MENU (All Products / category hover dropdown) ══ */
.category-navbar { position: relative; }
.category-nav-item.mega-active > .category-nav-link { background: rgba(0,0,0,0.22); color: #fff !important; }
.mega-menu { position: absolute; left: 0; right: 0; top: 100%; z-index: 1060; background: #fff; border-top: 3px solid var(--red);
             box-shadow: 0 18px 40px rgba(0,0,0,.2); padding: 14px 0 16px; max-height: 70vh; overflow-y: auto; }
.mega-menu[hidden] { display: none; }
.mega-toolbar { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-bottom: 8px; }
.mega-search { flex: 1 1 240px; min-width: 0; position: relative; }
.mega-search i { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); color: #9ca3af; font-size: .85rem; }
.mega-search input { width: 100%; padding: 8px 12px 8px 34px; border: 1.5px solid #e5e7eb; border-radius: 999px; font-size: .9rem; outline: none; }
.mega-search input:focus { border-color: var(--red); }
.mega-sort { flex: 0 1 200px; min-width: 0; padding: 8px 12px; border: 1.5px solid #e5e7eb; border-radius: 999px; font-size: .88rem; background: #fff; }
.mega-all { flex-shrink: 0; font-weight: 700; font-size: .9rem; color: var(--red); white-space: nowrap; }
.mega-meta { font-size: .78rem; color: #6b7280; margin-bottom: 8px; }
.mega-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; }
.mega-item { display: flex; flex-direction: column; gap: 4px; padding: 8px; border: 1px solid #f0f0f0; border-radius: 12px; color: var(--text-primary); transition: .15s; min-width: 0; }
.mega-item:hover { border-color: var(--red); box-shadow: 0 6px 16px rgba(0,0,0,.1); transform: translateY(-2px); color: var(--text-primary); }
.mega-item img { width: 100%; aspect-ratio: 1 / 1; object-fit: contain; background: #fafafa; border-radius: 8px; }
.mega-name { font-size: .85rem; font-weight: 600; line-height: 1.3; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.mega-price { font-size: .85rem; font-weight: 700; color: var(--red); }
.mega-price del { color: #9ca3af; font-weight: 400; font-size: .75rem; }
.mega-price em { font-style: normal; font-size: .7rem; color: #6b7280; font-weight: 500; }
.mega-empty { grid-column: 1 / -1; text-align: center; color: #6b7280; padding: 24px 0; }

/* Header search suggestions */
.search-wrapper { position: relative; }
.search-suggest { position: absolute; top: calc(100% + 6px); left: 0; right: 0; z-index: 1050; background: #fff; border-radius: 16px; box-shadow: 0 12px 32px rgba(0,0,0,.18); max-height: 420px; overflow-y: auto; padding: 6px; }
.search-suggest[hidden] { display: none; }
.ss-item { display: flex; align-items: center; gap: 12px; padding: 8px 10px; border-radius: 12px; color: inherit; text-decoration: none; }
.ss-item:hover, .ss-item.active { background: #eef7ee; }
.ss-item img, .ss-noimg { width: 44px; height: 44px; border-radius: 8px; object-fit: cover; background: #f1f1f1; flex-shrink: 0; }
.ss-name { flex: 1; min-width: 0; font-weight: 600; font-size: .92rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ss-name small { display: block; font-weight: 400; color: #888; font-size: .75rem; }
.ss-price { font-weight: 700; color: #2e7d32; white-space: nowrap; }
.ss-all, .ss-empty { display: block; text-align: center; padding: 10px; font-size: .85rem; color: #2e7d32; text-decoration: none; font-weight: 600; }
.ss-empty { color: #888; font-weight: 400; }

/* Header search: category select + advanced panel */
.navbar-search-form { max-width: 680px; }
.search-wrapper .search-cat { position: absolute; left: 6px; top: 50%; transform: translateY(-50%); z-index: 2; max-width: 130px; border: 0; border-right: 1px solid var(--border); background: transparent; font-size: .82rem; font-weight: 600; padding: 6px 6px 6px 12px; outline: none; cursor: pointer; text-overflow: ellipsis; }
.search-wrapper .search-icon-inside { display: none; }
.search-wrapper .search-input { padding-left: 150px; padding-right: 150px; }
.search-adv-btn { position: absolute; right: 108px; top: 50%; transform: translateY(-50%); width: 34px; height: 34px; border-radius: 50%; border: 0; background: transparent; color: var(--text-muted); z-index: 2; }
.search-adv-btn:hover, .search-adv-btn[aria-expanded="true"] { background: #eef7ee; color: #2e7d32; }
.search-adv { position: absolute; top: calc(100% + 6px); right: 0; width: min(380px, 100%); z-index: 1060; background: #fff; border-radius: 16px; box-shadow: 0 12px 32px rgba(0,0,0,.18); padding: 16px; }
.search-adv[hidden] { display: none; }
.adv-title { font-weight: 700; margin-bottom: 10px; }
.adv-row { display: flex; gap: 10px; margin-bottom: 10px; }
.search-adv label { font-size: .78rem; font-weight: 600; color: #666; flex: 1; display: block; }
.search-adv label input[type=number], .search-adv label select { width: 100%; margin-top: 3px; padding: 7px 10px; border: 1px solid #ddd; border-radius: 10px; font-size: .88rem; }
.adv-full { margin-bottom: 10px; }
.adv-checks { display: flex; flex-wrap: wrap; gap: 6px 16px; margin-bottom: 12px; }
.adv-checks label { flex: none; font-weight: 500; display: flex; align-items: center; gap: 5px; }
.adv-actions { display: flex; justify-content: space-between; }
.ss-head { padding: 6px 10px; font-size: .75rem; font-weight: 700; color: #888; text-transform: uppercase; }
.ss-cats { display: flex; flex-wrap: wrap; gap: 8px; padding: 4px 8px 8px; }
.ss-cat { padding: 6px 12px; border: 1px solid #ddd; border-radius: 999px; font-size: .84rem; color: inherit; text-decoration: none; }
.ss-cat:hover { background: #eef7ee; border-color: #2e7d32; }
.ss-cat small { margin-left: 6px; color: #888; }
@media (max-width: 991px) { .search-wrapper .search-cat { display: none; } .search-wrapper .search-input { padding-left: 18px; } }

/* ── Shop by category drawer (≡ → categories → products) ── */
.cat-drawer-wrap { position: relative; }
.cat-drawer-btn { background: rgba(0,0,0,.18); border: 0; cursor: pointer; font-family: inherit; }
.cat-drawer-btn i { font-size: 1.05rem; }
.cat-drawer { position: absolute; top: 100%; left: 0; z-index: 1070; display: flex; width: min(860px, 92vw); max-height: 70vh; background: #fff;
  border-radius: 0 0 14px 14px; box-shadow: 0 14px 34px rgba(0,0,0,.22); overflow: hidden; border-top: 3px solid var(--red); text-shadow: none; }
.cat-drawer[hidden] { display: none; }
.cd-cats { flex: 0 0 270px; overflow-y: auto; background: #fff; border-right: 1px solid #eee; padding: 6px 0; }
.cd-cat { display: flex; align-items: center; gap: 10px; padding: 11px 16px; color: #222 !important; font-weight: 600; font-size: .92rem; text-decoration: none; }
.cd-cat > i:first-child { width: 22px; text-align: center; color: var(--green, #2e7d32); }
.cd-cat span { flex: 1; min-width: 0; }
.cd-cat small { color: #9ca3af; font-weight: 500; }
.cd-cat .cd-arrow { font-size: .7rem; color: #9ca3af; }
.cd-cat.active { background: var(--red, #c62828); color: #fff !important; }
.cd-cat.active > i:first-child, .cd-cat.active small, .cd-cat.active .cd-arrow { color: #fff; }
.cd-prods { flex: 1; min-width: 0; padding: 12px 16px; overflow-y: auto; background: #fafafa; }
.cd-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 10px; font-weight: 700; color: #222; }
.cd-head a { font-size: .85rem; color: var(--red, #c62828) !important; text-decoration: none; white-space: nowrap; }
.cd-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.cd-item { display: flex; align-items: center; gap: 10px; padding: 8px; background: #fff; border: 1px solid #eee; border-radius: 10px; color: #222 !important; text-decoration: none; min-width: 0; }
.cd-item:hover { border-color: var(--red, #c62828); }
.cd-item img, .cd-noimg { width: 44px; height: 44px; flex: 0 0 44px; object-fit: contain; border-radius: 6px; background: #f3f4f6; }
.cd-name { flex: 1; min-width: 0; font-size: .82rem; font-weight: 600; line-height: 1.25; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.cd-price { font-size: .82rem; font-weight: 700; color: var(--red, #c62828); white-space: nowrap; }
.cd-empty { grid-column: 1 / -1; text-align: center; color: #6b7280; padding: 24px 0; }

/* nav items stay on one line */
.category-nav-list { flex-wrap: nowrap; }
.category-nav-link { white-space: nowrap; }
/* 13 nav items on one line: tighter spacing, icons hidden on narrower desktops */
.category-nav-link { padding: 12px clamp(5px, .6vw, 9px); gap: 5px; font-size: clamp(.74rem, .6rem + .2vw, .86rem); }
@media (max-width: 1799.98px) { .category-nav-link > i { display: none; } .cat-drawer-btn > i { display: inline-block; } }

/* ── Product compare ── */
.compare-btn.active { background: var(--red, #c62828); border-color: var(--red, #c62828); color: #fff; }
.compare-tray { position: fixed; left: 0; right: 0; bottom: 0; z-index: 1045; display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 10px;
  padding: 10px max(16px, calc((100vw - 1320px) / 2)); background: #fff; border-top: 3px solid var(--red, #c62828); box-shadow: 0 -8px 24px rgba(0,0,0,.15); }
.compare-tray[hidden] { display: none; }
.ct-items { display: flex; flex-wrap: wrap; gap: 8px; min-width: 0; }
.ct-item { display: flex; align-items: center; gap: 8px; max-width: 230px; padding: 4px 8px 4px 4px; border: 1px solid #e5e7eb; border-radius: 999px; background: #fafafa; font-size: .8rem; }
.ct-item img { width: 34px; height: 34px; object-fit: contain; border-radius: 50%; background: #fff; }
.ct-item span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 140px; }
.ct-rm { border: 0; background: transparent; font-size: 1.1rem; line-height: 1; color: #6b7280; cursor: pointer; }
.ct-actions { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.ct-hint { font-size: .8rem; color: #6b7280; }
.ct-clear { border: 0; background: transparent; color: #6b7280; font-size: .85rem; cursor: pointer; }
.ct-go { background: #c62828; color: #fff !important; padding: 8px 18px; border-radius: 999px; font-weight: 700; font-size: .9rem; text-decoration: none; }
.ct-go.disabled { opacity: .45; }
.compare-table th, .compare-table td { min-width: 180px; vertical-align: middle; }
.compare-table .ctl { min-width: 150px; font-weight: 700; color: #374151; background: #f9fafb; position: sticky; left: 0; z-index: 1; }
.compare-table th { position: relative; padding-top: 22px; }
.cmp-img { width: 120px; height: 120px; object-fit: contain; background: #fafafa; border-radius: 10px; }
.cmp-remove { position: absolute; top: 4px; right: 6px; color: #9ca3af; text-decoration: none; }
.cmp-remove:hover { color: var(--red, #c62828); }
.cmp-best { background: #e8f5e9; }

/* footer: About Us link under the company blurb */
.footer-about-link { display: inline-flex; align-items: center; margin-bottom: 14px; padding: 7px 16px; border-radius: 999px; font-size: .85rem; font-weight: 600;
  color: #fff !important; text-decoration: none; background: #c62828; }
.footer-about-link:hover { filter: brightness(1.1); }

/* bigger nav text (still one line) */
.category-nav-link { padding: 16px clamp(9px, 1vw, 18px); gap: 7px; font-size: clamp(.95rem, .78rem + .34vw, 1.1rem); }
.category-nav-link > i { font-size: 1rem; }
@media (max-width: 2199.98px) { .category-nav-link > i { display: none; } .cat-drawer-btn > i { display: inline-block; } }

/* product card actions: [Compare] [Add to Cart]; each wraps to its own full-width row when the card is too narrow */
.product-actions > .compare-btn { flex: 1 1 88px; min-width: 0; white-space: nowrap; font-size: .875em; line-height: 1.25; }
.product-actions > form, .product-actions > button.btn-secondary { flex: 2 1 130px; min-width: 0; }
.product-actions > form .btn, .product-actions > button.btn-secondary { white-space: nowrap; }
.product-actions > .compare-btn, .product-actions > form .btn, .product-actions > button.btn-secondary { min-height: 38px; display: inline-flex; align-items: center; justify-content: center; }
.product-actions > form .btn { width: 100%; }

/* compare tray open: WhatsApp float sits above it, page keeps room at the bottom */
body.compare-open { padding-bottom: var(--compare-h, 70px); }
body.compare-open .whatsapp-float-btn { bottom: calc(var(--compare-h, 70px) + 16px); transition: bottom .2s ease; }

/* Home product cards: [Add to cart] [Compare]; wraps to two full-width rows on narrow cards */
.sp-qty-row { flex-wrap: wrap; }
.sp-qty-row > form { flex: 2 1 96px !important; min-width: 0; }
.sp-compare-btn { flex: 1 1 70px; min-width: 0; min-height: 34px; padding: 7px 10px; border-radius: 999px; border: 1.5px solid #cfd4da; background: #fff; color: #374151;
  font-size: .8rem; font-weight: 700; line-height: 1.2; white-space: nowrap; cursor: pointer; font-family: inherit; display: inline-flex; align-items: center; justify-content: center; transition: all .2s; }
.sp-compare-btn:hover { border-color: #c62828; color: #c62828; }
.sp-compare-btn.active { background: #c62828; border-color: #c62828; color: #fff; }

/* nav: the section you are in stays highlighted (bold, light background, yellow marker bar) */
.nav-flash { color: #ffd54f !important; }
.category-nav-link { position: relative; transition: background .12s, color .12s; }
.category-nav-link.active,
.category-nav-link:focus-visible,
.cat-drawer-wrap.open > .cat-drawer-btn {
  background: #fff !important; color: #a61b1b !important; font-weight: 800; text-shadow: none; outline: none;
}
.category-nav-link.active::after,
.category-nav-link:focus-visible::after,
.cat-drawer-wrap.open > .cat-drawer-btn::after {
  content: ""; position: absolute; left: 10px; right: 10px; bottom: 0; height: 4px; border-radius: 4px 4px 0 0; background: #ffb300;
}

/* ── Dashboards (Admin / Seller / Dashboard): own portal header, no shop header ── */
body.dash-page .top-announcement-bar,
body.dash-page .main-navbar,
body.dash-page .category-navbar { display: none !important; }
.dash-topbar { background: #fff; border-bottom: 3px solid #c62828; box-shadow: 0 2px 10px rgba(0,0,0,.07); z-index: 1030; }
.dash-top-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding-top: 10px; padding-bottom: 10px; }
.dash-brand { display: flex; align-items: center; gap: 12px; min-width: 0; }
.dash-brand img { height: 44px; width: auto; flex-shrink: 0; }
.dash-portal-title { font-weight: 800; font-size: 1.1rem; color: #212121; line-height: 1.2; padding-left: 12px; border-left: 2px solid #e5e7eb; }
.dash-actions { display: flex; align-items: center; gap: 8px; flex-shrink: 0; }
.dash-btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; height: 38px; padding: 0 16px; border-radius: 999px; font-size: .88rem; font-weight: 700; line-height: 1; white-space: nowrap; cursor: pointer; text-decoration: none; transition: .15s; }
.dash-btn-lang { background: #fff; color: #2e7d32; border: 1.5px solid #2e7d32; }
.dash-btn-lang:hover { background: #2e7d32; color: #fff; }
.dash-btn-shop { background: #fff; color: #212121; border: 1.5px solid #212121; }
.dash-btn-shop:hover { background: #212121; color: #fff; }
.dash-btn-out { background: #c62828; color: #fff; border: 1.5px solid #c62828; }
.dash-btn-out:hover { background: #a61f1f; border-color: #a61f1f; }
.dash-nav-row { background: #fafafa; border-top: 1px solid #eee; }
.dash-topnav { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 4px 6px; padding-top: 8px; padding-bottom: 8px; }
.dash-toplink { display: inline-flex; align-items: center; height: 34px; padding: 0 14px; border-radius: 999px; color: #424242; font-weight: 600; font-size: .88rem; text-decoration: none; white-space: nowrap; transition: .15s; }
.dash-toplink:hover { background: #f0f0f0; color: #c62828; }
.dash-toplink.active { background: #c62828; color: #fff; }
button.dash-toplink { background: transparent; }
.dash-drop { border-radius: 12px; border: 1px solid #eee; padding: 6px; min-width: 220px; }
.dash-drop .dropdown-item { border-radius: 8px; font-size: .9rem; font-weight: 600; padding: 8px 12px; color: #424242; }
.dash-drop .dropdown-item:hover { background: #fff5f5; color: #c62828; }
.dash-drop .dropdown-item.active { background: #c62828; color: #fff; }
.dash-topnav .dropdown { position: relative; }
.dash-toplink:focus { outline: none; box-shadow: none; }
.dash-toplink:focus-visible { box-shadow: 0 0 0 3px rgba(198,40,40,.25); }
.dash-toplink.show:not(.active) { background: #f0f0f0; color: #c62828; }
.dash-cur { display: inline-flex; align-items: center; max-width: 220px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 700; }
.dash-sep { margin: 0 6px; opacity: .75; }
.dash-drop .dropdown-item { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.dash-drop .dropdown-item.active::after { content: "\2713"; font-weight: 800; }
@media (max-width: 575.98px) {
    .dash-topnav { gap: 4px; padding-left: 8px; padding-right: 8px; }
    .dash-toplink { height: 32px; padding: 0 10px; font-size: .8rem; }
    .dash-drop { min-width: 200px; max-width: calc(100vw - 24px); }
    .dash-drop .dropdown-item { white-space: normal; }
    .dash-cur { max-width: 120px; }
}
@media (max-width: 575.98px) {
    .dash-top-row { flex-wrap: wrap; justify-content: center; }
    .dash-brand img { height: 38px; }
    .dash-portal-title { font-size: 1rem; }
    .dash-btn { height: 34px; padding: 0 12px; font-size: .82rem; }
}

/* ── Back button (all pages except home) ── */
.page-back-btn { display: inline-flex; align-items: center; gap: 6px; margin-bottom: 12px; padding: 6px 14px; border: 1px solid #ddd; border-radius: 999px; background: #fff; color: #333; font-weight: 600; font-size: .88rem; cursor: pointer; }
.page-back-btn:hover { background: #c62828; border-color: #c62828; color: #fff; }

/* ── Small screens: nothing should overflow sideways ── */
img { max-width: 100%; }
@media (max-width: 768px) {
    main table.table { display: block; overflow-x: auto; white-space: nowrap; }
    .dash-portal-title { font-size: .9rem; }
}

/* ── Category bar: centred, fitted to the window, same height in Bangla and English ── */
.category-navbar { overflow: visible; position: relative; }
.category-navbar .category-nav-list { flex-wrap: wrap !important; justify-content: center !important; align-items: stretch; padding: 0 8px; }
body .category-nav-link,
body.lang-en .category-nav-link { min-height: 52px; padding-top: 0 !important; padding-bottom: 0 !important; align-items: center; line-height: 1.2; }
.category-nav-link.nav-home { justify-content: center; padding-left: 16px !important; padding-right: 16px !important; }
.category-nav-link.nav-home > i { display: inline-block !important; font-size: 1.2rem; }

/* category drawer: centred under the bar, same margin on both sides, scales with the window */
.cat-drawer-wrap { position: static; }
.category-navbar .cat-drawer { left: 0; right: 0; margin-left: auto; margin-right: auto; width: min(1140px, calc(100% - 24px)); }
.cd-cats { flex: 0 0 clamp(200px, 24%, 290px); }
.cd-grid { grid-template-columns: repeat(auto-fill, minmax(min(230px, 100%), 1fr)); }
/* the earlier ".category-nav-list { margin: 0 }" cancelled the container's auto margins, so the bar sat on the left: centre it again */
.category-navbar .category-nav-list { margin-left: auto !important; margin-right: auto !important; width: 100%; max-width: 100% !important; }


/* বাটনের লেখা কখনো বাটনের বাইরে বেরোবে না: flex-এর ভেতরে বাটন চেপে ছোট হবে না, প্রয়োজনে লাইন ভাঙবে */
.btn { max-width: 100%; }
.d-flex > .btn, .d-flex > form > .btn, .btn.text-nowrap { flex-shrink: 0; }
.btn:not(.text-nowrap) { overflow-wrap: anywhere; }

/* স্ক্রল করলে উপরের বার মসৃণভাবে লুকায়/ফেরে */
.main-navbar.sticky-top { transition: transform .32s cubic-bezier(.4,0,.2,1), box-shadow .32s ease; will-change: transform; }
.main-navbar.nav-hidden { transform: translateY(-110%); box-shadow: none !important; pointer-events: none; }
@media (prefers-reduced-motion: reduce) { .main-navbar.sticky-top { transition: none; } }
/* একই আচরণ: ড্যাশবোর্ডের বার, আর কার্ট/চেকআউটের স্টিকি সারাংশ-বাক্স */
.dash-topbar.sticky-top { transition: transform .32s cubic-bezier(.4,0,.2,1), box-shadow .32s ease; will-change: transform; }
.dash-topbar.nav-hidden { transform: translateY(-110%); box-shadow: none !important; pointer-events: none; }
main .sticky-top[style*="top: 90px"] { transition: top .32s cubic-bezier(.4,0,.2,1); }
body.nav-is-hidden main .sticky-top[style*="top: 90px"] { top: 16px !important; }
@media (prefers-reduced-motion: reduce) { .dash-topbar.sticky-top, main .sticky-top[style*="top: 90px"] { transition: none; } }

/* ── রং: লাল মানে ওয়াইন রেড, সবুজ মানে সবুজ; কোনো মিশ্র গ্রেডিয়েন্ট নয় ── */
.btn-primary-brand:hover, .auth-submit-btn:hover, .auth-nav .btn-auth-register:hover, .search-btn:hover { background: var(--wine-dark) !important; }
.footer-about-link:hover, .ct-go:hover { background: #a61b1b; filter: none; }
/* ড্যাশবোর্ডের বার লম্বা, তাই ফেরার গতি একটু ধীর ও নরম */
.dash-topbar.sticky-top { transition: transform .55s cubic-bezier(.22,1,.36,1), box-shadow .4s ease; }
.dash-topbar.nav-hidden { transition: transform .35s cubic-bezier(.4,0,1,1); }
.main-navbar.sticky-top { transition: transform .45s cubic-bezier(.22,1,.36,1), box-shadow .4s ease; }
.main-navbar.nav-hidden { transition: transform .3s cubic-bezier(.4,0,1,1); }

/* ══ মোবাইল/ট্যাবলেট: অ্যাপের মতো নিচের মেনু বার (৯৯২px-এর নিচে) ══ */
.bottom-nav { position: fixed; left: 0; right: 0; bottom: 0; z-index: 1040; display: flex; align-items: stretch; justify-content: space-around;
    background: #fff; border-top: 1px solid #eee3e0; box-shadow: 0 -6px 20px rgba(60,20,10,.08);
    padding: 6px max(8px, env(safe-area-inset-left)) calc(6px + env(safe-area-inset-bottom)) max(8px, env(safe-area-inset-right)); }
.bn-item { flex: 1 1 0; min-width: 0; display: flex; flex-direction: column; align-items: center; justify-content: flex-end; gap: 3px;
    padding: 4px 2px; border: 0; background: none; color: #6b6560; text-decoration: none; font-size: .68rem; font-weight: 600; line-height: 1.1;
    -webkit-tap-highlight-color: transparent; min-height: 48px; }
.bn-item i { font-size: 1.15rem; }
.bn-item span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
.bn-item.active, .bn-item:active { color: #c62828; }
.bn-item.active i { transform: translateY(-1px); }
.bn-cart { position: relative; }
.bn-cart-circle { position: relative; width: 50px; height: 50px; margin-top: -24px; border-radius: 50%; background: #c62828; color: #fff;
    display: flex; align-items: center; justify-content: center; border: 4px solid #fff; box-shadow: 0 6px 16px rgba(198,40,40,.35); }
.bn-cart-circle i { font-size: 1.15rem; color: #fff; transform: none !important; }
.bn-badge { position: absolute; top: -6px; right: -8px; min-width: 20px; height: 20px; padding: 0 5px; border-radius: 999px; background: #2e7d32; color: #fff;
    font-size: .66rem; font-weight: 800; display: flex; align-items: center; justify-content: center; border: 2px solid #fff; }
.bn-badge[hidden] { display: none; }
@media (min-width: 576px) { .bn-item { font-size: .76rem; } .bn-item i { font-size: 1.25rem; } }
@media (max-width: 991.98px) {
    body { padding-bottom: calc(66px + env(safe-area-inset-bottom)); }          /* বারের নিচে কিছু ঢাকা পড়বে না */
    .compare-tray { bottom: calc(62px + env(safe-area-inset-bottom)); }
    .whatsapp-float-btn { bottom: calc(84px + env(safe-area-inset-bottom)) !important; }
    body.compare-open .whatsapp-float-btn { bottom: calc(var(--compare-h, 70px) + 84px + env(safe-area-inset-bottom)) !important; }
}
@media print { .bottom-nav { display: none !important; } }

/* ══════════ ফোন ও ছোট ট্যাবলেট: অ্যাপের মতো গোছানো লেআউট ══════════ */
html, body { overflow-x: hidden; }
@media (max-width: 991.98px) {
    /* কার্ট নিচের বারে আছে, তাই উপরের বার থেকে বাদ */
    .main-navbar a[href="/Cart"] { display: none !important; }
}
@media (max-width: 767.98px) {
    .container, .container-fluid { padding-left: 12px; padding-right: 12px; }
    main { padding-top: 0; }

    /* উপরের ঘোষণার পট্টি: এক সারি, ছোট */
    .top-announcement-bar .d-flex.justify-content-between { flex-wrap: nowrap !important; padding-top: 2px !important; padding-bottom: 2px !important; }
    .slogan-pill { font-size: .7rem; padding: 3px 9px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
    .lang-toggle-btn { font-size: .72rem; padding: 3px 9px; flex-shrink: 0; }

    /* হেডার: ১ম সারিতে লোগো + অ্যাকাউন্ট + মেনু, ২য় সারিতে পুরো চওড়া সার্চ */
    .main-navbar { padding: 6px 0; }
    .main-navbar .container > div { row-gap: 6px; justify-content: space-between; }
    .logo-bn, .logo-en { height: 38px !important; }
    .navbar-search-form { order: 5; flex: 0 0 100%; margin: 0 0 2px; }
    .search-wrapper { border-radius: 999px; }
    .search-wrapper .search-input { height: 42px; font-size: 16px; padding-left: 16px !important; padding-right: 92px !important; }
    .search-btn { padding: 0 14px !important; font-size: 0 !important; }      /* শুধু আইকন */
    .search-btn i { font-size: .95rem; margin: 0 !important; }
    .search-suggest { max-height: 60vh; overflow-y: auto; }

    /* অ্যাকাউন্ট: শুধু আইকন, লেখা বাদ */
    .auth-nav { gap: 6px !important; }
    .auth-nav .nav-item.me-1 > .btn { font-size: 0; padding: 7px 10px !important; }
    .auth-nav .nav-item.me-1 > .btn i { font-size: .95rem; margin: 0 !important; }
    .auth-nav .dropdown-toggle { font-size: 0; padding: 4px !important; }
    .auth-nav .dropdown-toggle i { font-size: 1.35rem; margin: 0 !important; }
    .auth-nav .dropdown-toggle::after { font-size: .8rem; }
    .auth-nav .dropdown-menu { position: absolute; right: 0; left: auto; }

    /* পণ্যের গ্রিড: ২ কলাম, কম ফাঁকা, ছোট কার্ড */
    main .row.g-4 { --bs-gutter-x: .7rem; --bs-gutter-y: .7rem; }
    main .row.g-3 { --bs-gutter-x: .7rem; --bs-gutter-y: .7rem; }
    .product-card { border-radius: 14px; }
    .product-card .p-3 { padding: .6rem !important; }
    .product-card h6 { font-size: .84rem; white-space: normal !important; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; min-height: 2.3em; line-height: 1.15; }
    .product-card h5 { font-size: 1rem; }
    .product-card .category-tag { font-size: .62rem; max-width: 62%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
    .product-card .mb-3 { margin-bottom: .5rem !important; }
    .product-card .btn { font-size: .78rem; padding: .4rem .5rem; }
    .product-card .badge-discount, .product-card .badge-featured { font-size: .62rem; padding: 3px 7px; }
    .product-quick-add { opacity: 1; transform: none; }

    /* শিরোনাম ও সেকশন */
    .section-title { font-size: 1.15rem; }
    h1, .h1 { font-size: 1.5rem; } h2, .h2 { font-size: 1.3rem; } h3, .h3 { font-size: 1.15rem; }
    .display-5 { font-size: 1.7rem !important; }
    .page-back-btn { margin: 8px 0; padding: 5px 12px; font-size: .82rem; }

    /* হোমের হিরো ব্যানার */
    .hero-slide { min-height: 0 !important; padding: 1.6rem 1.1rem !important; border-radius: 14px !important; background-size: cover !important; animation: none !important; }
    .hero-wrap { border-radius: 14px !important; }
    .hero-slide h1 span.d-block { font-size: 1.1rem !important; }
    .hero-slide p { font-size: .88rem !important; margin-bottom: 1rem !important; }
    .hero-slide .btn-lg { font-size: .9rem; padding: .5rem 1rem !important; }
    .hero-slide .d-flex.gap-3 { gap: .5rem !important; }

    /* মোডাল, ফর্ম, বাটন */
    .modal-dialog { margin: .6rem; }
    .btn-lg { font-size: 1rem; padding: .55rem 1rem; }
    input.form-control, select.form-select, textarea.form-control { font-size: 16px; }   /* iOS জুম বন্ধ */

    /* ফুটার: নিচে আলাদা নিয়ম আছে */
}
@media (max-width: 380px) {
    .slogan-pill { max-width: 58vw; }
    .product-card h5 { font-size: .92rem; }
    .bn-item { font-size: .62rem; }
}
/* ছোট ট্যাবলেট (৭৬৮–৯৯১px): পণ্য ৩ কলাম, সার্চ পুরো সারি */
@media (min-width: 768px) and (max-width: 991.98px) {
    .main-navbar .container > div { flex-wrap: wrap; }
    .navbar-search-form { order: 5; flex: 0 0 100%; margin: 4px 0 2px; }
}

/* ══ ফোনের হেডার, সাজগোজের ধাঁচে: বাঁয়ে মেনু, মাঝে লোগো, ডানে অ্যাকাউন্ট, নিচে সার্চ ══ */
@media (max-width: 767.98px) {
    .main-navbar .container > div { position: relative; min-height: 46px; align-items: center; column-gap: 0 !important; }
    .main-navbar .container > div > .d-flex.flex-shrink-0:last-child { display: contents !important; }
    .main-navbar .container > div > a:first-child { position: absolute; left: 50%; top: 2px; transform: translateX(-50%); margin: 0 !important; min-width: 0 !important; }
    .main-navbar [data-bs-target="#mobileNav"] { order: -1; margin-right: auto; border: 0 !important; background: transparent !important; font-size: 1.25rem; padding: 6px 8px !important; }
    .main-navbar .auth-nav { order: 2; margin-left: auto; }
    .main-navbar .auth-nav .nav-item.me-1 { display: none; }                 /* প্যানেল-বাটন নিচের বারের "অ্যাকাউন্ট"-এ আছে */
    .main-navbar .auth-nav .btn-auth-register { display: none; }
    .navbar-search-form { order: 5; flex: 0 0 100%; max-width: 100%; margin: 0 0 2px; }

    /* সার্চ: পরিষ্কার বর্ডার, ভেতরে ফিল্টার আর সার্চ আইকন পাশাপাশি */
    .search-wrapper .search-input { height: 44px; border: 1.5px solid #c62828; background: #fff; padding-left: 16px !important; padding-right: 88px !important; }
    .search-wrapper .search-btn { right: 5px; width: 36px; height: 34px; padding: 0 !important; border-radius: 50% !important; display: flex; align-items: center; justify-content: center; font-size: 0 !important; box-shadow: none !important; }
    .search-wrapper .search-btn i { font-size: .9rem; margin: 0 !important; }
    .search-wrapper .search-adv-btn { right: 44px; width: 34px; height: 34px; }
}
/* ══ নিচের বার: সমান মাপের সমতল আইকন, কার্টে ব্যাজ ══ */
.bn-cart-circle { width: auto; height: auto; margin-top: 0; border: 0; border-radius: 0; background: none; box-shadow: none; color: inherit; }
.bn-cart-circle i { color: inherit; font-size: 1.15rem; }
.bn-badge { top: -7px; right: -12px; background: #c62828; }
.bn-item { justify-content: center; text-transform: none; }
/* ভাষা বদলের ঝলক বন্ধ: ইংরেজি মোডে অনুবাদ বসার আগে পেজ দেখানো হয় না */
html.lang-pending body { visibility: hidden; }

/* ══ মসৃণ আচরণ ══ */
@view-transition { navigation: auto; }                       /* পেজ বদলালে ঝাঁকি নয়, নরম মিলিয়ে যাওয়া */
::view-transition-old(root), ::view-transition-new(root) { animation-duration: .18s; }
main { transition: opacity .14s ease; }
html.lang-vt::view-transition-old(root), html.lang-vt::view-transition-new(root) { animation-duration: .22s; animation-timing-function: ease; }
.btn, .bn-item, .dash-btn, .lang-toggle-btn { transition: transform .12s ease, background-color .18s ease, color .18s ease, border-color .18s ease, box-shadow .18s ease; -webkit-tap-highlight-color: transparent; touch-action: manipulation; }
.btn:active, .bn-item:active, .dash-btn:active, .lang-toggle-btn:active { transform: scale(.96); }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } @view-transition { navigation: none; } .btn:active, .bn-item:active { transform: none; } }

/* লাল সব জায়গায় এক রকম ও ভরাট: Admin Panel বাটনসহ */
.btn-danger { background-color:#c62828 !important; border-color:#c62828 !important; }
.btn-danger:hover, .btn-danger:focus { background-color:#a61b1b !important; border-color:#a61b1b !important; }
.btn-outline-danger { color:#c62828 !important; border-color:#c62828 !important; }
.btn-outline-danger:hover { background-color:#c62828 !important; color:#fff !important; }
.text-danger { color:#c62828 !important; } .bg-danger { background-color: rgba(198,40,40,var(--bs-bg-opacity,1)) !important; }   /* হালকা লাল (bg-opacity) ঠিক থাকে, লাল লেখা ঢেকে যায় না */

/* ══ সব ডেটা-টেবিল: প্রতিটা ঘর আলাদা বক্সে, সারি-কলাম স্পষ্ট ══ */
main table:not(.no-grid), .container table:not(.no-grid) { border-collapse: collapse !important; border-spacing: 0 !important; width: 100%; }
main table:not(.no-grid) > thead > tr > th, main table:not(.no-grid) > tbody > tr > td, main table:not(.no-grid) > tfoot > tr > td,
.container table:not(.no-grid) > thead > tr > th, .container table:not(.no-grid) > tbody > tr > td, .container table:not(.no-grid) > tfoot > tr > td {
    border: 1px solid #e3e3e3 !important; vertical-align: middle;
}
main table:not(.no-grid) > thead > tr > th, .container table:not(.no-grid) > thead > tr > th {
    background: #f6f6f6 !important; color: #444; font-weight: 700; white-space: nowrap;
}
main table:not(.no-grid) > tbody > tr:nth-child(even) > td, .container table:not(.no-grid) > tbody > tr:nth-child(even) > td { background-color: #fcfcfc; }
main table:not(.no-grid) > tbody > tr:hover > td, .container table:not(.no-grid) > tbody > tr:hover > td { background-color: #fff5f5; }

/* ══ সব টেবিলের লেখা ও মান মাঝখানে ══ */
main table > thead > tr > th, main table > tbody > tr > td, main table > tfoot > tr > td,
.container table > thead > tr > th, .container table > tbody > tr > td, .container table > tfoot > tr > td { text-align: center !important; vertical-align: middle !important; }
main table td > .d-flex, main table td > .d-inline-flex, .container table td > .d-flex { justify-content: center; }
main table td form, .container table td form { justify-content: center; }
main table tr.cms-edit > td, main table tr.cms-edit > td * { text-align: left !important; }
main table tr.cms-edit > td .row { justify-content: flex-start; }

/* ══ ফুটার: পরিষ্কার সারি, আইকন এক লাইনে, ফোনে মাঝখানে ══ */
.ft-logo { height: 62px; background: #fff; padding: 8px; border-radius: 10px; }
.ft-about { font-size: .85rem; color: rgba(255,255,255,.65); line-height: 1.7; }
.ft-about strong { color: rgba(255,255,255,.92); }
.ft-badges { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: .5rem; }
.ft-badges .badge, .ft-pay { font-size: .75rem; padding: 6px 10px; font-weight: 600; border-radius: 6px; }
.ft-slogan { background: rgba(198,40,40,.25); color: #ffcdd2; border: 1px solid rgba(198,40,40,.45); }
.ft-halal { background: #1b5e20; }
.ft-list { display: flex; flex-direction: column; align-items: flex-start; gap: 2px; }
.ft-list .footer-link, .ft-contact > div { display: flex; align-items: center; gap: 10px; margin-bottom: 7px; text-align: left; }
.ft-list i { width: 18px; text-align: center; color: #ef5350; flex-shrink: 0; font-size: .9rem; }
.ft-contact > div { font-size: .85rem; color: rgba(255,255,255,.7); line-height: 1.5; }
.ft-contact strong { color: #fff; }
.ft-list i.ft-wa { color: #4caf50; }
.footer-link:hover { padding-left: 0; }
.ft-sub { font-size: .82rem; padding-bottom: 6px; border-bottom-width: 1.5px; margin-top: .5rem; }
.ft-row { display: flex; flex-wrap: wrap; gap: 8px; }
.ft-social { gap: 18px; font-size: 1.35rem; }
.ft-social a { color: rgba(255,255,255,.55); transition: color .2s; }
.ft-social a.fb:hover { color: #1877f2; } .ft-social a.ig:hover { color: #e1306c; } .ft-social a.yt:hover { color: #ff0000; } .ft-social a.tt:hover { color: #fff; }
@media (max-width: 767.98px) {
    .site-footer { padding-top: 2rem; text-align: center; }
    .site-footer .row { --bs-gutter-x: .75rem; --bs-gutter-y: 1.75rem; }
    .ft-brand { display: flex; flex-direction: column; align-items: center; }
    .ft-about { max-width: 420px; margin-left: auto; margin-right: auto; }
    .ft-badges, .ft-row { justify-content: center; }
    .ft-col { display: flex; flex-direction: column; align-items: center; }
    .ft-col .footer-heading { margin-bottom: .85rem; }
    .ft-list { align-items: flex-start; }      /* তালিকা মাঝখানে, কিন্তু আইকনগুলো এক সোজা লাইনে */
    .ft-list .footer-link { font-size: .86rem; margin-bottom: 9px; }
    .ft-contact { margin-bottom: .75rem; }
    .ft-contact > div { justify-content: flex-start; }
    .ft-sub { margin-top: .75rem; }
    .footer-bottom { margin-top: 1.5rem; padding-bottom: 14px; }
}
.ft-paylogo { display: inline-flex; align-items: center; justify-content: center; height: 44px; padding: 6px 14px; background: #fff; border-radius: 8px; }
.ft-paylogo img { height: 30px; width: auto; display: block; }

/* ══ চ্যাট বাটন ও নতুন মেসেজের নোটিফিকেশন ══ */
.hdr-chat-btn { border: 1.5px solid #c62828; color: #c62828; background: #fff; font-weight: 700; }
.hdr-chat-btn:hover { background: #c62828; color: #fff; }
.chat-count { display: inline-flex; align-items: center; justify-content: center; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 999px; background: #c62828; color: #fff; font-size: .66rem; font-weight: 800; line-height: 1; }
.chat-count[hidden] { display: none !important; }
.hdr-chat-btn .chat-count { position: absolute; top: -6px; right: -6px; border: 2px solid #fff; }
.dash-toplink.active .chat-count, .dropdown-item.active .chat-count { background: #fff; color: #c62828; }
.chat-toast { position: fixed; z-index: 1080; right: 18px; bottom: 18px; display: flex; align-items: center; gap: 10px; background: #1f1f1f; color: #fff; padding: 10px 14px; border-radius: 14px; box-shadow: 0 8px 24px rgba(0,0,0,.2); font-size: .88rem; opacity: 0; transform: translateY(10px); transition: opacity .25s ease, transform .25s ease; }
.chat-toast.show { opacity: 1; transform: translateY(0); }
.chat-toast i { color: #ff8a80; }
.chat-toast a { color: #fff; font-weight: 700; background: #c62828; border-radius: 999px; padding: 3px 12px; text-decoration: none; }
@media (max-width: 991.98px) { .chat-toast { left: 12px; right: 12px; bottom: calc(76px + env(safe-area-inset-bottom)); justify-content: center; } }

/* ══ সাব-অ্যাডমিন: মুছা ও অ্যাডমিনের নিজস্ব কাজের বাটন দেখায় না (সার্ভারও আটকায়) ══ */
body.is-subadmin form[action*="/Delete" i], body.is-subadmin a[href*="/Delete" i],
body.is-subadmin form[action*="/AssignRole" i], body.is-subadmin form[action*="/SavePermissions" i],
body.is-subadmin form[action*="/CreateSeller" i], body.is-subadmin form[action*="/ResetUserPassword" i],
body.is-subadmin form[action*="/TransferOwnership" i], body.is-subadmin form[action*="/TakeAllProducts" i],
body.is-subadmin a[href="/Admin/Ownership"], body.is-subadmin a[href="/Admin/Settings"], body.is-subadmin a[href^="/Report"],
body.is-subadmin a[href^="/Chat/Monitor"], body.is-subadmin form[action*="/Chat/ModBlock" i] { display: none !important; }

/* নিশ্চিত করার পপআপ: লাল আইকন, লাল "হ্যাঁ" */
.dp-confirm .dp-icon { background: #c62828; box-shadow: 0 8px 20px rgba(198,40,40,.35); }
.dp-confirm .dp-btn { background: #c62828; }
.dp-confirm .dp-btn:hover { background: #a61b1b; }
.dp-confirm .dp-btn-alt { background: #fff; color: #444; border: 2px solid #ddd; }
.dp-confirm .dp-btn-alt:hover { background: #f5f5f5; }

/* লগইন ও রেজিস্টার পাতা: দোকানের উপরের লাল পট্টি আর বড় হেডার নেই */
body.auth-page .top-announcement-bar, body.auth-page .main-navbar, body.auth-page .category-navbar { display: none !important; }
.auth-topbar { position: relative; }
@media (max-width: 575.98px) { .auth-topbar .dash-top-row { flex-wrap: nowrap; justify-content: space-between; } .auth-topbar .dash-btn-shop span { display: none; } }

/* ══ উপরের হেডার: সব বাটন এক মাপের, সমান ফাঁক, লোগো বড় ও ঠিক মাঝ বরাবর ══ */
@media (min-width: 992px) {
    .main-navbar { padding: 12px 0; }
    .main-navbar .container > div { align-items: center !important; gap: 18px !important; }
    .main-navbar .hdr-logo { align-self: center; line-height: 0; }
    .main-navbar .hdr-logo img { height: 64px !important; width: auto; display: block; margin: 0; }
    body:not(.lang-en) .main-navbar .hdr-logo img.logo-en, body.lang-en .main-navbar .hdr-logo img.logo-bn { display: none !important; }
    .main-navbar .search-wrapper { align-self: center; }
    .main-navbar .hdr-actions { gap: 10px !important; align-items: center; }
    .main-navbar .hdr-actions .auth-nav { gap: 10px !important; align-items: center; margin: 0; }
    .main-navbar .hdr-actions .btn,
    .main-navbar .hdr-actions .auth-nav .btn {
        height: 44px; min-width: 44px; padding: 0 18px !important; border-radius: 999px !important;
        display: inline-flex; align-items: center; justify-content: center; gap: 7px;
        font-size: .92rem !important; font-weight: 700; line-height: 1; border-width: 1.5px !important; border-style: solid !important;
        box-shadow: none !important; transform: none !important; margin: 0 !important;
    }
    .main-navbar .hdr-actions .btn i { font-size: 1rem !important; }
    .main-navbar .hdr-actions .whatsapp-header-btn { border-color: #25d366 !important; }
    .main-navbar .hdr-actions .auth-nav .nav-item { margin: 0 !important; display: flex; align-items: center; }
    .main-navbar .hdr-actions .auth-nav .nav-link { height: 44px; display: inline-flex; align-items: center; padding: 0 6px !important; font-size: .95rem; }
}
@media (min-width: 992px) and (max-width: 1199.98px) {
    /* মাঝারি পর্দায় সার্চের জায়গা রাখতে বাটনগুলো শুধু আইকন, সবগুলো সমান গোল */
    .main-navbar .hdr-actions .hdr-txt { display: none !important; }
    .main-navbar .hdr-actions .btn, .main-navbar .hdr-actions .auth-nav .btn { width: 44px; padding: 0 !important; }
    .main-navbar .hdr-actions .btn i { margin: 0 !important; }
    .main-navbar .container > div { gap: 12px !important; }
    .main-navbar .hdr-logo img { height: 56px !important; }
}

/* ══ উপরের তিন সারি (লাল পট্টি, হেডার, ক্যাটাগরি বার): তিনটাই সমান ৪৮px, চিকন ══ */
@media (min-width: 992px) {
    :root { --tier-h: 48px; }
    .top-announcement-bar { padding: 0 !important; }
    .top-announcement-bar > .container > div { height: var(--tier-h); min-height: 0; padding-top: 0 !important; padding-bottom: 0 !important; flex-wrap: nowrap !important; }
    .top-announcement-bar .slogan-pill { padding: 2px 12px; line-height: 1.5; }
    .top-announcement-bar .lang-toggle-btn { height: 30px; padding: 0 12px; }

    .main-navbar { padding: 0 !important; }
    .main-navbar .container > div { height: calc(var(--tier-h) - 1px); padding-top: 0 !important; padding-bottom: 0 !important; gap: 16px !important; }
    .main-navbar .hdr-logo img { height: 40px !important; border-radius: 8px; }
    .main-navbar .search-input { height: 36px; padding-top: 0; padding-bottom: 0; font-size: .88rem; border-width: 1.5px; }
    .main-navbar .search-btn { height: 28px; padding: 0 14px; font-size: .8rem; display: inline-flex; align-items: center; }
    .main-navbar .hdr-actions .btn,
    .main-navbar .hdr-actions .auth-nav .btn { height: 36px; min-width: 36px; padding: 0 14px !important; font-size: .85rem !important; }
    .main-navbar .hdr-actions .btn i { font-size: .92rem !important; }
    .main-navbar .hdr-actions .auth-nav .nav-link { height: 36px; font-size: .9rem; }
    .main-navbar .hdr-actions .chat-count { top: -5px; right: -5px; }

    body .category-nav-link, body.lang-en .category-nav-link { min-height: var(--tier-h) !important; height: var(--tier-h); font-size: clamp(.86rem, .74rem + .25vw, 1rem); }
    .category-navbar { border-bottom-width: 0 !important; }
}
@media (min-width: 992px) and (max-width: 1199.98px) {
    .main-navbar .hdr-actions .btn, .main-navbar .hdr-actions .auth-nav .btn { width: 36px; padding: 0 !important; }
    .main-navbar .hdr-logo img { height: 38px !important; }
}

/* ══ মাঝারি পর্দায় (১০২৪–১৪৪০px) উপরের তিন সারি এক লাইনে, কিছু চেপে বা কেটে না যায় ══ */
@media (min-width: 992px) {
    .top-announcement-bar .container > div > div { flex-wrap: nowrap !important; min-width: 0; }
    .top-announcement-bar .container > div > div > span { white-space: nowrap; }
    .top-announcement-bar .slogan-pill { white-space: nowrap; flex-shrink: 0; }
    .category-nav-list { flex-wrap: nowrap !important; }
}
@media (min-width: 992px) and (max-width: 1199.98px) {
    .main-navbar .hdr-actions .auth-nav .btn span { display: none !important; }      /* লগইন/রেজিস্টার শুধু আইকন */
    .top-announcement-bar .container > div > div:first-child > span:nth-of-type(3) { display: none !important; }   /* ফ্রি ডেলিভারির লেখা */
}
@media (min-width: 1200px) and (max-width: 1439.98px) {
    body .category-nav-link, body.lang-en .category-nav-link { padding-left: clamp(6px, .62vw, 11px) !important; padding-right: clamp(6px, .62vw, 11px) !important; font-size: .86rem; }
    body.lang-en .category-nav-link { font-size: .8rem; }
    .category-nav-link.nav-home { padding-left: 10px !important; padding-right: 10px !important; }
}
@media (min-width: 1200px) and (max-width: 1439.98px) {
    body.lang-en .top-announcement-bar .container > div > div:first-child > span:nth-of-type(3) { display: none !important; }   /* ইংরেজিতে লেখা লম্বা, তাই এই মাপে ফ্রি ডেলিভারির লেখা লুকায় */
}

/* লেবেল (badge) কখনো নিজের ঘরের বাইরে যায় না */
.badge { max-width: 100%; white-space: normal; overflow-wrap: anywhere; line-height: 1.3; vertical-align: middle; }   /* লম্বা লেখা হলে পরের লাইনে যায়, কাটে না */

/* গাঢ় বা রঙিন বক্সের ভেতরের শিরোনাম সাদা থাকে, কালো হয়ে হারিয়ে যায় না */
.text-white h1, .text-white h2, .text-white h3, .text-white h4, .text-white h5, .text-white h6 { color: inherit; }
.bg-dark .text-secondary, .bg-dark .text-muted { color: rgba(255,255,255,.72) !important; }

/* ফুটার (বড় পর্দা): চার কলাম পুরো চওড়ায় সমান ফাঁকে ছড়ানো, বাঁয়ে চাপা নয় */
@media (min-width: 992px) {
    .site-footer > .container > .row { justify-content: space-between; }
    .site-footer > .container > .row > [class*="col-"] { flex: 0 0 auto; width: auto; }
    .site-footer > .container > .row > .ft-brand { max-width: 320px; }
}

/* footer payment popup + social icons without a link */
.ft-paybtn { border: 0; font: inherit; cursor: pointer; transition: transform .15s; }
.ft-paybtn { transition: transform .15s, box-shadow .15s, background-color .15s; }
.ft-paybtn:hover, .ft-paybtn:focus-visible { transform: translateY(-3px) scale(1.06); background: #fff7e6; box-shadow: 0 0 0 3px rgba(255,213,79,.9), 0 8px 18px rgba(0,0,0,.35); }
.ft-paybtn:focus-visible { outline: 2px solid #fff; outline-offset: 2px; }
.ft-social a.ft-nolink { cursor: default; }
.dp-pay { max-width: 340px; max-height: calc(100vh - 32px); overflow-y: auto; }
.dp-pay-x { position: absolute; top: 8px; right: 12px; border: 0; background: none; font-size: 1.6rem; line-height: 1; color: #888; cursor: pointer; }
.dp-pay-logo { height: 46px; width: auto; max-width: 70%; margin: 0 auto 12px; display: block; }
.dp-pay-note { color: #4b5563; font-size: .9rem; margin-bottom: 12px; }
.dp-pay-qr { width: auto; max-width: 100%; max-height: min(58vh, 420px); object-fit: contain; border: 1px solid #eee; border-radius: 12px; padding: 8px; margin: 0 auto 14px; display: block; background: #fff; }
.dp-pay-num { font-size: 1.4rem; font-weight: 800; letter-spacing: .5px; color: #1f2937; word-break: break-all; margin-bottom: 12px; }
.dp-pay .dp-btn { background: #c62828; }

/* ── পাসওয়ার্ড ভেরিফিকেশন (অ্যাডমিন / সেলার) ── */
.rc-wrap { max-width: 1100px; }
.rc-search { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 12px; }
.rc-search-box { position: relative; flex: 1 1 260px; min-width: 0; }
.rc-search-box i { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); color: #a8a19b; pointer-events: none; }
.rc-search-box input { width: 100%; padding: 11px 14px 11px 40px; border: 1.5px solid #e2dcd6; border-radius: 12px; font-size: 16px; background: #fff; outline: none; }
.rc-search-box input:focus { border-color: #c62828; box-shadow: 0 0 0 3px rgba(198,40,40,.12); }
.rc-btn { border-radius: 12px; font-weight: 700; min-height: 44px; display: inline-flex; align-items: center; justify-content: center; min-width: 120px; }
.rc-help { color: #6b7280; font-size: .86rem; margin: 6px 0 16px; line-height: 1.6; }
.rc-h { font-weight: 800; margin: 22px 0 10px; font-size: 1.02rem; }
.rc-empty { padding: 16px; background: #faf6f2; border-radius: 12px; color: #6b7280; font-size: .9rem; }
.rc-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 420px), 1fr)); gap: 14px; }
.rc-card { background: #fff; border: 1px solid #eee4dc; border-radius: 16px; padding: 16px; box-shadow: 0 4px 14px rgba(0,0,0,.05); min-width: 0; display: flex; flex-direction: column; gap: 10px; }
.rc-hard { border-color: #f3c98b; background: #fffaf1; }
.rc-done { border-color: #9ad8b0; background: #f6fdf8; }
.rc-badge-done { background: #166534; color: #fff; font-weight: 700; }
.rc-head { display: flex; justify-content: space-between; gap: 8px; flex-wrap: wrap; align-items: flex-start; }
.rc-name { font-weight: 800; font-size: 1.02rem; overflow-wrap: anywhere; min-width: 0; }
.rc-badges { display: flex; gap: 6px; flex-wrap: wrap; }
.rc-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 8px 14px; margin: 0; }
.rc-grid > div { min-width: 0; }
.rc-grid dt { font-size: .72rem; font-weight: 700; color: #8b8178; margin: 0; }
.rc-grid dd { margin: 0; font-size: .9rem; font-weight: 600; color: #1f2937; overflow-wrap: anywhere; }
.rc-status { font-size: .82rem; border-radius: 10px; padding: 8px 10px; line-height: 1.5; }
.rc-on { background: #ecfdf3; color: #166534; }
.rc-off { background: #f3f4f6; color: #4b5563; }
.rc-form { margin: 0; }
.rc-form .btn { width: 100%; }
.rc-pw { background: #f0fdf4; border: 1.5px solid #86efac; border-radius: 16px; padding: 14px 16px; margin: 0 0 16px; }
.rc-pw-top { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; color: #166534; font-size: .92rem; overflow-wrap: anywhere; }
.rc-dim { color: #6b7280; font-size: .84rem; }
.rc-pw-row { display: flex; gap: 12px; flex-wrap: wrap; align-items: center; margin: 10px 0; }
.rc-pw-code { font-size: 1.35rem; font-weight: 800; letter-spacing: .06em; background: #fff; border: 1.5px dashed #22c55e; border-radius: 12px; padding: 8px 14px; color: #111827; user-select: all; overflow-wrap: anywhere; }
.rc-pw-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.rc-pw-note { font-size: .82rem; color: #4b5563; line-height: 1.55; }
@media (max-width: 575.98px) {
    .rc-list { grid-template-columns: 1fr; }
    .rc-search .btn { flex: 1 1 auto; }
    .rc-pw-actions { width: 100%; }
    .rc-pw-actions .btn { flex: 1 1 auto; }
    .rc-pw-code { width: 100%; text-align: center; }
}
