/* ==========================================================================
   Variables de Entorno y Paleta de Colores (Estilo Neomorfismo/Glassmorphism limpio)
   ========================================================================== */
:root {
    --primary-gradient: linear-gradient(135deg, #FF512F 0%, #F09819 100%); /* Mango & Chamoy */
    --secondary-gradient: linear-gradient(135deg, #f857a6 0%, #ff5858 100%);
    --bg-dark: #121212;
    --bg-light: #fdfbf7;
    --card-light: #ffffff;
    --card-dark: #1e1e1e;
    --text-main: #2c3e50;
    --text-muted: #5a6c7d;
    --accent-color: #FFD700;
    --border-radius-lg: 16px;
    --border-radius-sm: 8px;
    --transition-smooth: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    --shadow-elegant: 0 10px 30px rgba(0, 0, 0, 0.08);
}

/* ==========================================================================
   Estilos Base y Tipografía
   ========================================================================== */
* {
    box-sizing: border-box;
}

body {
    font-family: 'Poppins', sans-serif;
    background-color: var(--bg-light);
    color: var(--text-main);
    margin: 0;
    padding: 0;
    line-height: 1.6;
    overflow-x: hidden;
}

/* ==========================================================================
   Estructura Header & Hero (Diseño Dividido Moderno)
   ========================================================================== */
.main-header {
    background: var(--primary-gradient);
    padding: 4rem 2rem;
    color: #ffffff;
    position: relative;
    clip-path: ellipse(140% 100% at 50% 0%);
}

.header-container {
    max-width: 1200px;
    margin: 0 auto;
}

.hero {
    display: flex;
    flex-direction: column-reverse;
    align-items: center;
    justify-content: space-between;
    gap: 3rem;
}

@media (min-width: 768px) {
    .hero {
        flex-direction: row;
        text-align: left;
    }
    .hero-text {
        flex: 1;
    }
    .logo-seccion {
        flex: 1;
    }
}

h1 {
    font-size: 2.6rem;
    font-weight: 700;
    line-height: 1.2;
    margin: 0 0 1.5rem 0;
    color: #ffffff;
}

@media (min-width: 992px) {
    h1 { font-size: 3.5rem; }
}

.text-highlight {
    color: var(--accent-color);
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.2);
}

.parrafo {
    font-size: 1.1rem;
    margin-bottom: 1rem;
    opacity: 0.95;
}

.font-highlight {
    font-weight: 600;
    font-size: 1.3rem;
    color: var(--accent-color);
}

/* Imagen de marca */
.imagen-hero {
    display: block;
    max-width: 85%;
    height: auto;
    margin: 0 auto;
    filter: drop-shadow(0 15px 25px rgba(0,0,0,0.25));
    animation: float 4s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-12px); }
}

/* ==========================================================================
   Botones Universales
   ========================================================================== */
.boton {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    padding: 1rem 2rem;
    font-size: 1rem;
    font-weight: 600;
    border-radius: 50px;
    border: none;
    cursor: pointer;
    text-decoration: none;
    transition: var(--transition-smooth);
    box-shadow: 0 5px 15px rgba(0,0,0,0.15);
}

.btn-hero {
    background-color: #ffffff;
    color: #FF512F;
    margin-top: 1.5rem;
}

.btn-hero:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(255, 215, 0, 0.4);
    background-color: var(--accent-color);
    color: #000;
}

/* ==========================================================================
   Contenedor de Contenido Comercial
   ========================================================================== */
.contenedor-principal {
    max-width: 1100px;
    margin: -2rem auto 4rem auto;
    padding: 0 1.5rem;
    position: relative;
    z-index: 10;
}

/* ==========================================================================
   Formulario de Pedidos Premium
   ========================================================================== */
.seccion-formulario {
    background-color: var(--card-light);
    border-radius: var(--border-radius-lg);
    padding: 2.5rem;
    box-shadow: var(--shadow-elegant);
}

.formulario fieldset {
    border: none;
    padding: 0;
    margin: 0;
}

legend {
    font-size: 1.75rem;
    font-weight: 700;
    color: #FF512F;
    margin-bottom: 2rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.contenedor-campos {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
}

@media (min-width: 768px) {
    .contenedor-campos {
        grid-template-columns: repeat(2, 1fr);
    }
    .campo:last-child {
        grid-column: span 2;
    }
}

.campo {
    display: flex;
    flex-direction: column;
}

.campo label {
    font-size: 0.95rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: var(--text-main);
}

/* Cajas de entrada optimizadas con iconos */
.input-container {
    position: relative;
    display: flex;
    align-items: center;
}

.icon-input {
    position: absolute;
    left: 1rem;
    color: var(--text-muted);
    font-size: 1rem;
    transition: var(--transition-smooth);
}

.input-container.alignment-top {
    align-items: flex-start;
}

.input-container.alignment-top .icon-input {
    top: 1.1rem;
}

.input-text, 
textarea {
    width: 100%;
    padding: 0.9rem 1rem 0.9rem 2.8rem;
    border: 2px solid #eef2f5;
    border-radius: var(--border-radius-sm);
    font-size: 1rem;
    font-family: inherit;
    background-color: #f8fafc;
    transition: var(--transition-smooth);
    color: var(--text-main);
}

textarea {
    min-height: 100px;
    resize: vertical;
}

.input-text:focus,
textarea:focus {
    outline: none;
    border-color: #F09819;
    background-color: #ffffff;
    box-shadow: 0 0 0 4px rgba(240, 152, 25, 0.15);
}

.input-text:focus + .icon-input,
textarea:focus + .icon-input {
    color: #F09819;
}

/* Área de botones del formulario */
.acciones-formulario {
    margin-top: 2.5rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

@media (min-width: 576px) {
    .acciones-formulario {
        flex-direction: row;
        justify-content: flex-end;
    }
}

.btn-whatsapp {
    background-color: #25D366;
    color: white;
}

.btn-whatsapp:hover {
    background-color: #20ba5a;
    transform: translateY(-2px);
}

.btn-submit {
    background: var(--primary-gradient);
    color: white;
}

.btn-submit:hover {
    background: linear-gradient(135deg, #F09819 0%, #FF512F 100%);
    transform: translateY(-2px);
}

/* ==========================================================================
   Sección de Testimonios Avanzada
   ========================================================================== */
.testimonios {
    margin-top: 5rem;
    text-align: center;
}

.testimonios h2 {
    font-size: 2.2rem;
    margin-bottom: 0.5rem;
    color: #FF512F;
}

.subtitulo-seccion {
    color: var(--text-muted);
    margin-bottom: 2.5rem;
    font-size: 1.1rem;
}

.carrusel-testimonios {
    display: flex;
    gap: 1.5rem;
    overflow-x: auto;
    padding: 1rem;
    scroll-snap-type: x mandatory;
    scroll-behavior: smooth;
    scrollbar-width: none; /* Oculta scrollbar en Firefox */
}

.carrusel-testimonios::-webkit-scrollbar {
    display: none; /* Oculta scrollbar en Chrome/Safari */
}

.testimonio {
    flex: 0 0 85%;
    scroll-snap-align: center;
    background-color: var(--card-light);
    border-radius: var(--border-radius-lg);
    padding: 2rem;
    box-shadow: var(--shadow-elegant);
    border-top: 4px solid #F09819;
    text-align: left;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

@media (min-width: 768px) {
    .carrusel-testimonios {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        overflow: visible;
    }
    .testimonio {
        flex: auto;
    }
}

.stars {
    color: #FFD700;
    margin-bottom: 1rem;
    font-size: 0.9rem;
}

.quote {
    font-style: italic;
    color: var(--text-main);
    font-size: 1.05rem;
    margin: 0 0 1rem 0;
}

.autor {
    font-weight: 700;
    color: #FF512F;
    font-size: 0.9rem;
}

/* ==========================================================================
   Footer Estilizado e Iconos Rediseñados
   ========================================================================== */
.main-footer {
    background-color: #1a1a1a;
    color: #ffffff;
    padding: 4rem 2rem 2rem 2rem;
    margin-top: 6rem;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    text-align: center;
}

.footer-info {
    font-size: 1.1rem;
    margin: 0 0 0.5rem 0;
    letter-spacing: 0.5px;
}

.footer-info i {
    color: #F09819;
    margin-right: 0.5rem;
}

.spacing {
    color: #a0aec0;
    font-size: 0.95rem;
}

.redes {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    margin: 2rem 0;
}

.redes a {
    color: #ffffff;
    font-size: 1.5rem;
    background-color: #2d2d2d;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: var(--transition-smooth);
}

.redes a:hover {
    background: var(--primary-gradient);
    transform: scale(1.15) rotate(8deg);
}

.copyright-container {
    border-top: 1px solid #2d2d2d;
    margin-top: 3rem;
    padding-top: 1.5rem;
    color: #718096;
    font-size: 0.85rem;
}
/* ==========================================================================
   Sección de Testimonios Avanzada (Carrusel Nativo en Móviles)
   ========================================================================== */
.testimonios {
    margin-top: 5rem;
    text-align: center;
    padding: 0 1rem;
}

.testimonios h2 {
    font-size: 2.2rem;
    margin-bottom: 0.5rem;
    color: #FF512F;
}

.subtitulo-seccion {
    color: var(--text-muted);
    margin-bottom: 2.5rem;
    font-size: 1.1rem;
}

/* Contenedor del carrusel */
.carrusel-testimonios {
    display: flex;
    gap: 1.2rem;
    overflow-x: auto; /* Permite scroll horizontal en móvil */
    scroll-snap-type: x mandatory; /* Fuerza a las tarjetas a alinearse perfectamente */
    scroll-behavior: smooth;
    padding: 1.5rem 1rem;
    margin: 0 -1rem; /* Expande el carrusel hasta los bordes de la pantalla móvil */
    
    /* Oculta la barra de scroll molesta en celulares */
    scrollbar-width: none; 
    -webkit-overflow-scrolling: touch; /* Suavidad extrema en iPhone/iOS */
}

.carrusel-testimonios::-webkit-scrollbar {
    display: none; /* Oculta la barra de scroll en Chrome y Safari */
}

/* Tarjeta individual del testimonio */
.testimonio {
    flex: 0 0 82%; /* Cada tarjeta ocupa el 82% del ancho para dejar ver un pedazo de la siguiente */
    scroll-snap-align: center; /* Se centra automáticamente al deslizar */
    background-color: var(--card-light);
    border-radius: var(--border-radius-lg);
    padding: 2rem 1.5rem;
    box-shadow: var(--shadow-elegant);
    border-top: 4px solid #F09819;
    text-align: left;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    transition: transform 0.3s ease;
}

.stars {
    color: #FFD700;
    margin-bottom: 1rem;
    font-size: 0.9rem;
}

.quote {
    font-style: italic;
    color: var(--text-main);
    font-size: 1rem;
    margin: 0 0 1.5rem 0;
    line-height: 1.5;
}

.autor {
    font-weight: 700;
    color: #FF512F;
    font-size: 0.9rem;
    display: block;
}

/* ==========================================================================
   Diseño para Pantallas Grandes (Se convierte en cuadrícula fija)
   ========================================================================== */
@media (min-width: 768px) {
    .carrusel-testimonios {
        display: grid;
        grid-template-columns: repeat(2, 1fr); /* 2 columnas en tablets */
        overflow: visible;
        margin: 0 auto;
        padding: 1rem 0;
    }
    
    .testimonio {
        flex: auto;
        scroll-snap-align: unset; /* Desactiva el comportamiento de carrusel */
    }
}

@media (min-width: 1024px) {
    .carrusel-testimonios {
        grid-template-columns: repeat(4, 1fr); /* 4 columnas en pantallas de PC */
    }
}
/* ==========================================================================
   Modo Oscuro del Sistema (Automático y Consistente)
   ========================================================================== */
@media (prefers-color-scheme: dark) {
    body {
        background-color: var(--bg-dark);
        color: #e2e8f0;
    }
    .seccion-formulario, 
    .testimonio {
        background-color: var(--card-dark);
        box-shadow: 0 10px 30px rgba(0,0,0,0.3);
    }
    .campo label {
        color: #e2e8f0;
    }
    .input-text, 
    textarea {
        background-color: #2d2d2d;
        border-color: #3d3d3d;
        color: white;
    }
    .input-text:focus,
    textarea:focus {
        background-color: #242424;
    }
    .quote {
        color: #cbd5e1;
    }
}