/* ========================================
   AUTO CLASS - Premium Auto Tools Store
   Black & White Premium Theme with RTL Support
   ======================================== */

/* CSS Variables */
:root {
    --primary-color: #ff0000;
    --secondary-color: #1a1a1a;
    --bg-dark: #0a0a0a;
    --bg-gray: #1a1a1a;
    --bg-light: #2a2a2a;
    --text-primary: #ffffff;
    --text-secondary: #b0b0b0;
    --text-muted: #707070;
    --chrome-silver: #c0c0c0;
    --border-color: #333333;
    --shadow: rgba(0, 0, 0, 0.5);
    --transition: all 0.3s ease;
}

[data-theme="light"] {
    --bg-dark: #f5f5f5;
    --bg-gray: #ffffff;
    --bg-light: #e5e5e5;
    --text-primary: #1a1a1a;
    --text-secondary: #4a4a4a;
    --text-muted: #8a8a8a;
    --border-color: #e0e0e0;
    --shadow: rgba(0, 0, 0, 0.1);
}

/* RTL Support */
[dir="rtl"] {
    direction: rtl;
    text-align: right;
}

[dir="rtl"] .logo {
    margin-left: 0;
    margin-right: auto;
}

/* Reset & Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: var(--bg-dark);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: var(--bg-gray);
}

::-webkit-scrollbar-thumb {
    background: var(--chrome-silver);
    border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--primary-color);
}

/* Container */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Header */
.header {
    background: var(--bg-gray);
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
    z-index: 1000;
    transition: var(--transition);
}

.header-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem 0;
    gap: 2rem;
}

.logo a {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    color: var(--text-primary);
    font-size: 1.5rem;
    font-weight: bold;
}

.logo i {
    color: var(--primary-color);
    font-size: 2rem;
}

.nav-list {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.nav-list a {
    color: var(--text-secondary);
    text-decoration: none;
    transition: var(--transition);
    position: relative;
    padding: 0.5rem 0;
}

.nav-list a:hover,
.nav-list a.active {
    color: var(--primary-color);
}

.nav-list a.active::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: var(--primary-color);
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.search-toggle,
.theme-toggle,
.wishlist-icon,
.cart-icon,
.user-menu {
    color: var(--text-secondary);
    cursor: pointer;
    transition: var(--transition);
    position: relative;
}

.search-toggle:hover,
.theme-toggle:hover,
.wishlist-icon:hover,
.cart-icon:hover,
.user-menu:hover {
    color: var(--primary-color);
}


.badge {
    position: absolute;
    top: -8px;
    right: -8px;
    background: var(--primary-color);
    color: white;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.7rem;
    font-weight: bold;
}
.btn-danger {

    background: #e74c3c;
    color: #fff;
    border: none;
}

.btn-danger:hover {

    background: #c0392b;
}

.status-cancelled {

    background: #e74c3c;
    color: #fff;
}
.status-delivered {

    background: rgba(46, 204, 113, 0.15);

    color: #2ecc71;

    border: 1px solid rgba(46, 204, 113, 0.4);
}
.status-pending {

    background: rgba(243, 156, 18, 0.15);

    color: #f39c12;

    border: 1px solid rgba(243, 156, 18, 0.4);
}

.status-processing {

    background: rgba(52, 152, 219, 0.15);

    color: #3498db;

    border: 1px solid rgba(52, 152, 219, 0.4);
}

.status-shipped {

    background: rgba(142, 68, 173, 0.15);

    color: #8e44ad;

    border: 1px solid rgba(142, 68, 173, 0.4);
}



.language-switcher {
    display: flex;
    gap: 0.5rem;
}

.lang-btn {
    padding: 0.3rem 0.6rem;
    border: 1px solid var(--border-color);
    background: transparent;
    color: var(--text-secondary);
    cursor: pointer;
    border-radius: 4px;
    transition: var(--transition);
}

.lang-btn:hover,
.lang-btn.active {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

/* User Dropdown */
.user-menu {
    position: relative;
}

.dropdown {
    position: absolute;
    top: 100%;
    right: 0;
    background: var(--bg-light);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 0.5rem 0;
    min-width: 150px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: var(--transition);
}

.user-menu:hover .dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown a {
    display: block;
    padding: 0.75rem 1rem;
    color: var(--text-secondary);
    text-decoration: none;
    transition: var(--transition);
}

.dropdown a:hover {
    background: var(--bg-gray);
    color: var(--primary-color);
}

.hidden {
    display: none !important;
}

/* Mobile Toggle */
.mobile-toggle {
    display: none;
    font-size: 1.5rem;
    cursor: pointer;
}

/* Search Bar */
.search-bar {
    display: none;
    padding: 1rem 0;
    position: relative;
}

.search-bar.active {
    display: block;
}

.search-bar input {
    width: 100%;
    padding: 0.75rem 3rem 0.75rem 1rem;
    background: var(--bg-light);
    border: 1px solid var(--border-color);
    border-radius: 25px;
    color: var(--text-primary);
    font-size: 1rem;
}

.search-btn {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    background: transparent;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    padding: 0.5rem;
}

.search-suggestions {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--bg-light);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    margin-top: 0.5rem;
    max-height: 300px;
    overflow-y: auto;
    display: none;
}

.search-suggestions.active {
    display: block;
}

.suggestion-item {
    padding: 0.75rem 1rem;
    cursor: pointer;
    transition: var(--transition);
    border-bottom: 1px solid var(--border-color);
}

.suggestion-item:last-child {
    border-bottom: none;
}

.suggestion-item:hover {
    background: var(--bg-gray);
}

/* Hero Section */
.hero {
    position: relative;
    background: linear-gradient(135deg, var(--bg-gray) 0%, var(--bg-dark) 100%);
    background-image: url('image1.png');
    background-size: cover;
    background-position: center;
    padding: 8rem 0 6rem;
    text-align: center;
    animation: fadeInUp 1s ease;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(0,0,0,0.9) 0%, rgba(26,26,26,0.95) 100%);
}

.hero-content {
    position: relative;
    z-index: 1;
}

.hero-title {
    font-size: 3rem;
    font-weight: bold;
    margin-bottom: 1rem;
    animation: fadeInUp 1s ease;
}

.hero-subtitle {
    font-size: 1.25rem;
    color: var(--text-secondary);
    margin-bottom: 2rem;
    animation: fadeInUp 1s ease 0.2s both;
}

.hero-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
    animation: fadeInUp 1s ease 0.4s both;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.875rem 2rem;
    border-radius: 25px;
    text-decoration: none;
    font-weight: 600;
    transition: var(--transition);
    cursor: pointer;
    border: none;
    font-size: 1rem;
}

.btn-primary {
    background: var(--primary-color);
    color: white;
}

.btn-primary:hover {
    background: #cc0000;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(255, 0, 0, 0.3);
}

.btn-outline {
    background: transparent;
    color: var(--text-primary);
    border: 2px solid var(--chrome-silver);
}

.btn-outline:hover {
    background: var(--chrome-silver);
    color: var(--bg-dark);
    transform: translateY(-2px);
}

.btn-block {
    width: 100%;
    justify-content: center;
}

/* Sections */
.section-title {
    font-size: 2.5rem;
    text-align: center;
    margin-bottom: 3rem;
    position: relative;
    padding-bottom: 1rem;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 3px;
    background: var(--primary-color);
}

.categories-section,
.featured-section,
.best-sellers-section,
.new-arrivals-section,
.features-section {
    padding: 4rem 0;
}

/* Categories Grid */
.categories-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.category-card {
    background: var(--bg-light);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 2rem;
    text-align: center;
    transition: var(--transition);
    cursor: pointer;
}

.category-card:hover {
    transform: translateY(-5px);
    border-color: var(--primary-color);
    box-shadow: 0 10px 30px var(--shadow);
}

.category-card i {
    font-size: 3rem;
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.category-card h3 {
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
}

.category-card p {
    color: var(--text-muted);
    font-size: 0.9rem;
}

/* Products Grid */
.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 2rem;
}

.product-card {
    background: var(--bg-light);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    overflow: hidden;
    transition: var(--transition);
    position: relative;
}

.product-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 40px var(--shadow);
    border-color: var(--primary-color);
}

.product-image {
    position: relative;
    overflow: hidden;
    height: 250px;
    background: var(--bg-gray);
}

.product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}

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

.product-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    background: var(--primary-color);
    color: white;
    padding: 0.3rem 0.75rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: bold;
}

.product-badge.new {
    background: #00ff00;
    color: #000;
}

.product-badge.sale {
    background: var(--primary-color);
}

.product-actions {
    position: absolute;
    top: 10px;
    left: 10px;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    opacity: 0;
    transition: var(--transition);
}

.product-card:hover .product-actions {
    opacity: 1;
}

.wishlist-btn,
.quickview-btn {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: white;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
    color: var(--bg-dark);
}

.wishlist-btn:hover,
.quickview-btn:hover {
    background: var(--primary-color);
    color: white;
    transform: scale(1.1);
}

.product-info {
    padding: 1.5rem;
}

.product-category {
    color: var(--text-muted);
    font-size: 0.85rem;
    text-transform: uppercase;
}

.product-title {
    font-size: 1.125rem;
    margin: 0.5rem 0;
    color: var(--text-primary);
}

.product-title a {
    color: inherit;
    text-decoration: none;
    transition: var(--transition);
}

.product-title a:hover {
    color: var(--primary-color);
}

.product-rating {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.75rem;
}

.stars {
    color: #ffa500;
}

.rating-count {
    color: var(--text-muted);
    font-size: 0.85rem;
}

.product-price {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1rem;
}

.current-price {
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--primary-color);
}

.old-price {
    font-size: 1rem;
    color: var(--text-muted);
    text-decoration: line-through;
}

.product-stock {
    font-size: 0.85rem;
    margin-bottom: 1rem;
}

.in-stock {
    color: #00ff00;
}

.out-of-stock {
    color: var(--primary-color);
}

.add-to-cart-btn {
    width: 100%;
}

/* Features Grid */
.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.feature-card {
    text-align: center;
    padding: 2rem;
    background: var(--bg-light);
    border-radius: 12px;
    border: 1px solid var(--border-color);
    transition: var(--transition);
}

.feature-card:hover {
    transform: translateY(-5px);
    border-color: var(--primary-color);
}

.feature-card i {
    font-size: 3rem;
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.feature-card h3 {
    margin-bottom: 0.5rem;
}

.feature-card p {
    color: var(--text-muted);
}

/* Footer */
.footer {
    background: var(--bg-gray);
    border-top: 1px solid var(--border-color);
    padding: 4rem 0 2rem;
    margin-top: 4rem;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 3rem;
    margin-bottom: 3rem;
}

.footer-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.5rem;
    font-weight: bold;
    margin-bottom: 1rem;
}

.footer-logo i {
    color: var(--primary-color);
    font-size: 2rem;
}

.footer-desc {
    color: var(--text-muted);
    margin-bottom: 1rem;
}

.social-links {
    display: flex;
    gap: 1rem;
}

.social-links a {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--bg-light);
    border: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-secondary);
    transition: var(--transition);
}

.social-links a:hover {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
    transform: translateY(-3px);
}

.footer-col h4 {
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.footer-col ul {
    list-style: none;
}

.footer-col ul li {
    margin-bottom: 0.75rem;
}

.footer-col ul li a {
    color: var(--text-muted);
    text-decoration: none;
    transition: var(--transition);
}

.footer-col ul li a:hover {
    color: var(--primary-color);
    padding-left: 5px;
}

.contact-info li {
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--text-muted);
}

.contact-info i {
    color: var(--primary-color);
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid var(--border-color);
    color: var(--text-muted);
}

/* Floating Buttons */
.whatsapp-float {
    position: fixed;
    bottom: 80px;
    right: 20px;
    width: 60px;
    height: 60px;
    background: #25D366;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 2rem;
    box-shadow: 0 5px 20px rgba(37, 211, 102, 0.5);
    transition: var(--transition);
    z-index: 999;
}

.whatsapp-float:hover {
    transform: scale(1.1);
    box-shadow: 0 8px 30px rgba(37, 211, 102, 0.7);
}

.back-to-top {
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 50px;
    height: 50px;
    background: var(--primary-color);
    border: none;
    border-radius: 50%;
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
    z-index: 999;
}

.back-to-top.visible {
    opacity: 1;
    visibility: visible;
}

.back-to-top:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 20px rgba(255, 0, 0, 0.5);
}

/* Toast Notification */
.toast {
    position: fixed;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%) translateY(100px);
    background: var(--bg-light);
    color: var(--text-primary);
    padding: 1rem 2rem;
    border-radius: 8px;
    box-shadow: 0 5px 20px var(--shadow);
    z-index: 9999;
    opacity: 0;
    transition: var(--transition);
    border: 1px solid var(--border-color);
}

.toast.show {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

.toast.success {
    border-left: 4px solid #00ff00;
}

.toast.error {
    border-left: 4px solid var(--primary-color);
}

/* Auth Pages */
.auth-section {
    min-height: calc(100vh - 300px);
    display: flex;
    align-items: center;
    padding: 4rem 0;
}

.auth-container {
    max-width: 500px;
    margin: 0 auto;
    width: 100%;
}

.auth-box {
    background: var(--bg-light);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 3rem;
}

.auth-header {
    text-align: center;
    margin-bottom: 2rem;
}

.auth-header i {
    font-size: 4rem;
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.auth-header h2 {
    margin-bottom: 0.5rem;
}

.auth-header p {
    color: var(--text-muted);
}

.auth-form .form-group {
    margin-bottom: 1.5rem;
}

.auth-form label {
    display: block;
    margin-bottom: 0.5rem;
    color: var(--text-secondary);
}

.input-group {
    position: relative;
}

.input-group i {
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
}

.input-group input {
    width: 100%;
    padding: 0.875rem 1rem 0.875rem 3rem;
    background: var(--bg-gray);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    color: var(--text-primary);
    font-size: 1rem;
    transition: var(--transition);
}

.input-group input:focus {
    outline: none;
    border-color: var(--primary-color);
}

.toggle-password {
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    background: transparent;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
}

.form-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
}

.forgot-link {
    color: var(--primary-color);
    text-decoration: none;
}

.auth-divider {
    text-align: center;
    margin: 1.5rem 0;
    position: relative;
}

.auth-divider::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 1px;
    background: var(--border-color);
}

.auth-divider span {
    background: var(--bg-light);
    padding: 0 1rem;
    position: relative;
    color: var(--text-muted);
}

.demo-credentials {
    background: var(--bg-gray);
    padding: 1rem;
    border-radius: 8px;
    margin: 1rem 0;
    border: 1px solid var(--border-color);
}

.demo-credentials p {
    margin: 0.5rem 0;
    font-size: 0.9rem;
}

.auth-footer {
    text-align: center;
    margin-top: 2rem;
    color: var(--text-muted);
}

.auth-footer a {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 600;
}

/* Page Header */
.page-header {
    background: var(--bg-gray);
    border-bottom: 1px solid var(--border-color);
    padding: 3rem 0;
    text-align: center;
}

.page-header h1 {
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
}

.page-header p {
    color: var(--text-muted);
    font-size: 1.125rem;
}

/* Products Page */
.products-page {
    padding: 3rem 0;
}

.products-layout {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 3rem;
}

.filters-sidebar {
    background: var(--bg-light);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 2rem;
    height: fit-content;
    position: sticky;
    top: 100px;
}

.filter-group {
    margin-bottom: 2rem;
}

.filter-group h3 {
    margin-bottom: 1rem;
    font-size: 1.125rem;
}

.filter-options label {
    display: block;
    margin-bottom: 0.75rem;
}

.price-range input {
    width: 100%;
    margin-bottom: 0.5rem;
}

.price-values {
    display: flex;
    justify-content: space-between;
    color: var(--text-muted);
    font-size: 0.9rem;
}

.products-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border-color);
}

.products-sort select {
    padding: 0.5rem 1rem;
    background: var(--bg-light);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    color: var(--text-primary);
    cursor: pointer;
}

/* Cart Page */
.cart-page {
    padding: 3rem 0;
}

.cart-layout {
    display: grid;
    grid-template-columns: 1fr 400px;
    gap: 3rem;
}

.cart-item {
    display: flex;
    gap: 2rem;
    padding: 2rem;
    background: var(--bg-light);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    margin-bottom: 1.5rem;
}

.cart-item-image {
    width: 120px;
    height: 120px;
    border-radius: 8px;
    overflow: hidden;
}

.cart-item-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.cart-item-details {
    flex: 1;
}

.cart-item-title {
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
}

.cart-item-price {
    color: var(--primary-color);
    font-size: 1.125rem;
    font-weight: bold;
    margin-bottom: 1rem;
}

.cart-item-actions {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.quantity-control {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.quantity-control button {
    width: 30px;
    height: 30px;
    border-radius: 4px;
    border: 1px solid var(--border-color);
    background: var(--bg-gray);
    color: var(--text-primary);
    cursor: pointer;
    transition: var(--transition);
}

.quantity-control button:hover {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

.remove-item {
    color: var(--primary-color);
    cursor: pointer;
    padding: 0.5rem;
    transition: var(--transition);
}

.remove-item:hover {
    color: #cc0000;
}

.cart-summary {
    background: var(--bg-light);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 2rem;
    height: fit-content;
    position: sticky;
    top: 100px;
}

.cart-summary h3 {
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border-color);
}

.summary-row {
    display: flex;
    justify-content: space-between;
    margin-bottom: 1rem;
    color: var(--text-secondary);
}

.summary-total {
    display: flex;
    justify-content: space-between;
    font-size: 1.25rem;
    font-weight: bold;
    padding-top: 1rem;
    margin-top: 1rem;
    border-top: 2px solid var(--border-color);
}

.empty-cart {
    text-align: center;
    padding: 4rem 2rem;
}

.empty-cart i {
    font-size: 5rem;
    color: var(--text-muted);
    margin-bottom: 1rem;
}

/* Checkout Page */
.checkout-page {
    padding: 3rem 0;
}

.checkout-layout {
    display: grid;
    grid-template-columns: 1fr 400px;
    gap: 3rem;
}

.checkout-form {
    background: var(--bg-light);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 2rem;
}

.checkout-section {
    margin-bottom: 2rem;
    padding-bottom: 2rem;
    border-bottom: 1px solid var(--border-color);
}

.checkout-section:last-child {
    border-bottom: none;
}

.checkout-section h3 {
    margin-bottom: 1.5rem;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

.form-group {
    margin-bottom: 1rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    color: var(--text-secondary);
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 0.75rem;
    background: var(--bg-gray);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    color: var(--text-primary);
    font-size: 1rem;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--primary-color);
}

.payment-option {
    display: block;
    padding: 1rem;
    margin-bottom: 1rem;
    background: var(--bg-gray);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    cursor: pointer;
    transition: var(--transition);
}

.payment-option:hover {
    border-color: var(--primary-color);
}

.payment-option input {
    margin-right: 0.75rem;
}

.checkout-summary {
    background: var(--bg-light);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 2rem;
    height: fit-content;
    position: sticky;
    top: 100px;
}

/* Success Page */
.success-page {
    min-height: calc(100vh - 300px);
    display: flex;
    align-items: center;
    padding: 4rem 0;
}

.success-box {
    text-align: center;
    max-width: 600px;
    margin: 0 auto;
    background: var(--bg-light);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 4rem 3rem;
}

.success-icon {
    font-size: 5rem;
    color: #00ff00;
    margin-bottom: 2rem;
}

.success-box h1 {
    margin-bottom: 1rem;
    color: #00ff00;
}

.success-box p {
    color: var(--text-muted);
    margin-bottom: 1rem;
}

.success-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
    margin-top: 2rem;
}

/* Profile Pages */
.profile-page,
.orders-page {
    padding: 3rem 0;
}

.profile-layout {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 3rem;
}

.profile-sidebar {
    background: var(--bg-light);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 2rem;
    height: fit-content;
    position: sticky;
    top: 100px;
}

.profile-menu a {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem;
    color: var(--text-secondary);
    text-decoration: none;
    border-radius: 8px;
    margin-bottom: 0.5rem;
    transition: var(--transition);
}

.profile-menu a:hover,
.profile-menu a.active {
    background: var(--bg-gray);
    color: var(--primary-color);
}

.profile-card {
    background: var(--bg-light);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 2rem;
    margin-bottom: 2rem;
}

.profile-card h3 {
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border-color);
}

.order-card {
    background: var(--bg-light);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 2rem;
    margin-bottom: 1.5rem;
}

.order-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border-color);
}

.order-status {
    padding: 0.3rem 0.75rem;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: bold;
}

.order-status.pending {
    background: #ffa500;
    color: #000;
}

.order-status.processing {
    background: #00bfff;
    color: #000;
}

.order-status.shipped {
    background: #9370db;
    color: #fff;
}

.order-status.delivered {
    background: #00ff00;
    color: #000;
}

/* Error Page */
.error-page {
    min-height: calc(100vh - 300px);
    display: flex;
    align-items: center;
    padding: 4rem 0;
}

.error-content {
    text-align: center;
    max-width: 600px;
    margin: 0 auto;
}

.error-content h1 {
    font-size: 8rem;
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.error-content h2 {
    font-size: 2rem;
    margin-bottom: 1rem;
}

.error-content p {
    color: var(--text-muted);
    margin-bottom: 2rem;
}

.error-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
}

/* Admin Styles */
.admin-body {
    background: var(--bg-dark);
}

.admin-container {
    display: grid;
    grid-template-columns: 250px 1fr;
    min-height: 100vh;
}

.admin-sidebar {
    background: var(--bg-gray);
    border-right: 1px solid var(--border-color);
    padding: 2rem 0;
}

.admin-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 0 2rem;
    margin-bottom: 2rem;
    font-size: 1.5rem;
    font-weight: bold;
}

.admin-logo i {
    color: var(--primary-color);
    font-size: 2rem;
}

.admin-menu a {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem 2rem;
    color: var(--text-secondary);
    text-decoration: none;
    transition: var(--transition);
}

.admin-menu a:hover,
.admin-menu a.active {
    background: var(--bg-light);
    color: var(--primary-color);
    border-left: 3px solid var(--primary-color);
}

.admin-main {
    background: var(--bg-dark);
    padding: 2rem;
}

.admin-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border-color);
}

.admin-user {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    color: var(--text-secondary);
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-bottom: 3rem;
}

.stat-card {
    background: var(--bg-light);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 2rem;
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.stat-icon {
    width: 60px;
    height: 60px;
    border-radius: 12px;
    background: var(--primary-color);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    color: white;
}

.stat-details h3 {
    font-size: 2rem;
    margin-bottom: 0.25rem;
}

.stat-details p {
    color: var(--text-muted);
}

.admin-section {
    background: var(--bg-light);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 2rem;
    margin-bottom: 2rem;
}

.admin-search {
    position: relative;
    margin-bottom: 2rem;
}

.admin-search input {
    width: 100%;
    padding: 0.75rem 1rem 0.75rem 3rem;
    background: var(--bg-gray);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    color: var(--text-primary);
}

.admin-search i {
    position: absolute;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
}

.admin-table-container {
    overflow-x: auto;
}

.admin-table {
    width: 100%;
    border-collapse: collapse;
}

.admin-table th,
.admin-table td {
    padding: 1rem;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
}

.admin-table th {
    background: var(--bg-gray);
    color: var(--text-secondary);
    font-weight: 600;
}

.admin-table tr:hover {
    background: var(--bg-gray);
}

.admin-actions {
    display: flex;
    gap: 0.5rem;
}

.edit-btn,
.delete-btn {
    padding: 0.5rem 1rem;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: var(--transition);
}

.edit-btn {
    background: #00bfff;
    color: white;
}

.edit-btn:hover {
    background: #0099cc;
}

.delete-btn {
    background: var(--primary-color);
    color: white;
}

.delete-btn:hover {
    background: #cc0000;
}

/* Modal */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.8);
    z-index: 10000;
    align-items: center;
    justify-content: center;
}

.modal.active {
    display: flex;
}

.modal-content {
    background: var(--bg-light);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    max-width: 600px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 2rem;
    border-bottom: 1px solid var(--border-color);
}

.modal-close {
    background: transparent;
    border: none;
    font-size: 2rem;
    color: var(--text-secondary);
    cursor: pointer;
    transition: var(--transition);
}

.modal-close:hover {
    color: var(--primary-color);
}

.modal-content form {
    padding: 2rem;
}

/* Animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in {
    animation: fadeInUp 0.6s ease;
}

/* Loading Skeleton */
.skeleton {
    background: linear-gradient(90deg, var(--bg-light) 25%, var(--bg-gray) 50%, var(--bg-light) 75%);
    background-size: 200% 100%;
    animation: loading 1.5s infinite;
}

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

/* Responsive Design */
@media (max-width: 1024px) {
    .products-layout,
    .cart-layout,
    .checkout-layout,
    .profile-layout {
        grid-template-columns: 1fr;
    }

    .filters-sidebar,
    .cart-summary,
    .checkout-summary,
    .profile-sidebar {
        position: static;
    }
}

@media (max-width: 768px) {
    .nav {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: var(--bg-light);
        border-top: 1px solid var(--border-color);
    }

    .nav.active {
        display: block;
    }

    .nav-list {
        flex-direction: column;
        padding: 1rem 0;
    }

    .mobile-toggle {
        display: block;
    }

    .hero-title {
        font-size: 2rem;
    }

    .products-grid {
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    }

    .cart-item {
        flex-direction: column;
    }

    .admin-container {
        grid-template-columns: 1fr;
    }

    .admin-sidebar {
        display: none;
    }

    .stats-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .hero-buttons {
        flex-direction: column;
        width: 100%;
    }

    .btn {
        width: 100%;
    }

    .products-grid {
        grid-template-columns: 1fr;
    }
    

    /* ========================================
   FINAL THEME FIXES
======================================== */

/* BODY THEME */

body[data-theme="dark"] {

    background-color: var(--bg-dark);
    color: var(--text-primary);
}

body[data-theme="light"] {

    background-color: #f5f5f5;
    color: #1a1a1a;
}

/* HEADER */

body[data-theme="light"] .header {

    background: #ffffff;
    border-color: #e0e0e0;
}

/* CARDS */

body[data-theme="light"] .product-card,
body[data-theme="light"] .profile-card,
body[data-theme="light"] .cart-summary,
body[data-theme="light"] .checkout-summary,
body[data-theme="light"] .auth-box,
body[data-theme="light"] .admin-section,
body[data-theme="light"] .admin-sidebar,
body[data-theme="light"] .filters-sidebar,
body[data-theme="light"] .modal-content,
body[data-theme="light"] .category-card,
body[data-theme="light"] .feature-card,
body[data-theme="light"] .order-card,
body[data-theme="light"] .cart-item {

    background: #ffffff;
    border-color: #dddddd;
}

/* INPUTS */

body[data-theme="light"] input,
body[data-theme="light"] textarea,
body[data-theme="light"] select {

    background: #ffffff;
    color: #111111;
    border-color: #dddddd;
}

/* LINKS */

body[data-theme="light"] a {

    color: #1a1a1a;
}

/* DROPDOWN */

body[data-theme="light"] .dropdown {

    background: #ffffff;
}

/* FOOTER */

body[data-theme="light"] .footer {

    background: #ffffff;
    border-color: #dddddd;
}

/* TABLE */

body[data-theme="light"] .admin-table th {

    background: #f5f5f5;
    color: #111111;
}

/* RTL */

[dir="rtl"] {

    direction: rtl;
    text-align: right;
}

/* RTL FLEX */

[dir="rtl"] .header-content,
[dir="rtl"] .header-actions,
[dir="rtl"] .nav-list,
[dir="rtl"] .product-actions,
[dir="rtl"] .cart-item-actions,
[dir="rtl"] .form-row,
[dir="rtl"] .profile-menu a,
[dir="rtl"] .admin-menu a,
[dir="rtl"] .products-toolbar,
[dir="rtl"] .order-header {

    direction: rtl;
}

/* RTL INPUT ICON */

[dir="rtl"] .input-group i {

    left: auto;
    right: 15px;
}

/* RTL INPUT */

[dir="rtl"] .input-group input {

    padding-left: 1rem;
    padding-right: 3rem;
}

/* RTL PASSWORD BUTTON */

[dir="rtl"] .toggle-password {

    right: auto;
    left: 15px;
}

/* RTL DROPDOWN */

[dir="rtl"] .dropdown {

    right: auto;
    left: 0;
}

/* RTL BADGE */

[dir="rtl"] .badge {

    right: auto;
    left: -8px;
}

/* RTL SEARCH */

[dir="rtl"] .search-btn {

    right: auto;
    left: 10px;
}

/* RTL SEARCH INPUT */

[dir="rtl"] .search-bar input {

    padding-right: 1rem;
    padding-left: 3rem;
}

/* RTL MOBILE */

@media (max-width: 768px) {

    [dir="rtl"] .nav {

        text-align: right;
    }

    [dir="rtl"] .nav-list {

        align-items: flex-end;
    }
}

/* TRANSITIONS */

body,
.header,
.footer,
.product-card,
.profile-card,
.cart-summary,
.checkout-summary,
.auth-box,
.admin-section,
.admin-sidebar,
.filters-sidebar,
.modal-content,
.category-card,
.feature-card,
input,
textarea,
select {

    transition:
        background 0.3s ease,
        color 0.3s ease,
        border 0.3s ease;
}

/* ACTIVE LANGUAGE */

.lang-btn.active {

    background: var(--primary-color);
    color: #ffffff;
    border-color: var(--primary-color);
}

/* THEME BUTTON */

.theme-toggle {

    user-select: none;
}

/* RTL PRODUCT INFO */

[dir="rtl"] .product-info,
[dir="rtl"] .product-details-info,
[dir="rtl"] .profile-content,
[dir="rtl"] .checkout-form,
[dir="rtl"] .cart-summary {

    text-align: right;
}
}
