/**
 * Modern Cart Styles
 * Professional shopping cart design with dark mode support
 */

/* Cart Container */
.cart-modern-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem 1rem;
}

/* Cart Header */
.cart-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 2rem;
    border-radius: 12px;
    margin-bottom: 2rem;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
}

.cart-header h1 {
    font-size: 1.8rem;
    font-weight: 700;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.cart-header-icon {
    width: 32px;
    height: 32px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Cart Items Card */
.cart-items-card {
    background: white;
    border-radius: 12px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
    overflow: hidden;
    margin-bottom: 1.5rem;
}

/* Cart Item */
.cart-item {
    padding: 1.5rem;
    border-bottom: 1px solid #e5e7eb;
    transition: background-color 0.2s;
}

.cart-item:last-child {
    border-bottom: none;
}

.cart-item:hover {
    background-color: #f9fafb;
}

.cart-item-row {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

/* Product Image */
.cart-item-image {
    width: 80px;
    height: 80px;
    border-radius: 8px;
    object-fit: cover;
    border: 2px solid #e5e7eb;
}

/* Product Info */
.cart-item-info {
    flex: 1;
    min-width: 0;
}

.cart-item-name {
    font-size: 1.1rem;
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.cart-item-name a {
    color: #667eea;
    text-decoration: none;
    transition: color 0.2s;
}

.cart-item-name a:hover {
    color: #764ba2;
}

.cart-item-options {
    font-size: 0.875rem;
    color: #6b7280;
    margin-top: 0.25rem;
}

.cart-item-option {
    display: inline-block;
    background: #f3f4f6;
    padding: 0.25rem 0.75rem;
    border-radius: 6px;
    margin-right: 0.5rem;
    margin-top: 0.25rem;
}

/* Quantity Controls */
.cart-qty-controls {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: #f9fafb;
    border-radius: 8px;
    padding: 0.25rem;
    border: 1px solid #e5e7eb;
}

.cart-qty-btn {
    width: 32px;
    height: 32px;
    border: none;
    background: white;
    color: #667eea;
    border-radius: 6px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
    font-weight: 600;
}

.cart-qty-btn:hover {
    background: #667eea;
    color: white;
    transform: scale(1.05);
}

.cart-qty-btn:active {
    transform: scale(0.95);
}

.cart-qty-input {
    width: 60px;
    text-align: center;
    border: none;
    background: transparent;
    font-weight: 600;
    color: #1f2937;
    font-size: 1rem;
}

.cart-qty-input:focus {
    outline: none;
}

/* Price Display */
.cart-item-price {
    text-align: center;
    min-width: 100px;
}

.cart-price-label {
    font-size: 0.75rem;
    color: #6b7280;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 0.25rem;
}

.cart-price-value {
    font-size: 1.1rem;
    font-weight: 700;
    color: #1f2937;
}

.cart-price-value.subtotal {
    color: #667eea;
}

/* Action Buttons */
.cart-item-actions {
    display: flex;
    gap: 0.5rem;
}

.cart-action-btn {
    width: 36px;
    height: 36px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}

.cart-action-btn.update {
    background: #10b981;
    color: white;
}

.cart-action-btn.update:hover {
    background: #059669;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3);
}

.cart-action-btn.delete {
    background: #ef4444;
    color: white;
}

.cart-action-btn.delete:hover {
    background: #dc2626;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(239, 68, 68, 0.3);
}

/* Cart Summary */
.cart-summary {
    background: white;
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
    position: sticky;
    top: 20px;
}

.cart-summary-title {
    font-size: 1.25rem;
    font-weight: 700;
    color: #1f2937;
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 2px solid #e5e7eb;
}

.cart-summary-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem 0;
    font-size: 0.95rem;
}

.cart-summary-label {
    color: #6b7280;
}

.cart-summary-value {
    font-weight: 600;
    color: #1f2937;
}

.cart-summary-total {
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 2px solid #e5e7eb;
}

.cart-summary-total .cart-summary-label {
    font-size: 1.1rem;
    font-weight: 700;
    color: #1f2937;
}

.cart-summary-total .cart-summary-value {
    font-size: 1.5rem;
    font-weight: 700;
    color: #667eea;
}

/* Discount Alert */
.cart-discount-alert {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
    padding: 1rem;
    border-radius: 8px;
    margin: 1rem 0;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.cart-discount-alert.warning {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
}

.cart-discount-icon {
    width: 24px;
    height: 24px;
    flex-shrink: 0;
}

/* Action Buttons */
.cart-actions {
    display: flex;
    gap: 1rem;
    margin-top: 1.5rem;
}

.cart-btn {
    flex: 1;
    padding: 1rem 1.5rem;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    text-decoration: none;
}

.cart-btn-secondary {
    background: #f3f4f6;
    color: #1f2937;
}

.cart-btn-secondary:hover {
    background: #e5e7eb;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.cart-btn-primary {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
}

.cart-btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 20px rgba(16, 185, 129, 0.4);
}

/* Empty Cart */
.cart-empty {
    text-align: center;
    padding: 4rem 2rem;
    background: white;
    border-radius: 12px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
}

.cart-empty-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 1.5rem;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
}

.cart-empty-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: #1f2937;
    margin-bottom: 0.5rem;
}

.cart-empty-text {
    color: #6b7280;
    margin-bottom: 2rem;
}

/* Dark Mode */
.dark-theme .cart-items-card,
.dark-theme .cart-summary,
.dark-theme .cart-empty {
    background: #1f2937;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.3);
}

.dark-theme .cart-item {
    border-bottom-color: #374151;
}

.dark-theme .cart-item:hover {
    background-color: #374151;
}

.dark-theme .cart-item-name,
.dark-theme .cart-price-value,
.dark-theme .cart-summary-title,
.dark-theme .cart-summary-total .cart-summary-label,
.dark-theme .cart-empty-title {
    color: #f9fafb;
}

.dark-theme .cart-item-options,
.dark-theme .cart-price-label,
.dark-theme .cart-summary-label,
.dark-theme .cart-empty-text {
    color: #9ca3af;
}

.dark-theme .cart-item-option {
    background: #374151;
    color: #d1d5db;
}

.dark-theme .cart-qty-controls {
    background: #374151;
    border-color: #4b5563;
}

.dark-theme .cart-qty-btn {
    background: #1f2937;
    color: #667eea;
}

.dark-theme .cart-qty-btn:hover {
    background: #667eea;
    color: white;
}

.dark-theme .cart-qty-input {
    color: #f9fafb;
}

.dark-theme .cart-summary-row {
    border-bottom-color: #374151;
}

.dark-theme .cart-summary-total {
    border-top-color: #374151;
}

.dark-theme .cart-btn-secondary {
    background: #374151;
    color: #f9fafb;
}

.dark-theme .cart-btn-secondary:hover {
    background: #4b5563;
}

.dark-theme .cart-item-image {
    border-color: #374151;
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .cart-modern-container {
        padding: 1rem 0.5rem;
    }

    .cart-header {
        padding: 1.5rem 1rem;
        margin-bottom: 1rem;
    }

    .cart-header h1 {
        font-size: 1.5rem;
    }

    .cart-item {
        padding: 1rem;
    }

    .cart-item-row {
        flex-direction: column;
        align-items: stretch;
        gap: 1rem;
    }

    .cart-item-image {
        width: 100%;
        height: 150px;
    }

    .cart-item-price {
        display: flex;
        justify-content: space-between;
        align-items: center;
        min-width: auto;
        width: 100%;
    }

    .cart-item-actions {
        width: 100%;
        justify-content: center;
    }

    .cart-actions {
        flex-direction: column;
    }

    .cart-summary {
        position: static;
        margin-top: 1rem;
    }
}

/* Loading State */
.cart-loading {
    opacity: 0.6;
    pointer-events: none;
    position: relative;
}

.cart-loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 40px;
    height: 40px;
    margin: -20px 0 0 -20px;
    border: 3px solid #667eea;
    border-top-color: transparent;
    border-radius: 50%;
    animation: cart-spin 0.8s linear infinite;
}

@keyframes cart-spin {
    to { transform: rotate(360deg); }
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.cart-item {
    animation: fadeIn 0.3s ease-out;
}

/* Breadcrumb Enhancement */
.navigationBar {
    background: transparent;
    padding: 1rem 0;
}

.navigationBar ol {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    list-style: none;
    padding: 0;
    margin: 0;
}

.navigationBar .breadcrumb-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: #6b7280;
}

.navigationBar .breadcrumb-item a {
    color: #667eea;
    text-decoration: none;
    transition: color 0.2s;
}

.navigationBar .breadcrumb-item a:hover {
    color: #764ba2;
}

.navigationBar .breadcrumb-item.active {
    color: #1f2937;
    font-weight: 600;
}

.dark-theme .navigationBar .breadcrumb-item {
    color: #9ca3af;
}

.dark-theme .navigationBar .breadcrumb-item.active {
    color: #f9fafb;
}
