/* ==========================================
   SHOPPING BY NIGHT - Estilos Globales v2.3
   ========================================== */

:root {
    --primary: #061b55;
    --primary-light: #eef2ff;
    --accent: #f43f5e;
    --accent-light: #fff1f2;
    --bg: #ffffff;
    --bg-secondary: #f9fafb;
    --text: #4b5563;
    --text-light: #9ca3af;
    --text-secondary: #475569;
    --text-muted: #64748b;
    --success: #10b981;
    --white: #ffffff;
    --gray-light: #f3f4f6;
    --gray: #e5e7eb;
    --gray-dark: #d1d5db;
    --shadow: 0 4px 24px rgba(0, 0, 0, 0.04);
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.02);
    --shadow-md: 0 8px 32px rgba(0, 0, 0, 0.06);
    --radius: 16px;
    --radius-sm: 10px;
    --transition: all 0.3s ease;
    --font: 'Inter', 'Roboto', -apple-system, BlinkMacSystemFont, sans-serif;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font);
    background-color: var(--bg);
    color: var(--text);
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* ==========================================
   HEADER
   ========================================== */

.header {
    background: var(--white);
    border-bottom: 1px solid var(--gray);
    padding: 0.75rem 2rem;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: var(--shadow-sm);
}

.header-inner {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 70px;
    gap: 1rem;
}

.logo {
    font-size: 6rem;
    font-weight: 700;
    color: var(--primary);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-shrink: 0;
}

.logo-img {
    height: 74px;
    width: auto;
    max-width: 300px;
    display: block;
}

@media (max-width: 768px) {
    .logo-img {
        height: 56px;
        max-width: 220px;
    }
    
    .header {
        padding: 0.5rem 1rem;
    }
    
    .header-inner {
        min-height: 60px;
    }
}

.nav {
    display: flex;
    align-items: center;
    gap: 2rem;
}

.nav a {
    color: var(--text);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.95rem;
    transition: var(--transition);
}

.nav a:hover {
    color: var(--accent);
}

.lang-selector {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: var(--gray-light);
    border-radius: 20px;
    padding: 0.4rem 0.8rem;
    cursor: pointer;
    position: relative;
}

.lang-selector select {
    background: transparent;
    border: none;
    font-family: var(--font);
    font-size: 0.9rem;
    color: var(--text);
    cursor: pointer;
    outline: none;
}

.lang-selector select option {
    background: var(--white);
    color: var(--text);
}

/* ==========================================
   HERO — Tamaño original
   ========================================== */

.hero {
    background: linear-gradient(135deg, var(--bg-secondary) 0%, var(--white) 100%);
    color: var(--primary);
    padding: 3rem 2rem;
    text-align: center;
    position: relative;
    overflow: hidden;
    border-bottom: 1px solid var(--gray-light);
}

.hero::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(79, 70, 229, 0.03) 0%, transparent 60%);
    animation: pulse 4s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

.hero-inner {
    max-width: 800px;
    margin: 0 auto;
    position: relative;
    z-index: 1;
}

.hero h1 {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 1rem;
    line-height: 1.2;
}

.hero h1 span {
    color: var(--accent);
}

.hero p {
    font-size: 1.25rem;
    opacity: 0.9;
    margin-bottom: 2rem;
}

.search-box {
    display: flex;
    max-width: 600px;
    margin: 0 auto 3rem;
    background: var(--white);
    border-radius: 50px;
    overflow: hidden;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.3);
}

.search-box input {
    flex: 1;
    padding: 1rem 1.5rem;
    border: none;
    font-size: 1rem;
    font-family: var(--font);
    outline: none;
    color: var(--text);
}

.search-box button {
    padding: 1rem 2rem;
    background: var(--accent);
    color: var(--white);
    border: none;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    font-family: var(--font);
    font-size: 1rem;
}

.search-box button:hover {
    background: #d63050;
}

.hero-stats {
    display: flex;
    justify-content: center;
    gap: 3rem;
}

.stat {
    text-align: center;
}

.stat-number {
    font-size: 2rem;
    font-weight: 700;
    color: var(--primary);
}

.stat-label {
    font-size: 0.9rem;
    color: var(--text-light);
}

/* ==========================================
   CATEGORÍAS
   ========================================== */

.categories {
    padding: 4rem 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

.section-title {
    text-align: center;
    margin-bottom: 2rem;
}

.section-title h2 {
    font-size: 2rem;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 0.5rem;
}

.section-title p {
    font-size: 1rem;
    color: var(--text-light);
}

.categories-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 1.5rem;
}

.category-card {
    background: var(--white);
    border-radius: var(--radius);
    padding: 1.5rem;
    text-align: center;
    text-decoration: none;
    color: var(--text);
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    border: 2px solid transparent;
}

.category-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
    border-color: var(--primary);
}

.category-icon {
    font-size: 2rem;
    margin-bottom: 0.75rem;
}

.category-card h3 {
    font-size: 1rem;
    font-weight: 600;
    color: var(--primary);
    margin-bottom: 0.5rem;
}

.category-card p {
    font-size: 0.8rem;
    color: var(--text-light);
    line-height: 1.4;
}

/* ==========================================
   CODE CARDS - TARJETAS DE DESCUENTO
   ========================================== */

.codes-section {
    padding: 4rem 2rem;
    max-width: 1200px;
    margin: 0 auto;
    flex: 1;
}

.codes-inner {
    max-width: 1200px;
    margin: 0 auto;
}

.codes-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    flex-wrap: wrap;
    gap: 1rem;
}

.codes-header h2 {
    font-size: 2rem;
    font-weight: 700;
    color: var(--primary);
}

.codes-filters {
    display: flex;
    gap: 0.75rem;
}

.filter-select {
    padding: 0.5rem 1rem;
    border: 1px solid var(--gray);
    border-radius: var(--radius-sm);
    font-family: var(--font);
    font-size: 0.9rem;
    color: var(--text);
    background: var(--white);
    cursor: pointer;
    outline: none;
}

.codes-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1.5rem;
    margin-top: 2rem;
}

.code-card {
    background: var(--white);
    border-radius: var(--radius);
    padding: 1.5rem;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    border: 2px solid transparent;
}

.code-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
    border-color: var(--primary);
}

.code-header {
    display: flex;
    align-items: center;
    margin-bottom: 1rem;
}

.code-badge {
    background: var(--success);
    color: white;
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
}

.code-store {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-muted);
    margin-bottom: 0.5rem;
}

.code-discount {
    font-size: 2rem;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 0.5rem;
}

.code-description {
    color: var(--text-secondary);
    margin-bottom: 1rem;
    line-height: 1.5;
}

.code-meta {
    display: flex;
    gap: 1rem;
    font-size: 0.875rem;
    color: var(--text-muted);
    margin-bottom: 1rem;
}

.code-actions {
    display: flex;
    gap: 0.75rem;
}

.btn-copy {
    background: var(--primary-light);
    color: var(--primary);
    border: 2px solid var(--primary);
    padding: 0.5rem 1rem;
    border-radius: 8px;
    font-size: 0.875rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}

.btn-copy:hover {
    background: var(--primary);
    color: white;
}

.btn-apply {
    background: var(--accent);
    color: white;
    border: none;
    padding: 0.5rem 1.25rem;
    border-radius: 8px;
    font-size: 0.875rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}

.btn-apply:hover {
    background: #d63050;
}

/* Toast notification */
.toast {
    position: fixed;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    background: var(--primary);
    color: white;
    padding: 1rem 2rem;
    border-radius: 12px;
    font-weight: 600;
    box-shadow: var(--shadow-md);
    z-index: 10000;
    animation: toast-in 0.3s ease;
}

@keyframes toast-in {
    from { opacity: 0; transform: translateX(-50%) translateY(20px); }
    to { opacity: 1; transform: translateX(-50%) translateY(0); }
}

/* ==========================================
   FOOTER
   ========================================== */

.footer {
    background: var(--bg-secondary);
    border-top: 1px solid var(--gray);
    padding: 3rem 2rem 1.5rem;
    margin-top: auto;
}

.footer-inner {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.footer-col h3 {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 0.75rem;
}

.footer-col p {
    font-size: 0.875rem;
    color: var(--text-muted);
    line-height: 1.5;
}

.footer-links {
    list-style: none;
}

.footer-links li {
    margin-bottom: 0.5rem;
}

.footer-links a {
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.875rem;
    transition: var(--transition);
}

.footer-links a:hover {
    color: var(--primary);
}

.footer-bottom {
    max-width: 1200px;
    margin: 2rem auto 0;
    padding-top: 1.5rem;
    border-top: 1px solid var(--gray);
    text-align: center;
}

.footer-bottom p {
    font-size: 0.8rem;
    color: var(--text-light);
}

/* ==========================================
   SOCIAL LINKS
   ========================================== */

.social-links {
    display: flex;
    gap: 0.75rem;
    margin-top: 0.5rem;
}

.social-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--primary-light);
    color: var(--primary);
    transition: var(--transition);
}

.social-icon:hover {
    background: var(--primary);
    color: var(--white);
}

.social-icon svg {
    width: 18px;
    height: 18px;
}

.social-icon[aria-label="Instagram"] {
    background: linear-gradient(45deg, #feda75, #fa7e1e, #d62976, #962fbf, #4f5bd5);
    color: #ffffff;
}

.social-icon[aria-label="Facebook"] {
    background: #1877f2;
    color: #ffffff;
}

/* ==========================================
   RESPONSIVE
   ========================================== */

@media (max-width: 768px) {
    .hero { padding: 3rem 1rem; }
    .hero h1 { font-size: 2rem; }
    .hero p { font-size: 1rem; }
    .search-box { max-width: 100%; }
    .hero-stats { gap: 1.5rem; }
    .stat-number { font-size: 1.5rem; }
    
    .categories { padding: 2rem 1rem; }
    .categories-grid { grid-template-columns: repeat(2, 1fr); }
    
    .codes-section { padding: 2rem 1rem; }
    .codes-grid { grid-template-columns: 1fr; }
    .code-actions { flex-direction: column; }
    
    .footer-inner { grid-template-columns: 1fr; }
}
