* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    /* Colors - Light Theme */
    --primary-gradient: linear-gradient(135deg, #3B82F6 0%, #1D4ED8 100%);
    --purple-500: #3B82F6; /* Mapped to Blue 500 */
    --purple-600: #2563EB; /* Mapped to Blue 600 */
    --purple-400: #60A5FA; /* Mapped to Blue 400 */
    --purple-100: #DBEAFE; /* Mapped to Blue 100 */
    --blue-500: #3B82F6;
    --blue-600: #2563EB;
    --blue-400: #60A5FA;
    --blue-100: #DBEAFE;
    
    --bg-light: #FFFFFF;
    --bg-secondary: #F9FAFB;
    --bg-card: #FFFFFF;
    --bg-card-hover: #F3F4F6;
    
    --text-primary: #111827;
    --text-secondary: #6B7280;
    --text-muted: #9CA3AF;
    
    --success: #10B981;
    --success-light: #D1FAE5;
    --warning: #F59E0B;
    --warning-light: #FEF3C7;
    --error: #EF4444;
    --error-light: #FEE2E2;
    
    --border-light: #E5E7EB;
    --border-medium: #D1D5DB;
    
    /* Spacing */
    --spacing-xs: 0.25rem;
    --spacing-sm: 0.5rem;
    --spacing-md: 1rem;
    --spacing-lg: 1.5rem;
    --spacing-xl: 2rem;
    --spacing-2xl: 3rem;
    --spacing-3xl: 4rem;
    
    /* Border Radius */
    --radius-sm: 0.375rem;
    --radius-md: 0.5rem;
    --radius-lg: 0.75rem;
    --radius-xl: 1rem;
    --radius-2xl: 1.5rem;
    
    /* Shadows */
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.07), 0 2px 4px -1px rgba(0, 0, 0, 0.04);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.08), 0 4px 6px -2px rgba(0, 0, 0, 0.03);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    --shadow-glow: 0 0 30px rgba(59, 130, 246, 0.2), 0 0 60px rgba(37, 99, 235, 0.1);
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background: var(--bg-secondary);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
}

.container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 var(--spacing-lg);
}

/* Navigation */
.navbar {
    position: sticky;
    top: 0;
    z-index: 1000;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border-light);
    padding: var(--spacing-lg) 0;
    box-shadow: var(--shadow-sm);
}

.nav-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--spacing-xl);
}

.logo {
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
    font-size: 1.5rem;
    font-weight: 700;
    cursor: pointer;
}

.logo-text {
    background: var(--primary-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.nav-links {
    display: flex;
    gap: var(--spacing-xl);
}

.nav-link {
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
    position: relative;
}

.nav-link:hover,
.nav-link.active {
    color: var(--text-primary);
}

.nav-link.active::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 0;
    right: 0;
    height: 2px;
    background: var(--primary-gradient);
    border-radius: 2px;
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: var(--spacing-lg);
}

.search-box {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    background: var(--bg-secondary);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-lg);
    padding: var(--spacing-sm) var(--spacing-md);
    transition: all 0.3s ease;
}

.search-box:focus-within {
    border-color: var(--purple-500);
    box-shadow: 0 0 0 3px var(--purple-100);
    background: var(--bg-light);
}

.search-box input {
    background: transparent;
    border: none;
    outline: none;
    color: var(--text-primary);
    width: 200px;
}

.search-box input::placeholder {
    color: var(--text-muted);
}

.cart-icon,
.user-icon {
    position: relative;
    cursor: pointer;
    padding: var(--spacing-sm);
    border-radius: var(--radius-md);
    transition: background 0.3s ease;
}

.cart-icon:hover,
.user-icon:hover {
    background: var(--bg-secondary);
}

.badge {
    position: absolute;
    top: 0;
    right: 0;
    background: var(--primary-gradient);
    color: white;
    font-size: 0.75rem;
    font-weight: 600;
    padding: 2px 6px;
    border-radius: 10px;
    min-width: 18px;
    text-align: center;
}

/* Hero Section */
.hero {
    position: relative;
    padding: var(--spacing-3xl) 0;
    overflow: hidden;
    background: linear-gradient(to bottom, rgba(59, 130, 246, 0.03) 0%, transparent 100%);
}

.hero-gradient {
    position: absolute;
    top: -50%;
    left: -10%;
    right: -10%;
    height: 150%;
    background: radial-gradient(ellipse at center, rgba(59, 130, 246, 0.08) 0%, rgba(37, 99, 235, 0.05) 50%, transparent 70%);
    pointer-events: none;
}

.hero-content {
    position: relative;
    z-index: 1;
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: var(--spacing-sm);
    background: var(--purple-100);
    border: 1px solid var(--purple-400);
    padding: var(--spacing-sm) var(--spacing-lg);
    border-radius: 50px;
    font-size: 0.875rem;
    color: var(--purple-600);
    font-weight: 500;
    margin-bottom: var(--spacing-xl);
    animation: fadeInUp 0.6s ease;
}

.badge-dot {
    width: 8px;
    height: 8px;
    background: var(--purple-500);
    border-radius: 50%;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: var(--spacing-lg);
    animation: fadeInUp 0.6s ease 0.1s backwards;
}

.gradient-text {
    background: var(--primary-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-subtitle {
    font-size: 1.25rem;
    color: var(--text-secondary);
    margin-bottom: var(--spacing-2xl);
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
    animation: fadeInUp 0.6s ease 0.2s backwards;
}

.hero-buttons {
    display: flex;
    gap: var(--spacing-md);
    justify-content: center;
    margin-bottom: var(--spacing-3xl);
    animation: fadeInUp 0.6s ease 0.3s backwards;
}

.hero-stats {
    display: flex;
    gap: var(--spacing-3xl);
    justify-content: center;
    padding-top: var(--spacing-2xl);
    border-top: 1px solid var(--border-light);
    animation: fadeInUp 0.6s ease 0.4s backwards;
}

.stat {
    text-align: center;
}

.stat-value {
    font-size: 2rem;
    font-weight: 700;
    background: var(--primary-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.stat-label {
    font-size: 0.875rem;
    color: var(--text-secondary);
    margin-top: var(--spacing-xs);
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    gap: var(--spacing-sm);
    padding: var(--spacing-md) var(--spacing-xl);
    border-radius: var(--radius-lg);
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s ease;
    cursor: pointer;
    border: none;
    font-size: 1rem;
}

.btn-primary {
    background: var(--primary-gradient);
    color: white;
    box-shadow: var(--shadow-lg);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-xl), var(--shadow-glow);
}

.btn-outline {
    background: transparent;
    color: var(--text-primary);
    border: 2px solid var(--border-medium);
}

.btn-outline:hover {
    border-color: var(--purple-500);
    background: var(--purple-100);
    color: var(--purple-600);
}

.btn-add-cart {
    width: 100%;
    background: var(--primary-gradient);
    color: white;
    justify-content: center;
}

.btn-add-cart:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-glow);
}

/* Featured Products */
.featured-products {
    padding: var(--spacing-3xl) 0;
}

.section-header {
    text-align: center;
    margin-bottom: var(--spacing-2xl);
}

.section-title {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: var(--spacing-sm);
}

.section-subtitle {
    font-size: 1.125rem;
    color: var(--text-secondary);
}

.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: var(--spacing-xl);
}

/* Product Card */
.product-card {
    background: var(--bg-light);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-xl);
    overflow: hidden;
    transition: all 0.3s ease;
    box-shadow: var(--shadow-sm);
}

.product-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-xl), var(--shadow-glow);
    border-color: var(--purple-400);
}

.product-image {
    position: relative;
    aspect-ratio: 1;
    overflow: hidden;
    background: var(--bg-secondary);
}

.product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.product-card:hover .product-image img {
    transform: scale(1.1);
}

.product-badge {
    position: absolute;
    top: var(--spacing-md);
    padding: var(--spacing-xs) var(--spacing-md);
    border-radius: var(--radius-md);
    font-size: 0.75rem;
    font-weight: 600;
    z-index: 1;
}

.product-badge.member {
    left: var(--spacing-md);
    background: var(--primary-gradient);
    color: white;
    box-shadow: var(--shadow-md);
}

.product-badge.new {
    right: var(--spacing-md);
    background: var(--success);
    color: white;
    box-shadow: var(--shadow-md);
}

.product-badge.hot {
    right: var(--spacing-md);
    background: var(--warning);
    color: white;
    box-shadow: var(--shadow-md);
}

.product-overlay {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    display: flex;
    gap: var(--spacing-md);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.product-card:hover .product-overlay {
    opacity: 1;
}

.btn-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.95);
    border: 1px solid var(--border-light);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: var(--shadow-md);
}

.btn-icon:hover {
    background: white;
    transform: scale(1.1);
    box-shadow: var(--shadow-lg);
}

.btn-icon svg {
    stroke: var(--text-primary);
}

.product-info {
    padding: var(--spacing-lg);
}

.product-category {
    font-size: 0.75rem;
    color: var(--purple-500);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: var(--spacing-xs);
}

.product-name {
    font-size: 1.125rem;
    font-weight: 600;
    margin-bottom: var(--spacing-sm);
    line-height: 1.4;
    color: var(--text-primary);
}

.product-rating {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    margin-bottom: var(--spacing-md);
}

.stars {
    color: #F59E0B;
    font-size: 0.875rem;
}

.rating-count {
    font-size: 0.875rem;
    color: var(--text-muted);
}

.product-prices {
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
    margin-bottom: var(--spacing-sm);
}

.price-original {
    font-size: 0.875rem;
    color: var(--text-muted);
    text-decoration: line-through;
}

.price-current {
    font-size: 1.5rem;
    font-weight: 700;
    background: var(--primary-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.product-member-price {
    display: flex;
    align-items: center;
    gap: var(--spacing-xs);
    font-size: 0.875rem;
    color: var(--text-secondary);
    padding: var(--spacing-sm);
    background: var(--purple-100);
    border-radius: var(--radius-md);
    margin-bottom: var(--spacing-md);
    border: 1px solid var(--purple-400);
}

.member-price {
    font-weight: 700;
    color: var(--purple-600);
}

/* Membership CTA */
.membership-cta {
    padding: var(--spacing-3xl) 0;
}

.cta-card {
    background: var(--bg-light);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-2xl);
    padding: var(--spacing-3xl);
    text-align: center;
    position: relative;
    overflow: hidden;
    box-shadow: var(--shadow-lg);
}

.cta-card::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(59, 130, 246, 0.05) 0%, rgba(37, 99, 235, 0.03) 50%, transparent 70%);
    pointer-events: none;
}

.cta-content {
    position: relative;
    z-index: 1;
    margin-bottom: var(--spacing-xl);
}

.cta-title {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: var(--spacing-md);
}

.cta-subtitle {
    font-size: 1.125rem;
    color: var(--text-secondary);
    margin-bottom: var(--spacing-xl);
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.cta-features {
    display: flex;
    gap: var(--spacing-2xl);
    justify-content: center;
    position: relative;
    z-index: 1;
}

.feature {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
}

.feature-icon {
    width: 24px;
    height: 24px;
    background: var(--primary-gradient);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.875rem;
    color: white;
}

.feature-text {
    font-weight: 500;
    color: var(--text-primary);
}

/* Footer */
.footer {
    background: var(--bg-light);
    border-top: 1px solid var(--border-light);
    padding: var(--spacing-3xl) 0 var(--spacing-xl);
    margin-top: var(--spacing-3xl);
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: var(--spacing-2xl);
    margin-bottom: var(--spacing-2xl);
}

.footer-title {
    font-size: 1.5rem;
    font-weight: 700;
    background: var(--primary-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: var(--spacing-md);
}

.footer-text {
    color: var(--text-secondary);
    line-height: 1.6;
}

.footer-heading {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: var(--spacing-md);
    color: var(--text-primary);
}

.footer-section {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-sm);
}

.footer-link {
    color: var(--text-secondary);
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-link:hover {
    color: var(--purple-500);
}

.footer-bottom {
    text-align: center;
    padding-top: var(--spacing-xl);
    border-top: 1px solid var(--border-light);
    color: var(--text-muted);
    font-size: 0.875rem;
}

/* Responsive */
@media (max-width: 768px) {
    .nav-links {
        display: none;
    }
    
    .search-box input {
        width: 120px;
    }
    
    .hero-title {
        font-size: 2.5rem;
    }
    
    .hero-subtitle {
        font-size: 1rem;
    }
    
    .hero-buttons {
        flex-direction: column;
    }
    
    .hero-stats {
        gap: var(--spacing-xl);
    }
    
    .products-grid {
        grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    }
    
    .cta-features {
        flex-direction: column;
        gap: var(--spacing-md);
    }

/* Order Pages Styles */
.page-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 20px;
}

.page-title {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 30px;
}

.back-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
    color: var(--text-secondary);
    font-weight: 500;
    margin-bottom: 20px;
    transition: color 0.2s;
}

.back-link:hover { color: var(--purple-600); }

/* Order List (orders.html) */
.orders-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.order-card {
    background: white;
    border-radius: 12px;
    box-shadow: 0 4px 6px -1px rgba(0,0,0,0.05);
    border: 1px solid var(--border-light);
    padding: 24px;
    transition: all 0.2s ease;
}

.order-card:hover {
    box-shadow: 0 10px 15px -3px rgba(0,0,0,0.05);
    transform: translateY(-2px);
}

.order-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--border-light);
}

.order-title {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.order-id {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-primary);
}

.order-date, .order-meta {
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.order-stats {
    display: flex;
    gap: 40px;
    margin-bottom: 20px;
}

.stat-item {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.btn-details {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    background: white;
    border: 2px solid var(--border-light);
    color: var(--text-primary);
    border-radius: 8px;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.2s ease;
}

.btn-details:hover {
    border-color: var(--purple-500);
    color: var(--purple-600);
    background: var(--purple-100);
}

/* Status Badges */
.status-badge {
    padding: 6px 12px;
    border-radius: 50px;
    font-size: 0.875rem;
    font-weight: 600;
    text-transform: capitalize;
    display: inline-block;
}

.status-badge.pendiente, .status-pendiente { background: #fff7ed; color: #c2410c; }
.status-badge.procesando, .status-procesando { background: #eff6ff; color: #1d4ed8; }
.status-badge.enviado, .status-enviado { background: #f0fdf4; color: #15803d; }
.status-badge.entregado, .status-entregado { background: #ecfdf5; color: #059669; }
.status-badge.cancelado, .status-cancelado { background: #fef2f2; color: #b91c1c; }

/* Order Details (order-details.html) */
.header-section {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 40px;
}

.order-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 40px;
}

.order-items {
    background: white;
    border: 1px solid var(--border-light);
    border-radius: 12px;
    overflow: hidden;
    margin-bottom: 20px;
}

.order-item {
    display: flex;
    align-items: center;
    padding: 20px;
    border-bottom: 1px solid var(--border-light);
    gap: 20px;
}

.order-item:last-child { border-bottom: none; }

.item-image img {
    width: 80px;
    height: 80px;
    object-fit: cover;
    border-radius: 8px;
    background: #f8fafc;
}

.item-details { flex: 1; }

.item-name {
    font-weight: 600;
    color: var(--text-primary);
    display: block;
    margin-bottom: 4px;
}

.item-meta {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.item-total {
    font-weight: 600;
    color: var(--text-primary);
    font-size: 1.1rem;
}

.order-summary-box {
    background: #f8fafc;
    border-radius: 12px;
    padding: 20px;
}

.summary-row {
    display: flex;
    justify-content: space-between;
    margin-bottom: 10px;
    color: var(--text-secondary);
}

.summary-row.total {
    color: var(--text-primary);
    font-weight: 700;
    font-size: 1.2rem;
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px solid var(--border-light);
    margin-bottom: 0;
}

.info-card {
    background: white;
    border-radius: 12px;
    border: 1px solid var(--border-light);
    padding: 24px;
    margin-bottom: 20px;
}

.info-card h3 {
    font-size: 1rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 15px;
    font-weight: 600;
}

.info-card p {
    margin-bottom: 5px;
    color: var(--text-primary);
    line-height: 1.5;
}

/* Utilities */
.loader {
    border: 4px solid var(--border-light);
    border-top: 4px solid var(--purple-600);
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
    margin: 0 auto 20px;
}

.text-center { text-align: center; padding: 40px; }
.hidden { display: none !important; }

.empty-state {
    text-align: center;
    padding: 80px 20px;
}

@keyframes spin { 0% { transform: rotate(0deg); } 100% { transform: rotate(360deg); } }

@media (max-width: 900px) {
    .order-grid { grid-template-columns: 1fr; }
}

@media (max-width: 640px) {
    .order-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }
    .order-stats {
        flex-direction: column;
        gap: 15px;
    }
}
