/* ========================================
   Store Specific Styles
======================================== */

/* Cart Icon in Navigation */
.cart-icon {
    position: relative;
    cursor: pointer;
    margin-left: 1rem;
    padding: 0.75rem;
    transition: all var(--transition-base);
}

.cart-icon:hover {
    transform: scale(1.1);
}

.cart-icon i {
    font-size: 1.5rem;
    color: var(--primary-blue);
}

.cart-count {
    position: absolute;
    top: 0;
    right: 0;
    background: var(--gradient-accent);
    color: var(--white);
    font-size: 0.75rem;
    font-weight: 700;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: pulse 1s ease infinite;
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.1);
    }
}

/* Store Hero */
.store-hero {
    padding: 150px 2rem 80px;
    background: var(--gradient-primary);
    color: var(--white);
    text-align: center;
    position: relative;
    overflow: hidden;
}

.store-hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg width="100" height="100" xmlns="http://www.w3.org/2000/svg"><circle cx="50" cy="50" r="2" fill="white" opacity="0.1"/></svg>');
    animation: movePattern 20s linear infinite;
}

.store-hero h1 {
    font-size: 3.5rem;
    font-weight: 800;
    margin-bottom: 1rem;
    position: relative;
    z-index: 1;
}

.store-hero p {
    font-size: 1.25rem;
    opacity: 0.95;
    position: relative;
    z-index: 1;
}

/* Store Layout */
.store-content {
    padding: 4rem 0;
    background: var(--light-bg);
}

.store-layout {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 3rem;
}

/* Sidebar */
.store-sidebar {
    background: var(--white);
    padding: 2rem;
    border-radius: 25px;
    box-shadow: var(--shadow-md);
    height: fit-content;
    position: sticky;
    top: 100px;
}

.filter-section {
    margin-bottom: 2rem;
    padding-bottom: 2rem;
    border-bottom: 2px solid var(--border-color);
}

.filter-section:last-child {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

.filter-section h3 {
    font-size: 1.25rem;
    color: var(--primary-blue);
    margin-bottom: 1rem;
}

.filter-options {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.filter-option {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    cursor: pointer;
    transition: all var(--transition-base);
}

.filter-option:hover {
    color: var(--orange);
    transform: translateX(5px);
}

.filter-option input[type="checkbox"] {
    width: 20px;
    height: 20px;
    cursor: pointer;
    accent-color: var(--orange);
}

.filter-option span {
    font-weight: 500;
}

/* Price Range */
.price-range {
    padding: 1rem 0;
}

.price-slider {
    width: 100%;
    height: 6px;
    border-radius: 5px;
    background: var(--gradient-light);
    outline: none;
    cursor: pointer;
    -webkit-appearance: none;
}

.price-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: var(--gradient-accent);
    cursor: pointer;
    box-shadow: var(--shadow-md);
}

.price-slider::-moz-range-thumb {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: var(--gradient-accent);
    cursor: pointer;
    border: none;
    box-shadow: var(--shadow-md);
}

.price-labels {
    display: flex;
    justify-content: space-between;
    margin-top: 0.75rem;
    color: var(--text-gray);
    font-weight: 600;
}

/* Sort Select */
.sort-select {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 2px solid var(--border-color);
    border-radius: 15px;
    background: var(--white);
    font-family: inherit;
    font-size: 1rem;
    cursor: pointer;
    transition: all var(--transition-base);
}

.sort-select:focus {
    outline: none;
    border-color: var(--light-blue);
    box-shadow: 0 0 0 4px rgba(96, 165, 250, 0.1);
}

/* Products Section */
.products-section {
    background: transparent;
}

.products-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

.products-header h2 {
    font-size: 2rem;
    color: var(--primary-blue);
}

.product-count {
    color: var(--text-gray);
    font-weight: 600;
}

/* Products Grid */
.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 2rem;
}

.product-card {
    background: var(--white);
    border-radius: 25px;
    overflow: hidden;
    box-shadow: var(--shadow-md);
    transition: all var(--transition-base);
    position: relative;
}

.product-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-2xl);
}

.product-badge {
    position: absolute;
    top: 15px;
    left: 15px;
    background: var(--gradient-accent);
    color: var(--white);
    padding: 0.5rem 1rem;
    border-radius: 50px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    z-index: 10;
    box-shadow: var(--shadow-md);
}

.product-badge.new {
    background: linear-gradient(135deg, #22c55e, #16a34a);
}

.product-image {
    position: relative;
    height: 280px;
    background: var(--gradient-light);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.image-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 6rem;
    color: var(--primary-blue);
    opacity: 0.7;
    transition: all var(--transition-base);
}

.product-card:hover .image-placeholder {
    transform: scale(1.1);
    opacity: 0.9;
}

.quick-view {
    position: absolute;
    bottom: -50px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--white);
    color: var(--primary-blue);
    border: none;
    padding: 0.75rem 2rem;
    border-radius: 50px;
    font-weight: 600;
    cursor: pointer;
    transition: all var(--transition-base);
    box-shadow: var(--shadow-lg);
}

.product-card:hover .quick-view {
    bottom: 20px;
}

.quick-view:hover {
    background: var(--gradient-accent);
    color: var(--white);
    transform: translateX(-50%) scale(1.05);
}

.product-info {
    padding: 1.5rem;
}

.product-info h3 {
    font-size: 1.25rem;
    color: var(--primary-blue);
    margin-bottom: 0.5rem;
}

.product-description {
    color: var(--text-gray);
    font-size: 0.875rem;
    margin-bottom: 1rem;
    line-height: 1.6;
}

.product-rating {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    margin-bottom: 1rem;
}

.product-rating i {
    color: var(--orange);
    font-size: 0.875rem;
}

.product-rating span {
    color: var(--text-gray);
    font-size: 0.875rem;
    margin-left: 0.5rem;
}

.product-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 1rem;
    border-top: 2px solid var(--border-color);
}

.product-price {
    font-size: 1.75rem;
    font-weight: 800;
    background: var(--gradient-accent);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.add-to-cart {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: var(--gradient-primary);
    color: var(--white);
    border: none;
    font-size: 1.25rem;
    cursor: pointer;
    transition: all var(--transition-base);
    display: flex;
    align-items: center;
    justify-content: center;
}

.add-to-cart:hover {
    transform: scale(1.1) rotate(10deg);
    box-shadow: var(--shadow-lg);
}

.add-to-cart.added {
    background: linear-gradient(135deg, #22c55e, #16a34a);
    animation: addedToCart 0.5s ease;
}

@keyframes addedToCart {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.3) rotate(360deg);
    }
    100% {
        transform: scale(1);
    }
}

/* Cart Sidebar */
.cart-sidebar {
    position: fixed;
    top: 0;
    right: -450px;
    width: 450px;
    height: 100vh;
    background: var(--white);
    box-shadow: var(--shadow-2xl);
    z-index: 2000;
    transition: right 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    display: flex;
    flex-direction: column;
}

.cart-sidebar.active {
    right: 0;
}

.cart-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 2rem;
    border-bottom: 2px solid var(--border-color);
}

.cart-header h2 {
    font-size: 1.5rem;
    color: var(--primary-blue);
}

.close-cart {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--light-bg);
    border: none;
    font-size: 1.25rem;
    cursor: pointer;
    transition: all var(--transition-base);
}

.close-cart:hover {
    background: var(--gradient-accent);
    color: var(--white);
    transform: rotate(90deg);
}

.cart-items {
    flex: 1;
    overflow-y: auto;
    padding: 1.5rem;
}

.empty-cart {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    color: var(--text-gray);
}

.empty-cart i {
    font-size: 4rem;
    margin-bottom: 1rem;
    opacity: 0.3;
}

.cart-item {
    display: flex;
    gap: 1rem;
    padding: 1rem;
    background: var(--light-bg);
    border-radius: 15px;
    margin-bottom: 1rem;
    animation: slideIn 0.3s ease;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateX(50px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.cart-item-image {
    width: 80px;
    height: 80px;
    border-radius: 10px;
    background: var(--gradient-light);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    color: var(--primary-blue);
}

.cart-item-details {
    flex: 1;
}

.cart-item-name {
    font-weight: 600;
    color: var(--primary-blue);
    margin-bottom: 0.5rem;
}

.cart-item-price {
    color: var(--orange);
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.cart-item-controls {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.quantity-btn {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: var(--white);
    border: 2px solid var(--border-color);
    cursor: pointer;
    transition: all var(--transition-base);
    display: flex;
    align-items: center;
    justify-content: center;
}

.quantity-btn:hover {
    background: var(--gradient-primary);
    color: var(--white);
    border-color: transparent;
}

.quantity {
    font-weight: 600;
    min-width: 30px;
    text-align: center;
}

.remove-item {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: transparent;
    border: 2px solid var(--border-color);
    color: var(--text-gray);
    cursor: pointer;
    transition: all var(--transition-base);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-left: auto;
}

.remove-item:hover {
    background: #ef4444;
    color: var(--white);
    border-color: transparent;
}

.cart-footer {
    padding: 2rem;
    border-top: 2px solid var(--border-color);
    background: var(--light-bg);
}

.cart-total {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    font-size: 1.5rem;
    font-weight: 700;
}

.total-amount {
    background: var(--gradient-accent);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.checkout-btn {
    width: 100%;
}

/* Responsive Design */
@media (max-width: 1024px) {
    .store-layout {
        grid-template-columns: 1fr;
    }
    
    .store-sidebar {
        position: relative;
        top: 0;
    }
    
    .filter-section {
        margin-bottom: 1rem;
        padding-bottom: 1rem;
    }
    
    .products-grid {
        grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    }
}

@media (max-width: 768px) {
    .store-hero h1 {
        font-size: 2.5rem;
    }
    
    .cart-sidebar {
        width: 100%;
        right: -100%;
    }
    
    .products-grid {
        grid-template-columns: 1fr;
    }
    
    .cart-icon {
        display: flex;
        align-items: center;
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .store-hero h1 {
        font-size: 2rem;
    }
    
    .products-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }
}