/* ========================================
   PreciosPe - CSS Profesional y Compacto
   ======================================== */

/* Reset y Variables */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    /* ==========================================
       PALETA MINIMALISTA - 3 COLORES + GRISES
       Inspirada en: Stripe, Linear, Apple
       ========================================== */

    /* ESCALA DE GRISES (Base del diseño - 95% del sitio) */
    --gray-50: #FAFAFA;        /* Fondo muy claro */
    --gray-100: #F5F5F5;       /* Fondo claro */
    --gray-200: #E5E5E5;       /* Bordes suaves */
    --gray-300: #D4D4D4;       /* Bordes */
    --gray-400: #A3A3A3;       /* Iconos disabled */
    --gray-500: #737373;       /* Texto secundario */
    --gray-600: #525252;       /* Texto principal */
    --gray-700: #404040;       /* Texto oscuro */
    --gray-800: #262626;       /* Casi negro */
    --gray-900: #171717;       /* Negro suave */

    /* COLORES DE ACENTO (Solo 3 colores - uso muy selectivo) */
    --blue: #2563EB;           /* Azul - SOLO botón principal CTA */
    --green: #10B981;          /* Verde - SOLO "Mejor Precio" */
    --red: #EF4444;            /* Rojo - SOLO errores críticos */

    /* ALIASES SEMÁNTICOS (para facilitar el código) */
    --text: var(--gray-900);
    --text-light: var(--gray-600);
    --text-muted: var(--gray-500);
    --bg: #FFFFFF;
    --bg-gray: var(--gray-50);
    --border: var(--gray-200);

    /* CTAs y estados */
    --primary: var(--blue);
    --success: var(--green);
    --danger: var(--red);

    /* Sombras sutiles */
    --shadow-sm: 0 1px 2px rgba(15,23,42,0.04);
    --shadow: 0 1px 3px rgba(15,23,42,0.08);
    --shadow-md: 0 4px 6px rgba(15,23,42,0.07);
    --shadow-lg: 0 10px 20px rgba(15,23,42,0.10);

    /* Bordes más redondeados (moderno) */
    --radius-sm: 6px;
    --radius: 8px;
    --radius-lg: 12px;

    /* Espaciado consistente */
    --spacing-xs: 0.5rem;
    --spacing-sm: 0.75rem;
    --spacing-md: 1rem;
    --spacing-lg: 1.5rem;
    --spacing-xl: 2rem;
    --spacing-2xl: 2.5rem;
    --spacing-3xl: 3rem;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    color: var(--text);
    background: var(--bg-gray);
    line-height: 1.5;
    font-size: 15px;
    font-feature-settings: 'cv02', 'cv03', 'cv04', 'cv11';
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    padding-top: 0;
}

.container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 var(--spacing-lg);
}

.hidden {
    display: none !important;
}

/* ========================================
   Header con búsqueda integrada - ESTABLE Y FIJO
   ======================================== */
.header {
    background: white;
    color: var(--text);
    padding: 1.25rem 0;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    border-bottom: 1px solid var(--border);
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    width: 100%;
    z-index: 1000;
    /* Optimizaciones avanzadas para eliminar completamente el temblor */
    transform: translate3d(0, 0, 0);
    -webkit-transform: translate3d(0, 0, 0);
    -webkit-backface-visibility: hidden;
    backface-visibility: hidden;
    will-change: transform;
    contain: layout style paint;
    /* Sin transiciones para evitar jank durante scroll */
}

/* Header compacto al hacer scroll - SIN cambiar padding para evitar saltos */
.header.scrolled {
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.header.scrolled .quick-search {
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    margin-top: 0;
    padding-top: 0;
    transition: all 0.3s ease;
}

.header-content {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.header-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
}

/* Logo mejorado */
.logo {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    color: var(--primary);
    flex-shrink: 0;
    transition: opacity 0.2s ease;
}

.logo:hover {
    opacity: 0.9;
}

.logo-icon {
    width: 44px;
    height: 44px;
    flex-shrink: 0;
}

.logo-icon svg {
    width: 100%;
    height: 100%;
    filter: drop-shadow(0 2px 6px rgba(0,0,0,0.15));
}

.logo-text {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.logo-text h1 {
    font-size: 1.625rem;
    font-weight: 800;
    letter-spacing: -0.5px;
    line-height: 1;
    margin: 0;
}

.logo-tagline {
    font-size: 0.6875rem;
    opacity: 0.92;
    font-weight: 500;
    letter-spacing: 0.3px;
}

/* Búsqueda mejorada */
.header-search {
    flex: 1;
    max-width: 720px;
    margin: 0 auto 0 2rem;
}

.search-box {
    display: flex;
    align-items: center;
    background: white;
    border-radius: 10px;
    padding: 0 1rem;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08), 0 0 0 1px rgba(255, 255, 255, 0.1);
    transition: all 0.2s ease;
    height: 54px;
}

.search-box:focus-within {
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.12), 0 0 0 2px rgba(255, 255, 255, 0.2);
    transform: translateY(-1px);
}

.search-icon {
    color: #64748B;
    flex-shrink: 0;
    margin-right: 0.875rem;
    opacity: 0.7;
    transition: opacity 0.2s ease;
}

.search-box:focus-within .search-icon {
    opacity: 1;
}

.search-box input {
    flex: 1;
    border: none;
    outline: none;
    font-size: 15px;
    color: var(--text);
    background: transparent;
    font-weight: 500;
}

.search-box input::placeholder {
    color: var(--text-muted);
    font-weight: 400;
}

.btn-search {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 0.625rem 1.5rem;
    background: var(--blue);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    white-space: nowrap;
    flex-shrink: 0;
    min-height: 44px;
    box-shadow: 0 2px 8px rgba(37, 99, 235, 0.25);
}

/* Botón Registra tu Tienda */
.btn-register-store {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 0.625rem 1.25rem;
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
    text-decoration: none;
    border-radius: 8px;
    font-size: 0.9375rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    white-space: nowrap;
    flex-shrink: 0;
    min-height: 44px;
    box-shadow: 0 2px 8px rgba(16, 185, 129, 0.25);
}

.btn-register-store:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.35);
}

.btn-register-store svg {
    flex-shrink: 0;
}

.btn-search:hover {
    background: var(--gray-800);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.4);
}

.btn-search:active {
    transform: translateY(0);
}

.btn-icon {
    display: none;
}

/* Quick Search Pills mejoradas */
.quick-search {
    display: flex;
    align-items: center;
    gap: 0.625rem;
    flex-wrap: wrap;
    transition: all 0.3s ease;
}

.pill {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 0.5rem 1rem;
    background: white;
    border: 1px solid var(--border);
    border-radius: 8px;
    font-size: 13px;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    font-weight: 500;
    color: var(--text);
}

.pill svg {
    flex-shrink: 0;
    opacity: 0.6;
    stroke: var(--text-light);
}

.pill:hover {
    background: var(--bg-gray);
    border-color: var(--text-light);
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.pill:hover svg {
    opacity: 1;
}

/* Botones secundarios */
.btn-secondary {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 0.75rem 1.25rem;
    background: white;
    color: var(--text);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    white-space: nowrap;
}

.btn-secondary:hover {
    background: var(--bg-gray);
    border-color: var(--text-light);
}

/* ========================================
   Comparación Inteligente (Resumen)
   ======================================== */
.comparison-section {
    padding: 2rem 0;
    background: var(--bg-gray);
    border-top: 2px solid var(--border);
}

.comparison-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1.5rem;
    justify-content: center;
}

.comparison-icon {
    color: var(--primary);
    flex-shrink: 0;
}

.comparison-title {
    font-size: 1.375rem;
    font-weight: 700;
    color: var(--text);
    margin-bottom: 0.25rem;
}

.comparison-subtitle {
    font-size: 0.875rem;
    color: var(--text-light);
}

.top-offers-table {
    background: white;
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    overflow: hidden;
}

.offer-row {
    display: grid;
    grid-template-columns: 140px 1fr;
    align-items: center;
    gap: 1.5rem;
    padding: 0.75rem 1.25rem;
    border-bottom: 1px solid var(--border);
}

.offer-row:last-child {
    border-bottom: none;
}

.offer-row:hover {
    background: var(--gray-50);
}

.offer-label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text);
}

.offer-label svg {
    color: var(--primary);
    flex-shrink: 0;
}

.offer-info {
    font-size: 0.875rem;
}

.section-title {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    color: var(--text);
}

.section-title svg {
    color: var(--primary);
}

.comparison-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.25rem;
}

.comparison-card {
    background: white;
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    box-shadow: var(--shadow-md);
    border: 2px solid transparent;
    transition: all 0.3s;
    position: relative;
    overflow: hidden;
}

.comparison-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--primary);
}

.comparison-card.best-price::before {
    background: linear-gradient(90deg, var(--success), var(--green));
}

.comparison-card.best-value::before {
    background: linear-gradient(90deg, var(--blue), var(--gray-800));
}

.comparison-card.best-discount::before {
    background: linear-gradient(90deg, var(--danger), var(--red));
}

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

.card-badge {
    font-size: 0.875rem;
    font-weight: 700;
    color: var(--text);
    margin-bottom: 1rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid var(--border);
}

.comparison-product {
    min-height: 200px;
}

/* ======== NUEVO: Estilo Google Shopping ======== */
.section-header {
    text-align: center;
    margin-bottom: 2rem;
}

.section-subtitle {
    color: var(--text-light);
    font-size: 0.9375rem;
    margin: 0.5rem 0 0;
}

/* Grid tipo Google */
.top-offers-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 1.5rem;
    max-width: 1200px;
    margin: 0 auto;
}

/* Cards estilo Google Shopping */
.offer-card {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid #e5e7eb;
}

.offer-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 12px 24px rgba(0,0,0,0.15);
    border-color: var(--primary);
}

/* Badges mejorados */
.offer-badge {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 0.75rem 1.25rem;
    font-size: 0.8125rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.best-price-badge {
    background: linear-gradient(135deg, var(--success) 0%, var(--green) 100%);
    color: white;
}

.best-value-badge {
    background: linear-gradient(135deg, var(--blue) 0%, var(--gray-800) 100%);
    color: white;
}

.best-discount-badge {
    background: linear-gradient(135deg, var(--danger) 0%, var(--red) 100%);
    color: white;
}

.offer-badge svg {
    width: 14px;
    height: 14px;
}

/* Contenido de la oferta */
.offer-content {
    padding: 1.5rem;
    min-height: 280px;
    display: flex;
    flex-direction: column;
}

.offer-content img {
    width: 100%;
    height: 200px;
    object-fit: contain;
    margin-bottom: 1rem;
    border-radius: 8px;
    background: #f9fafb;
}

.offer-content h3 {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text);
    line-height: 1.4;
    margin: 0 0 0.75rem;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.offer-price {
    font-size: 1.875rem;
    font-weight: 700;
    color: var(--primary);
    margin: 0.5rem 0;
}

.offer-store {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    color: var(--text-light);
    margin-bottom: 1rem;
}

.offer-savings {
    background: linear-gradient(135deg, #fff3e0 0%, #ffe0b2 100%);
    color: var(--gray-800);
    padding: 0.5rem 0.75rem;
    border-radius: 6px;
    font-size: 0.875rem;
    font-weight: 600;
    margin-bottom: 1rem;
    text-align: center;
    border-left: 3px solid var(--blue);
}

.offer-btn {
    width: 100%;
    padding: 0.875rem;
    background: linear-gradient(135deg, var(--blue) 0%, var(--gray-800) 100%);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 0.9375rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    margin-top: auto;
    box-shadow: 0 2px 8px rgba(255, 111, 0, 0.25);
}

.offer-btn:hover {
    background: linear-gradient(135deg, var(--gray-800) 0%, #c43e00 100%);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(255, 111, 0, 0.35);
}

.comparison-product .product-image {
    height: 140px;
    margin-bottom: 1rem;
}

.comparison-product .product-name {
    font-size: 0.9375rem;
    margin-bottom: 0.75rem;
}

.comparison-product .product-price {
    font-size: 1.75rem;
    color: var(--gray-500);
}

.comparison-product .savings {
    display: inline-block;
    margin-top: 0.5rem;
    padding: 0.375rem 0.75rem;
    background: var(--gray-500);
    color: white;
    border-radius: 999px;
    font-size: 0.875rem;
    font-weight: 600;
}

/* ========================================
   Hero Section - Página de Inicio
   ======================================== */
.hero-section {
    background: linear-gradient(135deg, #f0f9ff 0%, #e0f2fe 100%);
    padding: var(--spacing-2xl) 0;
}

.hero-content {
    text-align: center;
    margin-bottom: var(--spacing-2xl);
}

.hero-title {
    font-size: 2rem;
    font-weight: 800;
    color: var(--gray-900);
    margin-bottom: 0.75rem;
    line-height: 1.2;
}

.hero-subtitle {
    font-size: 1.125rem;
    color: var(--text);
    margin-bottom: var(--spacing-xl);
}

.hero-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--spacing-md);
    max-width: 800px;
    margin: 0 auto;
}

.hero-stat {
    display: flex;
    align-items: center;
    gap: 0.875rem;
    padding: var(--spacing-md);
    background: white;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border);
    transition: all 0.3s ease;
}

.hero-stat:hover {
    border-color: var(--primary);
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
}

.hero-stat-icon {
    flex-shrink: 0;
    stroke: var(--gray-600);
    opacity: 1;
}

.hero-stat-content {
    flex: 1;
    text-align: left;
}

.hero-stat-number {
    font-size: 1.75rem;
    font-weight: 800;
    color: var(--primary);
    line-height: 1.2;
    margin-bottom: 0.25rem;
}

.hero-stat-label {
    font-size: 0.875rem;
    color: var(--text);
    font-weight: 600;
}

/* ========================================
   Tiendas que Consultamos
   ======================================== */
/* ========================================
   Value Banner - Banner de Valor
   ======================================== */
.value-banner {
    background: linear-gradient(135deg, #EFF6FF 0%, #F5F3FF 100%);
    border-radius: 16px;
    padding: 3rem 2.5rem;
    margin: 3rem 0;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    align-items: center;
    overflow: hidden;
}

.value-content {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.value-title {
    font-size: 2.25rem;
    font-weight: 800;
    color: var(--gray-900);
    line-height: 1.2;
    letter-spacing: -0.5px;
}

.value-subtitle {
    font-size: 1.125rem;
    color: var(--gray-600);
    line-height: 1.6;
}

.value-stats {
    display: flex;
    gap: 2rem;
    padding: 1.5rem 0;
}

.value-stat {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.value-stat-number {
    font-size: 2rem;
    font-weight: 800;
    color: var(--blue);
    line-height: 1;
}

.value-stat-label {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--gray-600);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.btn-offers {
    background: var(--blue);
    color: white;
    padding: 1rem 2rem;
    border: none;
    border-radius: 10px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    align-self: flex-start;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.25);
}

.btn-offers:hover {
    background: var(--gray-900);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(37, 99, 235, 0.35);
}

.value-images {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
    position: relative;
}

.value-image {
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
}

.value-image:hover {
    transform: scale(1.05);
}

.value-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.value-image-1 {
    grid-column: 1 / 2;
    grid-row: 1 / 2;
    height: 200px;
}

.value-image-2 {
    grid-column: 2 / 3;
    grid-row: 1 / 3;
    height: 420px;
}

.value-image-3 {
    grid-column: 1 / 2;
    grid-row: 2 / 3;
    height: 200px;
}

.featured-categories {
    margin-bottom: var(--spacing-2xl);
}

.featured-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--gray-900);
    margin-bottom: var(--spacing-lg);
    text-align: center;
}

.categories-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--spacing-md);
    max-width: 1000px;
    margin: 0 auto;
}

.category-card {
    position: relative;
    border-radius: var(--radius-lg);
    overflow: hidden;
    cursor: pointer;
    transition: all 0.3s;
    min-height: 180px;
    border: none;
}

.category-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    position: absolute;
    top: 0;
    left: 0;
    transition: transform 0.3s ease;
}

.category-card:hover .category-image {
    transform: scale(1.1);
}

.category-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.8) 0%, rgba(0,0,0,0.4) 70%, transparent 100%);
    padding: 1.5rem 1rem;
    z-index: 1;
    transition: all 0.3s;
}

.category-card:hover .category-overlay {
    background: linear-gradient(to top, rgba(37,99,235,0.9) 0%, rgba(37,99,235,0.6) 70%, transparent 100%);
}

.category-card:hover {
    box-shadow: 0 8px 24px rgba(0,0,0,0.15);
    transform: translateY(-4px);
}

.category-name {
    font-size: 1.125rem;
    font-weight: 700;
    color: white;
    margin-bottom: 0.25rem;
}

.category-desc {
    font-size: 0.8125rem;
    color: rgba(255,255,255,0.9);
    line-height: 1.4;
}

.featured-products {
    margin-top: var(--spacing-2xl);
}

.featured-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: var(--spacing-md);
    margin-top: var(--spacing-lg);
    max-width: 100%;
}

.featured-product-card {
    background: white;
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: all 0.3s;
    cursor: pointer;
}

.featured-product-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
}

.featured-product-image {
    width: 100%;
    height: 200px;
    object-fit: contain;
    background: var(--gray-50);
    padding: 1rem;
}

.featured-product-info {
    padding: 1rem;
}

.featured-product-name {
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--gray-900);
    margin-bottom: 0.75rem;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    min-height: 2.8em;
}

.featured-product-price {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--primary);
    margin-bottom: 0.5rem;
}

.featured-product-stores {
    font-size: 0.875rem;
    color: var(--text);
    opacity: 0.8;
}

/* ========================================
   Stats Section - Compacta y Mejorada
   ======================================== */
.stats-section {
    padding: 1.25rem 0;
    background: white;
}

.stats-bar {
    display: flex;
    align-items: center;
    justify-content: center;
    background: white;
    border: 2px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 1rem 1.5rem;
    gap: 3rem;
    box-shadow: var(--shadow-sm);
}

.stat-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.stat-item.stat-price .stat-value-inline {
    color: var(--primary);
    font-size: 1.25rem;
}

.stat-item.stat-savings {
    color: var(--primary);
}

.stat-label-inline {
    font-size: 0.875rem;
    color: var(--text-light);
    font-weight: 500;
}

.stat-value-inline {
    font-size: 1rem;
    font-weight: 700;
    color: var(--text);
}

.stat-item.stat-savings .stat-value-inline {
    color: var(--primary);
    font-size: 1.25rem;
}

/* ========================================
   Filters Bar
   ======================================== */
.filters-bar {
    display: flex;
    gap: 1rem;
    align-items: flex-end;
    padding: 1.5rem;
    background: white;
    border-radius: var(--radius-lg);
    margin-bottom: 1.5rem;
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border);
    flex-wrap: wrap;
}

.filter-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
    min-width: 180px;
}

.filter-label {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--text-light);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.filter-label svg {
    opacity: 0.6;
}

.filter-select {
    padding: 0.75rem 1rem;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    font-size: 0.875rem;
    background: white;
    cursor: pointer;
    transition: all 0.2s;
    outline: none;
}

.filter-select:hover {
    border-color: var(--text-light);
}

.filter-select:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(217, 16, 35, 0.1);
}

.price-range {
    display: flex;
    align-items: center;
    gap: 8px;
}

.price-input {
    width: 100px;
    padding: 0.75rem 0.75rem;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    font-size: 0.875rem;
    outline: none;
    transition: all 0.2s;
}

.price-input:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(217, 16, 35, 0.1);
}

.range-separator {
    color: var(--text-muted);
    font-weight: 600;
}

/* ========================================
   Results Section
   ======================================== */
.results-section {
    padding: 0.5rem 0 3rem;
}

/* Loading State */
.loading-state {
    text-align: center;
    padding: 4rem 2rem;
}

.spinner {
    width: 48px;
    height: 48px;
    border: 4px solid var(--border);
    border-top-color: var(--primary);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
    margin: 0 auto 1rem;
}

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

.loading-state p {
    color: var(--text-light);
    font-size: 1rem;
    font-weight: 500;
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 4rem 2rem;
}

.empty-state svg {
    color: var(--text-muted);
    margin-bottom: 1rem;
}

.empty-state h3 {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
    color: var(--text);
}

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

/* Products Grid - Profesional y espaciado */
.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 1.25rem;
}

.product-card {
    background: white;
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    overflow: hidden;
    transition: all 0.2s;
    cursor: pointer;
    height: 100%;
    display: flex;
    flex-direction: column;
}

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

.product-image {
    position: relative;
    width: 100%;
    height: 200px;
    overflow: hidden;
    background: var(--bg-gray);
}

.product-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 0.75rem;
    transition: transform 0.3s;
}

.product-card:hover .product-image img {
    transform: scale(1.08);
}

.product-store {
    position: absolute;
    bottom: 8px;
    left: 8px;
    padding: 5px 10px;
    background: rgba(255, 255, 255, 0.98);
    border-radius: 6px;
    font-size: 0.7rem;
    font-weight: 700;
    color: var(--primary);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    backdrop-filter: blur(8px);
    border: 1px solid rgba(15, 23, 42, 0.1);
}

.product-discount {
    position: absolute;
    top: 8px;
    right: 8px;
    padding: 4px 10px;
    background: linear-gradient(135deg, var(--danger) 0%, var(--red) 100%);
    color: white;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 700;
    box-shadow: 0 2px 8px rgba(234, 67, 53, 0.3);
}

.product-info {
    padding: 1rem;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.product-store-name {
    display: flex;
    align-items: center;
    gap: 0.375rem;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--primary);
    margin-bottom: 0.5rem;
    letter-spacing: 0.3px;
}

.product-store-name svg {
    flex-shrink: 0;
    stroke: var(--gray-600);
}

.product-name {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text);
    margin-bottom: 0.75rem;
    line-height: 1.4;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    min-height: 2.8em;
}

.product-price {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--text);
    margin-bottom: 0.625rem;
}

.product-footer {
    padding: 1rem;
    background: white;
    border-top: 1px solid var(--border);
}

.btn-view {
    width: 100%;
    padding: 0.75rem;
    background: var(--gray-900);
    color: white;
    border: none;
    border-radius: var(--radius);
    font-size: 0.875rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.btn-view:hover {
    background: var(--gray-800);
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

/* ========================================
   Chart Section
   ======================================== */
.chart-section {
    padding: 2rem 0 3rem;
    background: var(--bg-gray);
}

.chart-card {
    background: white;
    padding: 1.75rem;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border);
    max-width: 900px;
    margin: 0 auto;
}

.chart-title {
    font-size: 1.125rem;
    font-weight: 700;
    margin-bottom: 0.25rem;
    color: var(--text);
    letter-spacing: -0.025em;
}

.chart-subtitle {
    font-size: 0.8125rem;
    color: var(--text-light);
    margin-bottom: 1.5rem;
    font-weight: 400;
}

#priceChart {
    max-height: 320px;
}

/* ========================================
   Footer
   ======================================== */
/* Old footer styles removed - using modern footer design below (line 2010+) */

/* ========================================
   Responsive
   ======================================== */
@media (max-width: 768px) {
    /* Header responsive */
    .header {
        padding: 0.75rem 0;
    }

    .header-content {
        gap: 0.75rem;
    }

    .header-top {
        flex-direction: column;
        gap: 0.75rem;
    }

    .logo {
        justify-content: center;
    }

    .logo-icon {
        width: 38px;
        height: 38px;
    }

    .logo-text h1 {
        font-size: 1.375rem;
    }

    .logo-tagline {
        font-size: 0.6875rem;
    }

    .header-search {
        max-width: 100%;
        margin: 0;
        transition: opacity 0.3s ease, transform 0.3s ease;
    }

    .btn-register-store {
        display: none; /* Ocultar en móvil */
    }

    .search-box {
        height: 48px;
        padding: 0 0.875rem;
    }

    .search-box input {
        font-size: 14px;
    }

    .search-icon {
        display: none;
    }

    .btn-search .btn-text {
        display: none;
    }

    .btn-search .btn-icon {
        display: block;
    }

    .btn-search {
        padding: 0.625rem 1rem;
        min-height: 44px;
        background: transparent;
        box-shadow: none;
        -webkit-tap-highlight-color: transparent;
        outline: none;
    }

    .btn-search:focus,
    .btn-search:active {
        outline: none;
        background: transparent;
    }

    .btn-search .btn-icon {
        color: #64748B;
    }

    /* Ocultar categorías en móvil */
    .featured-categories {
        display: none;
    }

    /* Quick search móvil - scroll horizontal */
    .quick-search {
        display: flex;
        overflow-x: auto;
        overflow-y: hidden;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none; /* Firefox */
        -ms-overflow-style: none; /* IE/Edge */
        gap: 0.5rem;
        padding: 0.5rem 0;
        margin: 0;
        transition: max-height 0.3s ease, opacity 0.3s ease, margin 0.3s ease;
        max-height: 60px;
        opacity: 1;
    }

    /* Ocultar scrollbar en Chrome/Safari */
    .quick-search::-webkit-scrollbar {
        display: none;
    }

    /* Ocultar categorías al hacer scroll */
    .quick-search.hidden-scroll {
        max-height: 0;
        opacity: 0;
        margin: 0;
        padding: 0;
        overflow: hidden;
    }

    /* Hero responsive */
    .hero-section {
        padding: var(--spacing-xl) 0;
    }

    .hero-content {
        margin-bottom: var(--spacing-xl);
    }

    .hero-title {
        font-size: 1.5rem;
    }

    .hero-subtitle {
        font-size: 1rem;
    }

    .hero-stats {
        grid-template-columns: repeat(3, 1fr);
        gap: 0.5rem;
        max-width: 100%;
    }

    .hero-stat {
        padding: 0.75rem 0.5rem;
        flex-direction: column;
        gap: 0.5rem;
        text-align: center;
    }

    .hero-stat-icon {
        width: 20px;
        height: 20px;
    }

    .hero-stat-content {
        text-align: center;
    }

    .hero-stat-number {
        font-size: 1.25rem;
    }

    .hero-stat-label {
        font-size: 0.7rem;
    }

    /* Value Banner responsive en móvil */
    .value-banner {
        grid-template-columns: 1fr;
        gap: 2rem;
        padding: 2rem 1.5rem;
    }

    .value-title {
        font-size: 1.75rem;
    }

    .value-subtitle {
        font-size: 1rem;
    }

    .value-stats {
        gap: 1.5rem;
        padding: 1rem 0;
    }

    .value-stat-number {
        font-size: 1.75rem;
    }

    .value-stat-label {
        font-size: 0.75rem;
    }

    .btn-offers {
        width: 100%;
        text-align: center;
        padding: 0.875rem 1.5rem;
    }

    .value-images {
        grid-template-columns: repeat(3, 1fr);
        grid-template-rows: 150px;
        gap: 0.75rem;
    }

    .value-image-1 {
        grid-column: 1 / 2;
        grid-row: 1 / 2;
        height: 150px;
    }

    .value-image-2 {
        grid-column: 2 / 3;
        grid-row: 1 / 2;
        height: 150px;
    }

    .value-image-3 {
        grid-column: 3 / 4;
        grid-row: 1 / 2;
        height: 150px;
    }

    /* Categorías responsive: scroll horizontal en móvil */
    .featured-categories {
        margin-left: -1rem;
        margin-right: -1rem;
        padding: 0 1rem;
        position: relative;
    }

    .featured-title {
        font-size: 1.25rem;
        text-align: left;
        margin-bottom: 0.75rem;
        position: relative;
        padding-right: 60px;
    }

    /* Indicador "Desliza →" en el título */
    .featured-title::after {
        content: 'Desliza →';
        position: absolute;
        right: 0;
        top: 50%;
        transform: translateY(-50%);
        font-size: 0.75rem;
        font-weight: 500;
        color: var(--blue);
        opacity: 0.8;
    }

    .categories-grid {
        display: flex;
        overflow-x: auto;
        overflow-y: hidden;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
        -ms-overflow-style: none;
        gap: 0.75rem;
        padding: 0.75rem 0;
        scroll-snap-type: x mandatory;
        /* Padding lateral para mostrar que hay más contenido */
        padding-left: 0.5rem;
        padding-right: 0.5rem;
    }

    .categories-grid::-webkit-scrollbar {
        display: none;
    }

    /* Indicador visual sutil de que hay más contenido */
    .categories-grid::after {
        content: '';
        position: sticky;
        right: 0;
        width: 40px;
        height: 100%;
        background: linear-gradient(to left, rgba(255,255,255,0.9), transparent);
        pointer-events: none;
    }

    .category-card {
        flex: 0 0 145px;
        min-width: 145px;
        padding: 1rem 0.875rem;
        scroll-snap-align: center;
        /* Asegurar que sea tocable */
        touch-action: pan-x;
    }

    .category-card:first-child {
        margin-left: 0.5rem;
    }

    .category-card:last-child {
        margin-right: 0.5rem;
    }

    .category-icon {
        width: 32px;
        height: 32px;
        margin-bottom: 0.5rem;
    }

    .category-name {
        font-size: 1rem;
    }

    .category-desc {
        font-size: 0.8rem;
    }

    /* Productos: 2 columnas en móvil */
    .featured-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1rem;
    }

    .featured-product-image {
        height: 150px;
    }

    /* Top 3 responsive */
    .offer-row {
        grid-template-columns: 1fr;
        gap: 0.75rem;
        padding: 0.875rem;
    }

    .offer-label {
        font-size: 0.8125rem;
        font-weight: 700;
        margin-bottom: 0.25rem;
    }

    .offer-info {
        gap: 6px;
    }

    .offer-product-name {
        font-size: 0.8125rem !important;
        line-height: 1.4 !important;
        margin-bottom: 0.25rem;
        display: -webkit-box;
        -webkit-line-clamp: 2;
        -webkit-box-orient: vertical;
        overflow: hidden;
    }

    .offer-store-name {
        font-size: 0.75rem !important;
    }

    .offer-price {
        font-size: 0.8125rem !important;
    }

    .offer-link-btn {
        padding: 4px 10px;
        font-size: 0.6875rem;
    }

    .store-offer {
        padding: 6px 8px;
    }

    .offer-savings {
        font-size: 0.75rem !important;
    }

    .comparison-title {
        font-size: 1.125rem !important;
    }

    .comparison-subtitle {
        font-size: 0.8125rem !important;
    }

    /* Stats responsive: 2 columnas en móvil */
    .stats-bar {
        flex-wrap: wrap;
        gap: 1rem;
        padding: 1rem;
    }

    .stat-item {
        flex: 1 1 45%;
        justify-content: center;
    }

    .stat-label-inline {
        font-size: 0.75rem;
    }

    .stat-value-inline {
        font-size: 0.875rem;
    }

    .stat-item.stat-price .stat-value-inline,
    .stat-item.stat-savings .stat-value-inline {
        font-size: 1rem;
    }

    .comparison-grid {
        grid-template-columns: 1fr;
    }

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

    .filters-bar {
        flex-direction: column;
        align-items: stretch;
    }

    .filter-group {
        min-width: 100%;
    }

    .products-grid {
        grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
        gap: 1rem;
    }

    .product-image {
        height: 160px;
    }

    .product-name {
        font-size: 0.8125rem;
    }

    .product-price {
        font-size: 1.25rem;
    }

    .product-info {
        padding: 0.875rem;
    }

    .product-footer {
        padding: 0.875rem;
    }
}

/* Móviles pequeños: optimización adicional */
@media (max-width: 480px) {
    /* Container más compacto */
    .container {
        padding: 0 0.875rem;
    }

    /* Hero más compacto */
    .hero-title {
        font-size: 1.375rem;
        line-height: 1.3;
    }

    .hero-subtitle {
        font-size: 0.9375rem;
    }

    /* Hero stats en 2 columnas */
    .hero-stats {
        grid-template-columns: repeat(2, 1fr);
        gap: 0.625rem;
    }

    /* Última stat ocupa 2 columnas */
    .hero-stat:last-child {
        grid-column: span 2;
    }

    .hero-stat {
        padding: 0.875rem;
    }

    .hero-stat-number {
        font-size: 1.375rem;
    }

    .hero-stat-label {
        font-size: 0.6875rem;
    }

    /* Categorías scroll horizontal en móviles pequeños */
    .categories-grid {
        gap: 0.625rem;
        padding-left: 0.25rem;
        padding-right: 0.25rem;
    }

    .category-card {
        flex: 0 0 135px;
        min-width: 135px;
        padding: 0.875rem 0.625rem;
        scroll-snap-align: center;
    }

    .category-card:first-child {
        margin-left: 0.25rem;
    }

    .category-card:last-child {
        margin-right: 0.25rem;
    }

    .category-icon {
        width: 28px;
        height: 28px;
    }

    .category-name {
        font-size: 0.9375rem;
    }

    .category-desc {
        font-size: 0.75rem;
    }

    /* Productos destacados más grandes en móvil */
    .featured-grid {
        grid-template-columns: 1fr;
        gap: 1.25rem;
    }

    .featured-product-image {
        height: 200px;
    }

    /* Products grid en 1 columna */
    .products-grid {
        grid-template-columns: 1fr;
        gap: 1.25rem;
    }

    .product-image {
        height: 220px;
    }

    .product-name {
        font-size: 0.9375rem;
        line-height: 1.4;
    }

    .product-price {
        font-size: 1.5rem;
    }

    /* Botones más grandes (mejor touch target) */
    .btn-primary,
    .btn-secondary {
        padding: 0.875rem 1.5rem;
        font-size: 1rem;
        min-height: 48px;
    }

    /* Pills con mejor touch target */
    .pill {
        padding: 0.5rem 1rem;
        min-height: 44px;
    }

    /* Category cards con mejor touch target */
    .category-card {
        min-height: 110px;
    }

    /* Featured title */
    .featured-title {
        font-size: 1.25rem;
        text-align: left;
        margin-bottom: 0.875rem;
        position: relative;
        padding-right: 80px;
    }

    .featured-title::after {
        content: 'Desliza →';
        position: absolute;
        right: 0;
        top: 50%;
        transform: translateY(-50%);
        font-size: 0.75rem;
        font-weight: 500;
        color: #2563EB;
        opacity: 0.8;
    }

    /* Mejor espaciado general */
    .hero-section {
        padding: 2rem 0;
    }

    .featured-categories {
        margin-top: 2rem;
    }

    .featured-products {
        margin-top: 2rem;
    }
}

/* ========================================
   Score Calidad-Precio Badges
   ======================================== */

.score-badge {
    position: absolute;
    top: 8px;
    left: 8px;
    z-index: 10;
    padding: 5px 12px;
    border-radius: 6px;
    font-size: 0.65rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    box-shadow: 0 2px 8px rgba(15, 23, 42, 0.15);
}

.score-excelente {
    background: var(--primary);
    color: white;
}

.score-bueno {
    background: var(--blue);
    color: white;
}

.score-normal {
    background: var(--text-light);
    color: white;
}

.score-reason {
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-top: 0.25rem;
    padding: 0.25rem 0.5rem;
    background: var(--bg-light);
    border-radius: 4px;
    line-height: 1.4;
}

.product-card.best-deal {
    border: 2px solid var(--text);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
}

.product-score {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-top: 8px;
    padding: 6px 10px;
    background: var(--bg-gray);
    border-radius: var(--radius-sm);
    border-left: 3px solid var(--text);
}

.score-label {
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--gray-800);
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

.score-value {
    font-size: 0.875rem;
    font-weight: 700;
    color: var(--primary);
}

.score-reason {
    margin-top: 6px;
    padding: 6px 8px;
    background: var(--gray-100);
    border-left: 3px solid var(--primary);
    border-radius: var(--radius-sm);
    font-size: 0.7rem;
    color: var(--gray-800);
    line-height: 1.3;
}

.product-card {
    position: relative; /* Para el badge absoluto */
}

/* Animación hover para mejores ofertas */
.product-card.best-deal:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 20px rgba(16, 185, 129, 0.25);
}

/* ========== NUEVO: Productos Agrupados (estilo Google Shopping) ========== */

/* Badge de producto agrupado */
.grouped-badge {
    position: absolute;
    top: 8px;
    right: 8px;
    background: var(--primary);
    color: white;
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 600;
    box-shadow: 0 2px 6px rgba(15, 23, 42, 0.3);
    z-index: 2;
}

/* Borde especial para productos agrupados */
.product-card.grouped-product {
    border: 2px solid var(--blue);
    background: white;
}

.product-card.grouped-product:hover {
    border-color: var(--primary);
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.15);
}

/* Product savings indicator */
.product-savings {
    margin-top: 8px;
    padding: 6px 12px;
    background: linear-gradient(135deg, var(--success) 0%, var(--green) 100%);
    color: white;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 600;
    text-align: center;
    letter-spacing: 0.3px;
    box-shadow: 0 2px 6px rgba(52, 168, 83, 0.25);
}

/* Botón para ver ofertas - OUTLINE GRIS */
.btn-view-offers {
    background: white;
    color: var(--text);
    border: 1.5px solid var(--border);
    font-weight: 600;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
}

.btn-view-offers:hover {
    background: var(--bg-gray);
    border-color: var(--text);
    transform: translateY(-2px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
}

/* Botón comparación detallada - Estilo outline minimalista */
.btn-compare {
    background: white;
    color: var(--text);
    border: 1.5px solid var(--border);
    font-weight: 600;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
}

.btn-compare:hover {
    background: var(--bg-gray);
    border-color: var(--primary);
    color: var(--primary);
    transform: translateY(-2px);
    box-shadow: 0 2px 8px rgba(37, 99, 235, 0.15);
}

/* Contenedor de ofertas de tiendas */
.store-offers {
    margin-top: 12px;
    border-top: 1px solid #e5e7eb;
    padding-top: 12px;
    animation: slideDown 0.3s ease-out;
}

@keyframes slideDown {
    from {
        opacity: 0;
        max-height: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        max-height: 500px;
        transform: translateY(0);
    }
}

.store-offers.hidden {
    display: none;
}

/* Individual store offer */
.store-offer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 10px;
    margin-bottom: 6px;
    background: var(--gray-50);
    border-radius: 6px;
    border: 1px solid var(--gray-200);
    transition: all 0.2s;
}

.store-offer:hover {
    background: var(--gray-100);
    border-color: var(--gray-300);
    transform: translateX(2px);
}

.store-offer:last-child {
    margin-bottom: 0;
}

.offer-info {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    flex: 1;
}

.offer-store-name {
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--gray-800);
    flex: 0 0 auto;
}

.offer-price {
    font-size: 0.875rem;
    font-weight: 700;
    color: var(--gray-900);
}

.offer-link-btn {
    padding: 5px 12px;
    background: var(--blue);
    color: white;
    border: none;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    white-space: nowrap;
}

.offer-link-btn:hover {
    background: var(--gray-800);
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(37, 99, 235, 0.25);
}

/* ========== HEADER MEJORADO - MÁS CATEGORÍAS ========== */

.quick-search {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    justify-content: center;
    max-width: 1200px;
    margin: 0 auto;
}

.quick-search .pill {
    flex-shrink: 0;
}

/* ========== FOOTER MEJORADO - ESTILO AMAZON/MERCADOLIBRE ========== */

.footer {
    position: relative;
    width: 100%;
    background: linear-gradient(180deg, #f8f9fa 0%, #e9ecef 100%);
    padding: 60px 0 0;
    margin-top: 80px;
    border-top: 1px solid #dee2e6;
}

/* Footer Principal con Columnas */
.footer-main {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 40px;
    padding-bottom: 40px;
    border-bottom: 1px solid #dee2e6;
    margin-bottom: 30px;
}

.footer-column {
    display: flex;
    flex-direction: column;
}

.footer-column-title {
    font-size: 1rem;
    font-weight: 700;
    color: var(--text);
    margin-bottom: 16px;
    padding-bottom: 8px;
    border-bottom: 2px solid var(--primary);
}

.footer-links-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.footer-links-list li {
    font-size: 0.875rem;
}

.footer-link {
    color: var(--text-light);
    text-decoration: none;
    transition: all 0.2s;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.footer-link:hover {
    color: var(--primary);
    transform: translateX(4px);
}

.footer-link svg {
    flex-shrink: 0;
}

.footer-store {
    color: var(--text-muted);
    font-size: 0.875rem;
}

/* Footer Bottom */
.footer-bottom {
    padding-bottom: 30px;
}

.footer-logo-section {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 24px;
}

.footer-logo-section svg {
    flex-shrink: 0;
}

.footer-logo-text h3 {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text);
    margin: 0 0 4px;
}

.footer-logo-text p {
    font-size: 0.875rem;
    color: var(--text-light);
    margin: 0;
}

.footer-description {
    margin-bottom: 24px;
}

.footer-tagline {
    font-size: 0.9375rem;
    color: var(--text-light);
    margin-bottom: 16px;
    line-height: 1.6;
}

.footer-stats {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.footer-stat-badge {
    display: inline-block;
    padding: 6px 14px;
    background: linear-gradient(135deg, var(--primary) 0%, var(--gray-800) 100%);
    color: white;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    box-shadow: 0 2px 6px rgba(26, 115, 232, 0.25);
}

.footer-copyright-section {
    padding-top: 20px;
    border-top: 1px solid #dee2e6;
}

.footer-copyright {
    font-size: 0.8125rem;
    color: var(--text-muted);
    margin: 0 0 8px;
    text-align: center;
}

.footer-disclaimer {
    font-size: 0.75rem;
    color: var(--text-muted);
    margin: 0;
    text-align: center;
    font-style: italic;
}

/* Responsive Footer */
@media (max-width: 768px) {
    .footer {
        padding: 40px 0 0;
    }
    
    .footer-main {
        grid-template-columns: repeat(2, 1fr);
        gap: 30px;
    }
    
    .footer-logo-section {
        flex-direction: column;
        text-align: center;
    }
    
    .footer-stats {
        justify-content: center;
    }
}

/* ========== RESPONSIVE MOBILE - REDESIGN PROFESIONAL ========== */

/* Tablet y móvil grande */
@media (max-width: 768px) {
    /* Header compacto en mobile */
    .header {
        padding: 0.75rem 0;
    }

    /* Logo responsive: mostrar texto en móvil */
    .logo-text h1 {
        font-size: 1.125rem;
        letter-spacing: -0.3px;
    }

    .logo-tagline {
        font-size: 0.625rem;
    }

    .logo-icon {
        width: 32px;
        height: 32px;
    }

    /* Search box más compacto */
    .search-box {
        height: 40px;
        padding: 0 0.75rem;
    }

    .search-box input {
        font-size: 14px;
    }

    .btn-search {
        padding: 0.5rem 1rem;
        font-size: 14px;
        min-height: 36px;
    }

    /* Pills con scroll horizontal en móvil */
    .quick-search {
        overflow-x: auto;
        overflow-y: hidden;
        flex-wrap: nowrap;
        gap: 8px;
        padding-bottom: 4px;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none; /* Firefox */
        -ms-overflow-style: none; /* IE/Edge */
    }

    .quick-search::-webkit-scrollbar {
        display: none; /* Chrome/Safari/Opera */
    }

    .pill {
        flex-shrink: 0;
        padding: 0.5rem 1rem;
        font-size: 13px;
        border-radius: 6px;
    }
}

/* Móvil pequeño */
@media (max-width: 480px) {
    .footer-main {
        grid-template-columns: 1fr;
        gap: 24px;
    }

    /* Header aún más compacto */
    .header {
        padding: 0.625rem 0;
    }

    .logo-icon {
        width: 28px;
        height: 28px;
    }

    /* Search responsive */
    .header-search {
        margin: 0;
    }

    .search-box {
        height: 38px;
        padding: 0 0.625rem;
    }

    .search-icon {
        margin-right: 0.625rem;
    }

    .btn-search {
        padding: 0.5rem 0.875rem;
        font-size: 13px;
    }

    /* Pills compactos en móvil pequeño */
    .quick-search {
        gap: 6px;
    }

    .pill {
        font-size: 0.75rem;
        padding: 6px 10px;
    }
}
