/**
 * TIENDAYA - Design System
 * Sistema de diseño unificado para toda la aplicación
 */

/* ===== VARIABLES CSS ===== */
:root {
    /* Colores principales - se sobrescriben dinámicamente */
    --primary: #FF0000;
    --primary-light: #FF3333;
    --primary-dark: #CC0000;
    --primary-bg: rgba(255, 0, 0, 0.08);
    
    /* Alias para compatibilidad */
    --neon: #FF0000;
    --neon-light: #FF3333;
    --neon-bg: rgba(255, 0, 0, 0.08);
    
    /* Fondos */
    --bg: #020202;
    --bg-primary: #020202;
    --bg-secondary: #0a0a0a;
    --bg-tertiary: #151515;
    --bg-card: rgba(20, 20, 20, 0.95);
    --bg-input: rgba(0, 0, 0, 0.3);
    
    /* Texto */
    --text-primary: #ffffff;
    --text-secondary: #b8b8b8;
    --text-muted: #808080;
    --text-light: #d0d0d0;
    
    /* Estados */
    --success: #22c55e;
    --success-light: #34d399;
    --warning: #f59e0b;
    --warning-light: #ffab40;
    --error: #dc2626;
    --error-light: #ef4444;
    --info: #3b82f6;
    
    /* Bordes */
    --border: rgba(255, 255, 255, 0.1);
    --border-light: rgba(255, 255, 255, 0.05);
    --border-medium: rgba(255, 255, 255, 0.15);
    --border-dark: rgba(255, 255, 255, 0.25);
    
    /* Sombras */
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.1);
    --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.2);
    --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.3);
    --shadow-xl: 0 12px 48px rgba(0, 0, 0, 0.4);
    --shadow-glow: 0 0 20px rgba(255, 0, 0, 0.3);
    
    /* Gradientes */
    --gradient-primary: linear-gradient(135deg, var(--primary-bg) 0%, var(--primary) 100%);
    --gradient-surface: linear-gradient(180deg, var(--bg-card), rgba(20, 20, 20, 0.98), var(--bg-secondary));
    --gradient-hero: linear-gradient(180deg, transparent 0%, var(--bg-primary) 100%);
    
    /* Espaciado */
    --space-xs: 4px;
    --space-sm: 8px;
    --space-md: 16px;
    --space-lg: 24px;
    --space-xl: 32px;
    --space-2xl: 48px;
    --space-3xl: 64px;
    
    /* Border radius */
    --radius-sm: 6px;
    --radius-md: 10px;
    --radius-lg: 16px;
    --radius-xl: 24px;
    --radius-full: 9999px;
    
    /* Transiciones */
    --transition-fast: 0.15s ease;
    --transition-base: 0.3s ease;
    --transition-slow: 0.5s ease;
    
    /* Z-index */
    --z-dropdown: 100;
    --z-sticky: 200;
    --z-modal: 300;
    --z-tooltip: 400;
}

/* ===== RESET Y BASE ===== */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    font-size: 16px;
    line-height: 1.6;
    color: var(--text-primary);
    background: var(--bg-primary);
    min-height: 100vh;
    overflow-x: hidden;
}

/* ===== TIPOGRAFÍA ===== */
h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    line-height: 1.2;
    color: var(--text-primary);
}

h1 { font-size: 2.5rem; }
h2 { font-size: 2rem; }
h3 { font-size: 1.5rem; }
h4 { font-size: 1.25rem; }
h5 { font-size: 1rem; }
h6 { font-size: 0.875rem; }

p { color: var(--text-secondary); }

a {
    color: var(--primary);
    text-decoration: none;
    transition: color var(--transition-fast);
}

a:hover {
    color: var(--primary-light);
}

/* ===== BOTONES ===== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-sm);
    padding: var(--space-md) var(--space-lg);
    font-size: 0.9rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    border: 2px solid transparent;
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all var(--transition-base);
    position: relative;
    overflow: hidden;
}

.btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.1), transparent);
    transition: left 0.5s ease;
}

.btn:hover::before {
    left: 100%;
}

.btn-primary {
    background: var(--gradient-primary);
    color: var(--text-primary);
    border-color: var(--primary-light);
    box-shadow: var(--shadow-lg), 0 4px 20px rgba(255, 0, 0, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-xl), 0 8px 30px rgba(255, 0, 0, 0.5);
    border-color: var(--primary);
}

.btn-outline {
    background: transparent;
    color: var(--text-primary);
    border-color: var(--primary);
}

.btn-outline:hover {
    background: var(--primary);
    color: var(--text-primary);
    transform: translateY(-2px);
}

.btn-ghost {
    background: transparent;
    color: var(--text-secondary);
    border: none;
}

.btn-ghost:hover {
    color: var(--text-primary);
    background: var(--bg-tertiary);
}

.btn-sm {
    padding: var(--space-sm) var(--space-md);
    font-size: 0.8rem;
}

.btn-lg {
    padding: var(--space-lg) var(--space-xl);
    font-size: 1rem;
}

.btn-block {
    width: 100%;
    display: flex;
}

.btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none !important;
}

/* ===== FORMULARIOS ===== */
.form-group {
    margin-bottom: var(--space-lg);
}

.form-label {
    display: block;
    margin-bottom: var(--space-sm);
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.form-label .required {
    color: var(--error);
}

.form-input,
.form-select,
.form-textarea {
    width: 100%;
    padding: var(--space-md);
    background: var(--bg-input);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    color: var(--text-primary);
    font-size: 1rem;
    transition: all var(--transition-base);
}

.form-input:focus,
.form-select:focus,
.form-textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px var(--primary-bg);
    transform: translateY(-1px);
}

.form-input::placeholder {
    color: var(--text-muted);
}

.form-input.error {
    border-color: var(--error);
    background: rgba(220, 38, 38, 0.05);
}

/* ===== TARJETAS ===== */
.card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: var(--space-lg);
    transition: all var(--transition-base);
}

.card:hover {
    border-color: var(--border-medium);
    box-shadow: var(--shadow-lg);
}

.card-header {
    margin-bottom: var(--space-lg);
    padding-bottom: var(--space-md);
    border-bottom: 1px solid var(--border-light);
}

.card-title {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: var(--space-xs);
}

.card-subtitle {
    font-size: 0.9rem;
    color: var(--text-muted);
}

/* ===== NAVEGACIÓN ===== */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: var(--z-sticky);
    background: rgba(2, 2, 2, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border);
    padding: var(--space-md) 0;
}

.navbar-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--space-lg);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.navbar-brand {
    font-size: 1.5rem;
    font-weight: 900;
    font-style: italic;
    text-transform: uppercase;
    color: var(--text-primary);
}

.navbar-brand span {
    color: var(--primary);
    filter: drop-shadow(0 0 8px rgba(255, 0, 0, 0.6));
}

.navbar-menu {
    display: flex;
    align-items: center;
    gap: var(--space-lg);
}

.navbar-link {
    color: var(--text-secondary);
    font-weight: 500;
    padding: var(--space-sm) var(--space-md);
    border-radius: var(--radius-sm);
    transition: all var(--transition-fast);
}

.navbar-link:hover,
.navbar-link.active {
    color: var(--text-primary);
    background: var(--bg-tertiary);
}

/* ===== BADGES ===== */
.badge {
    display: inline-flex;
    align-items: center;
    padding: var(--space-xs) var(--space-sm);
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    border-radius: var(--radius-full);
}

.badge-primary {
    background: var(--primary-bg);
    color: var(--primary);
}

.badge-success {
    background: rgba(34, 197, 94, 0.1);
    color: var(--success);
}

.badge-warning {
    background: rgba(245, 158, 11, 0.1);
    color: var(--warning);
}

.badge-error {
    background: rgba(220, 38, 38, 0.1);
    color: var(--error);
}

/* ===== ALERTAS ===== */
.alert {
    display: flex;
    align-items: center;
    gap: var(--space-md);
    padding: var(--space-md) var(--space-lg);
    border-radius: var(--radius-md);
    margin-bottom: var(--space-lg);
    font-weight: 500;
}

.alert-success {
    background: rgba(34, 197, 94, 0.1);
    border: 1px solid rgba(34, 197, 94, 0.3);
    color: var(--success);
}

.alert-error {
    background: rgba(220, 38, 38, 0.1);
    border: 1px solid rgba(220, 38, 38, 0.3);
    color: var(--error);
}

.alert-warning {
    background: rgba(245, 158, 11, 0.1);
    border: 1px solid rgba(245, 158, 11, 0.3);
    color: var(--warning);
}

.alert-info {
    background: rgba(59, 130, 246, 0.1);
    border: 1px solid rgba(59, 130, 246, 0.3);
    color: var(--info);
}

/* ===== TABLAS ===== */
.table-container {
    overflow-x: auto;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border);
}

.table {
    width: 100%;
    border-collapse: collapse;
}

.table th,
.table td {
    padding: var(--space-md);
    text-align: left;
    border-bottom: 1px solid var(--border-light);
}

.table th {
    background: var(--bg-tertiary);
    font-weight: 600;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-secondary);
}

.table tr:hover td {
    background: var(--bg-tertiary);
}

/* ===== GRID ===== */
.grid {
    display: grid;
    gap: var(--space-lg);
}

.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }

@media (max-width: 1024px) {
    .grid-4 { grid-template-columns: repeat(2, 1fr); }
    .grid-3 { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 640px) {
    .grid-4, .grid-3, .grid-2 { grid-template-columns: 1fr; }
}

/* ===== UTILIDADES ===== */
.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

.text-primary { color: var(--text-primary); }
.text-secondary { color: var(--text-secondary); }
.text-muted { color: var(--text-muted); }
.text-success { color: var(--success); }
.text-error { color: var(--error); }
.text-warning { color: var(--warning); }

.bg-primary { background: var(--bg-primary); }
.bg-secondary { background: var(--bg-secondary); }
.bg-card { background: var(--bg-card); }

.flex { display: flex; }
.flex-col { flex-direction: column; }
.items-center { align-items: center; }
.justify-center { justify-content: center; }
.justify-between { justify-content: space-between; }
.gap-sm { gap: var(--space-sm); }
.gap-md { gap: var(--space-md); }
.gap-lg { gap: var(--space-lg); }

.mt-sm { margin-top: var(--space-sm); }
.mt-md { margin-top: var(--space-md); }
.mt-lg { margin-top: var(--space-lg); }
.mb-sm { margin-bottom: var(--space-sm); }
.mb-md { margin-bottom: var(--space-md); }
.mb-lg { margin-bottom: var(--space-lg); }

.p-sm { padding: var(--space-sm); }
.p-md { padding: var(--space-md); }
.p-lg { padding: var(--space-lg); }

.rounded-sm { border-radius: var(--radius-sm); }
.rounded-md { border-radius: var(--radius-md); }
.rounded-lg { border-radius: var(--radius-lg); }
.rounded-full { border-radius: var(--radius-full); }

.shadow-sm { box-shadow: var(--shadow-sm); }
.shadow-md { box-shadow: var(--shadow-md); }
.shadow-lg { box-shadow: var(--shadow-lg); }

/* ===== ANIMACIONES ===== */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateX(-20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.animate-fadeIn { animation: fadeIn 0.5s ease forwards; }
.animate-fade-in { animation: fadeIn 0.5s ease forwards; }
.animate-fadeInUp { animation: fadeInUp 0.5s ease forwards; }
.animate-fade-in-up { animation: fadeInUp 0.5s ease forwards; }
.animate-slideIn { animation: slideIn 0.5s ease forwards; }
.animate-slide-up { animation: fadeInUp 0.5s ease forwards; }
.animate-pulse { animation: pulse 2s ease infinite; }
.animate-spin { animation: spin 1s linear infinite; }
.animate-scale-up { animation: fadeInUp 0.4s ease forwards; transform: scale(0.95); }
.animate-scale-in { animation: fadeInUp 0.4s ease forwards; }

/* Visibility utilities */
.visible { opacity: 1 !important; transform: translateY(0) !important; }
.hidden { display: none !important; }
.invisible { visibility: hidden; opacity: 0; }

/* Delay utilities */
.delay-1 { animation-delay: 0.1s; }
.delay-2 { animation-delay: 0.2s; }
.delay-3 { animation-delay: 0.3s; }
.delay-4 { animation-delay: 0.4s; }
.delay-5 { animation-delay: 0.5s; }

/* Alternate naming with hyphen */
.animate-delay-1 { animation-delay: 0.1s; }
.animate-delay-2 { animation-delay: 0.2s; }
.animate-delay-3 { animation-delay: 0.3s; }
.animate-delay-4 { animation-delay: 0.4s; }
.animate-delay-5 { animation-delay: 0.5s; }

/* ===== RESPONSIVE ===== */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--space-lg);
}

.section {
    padding: var(--space-3xl) 0;
}

/* ===== ESTADOS DE CARGANDO ===== */
.skeleton {
    background: linear-gradient(90deg, var(--bg-tertiary) 25%, var(--bg-secondary) 50%, var(--bg-tertiary) 75%);
    background-size: 200% 100%;
    animation: skeleton-loading 1.5s infinite;
    border-radius: var(--radius-sm);
}

@keyframes skeleton-loading {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

.spinner {
    width: 40px;
    height: 40px;
    border: 3px solid var(--border);
    border-top-color: var(--primary);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

/* ===== MODALES ===== */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(4px);
    z-index: var(--z-modal);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: var(--space-lg);
    opacity: 0;
    visibility: hidden;
    transition: all var(--transition-base);
}

.modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.modal {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-xl);
    padding: var(--space-xl);
    max-width: 500px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    transform: scale(0.9) translateY(20px);
    transition: transform var(--transition-base);
}

.modal-overlay.active .modal {
    transform: scale(1) translateY(0);
}

.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: var(--space-lg);
}

.modal-title {
    font-size: 1.5rem;
    font-weight: 700;
}

.modal-close {
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 1.5rem;
    cursor: pointer;
    padding: var(--space-sm);
    line-height: 1;
}

.modal-close:hover {
    color: var(--text-primary);
}

/* ===== TOOLTIPS ===== */
.tooltip {
    position: relative;
}

.tooltip::after {
    content: attr(data-tooltip);
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%) translateY(-8px);
    padding: var(--space-sm) var(--space-md);
    background: var(--bg-tertiary);
    color: var(--text-primary);
    font-size: 0.8rem;
    border-radius: var(--radius-sm);
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: all var(--transition-fast);
    z-index: var(--z-tooltip);
}

.tooltip:hover::after {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(-4px);
}

/* ===== DROPDOWNS ===== */
.dropdown {
    position: relative;
}

.dropdown-menu {
    position: absolute;
    top: 100%;
    right: 0;
    min-width: 200px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: var(--space-sm);
    box-shadow: var(--shadow-xl);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all var(--transition-fast);
    z-index: var(--z-dropdown);
}

.dropdown.active .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown-item {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    padding: var(--space-sm) var(--space-md);
    color: var(--text-secondary);
    border-radius: var(--radius-sm);
    transition: all var(--transition-fast);
}

.dropdown-item:hover {
    background: var(--bg-tertiary);
    color: var(--text-primary);
}

/* ===== TABS ===== */
.tabs {
    display: flex;
    gap: var(--space-sm);
    border-bottom: 1px solid var(--border);
    margin-bottom: var(--space-lg);
}

.tab {
    padding: var(--space-md) var(--space-lg);
    color: var(--text-muted);
    font-weight: 500;
    border-bottom: 2px solid transparent;
    transition: all var(--transition-fast);
    cursor: pointer;
}

.tab:hover {
    color: var(--text-primary);
}

.tab.active {
    color: var(--primary);
    border-bottom-color: var(--primary);
}

/* ===== PROGRESS ===== */
.progress {
    height: 8px;
    background: var(--bg-tertiary);
    border-radius: var(--radius-full);
    overflow: hidden;
}

.progress-bar {
    height: 100%;
    background: var(--gradient-primary);
    border-radius: var(--radius-full);
    transition: width var(--transition-slow);
}

/* ===== AVATAR ===== */
.avatar {
    width: 40px;
    height: 40px;
    border-radius: var(--radius-full);
    background: var(--gradient-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    color: var(--text-primary);
    font-size: 0.9rem;
}

.avatar-sm { width: 32px; height: 32px; font-size: 0.75rem; }
.avatar-lg { width: 56px; height: 56px; font-size: 1.25rem; }
.avatar-xl { width: 80px; height: 80px; font-size: 1.5rem; }

/* ===== DIVIDER ===== */
.divider {
    height: 1px;
    background: var(--border);
    margin: var(--space-lg) 0;
}

.divider-vertical {
    width: 1px;
    height: 24px;
    background: var(--border);
    margin: 0 var(--space-md);
}

/* ===== SCROLL TO TOP BUTTON ===== */
.scroll-top {
    position: fixed;
    bottom: 100px;
    right: 20px;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: var(--primary);
    color: white;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    box-shadow: var(--shadow-lg);
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    transition: all 0.3s ease;
    z-index: 999;
}

.scroll-top.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.scroll-top:hover {
    background: var(--primary-dark);
    transform: scale(1.1);
}

/* ===== CART BADGE ===== */
.cart-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 20px;
    height: 20px;
    padding: 0 6px;
    font-size: 0.75rem;
    font-weight: 700;
    background: var(--success);
    color: white;
    border-radius: var(--radius-full);
}

/* ===== BOTTOM NAVIGATION ===== */
.bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    display: flex;
    justify-content: space-around;
    align-items: center;
    background: var(--bg-card);
    border-top: 1px solid var(--border);
    padding: var(--space-sm) 0;
    padding-bottom: calc(var(--space-sm) + env(safe-area-inset-bottom, 0));
    z-index: var(--z-sticky);
}

.nav-link {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    padding: var(--space-sm);
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.75rem;
    transition: color 0.2s ease;
}

.nav-link i {
    font-size: 1.25rem;
}

.nav-link.active {
    color: var(--primary);
}

.nav-link:hover {
    color: var(--primary);
}

/* ===== CART BADGE ===== */
.cart-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 20px;
    height: 20px;
    padding: 0 6px;
    font-size: 0.75rem;
    font-weight: 700;
    background: var(--success);
    color: white;
    border-radius: var(--radius-full);
}

.cart-drawer.open {
    pointer-events: auto;
}

.cart-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.cart-drawer.open .cart-overlay {
    opacity: 1;
    visibility: visible;
}

.cart-content {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    width: 100%;
    max-width: 400px;
    background: var(--bg-card);
    border-left: 1px solid var(--border);
    display: flex;
    flex-direction: column;
    transform: translateX(100%);
    transition: transform 0.3s ease;
    visibility: hidden;
}

.cart-drawer.open .cart-content {
    transform: translateX(0);
    visibility: visible;
}

.cart-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: var(--space-lg);
    border-bottom: 1px solid var(--border);
}

.cart-header h3 {
    margin: 0;
    font-size: 1.25rem;
}

.cart-close {
    background: none;
    border: none;
    color: var(--text-secondary);
    font-size: 1.5rem;
    cursor: pointer;
    padding: var(--space-sm);
}

.cart-close:hover {
    color: var(--text-primary);
}

.cart-items {
    flex: 1;
    overflow-y: auto;
    padding: var(--space-md);
}

.cart-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    color: var(--text-muted);
    gap: var(--space-md);
}

.cart-empty i {
    font-size: 3rem;
}

.cart-footer {
    padding: var(--space-lg);
    border-top: 1px solid var(--border);
}

.cart-total {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: var(--space-md);
    font-size: 1.25rem;
    font-weight: 700;
}

.cart-total span:last-child {
    color: var(--primary);
}

.cart-checkout {
    width: 100%;
    padding: var(--space-md);
    background: var(--success);
    color: white;
    border: none;
    border-radius: var(--radius-md);
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-sm);
    transition: background 0.2s ease;
}

.cart-checkout:hover {
    background: var(--success-light);
}

.cart-item {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    padding: var(--space-md);
    background: var(--bg-secondary);
    border-radius: var(--radius-md);
    margin-bottom: var(--space-md);
}

.item-info h4 {
    margin: 0 0 4px;
    font-size: 0.9rem;
}

.item-type {
    font-size: 0.75rem;
    color: var(--text-muted);
    margin: 0;
}

.item-price {
    font-weight: 600;
    color: var(--primary);
    margin: 4px 0 0;
}

.item-controls {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
}

.qty-btn {
    width: 28px;
    height: 28px;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border);
    background: var(--bg-tertiary);
    color: var(--text-primary);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.qty-btn:hover {
    background: var(--primary);
    border-color: var(--primary);
}

.item-quantity {
    min-width: 24px;
    text-align: center;
    font-weight: 600;
}

.remove-btn {
    background: none;
    border: none;
    color: var(--error);
    cursor: pointer;
    padding: var(--space-xs);
    margin-left: var(--space-sm);
}

.remove-btn:hover {
    color: var(--error-light);
}

/* ===== TOAST NOTIFICATIONS ===== */
.toast-container {
    position: fixed;
    top: var(--space-lg);
    right: var(--space-lg);
    z-index: calc(var(--z-tooltip) + 100);
    display: flex;
    flex-direction: column;
    gap: var(--space-sm);
    pointer-events: none;
}

.toast {
    display: flex;
    align-items: center;
    gap: var(--space-md);
    padding: var(--space-md) var(--space-lg);
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-lg);
    color: var(--text-primary);
    font-size: 0.9rem;
    opacity: 0;
    transform: translateX(100%);
    transition: all 0.3s ease;
    pointer-events: auto;
}

.toast.show {
    opacity: 1;
    transform: translateX(0);
}

.toast-success {
    border-color: var(--success);
}

.toast-success i {
    color: var(--success);
}

.toast-error {
    border-color: var(--error);
}

.toast-error i {
    color: var(--error);
}

.toast-info {
    border-color: var(--info);
}

.toast-info i {
    color: var(--info);
}

/* ===== LOADING SKELETON ===== */
.skeleton-card {
    background: var(--bg-card);
    border-radius: var(--radius-lg);
    overflow: hidden;
}

.skeleton-image {
    height: 200px;
    background: linear-gradient(90deg, var(--bg-tertiary) 25%, var(--bg-secondary) 50%, var(--bg-tertiary) 75%);
    background-size: 200% 100%;
    animation: skeleton-loading 1.5s infinite;
}

.skeleton-content {
    padding: var(--space-md);
}

.skeleton-line {
    height: 16px;
    background: linear-gradient(90deg, var(--bg-tertiary) 25%, var(--bg-secondary) 50%, var(--bg-tertiary) 75%);
    background-size: 200% 100%;
    animation: skeleton-loading 1.5s infinite;
    border-radius: var(--radius-sm);
    margin-bottom: var(--space-sm);
}

.skeleton-line-short {
    width: 40%;
}

.skeleton-line-medium {
    width: 70%;
}
