/* Cart Page Styles */

/* Cart Layout */
.cart-layout {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 2rem;
    align-items: start;
}

/* Force responsive for all cart-layout variations */
.cart-layout,
.cart-layout.aos-init,
.cart-layout.aos-animate,
.cart-layout.aos-init.aos-animate {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 2rem;
    align-items: start;
}

.cart-item {
    transition: all 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.cart-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    border-color: rgba(102, 126, 234, 0.3);
}

.price-display {
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.1), rgba(118, 75, 162, 0.1));
    padding: 0.5rem 1rem;
    border-radius: 10px;
    border: 1px solid rgba(102, 126, 234, 0.2);
}

.remove-from-cart {
    transition: all 0.3s ease;
}

.remove-from-cart:hover {
    transform: scale(1.1);
    background-color: #dc3545 !important;
    border-color: #dc3545 !important;
}

.summary-details {
    background: rgba(255, 255, 255, 0.05);
    padding: 1.5rem;
    border-radius: 15px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.checkout-btn {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border: none;
    transition: all 0.3s ease;
}

.checkout-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(102, 126, 234, 0.4);
}

.clear-cart-btn {
    transition: all 0.3s ease;
}

.clear-cart-btn:hover {
    background-color: #dc3545 !important;
    border-color: #dc3545 !important;
    color: white !important;
}

/* Empty Cart State */
#emptyCartState .glass-card {
    min-height: 300px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
}

#emptyCartState .fa-shopping-cart {
    opacity: 0.3;
}

/* Loading States */
.loading-shimmer {
    background: linear-gradient(90deg, 
        rgba(255, 255, 255, 0.1) 0%, 
        rgba(255, 255, 255, 0.2) 50%, 
        rgba(255, 255, 255, 0.1) 100%);
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
}

@keyframes shimmer {
    0% { background-position: -200% 0; }
    100% { background-position: 200% 0; }
}

/* Responsive Design */
@media (max-width: 1200px) {
    .cart-layout,
    .cart-layout.aos-init,
    .cart-layout.aos-animate,
    .cart-layout.aos-init.aos-animate {
        grid-template-columns: 1fr !important;
        gap: 1.5rem !important;
    }
    
    .cart-summary-section {
        position: static;
    }
}

@media (max-width: 768px) {
    /* Hero Section Mobile */
    .cart-hero-section {
        padding: 2rem 0;
    }
    
    .hero-content {
        text-align: center;
        padding: 1rem;
    }
    
    .hero-title {
        font-size: 2rem;
        margin-bottom: 1rem;
    }
    
    .hero-subtitle {
        font-size: 1.1rem;
        margin-bottom: 2rem;
    }
    
    /* Cart Layout Mobile */
    .cart-layout,
    .cart-layout.aos-init,
    .cart-layout.aos-animate,
    .cart-layout.aos-init.aos-animate {
        grid-template-columns: 1fr !important;
        gap: 1rem !important;
    }
    
    /* Cart Layout Children Mobile */
    .cart-layout .cart-items-section,
    .cart-layout .cart-summary-section,
    .cart-layout.aos-init .cart-items-section,
    .cart-layout.aos-animate .cart-items-section,
    .cart-layout.aos-init.aos-animate .cart-items-section,
    .cart-layout.aos-init .cart-summary-section,
    .cart-layout.aos-animate .cart-summary-section,
    .cart-layout.aos-init.aos-animate .cart-summary-section {
        width: 100% !important;
        max-width: 100% !important;
    }
    
    .cart-layout .cart-items-section,
    .cart-layout.aos-init .cart-items-section,
    .cart-layout.aos-animate .cart-items-section,
    .cart-layout.aos-init.aos-animate .cart-items-section {
        order: 1 !important;
    }
    
    .cart-layout .cart-summary-section,
    .cart-layout.aos-init .cart-summary-section,
    .cart-layout.aos-animate .cart-summary-section,
    .cart-layout.aos-init.aos-animate .cart-summary-section {
        order: 2 !important;
    }
    
    /* Cart Progress Mobile */
    .cart-progress {
        flex-direction: column;
        gap: 1rem;
        align-items: center;
    }
    
    .progress-step {
        flex-direction: column;
        text-align: center;
        gap: 0.5rem;
    }
    
    .progress-connector {
        display: none;
    }
    
    .step-label {
        font-size: 0.9rem;
    }
    
    /* Cart Items Section Mobile */
    .cart-items-section {
        padding: 1rem;
        border-radius: 15px;
    }
    
    .section-header {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
        margin-bottom: 1.5rem;
    }
    
    .section-title {
        font-size: 1.2rem;
    }
    
    /* Cart Item Mobile - Improved Layout */
    .cart-item {
        padding: 1rem;
        margin-bottom: 1rem;
    }
    
    .cart-item .d-flex {
        flex-direction: column !important;
        gap: 1rem;
    }
    
    .cart-item-image-container {
        align-self: center;
        width: 120px;
        height: 80px;
    }
    
    .cart-item-image {
        width: 100%;
        height: 100%;
        object-fit: cover;
        border-radius: 10px;
    }
    
    .cart-item-content {
        text-align: center;
    }
    
    .cart-item-header {
        justify-content: center;
        margin-bottom: 0.5rem;
    }
    
    .cart-item-title {
        font-size: 1.1rem;
        margin-bottom: 0.5rem;
    }
    
    .cart-item-description {
        font-size: 0.9rem;
        margin-bottom: 0.75rem;
    }
    
    .cart-item-meta {
        flex-direction: column;
        gap: 0.5rem;
        font-size: 0.85rem;
    }
    
    .cart-item-price {
        text-align: center;
    }
    
    .price-display {
        font-size: 1.1rem;
        padding: 0.75rem 1rem;
    }
    
    .cart-item-actions {
        justify-content: center;
    }
    
   
    
    /* Cart Summary Mobile */
    .cart-summary-section {
        position: static;
    }
    
    .summary-sticky {
        padding: 1rem;
        border-radius: 15px;
    }
    
    .summary-details {
        padding: 1rem;
    }
    
    /* Empty Cart Mobile */
    .empty-cart-state {
        padding: 2rem 1rem;
    }
    
    .empty-icon {
        width: 80px;
        height: 80px;
        font-size: 2rem;
    }
    
    .empty-title {
        font-size: 1.6rem;
    }
    
    .empty-text {
        font-size: 1rem;
    }
    
    .empty-actions {
        flex-direction: column;
        align-items: center;
    }
    
    .btn-primary, .btn-outline {
        width: 100%;
        max-width: 280px;
    }
    
    /* Continue Shopping Mobile */
    .continue-shopping-card {
        flex-direction: column;
        gap: 1.5rem;
        text-align: center;
        padding: 1.5rem;
    }
    
    .card-content {
        flex-direction: column;
        text-align: center;
    }
    
    .card-actions {
        width: 100%;
        justify-content: center;
    }
    
    /* Suggestions Mobile */
    .suggestions-grid {
        grid-template-columns: 1fr;
    }
    
    .suggestions-section {
        padding: 1.5rem;
    }
}

@media (max-width: 480px) {
    /* Hero Section Small Mobile */
    .hero-title {
        font-size: 1.8rem;
    }
    
    .hero-subtitle {
        font-size: 1rem;
    }
    
    /* Cart Progress Small Mobile */
    .progress-step {
        gap: 0.25rem;
    }
    
    .step-icon {
        width: 40px;
        height: 40px;
        font-size: 1rem;
    }
    
    .step-label {
        font-size: 0.8rem;
    }
    
    /* Cart Items Section Small Mobile */
    .cart-items-section {
        padding: 0.75rem;
    }
    
    .section-title {
        font-size: 1.1rem;
    }
    
    /* Cart Item Small Mobile */
    .cart-item {
        padding: 0.75rem;
    }
    
    .cart-item-image-container {
        width: 100px;
        height: 70px;
    }
    
    .cart-item-title {
        font-size: 1rem;
    }
    
    .cart-item-description {
        font-size: 0.85rem;
    }
    
    .cart-item-meta {
        font-size: 0.8rem;
    }
    
    .price-display {
        font-size: 1rem;
        padding: 0.5rem 0.75rem;
    }
    

    /* Cart Summary Small Mobile */
    .summary-sticky {
        padding: 0.75rem;
    }
    
    .summary-details {
        padding: 0.75rem;
    }
    
    /* Empty Cart Small Mobile */
    .empty-cart-state {
        padding: 1.5rem 0.75rem;
    }
    
    .empty-icon {
        width: 60px;
        height: 60px;
        font-size: 1.5rem;
    }
    
    .empty-title {
        font-size: 1.4rem;
    }
    
    .empty-text {
        font-size: 0.9rem;
    }
    
    /* Continue Shopping Small Mobile */
    .continue-shopping-card {
        padding: 1rem;
    }
    
    .card-icon {
        width: 50px;
        height: 50px;
        font-size: 1.2rem;
    }
    
    .card-title {
        font-size: 1.1rem;
    }
    
    /* Suggestions Small Mobile */
    .suggestions-section {
        padding: 1rem;
    }
}

/* Cart Badge Animation */
.cart-item-count {
    position: absolute;
    top: -8px;
    right: -8px;
    background: linear-gradient(135deg, #ff6b6b, #ee5a24);
    color: white;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    font-size: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.1); }
    100% { transform: scale(1); }
}

/* Cart Item Type Badges */
.badge.bg-primary {
    background: linear-gradient(135deg, #667eea, #764ba2) !important;
    border: none;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
}

.cart-item-badge {
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    padding: 0.25rem 0.75rem;
    border-radius: 15px;
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.cart-item-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
}

.cart-item-header i {
    font-size: 0.9rem;
}

.cart-item-title {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
}

.cart-item-description {
    color: var(--text-secondary);
    font-size: 0.9rem;
    line-height: 1.4;
    margin-bottom: 0.75rem;
}

.cart-item-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.cart-item-meta span {
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

/* Cart Item Images */
.cart-item-image-container {
    flex-shrink: 0;
    width: 150px;
    height: 100px;
    border-radius: 10px;
    overflow: hidden;
}

.cart-item-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 10px;
    transition: all 0.3s ease;
}

.cart-item:hover .cart-item-image {
    transform: scale(1.05);
}

.cart-item-actions {
    display: flex;
    justify-content: flex-end;
    align-items: center;
}

.remove-btn {
    background: transparent;
    border: 2px solid #dc3545;
    color: #dc3545;
    width:100%;
    padding: 0.5rem 1rem;
    border-radius: 8px;
    font-size: 0.9rem;
    font-weight: 500;
    transition: all 0.3s ease;
    cursor: pointer;
}

.remove-btn:hover {
    background: #dc3545;
    color: white;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(220, 53, 69, 0.3);
}

.cart-item-price {
    display: flex;
    justify-content: flex-end;
    align-items: center;
}

.cart-item-content {
    flex: 1;
    min-width: 0;
}

/* Summary Card Styling */
.summary-details hr {
    border-color: rgba(255, 255, 255, 0.2);
    margin: 1rem 0;
}

/* Button Hover Effects */
.btn-modern {
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
}

.btn-modern::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: left 0.5s;
}

.btn-modern:hover::before {
    left: 100%;
}

/* Dark Theme Adjustments */
[data-theme="dark"] .cart-item {
    background: rgba(30, 30, 30, 0.8);
    border-color: rgba(255, 255, 255, 0.1);
}

[data-theme="dark"] .summary-details {
    background: rgba(30, 30, 30, 0.6);
    border-color: rgba(255, 255, 255, 0.1);
}

[data-theme="dark"] .price-display {
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.2), rgba(118, 75, 162, 0.2));
    border-color: rgba(102, 126, 234, 0.3);
}

/* Light Theme Adjustments */
[data-theme="light"] .cart-item {
    background: rgba(255, 255, 255, 0.8);
    border-color: rgba(0, 0, 0, 0.1);
}

[data-theme="light"] .summary-details {
    background: rgba(255, 255, 255, 0.6);
    border-color: rgba(0, 0, 0, 0.1);
}

[data-theme="light"] .price-display {
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.1), rgba(118, 75, 162, 0.1));
    border-color: rgba(102, 126, 234, 0.2);
}
