:root {
    --primary-red: #e11d48;
    --dark-bg: #0b0f1a;
    --light-bg: #f8fafc;
    --sidebar-bg: #0a0f1e;

    /* Your Custom Light Mode Colors */
    --light-mode-bg: #FFFFFF;
    --light-mode-primary: #E91E63;
    --light-mode-secondary: #F8F9FA;
    --light-mode-text: #212529;
}

/* ============================================================
   LIGHT MODE — Complete Polished Theme
   ============================================================ */

/* Core Reset */
.light-mode {
    background-color: var(--light-mode-bg) !important;
    color: var(--light-mode-text) !important;
}

/* --- Core Backgrounds --- */
.light-mode body,
.light-mode .bg-slate-900,
.light-mode .bg-slate-950,
.light-mode .bg-\[\#0a0a0a\],
.light-mode .bg-\[\#050505\],
.light-mode .bg-\[\#0d1526\]\/80 {
    background-color: var(--light-mode-bg) !important;
}

/* Sidebar */
.light-mode aside {
    background-color: #f1f3f5 !important;
    border-right: 1px solid #dee2e6 !important;
    box-shadow: 2px 0 12px rgba(0, 0, 0, 0.06) !important;
}

/* Sidebar items */
.light-mode .sidebar-item {
    color: #495057 !important;
}

.light-mode .sidebar-item i {
    color: #495057 !important;
}

.light-mode .sidebar-item:hover i,
.light-mode .sidebar-item.active i {
    color: var(--light-mode-primary) !important;
}

.light-mode .sidebar-tooltip {
    background-color: #212529 !important;
    color: #ffffff !important;
    border-color: #343a40 !important;
}

/* Header */
.light-mode .glass-header,
.light-mode header {
    background-color: #ffffff !important;
    border-bottom: 1px solid #dee2e6 !important;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.07) !important;
    backdrop-filter: none !important;
}

/* Category Drawer */
.light-mode #categoryDrawer {
    background-color: #ffffff !important;
    border-right: 1px solid #dee2e6 !important;
    box-shadow: 6px 0 24px rgba(0, 0, 0, 0.08) !important;
}

.light-mode #categoryDrawer .bg-slate-950 {
    background-color: #f8f9fa !important;
}

.light-mode #categoryDrawer .border-slate-800 {
    border-color: #dee2e6 !important;
}

.light-mode #categoryDrawer .hover\:bg-slate-800:hover {
    background-color: #f1f3f5 !important;
}

.light-mode #categoryDrawer .bg-\[\#0a0a0a\] {
    background-color: #f8f9fa !important;
}

/* AI Drawer */
.light-mode #aiDrawer {
    background-color: #ffffff !important;
    border-left: 1px solid #dee2e6 !important;
}

.light-mode #aiDrawer .bg-slate-900 {
    background-color: #f8f9fa !important;
}

.light-mode #aiDrawer .bg-slate-800 {
    background-color: #e9ecef !important;
}

.light-mode #chatMessages .bg-slate-800 {
    background-color: #e9ecef !important;
    border-color: #dee2e6 !important;
    color: #212529 !important;
}

.light-mode #aiInput {
    background-color: #f1f3f5 !important;
    border-color: #ced4da !important;
    color: #212529 !important;
}

/* Cards & Panels */
.light-mode .bg-slate-800\/40,
.light-mode .bg-slate-800\/50 {
    background-color: #f8f9fa !important;
    border-color: #dee2e6 !important;
}

.light-mode .bg-slate-800 {
    background-color: #f1f3f5 !important;
}

/* Product card — red top stripe accent */
.light-mode .product-card {
    border-color: #dee2e6 !important;
    background-color: #ffffff !important;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    border-top: 3px solid #E91E63 !important;
}

/* Product card hover — stronger red glow + border flush */
.light-mode .product-card:hover {
    box-shadow: 0 20px 40px rgba(233, 30, 99, 0.20), 0 4px 16px rgba(233, 30, 99, 0.10) !important;
    border-color: rgba(233, 30, 99, 0.45) !important;
    border-top-color: #E91E63 !important;
}

/* Product card image area */
.light-mode .bg-slate-900.rounded-xl {
    background-color: #f8f0f3 !important;
}

/* Product card bottom divider — red tinted */
.light-mode .product-card .border-t {
    border-color: rgba(233, 30, 99, 0.15) !important;
}

/* Store label — red icon + light red pill background */
.light-mode .product-card .fa-store {
    color: #E91E63 !important;
}

/* Like button — always visible, red-tinted border */
.light-mode .product-card .md\:opacity-0 {
    opacity: 1 !important;
    background-color: rgba(255, 255, 255, 0.95) !important;
    border-color: rgba(233, 30, 99, 0.25) !important;
}

.light-mode .product-card .md\:opacity-0 .fa-heart {
    color: #E91E63 !important;
    opacity: 0.4;
}

/* Like button hover */
.light-mode .product-card .md\:opacity-0:hover {
    background-color: #E91E63 !important;
    border-color: #E91E63 !important;
}

.light-mode .product-card .md\:opacity-0:hover .fa-heart {
    color: #ffffff !important;
    opacity: 1;
}

/* Text Colors */
.light-mode .text-white {
    color: #212529 !important;
}

/* Product name fix — slate-100 is near-white, invisible on white cards */
.light-mode .text-slate-100 {
    color: #1a1d23 !important;
}

.light-mode .text-slate-200 {
    color: #343a40 !important;
}

.light-mode .text-slate-300 {
    color: #495057 !important;
}

.light-mode .text-slate-400 {
    color: #6c757d !important;
}

.light-mode .text-slate-500 {
    color: #868e96 !important;
}

.light-mode .text-slate-600 {
    color: #868e96 !important;
}

/* Primary Action Color */
.light-mode .text-rose-600,
.light-mode .text-rose-500 {
    color: var(--light-mode-primary) !important;
}

/* Primary Buttons */
.light-mode .bg-rose-600 {
    background-color: var(--light-mode-primary) !important;
    color: #ffffff !important;
}

.light-mode .hover\:bg-rose-700:hover {
    background-color: #c2185b !important;
}

/* Borders */
.light-mode .border-slate-800,
.light-mode .border-slate-700 {
    border-color: #dee2e6 !important;
}

.light-mode .border-slate-800\/50,
.light-mode .border-slate-700\/50 {
    border-color: rgba(222, 226, 230, 0.7) !important;
}

/* Inputs and Selects */
.light-mode input[type="text"],
.light-mode input[type="email"],
.light-mode select,
.light-mode textarea {
    background-color: #f8f9fa !important;
    border-color: #ced4da !important;
    color: #212529 !important;
}

.light-mode input::placeholder,
.light-mode textarea::placeholder {
    color: #adb5bd !important;
}

.light-mode input:focus,
.light-mode textarea:focus,
.light-mode select:focus {
    border-color: var(--light-mode-primary) !important;
    box-shadow: 0 0 0 3px rgba(233, 30, 99, 0.12) !important;
}

/* FAQ / Common Questions cards */
.light-mode .bg-slate-800\/50.border.border-slate-700.p-6.rounded-2xl {
    background-color: #f8f9fa !important;
    border-color: #dee2e6 !important;
}

.light-mode .hover\:border-rose-500:hover {
    border-color: var(--light-mode-primary) !important;
}

/* Section divider gradients */
.light-mode .bg-gradient-to-b,
.light-mode .bg-gradient-to-r {
    opacity: 0.4;
}

/* Footer overrides */
.light-mode footer {
    background-color: #f1f3f5 !important;
    border-top: 1px solid #dee2e6 !important;
    color: #6c757d !important;
}

.light-mode footer .text-slate-400,
.light-mode footer .text-slate-500,
.light-mode footer .text-slate-600 {
    color: #6c757d !important;
}

.light-mode footer .text-white {
    color: #212529 !important;
}

.light-mode footer .bg-slate-900 {
    background-color: #e9ecef !important;
}

.light-mode footer .border-slate-800,
.light-mode footer .border-slate-900 {
    border-color: #dee2e6 !important;
}

.light-mode footer input[type="email"] {
    background-color: #ffffff !important;
}

/* Nav links */
.light-mode .nav-link {
    color: #495057 !important;
}

.light-mode .nav-link:hover,
.light-mode .nav-link.text-rose-600 {
    color: var(--light-mode-primary) !important;
}

/* Search bar in header */
.light-mode #globalSearchInput {
    background-color: #f1f3f5 !important;
    border-color: #ced4da !important;
    color: #212529 !important;
}

/* Hero sections — keep semi-transparent overlay readable */
.light-mode section .absolute.inset-0.bg-gradient-to-b {
    opacity: 1;
}

/* Company page DNA image card container */
.light-mode .border-slate-800.bg-slate-950 {
    background-color: #f8f9fa !important;
    border-color: #dee2e6 !important;
}

/* Hero sections in light mode — lighten overlay so text stays readable */
.light-mode section.relative.py-32,
.light-mode section.relative.py-28,
.light-mode section.relative.py-24 {
    background-color: #f8f9fa !important;
}

/* ============================================================
   DEPARTMENT CARDS — Per-card colored light mode
   ============================================================ */

/* Shared base: keep image visible, restore natural look */
.light-mode .grid .group.relative[onclick] {
    background-color: #ffffff !important;
    border-color: #e2e8f0 !important;
    box-shadow: 0 4px 20px rgba(0,0,0,0.06) !important;
}

/* Make background image more visible in light mode */
.light-mode .grid .group.relative[onclick] > div:first-child {
    opacity: 0.35 !important;
}
.light-mode .grid .group.relative[onclick]:hover > div:first-child {
    opacity: 0.55 !important;
}

/* ---- CARD 1: Maker Tech — Rose/Red ---- */
.light-mode .grid .group.relative[onclick]:nth-child(1) {
    background: linear-gradient(135deg, #fff0f3 0%, #ffe4ec 100%) !important;
    border-color: rgba(225, 29, 72, 0.25) !important;
}
.light-mode .grid .group.relative[onclick]:nth-child(1) > .bg-gradient-to-t {
    background: linear-gradient(to top, rgba(255,228,236,0.97) 0%, rgba(255,228,236,0.5) 55%, transparent 100%) !important;
}
.light-mode .grid .group.relative[onclick]:nth-child(1):hover {
    border-color: rgba(225, 29, 72, 0.6) !important;
    box-shadow: 0 12px 40px rgba(225,29,72,0.18), 0 4px 16px rgba(225,29,72,0.10) !important;
}
.light-mode .grid .group.relative[onclick]:nth-child(1) h4 { color: #9f1239 !important; }
.light-mode .grid .group.relative[onclick]:nth-child(1) p  { color: #be185d !important; opacity: 0.75; }
.light-mode .grid .group.relative[onclick]:nth-child(1) h4:hover { color: #e11d48 !important; }

/* ---- CARD 2: IT & Computing — Blue ---- */
.light-mode .grid .group.relative[onclick]:nth-child(2) {
    background: linear-gradient(135deg, #eff6ff 0%, #dbeafe 100%) !important;
    border-color: rgba(37, 99, 235, 0.25) !important;
}
.light-mode .grid .group.relative[onclick]:nth-child(2) > .bg-gradient-to-t {
    background: linear-gradient(to top, rgba(219,234,254,0.97) 0%, rgba(219,234,254,0.5) 55%, transparent 100%) !important;
}
.light-mode .grid .group.relative[onclick]:nth-child(2):hover {
    border-color: rgba(37, 99, 235, 0.55) !important;
    box-shadow: 0 12px 40px rgba(37,99,235,0.15), 0 4px 16px rgba(37,99,235,0.08) !important;
}
.light-mode .grid .group.relative[onclick]:nth-child(2) h4 { color: #1e40af !important; }
.light-mode .grid .group.relative[onclick]:nth-child(2) p  { color: #2563eb !important; opacity: 0.75; }

/* ---- CARD 3: Local Stores — Amber/Orange ---- */
.light-mode .grid .group.relative[onclick]:nth-child(3) {
    background: linear-gradient(135deg, #fffbeb 0%, #fef3c7 100%) !important;
    border-color: rgba(217, 119, 6, 0.25) !important;
}
.light-mode .grid .group.relative[onclick]:nth-child(3) > .bg-gradient-to-t {
    background: linear-gradient(to top, rgba(254,243,199,0.97) 0%, rgba(254,243,199,0.5) 55%, transparent 100%) !important;
}
.light-mode .grid .group.relative[onclick]:nth-child(3):hover {
    border-color: rgba(217, 119, 6, 0.55) !important;
    box-shadow: 0 12px 40px rgba(217,119,6,0.15), 0 4px 16px rgba(217,119,6,0.08) !important;
}
.light-mode .grid .group.relative[onclick]:nth-child(3) h4 { color: #92400e !important; }
.light-mode .grid .group.relative[onclick]:nth-child(3) p  { color: #b45309 !important; opacity: 0.75; }

/* ---- CARD 4: My Projects — Emerald/Green ---- */
.light-mode .grid .group.relative[onclick]:nth-child(4) {
    background: linear-gradient(135deg, #ecfdf5 0%, #d1fae5 100%) !important;
    border-color: rgba(5, 150, 105, 0.25) !important;
}
.light-mode .grid .group.relative[onclick]:nth-child(4) > .bg-gradient-to-t {
    background: linear-gradient(to top, rgba(209,250,229,0.97) 0%, rgba(209,250,229,0.5) 55%, transparent 100%) !important;
}
.light-mode .grid .group.relative[onclick]:nth-child(4):hover {
    border-color: rgba(5, 150, 105, 0.55) !important;
    box-shadow: 0 12px 40px rgba(5,150,105,0.15), 0 4px 16px rgba(5,150,105,0.08) !important;
}
.light-mode .grid .group.relative[onclick]:nth-child(4) h4 { color: #065f46 !important; }
.light-mode .grid .group.relative[onclick]:nth-child(4) p  { color: #059669 !important; opacity: 0.75; }

/* End of department card rules */

/* Gradient text clip — override for light mode */
.light-mode .bg-gradient-to-r.from-rose-600.to-rose-400.bg-clip-text {
    -webkit-text-fill-color: var(--light-mode-primary) !important;
    background: none !important;
}

/* Left border accent on text blocks */
.light-mode .border-l-2.border-rose-600\/20 {
    border-color: rgba(233, 30, 99, 0.25) !important;
}

/* "Our DNA" label pill */
.light-mode .bg-rose-600\/10 {
    background-color: rgba(233, 30, 99, 0.08) !important;
}

.light-mode .border-rose-600\/30 {
    border-color: rgba(233, 30, 99, 0.3) !important;
}

/* Support section hero text */
.light-mode .text-rose-500.font-bold.tracking-widest {
    color: var(--light-mode-primary) !important;
}

/* The horizontal rose line divider */
.light-mode .h-0\.5.flex-1.bg-rose-600 {
    background-color: var(--light-mode-primary) !important;
    opacity: 0.4;
}

/* Blue accent gradient blobs — hide in light mode */
.light-mode .bg-rose-600\/10.blur-\[120px\],
.light-mode .bg-blue-600\/5.blur-\[100px\] {
    opacity: 0 !important;
}

/* The thin top section divider line */
.light-mode .bg-gradient-to-r.from-transparent.via-rose-600.to-transparent {
    opacity: 0.3 !important;
}

/* Mag-scroll scrollbar in light mode */
.light-mode .mag-scroll {
    scrollbar-color: #E91E63 #f1f3f5;
}

.light-mode .mag-scroll::-webkit-scrollbar-track {
    background: rgba(241, 243, 245, 0.9);
}

.light-mode .mag-scroll::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, #E91E63 0%, #c2185b 100%);
    border-color: #f1f3f5;
}

/* Tab buttons in catalog drawer */
.light-mode #tab-electronics,
.light-mode #tab-pcparts {
    background-color: transparent !important;
}

.light-mode #tab-electronics.text-slate-500,
.light-mode #tab-pcparts.text-slate-500 {
    color: #868e96 !important;
}

/* Back-to-top keeps its red style in light mode — intentionally no override */

/* Light mode logo sizing — matches dark mode logo exactly (no padding correction needed) */
.light-mode img[alt="Magneto Logo"] {
    height: 40px !important;
    width: auto !important;
}

/* ============================================================
   STORES PAGE — Light Mode Overrides
   ============================================================ */

/* Search input */
.light-mode #storeSearchInput {
    background-color: #f8f9fa !important;
    border-color: #ced4da !important;
    color: #212529 !important;
}

.light-mode #storeSearchInput::placeholder {
    color: #adb5bd !important;
}

/* Store list container */
.light-mode #store-list {
    background-color: #f8f9fa !important;
}

/* Store cards inside the list (injected by JS) */
.light-mode #store-list .bg-slate-800,
.light-mode #store-list .bg-slate-800\/40,
.light-mode #store-list .bg-slate-900 {
    background-color: #ffffff !important;
    border-color: #dee2e6 !important;
    color: #212529 !important;
}

.light-mode #store-list .text-white,
.light-mode #store-list .text-slate-200 {
    color: #212529 !important;
}

.light-mode #store-list .text-slate-400 {
    color: #6c757d !important;
}

.light-mode #store-list .border-slate-700 {
    border-color: #dee2e6 !important;
}

/* Map layer toggle control */
.light-mode .custom-map-control {
    background: #ffffff !important;
    border-color: #dee2e6 !important;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.10) !important;
}

.light-mode .map-toggle-btn {
    color: #6c757d !important;
}

.light-mode .map-toggle-btn:not(.active):hover {
    background: #f1f3f5 !important;
    color: #212529 !important;
}

/* Leaflet popup — light mode overrides inline styles */
.light-mode .leaflet-popup-content-wrapper {
    background: #ffffff !important;
    color: #212529 !important;
    border: 1px solid #dee2e6 !important;
}

.light-mode .leaflet-popup-tip {
    background: #ffffff !important;
}

.light-mode .leaflet-popup-close-button {
    color: #6c757d !important;
}

/* Leaflet routing panel */
.light-mode .leaflet-routing-container {
    background-color: #ffffff !important;
    color: #212529 !important;
    border-color: #dee2e6 !important;
}

.light-mode .leaflet-routing-alt {
    background-color: #f8f9fa !important;
    border-bottom-color: #dee2e6 !important;
}

.light-mode .leaflet-routing-alt:hover {
    background-color: #f1f3f5 !important;
}

/* ============================================================
   PARTNER CARDS — Image Cards (all pages)
   Keep them dark with visible images like dark mode
   ============================================================ */

/* Partner store image cards on partners.html */
.light-mode .bg-slate-800\/40.border.border-slate-700.rounded-3xl {
    background-color: #111827 !important;
    border-color: rgba(255, 255, 255, 0.08) !important;
}

.light-mode .bg-slate-800\/40.border.border-slate-700.rounded-3xl h3 {
    color: #ffffff !important;
}

.light-mode .bg-slate-800\/40.border.border-slate-700.rounded-3xl p {
    color: rgba(148, 163, 184, 0.9) !important;
}

/* Gradient overlays on partner image cards — keep them visible */
.light-mode .bg-slate-800\/40.border.border-slate-700.rounded-3xl .absolute.inset-0.bg-gradient-to-t {
    opacity: 0.65 !important;
}

/* Icon badges on partner cards */
.light-mode .bg-slate-800\/40 .bg-slate-900.border.border-slate-700.rounded-xl {
    background-color: #1e293b !important;
    border-color: rgba(255, 255, 255, 0.08) !important;
}

/* Hero section text in light mode on store/partner/liked pages */
.light-mode section.relative.py-32 h1,
.light-mode section.relative.py-28 h1 {
    color: #ffffff !important;
}

.light-mode section.relative.py-32 p,
.light-mode section.relative.py-28 p {
    color: rgba(203, 213, 225, 0.9) !important;
}



.glass-header {
    backdrop-filter: blur(10px);
    background: rgba(15, 23, 42, 0.95);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.red-gradient {
    background: linear-gradient(135deg, #e11d48 0%, #9f1239 100%);
}

.no-scrollbar::-webkit-scrollbar {
    display: none;
}

.no-scrollbar {
    -ms-overflow-style: none;
    scrollbar-width: none;
}

.product-card {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.product-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 25px -5px rgba(225, 29, 72, 0.15);
}

.sidebar-item {
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    padding: 18px 0;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    color: #cbd5e1;
}

.sidebar-item:hover {
    color: white;
}

.sidebar-item i {
    transition: all 0.3s ease;
}

.sidebar-item:hover i {
    transform: scale(1.1);
}

.sidebar-item.active i {
    color: var(--primary-red);
}

.sidebar-tooltip {
    position: absolute;
    left: 100%;
    top: 50%;
    transform: translateY(-50%) translateX(15px);
    background-color: #0f172a;
    border: 1px solid #1e293b;
    color: white;
    padding: 8px 14px;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 600;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    box-shadow: 10px 0 15px rgba(0, 0, 0, 0.5);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 100;
}

.sidebar-tooltip::before {
    content: '';
    position: absolute;
    top: 50%;
    right: 100%;
    transform: translateY(-50%);
    border-width: 6px;
    border-style: solid;
    border-color: transparent #0f172a transparent transparent;
}

.sidebar-item:hover .sidebar-tooltip {
    opacity: 1;
    visibility: visible;
    transform: translateY(-50%) translateX(0);
}

/* Ensure consistent dark theme backgrounds for drawers */
#categoryDrawer,
#aiDrawer {
    background: var(--dark-bg);
    border-color: rgba(255, 255, 255, 0.05);
}

#aiDrawer .bg-slate-900 {
    background: #0f172a;
}

/* --- Filter Sidebar & Custom Checkboxes --- */
.filter-sidebar {
    background: #020617;
    /* Very dark blue */
}

.custom-checkbox {
    appearance: none;
    -webkit-appearance: none;
    width: 18px;
    height: 18px;
    background: #1e293b;
    border: 1px solid #475569;
    border-radius: 4px;
    cursor: pointer;
    position: relative;
    transition: all 0.2s ease;
}

.custom-checkbox:checked {
    background: #e11d48;
    border-color: #e11d48;
}

.custom-checkbox:checked::after {
    content: '\f00c';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: white;
    font-size: 10px;
}

.price-input {
    background: #1e293b;
    border: 1px solid #334155;
    padding: 6px 10px;
    border-radius: 6px;
    color: white;
    font-size: 13px;
    width: 100%;
    outline: none;
    transition: border-color 0.2s;
}

.price-input:focus {
    border-color: #e11d48;
}


/* Ensure no-scrollbar doesn't override custom-scrollbar when added together */
.no-scrollbar::-webkit-scrollbar {
    display: none;
}

.no-scrollbar {
    -ms-overflow-style: none;
    scrollbar-width: none;
}

/* ============================================================
   MAGNETO BRANDED SCROLLBAR — Rose-Red Theme
   Apply .mag-scroll to any scrollable container
   ============================================================ */

/* Global page scrollbar */
html {
    scrollbar-width: thin;
    scrollbar-color: #e11d48 #0a0a14;
}

html::-webkit-scrollbar {
    width: 7px;
}

html::-webkit-scrollbar-track {
    background: #0a0a14;
    border-left: 1px solid rgba(225, 29, 72, 0.08);
}

html::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, #e11d48 0%, #9f1239 100%);
    border-radius: 100px;
    border: 2px solid #0a0a14;
    box-shadow: 0 0 6px rgba(225, 29, 72, 0.4);
    transition: background 0.3s ease, box-shadow 0.3s ease;
}

html::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(180deg, #f43f5e 0%, #e11d48 100%);
    box-shadow: 0 0 10px rgba(225, 29, 72, 0.7);
}

html::-webkit-scrollbar-thumb:active {
    background: linear-gradient(180deg, #be123c 0%, #7f0f2e 100%);
}

/* Utility class for inner scrollable containers */
.mag-scroll {
    scrollbar-width: thin;
    scrollbar-color: #e11d48 #0a0a14;
}

.mag-scroll::-webkit-scrollbar {
    width: 5px;
}

.mag-scroll::-webkit-scrollbar-track {
    background: rgba(10, 10, 20, 0.8);
    border-radius: 100px;
}

.mag-scroll::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, #e11d48 0%, #9f1239 100%);
    border-radius: 100px;
    box-shadow: 0 0 5px rgba(225, 29, 72, 0.35);
    transition: background 0.3s ease;
}

.mag-scroll::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(180deg, #f43f5e 0%, #e11d48 100%);
    box-shadow: 0 0 8px rgba(225, 29, 72, 0.6);
}

.mag-scroll::-webkit-scrollbar-thumb:active {
    background: #be123c;
}

/* ============================================================
   PARTNER STORE CARDS — Premium Effects
   ============================================================ */

/* Base card lift + transition */
.partner-card {
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1),
                box-shadow 0.4s cubic-bezier(0.4, 0, 0.2, 1),
                border-color 0.3s ease !important;
    position: relative;
}

.partner-card:hover {
    transform: translateY(-10px) !important;
}

/* Shimmer sweep pseudo-element */
.partner-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 60%;
    height: 100%;
    background: linear-gradient(
        105deg,
        transparent 30%,
        rgba(255, 255, 255, 0.06) 50%,
        transparent 70%
    );
    transition: left 0.6s ease;
    z-index: 10;
    pointer-events: none;
    border-radius: inherit;
}

.partner-card:hover::before {
    left: 160%;
}

/* ---- DZDUINO — Rose/Red glow ---- */
.partner-card-rose:hover {
    box-shadow:
        0 20px 60px rgba(225, 29, 72, 0.35),
        0 0 0 1px rgba(225, 29, 72, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.06) !important;
}

.partner-card-rose .partner-icon {
    transition: background 0.3s ease, box-shadow 0.3s ease, transform 0.3s ease;
}
.partner-card-rose:hover .partner-icon {
    background-color: rgba(225, 29, 72, 0.15) !important;
    box-shadow: 0 0 18px rgba(225, 29, 72, 0.5) !important;
    transform: rotate(15deg) scale(1.15);
}

.partner-card-rose .partner-btn {
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
}
.partner-card-rose .partner-btn::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.15), transparent);
    transform: translateX(-100%);
    transition: transform 0.5s ease;
}
.partner-card-rose:hover .partner-btn::after {
    transform: translateX(100%);
}
.partner-card-rose:hover .partner-btn {
    box-shadow: 0 8px 25px rgba(225, 29, 72, 0.5) !important;
    letter-spacing: 0.12em;
}

/* ---- WiFi Djelfa — Blue glow ---- */
.partner-card-blue:hover {
    box-shadow:
        0 20px 60px rgba(37, 99, 235, 0.35),
        0 0 0 1px rgba(37, 99, 235, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.06) !important;
}

.partner-card-blue .partner-icon {
    transition: background 0.3s ease, box-shadow 0.3s ease, transform 0.3s ease;
}
.partner-card-blue:hover .partner-icon {
    background-color: rgba(37, 99, 235, 0.15) !important;
    box-shadow: 0 0 18px rgba(37, 99, 235, 0.5) !important;
    transform: rotate(15deg) scale(1.15);
}

.partner-card-blue .partner-btn {
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
}
.partner-card-blue .partner-btn::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.15), transparent);
    transform: translateX(-100%);
    transition: transform 0.5s ease;
}
.partner-card-blue:hover .partner-btn::after {
    transform: translateX(100%);
}
.partner-card-blue:hover .partner-btn {
    box-shadow: 0 8px 25px rgba(37, 99, 235, 0.5) !important;
    letter-spacing: 0.12em;
}

/* ---- Khabir Tech — Amber glow ---- */
.partner-card-amber:hover {
    box-shadow:
        0 20px 60px rgba(217, 119, 6, 0.35),
        0 0 0 1px rgba(217, 119, 6, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.06) !important;
}

.partner-card-amber .partner-icon {
    transition: background 0.3s ease, box-shadow 0.3s ease, transform 0.3s ease;
}
.partner-card-amber:hover .partner-icon {
    background-color: rgba(217, 119, 6, 0.15) !important;
    box-shadow: 0 0 18px rgba(217, 119, 6, 0.5) !important;
    transform: rotate(15deg) scale(1.15);
}

.partner-card-amber .partner-btn {
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
}
.partner-card-amber .partner-btn::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.15), transparent);
    transform: translateX(-100%);
    transition: transform 0.5s ease;
}
.partner-card-amber:hover .partner-btn::after {
    transform: translateX(100%);
}
.partner-card-amber:hover .partner-btn {
    box-shadow: 0 8px 25px rgba(217, 119, 6, 0.5) !important;
    letter-spacing: 0.12em;
}

/* ============================================================
   FOOTER SOCIAL BUTTONS — Brand-colored premium effects
   ============================================================ */

.social-btn {
    position: relative;
    overflow: hidden;
    transition:
        transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1),
        box-shadow 0.3s ease,
        border-color 0.25s ease,
        background-color 0.25s ease,
        color 0.25s ease !important;
}

/* Lift + scale pop on hover */
.social-btn:hover {
    transform: translateY(-4px) scale(1.12) !important;
}

/* Shimmer sweep */
.social-btn::before {
    content: '';
    position: absolute;
    top: 0; left: -80%;
    width: 50%;
    height: 100%;
    background: linear-gradient(100deg, transparent 20%, rgba(255,255,255,0.18) 50%, transparent 80%);
    transition: left 0.45s ease;
    pointer-events: none;
    z-index: 5;
}
.social-btn:hover::before { left: 130%; }

/* Active press */
.social-btn:active { transform: scale(0.93) !important; }

/* ---- Discord — Indigo/Blurple ---- */
.social-btn-discord:hover {
    color: #5865F2 !important;
    border-color: #5865F2 !important;
    background-color: rgba(88, 101, 242, 0.12) !important;
    box-shadow:
        0 8px 24px rgba(88, 101, 242, 0.45),
        0 0 0 1px rgba(88, 101, 242, 0.3) !important;
}

/* ---- GitHub — Slate/White ---- */
.social-btn-github:hover {
    color: #e2e8f0 !important;
    border-color: #94a3b8 !important;
    background-color: rgba(148, 163, 184, 0.15) !important;
    box-shadow:
        0 8px 24px rgba(148, 163, 184, 0.35),
        0 0 0 1px rgba(148, 163, 184, 0.25) !important;
}

/* ---- Twitch — Purple ---- */
.social-btn-twitch:hover {
    color: #9146FF !important;
    border-color: #9146FF !important;
    background-color: rgba(145, 70, 255, 0.12) !important;
    box-shadow:
        0 8px 24px rgba(145, 70, 255, 0.45),
        0 0 0 1px rgba(145, 70, 255, 0.3) !important;
}

/* Light mode — brighter base so buttons are clearly visible */
.light-mode .social-btn {
    background-color: #f1f3f5 !important;
    border-color: #dee2e6 !important;
    color: #6c757d !important;
    box-shadow: 0 2px 6px rgba(0,0,0,0.06);
}

.light-mode .social-btn-discord:hover {
    background-color: rgba(88, 101, 242, 0.10) !important;
    border-color: #5865F2 !important;
    color: #5865F2 !important;
    box-shadow: 0 8px 24px rgba(88, 101, 242, 0.30), 0 0 0 1px rgba(88, 101, 242, 0.25) !important;
}

.light-mode .social-btn-github:hover {
    background-color: rgba(30, 41, 59, 0.08) !important;
    border-color: #475569 !important;
    color: #1e293b !important;
    box-shadow: 0 8px 24px rgba(30, 41, 59, 0.20), 0 0 0 1px rgba(30, 41, 59, 0.15) !important;
}

.light-mode .social-btn-twitch:hover {
    color: #9146FF !important;
}

/* ============================================================
   NEWSLETTER & UTILITY BUTTONS — Premium Refinement
   ============================================================ */

/* Newsletter Input Glow */
footer input[type="email"] {
    transition: all 0.3s ease !important;
}

footer input[type="email"]:focus {
    background-color: rgba(233, 30, 99, 0.05) !important;
    border-color: #E91E63 !important;
    box-shadow: 0 0 20px rgba(233, 30, 99, 0.15), inset 0 2px 4px rgba(0,0,0,0.2) !important;
}

/* Newsletter Arrow Button */
footer .relative.group button i {
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

footer .relative.group:hover button i {
    transform: translateX(3px) scale(1.2);
    text-shadow: 0 0 8px rgba(233, 30, 99, 0.6);
}

/* Back to Top Button Enhancement (Squircle Design) */
#back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 48px;
    height: 48px;
    background: #E91E63;
    color: white;
    border: none;
    border-radius: 12px; /* Perfect modern squircle */
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 8px 24px rgba(233, 30, 99, 0.25);
    transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
    z-index: 9999;
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    font-size: 18px;
}

#back-to-top.btt-visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

#back-to-top:hover {
    background: #ff2a75;
    transform: translateY(-6px) scale(1.05);
    box-shadow: 0 15px 30px rgba(233, 30, 99, 0.4);
}

#back-to-top:active {
    transform: scale(0.92);
}

/* Light Mode Adjustments */
.light-mode footer input[type="email"] {
    background-color: #f8f9fa !important;
    border-color: #dee2e6 !important;
    color: #212529 !important;
}

.light-mode footer input[type="email"]:focus {
    background-color: #ffffff !important;
    border-color: #E91E63 !important;
    box-shadow: 0 0 20px rgba(233, 30, 99, 0.1) !important;
}

.light-mode #back-to-top {
    box-shadow: 0 10px 25px rgba(233, 30, 99, 0.2);
}

.light-mode #back-to-top:hover {
    box-shadow: 0 15px 30px rgba(233, 30, 99, 0.4);
}
/* ============================================================
   PREMIUM ACTION BUTTONS — Shimmer & Glow
   ============================================================ */

.mag-btn-primary {
    position: relative;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1) !important;
    z-index: 1;
}

/* Base Shadow/Glow */
.mag-btn-primary:hover {
    transform: translateY(-5px) scale(1.02);
    box-shadow: 0 15px 35px rgba(233, 30, 99, 0.4), 0 0 20px rgba(233, 30, 99, 0.2) !important;
    background-color: #FF4081 !important;
}

/* Shimmer Sweep */
.mag-btn-primary::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 60%;
    height: 100%;
    background: linear-gradient(
        90deg,
        transparent,
        rgba(255, 255, 255, 0.2),
        transparent
    );
    transition: left 0.6s ease;
    z-index: 2;
    pointer-events: none;
}

.mag-btn-primary:hover::after {
    left: 150%;
}

/* Active Press */
.mag-btn-primary:active {
    transform: scale(0.96) translateY(-2px);
}

/* Light mode specific adjustment for buttons */
.light-mode .mag-btn-primary {
    box-shadow: 0 10px 20px rgba(233, 30, 99, 0.15);
}

.light-mode .mag-btn-primary:hover {
    box-shadow: 0 15px 35px rgba(233, 30, 99, 0.3);
}
/* ============================================================
   FOOTER TEXT LINKS — Premium Nightmode Effects
   ============================================================ */



/* Footer Link Hover & Click Refinement */
footer ul li a {
    position: relative;
    display: inline-block;
    transition: all 0.3s ease;
}

footer ul li a:hover {
    transform: translateX(8px);
    color: #E91E63 !important;
    text-shadow: 0 0 15px rgba(233, 30, 99, 0.4);
    font-weight: 700;
    -webkit-text-fill-color: #E91E63 !important; /* Ensure visibility */
}

footer ul li a:active {
    transform: translateX(4px) scale(0.95);
    color: #C026D3 !important; /* Slightly darker shade on press */
    -webkit-text-fill-color: #C026D3 !important;
}

/* ==========================================
   PREMIUM DOWNLOAD BUTTON EFFECTS
   ========================================== */
.mag-download-btn, #chatMessages button:has(.fa-file-pdf) {
    position: relative;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 1;
}

/* Shimmer/Glint Animation */
.mag-download-btn::after, #chatMessages button:has(.fa-file-pdf)::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -100%;
    width: 50%;
    height: 200%;
    background: linear-gradient(
        to right,
        rgba(255, 255, 255, 0) 0%,
        rgba(255, 255, 255, 0.15) 50%,
        rgba(255, 255, 255, 0) 100%
    );
    transform: rotate(25deg);
    transition: none;
    pointer-events: none;
    z-index: 2;
}

.mag-download-btn:hover::after, #chatMessages button:has(.fa-file-pdf):hover::after {
    left: 150%;
    transition: all 0.8s ease-in-out;
}

/* Hover State */
.mag-download-btn:hover, #chatMessages button:has(.fa-file-pdf):hover {
    background-color: #E91E63 !important;
    border-color: #E91E63 !important;
    color: white !important;
    transform: translateY(-3px);
    box-shadow: 0 10px 20px rgba(233, 30, 99, 0.3);
}

.mag-download-btn:hover i, #chatMessages button:has(.fa-file-pdf):hover i {
    transform: scale(1.2) rotate(10deg);
    color: white !important;
}

/* ==========================================
   ULTIMATE LIGHT MODE REFINEMENT
   ========================================== */

/* HIGH-CONTRAST CHAT & DOWNLOAD COMPS */
html body.light-mode .mag-download-btn, 
html body.light-mode #chatMessages button,
html body.light-mode .ai-response button, 
html body.light-mode [class*="chat"] button,
html body.light-mode .bom-card button {
    background-color: #ffffff !important;
    background: #ffffff !important;
    color: #000000 !important; 
    border: 2px solid #000000 !important; 
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.15) !important;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
    font-weight: 900 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    position: relative !important;
    overflow: hidden !important;
}

/* Force children (icon and text) to be above the shimmer and stay black */
html body.light-mode .mag-download-btn *,
html body.light-mode #chatMessages button * {
    position: relative !important;
    z-index: 5 !important;
    color: #000000 !important;
    opacity: 1 !important;
}

html body.light-mode .mag-download-btn:hover, 
html body.light-mode #chatMessages button:hover {
    background-color: #000000 !important;
    color: #ffffff !important;
}

html body.light-mode .mag-download-btn:hover *,
html body.light-mode #chatMessages button:hover * {
    color: #ffffff !important;
}

/* AI advisor bubble fixes for Light Mode - REQUIRED FOR TEXT VISIBILITY */
html body.light-mode #chatMessages div,
html body.light-mode .ai-response,
html body.light-mode .chat-message {
    background-color: #ffffff !important;
    color: #000000 !important;
    border: 1px solid #e2e8f0 !important;
    box-shadow: 0 4px 12px rgba(0,0,0,0.05) !important;
}

html body.light-mode #chatMessages div b, 
html body.light-mode #chatMessages div strong {
    color: #000000 !important;
    font-weight: 900 !important;
}

html body.light-mode #chatMessages div i, 
html body.light-mode #chatMessages div em {
    color: #be123c !important; 
    font-weight: 700 !important;
}

/* ==========================================
   SUPPORT PAGE EFFECTS (LIGHT MODE)
   ========================================== */
.light-mode .space-y-12 .bg-slate-800\/50,
.light-mode .space-y-12 .bg-slate-800 {
    background-color: #ffffff !important;
    border: 1px solid #e2e8f0 !important;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.03) !important;
    transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1) !important;
}

.light-mode .space-y-12 .bg-slate-800\/50:hover,
.light-mode .space-y-12 .bg-slate-800:hover {
    transform: translateY(-4px) !important;
    border-color: #E91E63 !important;
    box-shadow: 0 15px 30px rgba(233, 30, 99, 0.12) !important;
}

.light-mode .space-y-12 .bg-slate-800\/50 h4,
.light-mode .space-y-12 .bg-slate-800 .text-lg {
    color: #0f172a !important;
}



/* Bullet indicator on hover with pulse */
/* Specific footer navigation lists to avoid affecting the branding logo column */
footer .space-y-4 li a::before {
    content: '→';
    position: absolute;
    left: -20px;
    opacity: 0;
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    color: #E91E63;
    font-size: 11px;
    filter: drop-shadow(0 0 5px rgba(233, 30, 99, 0.3));
    pointer-events: none;
    visibility: hidden;
}

footer .space-y-4 li a:hover::before {
    opacity: 1;
    visibility: visible;
    left: -15px;
}

/* Footer Heading Accent with Vibrant Glow */
footer h4 {
    position: relative;
    display: inline-block;
    padding-bottom: 8px;
    margin-bottom: 24px !important;
    transition: all 0.4s ease;
}

footer .grid > div:hover h4 {
    color: #E91E63 !important;
    text-shadow: 0 0 20px rgba(225, 29, 72, 0.5);
    letter-spacing: 0.25em !important;
}

footer h4::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 35px;
    height: 3px;
    background: linear-gradient(90deg, #E91E63, #ff4d8d);
    box-shadow: 0 2px 10px rgba(225, 29, 72, 0.6);
    transition: width 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
    border-radius: 10px;
}

footer .grid > div:hover h4::after {
    width: 60px;
    background: linear-gradient(90deg, #ff4d8d, #E91E63);
}

/* Newsletter Input Premium Hover */
.light-mode footer .relative.group {
    box-shadow: 0 4px 12px rgba(0,0,0,0.03);
    border-radius: 12px;
}

.light-mode footer .relative.group:hover {
    box-shadow: 0 10px 25px rgba(225, 29, 72, 0.08);
}

/* Glassmorphism for footer columns on hover (Subtle) */
footer .grid > div {
    padding: 15px;
    margin: -15px;
    border-radius: 20px;
    transition: background 0.4s ease, box-shadow 0.4s ease;
}

footer .grid > div:hover {
    background: rgba(255, 255, 255, 0.02);
}

.light-mode footer .grid > div:hover {
    background: rgba(0, 0, 0, 0.015);
}

/* Specific Light Mode Polish for Footer Links */
.light-mode footer ul li a {
    color: #495057 !important;
}

.light-mode footer ul li a:hover {
    color: #E91E63 !important;
    text-shadow: 0 0 8px rgba(225, 29, 72, 0.2);
}

.light-mode footer h4 {
    color: #212529 !important;
}

/* Premium Reveal Animation for Footer Columns */
@keyframes footerFadeUp {
    from { opacity: 0; transform: translateY(15px); }
    to { opacity: 1; transform: translateY(0); }
}

footer .grid > div {
    animation: footerFadeUp 0.6s ease backwards;
}

footer .grid > div:nth-child(1) { animation-delay: 0.1s; }
footer .grid > div:nth-child(2) { animation-delay: 0.2s; }
footer .grid > div:nth-child(3) { animation-delay: 0.3s; }
/* Global Active (Click) State for Tactile Feedback */
a:active, 
button:active, 
.sidebar-item:active, 
.nav-link:active,
.product-card:active,
#categoryDrawer div:active {
    color: #E91E63 !important;
    transform: scale(0.96) !important;
    transition: transform 0.1s ease !important;
}

/* Specific Sidebar Active Polish */
.sidebar-item:active i {
    color: #E91E63 !important;
    filter: drop-shadow(0 0 8px rgba(233, 30, 99, 0.6));
}

/* Ensure no override on special buttons that already have custom active states */
.social-btn:active, .mag-btn-primary:active {
    transform: scale(0.93) !important;
}