﻿@font-face {
    font-family: 'EvelethSlant';
    src: url('assets/fonts/EvelethSlantW01-Bold.woff') format('woff');
    font-weight: bold;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'Distro-Bold';
    src: url('assets/fonts/Distro-Bold.woff') format('woff');
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}

/* Apply new font to subtitles */
.benefit-item p,
.calculator-module>p,
.recipe-content p,
.result-sub {
    font-family: 'Distro-Bold', sans-serif;
    text-transform: uppercase;
    /* Ensure they look like the screenshots if needed, usually subtitles in these designs are uppercase, checking images... yes they seem uppercase in the images provided, will add text-transform just in case they aren't in HTML, or just rely on font. Actually looking at HTML they are Mixed case. The image text is ALL CAPS. I should probably add text-transform: uppercase as well to match the look if the specific font doesn't do it automatically, but the user only asked to change typography. However, "Distro" fonts are often all-caps. I'll stick to just font-family for now unless I see they need casing changes. Wait, looking at the images, they are indeed ALL CAPS in the design. HTML content: "Mantenimiento muscular y saciedad." (Mixed). Image: "MANTENIMIENTO MUSCULAR Y SACIEDAD." (Caps). I will add text-transform: uppercase to be sure it matches the visual intent. */
    text-transform: uppercase;
}

.emoji-icon {
    font-family: "Segoe UI Emoji", "Apple Color Emoji", "Noto Color Emoji", sans-serif;
    font-style: normal;
}

:root {
    color-scheme: light;
    --color-primary: #002366;
    /* Deep Blue from Vida Activa */
    --color-primary-light: #1a44a0;
    --color-secondary: #e6e6e6;
    /* White/Light Grey */
    --color-accent: #ffffff;
    --color-text-dark: #333333;
    --color-text-light: #ffffff;
    --font-heading: 'EvelethSlant', sans-serif;
    --font-body: 'EvelethSlant', sans-serif;
    --container-max-width: 1200px;
    --spacing-section: 80px;
}

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

body {
    font-family: var(--font-body);
    background-color: #f9f9f9;
    color: var(--color-text-dark);
    line-height: 1.6;
    overflow-x: hidden;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

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

/* --- NAVBAR --- */
html {
    scroll-behavior: smooth;
}

.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    background: rgba(0, 35, 102, 0.95);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
}

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

.navbar-logo img {
    height: 45px;
    width: auto;
    transition: transform 0.3s ease;
}

.navbar-logo:hover img {
    transform: scale(1.05);
}

.navbar-menu {
    display: flex;
    list-style: none;
    gap: 40px;
    margin: 0;
    padding: 0;
}

.navbar-menu li a {
    font-family: var(--font-heading);
    font-size: 1rem;
    color: var(--color-text-light);
    text-decoration: none;
    text-transform: uppercase;
    letter-spacing: 1px;
    padding: 8px 0;
    position: relative;
    transition: all 0.3s ease;
}

.navbar-menu li a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: white;
    transition: width 0.3s ease;
}

.navbar-menu li a:hover::after {
    width: 100%;
}

.navbar-menu li a:hover {
    opacity: 0.9;
}

/* Offset for fixed navbar */
section[id] {
    scroll-margin-top: 80px;
}

/* =====================================================
   HERO — Imagen KV completa (sin recortes) + entrada animada
   Mobile: KV vertical | Desktop: KV horizontal
   ===================================================== */
.hero-section {
    position: relative;
    background: var(--color-primary);
    line-height: 0;            /* elimina gap fantasma debajo de la imagen */
    overflow: hidden;
}

.hero-picture {
    display: block;
    width: 100%;
}

/* La imagen se muestra completa, en su proporción natural.
   Nunca se recorta ni se zoomea: no se cortan cabezas ni texto. */
.hero-background {
    display: block;
    width: 100%;
    height: auto;
}

/* --- Entrada: la imagen aparece desde el azul de marca --- */
@keyframes heroImgIn {
    from { opacity: 0; }
    to   { opacity: 1; }
}

.hero-background {
    animation: heroImgIn 1.1s ease-out both;
}

/* Cortina azul que se desvanece revelando el KV */
.hero-reveal {
    position: absolute;
    inset: 0;
    background: var(--color-primary);
    z-index: 2;
    pointer-events: none;
    animation: heroCurtain 1.1s ease-out forwards;
}

@keyframes heroCurtain {
    0%   { opacity: 1; }
    100% { opacity: 0; }
}

/* Destello diagonal que recorre el KV periódicamente */
.hero-shine {
    position: absolute;
    top: 0;
    left: 0;
    width: 60%;
    height: 100%;
    z-index: 1;
    pointer-events: none;
    background: linear-gradient(100deg,
            transparent 0%,
            rgba(255, 255, 255, 0.18) 45%,
            rgba(255, 255, 255, 0.35) 50%,
            rgba(255, 255, 255, 0.18) 55%,
            transparent 100%);
    transform: skewX(-12deg) translateX(-120%);
    animation: heroShine 7s ease-in-out 2.5s infinite;
}

@keyframes heroShine {
    0%   { transform: skewX(-12deg) translateX(-120%); }
    18%  { transform: skewX(-12deg) translateX(320%); }
    100% { transform: skewX(-12deg) translateX(320%); }
}

/* Flecha "hay más abajo": rebota suave, desaparece al primer scroll.
   Solo en celular (portrait): el hero gana una franja azul propia
   debajo del KV para que la flecha no tape la viñeta. */
.hero-scroll-cue {
    display: none;
}

@media (orientation: portrait) {
    .hero-section {
        padding-bottom: 58px;   /* franja azul que continúa el KV */
    }

    .hero-scroll-cue {
        position: absolute;
        bottom: 8px;
        left: 50%;
        transform: translateX(-50%);
        z-index: 3;
        color: #ffffff;
        border-radius: 50%;
        width: 44px;
        height: 44px;
        display: flex;
        align-items: center;
        justify-content: center;
        animation: cueBounce 2s ease-in-out 1.8s infinite both;
        transition: opacity 0.5s ease;
        pointer-events: none;
    }
}

.hero-scroll-cue.hidden {
    opacity: 0;
}

@keyframes cueBounce {
    0%, 100% { transform: translateX(-50%) translateY(0); }
    50%      { transform: translateX(-50%) translateY(-9px); }
}

@media (prefers-reduced-motion: reduce) {
    .hero-background, .hero-reveal, .hero-shine {
        animation: none;
        opacity: 1;
    }
    .hero-reveal, .hero-shine { display: none; }
    .hero-scroll-cue { animation: none; }
}

/* --- MANIFESTO SECTION --- */
.manifesto-section {
    padding: var(--spacing-section) 0;
    background-color: white;
}

.manifesto-grid {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 40px;
}

.manifesto-block {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 20px;
}

.manifesto-icon-img {
    height: 150px;
    width: auto;
    object-fit: contain;
    margin-bottom: 30px;
    transition: transform 0.3s ease;
}

.manifesto-icon-img:hover {
    transform: scale(1.1);
}

/* Ajustes visuales de alineaciÃ³n manual */
.manifesto-block:nth-child(1) .manifesto-icon-img {
    margin-top: -20px;
    /* Subir el primero */
}

.manifesto-block:nth-child(2) .manifesto-icon-img {
    margin-top: 20px;
    /* Bajar el del medio */
}

.manifesto-block:nth-child(2) .manifesto-text-img {
    margin-top: -30px;
    /* Subir el texto visualmente */
}

.manifesto-text-img {
    max-width: 100%;
    max-height: 280px;
    height: auto;
    object-fit: contain;
}

.manifesto-block:nth-child(3) .manifesto-text-img {
    max-height: 320px;
    margin-top: -40px;
}

/* --- BENEFITS SECTION --- */
.benefits-section {
    padding: var(--spacing-section) 0;
    background-color: #f0f4f8;
}

.benefits-layout {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 60px;
    position: relative;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 40px;
}

.benefits-column {
    display: flex;
    flex-direction: column;
    gap: 15px;
    flex: 0 0 220px;
}

.benefits-left {
    align-items: flex-end;
    justify-content: space-between;
    height: 700px;
}

.benefits-right {
    align-items: flex-start;
    justify-content: space-between;
    height: 500px;
}

.benefits-center {
    flex: 0 0 auto;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    padding: 0 40px;
}

.product-wrapper {
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
    perspective: 1100px;       /* habilita el tilt y el flip 3D del pack */
}

/* Contenedor que se da vuelta (frente: pack / dorso: tabla nutricional) */
.product-flip {
    position: relative;
    width: 320px;
    height: 600px;
    transform-style: preserve-3d;
    transition: transform 0.8s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    z-index: 2;
    -webkit-tap-highlight-color: transparent;
}

.product-flip.flipped {
    transform: rotateY(180deg);
}

.product-face {
    position: absolute;
    inset: 0;
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

.product-center-img {
    height: 100%;
    width: auto;
    max-width: 100%;
    filter: drop-shadow(0 20px 40px rgba(0, 35, 102, 0.3));
    transition: transform 0.2s ease-out;
    will-change: transform;
}

/* Indicador "tocá para ver info" */
.product-flip-hint {
    position: absolute;
    bottom: 6px;
    left: 50%;
    transform: translateX(-50%);
    white-space: nowrap;
    font-family: var(--font-heading);
    font-size: 0.8rem;
    color: var(--color-primary);
    background: rgba(255, 255, 255, 0.92);
    padding: 5px 14px;
    border-radius: 999px;
    box-shadow: 0 2px 10px rgba(0, 35, 102, 0.18);
    opacity: 0.9;
    animation: hintPulse 2.2s ease-in-out infinite;
}

/* Pulso sutil para invitar a tocar/clickear */
@keyframes hintPulse {
    0%, 100% { transform: translateX(-50%) scale(1); box-shadow: 0 2px 10px rgba(0, 35, 102, 0.18); }
    50%      { transform: translateX(-50%) scale(1.06); box-shadow: 0 4px 16px rgba(0, 35, 102, 0.28); }
}

/* En desktop, al pasar el mouse por el pack, el cartelito se resalta */
.product-flip:hover .product-flip-hint {
    opacity: 1;
    background: var(--color-primary);
    color: #fff;
    animation-play-state: paused;
}

@media (prefers-reduced-motion: reduce) {
    .product-flip-hint { animation: none; }
}

/* Dorso: tarjeta con la tabla nutricional */
.product-back {
    transform: rotateY(180deg);
    background: #ffffff;
    border-radius: 16px;
    box-shadow: 0 10px 30px rgba(0, 35, 102, 0.18);
    padding: 18px 16px;
    flex-direction: column;
    overflow: hidden;
}

.nutrition {
    width: 100%;
    color: var(--color-primary);
    display: flex;
    flex-direction: column;
    justify-content: center;
    height: 100%;
}

.nutrition-title {
    font-family: var(--font-heading);
    font-size: 1rem;
    text-transform: uppercase;
    text-align: center;
    margin: 0 0 2px;
}

.nutrition-portion {
    font-size: 0.72rem;
    text-align: center;
    opacity: 0.75;
    margin: 0 0 8px;
}

.nutrition-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.68rem;
    line-height: 1.15;
}

.nutrition-table th {
    font-weight: bold;
    text-align: right;
    padding: 3px 2px;
    border-bottom: 2px solid var(--color-primary);
    font-size: 0.62rem;
}

.nutrition-table th:first-child {
    text-align: left;
}

.nutrition-table td {
    padding: 3px 2px;
    border-bottom: 1px solid rgba(0, 35, 102, 0.12);
    text-align: right;
}

.nutrition-table td:first-child {
    text-align: left;
    font-weight: 600;
}

.nutrition-table tr.sub td:first-child {
    padding-left: 10px;
    font-weight: 400;
    opacity: 0.8;
}

.nutrition-foot {
    font-size: 0.58rem;
    opacity: 0.7;
    margin: 8px 0 0;
    line-height: 1.2;
}

/* Flechas SVG */
.arrow {
    position: absolute;
    width: 120px;
    height: 80px;
    z-index: 1;
}

.arrow-left-top {
    left: -130px;
    top: 80px;
}

.arrow-left-middle {
    left: -130px;
    top: 50%;
    transform: translateY(-50%);
    height: 30px;
}

.arrow-left-bottom {
    left: -130px;
    bottom: 80px;
}

.arrow-right-top {
    right: -130px;
    top: 33%;
    transform: translateY(-50%);
}

.arrow-right-bottom {
    right: -130px;
    top: 66%;
    transform: translateY(-50%);
}


/* === FLIP CARD: frente (ícono + título) / dorso (descripción) === */
.benefit-item {
    width: 200px;
    height: 200px;
    perspective: 1000px;
    cursor: pointer;
    background: transparent;
    -webkit-tap-highlight-color: transparent;
}

.benefit-inner {
    position: relative;
    width: 100%;
    height: 100%;
    transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
    transform-style: preserve-3d;
}

.benefit-item.flipped .benefit-inner {
    transform: rotateY(180deg);
}

.benefit-face {
    position: absolute;
    inset: 0;
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
    border-radius: 15px;
    padding: 20px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    box-shadow: 0 4px 14px rgba(0, 35, 102, 0.08);
    overflow: hidden;
}

.benefit-front {
    background: white;
}

.benefit-back {
    background: var(--color-primary);
    color: #ffffff;
    transform: rotateY(180deg);
}

/* Realce en hover sin transform en el contenedor (no rompe el 3D) */
.benefit-item:hover .benefit-face {
    box-shadow: 0 10px 28px rgba(0, 35, 102, 0.18);
}

/* Indicador "girá la tarjeta" */
.flip-hint {
    position: absolute;
    bottom: 9px;
    right: 12px;
    font-size: 1.05rem;
    line-height: 1;
    color: var(--color-primary);
    opacity: 0.35;
    transition: opacity 0.3s ease, transform 0.5s ease;
}

.benefit-item:hover .flip-hint {
    opacity: 0.7;
    transform: rotate(90deg);
}

.benefit-icon {
    margin-bottom: 10px;
    height: 56px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.benefit-icon-img {
    max-height: 100%;
    max-width: 100%;
    object-fit: contain;
}

.benefit-item h3 {
    font-family: var(--font-heading);
    color: var(--color-primary);
    margin-bottom: 0;
    font-size: 1.1rem;
}

.benefit-item p {
    font-size: 0.95rem;
    line-height: 1.4;
    margin: 0;
}

/* La gota (0% grasas) ya está bien proporcionada, no necesita escalado extra */

/* --- INTERACTIVE SECTION --- */
.interactive-section {
    padding: var(--spacing-section) 0;
    background-color: var(--color-primary);
    color: white;
}

.interactive-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
}

.calculator-module,
.visualizer-module {
    background: rgba(255, 255, 255, 0.1);
    padding: 40px;
    border-radius: 20px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.interactive-section h2 {
    font-family: var(--font-heading);
    font-size: 2rem;
    margin-bottom: 10px;
}

.interactive-section p {
    margin-bottom: 25px;
    opacity: 0.9;
}

/* Calculator Styles */
.input-group {
    margin-bottom: 20px;
}

.input-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: bold;
}

.input-group input {
    width: 100%;
    padding: 12px;
    border-radius: 8px;
    border: none;
    font-family: var(--font-body);
    font-size: 1rem;
}

.activity-selector {
    display: flex;
    gap: 10px;
}

.activity-btn {
    flex: 1;
    padding: 10px;
    background: rgba(255, 255, 255, 0.2);
    border: 1px solid white;
    color: white;
    border-radius: 8px;
    cursor: pointer;
    font-family: var(--font-body);
    transition: all 0.3s;
}

.activity-btn.active,
.activity-btn:hover {
    background: white;
    color: var(--color-primary);
}

.result-box {
    margin-top: 30px;
    background: white;
    color: var(--color-primary);
    padding: 20px;
    border-radius: 10px;
    text-align: center;
    transition: opacity 0.5s ease;
}

.result-box.hidden {
    opacity: 0;
    pointer-events: none;
}

.result-text {
    font-size: 1.2rem;
    font-weight: bold;
    margin-bottom: 5px !important;
}

.result-sub {
    font-size: 0.9rem;
    margin-bottom: 0 !important;
}

/* Visualizer Styles */
.glass-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
}

.glass {
    width: 120px;
    height: 200px;
    border: 4px solid white;
    border-top: none;
    border-radius: 0 0 15px 15px;
    margin-bottom: 20px;
    position: relative;
    overflow: hidden;
    background: rgba(255, 255, 255, 0.05);
}

.milk-liquid {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 0%;
    /* Dynamic (JS setea la altura) */
    background: linear-gradient(to bottom, #ffffff 0%, #eef3fb 100%);
    transition: height 0.35s cubic-bezier(0.16, 1, 0.3, 1);
    overflow: visible;
}

/* Ola en la superficie del líquido */
.milk-wave {
    position: absolute;
    top: -9px;            /* asoma por encima del nivel del líquido */
    left: 0;
    width: 200%;          /* el doble de ancho para poder animar el loop */
    height: 12px;
    fill: #ffffff;
    animation: waveMove 2.6s linear infinite;
}

@keyframes waveMove {
    from { transform: translateX(0); }
    to   { transform: translateX(-50%); }
}

/* Burbujas que suben */
.bubble {
    position: absolute;
    bottom: 6px;
    width: 6px;
    height: 6px;
    background: rgba(255, 255, 255, 0.85);
    border-radius: 50%;
    opacity: 0;
    animation: bubbleRise 3s ease-in infinite;
}

.bubble:nth-child(2) { left: 20%; width: 5px; height: 5px; animation-duration: 3.4s; animation-delay: 0.2s; }
.bubble:nth-child(3) { left: 40%; width: 7px; height: 7px; animation-duration: 2.8s; animation-delay: 0.9s; }
.bubble:nth-child(4) { left: 60%; width: 4px; height: 4px; animation-duration: 3.6s; animation-delay: 1.4s; }
.bubble:nth-child(5) { left: 78%; width: 6px; height: 6px; animation-duration: 3.1s; animation-delay: 0.5s; }
.bubble:nth-child(6) { left: 50%; width: 5px; height: 5px; animation-duration: 3.3s; animation-delay: 2.0s; }

@keyframes bubbleRise {
    0%   { transform: translateY(0);     opacity: 0; }
    15%  { opacity: 0.9; }
    80%  { opacity: 0.6; }
    100% { transform: translateY(-150px); opacity: 0; }
}

/* Vaso vacío: sin ola ni burbujas */
.milk-liquid.empty .milk-wave,
.milk-liquid.empty .bubble {
    display: none;
}

@media (prefers-reduced-motion: reduce) {
    .milk-wave, .bubble { animation: none; }
    .bubble { opacity: 0; }
}

.measurement-lines .line {
    position: absolute;
    width: 20px;
    height: 2px;
    background: rgba(255, 255, 255, 0.5);
    left: -10px;
    /* Inside visual trick */
}

/* Lines at approx functional positions */
.line-25 {
    bottom: 25%;
    width: 100%;
    left: 0;
    border-top: 1px dashed rgba(255, 255, 255, 0.3);
    background: transparent;
}

.line-50 {
    bottom: 50%;
    width: 100%;
    left: 0;
    border-top: 1px dashed rgba(255, 255, 255, 0.3);
    background: transparent;
}

.line-100 {
    bottom: 100%;
}

.visualizer-controls {
    width: 100%;
    padding: 0 20px;
}

input[type=range] {
    width: 100%;
    -webkit-appearance: none;
    appearance: none;
    background: transparent;
}

input[type=range]::-webkit-slider-thumb {
    -webkit-appearance: none;
    height: 24px;
    width: 24px;
    border-radius: 50%;
    background: white;
    cursor: pointer;
    margin-top: -10px;
}

input[type=range]::-webkit-slider-runnable-track {
    width: 100%;
    height: 4px;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 2px;
}

.visualizer-feedback {
    margin-top: 15px;
    font-weight: bold;
    min-height: 24px;
    text-align: center;
}

/* --- RECIPES SECTION --- */
.recipes-section {
    padding: var(--spacing-section) 0;
    background-color: white;
}

.section-title {
    text-align: center;
    font-family: var(--font-heading);
    color: var(--color-primary);
    font-size: 3rem;
    margin-bottom: 50px;
}

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

.recipe-card {
    border-radius: 15px;
    overflow: hidden;
    background: white;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    height: 100%;
    position: relative;
}

.recipe-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
}

.recipe-image {
    height: 250px;
    background-size: cover;
    background-position: center;
    flex-shrink: 0;
}

.recipe-content {
    padding: 25px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.recipe-content h3 {
    color: var(--color-primary);
    font-size: 1.5rem;
    margin-bottom: 10px;
}

.recipe-intro {
    margin-bottom: 15px;
    font-style: italic;
    color: #666;
    font-size: 1.2rem;
    line-height: 1.4;
}

.recipe-meta {
    display: flex;
    gap: 15px;
    margin-bottom: 20px;
    font-size: 0.9rem;
    color: #888;
    font-weight: bold;
}

.view-recipe-btn {
    margin-top: auto;
    padding: 10px 20px;
    background-color: transparent;
    border: 2px solid var(--color-primary);
    color: var(--color-primary);
    border-radius: 50px;
    font-family: 'Distro-Bold', sans-serif;
    text-transform: uppercase;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s;
    align-self: flex-start;
}

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

/* Expanded State */
.recipe-details {
    display: none;
    margin-top: 20px;
    border-top: 1px solid #eee;
    padding-top: 20px;
    animation: fadeIn 0.5s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.recipe-card.expanded .recipe-details {
    display: block;
}

.recipe-card.expanded .view-recipe-btn {
    display: none;
}

.recipe-details h4 {
    color: var(--color-primary);
    margin-bottom: 10px;
    font-family: var(--font-heading);
    font-size: 1.2rem;
}

.recipe-details ul,
.recipe-details ol {
    margin-bottom: 20px;
    padding-left: 20px;
}

.recipe-details li {
    margin-bottom: 5px;
    color: #555;
}

.recipe-tip {
    background-color: #f9f9f9;
    padding: 15px;
    border-radius: 10px;
    border-left: 4px solid var(--color-primary);
    margin-bottom: 20px;
    font-size: 0.95rem;
}

.close-recipe {
    background: none;
    border: none;
    color: #999;
    cursor: pointer;
    font-weight: bold;
    display: block;
    margin: 0 auto;
    padding: 10px;
    transition: color 0.3s;
}

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

/* --- FOOTER --- */
.footer-section {
    background-color: var(--color-primary);
    color: white;
    padding: 60px 0;
    text-align: center;
}

.footer-cta {
    margin-bottom: 40px;
}

.footer-cta-title {
    font-family: var(--font-heading);
    font-size: 2.5rem;
    margin-bottom: 15px;
    text-transform: uppercase;
}

.footer-cta-subtitle {
    font-family: 'Distro-Bold', sans-serif;
    font-size: 1.2rem;
    opacity: 0.9;
    max-width: 500px;
    margin: 0 auto;
    text-transform: uppercase;
}

/* Botón de Instagram en el footer */
.footer-ig-btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    margin-top: 28px;
    padding: 13px 28px;
    background: #ffffff;
    color: var(--color-primary);
    font-family: var(--font-heading);
    font-size: 1rem;
    text-decoration: none;
    text-transform: uppercase;
    border-radius: 999px;
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.25);
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.3s ease;
}

.footer-ig-btn:hover {
    transform: translateY(-3px) scale(1.03);
    box-shadow: 0 10px 26px rgba(0, 0, 0, 0.35);
}

.footer-ig-btn:active {
    transform: scale(0.97);
}

.footer-logo img {
    height: 60px;
    margin: 0 auto 30px;
    width: auto;
}

.footer-seals {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-bottom: 30px;
    flex-wrap: wrap;
}

.seal {
    border: 1px solid white;
    padding: 5px 15px;
    border-radius: 50px;
    font-size: 0.9rem;
}

.footer-legal p {
    font-size: 0.8rem;
    opacity: 0.6;
}

/* --- RESPONSIVE --- */
@media (max-width: 768px) {

    /* Navbar Responsive */
    .navbar-container {
        flex-direction: column;
        gap: 15px;
    }

    .navbar-menu {
        gap: 15px;
        flex-wrap: wrap;
        justify-content: center;
    }

    .navbar-logo img {
        height: 35px;
    }

    /* Hero: la imagen ya se adapta sola por proporción natural, no necesita override */

    /* Manifesto Section */
    .manifesto-grid {
        flex-direction: column;
        gap: 30px;
    }

    .manifesto-block {
        padding: 0;
        width: 100%;
    }

    /* Reset manual adjustments for desktop */
    .manifesto-block:nth-child(n) .manifesto-icon-img,
    .manifesto-block:nth-child(n) .manifesto-text-img {
        margin-top: 0;
    }

    .manifesto-text-img {
        max-width: 100%;
        height: auto;
        max-height: 160px;
    }

    /* Benefits View: grid 2 columnas — 54g ancha arriba, resto en 2x2 */
    .benefits-layout {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 16px;
        align-items: stretch;
    }

    /* Las columnas "desaparecen": sus tarjetas pasan a ser items del grid */
    .benefits-left,
    .benefits-right {
        display: contents;
    }

    /* El pack: todo el ancho, arriba de todo */
    .benefits-center {
        grid-column: 1 / -1;
        order: -1;
        margin-bottom: 8px;
        padding: 0;
    }

    /* Flip del pack más chico en celular; el dorso (tabla) usa el ancho */
    .product-flip {
        width: min(340px, 90vw);
        height: 360px;
    }

    .arrow {
        display: none;
    }

    /* Las 4 tarjetas de la 2x2: cuadradas, más chicas */
    .benefit-item {
        width: auto;
        max-width: none;
        height: 150px;
        padding: 0;
        margin: 0;
    }

    /* Tarjeta 54g: ancha (todo el ancho) y más bajita, ícono+título horizontal */
    .benefits-left .benefit-item:nth-child(1) {
        grid-column: 1 / -1;
        height: 110px;
    }

    .benefits-left .benefit-item:nth-child(1) .benefit-front {
        flex-direction: row;
        gap: 18px;
    }

    .benefits-left .benefit-item:nth-child(1) .benefit-icon {
        margin-bottom: 0;
    }

    /* Títulos: chicos en las 2x2, más grande en la featured 54g */
    .benefit-item h3 {
        font-size: 1rem;
    }

    .benefits-left .benefit-item:nth-child(1) h3 {
        font-size: 1.35rem;
    }

    /* Íconos un poco más chicos en las 2x2 para dar aire */
    .benefit-icon {
        height: 48px;
    }

    /* Interactive */
    .interactive-grid {
        grid-template-columns: 1fr;
        gap: 40px;
    }
}

/* --- RESPONSIVE: Small Mobile (< 480px) --- */
@media (max-width: 480px) {

    /* MANIFESTO - Íconos más grandes, textos más chicos, compacto */
    .manifesto-section {
        padding: 32px 0;
    }

    .manifesto-block {
        padding: 8px 20px;
    }

    .manifesto-icon-img {
        height: 120px;
        margin-bottom: 10px;
    }

    /* Los tres textos al MISMO ancho => misma escala visual de texto */
    .manifesto-text-img {
        width: 72%;
        max-width: 72%;
        max-height: none;
        height: auto;
    }

    /* Anular el agrandado especial de la 3ra en celular */
    .manifesto-block:nth-child(3) .manifesto-text-img {
        max-height: none;
        margin-top: 0;
    }

    /* BENEFICIOS - celulares chicos */
    .benefits-section {
        padding: 40px 0;
    }

    .product-flip {
        height: 350px;
    }

    /* Las 4 tarjetas 2x2: alto un poco menor en pantallas chicas */
    .benefit-item {
        height: 140px;
    }

    .benefits-left .benefit-item:nth-child(1) {
        height: 105px;
    }

    /* Section spacing */
    :root {
        --spacing-section: 50px;
    }

    /* Footer adjustments */
    .footer-cta-title {
        font-size: 1.8rem;
    }

    .footer-cta-subtitle {
        font-size: 1rem;
    }
} /* ← cierra @media (max-width: 480px) */

/* =====================================================
   ANIMACIONES
   ===================================================== */

/* --- Reveal de texto palabra por palabra --- */
.word-reveal {
    display: inline-block;
    opacity: 0;
    transform: translateY(0.5em);
    transition: opacity 0.5s cubic-bezier(0.16, 1, 0.3, 1),
                transform 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.word-reveal.is-revealed {
    opacity: 1;
    transform: translateY(0);
}

/* --- Parallax en scroll (movido por JS, suave y con GPU) --- */
[data-parallax] {
    will-change: transform;
}

@media (prefers-reduced-motion: reduce) {
    [data-parallax] {
        transform: none !important;
    }
}

/* --- Producto: flotación continua --- */
@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50%       { transform: translateY(-14px); }
}

.product-wrapper {
    animation: float 4.5s ease-in-out infinite;
}

/* Override: hover escala sobre el flotante */
.product-center-img:hover {
    transform: scale(1.05);
    transition: transform 0.4s ease;
}

/* --- Scroll animations: base --- */
.fade-in-up {
    opacity: 0;
    transform: translateY(36px);
    transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.fade-in-left {
    opacity: 0;
    transform: translateX(-36px);
    transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.fade-in-right {
    opacity: 0;
    transform: translateX(36px);
    transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.fade-in-up.is-visible,
.fade-in-left.is-visible,
.fade-in-right.is-visible {
    opacity: 1;
    transform: translate(0, 0);
}

/* Stagger delays */
.stagger-1 { transition-delay: 0.10s; }
.stagger-2 { transition-delay: 0.22s; }
.stagger-3 { transition-delay: 0.34s; }
.stagger-4 { transition-delay: 0.46s; }
.stagger-5 { transition-delay: 0.58s; }

/* --- Recetas: pulse suave en hover sobre el botón --- */
@keyframes pulseBorder {
    0%, 100% { box-shadow: 0 0 0 0 rgba(0, 35, 102, 0.3); }
    50%       { box-shadow: 0 0 0 6px rgba(0, 35, 102, 0); }
}

.view-recipe-btn:hover {
    animation: pulseBorder 1.2s ease-in-out infinite;
}

/* --- Benefit: aparición al entrar al viewport (opacity only para no
   romper el contexto 3D del flip) --- */
.benefit-item {
    opacity: 0;
    transition: opacity 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.benefit-item.is-visible {
    opacity: 1;
}

/* --- Contador animado del número 54g --- */
@keyframes countUp {
    from { transform: translateY(8px); opacity: 0; }
    to   { transform: translateY(0);   opacity: 1; }
}

.benefit-item.is-visible h3 {
    animation: countUp 0.4s ease 0.1s both;
}

/* --- Manifesto: slide lateral alternado --- */
.manifesto-block:nth-child(odd)  { opacity: 0; transform: translateX(-30px); transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1); }
.manifesto-block:nth-child(even) { opacity: 0; transform: translateX(30px);  transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1); }

.manifesto-block.is-visible {
    opacity: 1;
    transform: translateX(0);
}

.manifesto-block:nth-child(1) { transition-delay: 0.0s; }
.manifesto-block:nth-child(2) { transition-delay: 0.18s; }
.manifesto-block:nth-child(3) { transition-delay: 0.36s; }

/* --- Footer CTA --- */
.footer-cta {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.9s cubic-bezier(0.16, 1, 0.3, 1), transform 0.9s cubic-bezier(0.16, 1, 0.3, 1);
}

.footer-cta.is-visible {
    opacity: 1;
    transform: translateY(0);
}

/* --- Módulos interactivos --- */
.calculator-module,
.visualizer-module {
    opacity: 0;
    transform: translateY(28px);
    transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.calculator-module.is-visible,
.visualizer-module.is-visible {
    opacity: 1;
    transform: translateY(0);
}

.visualizer-module { transition-delay: 0.18s; }

/* --- Recipe cards --- */
.recipe-card {
    opacity: 0;
    transform: translateY(28px);
    transition: opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1), transform 0.7s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.3s ease;
}

.recipe-card.is-visible {
    opacity: 1;
    transform: translateY(0);
}

.recipe-card:nth-child(1) { transition-delay: 0.0s; }
.recipe-card:nth-child(2) { transition-delay: 0.15s; }
.recipe-card:nth-child(3) { transition-delay: 0.30s; }

/* Asegurar que el hover de recipe-card funcione cuando ya es visible */
.recipe-card.is-visible:hover {
    transform: translateY(-5px);
}

/* =====================================================
   MOBILE: mejoras específicas para experiencia QR
   ===================================================== */
@media (max-width: 768px) {
    /* Manifesto: en mobile no hay espacio para slide lateral, hacemos fade-up */
    .manifesto-block:nth-child(odd),
    .manifesto-block:nth-child(even) {
        transform: translateY(28px);
    }

    /* Recipe cards en mobile: stagger menor */
    .recipe-card:nth-child(2) { transition-delay: 0.08s; }
    .recipe-card:nth-child(3) { transition-delay: 0.16s; }
}
