


:root {
    /* Primary Colors - Marjane Inspired Blue */
    --primary-color: #0055a4;
    --primary-dark: #004487;
    --primary-light: #2679c5;
    
    /* Secondary & Accent Colors */
    --accent-orange: #f68b1e; /* Call to actions */
    --accent-yellow: #ffc20e; /* Marjane Yellow */
    
    --secondary-color: #0f1111;
    --secondary-light: #232f3e;
    
    /* Support Colors */
    --accent-green: #007600;
    --accent-red: #cc0c39;
    --accent-blue: #0055a4;
    
    /* Neutral Colors */
    --white: #FFFFFF;
    --bg-light: #F2F4F8; /* Light blue-grey background */
    --bg-grey: #e3e6e6;
    --text-dark: #111827;
    --text-grey: #565959;
    --text-light: #949494;
    --border-color: #d5d9d9;
    --card-bg: #FFFFFF;
    
    /* Layout */
    --nav-height: 60px;
    
    /* Shadows - Subtle */
    --shadow-sm: 0 1px 3px rgba(0,0,0,0.06);
    --shadow-md: 0 4px 6px rgba(0,0,0,0.08);
    --shadow-lg: 0 10px 15px rgba(0,0,0,0.08);
    --shadow-xl: 0 20px 25px rgba(0,0,0,0.1);
    
    /* Border Radius - Rounded modern */
    --radius-sm: 4px;
    --radius-md: 8px;
    --radius-lg: 12px;
    --radius-xl: 16px;
    
    /* Transitions */
    --transition-fast: 0.1s ease;
    --transition-normal: 0.2s ease;
    --transition-slow: 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Cairo', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background-color: var(--bg-light);
    color: var(--text-dark);
    line-height: 1.7;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

main, .container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    flex: 1 0 auto;
}

footer {
    background: var(--secondary-color);
    color: #fff;
    text-align: center;
    padding: 24px 0 12px 0;
    font-size: 15px;
    margin-top: 40px;
    letter-spacing: 0.5px;
}

button, .btn {
    background: var(--primary-color);
    color: #fff;
    border: none;
    border-radius: var(--radius-md);
    padding: 10px 22px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    box-shadow: var(--shadow-sm);
    transition: background 0.2s, box-shadow 0.2s, transform 0.15s;
}
button:hover, .btn:hover {
    background: var(--primary-dark);
    box-shadow: var(--shadow-md);
    transform: translateY(-2px) scale(1.03);
}

.card {
    background: #fff;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    padding: 2rem;
    margin-bottom: 2rem;
    transition: box-shadow 0.2s, transform 0.15s;
}
.card:hover {
    box-shadow: var(--shadow-xl);
    transform: translateY(-3px) scale(1.01);
}

input, select, textarea {
    border: 1.5px solid var(--border-color);
    border-radius: var(--radius-sm);
    padding: 10px 14px;
    font-size: 1rem;
    background: #fff;
    color: var(--text-dark);
    margin-bottom: 12px;
    transition: border 0.2s, box-shadow 0.2s;
}
input:focus, select:focus, textarea:focus {
    border-color: var(--primary-color);
    outline: none;
    box-shadow: 0 0 0 2px var(--primary-light);
}

.product-list, .products {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 2rem;
    margin: 2rem 0;
}

.product-card {
    background: #fff;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    transition: box-shadow 0.2s, transform 0.15s;
}
.product-card:hover {
    box-shadow: var(--shadow-lg);
    transform: translateY(-2px) scale(1.02);
}
.product-card img {
    max-width: 100%;
    max-height: 180px;
    border-radius: var(--radius-sm);
    margin-bottom: 1rem;
}
.product-card .product-title {
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    color: var(--secondary-color);
}
.product-card .product-price {
    color: var(--primary-color);
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
}
.product-card .product-desc {
    color: var(--text-grey);
    font-size: 0.97rem;
    margin-bottom: 1rem;
    text-align: center;
}
.product-card .btn {
    margin-top: auto;
}

@media (max-width: 900px) {
    .container, main { padding: 0 10px; }
    .product-list, .products { gap: 1rem; }
    .card { padding: 1rem; }
}
@media (max-width: 600px) {
    .product-list, .products { grid-template-columns: 1fr; }
    .main-header, .top-bar { padding: 8px 0; }
    .card { padding: 0.7rem; }
}


a { 
    text-decoration: none; 
    color: inherit;
    transition: var(--transition-fast);
}

a:hover {
    color: var(--primary-color);
}

ul { list-style: none; }

/* ===== TOP BAR ===== */
.top-bar {
    background: var(--bg-light);
    border-bottom: 1px solid var(--border-color);
    padding: 6px 0;
    font-size: 12px;
    color: var(--text-grey);
    box-shadow: none;
}

.top-bar .container { 
    display: flex; 
    justify-content: space-between; 
    align-items: center;
}

.top-bar > .container > span {
    display: flex;
    align-items: center;
    gap: 6px;
    color: var(--primary-color);
    font-weight: 600;
}

.top-bar > .container > span i {
    font-size: 13px;
}

.top-links { 
    display: flex;
    gap: 15px;
}

.top-links a { 
    color: var(--text-grey);
    font-weight: 400;
    padding: 0;
    border-radius: 0;
    transition: var(--transition-fast);
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 12px;
}

.top-links a i { font-size: 12px; }

.top-links a:hover { 
    color: var(--primary-color);
    background: transparent;
}

[dir="rtl"] .top-links a { margin-left: 0; margin-right: 0; }

/* ===== MAIN HEADER ===== */
.main-header {
    background: var(--white);
    padding: 20px 0;
    position: relative;
    z-index: 100;
    box-shadow: none;
}

.header-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 40px;
}

.logo h1 { 
    font-size: 32px; 
    font-weight: 800;
    letter-spacing: -0.5px;
    display: flex;
    align-items: center;
    gap: 2px;
    color: var(--primary-color);
    background: none;
    -webkit-text-fill-color: initial;
    text-shadow: none;
}

.logo h1 span:first-child {
    background: none;
    -webkit-background-clip: unset;
    -webkit-text-fill-color: initial;
    background-clip: unset;
    color: var(--primary-color);
}

.logo .dot { 
    color: var(--accent-orange);
    font-size: 38px;
    line-height: 0;
    margin-top: 5px;
    -webkit-text-fill-color: initial;
}

/* Search Bar - Modern Pill Style */
.search-bar {
    flex: 1;
    display: flex;
    max-width: 600px;
    position: relative;
}

.search-bar input {
    width: 100%;
    padding: 14px 20px;
    padding-right: 60px;
    border: 2px solid #E5E7EB;
    border-radius: 50px;
    outline: none;
    font-size: 14px;
    font-family: inherit;
    background: #F9FAFB;
    transition: all 0.3s ease;
}

.search-bar input:focus {
    background: var(--white);
    border-color: var(--primary-color);
    box-shadow: 0 4px 12px rgba(0, 85, 164, 0.1);
}

.search-bar input::placeholder {
    color: var(--text-light);
}

[dir="rtl"] .search-bar input {
    padding-right: 20px;
    padding-left: 60px;
}

.search-bar button {
    position: absolute;
    right: 5px;
    top: 5px;
    bottom: 5px;
    background: var(--primary-color);
    color: var(--white);
    border: none;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 16px;
    transition: var(--transition-normal);
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50% !important; /* Force circle */
}

.search-bar button:hover {
    background: var(--primary-dark);
    transform: scale(1.05);
}

[dir="rtl"] .search-bar button {
    right: auto;
    left: 5px;
}

/* User Actions */
.user-actions { 
    display: flex; 
    gap: 15px;
}

.action-item { 
    display: flex; 
    flex-direction: column; 
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 600;
    position: relative;
    color: var(--text-grey);
    padding: 5px 10px;
    border-radius: var(--radius-md);
    transition: var(--transition-normal);
    min-width: 60px;
}

.action-item:hover {
    background: transparent;
    color: var(--primary-color);
}

.action-item i { 
    font-size: 24px; 
    margin-bottom: 6px;
    color: var(--text-dark);
    transition: color 0.2s;
}

.action-item:hover i {
    color: var(--primary-color);
}

.badge {
    position: absolute;
    top: 4px;
    right: 10px;
    background: var(--accent-orange);
    color: var(--secondary-color);
    font-size: 10px;
    font-weight: 800;
    min-width: 18px;
    height: 18px;
    padding: 0 5px;
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 5px rgba(246, 139, 30, 0.4);
}

/* ===== MAIN NAVIGATION ===== */
.main-nav {
    background: var(--primary-color);
    height: 52px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    position: relative;
    border-top: 1px solid rgba(255,255,255,0.1);
}

.main-nav .container { 
    display: flex; 
    align-items: center; 
    height: 100%;
}

.categories-btn {
    
    background: transparent;
    color: white;
    padding: 0 15px;
    height: 40px;
    display: flex;
    align-items: center;
    font-weight: 700;
}
.categories-btn i {
    font-size: 18px;
}

.nav-links { 
    display: flex; 
    margin-left: 10px;
    height: 100%;
}

[dir="rtl"] .nav-links { 
    margin-left: 0; 
    margin-right: 10px;
}

.nav-links li { height: 100%; }

.nav-links li a { 
    padding: 0 20px; 
    display: flex; 
    align-items: center; 
    height: 100%; 
    font-weight: 600; 
    font-size: 14px;
}

.brand-filter-container {
    margin-left: auto;
    display: flex;
    align-items: center;
}

.brand-filter-container select {
    padding: 8px 12px;
    border-radius: var(--radius-md);
    border: 1px solid rgba(255,255,255,0.3);
    background: rgba(255,255,255,0.1);
    color: white;
    font-size: 14px;
    cursor: pointer;
    outline: none;
}

.brand-filter-container select:hover,
.brand-filter-container select:focus {
    background: rgba(255,255,255,0.2);
}

.brand-filter-container select option {
    background: var(--primary-color);
    color: white;
    color: rgba(255,255,255,0.95);
    position: relative;
    transition: var(--transition-fast);
    letter-spacing: 0.3px;
    border:solid 1px;
    border-radius: 25px 0px 25px 0px ;
}

.nav-links li a:hover { 
    color: var(--accent-yellow);
    background: rgba(0, 0, 0, 0.1);
}

.nav-links li a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0; 
    width: 100%;
    height: 3px;
    background: var(--accent-yellow);
    transform: scaleX(0);
    transform-origin: right;
    transition: transform 0.3s ease;
    box-shadow: none;
    border-radius: 0;
}

.nav-links li a:hover::after {
    transform: scaleX(1);
    transform-origin: left;
}

/* ===== HERO SECTION WITH SLIDER ===== */
.hero { 
    padding: 15px 0 20px;
    background: var(--bg-light);
}


/* Keep old banner styles for text */
.banner-badge {
    position: absolute;
    top: 15px;
    right: 15px;
    background: var(--accent-red);
    color: white;
    padding: 5px 14px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 700;
    animation: pulse 2s infinite;
    z-index: 5;
}

[dir="rtl"] .banner-badge {
    right: auto;
    left: 15px;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

.slide-content .banner-label,
.banner-label {
    display: inline-block;
    background: var(--primary-color);
    color: white;
    padding: 5px 14px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 700;
    margin-bottom: 12px;
}

.slide-content h2,
.banner-text h2 { 
    font-size: 28px;
    font-weight: 800;
    color: white;
    margin-bottom: 8px;
    line-height: 1.2;
}

.banner-text h2 .highlight {
    color: var(--primary-color);
}

.slide-content p,
.banner-text p { 
    color: rgba(255,255,255,0.8);
    margin-bottom: 18px;
    font-size: 14px;
}

/* Side Banners */
.side-banners {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.mini-banner {
    flex: 1;
    border-radius: var(--radius-lg);
    padding: 20px;
    display: flex;
    align-items: center;
    cursor: pointer;
    transition: var(--transition-normal);
    min-height: 130px;
}

.mini-banner:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-lg);
}

.banner-orange {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    color: white;
}

.banner-dark {
    background: linear-gradient(135deg, #2D2D2D 0%, #1A1A1A 100%);
    color: white;
}

.mini-banner-content { text-align: center; width: 100%; }

.mini-label {
    font-size: 10px;
    opacity: 0.8;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.mini-banner h4 {
    font-size: 16px;
    font-weight: 700;
    margin: 8px 0;
}

.mini-discount {
    display: inline-block;
    background: white;
    color: var(--secondary-color);
    padding: 4px 12px;
    border-radius: 15px;
    font-size: 14px;
    font-weight: 800;
}

.btn-primary {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    background: var(--primary-color);
    color: white;
    padding: 14px 30px;
    border-radius: var(--radius-md);
    font-weight: 700;
    font-size: 14px;
    box-shadow: 0 4px 15px rgba(246, 139, 30, 0.4);
    transition: var(--transition-normal);
    border: none;
    cursor: pointer;
}

.btn-primary:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(246, 139, 30, 0.5);
    color: white;
}

/* ===== FLASH DEALS ===== */
.flash-deals-section {
    background: white;
    border-radius: var(--radius-lg);
    padding: 18px 24px;
    margin-top: 0;
    margin-bottom: 20px;
    box-shadow: var(--shadow-sm);
    border: 2px solid transparent;
    transition: var(--transition-normal);
}

.flash-deals-section:hover {
    border-color: var(--primary-color);
    box-shadow: var(--shadow-md);
}

.flash-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 15px;
}

.flash-title {
    display: flex;
    align-items: center;
    gap: 12px;
}

.flash-title i {
    color: var(--primary-color);
    font-size: 24px;
}

.flash-title h3 {
    font-size: 20px;
    font-weight: 800;
    color: var(--secondary-color);
    margin: 0;
}

.flash-badge {
    background: var(--accent-red);
    color: white;
    padding: 4px 12px;
    border-radius: 15px;
    font-size: 11px;
    font-weight: 700;
}

/* ===== CATEGORIES SECTION ===== */
.categories-section {
    margin-top: 5px;
    margin-bottom: 25px;
    padding: 0;
}

.categories-grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 18px;
}

@media (max-width: 1100px) {
    .categories-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 600px) {
    .categories-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

.category-card {
    background: white;
    border-radius: var(--radius-lg);
    padding: 28px 18px;
    text-align: center;
    cursor: pointer;
    transition: var(--transition-normal);
    border: 2px solid transparent;
    box-shadow: var(--shadow-sm);
}

.category-card:hover {
    border-color: var(--primary-color);
    transform: translateY(-5px);
    box-shadow: var(--shadow-md);
}

.category-icon {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, rgba(246, 139, 30, 0.1) 0%, rgba(246, 139, 30, 0.2) 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 12px;
}

.category-icon i {
    font-size: 24px;
    color: var(--primary-color);
}

.category-card h4 {
    font-size: 14px;
    font-weight: 700;
    color: var(--secondary-color);
    margin-bottom: 5px;
}

.category-count {
    font-size: 12px;
    color: var(--text-grey);
}

/* ===== BRANDS SECTION ===== */
.brands-section {
    padding: 20px 20px 25px;
    margin-bottom: 25px;
    background: white;
    border-radius: var(--radius-lg);
    margin-left: auto;
    margin-right: auto;
    box-shadow: var(--shadow-sm);
}

.brands-section .section-title {
    margin-bottom: 20px;
    padding: 0;
}

.brands-grid {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 15px;
    padding: 0;
}

.brand-item {
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--white);
    border: 2px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 15px 30px;
    min-width: 120px;
    cursor: pointer;
    transition: var(--transition-normal);
}

.brand-item:hover {
    border-color: var(--primary-color);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.brand-item i {
    font-size: 28px;
    color: var(--secondary-color);
}

.brand-logo {
    font-weight: 700;
    font-size: 16px;
    color: var(--secondary-color);
}

/* ===== PRODUCTS SECTION ===== */
.products-section { 
    padding: 0 0 40px;
}

.products-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    flex-wrap: wrap;
    gap: 15px;
}

.section-title { 
    font-size: 24px; 
    font-weight: 800; 
    margin: 0 0 5px 0; 
    color: var(--secondary-color);
    display: flex;
    align-items: center;
    text-align: right;
    gap: 14px;
}

.section-title i {
    color: var(--primary-color);
    font-size: 22px;
}

.products-filter {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

[dir="rtl"] .products-filter {
    justify-content: flex-start;
}

.filter-btn {
    background: white;
    border: 2px solid var(--border-color);
    padding: 10px 22px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
    color: var(--text-grey);
    cursor: pointer;
    transition: var(--transition-fast);
    font-family: inherit;
    white-space: nowrap;
}

.filter-btn:hover {
    border-color: var(--primary-color);
    color: var(--primary-color);
}

.filter-btn.active {
    background: var(--primary-color);
    border-color: var(--primary-color);
    color: white;
}

/* ===== FEATURES SECTION ===== */
.features-section {
    background: white;
    padding: 45px 0;
    margin-top: 20px;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 25px;
}

.feature-item {
    text-align: center;
    padding: 25px 15px;
}

.feature-icon {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, rgba(246, 139, 30, 0.1) 0%, rgba(246, 139, 30, 0.2) 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 15px;
}

.feature-icon i {
    font-size: 24px;
    color: var(--primary-color);
}

.feature-item h4 {
    font-size: 15px;
    font-weight: 700;
    color: var(--secondary-color);
    margin-bottom: 5px;
}

.feature-item p {
    font-size: 13px;
    color: var(--text-grey);
    margin: 0;
}

/* ===== FOOTER ===== */
footer { 
    background: linear-gradient(180deg, var(--secondary-color) 0%, #0F0F1E 100%);
    color: rgba(255,255,255,0.9);
    padding: 24px 0 0;
    margin-top: 60px;
    box-shadow: 0 -4px 30px rgba(0,0,0,0.2);
}

.footer-top {
    display: flex;
    justify-content: space-between;
    gap: 40px;
    padding-bottom: 30px;
    border-bottom: 1px solid rgba(255,255,255,0.1);
    flex-wrap: wrap;
}

.footer-brand h3 {
    font-size: 28px;
    font-weight: 800;
    margin-bottom: 15px;
    color: white;
    letter-spacing: -0.5px;
}

.footer-brand h3 span {
    color: var(--accent-yellow);
}

.footer-brand p {
    color: rgba(255,255,255,0.7);
    font-size: 14px;
    line-height: 1.6;
    margin-bottom: 20px;
    max-width: 300px;
}

.social-icons {
    display: flex;
    gap: 10px;
}

.social-icons a {
    width: 36px;
    height: 36px;
    background: rgba(255,255,255,0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 16px;
    transition: var(--transition-normal);
    border: 1px solid rgba(255,255,255,0.1);
}

.social-icons a:hover {
    background: var(--primary-color);
    transform: translateY(-2px);
    color: white;
    border-color: var(--primary-color);
    box-shadow: var(--shadow-md);
}

.footer-cols { 
    display: flex; 
    gap: 40px;
    flex-wrap: wrap;
}

.col h4 { 
    margin-bottom: 15px; 
    font-size: 14px; 
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: white;
    position: relative;
    padding-bottom: 8px;
}

.col h4::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 30px;
    height: 2px;
    background: var(--accent-yellow);
}

.col ul li { 
    margin-bottom: 8px;
}

.col ul li a,
.col ul li {
    color: rgba(255,255,255,0.6);
    font-size: 13px;
    transition: var(--transition-fast);
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 6px;
    text-decoration: none;
}

.col ul li:hover,
.col ul li a:hover { 
    color: var(--accent-yellow);
}

.contact-info li i {
    color: var(--accent-yellow);
    width: 14px;
}

.footer-bottom {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 15px 0;
    background: rgba(0,0,0,0.3);
    margin: 0;
    width: 100vw;
    margin-left: calc(50% - 50vw);
    margin-right: calc(50% - 50vw);
    padding-left: max(20px, 50vw - 600px);
    padding-right: max(20px, 50vw - 600px);
}

.footer-bottom .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 15px;
    margin: 0 auto;
    width: 100%;
}

/* Payment methods removed */

.copyright { 
    font-size: 12px; 
    color: rgba(255,255,255,0.5);
    font-weight: 400;
}

/* ===== CART SIDEBAR ===== */
.cart-view {
    position: fixed;
    top: 0;
    right: 0;
    width: 420px;
    max-width: 95vw;
    height: 100vh;
    background: var(--white);
    box-shadow: -10px 0 40px rgba(0,0,0,0.15);
    z-index: 1002;
    transform: translateX(100%);
    transition: var(--transition-slow);
    display: flex;
    flex-direction: column;
}

.cart-view.show {
    transform: translateX(0);
}

[dir="rtl"] .cart-view {
    right: auto;
    left: 0;
    transform: translateX(-100%);
    box-shadow: 10px 0 40px rgba(0,0,0,0.15);
}

[dir="rtl"] .cart-view.show {
    transform: translateX(0);
}

.cart-view > h2 {
    padding: 24px;
    background: linear-gradient(135deg, var(--secondary-color) 0%, var(--secondary-light) 100%);
    color: white;
    font-size: 20px;
    margin: 0;
    text-align: center;
}

#cart-items-container {
    padding: 20px;
    overflow-y: auto;
    flex: 1;
    background: var(--bg-light);
}

.cart-item {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px;
    background: white;
    border-radius: var(--radius-md);
    margin-bottom: 12px;
    box-shadow: var(--shadow-sm);
    transition: var(--transition-normal);
}

.cart-item:hover {
    box-shadow: var(--shadow-md);
}

.cart-item img {
    width: 70px;
    height: 70px;
    object-fit: contain;
    border-radius: var(--radius-sm);
    background: var(--bg-light);
    padding: 5px;
}

.cart-item-info {
    flex: 1;
}

.cart-item-title {
    font-weight: 600;
    font-size: 14px;
    margin-bottom: 6px;
    color: var(--text-dark);
}

.cart-item-price {
    color: var(--primary-color);
    font-weight: 700;
    font-size: 16px;
}

#cart-summary {
    padding: 24px;
    background: white;
    border-top: 2px solid var(--border-color);
}

#cart-summary h3 {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 18px;
    margin-bottom: 20px;
    color: var(--secondary-color);
}

#cart-summary h3 span {
    color: var(--primary-color);
    font-size: 24px;
}

.cart-button {
    display: block;
    width: 100%;
    padding: 16px;
    border-radius: var(--radius-md);
    font-weight: 700;
    font-size: 15px;
    text-align: center;
    cursor: pointer;
    transition: var(--transition-normal);
    border: none;
    margin-bottom: 10px;
    font-family: inherit;
}

.checkout-button {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    color: white;
    box-shadow: 0 4px 15px rgba(227, 6, 19, 0.3);
}

.checkout-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(227, 6, 19, 0.4);
}

.close-cart-button {
    background: var(--bg-grey);
    color: var(--text-grey);
}

.close-cart-button:hover {
    background: var(--border-color);
    color: var(--text-dark);
}

/* ===== MODAL ===== */
.modal {
    display: none; 
    position: fixed; 
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
    -webkit-backdrop-filter: blur(4px);
    backdrop-filter: blur(4px);
}

.modal-content {
    background: var(--white);
    margin: 10% auto;
    padding: 40px;
    border-radius: var(--radius-lg);
    width: 90%;
    max-width: 500px;
    box-shadow: var(--shadow-xl);
    position: relative;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 1200px) {
    .hero-slider-wrapper {
        grid-template-columns: 1fr 240px;
    }
}

@media (max-width: 992px) {
    .hero-slider-wrapper {
        grid-template-columns: 1fr;
    }
    
    .hero-slider {
        height: 240px;
    }
    
    .side-banners {
        flex-direction: row;
    }
    
    .mini-banner {
        min-height: 100px;
        padding: 15px;
    }
}

@media (max-width: 768px) {
    .hero-slider {
        height: 200px;
    }
    
    .slide {
        padding: 20px 25px;
    }
    
    .slide-content h2 {
        font-size: 22px;
    }
    
    .slide-content p {
        font-size: 12px;
        margin-bottom: 12px;
    }
    
    .slide-image {
        display: none;
    }
    
    .slider-btn {
        width: 32px;
        height: 32px;
        font-size: 14px;
    }
    
    .side-banners {
        flex-direction: column;
        gap: 10px;
    }
    
    .mini-banner {
        min-height: 80px;
        padding: 12px;
    }
    
    .mini-banner h4 {
        font-size: 13px;
    }
}

@media (max-width: 1024px) {
    .footer-top {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    .footer-cols {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .social-icons {
        justify-content: center;
    }
    
    .features-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 900px) {
    .top-bar {
        display: none;
    }
    
    .header-content { 
        flex-wrap: wrap;
        gap: 12px;
        padding: 10px 15px;
    }
    
    .logo h1 {
        font-size: 22px;
    }
    
    .logo .dot {
        font-size: 26px;
    }
    
    .search-bar { 
        order: 3;
        max-width: 100%;
        width: 100%;
    }
    
    .search-bar input {
        padding: 10px 15px;
        font-size: 14px;
    }
    
    /* Sidebar Mobile Navigation */
    .nav-links { 
        display: block;
        position: fixed;
        top: 0;
        right: -280px; /* Hide off-screen right */
        width: 260px;
        height: 100vh;
        background: white;
        padding-top: 60px;
        z-index: 2200;
        transition: right 0.3s cubic-bezier(0.4, 0, 0.2, 1);
        box-shadow: -5px 0 20px rgba(0,0,0,0.15);
        flex-direction: column;
        margin: 0;
    }
    
    .nav-links.active {
        right: 0; /* Slide in */
    }
    
    .nav-links li {
        width: 100%;
        height: auto;
        border-bottom: 1px solid var(--bg-light);
    }
    
    .nav-links li a {
        display: block;
        padding: 16px 20px;
        color: var(--text-dark);
        font-size: 15px;
        width: 100%;
        height: auto;
    }
    
    .nav-links li a:hover {
        background: var(--bg-light);
        color: var(--primary-color);
    }
    
    .nav-links li a::after {
        display: none;
    }
    
    /* Overlay */
    .mobile-nav-overlay {
        display:non;
        visibility:hidden;
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: rgba(0,0,0,0.5);
        opacity: 0;
        transition: all 0.3s;
        display:non;
    }
    
    .mobile-nav-overlay.active {
        opacity: 1;
        visibility: visible;
    }

    .main-nav .container {
        padding: 0 15px;
        width: 100%;
    }
    
    .main-nav {
        overflow: visible;
    }
    
    .categories-btn {
        font-size: 12px;
        padding: 0 15px;
        white-space: nowrap;
    }
    
    .hero-grid {
        grid-template-columns: 1fr;
    }
    
    .hero-banner.main-banner { 
        min-height: 220px;
        padding: 25px 20px;
    }
    
    .banner-text h2 {
        font-size: 24px;
    }
    
    .banner-text p {
        font-size: 14px;
        margin-bottom: 18px;
    }
    
    .btn-primary {
        padding: 12px 24px;
        font-size: 13px;
    }
    
    .banner-image { display: none; }
    
    .side-banners {
        flex-direction: column;
    }
    
    .mini-banner {
        min-height: 80px;
        padding: 18px;
    }
    
    .categories-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 10px;
    }
    
    .category-card {
        padding: 15px 10px;
    }
    
    .category-icon {
        width: 50px;
        height: 50px;
    }
    
    .category-icon i {
        font-size: 20px;
    }
    
    .category-card h4 {
        font-size: 12px;
    }
    
    .user-actions { 
        gap: 5px;
    }
    
    .action-item {
        padding: 8px 10px;
        min-width: auto;
    }
    
    .action-item span {
        display: none;
    }
    
    .action-item i {
        font-size: 20px;
    }
    
    .section-title {
        font-size: 18px;
    }
    
    .section-title i {
        font-size: 16px;
    }
    
    .brands-section {
        margin-left: 0;
        margin-right: 0;
        border-radius: 0;
    }
    
    .brand-item {
        padding: 12px 20px;
        min-width: 100px;
    }
    
    .footer-cols {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    .footer-bottom {
        flex-direction: column;
        text-align: center;
    }
    
    .cart-view {
        width: 100%;
        max-width: 100%;
    }
    
    .features-grid {
        grid-template-columns: 1fr 1fr;
        gap: 15px;
    }
    
    .feature-item {
        padding: 15px 10px;
    }
    
    .feature-icon {
        width: 50px;
        height: 50px;
    }
    
    .feature-icon i {
        font-size: 20px;
    }
    
    .feature-item h4 {
        font-size: 13px;
    }
    
    .feature-item p {
        font-size: 11px;
    }
    
    .products-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }
    
    .products-filter {
        width: 100%;
        overflow-x: auto;
        padding-bottom: 10px;

    }
    
    .filter-btn {
        padding: 8px 16px;
        font-size: 12px;
    }
    
    .flash-header {
        flex-direction: column;
        gap: 12px;
        text-align: center;
    }
    
    .flash-title h3 {
        font-size: 16px;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 12px;
    }
    
    .hero-banner.main-banner {
        min-height: 180px;
        padding: 20px 15px;
    }
    
    .banner-label {
        font-size: 11px;
        padding: 5px 12px;
    }
    
    .banner-text h2 {
        font-size: 20px;
    }
    
    .banner-text p {
        font-size: 13px;
    }
    
    .btn-primary {
        padding: 10px 20px;
        font-size: 12px;
    }
    
    .section-title {
        font-size: 16px;
    }
    
    .categories-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 8px;
    }
    
    .category-card {
        padding: 12px 8px;
    }
    
    .category-icon {
        width: 42px;
        height: 42px;
        margin-bottom: 8px;
    }
    
    .category-icon i {
        font-size: 18px;
    }
    
    .category-card h4 {
        font-size: 11px;
        margin-bottom: 3px;
    }
    
    .category-count {
        font-size: 10px;
    }
    
    .brands-section {
        padding: 15px 0;
    }
    
    .brand-item {
        padding: 10px 16px;
        min-width: 80px;
    }
    
    .brand-logo {
        font-size: 13px;
    }
    
    .features-grid {
        grid-template-columns: 1fr 1fr;
        gap: 10px;
    }
    
    .feature-item {
        padding: 12px 8px;
    }
    
    .feature-icon {
        width: 40px;
        height: 40px;
        margin-bottom: 8px;
    }
    
    .feature-icon i {
        font-size: 16px;
    }
    
    .feature-item h4 {
        font-size: 12px;
    }
    
    .feature-item p {
        font-size: 10px;
    }
    
    .flash-header {
        flex-direction: column;
        gap: 10px;
    }
    
    .flash-title h3 {
        font-size: 15px;
    }
    
    .countdown-item {
        padding: 6px 10px;
        min-width: 42px;
    }
    
    .footer-brand h3 {
        font-size: 22px;
    }
    
    .footer-brand p {
        font-size: 13px;
    }
    
    .col h4 {
        font-size: 13px;
        margin-bottom: 12px;
    }
    
    .col ul li a,
    .col ul li {
        font-size: 12px;
    }
}

/* Utility Classes */
.invisible {
    visibility: hidden;
}

.text-center {
    text-align: center;
}
/* Ensure Sidebar is above Overlay (Fix for blurred sidebar) */
@media (max-width: 900px) {
    .main-nav {
        position: relative;
        z-index: 2200; /* Higher than overlay's 1050 */
    }
    .nav-links {
        z-index: 2201;
    }
}

/* Blur for Cart Open: Exclude Cart Sidebar and ensure Nav is blurred */
body.cart-open > *:not(.cart-view):not(.toast-notification):not(.mobile-nav-overlay):not(script):not(style) {
    filter: blur(4px);
    -webkit-filter: blur(4px);
    pointer-events: none;
    user-select: none;
}

/* Blur for Menu Open: Exclude Main Nav (Sidebar) and ensure Cart is blurred */
body.menu-open > *:not(.main-nav):not(.toast-notification):not(.mobile-nav-overlay):not(script):not(style) {
    filter: blur(4px);
    -webkit-filter: blur(4px);
    pointer-events: none;
    user-select: none;
}

body.cart-open, body.menu-open {
    overflow: hidden;
}

/* Flash Animation */
@keyframes flash {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.6; transform: scale(1.1); }
}

.flash-icon {
    animation: flash 1.2s ease-in-out infinite;
    color: #F68B1E;
}

/* Countdown Timer */
.countdown {
    display: flex;
    gap:10px;
    justify-content: center;
    direction: ltr;
}
.countdown-item {
    background: linear-gradient(135deg, #1A1A2E 0%, #282A3A 100%);
    color: white;
    padding: 10px 14px;
    border-radius: 8px;
    font-weight: 700;
    min-width: 52px;
    text-align: center;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}
.countdown-item span {
    font-size: 20px;
    display: block;
}
.countdown-label {
    font-size: 10px;
    opacity: 0.75;
    margin-top: 2px;
}

/* Modal Styles */
#tracking-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    -webkit-backdrop-filter: blur(5px);
    backdrop-filter: blur(5px);
    z-index: 9999;
    justify-content: center;
    align-items: center;
}
.modal-content {
    background: white;
    padding: 35px;
    border-radius: 16px;
    width: 90%;
    max-width: 420px;
    text-align: center;
    box-shadow: 0 25px 60px rgba(0,0,0,0.3);
}
.modal-content h3 {
    color: #1A1A2E;
    font-size: 22px;
    margin-bottom: 10px;
}
.modal-description {
    margin-bottom: 20px;
    color: #666;
}
#tracking-order-id {
    width: 100%;
    border-radius: 10px;
    margin-bottom: 15px;
    font-size: 16px;
    transition: all 0.3s;
}
#tracking-order-id:focus {
    outline: none;
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}
.btn-track {
    background: #3b82f6;
    color: white;
    border: none;
    padding: 14px 28px;
    border-radius: 10px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s;
}
.btn-track:hover {
    background: #2563eb;
}
.btn-close {
    background: #6b7280;
    color: white;
    border: none;
    padding: 14px 28px;
    border-radius: 10px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s;
}
.btn-close:hover { background: #d1d5db; }