/* Cart Page Styles */

/* Cart Hero Section */
.cart-hero {
    background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
    padding: 120px 0 60px;
    text-align: center;
}

.cart-hero .hero-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

.cart-title {
    font-size: 3rem;
    font-weight: 900;
    color: #1e293b;
    margin-bottom: 16px;
}

.cart-subtitle {
    font-size: 1.2rem;
    color: #64748b;
    max-width: 600px;
    margin: 0 auto;
}

/* Cart Section */
.cart-section {
    padding: 60px 0;
    background: #fff;
    min-height: 60vh;
}

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

/* Empty Cart */
.empty-cart {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 400px;
}

.empty-cart-content {
    text-align: center;
    max-width: 400px;
}

.empty-cart-icon {
    color: #cbd5e1;
    margin-bottom: 24px;
}

.empty-cart-content h2 {
    font-size: 2rem;
    color: #1e293b;
    margin-bottom: 12px;
}

.empty-cart-content p {
    color: #64748b;
    margin-bottom: 32px;
    font-size: 1.1rem;
}

.continue-shopping-btn {
    display: inline-block;
    background: linear-gradient(135deg, #2563eb, #1d4ed8);
    color: white;
    padding: 14px 32px;
    border-radius: 12px;
    text-decoration: none;
    font-weight: 600;
    font-size: 1rem;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.continue-shopping-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(37, 99, 235, 0.3);
}

/* Cart Content Layout */
.cart-content {
    display: grid;
    grid-template-columns: 1fr 400px;
    gap: 40px;
    align-items: start;
}

/* Cart Items Section */
.cart-items-section {
    background: #f8fafc;
    border-radius: 20px;
    padding: 32px;
}

.cart-items-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 32px;
    padding-bottom: 16px;
    border-bottom: 2px solid #e2e8f0;
}

.cart-items-header h2 {
    font-size: 1.8rem;
    color: #1e293b;
    font-weight: 700;
}

.clear-cart-btn {
    background: transparent;
    color: #ef4444;
    border: 2px solid #ef4444;
    padding: 8px 16px;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 0.9rem;
}

.clear-cart-btn:hover {
    background: #ef4444;
    color: white;
}

/* Cart Items */
.cart-items {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.cart-item {
    background: white;
    border-radius: 16px;
    padding: 24px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.06);
    border: 1px solid #e2e8f0;
    position: relative;
}

.cart-item-content {
    display: grid;
    grid-template-columns: 120px 1fr auto;
    gap: 20px;
    align-items: center;
}

.cart-item-image {
    width: 120px;
    height: 120px;
    border-radius: 12px;
    overflow: hidden;
    border: 2px solid #f1f5f9;
}

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

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

.cart-item-title {
    font-size: 1.2rem;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 8px;
    line-height: 1.4;
}

.cart-item-description {
    color: #64748b;
    font-size: 0.9rem;
    margin-bottom: 12px;
    line-height: 1.5;
}

.cart-item-size {
    display: inline-block;
    background: #f1f5f9;
    color: #475569;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    margin-bottom: 8px;
}

.cart-item-price {
    font-size: 1.3rem;
    font-weight: 800;
    color: #1e293b;
}

.cart-item-controls {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 16px;
}

.remove-item-btn {
    position: absolute;
    top: 16px;
    right: 16px;
    background: #fee2e2;
    color: #dc2626;
    border: none;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.remove-item-btn:hover {
    background: #dc2626;
    color: white;
    transform: scale(1.1);
}

.quantity-controls {
    display: flex;
    align-items: center;
    gap: 12px;
    background: #f8fafc;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    padding: 8px 12px;
}

.quantity-btn {
    background: #e2e8f0;
    border: none;
    width: 32px;
    height: 32px;
    border-radius: 8px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    color: #475569;
    transition: all 0.3s ease;
}

.quantity-btn:hover {
    background: #cbd5e1;
    color: #1e293b;
}

.quantity-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.quantity-input {
    width: 50px;
    text-align: center;
    border: none;
    background: transparent;
    font-size: 1rem;
    font-weight: 600;
    color: #1e293b;
}

.refresh-btn {
    background: #e2e8f0;
    border: none;
    width: 32px;
    height: 32px;
    border-radius: 8px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #475569;
    transition: all 0.3s ease;
}

.refresh-btn:hover {
    background: #cbd5e1;
    transform: rotate(90deg);
}

/* Order Summary */
.order-summary {
    background: white;
    border-radius: 20px;
    padding: 32px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    border: 1px solid #e2e8f0;
    position: sticky;
    top: 100px;
    height: fit-content;
}

.summary-header {
    margin-bottom: 24px;
    padding-bottom: 16px;
    border-bottom: 2px solid #f1f5f9;
}

.summary-header h3 {
    font-size: 1.5rem;
    color: #1e293b;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.summary-details {
    margin-bottom: 32px;
}

.summary-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
    font-size: 1rem;
}

.summary-row span:first-child {
    color: #64748b;
    font-weight: 500;
}

.summary-row span:last-child {
    color: #1e293b;
    font-weight: 600;
}

.total-row {
    margin-top: 24px;
    padding-top: 16px;
    border-top: 2px solid #f1f5f9;
    font-size: 1.2rem;
    font-weight: 700;
}

.total-row span {
    color: #1e293b;
    font-weight: 800;
}

.checkout-section {
    margin-top: 32px;
}

.terms-checkbox {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 24px;
}

.terms-input {
    width: 18px;
    height: 18px;
    accent-color: #2563eb;
    margin-top: 2px;
}

.terms-label {
    color: #64748b;
    font-size: 0.9rem;
    line-height: 1.4;
    cursor: pointer;
}

.checkout-btn {
    width: 100%;
    background: linear-gradient(135deg, #2563eb, #1d4ed8);
    color: white;
    border: none;
    padding: 16px 24px;
    border-radius: 12px;
    font-size: 1.1rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.checkout-btn:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(37, 99, 235, 0.3);
}

.checkout-btn:disabled {
    background: #cbd5e1;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

/* Dark Mode Support */
[data-theme="dark"] .cart-hero {
    background: linear-gradient(135deg, #1e293b 0%, #0f172a 100%);
}

[data-theme="dark"] .cart-title {
    color: #f1f5f9;
}

[data-theme="dark"] .cart-subtitle {
    color: #94a3b8;
}

[data-theme="dark"] .cart-section {
    background: #0f172a;
}

[data-theme="dark"] .cart-items-section {
    background: #1e293b;
}

[data-theme="dark"] .cart-item {
    background: #334155;
    border-color: #475569;
}

[data-theme="dark"] .cart-item-title {
    color: #f1f5f9;
}

[data-theme="dark"] .cart-item-description {
    color: #94a3b8;
}

[data-theme="dark"] .cart-item-price {
    color: #f1f5f9;
}

[data-theme="dark"] .order-summary {
    background: #1e293b;
    border-color: #475569;
}

[data-theme="dark"] .summary-header h3 {
    color: #f1f5f9;
}

[data-theme="dark"] .summary-row span:last-child,
[data-theme="dark"] .total-row span {
    color: #f1f5f9;
}

/* Responsive Design */
@media (max-width: 1024px) {
    .cart-content {
        grid-template-columns: 1fr 350px;
        gap: 30px;
    }
    
    .order-summary {
        position: static;
    }
}

@media (max-width: 768px) {
    .cart-content {
        grid-template-columns: 1fr;
        gap: 30px;
    }
    
    .cart-items-section,
    .order-summary {
        padding: 24px;
    }
    
    .cart-item-content {
        grid-template-columns: 100px 1fr;
        grid-template-rows: auto auto;
        gap: 16px;
    }
    
    .cart-item-controls {
        grid-column: 1 / -1;
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
    }
    
    .cart-item-image {
        width: 100px;
        height: 100px;
    }
    
    .cart-title {
        font-size: 2.5rem;
    }
}

@media (max-width: 480px) {
    .cart-hero {
        padding: 100px 0 40px;
    }
    
    .cart-title {
        font-size: 2rem;
    }
    
    .cart-container {
        padding: 0 16px;
    }
    
    .cart-items-section,
    .order-summary {
        padding: 20px;
    }
    
    .cart-item {
        padding: 20px;
    }
    
    .cart-item-content {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    .cart-item-controls {
        flex-direction: column;
        gap: 12px;
    }
}