:root {
    --primary: #2563eb;
    --primary-dark: #1d4ed8;
    --accent: #f59e0b;
    --dark: #1f2937;
    --light: #f8fafc;
    --gray: #64748b;
    --success: #10b981;
    --danger: #ef4444;
}

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

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: var(--dark);
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    scroll-behavior: smooth;
}

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

/* Header */
header {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    padding: 1rem 0;
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.1);
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 1.8rem;
    font-weight: bold;
    color: var(--primary);
    text-decoration: none;
}

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

.nav-links a {
    text-decoration: none;
    color: var(--dark);
    font-weight: 500;
    transition: color 0.3s;
}

.nav-links a:hover {
    color: var(--primary);
}

.cart-icon {
    position: relative;
    cursor: pointer;
    padding: 10px;
    font-size: 1.2rem;
}

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

/* Search Bar */
.search-container {
    position: relative;
    margin: 0 20px;
    flex: 1;
    max-width: 400px;
}

.search-bar {
    width: 100%;
    padding: 12px 45px 12px 15px;
    border: 2px solid #e2e8f0;
    border-radius: 25px;
    font-size: 1rem;
    transition: all 0.3s;
}

.search-bar:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.search-btn {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: var(--gray);
    cursor: pointer;
    font-size: 1.1rem;
}

/* Hero Section */
.hero {
    padding: 100px 0 20px 0;
    text-align: center;
    color: white;
    background-image: url('../assets/background.jpg');
}

.hero h1 {
    font-size: 3.5rem;
    margin-bottom: 1rem;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.hero p {
    font-size: 1.2rem;
    max-width: 600px;
    margin: 0 auto 2rem;
    opacity: 0.9;
}

.btn {
    display: inline-block;
    padding: 12px 30px;
    background: var(--accent);
    color: white;
    text-decoration: none;
    border-radius: 50px;
    font-weight: 600;
    transition: all 0.3s;
    border: none;
    cursor: pointer;
}

.btn:hover {
    background: #e69008;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

/* Categories */
.category-dropdown {
    background-color: white;
    display: flex;
    justify-content: center;
}
.category-dropdown select {
    margin: 10px 5px 5px 20px;
    width: 250px;
    padding: 12px;
    border: 2px solid var(--primary);
    border-radius: 8px;
    font-size: 16px;
    font-weight: 500;
    background: white;
    cursor: pointer;
    transition: 0.3s;
}

.category-dropdown select:hover {
    background: white;
    color: black;
}

/* Products Section */
.products {        
    padding: 10px 0;
    background: white;
}

.section-title {      
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 3rem;
    color: var(--dark);
}

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

.product-card {
    background: white;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s, box-shadow 0.3s;
    border: 1px solid #e2e8f0;
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.15);
}

.product-image {
    height: 200px;
    overflow: hidden;
    position: relative;
}

.product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s;
}

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

.product-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    background: var(--accent);
    color: white;
    padding: 5px 10px;
    border-radius: 15px;
    font-size: 0.8rem;
    font-weight: 600;
}

.discount-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    background: var(--danger);
    color: white;
    padding: 5px 10px;
    border-radius: 15px;
    font-size: 0.8rem;
    font-weight: 600;
    z-index: 2;
}

.product-info {
    padding: 1.5rem;
}

.product-title {
    font-size: 1.3rem;
    margin-bottom: 0.5rem;
    color: var(--dark);
}

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

.price-compare {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
}

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

.discount-percent {
    color: var(--danger);
    font-weight: bold;
    font-size: 0.9rem;
}

.product-description {
    color: var(--gray);
    margin-bottom: 1.5rem;
    line-height: 1.5;
    font-size: 0.95rem;
}

.product-meta {
    display: flex;
    justify-content: space-between;
    margin: 10px 0;
    font-size: 0.9rem;
    color: var(--gray);
}

.product-rating, .product-sales {
    display: flex;
    align-items: center;
    gap: 5px;
}

.product-rating i {
    color: #f59e0b;
}

.add-to-cart {
    width: 100%;
    background: var(--primary);
    color: white;
    border: none;
    padding: 12px;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    transition: background 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.add-to-cart:hover {
    background: var(--primary-dark);
}

.product-actions {
    display: flex;
    gap: 10px;
    margin-top: 15px;
}

.quick-view-btn {
    background: var(--accent);
    color: white;
    border: none;
    padding: 12px;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    transition: background 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    flex: 1;
}

.quick-view-btn:hover {
    background: #e69008;
}

.view-details-btn {
    width: 100%;
    background: transparent;
    color: var(--primary);
    border: 1px solid var(--primary);
    padding: 10px;
    border-radius: 5px;
    cursor: pointer;
    margin-top: 10px;
    transition: all 0.3s;
}

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

/* Cart Modal */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 2000;
    backdrop-filter: blur(5px);
}

.modal-content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: white;
    padding: 2rem;
    border-radius: 15px;
    max-width: 500px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
}

.close-modal {
    position: absolute;
    top: 1rem;
    right: 1rem;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--gray);
}

.cart-items {
    margin: 1.5rem 0;
}

.cart-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 0;
    border-bottom: 1px solid #eee;
}

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

.cart-item-title {
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.cart-item-price {
    color: var(--primary);
    font-weight: bold;
    font-size: 0.9rem;
}

.remove-item {
    color: var(--danger);
    cursor: pointer;
    padding: 5px;
    background: none;
    border: none;
    font-size: 1.1rem;
}

.cart-total {
    font-size: 1.2rem;
    font-weight: bold;
    text-align: right;
    margin: 1rem 0;
    padding-top: 1rem;
    border-top: 2px solid #eee;
}

/* Checkout Form */
.checkout-form {
    display: none;
}

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

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: var(--dark);
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 12px;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    font-size: 1rem;
    transition: border-color 0.3s;
}

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

.form-group textarea {
    min-height: 100px;
    resize: vertical;
}

/* Footer */
footer {
    background: var(--dark);
    color: white;
    text-align: center;
    padding: 2rem 0;
}

/* Responsive */
@media (max-width: 768px) {
    .nav-links {
        display: none;
    }

    .search-container {
        margin: 0 10px;
        max-width: 250px;
    }

    .hero h1 {
        font-size: 2.5rem;
    }

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

    .modal-content {
        width: 95%;
        padding: 1.5rem;
    }

    .category-buttons {
        gap: 0.5rem;
    }

    .category-btn {
        padding: 8px 15px;
        font-size: 0.9rem;
    }
    
    .product-actions {
        flex-direction: column;
    }
}

/* Animation */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

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

/* No results message */
.no-results {
    text-align: center;
    padding: 3rem;
    color: var(--gray);
    font-size: 1.1rem;
    grid-column: 1 / -1;
}

.no-results i {
    font-size: 3rem;
    margin-bottom: 1rem;
    color: var(--gray);
}

/* Reviews Section */
.review-container > div {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 20px;
    max-width: 100% !important; 
    margin: 0 auto;
    text-align: center;
}

/* review card */
.review-card {
    background: #fff;
    border-radius: 16px;
    padding: 20px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.review-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 6px 18px rgba(0,0,0,0.15);
}

.Link {
    display: inline-block;
    padding: 10px;
    font-size: 25px;
    text-decoration: none;
    color: black;
    border-radius: 8px;
    margin: 0 10px;
    transition: 0.3s;
}

.Link:hover {
    font-size: 27px;
}

/* Loading Spinner */
.loading-spinner {
    text-align: center;
    padding: 40px;
    grid-column: 1 / -1;
}

.spinner {
    border: 4px solid rgba(0, 0, 0, 0.1);
    border-radius: 50%;
    border-top: 4px solid var(--primary);
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
    margin: 0 auto 20px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Filter and Sort */
.filter-sort-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    flex-wrap: wrap;
    gap: 15px;
}

.sort-options {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.sort-btn {
    padding: 8px 15px;
    border: 1px solid #e2e8f0;
    background: white;
    border-radius: 20px;
    cursor: pointer;
    transition: all 0.3s;
    font-size: 14px;
}

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

.results-count {
    font-size: 0.9rem;
    color: var(--gray);
}

/* Pagination */
.pagination {
    display: flex;
    justify-content: center;
    margin-top: 30px;
    gap: 10px;
}

.pagination-btn {
    padding: 8px 15px;
    border: 1px solid #e2e8f0;
    background: white;
    border-radius: 5px;
    cursor: pointer;
    transition: all 0.3s;
}

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

.pagination-btn:hover:not(.active) {
    background: #f8f9fa;
}

/* Quick View Modal */
.quick-view-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    z-index: 3000;
    backdrop-filter: blur(5px);
}

.quick-view-content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: white;
    padding: 30px;
    border-radius: 15px;
    max-width: 800px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
}

.quick-view-close {
    position: absolute;
    top: 15px;
    right: 15px;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--gray);
}

.quick-view-body {
    display: flex;
    gap: 30px;
    margin-top: 20px;
}

.quick-view-image {
    flex: 1;
    border-radius: 10px;
    overflow: hidden;
}

.quick-view-image img {
    width: 100%;
    height: auto;
    display: block;
}

.quick-view-info {
    flex: 1;
}

@media (max-width: 768px) {
    .filter-sort-container {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .quick-view-body {
        flex-direction: column;
    }
    
    .quick-view-image, .quick-view-info {
        flex: none;
    }
}

/* Stats Container */
.stats-container {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-top: 20px;
    flex-wrap: wrap;
}

.stat-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    background: rgba(255, 255, 255, 0.1);
    padding: 15px;
    border-radius: 10px;
    min-width: 100px;
}

.stat-value {
    font-size: 1.5rem;
    font-weight: bold;
    margin-bottom: 5px;
}

.stat-label {
    font-size: 0.9rem;
    opacity: 0.9;
}

/* Feature Grid */
.feature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

.feature-card {
    background: white;
    padding: 30px;
    border-radius: 10px;
    text-align: center;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
    transition: transform 0.3s;
}

.feature-card:hover {
    transform: translateY(-5px);
}

.feature-icon {
    font-size: 2.5rem;
    color: var(--primary);
    margin-bottom: 15px;
}

/* Contact Grid */
.contact-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

.contact-card {
    background: #f8fafc;
    padding: 25px;
    border-radius: 10px;
    text-align: center;
}

.contact-icon {
    font-size: 2rem;
    color: var(--primary);
    margin-bottom: 15px;
}

/* Review Cards Grid */
.review-cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
    margin-top: 30px;
}
