:root {
    --primary-color: #000000;
    --secondary-color: #ffffff;
    --accent-color: #f8f9fa;
    --gold-color: #000000;
    --text-dark: #000000;
    --text-light: #666666;
    --gradient-primary: linear-gradient(135deg, #000000 0%, #1a1a1a 100%);
    --gradient-gold: linear-gradient(135deg, #000000 0%, #333333 100%);
    --shadow-soft: 0 10px 40px rgba(0, 0, 0, 0.1);
    --shadow-medium: 0 20px 60px rgba(0, 0, 0, 0.15);
    --border-color: #e0e0e0;
    --hover-color: #f5f5f5;
    --background-color: #ffffff;
    --glass-background: rgba(255, 255, 255, 0.25);
    --glass-background-dark: rgba(255, 255, 255, 0.15);
    --glass-border: 1px solid rgba(0, 0, 0, 0.1);
    --card-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.1);
    --text-color: #333333;
    --bg-light: #f8f9fa;
    --shadow: 0 0 20px rgba(0,0,0,0.1);
}

body {
    background: linear-gradient(135deg, var(--background-color), #fff);
    min-height: 100vh;
    font-family: 'Tajawal', 'Poppins', sans-serif;
}

.glass-effect {
    background: var(--glass-background);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    border-radius: 10px;
    border: var(--glass-border);
    box-shadow: var(--card-shadow);
}

/* Section Header */
.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

.section-header h2 {
    color: var(--text-color);
    font-weight: 600;
    margin: 0;
}

.glass-select {
    background: var(--glass-background);
    border: var(--glass-border);
    color: var(--text-color);
    max-width: 200px;
}

/* Filter Sidebar */
.filter-sidebar {
    padding: 20px;
}

.filter-container {
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(10px);
    border-radius: 15px;
    padding: 25px;
    border: 1px solid rgba(0, 0, 0, 0.15);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}



.filter-container h3 {
    color: var(--primary-color);
    font-weight: 600;
    font-size: 1.5rem;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 2px solid rgba(0, 0, 0, 0.1);
}

.filter-section {
    margin-bottom: 30px;
}

.filter-section h4 {
    color: var(--primary-color);
    margin-bottom: 15px;
    font-size: 1.2rem;
    font-weight: 600;
    position: relative;
    display: inline-block;
}


/* Filter Checkboxes */
.form-check-input {
    width: 20px;
    height: 20px;
    margin-top: 0.2rem;
    background-color: #fff;
    border: 2px solid rgba(0, 146, 69, 0.3);
    cursor: pointer;
    transition: all 0.2s ease;
}

.form-check-input:checked {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
}

.form-check-label {
    font-size: 1rem;
    color: var(--text-color);
    cursor: pointer;
    padding: 5px 0;
    transition: all 0.2s ease;
}

.form-check-label:hover {
    color: var(--primary-color);
}

.category-item {
    transition: all 0.2s ease;
    padding: 5px 10px;
    border-radius: 8px;
}

.category-item:hover {
    background-color: rgba(0, 146, 69, 0.05);
}

.badge.bg-primary {
    background-color: var(--primary-color) !important;
    font-weight: 500;
    font-size: 0.8rem;
    padding: 5px 10px;
    color: white;
}

/* Price Range */
.form-range {
    height: 8px;
    background: rgba(0, 146, 69, 0.1);
    border-radius: 5px;
    cursor: pointer;
}

.form-range::-webkit-slider-thumb {
    width: 20px;
    height: 20px;
    background: var(--primary-color);
    border: 2px solid #fff;
    box-shadow: 0 0 5px rgba(0, 0, 0, 0.2);
    cursor: pointer;
}

/* Reset Filter Button */
#resetFiltersBtn {
    display: inline-flex;
    align-items: center;
    padding: 8px 16px;
    background-color: rgba(0, 146, 69, 0.08);
    color: var(--primary-color);
    border: 1px solid rgba(0, 146, 69, 0.2);
    border-radius: 10px;
    transition: all 0.3s ease;
    font-weight: 500;
}

#resetFiltersBtn:hover {
    background-color: var(--primary-color);
    color: white;
    transform: translateY(-3px);
    box-shadow: 0 4px 10px rgba(0, 146, 69, 0.15);
}

/* Sort Select */
#sortSelect {
    border-color: rgba(0, 146, 69, 0.2);
    color: var(--text-color);
    padding: 8px 16px;
    border-radius: 10px;
    background-color: rgba(255, 255, 255, 0.8);
    transition: all 0.3s ease;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.03);
}

#sortSelect:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(0, 146, 69, 0.1);
}

/* Product Card */
.product-card {
    background: var(--glass-background);
    border-radius: 20px;
    border: var(--glass-border);
    overflow: hidden;

    height: 100%;
    position: relative;
    cursor: pointer;
}



.product-image-wrapper {
    position: relative;
    padding-top: 100%;
    overflow: hidden;
    display: block;
    border-radius: 8px 8px 0 0;
    background: #f8f9fa;
}

.product-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.product-details {
    padding: 1.5rem;
    position: relative;
    z-index: 1;
}

.product-category {
    font-size: 0.85rem;
    color: var(--text-light);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 0.5rem;
}

.product-title {
    color: var(--text-color);
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 0.75rem;
}

.product-price {
    font-size: 1.3rem;
    color: var(--primary-color);
    font-weight: bold;
    margin-bottom: 1rem;
}

.product-actions {
    display: flex;
    gap: 0.5rem;
}

.add-to-cart-btn {
    flex: 1;
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: 12px;
    padding: 0.75rem;
    font-weight: 500;
    transition: all 0.3s ease;
}

.add-to-cart-btn:hover {
    background: var(--secondary-color);
    transform: translateY(-2px);
}

.view-details-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 8px;
    background: var(--glass-background);
    color: var(--primary-color);
    border: 2px solid rgba(74, 58, 255, 0.2);
    box-shadow: var(--card-shadow);
}



/* Modern Shopping Cart Sidebar Redesign */
.cart-sidebar {
    position: fixed;
    top: 0;
    right: -100%;
    width: 100%;
    height: 100vh;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.95), rgba(255, 255, 255, 0.98));
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    z-index: 1050;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    flex-direction: column;
    box-shadow: -10px 0 30px rgba(0, 0, 0, 0.1);
    border-left: 1px solid rgba(0, 146, 69, 0.1);
    overflow: hidden; /* Hide overflow to prevent double scrollbars */
}

@media (min-width: 768px) {
    .cart-sidebar {
        width: 450px;
        border-radius: 30px 0 0 30px;
    }
}

.cart-sidebar.active {
    right: 0;
    transform: translateX(0);
}

body.cart-open {
    overflow: hidden;
}

/* Cart Overlay */
.cart-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    z-index: 1040;
    transition: opacity 0.3s ease;
    opacity: 0;
}

.cart-overlay.active {
    display: block;
    opacity: 1;
}

/* Cart Header */
.cart-header {
    padding: 20px 25px;
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(0, 146, 69, 0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.03);
    flex-shrink: 0; /* Prevent header from shrinking */
}

.cart-header h3 {
    margin: 0;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-color);
    display: flex;
    align-items: center;
}

.cart-header h3::before {
    content: '\f07a';
    font-family: 'Font Awesome 5 Free';
    margin-left: 10px;
    font-weight: 900;
    background: rgba(0, 146, 69, 0.1);
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
}

.close-cart {
    background: rgba(255, 255, 255, 0.9);
    border: none;
    color: #666666;
    font-size: 1.2rem;
    cursor: pointer;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.05);
    border: 1px solid rgba(0, 0, 0, 0.05);
}

.close-cart:hover {
    color: #ff5555;
    background-color: rgba(255, 85, 85, 0.1);
    transform: rotate(90deg);
}

/* Cart Items Container */
.cart-items-container {
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
    position: relative;
    display: flex;
    flex-direction: column;
    min-height: 0; /* Important for flexbox scrolling */
    /* Enable smooth scrolling on mobile */
    -webkit-overflow-scrolling: touch;
}

/* Cart Items */
.cart-items {
    flex: 1;
    overflow: visible; /* Remove individual scrolling */
    padding: 20px;
    background: transparent;
    min-height: 0; /* Important for flexbox scrolling */
}

/* Hide scrollbar for WebKit browsers (Chrome, Safari, Edge) on desktop */
@media (min-width: 768px) {
    .cart-items-container::-webkit-scrollbar {
        display: none;
    }
}

/* Show scrollbar only on mobile */
@media (max-width: 767px) {
    .cart-items-container::-webkit-scrollbar {
        width: 6px;
    }

    .cart-items-container::-webkit-scrollbar-track {
        background: rgba(0, 146, 69, 0.1);
        border-radius: 10px;
        margin: 5px 0;
    }

    .cart-items-container::-webkit-scrollbar-thumb {
        background-color: var(--primary-color);
        border-radius: 10px;
        border: 2px solid rgba(255, 255, 255, 0.3);
    }

    .cart-items-container::-webkit-scrollbar-thumb:hover {
        background-color: #333;
    }
}

/* Cart Item */
.cart-item {
    background: #fff;
    border-radius: 20px;
    margin-bottom: 15px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.03);
    position: relative;
    overflow: hidden;
    border: 1px solid rgba(0, 146, 69, 0.08);
    transition: all 0.3s ease;
}

.cart-item:last-child {
    margin-bottom: 0;
}

/* Remove Button */
.remove-btn {
    position: absolute;
    left: 15px;
    top: 15px;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.9);
    border: 1px solid rgba(255, 85, 85, 0.3);
    color: #ff5555;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    opacity: 1;
    transform: scale(1);
    transition: all 0.3s ease;
    z-index: 10;
    box-shadow: 0 3px 10px rgba(255, 85, 85, 0.1);
}

/* Cart Item Inner */
.cart-item-inner {
    position: relative;
    padding: 20px;
    display: flex;
    gap: 15px;
    align-items: center;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

.cart-item-image {
    width: 100px;
    height: 100px;
    object-fit: cover;
    border-radius: 15px;
    flex-shrink: 0;
    border: 2px solid rgba(0, 146, 69, 0.1);
    background: white;
    padding: 3px;
    transition: all 0.3s ease;
}

.cart-item-details {
    flex: 1;
    min-width: 0;
    padding: 10px;
    background: rgba(255, 255, 255, 0.8);
    border-radius: 15px;
    border: 1px solid rgba(0, 146, 69, 0.05);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.cart-item-title {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-color);
    margin-bottom: 10px;
    transition: all 0.3s ease;
}

.cart-item-variants {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 0.5rem;
}

.variant-tag {
    background-color: rgba(0, 146, 69, 0.1);
    color: var(--primary-color);
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    font-size: 0.8rem;
}

.cart-item-price {
    font-size: 1.2rem;
    color: var(--primary-color);
    font-weight: 700;
    margin-bottom: 15px;
    background: rgba(0, 146, 69, 0.05);
    padding: 5px 15px;
    border-radius: 30px;
    display: inline-block;
}

/* Cart Footer */
.cart-footer {
    padding: 25px;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-top: 1px solid rgba(0, 146, 69, 0.1);
    box-shadow: 0 -5px 20px rgba(0, 0, 0, 0.03);
    flex-shrink: 0; /* Prevent footer from shrinking */
    margin-top: auto; /* Push footer to bottom */
    position: sticky;
    bottom: 0;
    z-index: 10;
}

.cart-total {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding: 15px 20px;
    background: white;
    border-radius: 15px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.03);
    border: 1px solid rgba(0, 146, 69, 0.08);
}

.cart-total span:first-child {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-color);
}

.cart-total span:last-child {
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--primary-color);
}

.checkout-btn {
    display: block;
    width: 100%;
    padding: 18px 20px;
    background: linear-gradient(135deg, #000000 0%, #333333 100%);
    color: #fff;
    text-align: center;
    border-radius: 20px;
    text-decoration: none;
    font-weight: 700;
    font-size: 1.2rem;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    border: 2px solid transparent;
    position: relative;
    overflow: hidden;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    letter-spacing: 0.5px;
}

.checkout-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    transition: all 0.6s ease;
}

.checkout-btn:hover {
    background: linear-gradient(135deg, #333333 0%, #000000 100%);
    transform: translateY(-3px);
    color: #fff;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.3);
    border-color: rgba(255, 255, 255, 0.2);
}

.checkout-btn:hover::before {
    left: 100%;
}

.checkout-btn:active {
    transform: translateY(-1px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
}

.checkout-btn i {
    font-size: 1.3rem;
    transition: transform 0.3s ease;
}

.checkout-btn:hover i {
    transform: scale(1.1);
}

/* Empty Cart State */
.cart-empty {
    text-align: center;
    padding: 50px 30px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 100%;
    flex: 1;
}

.cart-empty i {
    font-size: 5rem;
    color: rgba(0, 146, 69, 0.1);
    margin-bottom: 20px;
    background: rgba(0, 146, 69, 0.05);
    width: 120px;
    height: 120px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px dashed rgba(0, 146, 69, 0.2);
}

.cart-empty p {
    color: var(--text-light);
    font-size: 1.2rem;
    margin-bottom: 30px;
    max-width: 300px;
}

.cart-empty .btn {
    background: var(--primary-color);
    color: white;
    padding: 12px 25px;
    border-radius: 30px;
    font-weight: 600;
    transition: all 0.3s ease;
    border: none;
    box-shadow: 0 5px 15px rgba(0, 146, 69, 0.1);
}

.cart-empty .btn:hover {
    background: var(--secondary-color);
    transform: scale(1.05);
}

/* Login and Register Buttons in Cart - Side by Side */
.cart-empty .btn-group {
    display: flex;
    gap: 15px;
    justify-content: center;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.cart-empty .btn-group .btn {
    flex: 1;
    min-width: 140px;
    max-width: 180px;
    padding: 14px 22px;
    font-size: 1.1rem;
    border-radius: 15px;
    font-weight: 700;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.15);
    position: relative;
    overflow: hidden;
    letter-spacing: 0.3px;
}

.cart-empty .btn-group .btn-primary {
    background: linear-gradient(135deg, #000000 0%, #333333 100%);
    color: white;
    border: 2px solid transparent;
}

.cart-empty .btn-group .btn-outline-primary {
    background: transparent;
    color: #000000;
    border: 2px solid #000000;
}

.cart-empty .btn-group .btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: all 0.6s ease;
}

.cart-empty .btn-group .btn-primary:hover {
    background: linear-gradient(135deg, #333333 0%, #000000 100%);
    border-color: rgba(255, 255, 255, 0.2);
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.cart-empty .btn-group .btn-outline-primary:hover {
    background: #000000;
    color: white;
    border-color: #000000;
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.cart-empty .btn-group .btn:hover::before {
    left: 100%;
}

.cart-empty .btn-group .btn:active {
    transform: translateY(-1px);
}

/* Continue Shopping Button */
.cart-empty .btn-outline-secondary {
    background: rgba(108, 117, 125, 0.1);
    color: #6c757d;
    border: 2px solid rgba(108, 117, 125, 0.3);
    padding: 12px 28px;
    border-radius: 15px;
    font-weight: 700;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    margin-top: 15px;
    position: relative;
    overflow: hidden;
    letter-spacing: 0.3px;
}

.cart-empty .btn-outline-secondary::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: all 0.6s ease;
}

.cart-empty .btn-outline-secondary:hover {
    background: #6c757d;
    color: white;
    border-color: #6c757d;
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(108, 117, 125, 0.3);
}

.cart-empty .btn-outline-secondary:hover::before {
    left: 100%;
}

.cart-empty .btn-outline-secondary:active {
    transform: translateY(-1px);
}

/* Mobile Responsive */
@media (max-width: 576px) {
    .cart-sidebar {
        width: 100%;
        height: 100vh;
        right: -100%;
    }

    .cart-items-container {
        /* Ensure proper scrolling on mobile */
        -webkit-overflow-scrolling: touch;
        scrollbar-width: thin;
        scrollbar-color: var(--primary-color) rgba(0, 146, 69, 0.1);
    }

    .cart-items {
        padding: 15px;
        /* Remove individual height constraints */
        max-height: none;
    }

    .cart-footer {
        padding: 20px 15px;
        /* Ensure footer is always visible */
        position: sticky;
        bottom: 0;
        background: rgba(255, 255, 255, 0.95);
        backdrop-filter: blur(15px);
        -webkit-backdrop-filter: blur(15px);
    }

    .cart-empty {
        padding: 30px 20px;
    }

    .cart-empty .btn-group {
        flex-direction: column;
        gap: 10px;
        width: 100%;
        max-width: 280px;
    }

    .cart-empty .btn-group .btn {
        min-width: auto;
        max-width: none;
        width: 100%;
        padding: 10px 15px;
        font-size: 0.9rem;
    }

    .cart-empty i {
        font-size: 4rem;
        width: 100px;
        height: 100px;
    }

    .cart-empty p {
        font-size: 1rem;
        margin-bottom: 25px;
    }
}

/* Additional Mobile Cart Improvements */
@media (max-width: 768px) {
    .cart-sidebar {
        width: 100%;
        right: -100%;
    }

    .cart-items {
        padding: 15px;
        max-height: none; /* Remove height constraint */
    }

    .cart-footer {
        padding: 20px 15px;
    }

    .cart-header {
        padding: 15px 20px;
    }
}

@media (max-width: 576px) {
    .cart-item-inner {
        padding: 0.75rem;
    }

    .cart-item-image {
        width: 60px;
        height: 60px;
    }

    .cart-item-title {
        font-size: 0.95rem;
    }

    .cart-item-price {
        font-size: 1rem;
    }

    .remove-btn {
        opacity: 1;
        width: 28px;
        height: 28px;
        left: 0.75rem;
    }

    /* Ensure checkout button is always accessible */
    .checkout-btn {
        padding: 15px 20px;
        font-size: 1.1rem;
        min-height: 50px;
        display: flex;
        align-items: center;
        justify-content: center;
    }
}

/* Cart Animation */
.cart-sidebar {
    transition: transform 0.3s ease-in-out;
    transform: translateX(100%);
}

.cart-sidebar.active {
    transform: translateX(0);
}

/* Cart Toggle Button */
.cart-toggle {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: var(--primary-color);
    color: white;
    border: none;
    box-shadow: var(--card-shadow);
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 999;
}

.cart-toggle:hover {
    transform: scale(1.1);
    background: var(--secondary-color);
}

.cart-count {
    position: absolute;
    top: -5px;
    right: -5px;
    background: #e74c3c;
    color: white;
    border-radius: 50%;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
}

/* Product Modal */
.modal-content {
    background: var(--glass-background);
    backdrop-filter: blur(10px);
    border: var(--glass-border);
    border-radius: 15px;
    color: var(--text-color);
}

.modal-header {
    border-bottom: var(--glass-border);
    background: var(--glass-background);
}

.carousel-item img {
    width: 100%;
    height: 300px;
    object-fit: cover;
    border-radius: 15px;
    box-shadow: var(--card-shadow);
    border: var(--glass-border);
}

.quantity-selector {
    max-width: 150px;
    background: var(--glass-background);
    border: var(--glass-border);
    border-radius: 8px;
    padding: 5px;
    box-shadow: var(--card-shadow);
}

/* Toast Notification */
.toast {
    background: var(--glass-background);
    backdrop-filter: blur(8px);
    border: var(--glass-border);
    box-shadow: var(--card-shadow);
}

.toast-header {
    background: rgba(255, 255, 255, 0.15);
    color: var(--primary-color);
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
}

/* Responsive Design */
@media (max-width: 991px) {
    .filter-sidebar {
        margin-bottom: 25px;
        padding: 15px;
    }
}

@media (max-width: 768px) {
    .modal-dialog {
        margin: 15px;
    }
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Custom Scrollbar - Unified */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.05);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb {
    background: #dee2e6;
    border-radius: 4px;
    border: 2px solid transparent;
    background-clip: padding-box;
}

::-webkit-scrollbar-thumb:hover {
    background: #adb5bd;
    border: 2px solid transparent;
    background-clip: padding-box;
}

/* For Firefox */
* {
    scrollbar-width: thin;
    scrollbar-color: #dee2e6 rgba(0, 0, 0, 0.05);
}

/* Color & Size Selection */
.colors-grid,
.sizes-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 0.5rem;
}

.color-item {
    display: flex;
    align-items: center;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    background: #f8f9fa;
    border: 2px solid rgba(0, 146, 69, 0.2);
    box-shadow: var(--card-shadow);
}

.color-item.selected {
    background: var(--primary-color);
    color: white;
    border-color: var(--secondary-color);
}

.color-item:not(.available) {
    opacity: 0.5;
    cursor: not-allowed;
}

.size-item {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 8px;
    background: #f8f9fa;
    border: 2px solid rgba(0, 146, 69, 0.2);
    box-shadow: var(--card-shadow);
}

.size-item.selected {
    background: var(--primary-color);
    color: white;
    border-color: var(--secondary-color);
}

.size-item:not(.available) {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Fixed Buttons Group */
.fixed-buttons-group {
    position: fixed;
    bottom: 20px;
    left: 20px;
    display: flex;
    gap: 15px;
    z-index: 1000;
}

/* Fixed Filter Button */
.fixed-filter-btn {
    position: fixed;
    bottom: 100px;
    left: 20px;
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border: none;
    border-radius: 50%;
    color: white;
    font-size: 18px;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
    transition: all 0.3s ease;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
}

.fixed-filter-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.6);
    background: linear-gradient(135deg, #5a6fd8 0%, #6a4190 100%);
}

.fixed-filter-btn:active {
    transform: translateY(0);
}

/* Fixed Cart Button */
.fixed-cart-btn {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: var(--primary-color);
    color: white;
    border: none;
    box-shadow: 0 4px 12px rgba(0, 146, 69, 0.25);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: transform 0.3s ease, background-color 0.3s ease;
    border: 2px solid rgba(255, 255, 255, 0.2);
}


.fixed-cart-btn .cart-count {
    position: absolute;
    top: 0;
    right: 0;
    transform: translate(25%, -25%);
}

/* Fixed Dashboard Button */
.fixed-dashboard-btn {
    height: 60px;
    background: var(--primary-color);
    color: white;
    padding: 0 1.5rem;
    border-radius: 30px;
    text-decoration: none;
    box-shadow: 0 4px 12px rgba(0, 146, 69, 0.25);
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 600;
    border: 2px solid rgba(255, 255, 255, 0.2);
    transition: transform 0.3s ease, background-color 0.3s ease;
}


/* Adjust for mobile bottom navigation */
@media (max-width: 991px) {
    .fixed-buttons-group {
        bottom: 110px; /* Above bottom navigation */
    }
}

@media (max-width: 768px) {
    .fixed-buttons-group {
        bottom: 110px; /* Keep above bottom nav */
        left: 15px;
        gap: 10px;
    }

    .fixed-cart-btn {
        width: 50px;
        height: 50px;
    }

    .fixed-dashboard-btn {
        height: 50px;
        padding: 0 1rem;
        font-size: 0.9rem;
    }

    /* Mobile Filter Button - Same size as cart button */
    .fixed-filter-btn {
        bottom: 100px;
        left: 15px;
        width: 50px;
        height: 50px;
        font-size: 16px;
    }
}

/* Order Product Button */
.order-product-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    width: 100%;
    padding: 0.75rem 1rem;
    background: var(--primary-color);
    color: white;
    text-align: center;
    border-radius: 12px;
    text-decoration: none;
    border: 2px solid rgba(0, 146, 69, 0.2);
    box-shadow: 0 4px 12px rgba(0, 146, 69, 0.08);
    font-weight: 600;
    transition: all 0.3s ease;
}

/* Disable hover effects for cart empty buttons */
.cart-empty .btn-primary:hover,
.cart-empty .btn-outline-primary:hover,
.cart-empty .btn-outline-secondary:hover {
    background-color: var(--primary-color) !important;
    border-color: var(--primary-color) !important;
    color: white !important;
    transform: none !important;
    box-shadow: 0 4px 12px rgba(0, 146, 69, 0.08) !important;
}

.cart-empty .btn-outline-primary:hover {
    background-color: var(--primary-color) !important;
    border-color: var(--primary-color) !important;
    color: white !important;
}

.cart-empty .btn-outline-secondary:hover {
    background-color: #6c757d !important;
    border-color: #6c757d !important;
    color: white !important;
}


.order-product-btn i {
    font-size: 1.1rem;
}

@media (max-width: 768px) {
    .order-product-btn {
        padding: 0.4rem 0.8rem;
        font-size: 0.85rem;
        gap: 0.3rem;
    }

    .order-product-btn i {
        font-size: 0.9rem;
    }
}

@media (max-width: 576px) {
    .order-product-btn {
        padding: 0.35rem 0.7rem;
        font-size: 0.8rem;
        gap: 0.25rem;
        border-radius: 8px;
    }

    .order-product-btn i {
        font-size: 0.85rem;
    }
}

/* Cart Item Animation */
.cart-item {
    transition: all 0.3s ease;
}

/* Modern Toast Notification Styles */
.notification-toast {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 9999;
    min-width: 320px;
    max-width: 400px;
    background: #FFFFFF;
    color: #333333;
    border-radius: 12px;
    padding: 16px 20px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.12);
    border: 1px solid rgba(0, 0, 0, 0.08);
    animation: slideInRight 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    backdrop-filter: blur(10px);
    font-family: 'Tajawal', sans-serif;
}

.notification-toast.show {
    opacity: 1;
    transform: translateX(0);
}

.notification-toast.alert-success {
    background: linear-gradient(135deg, #10B981, #059669);
    color: white;
    border: none;
    padding: 16px 20px;
    font-weight: 500;
    box-shadow: 0 8px 32px rgba(16, 185, 129, 0.25);
}

.notification-toast.alert-error {
    background: linear-gradient(135deg, #EF4444, #DC2626);
    color: white;
    border: none;
    box-shadow: 0 8px 32px rgba(239, 68, 68, 0.25);
}

.notification-toast.alert-warning {
    background: linear-gradient(135deg, #F59E0B, #D97706);
    color: white;
    border: none;
    box-shadow: 0 8px 32px rgba(245, 158, 11, 0.25);
}

.notification-toast.alert-info {
    background: linear-gradient(135deg, #3B82F6, #2563EB);
    color: white;
    border: none;
    box-shadow: 0 8px 32px rgba(59, 130, 246, 0.25);
}

/* Modern Toast Animations */
@keyframes slideInRight {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes slideOutRight {
    from {
        transform: translateX(0);
        opacity: 1;
    }
    to {
        transform: translateX(100%);
        opacity: 0;
    }
}

@keyframes slideDown {
    from {
        transform: translate(-50%, -100%);
        opacity: 0;
    }
    to {
        transform: translate(-50%, 0);
        opacity: 1;
    }
}

/* Alert Success Style */
.alert-success {
    background-color: #009245;
    color: white;
    border-radius: 8px;
    border: none;
    padding: 12px 20px;
    font-weight: 600;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.15);
    position: fixed;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 9999;
    min-width: 300px;
    text-align: center;
    opacity: 1;
    animation: fadeInOut 4s ease-in-out;
}

@keyframes fadeInOut {
    0% { opacity: 0; transform: translate(-50%, -20px); }
    10% { opacity: 1; transform: translate(-50%, 0); }
    90% { opacity: 1; transform: translate(-50%, 0); }
    100% { opacity: 0; transform: translate(-50%, -20px); }
}

/* Cart Button in Navbar */
#cartToggle {
    position: relative;
    padding: 8px 16px;
    background-color: rgba(0, 146, 69, 0.08);
    color: var(--primary-color);
    border-color: rgba(0, 146, 69, 0.2);
    border-radius: 10px;
    transition: all 0.3s ease;
}

#cartToggle:hover {
    background-color: var(--primary-color);
    color: white;
    transform: translateY(-3px);
    box-shadow: 0 4px 10px rgba(0, 146, 69, 0.15);
}

/* Dashboard Button & Styles */
.dashboard-btn,
.dashboard-link,
.logout-btn,
.user-button {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background-color: var(--primary-color);
    color: white;
    border: none;
    padding: 8px 18px;
    border-radius: 10px;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
    box-shadow: 0 4px 10px rgba(0, 146, 69, 0.15);
}

.dashboard-btn:hover,
.dashboard-link:hover,
.logout-btn:hover,
.user-button:hover {
    background-color: var(--secondary-color);
    color: white;
    transform: translateY(-3px);
    box-shadow: 0 4px 15px rgba(0, 146, 69, 0.25);
}

/* Centered Contact Info Box */
.contact-info-box {
    background: #fff;
    border-radius: 20px;
    padding: 30px 20px;
    box-shadow: 0 10px 30px rgba(0, 146, 69, 0.1);
    text-align: center;
    max-width: 500px;
    margin: 0 auto;
    border: 1px solid rgba(0, 146, 69, 0.1);
}

.contact-info-box h4 {
    color: var(--primary-color);
    font-weight: 600;
    margin-bottom: 25px;
    position: relative;
    display: inline-block;
    padding-bottom: 10px;
}

.contact-info-box h4::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--primary-color);
    width: 80px;
    margin: 0 auto;
    border-radius: 3px;
}

.contact-info-box .contact-item {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
}

.contact-info-box .contact-icon {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: rgba(0, 146, 69, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-left: 15px;
    color: var(--primary-color);
    font-size: 1.2rem;
    transition: all 0.3s ease;
}

.contact-info-box .contact-item:hover .contact-icon {
    background: var(--primary-color);
    color: white;
    transform: scale(1.1);
    box-shadow: 0 5px 15px rgba(0, 146, 69, 0.2);
}

.contact-info-box .contact-text {
    color: var(--text-color);
    font-size: 1rem;
    text-align: right;
    direction: ltr;
}

.contact-info-box .contact-text a {
    color: var(--text-color);
    text-decoration: none;
    transition: color 0.3s ease;
}

.contact-info-box .contact-text a:hover {
    color: var(--primary-color);
}

/* Custom Scrollbar - Unified */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.05);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb {
    background: #dee2e6;
    border-radius: 4px;
    border: 2px solid transparent;
    background-clip: padding-box;
}

::-webkit-scrollbar-thumb:hover {
    background: #adb5bd;
    border: 2px solid transparent;
    background-clip: padding-box;
}

/* For Firefox */
* {
    scrollbar-width: thin;
    scrollbar-color: #dee2e6 rgba(0, 0, 0, 0.05);
}

/* Social Media Icons - General Rules */
.social-link {
    color: white !important;
}

.social-link i {
    color: white !important;
}

.social-link:hover {
    color: white !important;
}

.social-link:hover i {
    color: white !important;
}

/* Responsive Styles */
@media (max-width: 768px) {
    .glass-footer {
        margin-top: 4rem;
    }

    .glass-footer::after {
        top: -40px;
        height: 40px;
    }

    .glass-footer .container {
        padding: 2rem 1rem;
    }

    .glass-footer .row {
        text-align: center;
    }

    .glass-footer h5 {
        display: inline-block;
        margin-bottom: 1.5rem;
    }


    .social-links {
        justify-content: center;
        margin: 1.5rem 0;
    }

    .social-link {
        width: 50px;
        height: 50px;
        font-size: 1.3rem;
        background: rgba(255, 255, 255, 0.1);
        color: white !important; /* Force white color for mobile */
        border: 1px solid rgba(255, 255, 255, 0.2);
    }

    .social-link:hover {
        background: rgba(255, 255, 255, 0.2);
        color: white !important;
        transform: scale(1.1);
    }

    .social-link i {
        color: white !important;
    }

    .newsletter {
        text-align: center;
        padding: 1.5rem;
        margin: 1rem -0.5rem;
        border-radius: 30px;
    }

    .newsletter .input-group {
        max-width: 400px;
        margin: 0 auto;
    }

    .newsletter input {
        text-align: center;
        height: 50px;
        font-size: 1rem;
    }

    .newsletter .btn {
        height: 50px;
        width: 100%;
        font-size: 1rem;
    }

    .glass-footer ul {
        text-align: center;
        margin: 0 auto;
        max-width: 300px;
    }

    .glass-footer ul li a {
        padding: 0.8rem 0;
        font-size: 1.1rem;
    }

    .glass-footer ul li a::before {
        display: none;
    }

    .glass-footer ul li a:hover {
        padding-left: 0;
        transform: scale(1.05);
    }
}

@media (max-width: 576px) {
    .glass-footer {
        margin-top: 3rem;
    }

    .glass-footer::after {
        top: -30px;
        height: 30px;
    }

    .glass-footer .container {
        padding: 1.5rem 1rem;
    }

    .social-link {
        width: 45px;
        height: 45px;
        font-size: 1.2rem;
        background: rgba(255, 255, 255, 0.1);
        color: white !important;
        border: 1px solid rgba(255, 255, 255, 0.2);
    }

    .social-link:hover {
        background: rgba(255, 255, 255, 0.2);
        color: white !important;
        transform: scale(1.1);
    }

    .social-link i {
        color: white !important;
    }

    .newsletter {
        padding: 1.25rem;
        margin: 1rem -0.25rem;
    }

    .newsletter input,
    .newsletter .btn {
        height: 45px;
    }

    .glass-footer ul li a {
        padding: 0.6rem 0;
        font-size: 1rem;
    }
}

/* Profile Dropdown Styles */
.profile-dropdown {
    padding: 8px 16px;
    background-color: rgba(0, 146, 69, 0.08);
    color: var(--primary-color);
    border-color: rgba(0, 146, 69, 0.2);
    border-radius: 10px;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 44px;
}

.profile-dropdown:hover,
.profile-dropdown:focus,
.profile-dropdown:active,
.profile-dropdown.show,
.profile-dropdown.active {
    background-color: rgba(0, 146, 69, 0.1);
    border-color: var(--primary-color);
}

/* Dropdown arrow styles */
.dropdown-arrow-wrapper {
    display: inline-flex;
    align-items: center;
    margin-right: 2px;
    transition: all 0.3s ease;
}

.dropdown-arrow {
    font-size: 14px;
    opacity: 0.7;
    transition: transform 0.3s ease;
}

.profile-dropdown:hover .dropdown-arrow,
.profile-dropdown.active .dropdown-arrow {
    opacity: 1;
    transform: translateY(2px);
}

.profile-dropdown-container {
    position: relative;
}

/* Fixed Navbar and Dropdown Menu */
.sticky-top {
    position: sticky;
    top: 0;
    z-index: 1020;
}

.profile-menu {
    position: fixed;
    z-index: 1050 !important;
    display: none;
    min-width: 200px;
    padding: 0.5rem;
    color: var(--text-color);
    text-align: right;
    background: var(--glass-background);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: var(--glass-border);
    border-radius: 15px;
    box-shadow: var(--card-shadow);
}

.profile-menu.show {
    display: block;
}

.profile-menu .dropdown-item {
    color: var(--text-color);
    padding: 0.75rem 1rem;
    border-radius: 8px;
    transition: all 0.3s ease;
    font-weight: 500;
}

.profile-menu .dropdown-item:hover {
    background-color: rgba(0, 146, 69, 0.1);
    color: var(--primary-color);
}

.profile-menu .dropdown-divider {
    border-color: rgba(0, 146, 69, 0.1);
    margin: 0.5rem 0;
}

.profile-menu form button.dropdown-item {
    width: 100%;
    text-align: right;
    border: none;
    background: none;
    cursor: pointer;
}

/* Icon spacing and consistency */
.cart-wrapper, .profile-wrapper {
    display: inline-block;
    margin: 0 10px;
}

.cart-wrapper button, .profile-wrapper button {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 42px;
    width: 42px;
    padding: 0;
}

#cartToggle {
    background-color: rgba(0, 146, 69, 0.08);
    color: var(--primary-color);
    border-color: rgba(0, 146, 69, 0.2);
    border-radius: 10px;
    transition: all 0.3s ease;
}

#cartToggle:hover {
    background-color: var(--primary-color);
    color: white;
    transform: translateY(-3px);
    box-shadow: 0 4px 10px rgba(0, 146, 69, 0.15);
}

/* Coupon Badge */
.coupon-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    z-index: 10;
    max-width: 140px;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.3));
    transition: all 0.3s ease;
}

.coupon-badge .badge {
    font-size: 0.75rem;
    font-weight: bold;
    padding: 0.35rem 0.5rem;
    border-radius: 4px;
    display: block;
    text-align: center;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.coupon-badge small {
    font-size: 0.65rem;
    opacity: 0.9;
    margin-top: 2px;
    font-weight: 500;
}



@media (max-width: 768px) {
    .coupon-badge {
        top: 5px;
        left: 5px;
        max-width: 110px;
    }

    .coupon-badge .badge {
        font-size: 0.65rem;
        padding: 0.25rem 0.35rem;
    }

    .coupon-badge small {
        font-size: 0.55rem;
    }
}
