/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
    background-color: #f8f9fa;
    color: #333;
    line-height: 1.6;
}

.container-shop {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

/* Header Styles */
.shop-heading {
    display: flex;
    align-items: center;
    margin-bottom: 30px;
    margin-top: 20px;
}

.shop-heading h1 {
    font-size: 2.2rem;
    margin-left: 15px;
    color: #162474;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.1);
}

.shop-icon {
    width: 60px;
    height: 60px;
    background: white;
    border-radius: 50%;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.shop-icon i {
    font-size: 2rem;
    color: rgb(50, 93, 155);
}

/* Categories Styles */
.categories-container {
    margin-bottom: 30px;
    padding: 20px;
    background: white;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.categories-title {
    display: flex;
    align-items: center;
    margin-bottom: 20px;
    font-size: 1.2rem;
    color: rgb(50, 93, 155);
    font-weight: 600;
}

.categories-title i {
    margin-right: 10px;
    font-size: 1.4rem;
}

.categories {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.category {
    display: flex;
    align-items: center;
    padding: 12px 20px;
    background: #f8f9fa;
    border-radius: 8px;
    transition: all 0.3s ease;
    cursor: pointer;
    border: 1px solid #e9ecef;
}

.category:hover {
    background: #e9ecef;
    transform: translateY(-3px);
}

.category i {
    font-size: 1.2rem;
    margin-right: 10px;
    color: rgb(50, 93, 155);
}

.category.active {
    background: rgb(50, 93, 155);
    color: white;
    font-weight: bold;
    box-shadow: 0 5px 15px rgba(58, 12, 163, 0.3);
}

.category.active i {
    color: white;
}

/* Results Info */
.results-info {
    text-align: center;
    margin-bottom: 25px;
    color: #636e72;
    font-size: 0.95rem;
    background: white;
    padding: 12px;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

/* Products Grid */
.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 25px;
    margin-bottom: 40px;
}

.product-card {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.06);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    position: relative;
    display: flex;
    flex-direction: column;
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
}

.product-image {
    height: 180px;
    width: 100%;
    background-color: #f5f7fa;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.product-image img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    transition: transform 0.5s ease;
}

.product-card:hover .product-image img {
    transform: scale(1.05);
}

.product-info {
    padding: 18px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.product-name {
    font-weight: 600;
    font-size: 1.1rem;
    margin-bottom: 8px;
    color: #2d3436;
}

.product-description {
    color: #636e72;
    font-size: 0.9rem;
    margin-bottom: 15px;
    flex-grow: 1;
}

.product-price {
    font-weight: bold;
    color: #3a0ca3;
    font-size: 1.2rem;
    margin-bottom: 15px;
}

/* Add to Cart Button Styles */
.add-to-cart-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    padding: 12px 0;
    background: linear-gradient(135deg, #3a0ca3 0%, #4361ee 100%);
    color: white;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    overflow: hidden;
    position: relative;
    text-decoration: none;
}


.add-to-cart-btn i {
    margin-right: 8px;
    transition: transform 0.3s ease;
    text-decoration: none;
}

.add-to-cart-btn:hover {
  
    box-shadow: 0 5px 15px rgba(58, 12, 163, 0.4);
}

.add-to-cart-btn:hover i {
    transform: translateX(3px);
}
.add-to-cart-btn-link {
    text-decoration: none;   /* remove underline */
    display: inline-block;   /* keeps it clean */
}

/* Enhanced Pagination Styles */
.pagination {
    display: flex;
    justify-content: center;
    margin-top: 30px;
    margin-bottom: 25px;
}

.page-numbers {
    display: flex;
    list-style: none;
    background: white;
    padding: 10px 20px;
    border-radius: 50px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    flex-wrap: wrap;
    justify-content: center;
}

.page-numbers li {
    margin: 5px;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s ease;
}

.page-numbers li:hover {
    background: #f5f7fa;
}

.page-numbers li.active {
    background: #3a0ca3;
    color: white;
}

.page-numbers li.disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Responsive adjustments for pagination */
@media (max-width: 480px) {
    .page-numbers {
        padding: 8px 12px;
    }
    
    .page-numbers li {
        width: 35px;
        height: 35px;
        margin: 3px;
        font-size: 0.9rem;
    }
}

/* Cart Sidebar Styles */
.cart-sidebar {
    position: fixed;
    top: 0;
    right: -400px;
    width: 350px;
    height: 100vh;
    background: white;
    box-shadow: -5px 0 15px rgba(0, 0, 0, 0.1);
    z-index: 1000;
    transition: right 0.3s ease;
    padding: 20px;
    overflow-y: auto;
}

.cart-sidebar.active {
    right: 0;
}

.cart-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 1px solid #eee;
}

.cart-header h2 {
    font-size: 1.5rem;
    color: #3a0ca3;
}

.close-cart {
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: #636e72;
}

.cart-items {
    margin-bottom: 20px;
}

.cart-item {
    display: flex;
    margin-bottom: 15px;
    padding-bottom: 15px;
    border-bottom: 1px solid #eee;
}

.cart-item-image {
    width: 70px;
    height: 70px;
    background: #f5f7fa;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 15px;
}

.cart-item-image img {
    max-width: 90%;
    max-height: 90%;
    object-fit: contain;
}

.cart-item-details {
    flex-grow: 1;
}

.cart-item-name {
    font-weight: 600;
    margin-bottom: 5px;
}

.cart-item-price {
    color: #3a0ca3;
    font-weight: bold;
}

.remove-item {
    background: none;
    border: none;
    color: #ff6b6b;
    cursor: pointer;
    font-size: 1.2rem;
}

.cart-total {
    font-size: 1.2rem;
    font-weight: bold;
    text-align: right;
    margin-bottom: 20px;
    padding-top: 15px;
    border-top: 2px solid #eee;
}

.checkout-btn {
    display: block;
    width: 100%;
    padding: 15px;
    background: #3a0ca3;
    color: white;
    border: none;
    border-radius: 8px;
    font-weight: bold;
    font-size: 1.1rem;
    cursor: pointer;
    transition: background 0.3s ease;
}

.checkout-btn:hover {
    background: #4361ee;
}

.empty-cart-message {
    text-align: center;
    color: #636e72;
    padding: 30px 0;
}

.overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 999;
    display: none;
}

.overlay.active {
    display: block;
}

/* Responsive Styles */
@media (max-width: 1024px) {
    .products-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 768px) {
    .categories {
        width: 100%;
        flex-wrap: wrap;
    }
    
    .category {
        width: 48%;
        margin-bottom: 10px;
    }
    
    .products-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .cart-sidebar {
        width: 300px;
    }
}

@media (max-width: 480px) {
    .products-grid {
        grid-template-columns: 1fr;
    }
    
    .category {
        width: 100%;
    }
    
    .cart-sidebar {
        width: 85%;
    }
}