/* ===============================
   ElectroHub — Storefront Styles
   =============================== */

:root {
    --primary: #1a56db;
    --primary-dark: #1541a8;
    --primary-light: #e8f0fe;
    --accent: #06b6d4;
    --deal: #ff6b2c;
    --deal-dark: #e2560f;
    --dark: #0f172a;
    --dark-2: #1e293b;
    --text: #1e293b;
    --text-muted: #64748b;
    --text-light: #94a3b8;
    --border: #e2e8f0;
    --bg: #f8fafc;
    --white: #ffffff;
    --success: #16a34a;
    --star: #f59e0b;
    --radius: 12px;
    --radius-sm: 8px;
    --shadow-sm: 0 1px 3px rgba(15, 23, 42, 0.08);
    --shadow: 0 4px 16px rgba(15, 23, 42, 0.08);
    --shadow-lg: 0 12px 32px rgba(15, 23, 42, 0.14);
    --header-h: 76px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    color: var(--text);
    background: var(--bg);
    line-height: 1.6;
    font-size: 15px;
}

a { text-decoration: none; color: inherit; }
ul { list-style: none; }
img { max-width: 100%; display: block; }

.material-icons-outlined {
    font-family: 'Material Icons Outlined';
    font-weight: normal;
    font-style: normal;
    line-height: 1;
    letter-spacing: normal;
    text-transform: none;
    display: inline-block;
    white-space: nowrap;
    word-wrap: normal;
    direction: ltr;
    -webkit-font-feature-settings: 'liga';
    -webkit-font-smoothing: antialiased;
    vertical-align: middle;
    user-select: none;
}

.container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 24px;
}

/* ---------- Buttons ---------- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 24px;
    border-radius: var(--radius-sm);
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
    border: none;
    transition: all 0.2s ease;
    white-space: nowrap;
}
.btn-primary { background: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--primary-dark); transform: translateY(-2px); box-shadow: var(--shadow); }
.btn-outline { background: transparent; border: 2px solid rgba(255,255,255,0.6); color: #fff; }
.btn-outline:hover { background: rgba(255,255,255,0.15); }
.btn-lg { padding: 15px 34px; font-size: 15px; }
.btn-block { width: 100%; }
.btn-google { background: #fff; border: 1px solid var(--border); color: var(--text); }
.btn-google:hover { background: var(--bg); }

/* ---------- Top Bar ---------- */
.top-bar {
    background: var(--dark);
    color: #cbd5e1;
    font-size: 13px;
    padding: 8px 0;
}
.top-bar-inner { display: flex; justify-content: space-between; align-items: center; gap: 20px; }
.top-bar-marquee { flex: 1; overflow: hidden; white-space: nowrap; }
.marquee-text {
    display: inline-block; padding-left: 100%; color: #cbd5e1;
    animation: marquee 22s linear infinite; transition: color 0.2s;
}
.marquee-text:hover { animation-play-state: paused; color: #fff; }
@keyframes marquee { 0% { transform: translateX(0); } 100% { transform: translateX(-100%); } }
.top-bar-links { display: flex; gap: 22px; flex-shrink: 0; }
.top-bar-tools { display: flex; align-items: center; gap: 8px; flex-shrink: 0; }
.tb-tool { display: inline-flex; align-items: center; justify-content: center; gap: 4px; min-width: 30px; height: 26px; padding: 0 8px; border: 1px solid rgba(255,255,255,0.25); background: rgba(255,255,255,0.08); color: #cbd5e1; border-radius: 6px; font-size: 12px; font-weight: 700; cursor: pointer; transition: all 0.2s; }
.tb-tool:hover { background: rgba(255,255,255,0.2); color: #fff; }
.tb-tool .material-icons-outlined { font-size: 16px; }

/* ============================================================
   DARK MODE
   ============================================================ */
.dark {
    --bg: #0f172a;
    --card: #18233c;
    --text: #e5e9f2;
    --text-muted: #97a3b8;
    --text-light: #6b7a93;
    --border: #2a3a57;
    --primary-light: #1c2c4a;
    --white: #18233c;
}
.dark body { background: var(--bg); color: var(--text); }

/* Surfaces that were hardcoded white → dark card */
.dark .header,
.dark .main-nav,
.dark .product-card,
.dark .category-card,
.dark .why-us,
.dark .why-card:hover,
.dark .modal,
.dark .cart-sidebar,
.dark .notif-panel,
.dark .user-dropdown,
.dark .search-suggest,
.dark .pd-share-menu,
.dark .tab-btn,
.dark .sort-select,
.dark .shop-filters,
.dark .ad-card,
.dark .toast,
.dark .categories-menu,
.dark .close-cart,
.dark .modal-close,
.dark .qty-btn,
.dark .product-wishlist,
.dark .product-compare,
.dark .pd-wish,
.dark .filter-toggle,
.dark .page-btn,
.dark .google-account { background: var(--card); }

.dark .search-bar,
.dark .cart-item-img,
.dark .suggest-thumb,
.dark .pd-qty button,
.dark .empty-cart,
.dark .list-row-img { background: var(--bg); }

/* Text */
.dark h1, .dark h2, .dark h3, .dark h4, .dark h5,
.dark .product-name, .dark .product-price, .dark .pd-price,
.dark .cart-total strong, .dark .cart-item-price, .dark .checkout-item-price,
.dark .list-row-price, .dark .order-row-amt, .dark .suggest-name,
.dark .logo-text h1, .dark .cmp-price, .dark .stat-value { color: var(--text); }
.dark .logo-text span, .dark .header-action { color: var(--text-muted); }
.dark .nav-links a, .dark .categories-menu li a, .dark .user-dropdown a,
.dark .footer-col ul li a, .dark .suggest-cat, .dark .product-category { color: var(--text-muted); }
.dark .nav-links a:hover, .dark .nav-links a.active { color: var(--primary); }

/* Inputs */
.dark input, .dark textarea, .dark select { background: var(--card); color: var(--text); border-color: var(--border); }
.dark .search-bar input, .dark .search-bar select { background: transparent; }
.dark input::placeholder, .dark textarea::placeholder { color: var(--text-light); }

/* Borders / dividers */
.dark .header, .dark .main-nav, .dark .product-card, .dark .category-card { border-color: var(--border); }

/* Header icons */
.dark .header-action .material-icons-outlined { color: var(--text); }

/* Add-to-cart light button */
.dark .add-to-cart { background: var(--primary-light); color: #7aa5ff; }
.dark .add-to-cart:hover { background: var(--primary); color: #fff; }

/* Product image stays light so photos read well */
.dark .product-image { background: #f1f5f9; }

/* Keep the marquee readable */
.dark .marquee-text { color: #cbd5e1; }
.top-bar-links a { display: inline-flex; align-items: center; gap: 5px; transition: color 0.2s; }
.top-bar-links a:hover { color: #fff; }
.top-bar-links .material-icons-outlined { font-size: 16px; }

/* ---------- Header ---------- */
.header { background: #fff; border-bottom: 1px solid var(--border); position: sticky; top: 0; z-index: 100; }
.header-inner { display: flex; align-items: center; gap: 32px; padding: 16px 24px; }
.logo { display: flex; align-items: center; gap: 12px; flex-shrink: 0; }
.logo-icon {
    width: 44px; height: 44px;
    background: linear-gradient(135deg, var(--primary), var(--accent));
    border-radius: 10px;
    display: flex; align-items: center; justify-content: center;
    color: #fff;
}
.logo-icon .material-icons-outlined { font-size: 26px; }
.logo-text h1 { font-size: 22px; font-weight: 800; letter-spacing: -0.5px; color: var(--dark); }
.logo-text span { font-size: 11px; color: var(--text-muted); font-weight: 500; }

.search-bar {
    flex: 1;
    display: flex;
    border: 2px solid var(--border);
    border-radius: var(--radius-sm);
    overflow: hidden;
    max-width: 640px;
}
.search-bar:focus-within { border-color: var(--primary); }
.search-bar select {
    border: none;
    background: var(--bg);
    padding: 0 14px;
    font-size: 13px;
    color: var(--text-muted);
    cursor: pointer;
    border-right: 1px solid var(--border);
    outline: none;
}
.search-bar input { flex: 1; border: none; padding: 12px 16px; font-size: 14px; outline: none; }
.search-btn {
    background: var(--primary);
    color: #fff; border: none;
    padding: 0 22px;
    display: flex; align-items: center; gap: 6px;
    font-weight: 600; font-size: 14px; cursor: pointer;
    transition: background 0.2s;
}
.search-btn:hover { background: var(--primary-dark); }

.header-actions { display: flex; gap: 22px; flex-shrink: 0; }
.header-action {
    display: flex; flex-direction: column; align-items: center; gap: 2px;
    font-size: 12px; color: var(--text-muted); position: relative;
    transition: color 0.2s;
}
.header-action:hover { color: var(--primary); }
.header-action .material-icons-outlined { font-size: 24px; color: var(--dark); }
.header-action:hover .material-icons-outlined { color: var(--primary); }
.badge {
    position: absolute; top: -6px; right: 4px;
    background: var(--deal); color: #fff;
    font-size: 10px; font-weight: 700;
    min-width: 18px; height: 18px;
    border-radius: 9px;
    display: flex; align-items: center; justify-content: center;
    padding: 0 4px;
}

/* ---------- Navigation ---------- */
.main-nav { background: #fff; border-bottom: 1px solid var(--border); position: relative; z-index: 90; }
.nav-inner { display: flex; align-items: center; gap: 28px; }
.categories-dropdown { position: relative; }
.categories-btn {
    display: flex; align-items: center; gap: 8px;
    background: var(--primary); color: #fff;
    border: none; padding: 14px 20px;
    font-weight: 600; font-size: 14px; cursor: pointer;
    min-width: 220px;
}
.categories-btn .arrow { margin-left: auto; transition: transform 0.2s; }
.categories-dropdown.open .arrow { transform: rotate(180deg); }
.categories-menu {
    position: absolute; top: 100%; left: 0;
    width: 260px; background: #fff;
    box-shadow: var(--shadow-lg);
    border-radius: 0 0 var(--radius-sm) var(--radius-sm);
    opacity: 0; visibility: hidden; transform: translateY(8px);
    transition: all 0.2s; overflow: hidden;
}
.categories-dropdown.open .categories-menu { opacity: 1; visibility: visible; transform: translateY(0); }
.categories-menu li a {
    display: flex; align-items: center; gap: 12px;
    padding: 12px 20px; font-size: 14px; color: var(--text);
    border-bottom: 1px solid var(--bg);
    transition: all 0.2s;
}
.categories-menu li a:hover { background: var(--primary-light); color: var(--primary); padding-left: 24px; }
.categories-menu li a .material-icons-outlined { font-size: 20px; color: var(--text-muted); }
.categories-menu li.highlight a { color: var(--deal); font-weight: 600; }

.nav-links { display: flex; gap: 6px; }
.nav-links a {
    display: flex; align-items: center; gap: 3px;
    padding: 14px 14px; font-size: 14px; font-weight: 500; color: var(--text);
    position: relative; transition: color 0.2s;
}
.nav-links a .material-icons-outlined { font-size: 18px; }
.nav-links a:hover, .nav-links a.active { color: var(--primary); }
.nav-links a.active::after {
    content: ''; position: absolute; bottom: 0; left: 14px; right: 14px;
    height: 3px; background: var(--primary); border-radius: 3px 3px 0 0;
}
.nav-auth { margin-left: auto; position: relative; }
.nav-auth > a {
    font-weight: 600; font-size: 14px; color: var(--primary);
    padding: 8px 18px; border: 2px solid var(--primary); border-radius: var(--radius-sm);
    transition: all 0.2s; display: inline-block;
}
.nav-auth > a:hover { background: var(--primary); color: #fff; }

/* Logged-in user menu */
.user-menu { position: relative; }
.user-btn {
    display: flex; align-items: center; gap: 6px;
    background: var(--primary-light); color: var(--primary);
    border: none; padding: 8px 14px; border-radius: var(--radius-sm);
    font-weight: 600; font-size: 14px; cursor: pointer; transition: all 0.2s;
}
.user-btn:hover { background: var(--primary); color: #fff; }
.user-btn .arrow { font-size: 18px; transition: transform 0.2s; }
.user-menu.open .arrow { transform: rotate(180deg); }
.user-dropdown {
    position: absolute; top: calc(100% + 8px); right: 0; width: 230px;
    background: #fff; border-radius: var(--radius-sm); box-shadow: var(--shadow-lg);
    opacity: 0; visibility: hidden; transform: translateY(8px); transition: all 0.2s;
    overflow: hidden; z-index: 120;
}
.user-menu.open .user-dropdown { opacity: 1; visibility: visible; transform: translateY(0); }
.user-dropdown-head { padding: 14px 16px; background: var(--bg); border-bottom: 1px solid var(--border); }
.user-dropdown-head strong { display: block; font-size: 14px; color: var(--dark); }
.user-dropdown-head span { font-size: 12px; color: var(--text-muted); }
.user-dropdown a {
    display: flex; align-items: center; gap: 10px; padding: 12px 16px;
    font-size: 14px; color: var(--text); transition: all 0.2s;
}
.user-dropdown a:hover { background: var(--primary-light); color: var(--primary); }
.user-dropdown a .material-icons-outlined { font-size: 20px; color: var(--text-muted); }
.user-dropdown a:hover .material-icons-outlined { color: var(--primary); }
#logoutLink:hover { background: rgba(255,107,44,0.1) !important; color: var(--deal) !important; }
#logoutLink:hover .material-icons-outlined { color: var(--deal); }

/* ---------- Hero ---------- */
.hero {
    background: linear-gradient(135deg, #0f172a 0%, #1e3a8a 55%, #1a56db 100%);
    color: #fff; overflow: hidden; position: relative;
}
.hero-inner {
    display: grid; grid-template-columns: 1.1fr 1fr;
    gap: 40px; padding: 60px 24px 0;
    align-items: center;
}
.hero-content { padding-bottom: 60px; }
.hero-tagline {
    display: inline-block; font-size: 13px; font-weight: 700; letter-spacing: 2px;
    color: var(--accent); margin-bottom: 16px; transition: opacity 0.2s;
}
a.hero-tagline:hover { opacity: 0.8; }

/* Hero slider (uploaded from admin) */
.hero-slider { position: relative; width: 400px; max-width: 100%; border-radius: 18px; overflow: hidden; box-shadow: var(--shadow-lg); }
.hero-track { display: flex; transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1); }
.hero-slide { min-width: 100%; }
.hero-slide img { width: 100%; height: 330px; object-fit: cover; display: block; }
.hero-slide a { display: block; }
.hero-arrow {
    position: absolute; top: 50%; transform: translateY(-50%);
    width: 38px; height: 38px; border-radius: 50%; background: rgba(255,255,255,0.85);
    border: none; cursor: pointer; display: flex; align-items: center; justify-content: center;
    color: var(--dark); transition: background 0.2s; z-index: 2;
}
.hero-arrow:hover { background: #fff; }
.hero-arrow.prev { left: 10px; }
.hero-arrow.next { right: 10px; }
.hero-dots { position: absolute; bottom: 12px; left: 0; right: 0; display: flex; justify-content: center; gap: 8px; z-index: 2; }
.hero-dot { width: 9px; height: 9px; border-radius: 50%; border: none; background: rgba(255,255,255,0.55); cursor: pointer; padding: 0; transition: all 0.2s; }
.hero-dot.active { background: #fff; width: 22px; border-radius: 5px; }
.hero-content h2 { font-size: 48px; font-weight: 800; line-height: 1.1; letter-spacing: -1px; margin-bottom: 18px; }
.hero-content p { font-size: 17px; color: #cbd5e1; margin-bottom: 30px; max-width: 460px; }
.hero-buttons { display: flex; gap: 14px; }

.hero-image { display: flex; justify-content: center; align-items: center; padding-bottom: 40px; }
.hero-visual { position: relative; width: 380px; height: 340px; }
.circuit-board {
    position: absolute; inset: 0;
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(6,182,212,0.3);
    border-radius: 20px;
}
.chip {
    position: absolute;
    background: rgba(255,255,255,0.08);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(6,182,212,0.4);
    border-radius: 14px;
    padding: 16px; text-align: center;
    display: flex; flex-direction: column; align-items: center; gap: 8px;
    animation: float 4s ease-in-out infinite;
}
.chip .material-icons-outlined { font-size: 34px; color: var(--accent); }
.chip-label { font-size: 12px; font-weight: 600; color: #e2e8f0; }
.main-chip { top: 100px; left: 120px; transform: translateX(0); animation-delay: 0s; }
.sensor-chip { top: 30px; left: 20px; animation-delay: 0.8s; }
.wifi-chip { top: 40px; right: 20px; animation-delay: 1.6s; }
.motor-chip { bottom: 30px; right: 40px; animation-delay: 2.4s; }
@keyframes float { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-12px); } }
.trace { position: absolute; background: linear-gradient(90deg, transparent, var(--accent), transparent); opacity: 0.5; }
.trace-1 { width: 120px; height: 2px; top: 90px; left: 90px; }
.trace-2 { width: 2px; height: 90px; top: 90px; left: 180px; }
.trace-3 { width: 100px; height: 2px; bottom: 90px; right: 90px; }
.pulse-dot {
    position: absolute; width: 10px; height: 10px; border-radius: 50%;
    background: var(--accent); box-shadow: 0 0 12px var(--accent);
    animation: pulse 2s ease-in-out infinite;
}
.dot-1 { top: 85px; left: 85px; }
.dot-2 { top: 175px; left: 175px; animation-delay: 0.6s; }
.dot-3 { bottom: 85px; right: 85px; animation-delay: 1.2s; }
@keyframes pulse { 0%,100% { opacity: 0.4; transform: scale(1); } 50% { opacity: 1; transform: scale(1.4); } }

.hero-features {
    grid-column: 1 / -1;
    display: grid; grid-template-columns: repeat(4, 1fr);
    gap: 1px; background: rgba(255,255,255,0.1);
    margin-top: 20px;
}
.hero-feature {
    background: rgba(15,23,42,0.6);
    display: flex; align-items: center; gap: 12px;
    padding: 20px 24px;
}
.hero-feature .material-icons-outlined { font-size: 30px; color: var(--accent); }
.hero-feature strong { display: block; font-size: 14px; }
.hero-feature span { font-size: 12px; color: #94a3b8; }

/* ---------- Section Header ---------- */
section { padding: 56px 0; }
.section-header {
    display: flex; justify-content: space-between; align-items: center;
    margin-bottom: 32px;
}
.section-header h2 { font-size: 28px; font-weight: 800; letter-spacing: -0.5px; color: var(--dark); }
.section-header.centered { flex-direction: column; text-align: center; gap: 8px; }
.section-header.centered p { color: var(--text-muted); }
.view-all { display: inline-flex; align-items: center; gap: 4px; color: var(--primary); font-weight: 600; font-size: 14px; }
.view-all:hover { gap: 8px; }
.view-all .material-icons-outlined { font-size: 18px; transition: all 0.2s; }

/* ---------- Categories ---------- */
.categories-grid {
    display: grid; grid-template-columns: repeat(9, 1fr); gap: 16px;
}
.category-card {
    background: #fff; border: 1px solid var(--border);
    border-radius: var(--radius); padding: 22px 12px;
    text-align: center; cursor: pointer; transition: all 0.25s;
}
.category-card:hover { border-color: var(--primary); transform: translateY(-6px); box-shadow: var(--shadow); }
.category-icon {
    width: 56px; height: 56px; margin: 0 auto 12px;
    background: var(--primary-light); border-radius: 14px;
    display: flex; align-items: center; justify-content: center;
    transition: all 0.25s;
}
.category-icon .material-icons-outlined { font-size: 28px; color: var(--primary); }
.category-icon img { width: 100%; height: 100%; object-fit: contain; border-radius: 10px; }
.category-card:hover .category-icon { background: var(--primary); }
.category-card:hover .category-icon img { }
.cat-menu-img { width: 20px; height: 20px; object-fit: contain; border-radius: 4px; vertical-align: middle; }
.category-card:hover .category-icon .material-icons-outlined { color: #fff; }
.category-card h3 { font-size: 13px; font-weight: 600; color: var(--text); }

/* ---------- Products ---------- */
.product-tabs { display: flex; gap: 8px; }
.tab-btn {
    background: #fff; border: 1px solid var(--border);
    padding: 9px 18px; border-radius: var(--radius-sm);
    font-size: 13px; font-weight: 600; color: var(--text-muted);
    cursor: pointer; transition: all 0.2s;
}
.tab-btn:hover { border-color: var(--primary); color: var(--primary); }
.tab-btn.active { background: var(--primary); color: #fff; border-color: var(--primary); }

.products-grid {
    display: grid; grid-template-columns: repeat(5, 1fr); gap: 20px;
}
.product-card {
    background: #fff; border: 1px solid var(--border);
    border-radius: var(--radius); overflow: hidden;
    transition: all 0.25s; position: relative;
    display: flex; flex-direction: column;
}
.product-card:hover { border-color: var(--primary); box-shadow: var(--shadow-lg); transform: translateY(-4px); }
.product-badge {
    position: absolute; top: 12px; left: 12px; z-index: 2;
    background: var(--deal); color: #fff;
    font-size: 11px; font-weight: 700; padding: 4px 10px;
    border-radius: 20px;
}
.product-badge.new { background: var(--success); }
.product-badge.bestseller { background: var(--primary); }
.product-wishlist {
    position: absolute; top: 12px; right: 12px; z-index: 2;
    width: 36px; height: 36px; border-radius: 50%;
    background: #fff; border: 1px solid var(--border);
    display: flex; align-items: center; justify-content: center;
    cursor: pointer; transition: all 0.2s; color: var(--text-muted);
}
.product-wishlist:hover, .product-wishlist.active { background: var(--deal); color: #fff; border-color: var(--deal); }
.product-wishlist .material-icons-outlined { font-size: 20px; }
.product-image {
    height: 190px; background: #fff; padding: 14px;
    display: flex; align-items: center; justify-content: center;
    position: relative;
}
.product-image img { width: 100%; height: 100%; object-fit: contain; }
.product-image .material-icons-outlined { font-size: 76px; color: var(--primary); opacity: 0.85; }
.product-info { padding: 16px; flex: 1; display: flex; flex-direction: column; }
.product-category { font-size: 11px; color: var(--text-light); text-transform: uppercase; letter-spacing: 0.5px; font-weight: 600; }
.product-name { font-size: 14px; font-weight: 600; color: var(--dark); margin: 6px 0; line-height: 1.4; min-height: 40px; }
.product-rating { display: flex; align-items: center; gap: 4px; margin-bottom: 10px; }
.product-rating .stars { display: flex; color: var(--star); }
.product-rating .stars .material-icons-outlined { font-size: 15px; }
.product-rating .count { font-size: 12px; color: var(--text-muted); }
.product-price-row { display: flex; align-items: center; gap: 8px; margin-top: auto; margin-bottom: 12px; }
.product-price { font-size: 19px; font-weight: 800; color: var(--dark); }
.product-old-price { font-size: 13px; color: var(--text-light); text-decoration: line-through; }
.add-to-cart {
    width: 100%; background: var(--primary-light); color: var(--primary);
    border: none; padding: 11px; border-radius: var(--radius-sm);
    font-weight: 600; font-size: 13px; cursor: pointer;
    display: flex; align-items: center; justify-content: center; gap: 6px;
    transition: all 0.2s;
}
.add-to-cart:hover { background: var(--primary); color: #fff; }
.add-to-cart .material-icons-outlined { font-size: 18px; }

/* ---------- Deals Banner ---------- */
.deals-banner {
    background: linear-gradient(120deg, var(--deal) 0%, var(--deal-dark) 100%);
    color: #fff; margin: 0; position: relative; overflow: hidden;
}
.deals-inner { display: grid; grid-template-columns: 1.2fr 1fr; align-items: center; gap: 40px; }
.deals-badge {
    display: inline-block; background: rgba(255,255,255,0.2);
    padding: 6px 16px; border-radius: 20px; font-size: 12px; font-weight: 700;
    letter-spacing: 1px; margin-bottom: 16px;
}
.deals-content h2 { font-size: 40px; font-weight: 800; margin-bottom: 12px; letter-spacing: -1px; }
.deals-content > p { font-size: 18px; margin-bottom: 24px; }
.deals-content strong { font-size: 22px; }
.countdown { display: flex; gap: 14px; margin-bottom: 28px; }
.countdown-item {
    background: rgba(255,255,255,0.15); backdrop-filter: blur(6px);
    border-radius: var(--radius-sm); padding: 14px 18px; text-align: center; min-width: 72px;
}
.countdown-item .count { display: block; font-size: 30px; font-weight: 800; line-height: 1; }
.countdown-item .label { font-size: 11px; text-transform: uppercase; letter-spacing: 1px; opacity: 0.85; }
.deals-banner .btn-primary { background: #fff; color: var(--deal-dark); }
.deals-banner .btn-primary:hover { background: var(--dark); color: #fff; }
.deals-visual { position: relative; height: 260px; display: flex; align-items: center; justify-content: center; }
.floating-product {
    position: absolute; width: 120px; height: 120px;
    background: rgba(255,255,255,0.15); backdrop-filter: blur(8px);
    border: 1px solid rgba(255,255,255,0.3); border-radius: 20px;
    display: flex; align-items: center; justify-content: center;
    animation: float 4s ease-in-out infinite;
}
.floating-product .material-icons-outlined { font-size: 56px; color: #fff; }
.discount-tag {
    position: absolute; top: -10px; right: -10px;
    background: var(--dark); color: #fff; font-size: 13px; font-weight: 700;
    padding: 4px 10px; border-radius: 20px;
}
.fp-1 { top: 20px; left: 40px; }
.fp-2 { top: 70px; right: 60px; animation-delay: 1s; }
.fp-3 { bottom: 10px; left: 130px; animation-delay: 2s; }
/* Deals slider (uploaded from admin) */
.ds-slider { position: relative; width: 100%; max-width: 400px; border-radius: 16px; overflow: hidden; box-shadow: 0 12px 32px rgba(0,0,0,0.28); }
.ds-track { display: flex; transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1); }
.ds-slide { min-width: 100%; }
.ds-slide img { width: 100%; height: 240px; object-fit: cover; display: block; }
.ds-slide a { display: block; }
.ds-arrow {
    position: absolute; top: 50%; transform: translateY(-50%);
    width: 34px; height: 34px; border-radius: 50%; background: rgba(255,255,255,0.9);
    border: none; cursor: pointer; display: flex; align-items: center; justify-content: center;
    color: var(--deal-dark); z-index: 2;
}
.ds-arrow.prev { left: 8px; }
.ds-arrow.next { right: 8px; }
.ds-arrow .material-icons-outlined { font-size: 20px; }
.ds-dots { position: absolute; bottom: 10px; left: 0; right: 0; display: flex; justify-content: center; gap: 6px; z-index: 2; }
.ds-dot { width: 8px; height: 8px; border-radius: 50%; border: none; background: rgba(255,255,255,0.55); cursor: pointer; padding: 0; transition: all 0.2s; }
.ds-dot.active { background: #fff; width: 20px; border-radius: 4px; }

/* ---------- Why Us ---------- */
.why-us { background: #fff; }
.why-us-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }
.why-card { text-align: center; padding: 28px 20px; border-radius: var(--radius); transition: all 0.25s; }
.why-card:hover { background: var(--bg); transform: translateY(-4px); }
.why-icon {
    width: 68px; height: 68px; margin: 0 auto 18px;
    background: linear-gradient(135deg, var(--primary), var(--accent));
    border-radius: 18px; display: flex; align-items: center; justify-content: center;
}
.why-icon .material-icons-outlined { font-size: 34px; color: #fff; }
.why-card h3 { font-size: 17px; font-weight: 700; margin-bottom: 8px; color: var(--dark); }
.why-card p { font-size: 14px; color: var(--text-muted); }

/* ---------- YouTube Channel Promo ---------- */
.yt-promo { padding: 56px 0; background: linear-gradient(120deg, #1a1a1a 0%, #cc0000 120%); color: #fff; }
.yt-promo-inner { display: grid; grid-template-columns: 1.3fr 1fr; gap: 40px; align-items: center; }
.yt-promo-content .yt-logo { width: 60px; height: 60px; border-radius: 16px; background: #ff0000; display: flex; align-items: center; justify-content: center; margin-bottom: 18px; box-shadow: 0 6px 20px rgba(255,0,0,0.4); }
.yt-promo-content .yt-logo .material-icons-outlined { font-size: 36px; color: #fff; }
.yt-promo-content h2 { font-size: 32px; font-weight: 800; margin-bottom: 12px; letter-spacing: -0.5px; }
.yt-promo-content p { font-size: 16px; color: rgba(255,255,255,0.85); margin-bottom: 24px; max-width: 460px; }
.yt-btn { background: #fff; color: #cc0000; padding: 14px 28px; font-size: 15px; }
.yt-btn:hover { background: #ff0000; color: #fff; transform: translateY(-2px); }
.yt-btn .material-icons-outlined { font-size: 20px; }
.yt-promo-video { position: relative; display: block; border-radius: var(--radius); overflow: hidden; box-shadow: 0 16px 40px rgba(0,0,0,0.4); aspect-ratio: 16/9; }
.yt-promo-video img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.3s; }
.yt-promo-video:hover img { transform: scale(1.05); }
.yt-play { position: absolute; top: 50%; left: 50%; transform: translate(-50%,-50%); width: 66px; height: 66px; border-radius: 50%; background: #ff0000; display: flex; align-items: center; justify-content: center; box-shadow: 0 4px 16px rgba(0,0,0,0.4); }
.yt-play .material-icons-outlined { color: #fff; font-size: 40px; margin-left: 3px; }

/* ---------- Small Ad Cards ---------- */
.ad-banner-section { padding: 36px 0; }
.ad-cards-head { margin-bottom: 14px; }
.ad-tag { display: inline-block; background: var(--bg); color: var(--text-muted); font-size: 10px; font-weight: 700; letter-spacing: 1px; text-transform: uppercase; padding: 4px 12px; border-radius: 20px; border: 1px solid var(--border); }
.ad-cards-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 16px; }
.ad-card { display: block; background: #fff; border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; transition: all 0.25s; }
a.ad-card { cursor: pointer; }
a.ad-card:hover { border-color: var(--primary); box-shadow: var(--shadow-lg); transform: translateY(-4px); }
.ad-card-img { height: 120px; background: var(--bg); }
.ad-card-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.ad-card-title { padding: 12px 14px; font-size: 14px; font-weight: 600; color: var(--dark); }

@media (max-width: 800px) {
    .yt-promo-inner { grid-template-columns: 1fr; }
    .yt-promo-content h2 { font-size: 26px; }
    .ad-cards-grid { grid-template-columns: repeat(2, 1fr); }
}

/* ---------- Newsletter ---------- */
.newsletter { background: linear-gradient(135deg, var(--dark) 0%, var(--dark-2) 100%); }
.newsletter-inner { display: flex; align-items: center; justify-content: space-between; gap: 40px; flex-wrap: wrap; }
.newsletter-content h2 { font-size: 28px; font-weight: 800; color: #fff; margin-bottom: 6px; }
.newsletter-content p { color: #94a3b8; font-size: 15px; }
.newsletter-form { display: flex; gap: 10px; flex: 1; max-width: 480px; min-width: 300px; }
.newsletter-form input {
    flex: 1; padding: 14px 18px; border: none; border-radius: var(--radius-sm);
    font-size: 14px; outline: none;
}

/* ---------- Footer ---------- */
.footer { background: #0b1120; color: #94a3b8; padding: 56px 0 0; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1.4fr; gap: 40px; padding-bottom: 40px; }
.footer-logo { display: flex; align-items: center; gap: 12px; margin-bottom: 18px; }
.footer-logo .logo-text h3 { color: #fff; font-size: 20px; font-weight: 800; }
.footer-logo .logo-text span { font-size: 11px; }
.footer-col > p { font-size: 14px; margin-bottom: 18px; line-height: 1.7; }
.footer-col h4 { color: #fff; font-size: 16px; font-weight: 700; margin-bottom: 18px; }
.footer-col ul li { margin-bottom: 11px; }
.footer-col ul li a { font-size: 14px; transition: all 0.2s; }
.footer-col ul li a:hover { color: var(--accent); padding-left: 5px; }
.social-links { display: flex; gap: 10px; }
.social-links a {
    width: 40px; height: 40px; border-radius: 10px;
    background: rgba(255,255,255,0.08);
    display: flex; align-items: center; justify-content: center;
    color: #cbd5e1; transition: all 0.2s;
}
.social-links a:hover { background: var(--primary); color: #fff; transform: translateY(-3px); }
.contact-info p { display: flex; align-items: center; gap: 10px; font-size: 14px; margin-bottom: 12px; }
.contact-info .material-icons-outlined { font-size: 20px; color: var(--accent); }
.footer-bottom {
    border-top: 1px solid rgba(255,255,255,0.08);
    padding: 22px 0; display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 16px;
    font-size: 13px;
}
.payment-methods { display: flex; align-items: center; gap: 12px; }
.payment-icons { display: flex; gap: 8px; }
.payment-icon {
    background: rgba(255,255,255,0.1); color: #cbd5e1;
    padding: 5px 10px; border-radius: 6px; font-size: 12px; font-weight: 600;
}

/* ---------- Cart Sidebar ---------- */
.cart-overlay {
    position: fixed; inset: 0; background: rgba(15,23,42,0.5);
    opacity: 0; visibility: hidden; transition: all 0.3s; z-index: 200;
}
.cart-overlay.open { opacity: 1; visibility: visible; }
.cart-sidebar {
    position: fixed; top: 0; right: 0; height: 100%; width: 420px; max-width: 90vw;
    background: #fff; z-index: 210; display: flex; flex-direction: column;
    transform: translateX(100%); transition: transform 0.3s ease;
    box-shadow: var(--shadow-lg);
}
.cart-sidebar.open { transform: translateX(0); }
.cart-header {
    display: flex; justify-content: space-between; align-items: center;
    padding: 20px 24px; border-bottom: 1px solid var(--border);
}
.cart-header h3 { display: flex; align-items: center; gap: 10px; font-size: 18px; font-weight: 700; }
.close-cart { background: var(--bg); border: none; width: 38px; height: 38px; border-radius: 50%; cursor: pointer; color: var(--text); transition: all 0.2s; }
.close-cart:hover { background: var(--deal); color: #fff; }
.cart-items { flex: 1; overflow-y: auto; padding: 16px 24px; }
.empty-cart { text-align: center; padding: 60px 20px; color: var(--text-light); }
.empty-cart .material-icons-outlined { font-size: 64px; margin-bottom: 12px; }
.cart-item { display: flex; gap: 14px; padding: 14px 0; border-bottom: 1px solid var(--bg); }
.cart-item-img {
    width: 64px; height: 64px; border-radius: var(--radius-sm); background: var(--bg);
    display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.cart-item-img .material-icons-outlined { font-size: 34px; color: var(--primary); }
.cart-item-details { flex: 1; }
.cart-item-details h4 { font-size: 14px; font-weight: 600; margin-bottom: 4px; }
.cart-item-price { color: var(--primary); font-weight: 700; font-size: 14px; }
.cart-item-controls { display: flex; align-items: center; gap: 10px; margin-top: 8px; }
.qty-btn {
    width: 26px; height: 26px; border: 1px solid var(--border); background: #fff;
    border-radius: 6px; cursor: pointer; display: flex; align-items: center; justify-content: center;
    font-size: 16px; color: var(--text); transition: all 0.2s;
}
.qty-btn:hover { background: var(--primary); color: #fff; border-color: var(--primary); }
.cart-item-qty { font-weight: 600; font-size: 14px; min-width: 20px; text-align: center; }
.remove-item { margin-left: auto; background: none; border: none; cursor: pointer; color: var(--text-light); }
.remove-item:hover { color: var(--deal); }
.cart-footer { padding: 20px 24px; border-top: 1px solid var(--border); }
.cart-total { display: flex; justify-content: space-between; align-items: center; margin-bottom: 16px; font-size: 16px; }
.cart-total strong { font-size: 22px; color: var(--dark); }
.cart-footer .btn { margin-bottom: 10px; }
.cart-footer .btn-outline { border-color: var(--primary); color: var(--primary); }
.cart-footer .btn-outline:hover { background: var(--primary-light); }

/* ---------- Login Modal ---------- */
.modal-overlay {
    position: fixed; inset: 0; background: rgba(15,23,42,0.6);
    display: flex; align-items: center; justify-content: center;
    opacity: 0; visibility: hidden; transition: all 0.3s; z-index: 300; padding: 20px;
}
.modal-overlay.open { opacity: 1; visibility: visible; }
.modal {
    background: #fff; border-radius: var(--radius); width: 100%; max-width: 420px;
    padding: 36px; position: relative; transform: translateY(20px); transition: transform 0.3s;
    max-height: 92vh; overflow-y: auto;
}
.modal-overlay.open .modal { transform: translateY(0); }
.modal-close { position: absolute; top: 16px; right: 16px; z-index: 6; background: var(--bg); border: none; width: 36px; height: 36px; border-radius: 50%; cursor: pointer; transition: all 0.2s; }
.modal-close:hover { background: var(--deal); color: #fff; }
.modal-header { text-align: center; margin-bottom: 24px; }
.modal-header .logo-icon { margin: 0 auto 14px; }
.modal-header h2 { font-size: 24px; font-weight: 800; color: var(--dark); }
.modal-header p { color: var(--text-muted); font-size: 14px; }
.modal-form .form-group { margin-bottom: 16px; }
.modal-form label { display: block; font-size: 13px; font-weight: 600; margin-bottom: 6px; }
.modal-form input[type="email"], .modal-form input[type="password"] {
    width: 100%; padding: 12px 14px; border: 2px solid var(--border);
    border-radius: var(--radius-sm); font-size: 14px; outline: none; transition: border 0.2s;
}
.modal-form input:focus { border-color: var(--primary); }
.form-row { display: flex; justify-content: space-between; align-items: center; margin-bottom: 20px; font-size: 13px; }
.checkbox-label { display: flex; align-items: center; gap: 6px; color: var(--text-muted); cursor: pointer; }
.form-row a { color: var(--primary); font-weight: 600; }
.divider { text-align: center; position: relative; margin: 20px 0; }
.divider::before { content: ''; position: absolute; top: 50%; left: 0; right: 0; height: 1px; background: var(--border); }
.divider span { background: #fff; padding: 0 14px; position: relative; color: var(--text-light); font-size: 13px; }
.modal-footer-text { text-align: center; font-size: 14px; color: var(--text-muted); margin-top: 18px; }
.modal-footer-text a { color: var(--primary); font-weight: 600; }

/* ---------- Product Detail Modal ---------- */
.product-detail-modal { max-width: 900px; padding: 0; overflow: hidden; }

/* Promo / blog link banner at the top of the card */
.pd-promo-banner {
    display: flex; align-items: center; gap: 12px;
    padding: 14px 56px 14px 20px;
    background: linear-gradient(100deg, var(--deal) 0%, #ff9a3c 50%, var(--deal) 100%);
    background-size: 200% 100%;
    color: #fff; font-weight: 700; font-size: 15px;
    position: relative; overflow: hidden;
    animation: promoShine 4s linear infinite;
}
@keyframes promoShine { 0% { background-position: 0% 0; } 100% { background-position: 200% 0; } }
.pd-promo-banner:hover { filter: brightness(1.05); }
.pd-promo-icon {
    width: 34px; height: 34px; border-radius: 50%; flex-shrink: 0;
    background: rgba(255,255,255,0.22);
    display: flex; align-items: center; justify-content: center;
    animation: promoRing 1.6s ease-in-out infinite;
}
.pd-promo-icon .material-icons-outlined { font-size: 20px; }
@keyframes promoRing { 0%,100% { transform: rotate(0); } 20% { transform: rotate(-12deg); } 40% { transform: rotate(12deg); } 60% { transform: rotate(-8deg); } 80% { transform: rotate(8deg); } }
.pd-promo-text { flex: 1; line-height: 1.35; text-shadow: 0 1px 2px rgba(0,0,0,0.15); }
.pd-promo-arrow {
    width: 30px; height: 30px; border-radius: 50%; flex-shrink: 0;
    background: rgba(255,255,255,0.9); color: var(--deal-dark);
    display: flex; align-items: center; justify-content: center;
    transition: transform 0.2s;
}
.pd-promo-banner:hover .pd-promo-arrow { transform: translateX(4px); }
.pd-promo-arrow .material-icons-outlined { font-size: 20px; }

.pd-body { display: grid; grid-template-columns: 1fr 1.1fr; }
.pd-gallery { background: var(--bg); padding: 32px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 16px; position: relative; min-height: 420px; }
.pd-badges { position: absolute; top: 20px; left: 20px; display: flex; flex-direction: column; gap: 8px; z-index: 2; }
.pd-badges .product-badge { position: static; }
.pd-image { width: 100%; flex: 1; min-height: 200px; display: flex; align-items: center; justify-content: center; }
.pd-image img { max-width: 100%; max-height: 340px; object-fit: contain; border-radius: var(--radius); }
.pd-image .material-icons-outlined { font-size: 160px; color: var(--primary); opacity: 0.85; }

/* Product image thumbnails (gallery) */
.pd-thumbs { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; justify-content: center; }
.pd-thumb { width: 60px; height: 60px; border-radius: 8px; border: 2px solid var(--border); background: #fff; padding: 3px; cursor: pointer; overflow: hidden; transition: all 0.2s; }
.pd-thumb img { width: 100%; height: 100%; object-fit: contain; }
.pd-thumb:hover { border-color: var(--primary); }
.pd-thumb.active { border-color: var(--primary); box-shadow: 0 0 0 2px var(--primary-light); }

/* Product video card */
.pd-video { width: 100%; margin-top: 16px; }
.pd-video-card {
    position: relative; width: 100%; aspect-ratio: 16 / 9; border-radius: var(--radius);
    overflow: hidden; cursor: pointer; background: #000; box-shadow: var(--shadow);
}
.pd-video-card img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.3s, filter 0.3s; }
.pd-video-card:hover img { transform: scale(1.05); filter: brightness(0.85); }
.pd-video-play {
    position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%);
    width: 60px; height: 60px; border-radius: 50%; background: #ff0000;
    display: flex; align-items: center; justify-content: center;
    box-shadow: 0 4px 16px rgba(0,0,0,0.4); transition: transform 0.2s;
}
.pd-video-card:hover .pd-video-play { transform: translate(-50%, -50%) scale(1.12); }
.pd-video-play .material-icons-outlined { color: #fff; font-size: 36px; margin-left: 2px; }
.pd-video-tag {
    position: absolute; bottom: 12px; left: 12px;
    display: flex; align-items: center; gap: 6px;
    background: rgba(0,0,0,0.7); color: #fff; padding: 6px 12px; border-radius: 20px;
    font-size: 12px; font-weight: 600;
}
.pd-video-tag .material-icons-outlined { font-size: 18px; }
.pd-video-frame { width: 100%; aspect-ratio: 16 / 9; border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); background: #000; }
.pd-video-frame iframe { width: 100%; height: 100%; border: 0; display: block; }
.pd-video-fallback {
    display: inline-flex; align-items: center; gap: 6px; margin-top: 10px;
    font-size: 13px; font-weight: 600; color: var(--primary);
}
.pd-video-fallback:hover { text-decoration: underline; }
.pd-video-fallback .material-icons-outlined { font-size: 17px; }
.pd-info { padding: 36px 32px; overflow-y: auto; max-height: 88vh; }
.pd-category { font-size: 12px; text-transform: uppercase; letter-spacing: 0.5px; color: var(--primary); font-weight: 700; }
.pd-info h2 { font-size: 26px; font-weight: 800; color: var(--dark); margin: 8px 0 12px; line-height: 1.25; }
.pd-rating-row { display: flex; align-items: center; gap: 8px; margin-bottom: 16px; }
.pd-stars { display: inline-flex; color: var(--star); }
.pd-stars .material-icons-outlined { font-size: 18px; }
.pd-reviews { font-size: 13px; color: var(--text-muted); }
.pd-price-row { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; flex-wrap: wrap; }
.pd-price { font-size: 30px; font-weight: 800; color: var(--dark); }
.pd-old-price { font-size: 17px; color: var(--text-light); text-decoration: line-through; }
.pd-discount { background: rgba(255,107,44,0.12); color: var(--deal); font-size: 13px; font-weight: 700; padding: 4px 10px; border-radius: 20px; }
.pd-stock { margin-bottom: 16px; font-size: 14px; font-weight: 600; }
.pd-stock .in { color: var(--success); }
.pd-stock .low { color: var(--deal); }
.pd-stock .out { color: #ef4444; }
.pd-description { font-size: 14px; color: var(--text-muted); line-height: 1.7; margin-bottom: 18px; }
.pd-meta { display: flex; flex-wrap: wrap; gap: 22px; padding: 16px 0; border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); margin-bottom: 20px; }
.pd-meta div { display: flex; flex-direction: column; gap: 2px; }
.pd-meta span { font-size: 12px; color: var(--text-light); }
.pd-meta strong { font-size: 14px; color: var(--text); }
.pd-actions { display: flex; align-items: center; gap: 12px; margin-bottom: 24px; }
.pd-qty { display: flex; align-items: center; border: 2px solid var(--border); border-radius: var(--radius-sm); overflow: hidden; }
.pd-qty button { width: 42px; height: 46px; border: none; background: var(--bg); font-size: 20px; cursor: pointer; color: var(--text); transition: background 0.2s; }
.pd-qty button:hover { background: var(--primary); color: #fff; }
.pd-qty span { min-width: 44px; text-align: center; font-weight: 700; font-size: 15px; }
.pd-add { flex: 1; height: 46px; }
.pd-wish { width: 46px; height: 46px; border: 2px solid var(--border); background: #fff; border-radius: var(--radius-sm); cursor: pointer; color: var(--text-muted); display: flex; align-items: center; justify-content: center; transition: all 0.2s; }
.pd-wish:hover, .pd-wish.active { background: var(--deal); color: #fff; border-color: var(--deal); }
.pd-specs h3 { font-size: 16px; font-weight: 700; color: var(--dark); margin-bottom: 12px; }
.pd-specs-table { width: 100%; border-collapse: collapse; }
.pd-specs-table tr { border-bottom: 1px solid var(--bg); }
.pd-specs-table td { padding: 10px 4px; font-size: 13px; }
.pd-specs-table td:first-child { color: var(--text-muted); width: 45%; font-weight: 500; }
.pd-specs-table td:last-child { font-weight: 600; color: var(--text); }

@media (max-width: 720px) {
    .pd-body { grid-template-columns: 1fr; }
    .pd-gallery { min-height: 240px; padding: 30px; }
    .pd-image .material-icons-outlined { font-size: 110px; }
    .pd-info { padding: 24px 20px; max-height: none; overflow: visible; }
    /* modal has overflow:hidden — let the whole modal scroll on phones */
    .product-detail-modal { overflow-y: auto; max-height: 92vh; }
}

/* ---------- Checkout Modal ---------- */
.checkout-modal { max-width: 860px; padding: 0; overflow: hidden; }
.checkout-header { text-align: left; padding: 24px 28px; border-bottom: 1px solid var(--border); margin-bottom: 0; }
.checkout-header h2 { display: flex; align-items: center; gap: 10px; font-size: 22px; }
.checkout-header p { margin-top: 2px; }
.checkout-body { display: grid; grid-template-columns: 1.4fr 1fr; gap: 0; }
.checkout-form { padding: 24px 28px; }
.checkout-summary { padding: 24px 28px; background: var(--bg); border-left: 1px solid var(--border); }
.checkout-section-title { font-size: 15px; font-weight: 700; color: var(--dark); margin: 8px 0 14px; }
.checkout-form .checkout-section-title:first-child { margin-top: 0; }
.checkout-form .form-group { margin-bottom: 14px; }
.checkout-form label { display: block; font-size: 13px; font-weight: 600; margin-bottom: 6px; }
.checkout-form input, .checkout-form textarea {
    width: 100%; padding: 11px 14px; border: 2px solid var(--border);
    border-radius: var(--radius-sm); font-size: 14px; outline: none; font-family: inherit; resize: vertical;
    transition: border 0.2s;
}
.checkout-form input:focus, .checkout-form textarea:focus { border-color: var(--primary); }
.checkout-2col { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.payment-options { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.payment-option input { display: none; }
.payment-card {
    display: flex; align-items: center; gap: 8px; padding: 12px 14px;
    border: 2px solid var(--border); border-radius: var(--radius-sm);
    font-size: 13px; font-weight: 600; cursor: pointer; transition: all 0.2s;
}
.payment-card .material-icons-outlined { font-size: 20px; color: var(--text-muted); }
.payment-option input:checked + .payment-card { border-color: var(--primary); background: var(--primary-light); color: var(--primary); }
.payment-option input:checked + .payment-card .material-icons-outlined { color: var(--primary); }

/* Delivery area selector */
.delivery-area { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 4px; }
.area-option input { display: none; }
.area-card { display: flex; align-items: center; gap: 8px; padding: 12px 14px; border: 2px solid var(--border); border-radius: var(--radius-sm); font-size: 13px; font-weight: 600; cursor: pointer; transition: all 0.2s; }
.area-card .material-icons-outlined { font-size: 20px; color: var(--text-muted); }
.area-card b { margin-left: auto; color: var(--primary); font-weight: 800; }
.area-option input:checked + .area-card { border-color: var(--primary); background: var(--primary-light); color: var(--primary); }
.area-option input:checked + .area-card .material-icons-outlined { color: var(--primary); }

.checkout-items { display: flex; flex-direction: column; gap: 12px; margin-bottom: 18px; max-height: 220px; overflow-y: auto; }
.checkout-item { display: flex; align-items: center; gap: 10px; font-size: 13px; }
.checkout-item-img { width: 44px; height: 44px; border-radius: 8px; background: #fff; display: flex; align-items: center; justify-content: center; flex-shrink: 0; overflow: hidden; border: 1px solid var(--border); }
.checkout-item-img .material-icons-outlined { font-size: 24px; color: var(--primary); }
.checkout-item-img img { width: 100%; height: 100%; object-fit: contain; }
.checkout-item-info { flex: 1; min-width: 0; }
.checkout-item-info h5 { font-size: 13px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.checkout-item-info span { font-size: 12px; color: var(--text-muted); }
.checkout-item-price { font-weight: 700; white-space: nowrap; }
.checkout-totals { border-top: 1px solid var(--border); padding-top: 14px; margin-bottom: 18px; }
.ct-row { display: flex; justify-content: space-between; font-size: 14px; margin-bottom: 8px; color: var(--text-muted); }
.ct-total { font-size: 18px; font-weight: 800; color: var(--dark); border-top: 1px solid var(--border); padding-top: 12px; margin-top: 4px; }
.checkout-secure { text-align: center; font-size: 12px; color: var(--text-muted); margin-top: 12px; display: flex; align-items: center; justify-content: center; gap: 5px; }
.checkout-secure .material-icons-outlined { font-size: 16px; color: var(--success); }

/* Order success */
.success-modal { text-align: center; max-width: 440px; }
.success-icon { width: 80px; height: 80px; margin: 0 auto 18px; border-radius: 50%; background: rgba(22,163,74,0.12); display: flex; align-items: center; justify-content: center; animation: popIn 0.4s ease; }
.success-icon .material-icons-outlined { font-size: 48px; color: var(--success); }
@keyframes popIn { 0% { transform: scale(0); } 70% { transform: scale(1.15); } 100% { transform: scale(1); } }
.success-modal h2 { font-size: 24px; font-weight: 800; color: var(--dark); margin-bottom: 8px; }
.success-modal > p { color: var(--text-muted); margin-bottom: 18px; }
.success-order-id { background: var(--bg); border-radius: var(--radius-sm); padding: 12px; font-size: 14px; margin-bottom: 14px; }
.success-order-id strong { color: var(--primary); }
.success-detail { text-align: left; font-size: 13px; color: var(--text-muted); margin-bottom: 20px; }
.success-detail div { display: flex; justify-content: space-between; padding: 4px 0; }

@media (max-width: 720px) {
    .checkout-body { grid-template-columns: 1fr; }
    .checkout-summary { border-left: none; border-top: 1px solid var(--border); }
    .payment-options { grid-template-columns: 1fr; }
    .checkout-modal { overflow-y: auto; max-height: 92vh; }
    .checkout-2col { grid-template-columns: 1fr; }
}

/* ---------- Sort control ---------- */
.products-controls { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.sort-select {
    border: 1px solid var(--border); background: #fff; border-radius: var(--radius-sm);
    padding: 9px 14px; font-size: 13px; font-weight: 600; color: var(--text-muted); cursor: pointer; outline: none;
}
.sort-select:focus { border-color: var(--primary); }
.btn-sm { padding: 8px 14px; font-size: 12px; }

/* ---------- Checkout promo ---------- */
.promo-box { display: flex; gap: 8px; margin-bottom: 8px; }
.promo-box input { flex: 1; padding: 11px 14px; border: 2px solid var(--border); border-radius: var(--radius-sm); font-size: 13px; outline: none; }
.promo-box input:focus { border-color: var(--primary); }
.promo-box button { background: var(--dark); color: #fff; border: none; padding: 0 18px; border-radius: var(--radius-sm); font-weight: 600; font-size: 13px; cursor: pointer; transition: background 0.2s; }
.promo-box button:hover { background: var(--primary); }
.promo-hint { font-size: 12px; margin-bottom: 12px; min-height: 16px; }
.promo-hint.ok { color: var(--success); }
.promo-hint.error { color: var(--deal); }
.ct-discount { color: var(--success) !important; font-weight: 600; }

/* ---------- Product Detail: reviews & related ---------- */
.pd-reviews { margin-top: 26px; padding-top: 22px; border-top: 1px solid var(--border); }
.pd-reviews h3 { font-size: 16px; font-weight: 700; color: var(--dark); margin-bottom: 14px; }
.pd-no-reviews { font-size: 13px; color: var(--text-muted); margin-bottom: 16px; }
.pd-reviews-list { display: flex; flex-direction: column; gap: 14px; margin-bottom: 20px; }
.pd-review { background: var(--bg); border-radius: var(--radius-sm); padding: 14px; }
.pd-review-head { display: flex; align-items: center; gap: 10px; margin-bottom: 6px; }
.pd-review-avatar { width: 32px; height: 32px; border-radius: 50%; background: var(--primary); color: #fff; display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: 13px; flex-shrink: 0; }
.pd-review-head strong { font-size: 13px; display: block; }
.pd-review-stars-sm .material-icons-outlined { font-size: 14px; color: var(--star); }
.pd-review-date { margin-left: auto; font-size: 12px; color: var(--text-light); }
.pd-review p { font-size: 13px; color: var(--text); }
.pd-review-form { background: var(--bg); border-radius: var(--radius-sm); padding: 16px; }
.pd-review-form h4 { font-size: 14px; font-weight: 700; margin-bottom: 10px; }
.pd-review-stars { display: flex; gap: 2px; margin-bottom: 10px; cursor: pointer; }
.pd-review-stars .material-icons-outlined { font-size: 26px; color: var(--star); transition: transform 0.1s; }
.pd-review-stars .material-icons-outlined:hover { transform: scale(1.15); }
.pd-review-form textarea { width: 100%; padding: 10px 12px; border: 2px solid var(--border); border-radius: var(--radius-sm); font-size: 13px; font-family: inherit; outline: none; resize: vertical; margin-bottom: 10px; }
.pd-review-form textarea:focus { border-color: var(--primary); }

.pd-related { margin-top: 26px; padding-top: 22px; border-top: 1px solid var(--border); }
.pd-related h3 { font-size: 16px; font-weight: 700; color: var(--dark); margin-bottom: 14px; }
.pd-related-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.pd-related-card { cursor: pointer; text-align: center; border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 12px 8px; transition: all 0.2s; }
.pd-related-card:hover { border-color: var(--primary); box-shadow: var(--shadow); transform: translateY(-3px); }
.pd-related-img { height: 64px; display: flex; align-items: center; justify-content: center; margin-bottom: 8px; }
.pd-related-img img { max-height: 64px; max-width: 100%; object-fit: contain; }
.pd-related-img .material-icons-outlined { font-size: 40px; color: var(--primary); opacity: 0.85; }
.pd-related-card h5 { font-size: 11px; font-weight: 600; line-height: 1.3; margin-bottom: 4px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.pd-related-price { font-size: 13px; font-weight: 800; color: var(--dark); }

/* ---------- List Modals (Wishlist / Track / My Orders) ---------- */
.list-modal { max-width: 560px; padding: 0; overflow: hidden; }
.list-modal-header { padding: 22px 24px; border-bottom: 1px solid var(--border); }
.list-modal-header h2 { display: flex; align-items: center; gap: 10px; font-size: 20px; font-weight: 800; }
.list-modal-header h2 .material-icons-outlined { color: var(--primary); }
.list-modal-body { padding: 20px 24px; max-height: 66vh; overflow-y: auto; }
.list-empty { text-align: center; padding: 44px 20px; color: var(--text-light); }
.list-empty .material-icons-outlined { font-size: 56px; margin-bottom: 12px; }
.list-row { display: flex; align-items: center; gap: 14px; padding: 14px 0; border-bottom: 1px solid var(--bg); }
.list-row:last-child { border-bottom: none; }
.list-row-img { width: 56px; height: 56px; border-radius: var(--radius-sm); background: var(--bg); display: flex; align-items: center; justify-content: center; flex-shrink: 0; overflow: hidden; }
.list-row-img img { width: 100%; height: 100%; object-fit: contain; }
.list-row-img .material-icons-outlined { font-size: 30px; color: var(--primary); }
.list-row-info { flex: 1; min-width: 0; }
.list-row-info h4 { font-size: 14px; font-weight: 600; }
.list-row-cat { font-size: 12px; color: var(--text-muted); display: block; }
.list-row-price { font-size: 15px; color: var(--dark); }
.list-row-actions { display: flex; align-items: center; gap: 8px; flex-shrink: 0; }
.list-row-remove { background: none; border: none; cursor: pointer; color: var(--text-light); }
.list-row-remove:hover { color: var(--deal); }

/* Info pages (About / Contact / FAQs / policies) */
.info-body { line-height: 1.7; }
.info-body p { margin-bottom: 12px; color: var(--text); font-size: 14px; }
.info-body h4 { font-size: 15px; font-weight: 700; color: var(--dark); margin: 16px 0 8px; }
.info-body ul { margin: 0 0 12px; padding-left: 20px; }
.info-body ul.info-list, .info-body ul.info-contact { list-style: none; padding-left: 0; }
.info-body ul li { margin-bottom: 8px; font-size: 14px; }
.info-body ul.info-list li { padding: 10px 14px; background: var(--bg); border-radius: var(--radius-sm); }
.info-body ul.info-list li span { font-size: 13px; color: var(--text-muted); }
.info-body ul.info-contact li { display: flex; align-items: center; gap: 10px; }
.info-body ul.info-contact .material-icons-outlined { color: var(--primary); font-size: 20px; }
.info-body a { color: var(--primary); font-weight: 600; }
.info-body .info-faq { margin-bottom: 14px; padding-bottom: 12px; border-bottom: 1px solid var(--bg); }
.info-body .info-faq:last-child { border-bottom: none; }
.info-body .info-faq h4 { margin-top: 0; }
.info-body .info-faq p { margin-bottom: 0; color: var(--text-muted); }

/* Clickable footer contact links */
.contact-info a { color: inherit; transition: color 0.2s; }
.contact-info a:hover { color: var(--accent); }

/* Track order */
.track-search { display: flex; gap: 8px; margin-bottom: 18px; }
.track-search input { flex: 1; padding: 12px 14px; border: 2px solid var(--border); border-radius: var(--radius-sm); font-size: 14px; outline: none; }
.track-search input:focus { border-color: var(--primary); }
.track-empty { text-align: center; padding: 30px; color: var(--text-muted); font-size: 14px; }
.track-empty .material-icons-outlined { display: block; font-size: 44px; margin-bottom: 8px; color: var(--text-light); }
.track-summary { background: var(--bg); border-radius: var(--radius-sm); padding: 12px 16px; font-size: 14px; margin-bottom: 24px; }
.track-cancelled { display: flex; align-items: center; gap: 8px; color: var(--deal); font-weight: 600; padding: 16px; background: rgba(255,107,44,0.08); border-radius: var(--radius-sm); }
.track-timeline { display: flex; justify-content: space-between; position: relative; margin: 0 10px 24px; }
.track-timeline::before { content: ''; position: absolute; top: 22px; left: 22px; right: 22px; height: 3px; background: var(--border); }
.track-step { display: flex; flex-direction: column; align-items: center; gap: 8px; position: relative; z-index: 1; flex: 1; }
.track-dot { width: 44px; height: 44px; border-radius: 50%; background: #fff; border: 3px solid var(--border); display: flex; align-items: center; justify-content: center; color: var(--text-light); }
.track-step.done .track-dot { border-color: var(--success); background: var(--success); color: #fff; }
.track-step.current .track-dot { box-shadow: 0 0 0 5px rgba(22,163,74,0.15); }
.track-label { font-size: 12px; font-weight: 600; color: var(--text-muted); text-align: center; }
.track-step.done .track-label { color: var(--dark); }
.track-address { display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--text-muted); padding-top: 8px; border-top: 1px solid var(--bg); }
.track-address .material-icons-outlined { color: var(--primary); font-size: 20px; }

/* My orders */
.order-row { display: flex; align-items: center; gap: 12px; padding: 14px 0; border-bottom: 1px solid var(--bg); }
.order-row:last-child { border-bottom: none; }
.order-row-main { flex: 1; min-width: 0; }
.order-row-main strong { font-size: 14px; display: block; }
.order-row-main span { font-size: 12px; color: var(--text-muted); }
.order-row-amt { font-size: 15px; color: var(--dark); }
.status-pill { padding: 4px 10px; border-radius: 20px; font-size: 11px; font-weight: 700; text-transform: capitalize; }
.status-pill.status-pending { background: rgba(245,158,11,0.14); color: #b45309; }
.status-pill.status-processing { background: rgba(26,86,219,0.12); color: var(--primary); }
.status-pill.status-delivered { background: rgba(22,163,74,0.14); color: var(--success); }
.status-pill.status-cancelled { background: rgba(239,68,68,0.12); color: #dc2626; }

@media (max-width: 560px) {
    .pd-related-grid { grid-template-columns: repeat(2, 1fr); }
    .track-label { font-size: 10px; }
    .order-row { flex-wrap: wrap; }
    .list-row-actions { flex-direction: column; }
}

/* ---------- Smart features ---------- */

/* Compare button on product cards */
.product-compare {
    position: absolute; top: 56px; right: 12px; z-index: 2;
    width: 36px; height: 36px; border-radius: 50%;
    background: #fff; border: 1px solid var(--border);
    display: flex; align-items: center; justify-content: center;
    cursor: pointer; transition: all 0.2s; color: var(--text-muted);
}
.product-compare:hover, .product-compare.active { background: var(--primary); color: #fff; border-color: var(--primary); }
.product-compare .material-icons-outlined { font-size: 20px; }

/* Live search suggestions */
.search-bar { overflow: visible; position: relative; }
.search-bar select { border-top-left-radius: var(--radius-sm); border-bottom-left-radius: var(--radius-sm); }
.search-btn { border-top-right-radius: var(--radius-sm); border-bottom-right-radius: var(--radius-sm); }
.search-suggest {
    position: absolute; top: calc(100% + 6px); left: 0; right: 0; background: #fff;
    border: 1px solid var(--border); border-radius: var(--radius-sm); box-shadow: var(--shadow-lg);
    z-index: 130; display: none; max-height: 400px; overflow-y: auto;
}
.search-suggest.open { display: block; }
.suggest-item { display: flex; align-items: center; gap: 12px; padding: 10px 14px; cursor: pointer; border-bottom: 1px solid var(--bg); }
.suggest-item:last-child { border-bottom: none; }
.suggest-item:hover { background: var(--primary-light); }
.suggest-thumb { width: 42px; height: 42px; border-radius: 8px; background: var(--bg); display: flex; align-items: center; justify-content: center; flex-shrink: 0; overflow: hidden; }
.suggest-thumb img { width: 100%; height: 100%; object-fit: contain; }
.suggest-thumb .material-icons-outlined { color: var(--primary); }
.suggest-info { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.suggest-name { font-size: 13px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.suggest-cat { font-size: 11px; color: var(--text-muted); }
.suggest-price { font-weight: 700; color: var(--primary); font-size: 13px; }
.suggest-empty { padding: 18px; text-align: center; color: var(--text-muted); font-size: 13px; }

/* Free-shipping progress bar (cart) */
.free-ship-bar { margin-bottom: 14px; }
.fsb-text { font-size: 13px; margin-bottom: 6px; color: var(--text); display: flex; align-items: center; gap: 5px; }
.fsb-text.success { color: var(--success); font-weight: 600; }
.fsb-text .material-icons-outlined { font-size: 18px; }
.fsb-track { height: 7px; background: var(--bg); border-radius: 4px; overflow: hidden; }
.fsb-track span { display: block; height: 100%; background: linear-gradient(90deg, var(--success), #4ade80); border-radius: 4px; transition: width 0.4s; }

/* Available coupons (checkout) */
.available-coupons { margin-bottom: 12px; }
.ac-title { font-size: 12px; color: var(--text-muted); margin-bottom: 6px; }
.ac-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.ac-chip { border: 1px dashed var(--primary); background: var(--primary-light); color: var(--primary); font-size: 12px; font-weight: 700; padding: 5px 10px; border-radius: 6px; cursor: pointer; transition: all 0.2s; }
.ac-chip:hover { background: var(--primary); color: #fff; }

/* Compare modal */
.compare-modal { max-width: 880px; padding: 0; overflow: hidden; }
.compare-body { padding: 20px 24px; max-height: 74vh; overflow-y: auto; }
.compare-scroll { overflow-x: auto; }
.compare-table { width: 100%; border-collapse: collapse; min-width: 480px; }
.compare-table td { padding: 12px 14px; border-bottom: 1px solid var(--bg); font-size: 13px; vertical-align: middle; text-align: center; }
.compare-table .cmp-label { text-align: left; font-weight: 700; color: var(--text-muted); width: 110px; background: var(--bg); position: sticky; left: 0; }
.cmp-cell-img { margin-bottom: 6px; }
.cmp-img { width: 84px; height: 84px; object-fit: contain; margin: 0 auto; display: block; }
.cmp-icon { font-size: 60px; color: var(--primary); }
.cmp-price { color: var(--primary); font-weight: 800; font-size: 15px; }
.compare-table s { color: var(--text-light); font-size: 12px; }
.cmp-stars .material-icons-outlined { font-size: 15px; color: var(--star); }
.cmp-remove { background: none; border: none; color: var(--deal); font-size: 12px; font-weight: 600; cursor: pointer; margin-top: 6px; }
.cmp-remove:hover { text-decoration: underline; }

/* Back to top */
.back-to-top {
    position: fixed; bottom: 158px; right: 22px; z-index: 350;
    width: 46px; height: 46px; border-radius: 50%; border: none; cursor: pointer;
    background: var(--primary); color: #fff; display: flex; align-items: center; justify-content: center;
    box-shadow: var(--shadow-lg); opacity: 0; visibility: hidden; transform: translateY(10px); transition: all 0.25s;
}
.back-to-top.show { opacity: 1; visibility: visible; transform: translateY(0); }
.back-to-top:hover { background: var(--primary-dark); transform: translateY(-2px); }

/* Notifications */
.notif-wrap { position: relative; }
.notif-panel {
    position: absolute; top: calc(100% + 14px); right: 0; width: 330px; max-width: 92vw;
    background: #fff; border: 1px solid var(--border); border-radius: var(--radius-sm);
    box-shadow: var(--shadow-lg); opacity: 0; visibility: hidden; transform: translateY(8px);
    transition: all 0.2s; z-index: 140; overflow: hidden;
}
.notif-wrap.open .notif-panel { opacity: 1; visibility: visible; transform: translateY(0); }
.notif-head { display: flex; justify-content: space-between; align-items: center; padding: 14px 16px; border-bottom: 1px solid var(--border); }
.notif-head strong { font-size: 15px; }
.notif-head button { background: none; border: none; color: var(--primary); font-weight: 600; font-size: 12px; cursor: pointer; }
.notif-list { max-height: 360px; overflow-y: auto; }
.notif-item { display: flex; gap: 12px; padding: 12px 16px; border-bottom: 1px solid var(--bg); text-align: left; }
.notif-item.unread { background: var(--primary-light); }
.notif-item .material-icons-outlined { color: var(--primary); font-size: 22px; flex-shrink: 0; }
.notif-item p { font-size: 13px; color: var(--text); margin-bottom: 3px; }
.notif-time { font-size: 11px; color: var(--text-light); }
.notif-empty { text-align: center; padding: 40px 20px; color: var(--text-light); }
.notif-empty .material-icons-outlined { font-size: 44px; margin-bottom: 8px; }

/* Share menu (product detail) */
.pd-share-wrap { position: relative; }
.pd-share-menu {
    position: absolute; bottom: calc(100% + 8px); right: 0; width: 190px; background: #fff;
    border: 1px solid var(--border); border-radius: var(--radius-sm); box-shadow: var(--shadow-lg);
    opacity: 0; visibility: hidden; transform: translateY(6px); transition: all 0.2s; z-index: 20; overflow: hidden;
}
.pd-share-menu.open { opacity: 1; visibility: visible; transform: translateY(0); }
.pd-share-menu button, .pd-share-menu a {
    display: flex; align-items: center; gap: 10px; width: 100%; padding: 11px 14px;
    background: none; border: none; border-bottom: 1px solid var(--bg); font-size: 13px; font-weight: 500;
    color: var(--text); cursor: pointer; text-align: left;
}
.pd-share-menu button:last-child, .pd-share-menu a:last-child { border-bottom: none; }
.pd-share-menu button:hover, .pd-share-menu a:hover { background: var(--primary-light); color: var(--primary); }
.pd-share-menu .material-icons-outlined { font-size: 18px; color: var(--text-muted); }

/* Install App button (PWA) */
.install-btn {
    position: fixed; bottom: 88px; left: 24px; z-index: 350;
    display: inline-flex; align-items: center; gap: 8px;
    background: var(--dark); color: #fff; border: none; border-radius: 30px;
    padding: 12px 20px; font-weight: 600; font-size: 14px; cursor: pointer; box-shadow: var(--shadow-lg);
}
.install-btn:hover { background: var(--primary); }
.install-btn .material-icons-outlined { font-size: 20px; }

/* Floating side banners (stacked) */
.floating-banner {
    position: fixed; right: 16px; top: 50%; transform: translateY(-50%);
    z-index: 345; width: 172px; animation: slideIn 0.4s ease;
}
.floating-banner-items { display: flex; flex-direction: column; gap: 10px; max-height: 84vh; overflow-y: auto; padding-top: 6px; }
.fb-item { display: block; border-radius: 12px; overflow: hidden; background: #fff; box-shadow: 0 10px 28px rgba(0,0,0,0.26); transition: transform 0.2s; }
a.fb-item:hover { transform: scale(1.03); }
.fb-item img { width: 100%; height: auto; display: block; }
.floating-banner-close {
    position: absolute; top: -8px; right: -8px; z-index: 2;
    width: 26px; height: 26px; border-radius: 50%; border: 2px solid #fff; cursor: pointer;
    background: rgba(0,0,0,0.7); color: #fff; font-size: 17px; line-height: 1;
    display: flex; align-items: center; justify-content: center;
}
.floating-banner-close:hover { background: #000; }
@media (max-width: 700px) {
    .floating-banner { width: 108px; right: 8px; top: auto; bottom: 80px; transform: none; }
    .floating-banner-items { flex-direction: row; max-height: none; }
}

/* WhatsApp floating chat button */
/* Invoice modal */
.invoice-modal { max-width: 640px; padding: 0; }
.invoice-scroll { padding: 28px; max-height: 70vh; overflow-y: auto; }
.invoice-actions { display: flex; justify-content: flex-end; gap: 10px; padding: 16px 24px; border-top: 1px solid var(--border); }
.inv-head { display: flex; justify-content: space-between; gap: 20px; border-bottom: 2px solid var(--primary); padding-bottom: 16px; margin-bottom: 18px; }
.inv-logo { font-size: 20px; font-weight: 800; color: var(--primary); margin-bottom: 6px; }
.inv-title { text-align: right; }
.inv-title h1 { font-size: 24px; font-weight: 800; letter-spacing: 2px; margin-bottom: 4px; }
.inv-muted { color: var(--text-muted); font-size: 12px; line-height: 1.6; }
.inv-bill { font-size: 13px; line-height: 1.7; margin-bottom: 16px; }
.inv-table { width: 100%; border-collapse: collapse; margin-bottom: 16px; font-size: 13px; }
.inv-table th { background: var(--bg); text-align: left; padding: 10px; border-bottom: 2px solid var(--border); }
.inv-table td { padding: 10px; border-bottom: 1px solid var(--bg); }
.inv-table .r { text-align: right; } .inv-table .c { text-align: center; }
.inv-totals { margin-left: auto; width: 260px; font-size: 13px; }
.inv-totals > div { display: flex; justify-content: space-between; padding: 5px 0; color: var(--text-muted); }
.inv-grand { font-size: 17px; font-weight: 800; color: var(--dark); border-top: 2px solid var(--border); padding-top: 8px !important; margin-top: 4px; }
.inv-foot { text-align: center; margin-top: 24px; color: var(--text-muted); font-size: 13px; border-top: 1px solid var(--border); padding-top: 16px; }

/* Shop page with filters */
.shop-section { padding: 56px 0; background: var(--bg); }
.filter-toggle { display: none; align-items: center; gap: 6px; background: #fff; border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 9px 14px; font-weight: 600; font-size: 13px; cursor: pointer; color: var(--text); }
.shop-layout { display: grid; grid-template-columns: 250px 1fr; gap: 24px; align-items: start; }
.shop-filters { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 20px; position: sticky; top: 90px; }
.shop-filters-head { display: none; justify-content: space-between; align-items: center; margin-bottom: 12px; }
.shop-filters-head h3 { font-size: 18px; font-weight: 800; }
.close-filters { background: var(--bg); border: none; width: 34px; height: 34px; border-radius: 50%; cursor: pointer; }
.filter-group { padding: 14px 0; border-bottom: 1px solid var(--bg); }
.filter-group:first-of-type { padding-top: 0; }
.filter-group h4 { font-size: 12px; font-weight: 700; margin-bottom: 10px; text-transform: uppercase; letter-spacing: 0.5px; color: var(--text-muted); }
.filter-check { display: flex; align-items: center; gap: 8px; font-size: 13px; margin-bottom: 8px; cursor: pointer; }
.filter-check input { width: 16px; height: 16px; cursor: pointer; flex-shrink: 0; }
.price-inputs { display: flex; align-items: center; gap: 8px; }
.price-inputs input { width: 100%; padding: 8px 10px; border: 1px solid var(--border); border-radius: 6px; font-size: 13px; outline: none; }
.price-inputs input:focus { border-color: var(--primary); }
.rating-filter label { display: flex; align-items: center; gap: 8px; font-size: 13px; margin-bottom: 8px; cursor: pointer; }
.shop-toolbar { display: flex; justify-content: space-between; align-items: center; margin-bottom: 18px; gap: 12px; }
.shop-count { font-size: 14px; color: var(--text-muted); font-weight: 600; }
#shopGrid { grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); }
.filters-backdrop { display: none; position: fixed; inset: 0; background: rgba(15,23,42,0.5); z-index: 199; }
.filters-backdrop.open { display: block; }

@media (max-width: 900px) {
    .shop-layout { grid-template-columns: 1fr; }
    .filter-toggle { display: inline-flex; }
    .shop-filters {
        position: fixed; top: 0; left: 0; height: 100%; width: 300px; max-width: 85vw; z-index: 200;
        border-radius: 0; transform: translateX(-100%); transition: transform 0.25s; overflow-y: auto;
    }
    .shop-filters.open { transform: translateX(0); }
    .shop-filters-head { display: flex; }
}
@media (max-width: 640px) {
    .notif-panel { position: fixed; top: 12px; left: 12px; right: 12px; width: auto; max-width: none; }
}
@media (max-width: 480px) {
    #shopGrid { grid-template-columns: repeat(2, 1fr); }
    .install-btn { bottom: 16px; left: 16px; padding: 10px 16px; font-size: 13px; }
}

/* ---------- Google Sign-In ---------- */
/* Small multicolor "G" for the auth buttons (SVG data URI, works offline) */
.google-g-sm {
    width: 18px; height: 18px; display: inline-block; flex-shrink: 0;
    background-repeat: no-repeat; background-position: center; background-size: contain;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 48 48'%3E%3Cpath fill='%23EA4335' d='M24 9.5c3.54 0 6.71 1.22 9.21 3.6l6.85-6.85C35.9 2.38 30.47 0 24 0 14.62 0 6.51 5.38 2.56 13.22l7.98 6.19C12.43 13.72 17.74 9.5 24 9.5z'/%3E%3Cpath fill='%234285F4' d='M46.98 24.55c0-1.57-.15-3.09-.38-4.55H24v9.02h12.94c-.58 2.96-2.26 5.48-4.78 7.18l7.73 6c4.51-4.18 7.09-10.36 7.09-17.65z'/%3E%3Cpath fill='%23FBBC05' d='M10.53 28.59c-.48-1.45-.76-2.99-.76-4.59s.27-3.14.76-4.59l-7.98-6.19C.92 16.46 0 20.12 0 24c0 3.88.92 7.54 2.56 10.78l7.97-6.19z'/%3E%3Cpath fill='%2334A853' d='M24 48c6.48 0 11.93-2.13 15.89-5.81l-7.73-6c-2.15 1.45-4.92 2.3-8.16 2.3-6.26 0-11.57-4.22-13.47-9.91l-7.98 6.19C6.51 42.62 14.62 48 24 48z'/%3E%3C/svg%3E");
}

.google-modal { max-width: 400px; text-align: center; }
.google-head { margin-bottom: 20px; }
.google-g-lg { margin: 0 auto 12px; display: block; }
.google-head h2 { font-size: 22px; font-weight: 600; color: var(--dark); }
.google-head p { font-size: 14px; color: var(--text-muted); margin-top: 2px; }
.google-accounts { display: flex; flex-direction: column; border: 1px solid var(--border); border-radius: var(--radius-sm); overflow: hidden; }
.google-account {
    display: flex; align-items: center; gap: 14px; padding: 14px 18px;
    background: #fff; border: none; border-bottom: 1px solid var(--border);
    cursor: pointer; text-align: left; transition: background 0.15s; width: 100%;
}
.google-account:last-child { border-bottom: none; }
.google-account:hover { background: #f5f7fb; }
.google-avatar {
    width: 40px; height: 40px; border-radius: 50%; flex-shrink: 0;
    display: flex; align-items: center; justify-content: center;
    color: #fff; font-weight: 700; font-size: 18px;
}
.google-avatar.alt { background: var(--bg); color: var(--text-muted); }
.google-avatar.alt .material-icons-outlined { font-size: 22px; }
.google-account-info { display: flex; flex-direction: column; }
.google-account-info strong { font-size: 14px; font-weight: 600; color: var(--text); }
.google-account-info span { font-size: 13px; color: var(--text-muted); }
.google-form { text-align: left; margin-top: 6px; }
.google-form .form-group { margin-bottom: 14px; }
.google-form label { display: block; font-size: 13px; font-weight: 600; margin-bottom: 6px; }
.google-form input { width: 100%; padding: 12px 14px; border: 2px solid var(--border); border-radius: var(--radius-sm); font-size: 14px; outline: none; }
.google-form input:focus { border-color: var(--primary); }
.google-disclaimer { font-size: 12px; color: var(--text-light); margin-top: 16px; }

/* ---------- Toast ---------- */
.toast-container { position: fixed; bottom: 96px; right: 24px; z-index: 400; display: flex; flex-direction: column; gap: 12px; }
.toast {
    background: #fff; border-radius: var(--radius-sm); padding: 14px 18px;
    box-shadow: var(--shadow-lg); display: flex; align-items: center; gap: 12px;
    min-width: 280px; border-left: 4px solid var(--success);
    animation: slideIn 0.3s ease; font-size: 14px; font-weight: 500;
}
.toast.hide { animation: slideOut 0.3s ease forwards; }
.toast .material-icons-outlined { color: var(--success); font-size: 22px; }
.toast.error { border-left-color: var(--deal); }
.toast.error .material-icons-outlined { color: var(--deal); }
@keyframes slideIn { from { transform: translateX(120%); opacity: 0; } to { transform: translateX(0); opacity: 1; } }
@keyframes slideOut { to { transform: translateX(120%); opacity: 0; } }

/* ---------- Responsive ---------- */
@media (max-width: 1100px) {
    .products-grid { grid-template-columns: repeat(4, 1fr); }
    .categories-grid { grid-template-columns: repeat(5, 1fr); }
    .hero-content h2 { font-size: 40px; }
    .header-inner { gap: 20px; }
}

@media (max-width: 900px) {
    /* Header: search bar moves to its own full-width row (kept visible on mobile) */
    .header-inner { flex-wrap: wrap; gap: 12px 16px; }
    .logo { order: 1; }
    .header-actions { order: 2; margin-left: auto; }
    .search-bar { order: 3; flex-basis: 100%; max-width: none; }

    .hero-inner { grid-template-columns: 1fr; }
    .hero-image { display: none; }
    .hero-features { grid-template-columns: repeat(2, 1fr); }
    .deals-inner { grid-template-columns: 1fr; }
    .deals-visual { display: none; }
    .footer-grid { grid-template-columns: 1fr 1fr; }
    .why-us-grid { grid-template-columns: repeat(2, 1fr); }
    .products-grid { grid-template-columns: repeat(3, 1fr); }
    .nav-links { display: none; }
    .nav-inner { flex-wrap: wrap; gap: 10px; }
    .nav-auth { margin-left: auto; }
}

@media (max-width: 640px) {
    .top-bar-links { display: none; }
    .top-bar-inner { justify-content: center; }
    .header-actions { gap: 14px; }
    .header-action span:not(.material-icons-outlined):not(.badge) { display: none; }
    .search-bar select { display: none; }
    .products-grid { grid-template-columns: repeat(2, 1fr); }
    .categories-grid { grid-template-columns: repeat(3, 1fr); }
    .why-us-grid { grid-template-columns: 1fr; }
    .footer-grid { grid-template-columns: 1fr; }
    .hero-features { grid-template-columns: 1fr; }
    .hero-content h2 { font-size: 30px; }
    .hero-content p { font-size: 15px; }
    .section-header { flex-wrap: wrap; gap: 12px; }
    .section-header h2 { font-size: 22px; }
    .categories-btn { min-width: auto; width: 100%; }
    .categories-dropdown { flex: 1; }

    /* Featured tabs + sort stack neatly */
    .products-controls { width: 100%; flex-direction: column; align-items: stretch; }
    .product-tabs { flex-wrap: wrap; }
    .sort-select { width: 100%; }

    /* Deals countdown wraps instead of overflowing */
    .countdown { flex-wrap: wrap; gap: 10px; }
    .countdown-item { min-width: 62px; padding: 10px 12px; }
    .countdown-item .count { font-size: 24px; }
    .deals-content h2 { font-size: 30px; }

    /* Newsletter stacks */
    .newsletter-form { min-width: 0; }

    /* Toasts fit narrow screens */
    .toast-container { left: 12px; right: 12px; bottom: 88px; }
    .toast { min-width: 0; width: 100%; }

    /* List modals (wishlist / track / orders) */
    .list-row { flex-wrap: wrap; }
    .track-timeline { margin: 0 0 24px; }
    .payment-methods { flex-direction: column; align-items: flex-start; gap: 8px; }
}

@media (max-width: 400px) {
    .container { padding: 0 14px; }
    .header-inner { padding: 12px 14px; gap: 10px; }
    .logo-text h1 { font-size: 18px; }
    .logo-icon { width: 38px; height: 38px; }
    .hero { }
    .hero-content h2 { font-size: 25px; }
    .hero-inner { padding: 40px 20px 0; }
    .products-grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
    .product-name { font-size: 13px; min-height: 36px; }
    .product-image { height: 140px; }
    .categories-grid { grid-template-columns: repeat(2, 1fr); }
    .pd-info h2 { font-size: 20px; }
    .pd-price { font-size: 24px; }
    .modal { padding: 24px 18px; }
    .cart-sidebar { width: 100%; }
}

/* =========================================================
   AI CHAT ASSISTANT
   ========================================================= */
.chat-fab {
    position: fixed; bottom: 24px; right: 24px; z-index: 360;
    width: 60px; height: 60px; border-radius: 50%; border: none; cursor: pointer;
    background: var(--primary); color: #fff;
    display: flex; align-items: center; justify-content: center;
    box-shadow: 0 8px 24px rgba(26,86,219,0.45);
    transition: transform 0.2s, background 0.2s;
}
.chat-fab:hover { transform: scale(1.07); background: var(--primary-dark); }
.chat-fab .material-icons-outlined { font-size: 28px; }
.chat-fab .chat-fab-close { display: none; }
.chat-fab.open .chat-fab-open { display: none; }
.chat-fab.open .chat-fab-close { display: block; }
.chat-fab-dot {
    position: absolute; top: 8px; right: 8px; width: 12px; height: 12px;
    border-radius: 50%; background: #ef4444; border: 2px solid #fff;
}

/* `display: flex` below would otherwise beat the plain [hidden] attribute,
   leaving the panel permanently on screen. */
.chat-panel[hidden] { display: none; }
.chat-fab-dot[hidden] { display: none; }

.chat-panel {
    position: fixed; bottom: 96px; right: 24px; z-index: 360;
    width: 380px; max-width: calc(100vw - 32px);
    height: 540px; max-height: calc(100vh - 140px);
    background: #fff; border-radius: 18px; overflow: hidden;
    box-shadow: 0 18px 50px rgba(15,23,42,0.22);
    display: flex; flex-direction: column;
    animation: chatIn 0.22s ease;
}
@keyframes chatIn { from { opacity: 0; transform: translateY(14px) scale(0.98); } to { opacity: 1; transform: none; } }

.chat-head { display: flex; align-items: center; gap: 12px; padding: 16px 18px; background: var(--primary); color: #fff; }
.chat-avatar { width: 40px; height: 40px; border-radius: 50%; background: rgba(255,255,255,0.2); display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.chat-head-text { flex: 1; min-width: 0; }
.chat-head-text strong { display: block; font-size: 15px; }
.chat-head-text small { font-size: 12px; opacity: 0.9; display: flex; align-items: center; gap: 6px; }
.chat-dot { width: 8px; height: 8px; border-radius: 50%; background: #4ade80; display: inline-block; }
.chat-close { background: none; border: none; color: #fff; cursor: pointer; padding: 4px; display: flex; opacity: 0.85; }
.chat-close:hover { opacity: 1; }

.chat-log { flex: 1; overflow-y: auto; padding: 18px; display: flex; flex-direction: column; gap: 12px; background: #f8fafc; }
.chat-msg { max-width: 84%; padding: 11px 15px; font-size: 14px; line-height: 1.6; border-radius: 16px; white-space: pre-wrap; word-break: break-word; }
.chat-msg.bot { align-self: flex-start; background: #fff; color: var(--text); border-bottom-left-radius: 4px; box-shadow: 0 1px 3px rgba(15,23,42,0.08); }
.chat-msg.me { align-self: flex-end; background: var(--primary); color: #fff; border-bottom-right-radius: 4px; }
.chat-msg.error { background: #fef2f2; color: #b91c1c; }

.chat-typing { align-self: flex-start; display: flex; gap: 4px; padding: 14px 16px; background: #fff; border-radius: 16px; border-bottom-left-radius: 4px; box-shadow: 0 1px 3px rgba(15,23,42,0.08); }
.chat-typing i { width: 7px; height: 7px; border-radius: 50%; background: #94a3b8; animation: chatBlink 1.3s infinite; }
.chat-typing i:nth-child(2) { animation-delay: 0.18s; }
.chat-typing i:nth-child(3) { animation-delay: 0.36s; }
@keyframes chatBlink { 0%, 60%, 100% { opacity: 0.3; } 30% { opacity: 1; } }

/* Product card the agent offers, with a one-tap add to cart */
.chat-product { align-self: flex-start; width: 84%; background: #fff; border: 1px solid var(--border); border-radius: 14px; padding: 12px 14px; box-shadow: 0 1px 3px rgba(15,23,42,0.08); }
.chat-product-name { font-size: 13px; font-weight: 700; color: var(--dark); margin-bottom: 4px; }
.chat-product-meta { font-size: 13px; color: var(--primary); font-weight: 700; margin-bottom: 10px; }
.chat-product-meta span { color: var(--text-muted); font-weight: 500; font-size: 12px; }
.chat-product button { width: 100%; padding: 9px; border: none; border-radius: 8px; background: var(--primary); color: #fff; font-weight: 600; font-size: 13px; cursor: pointer; display: flex; align-items: center; justify-content: center; gap: 6px; }
.chat-product button:hover { background: var(--primary-dark); }
.chat-product button:disabled { background: #cbd5e1; cursor: not-allowed; }
.chat-product button .material-icons-outlined { font-size: 17px; }

.chat-quick { display: flex; gap: 8px; padding: 10px 14px 0; flex-wrap: wrap; }
.chat-quick button { background: #eef2ff; border: 1px solid #dbe3ff; color: var(--primary); font-size: 12px; font-weight: 600; padding: 7px 12px; border-radius: 20px; cursor: pointer; }
.chat-quick button:hover { background: var(--primary); color: #fff; border-color: var(--primary); }
.chat-quick:empty { display: none; }

.chat-form { display: flex; gap: 8px; padding: 14px; border-top: 1px solid var(--border); background: #fff; }
.chat-form input { flex: 1; padding: 11px 15px; border: 1px solid var(--border); border-radius: 24px; font-family: inherit; font-size: 14px; outline: none; }
.chat-form input:focus { border-color: var(--primary); }
.chat-form button { width: 42px; height: 42px; border-radius: 50%; border: none; background: var(--primary); color: #fff; cursor: pointer; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.chat-form button:hover { background: var(--primary-dark); }

@media (max-width: 520px) {
    .chat-panel { right: 12px; left: 12px; width: auto; bottom: 88px; height: calc(100vh - 120px); }
    .chat-fab { bottom: 16px; right: 16px; width: 54px; height: 54px; }
}
/* A reply typed by the shop owner, not the agent */
.chat-msg.bot.from-shop { background: #ecfdf5; border-left: 3px solid var(--green); }

/* "Goes with" — the parts a buyer of this product needs alongside it */
.pd-goes-with { margin: 18px 0 6px; padding: 14px; border-radius: 12px; background: var(--bg-secondary, #f8fafc); border: 1px dashed var(--border, #e2e8f0); }
.pd-goes-with h4 { margin: 0 0 10px; font-size: 0.95rem; }
.pd-goes-grid { display: grid; gap: 10px; }
.pd-goes-card { display: grid; grid-template-columns: 48px 1fr auto; align-items: center; gap: 10px; }
.pd-goes-img { width: 48px; height: 48px; border-radius: 8px; background: #fff; display: flex; align-items: center; justify-content: center; overflow: hidden; cursor: pointer; }
.pd-goes-img img { width: 100%; height: 100%; object-fit: contain; }
.pd-goes-info h5 { margin: 0; font-size: 0.85rem; font-weight: 600; cursor: pointer; }
.pd-goes-info span { font-size: 0.8rem; color: var(--text-muted, #64748b); }
.pd-goes-add { padding: 6px 12px; font-size: 0.8rem; white-space: nowrap; }
