/* ============================================================
   ALEJANDRO & SOFÍA — styles.css
   Modelo 5 · Editorial Magazine v4
   Inspirado en: Save the Date editorial moderno
   Paleta: Crema / Negro / Serif tipografía
============================================================ */

/* ── RESET & TOKENS ─────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
    --cream:    #F0EDE6;
    --cream-2:  #E8E3D8;
    --cream-3:  #DDD8CB;
    --ink:      #111110;
    --ink-2:    #2B2A27;
    --ink-3:    #4A4844;
    --white:    #FAFAF8;
    --gold:     #8B7355;
    --gold-l:   #C4A97D;

    --serif:    'Cormorant Garamond', 'Georgia', serif;
    --serif-alt:'Italiana', 'Georgia', serif;
    --script:   'Great Vibes', cursive;
    --sans:     'Montserrat', 'Arial', sans-serif;

    --gap-sm:   12px;
    --gap:      24px;
    --gap-lg:   48px;
    --max:      1400px;

    --ease:     cubic-bezier(.4,0,.2,1);
}

html { scroll-behavior: smooth; font-size: 16px; }

body {
    background: var(--cream);
    color: var(--ink);
    font-family: var(--serif);
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; object-fit: cover; }
a   { text-decoration: none; color: inherit; }


/* ── SCROLL REVEAL ──────────────────────────────────────── */
.reveal-section,
.reveal-item,
.reveal-left,
.reveal-right {
    opacity: 0;
    transition: opacity .8s var(--ease), transform .8s var(--ease);
}
.reveal-section, .reveal-item { transform: translateY(36px); }
.reveal-left { transform: translateX(-60px); }
.reveal-right { transform: translateX(60px); }

.reveal-section.in-view,
.reveal-item.in-view,
.reveal-left.in-view,
.reveal-right.in-view {
    opacity: 1;
    transform: none;
}
.reveal-item:nth-child(2), .reveal-left:nth-child(2), .reveal-right:nth-child(2) { transition-delay: .12s; }
.reveal-item:nth-child(3), .reveal-left:nth-child(3), .reveal-right:nth-child(3) { transition-delay: .22s; }
.reveal-item:nth-child(4), .reveal-left:nth-child(4), .reveal-right:nth-child(4) { transition-delay: .32s; }


/* ── SHARED SECTION LABEL ROW ───────────────────────────── */
.section-label-row {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
}
.slr-line  { flex: 1; height: 1px; background: var(--ink); opacity: .25; }
.slr-text  {
    font-family: var(--sans);
    font-size: .58rem;
    font-weight: 500;
    letter-spacing: .25em;
    text-transform: uppercase;
    color: var(--ink-3);
    white-space: nowrap;
}
.slr-light .slr-line { background: var(--white); opacity: .25; }
.slr-light .slr-text { color: rgba(255,255,255,.55); }


/* ── SHARED SECTION BIG TITLE ───────────────────────────── */
.section-big-title {
    font-family: var(--serif);
    font-size: clamp(2.6rem, 5vw, 4.5rem);
    font-weight: 300;
    line-height: 1.05;
    color: var(--ink);
    margin-bottom: 1.5rem;
}
.section-big-title em {
    font-style: italic;
    font-weight: 300;
    color: var(--ink-3);
}
.stl-light        { color: var(--white); }
.stl-light em     { color: rgba(255,255,255,.6); }


/* ── MUSIC FAB ──────────────────────────────────────────── */
.music-fab {
    position: fixed;
    bottom: 28px; right: 28px;
    z-index: 9000;
    width: 48px; height: 48px;
    border-radius: 50%;
    background: var(--ink);
    border: none;
    color: var(--cream);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background .3s;
    box-shadow: 0 4px 20px rgba(0,0,0,.25);
}
.music-fab:hover { background: var(--gold); }
.music-fab svg   { width: 20px; height: 20px; }
.music-fab .icon-pause { display: none; }
.music-fab.playing .icon-play  { display: none; }
.music-fab.playing .icon-pause { display: block; }


/* ════════════════════════════════════════════════════════
   WELCOME OVERLAY — FLORAL + INICIALES
════════════════════════════════════════════════════════ */
#welcome-overlay {
    position: fixed;
    inset: 0;
    z-index: 9999;
    background-color: #000; /* Fondo negro como base por si la imagen no cubre */
    transition: opacity .8s var(--ease), visibility .8s;
    overflow: hidden;
}
#welcome-overlay.hidden { opacity: 0; visibility: hidden; pointer-events: none; }

/* Fondo floral (tag img) adaptado como picapiedra */
.wlc-bg-img {
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    height: 100%;
    width: 100%;
    object-fit: cover;
    z-index: 0;
}

/* Contenedor del contenido */
.wlc-floral-content {
    position: relative;
    z-index: 1;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* ── Estado 1: Iniciales + Botón ────────────────────── */
#wlc-initial-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    gap: 3rem;
    transition: opacity 0.5s var(--ease);
}
.wlc-init-visible {
    opacity: 1;
}

/* Iniciales PNG */
.wlc-iniciales-wrap {
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 1s cubic-bezier(0.4, 0, 0, 1), opacity 0.8s var(--ease);
}
.wlc-iniciales {
    max-width: 70%;
    max-height: 80vh;
    width: auto;
    height: auto;
    object-fit: contain;
    display: block;
}

/* Animación de las iniciales subiendo */
.wlc-iniciales-fly-up .wlc-iniciales-wrap {
    transform: translateY(-120vh);
    opacity: 0;
}

/* Botón "ABRIR INVITACIÓN" negro */
.btn-abrir-inv {
    display: inline-block;
    background: linear-gradient(135deg, var(--ink) 0%, #2a2c2e 100%);
    color: var(--white);
    font-family: var(--sans);
    font-size: .95rem; /* Letra más grande */
    font-weight: 600;
    letter-spacing: .35em; /* Más elegante */
    padding: 1.6rem 4.5rem; /* Botón mucho más grande */
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 2px;
    cursor: pointer;
    text-transform: uppercase;
    transition: all .4s var(--ease);
    position: relative;
    overflow: hidden;
    box-shadow: 0 10px 40px rgba(0,0,0,.5); /* Sombra que lo hace resaltar */
}
.btn-abrir-inv:hover {
    background: var(--ink-2);
    transform: translateY(-3px);
    box-shadow: 0 15px 50px rgba(0,0,0,.6);
    border-color: rgba(255, 255, 255, 0.3);
}

/* ── Estado 2: Invitado Card ────────────────────────── */
.wlc-reveal-hidden {
    display: none;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2.5rem;
    opacity: 0;
}
.wlc-reveal-show {
    display: flex !important;
    flex-direction: column;
    align-items: stretch; /* En móvil, el botón hereda el ANCHO de la tarjeta */
    gap: 0; /* Botón pegado a la tarjeta */
    animation: fadeInCard 1s var(--ease) forwards;
    width: max-content; /* El ancho lo define la tarjeta */
    margin: 0 auto; /* Centrado en móvil */
}
@keyframes fadeInCard {
    from { opacity: 0; transform: translateY(30px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* Card negro premium */
.wlc-invitado-card {
    background: var(--ink);
    color: var(--white);
    padding: 1.5rem 2.5rem; /* Menos padding vertical para forzar forma rectangular apaisada */
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: .6rem;
    min-width: 300px;
    width: 90%;
    max-width: 450px;
    box-shadow: 0 20px 60px rgba(0,0,0,.35);
}
.wlc-inv-label {
    font-family: var(--sans);
    font-size: .58rem;
    font-weight: 500;
    letter-spacing: .3em;
    text-transform: uppercase;
    color: rgba(255,255,255,.5);
}
.wlc-inv-name {
    font-family: var(--serif);
    font-size: clamp(1.8rem, 5vw, 2.5rem);
    font-weight: 300;
    font-style: italic;
    color: var(--white);
    line-height: 1.3;
}
.wlc-inv-sep {
    width: 50px;
    height: 1px;
    background: rgba(255,255,255,.2);
    margin: .5rem 0;
}
.wlc-inv-pases-row {
    display: flex;
    align-items: baseline;
    gap: 1rem;
}
.wlc-inv-pases-label {
    font-family: var(--sans);
    font-size: .55rem;
    font-weight: 600;
    letter-spacing: .25em;
    text-transform: uppercase;
    color: var(--gold-l);
}
.wlc-inv-pases-num {
    font-family: var(--serif-alt);
    font-size: 2.5rem;
    font-weight: 400;
    color: var(--white);
    line-height: 1;
}

/* Botón "VER MÁS" — plomo oscuro */
.btn-ver-mas {
    display: flex;
    align-items: center;
    justify-content: center;
    background: #3a3d40; /* plomo oscuro */
    color: var(--white);
    font-family: var(--sans);
    font-size: .8rem;
    font-weight: 600;
    letter-spacing: .25em;
    padding: 1.5rem 2rem; /* Alto natural en móvil, ancho adaptativo */
    border: none;
    cursor: pointer;
    text-transform: uppercase;
    transition: all .4s var(--ease);
    box-shadow: 0 8px 25px rgba(0,0,0,0.3);
}
.btn-ver-mas:hover {
    background: #2a2c2e;
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.4);
}

/* ── PC: Iniciales a la izquierda, botón a la derecha ── */
@media (min-width: 1081px) {
    #wlc-initial-state {
        flex-direction: row;
        justify-content: center;
        align-items: center;
        gap: 6rem;
        padding: 0 4%;
    }
    .wlc-iniciales {
        max-width: 70%;
        max-height: 90vh;
    }
    
    /* Mostrar la tarjeta y el botón en fila, pegados */
    .wlc-reveal-show {
        position: absolute;
        left: 15%; /* Más al centro (antes era 8%) */
        top: 42%;  /* Más arriba (antes era 50%) */
        transform: translateY(-50%);
        flex-direction: row; /* El botón va a la DERECHA de la tarjeta */
        justify-content: flex-start;
        align-items: stretch; /* El botón hereda el ALTO de la tarjeta */
        gap: 0; /* Totalmente pegado a su lado */
        width: auto;
    }
    .btn-ver-mas {
        padding: 0 3.5rem; /* En PC el alto lo da flex, usamos padding para el ancho */
    }
}

/* ── MOBILE: columna centrada, fondo 9:16 ────────────── */
@media (max-width: 1080px) {
    .wlc-bg-img {
        /* Lógica idéntica a picapiedra para mantener 9:16 centrado */
        width: auto;
        height: 100%;
        aspect-ratio: 9 / 16;
        max-width: 100%;
        object-fit: cover;
        margin: 0 auto;
        display: block;
    }
    #wlc-initial-state {
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 2rem;
        padding: 2rem 1.5rem;
    }
    .wlc-reveal-show {
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 1.5rem;
    }
    .wlc-iniciales-wrap {
        justify-content: center;
    }
    .wlc-iniciales {
        max-width: 85%;
        max-height: 55vh;
    }
    .wlc-invitado-card {
        min-width: unset;
        width: 85%;
        padding: 2.5rem 2rem;
    }
    .btn-abrir-inv {
        font-size: .62rem;
        padding: 1rem 2.5rem;
    }
    .btn-ver-mas {
        font-size: .6rem;
        padding: 1.1rem;
        width: 85%;
    }
}


/* ════════════════════════════════════════════════════════
   SEC 1: PORTADA — Editorial split (main hero)
════════════════════════════════════════════════════════ */
.s-portada {
    /* PC: exactamente 100dvh, sin desborde */
    height: 100dvh;
    display: flex;
    flex-direction: column;
    position: relative;
    background: var(--white);
    border-bottom: 1px solid rgba(0,0,0,.12);
    overflow: hidden;
}

/* Main split: 45% text / 55% photos */
.portada-split {
    display: grid;
    grid-template-columns: 45% 55%;
    flex: 1;
    min-height: 0;
    overflow: hidden;
}

/* LEFT: PNG text centered */
.portada-text {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 3rem 2rem;
    background: var(--white);
}
.portada-png-wrap {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
}
.portada-png-text {
    /* 👇 AQUÍ PUEDES MODIFICAR EL TAMAÑO DEL TEXTO PC 👇
       Cambia estos valores (ej: 70%, 85%, 90%) para achicar o agrandar */
    max-width: 80%;
    max-height: 80%;
    
    width: auto;
    height: auto;
    object-fit: contain;
    display: block;
}

/* RIGHT: 3-column horizontal photo strip */
.portada-photos {
    position: relative;
    overflow: hidden;
    height: 100%;
    display: flex;
    align-items: center; /* Centrado vertical para no ir de punta a punta */
    justify-content: center;
    padding: 2rem; /* Espacio general alrededor */
}
.portada-photo-strip {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    width: 100%;
    gap: 1.5rem; /* Espacios a los lados de cada foto/video */
}
.pps-figure {
    overflow: hidden;
    position: relative;
    margin: 0;
    aspect-ratio: 9 / 16; /* Forzar estricta proporción 9:16 */
}
.pps-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center center;
    filter: grayscale(10%) contrast(1.08) brightness(.96);
    transition: transform 7s ease;
    display: block;
}
.pps-figure:hover .pps-img { transform: scale(1.04); }

/* Video figure - matches same size as image figures */
.pps-video-figure {
    overflow: hidden;
    position: relative;
    aspect-ratio: 9 / 16; /* Forzar estricta proporción 9:16 */
}
.pps-video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center center;
    display: block;
}


/* Bottom Nav */
.portada-nav {
    display: flex;
    justify-content: center;
    gap: 0;
    border-top: 1px solid rgba(0,0,0,.12);
    background: var(--white);
    overflow-x: auto;
}
.pnav-link {
    font-family: var(--sans);
    font-size: .55rem;
    font-weight: 500;
    letter-spacing: .18em;
    text-transform: uppercase;
    color: var(--ink-3);
    padding: .9rem 1.4rem;
    border-right: 1px solid rgba(0,0,0,.08);
    transition: background .2s, color .2s;
    white-space: nowrap;
}
.pnav-link:last-child { border-right: none; }
.pnav-link:hover { background: var(--ink); color: var(--cream); }

/* ─── PHOTO STRIP in welcome overlay: same 3-col logic ─── */
.photo-strip {
    display: grid;
    grid-template-rows: 1fr 1fr 1fr;
    height: 100%;
    gap: 4px;
    background: var(--ink);
}
.ps-photo {
    overflow: hidden;
    position: relative;
}
.ps-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center center;
    filter: grayscale(20%) contrast(1.05);
    transition: transform 6s ease;
}
.ps-photo:hover img { transform: scale(1.04); }
.ps-video video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center center;
    display: block;
}



/* ════════════════════════════════════════════════════════
   SEC 2: CONTADOR — Dark editorial
════════════════════════════════════════════════════════ */
.s-contador {
    background: var(--ink);
    overflow: hidden;
}
.contador-inner {
    display: grid;
    grid-template-columns: 1fr 1fr;
    max-width: var(--max);
    margin: 0 auto;
    padding: 5rem var(--gap-lg);
    gap: 4rem;
    align-items: center;
}
.cnt-tag {
    display: block;
    font-family: var(--sans);
    font-size: .55rem;
    font-weight: 500;
    letter-spacing: .25em;
    text-transform: uppercase;
    color: var(--gold-l);
    margin-bottom: 1rem;
}
.cnt-headline {
    font-family: var(--serif);
    font-size: clamp(2.5rem, 4.5vw, 4rem);
    font-weight: 300;
    line-height: 1.05;
    color: var(--white);
    margin-bottom: 1rem;
}
.cnt-headline em {
    font-style: italic;
    color: rgba(255,255,255,.5);
}
.cnt-sub {
    font-family: var(--serif);
    font-size: .92rem;
    font-style: italic;
    color: rgba(255,255,255,.4);
    line-height: 1.65;
}
.contador-nums-col {
    display: flex;
    align-items: flex-end;
    justify-content: center;
    gap: .5rem;
    flex-wrap: wrap;
}
.cnt-num-group {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: .3rem;
}
.cnt-num {
    font-family: var(--serif-alt);
    font-size: clamp(4rem, 8vw, 7rem);
    font-weight: 400;
    color: var(--white);
    line-height: 1;
    letter-spacing: -.02em;
}
.cnt-unit {
    font-family: var(--sans);
    font-size: .48rem;
    font-weight: 500;
    letter-spacing: .22em;
    text-transform: uppercase;
    color: var(--gold-l);
}
.cnt-sep {
    font-family: var(--serif);
    font-size: 4rem;
    color: var(--gold);
    opacity: .5;
    line-height: 1;
    margin-bottom: .6rem;
    animation: blink-cnt .9s step-end infinite;
}
@keyframes blink-cnt { 0%,100%{ opacity:.5 } 50%{ opacity:0 } }

/* Contador photo band */
.contador-photo-band {
    position: relative;
    height: 240px;
    overflow: hidden;
}
.cpb-img {
    width: 100%; height: 100%;
    object-fit: cover;
    object-position: center 30%;
    filter: grayscale(40%) brightness(.5);
}
.cpb-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to bottom, var(--ink) 0%, transparent 40%, transparent 60%, var(--ink) 100%);
}
.cpb-text {
    position: absolute;
    bottom: 1.5rem; left: 50%;
    transform: translateX(-50%);
    font-family: var(--sans);
    font-size: .58rem;
    font-weight: 500;
    letter-spacing: .28em;
    text-transform: uppercase;
    color: rgba(255,255,255,.5);
    white-space: nowrap;
}


/* ════════════════════════════════════════════════════════
   SEC 3: PADRES
════════════════════════════════════════════════════════ */
.s-padres {
    background: var(--cream-2);
    padding: 6rem var(--gap-lg);
}
.s-padres .section-label-row,
.s-padres .section-big-title {
    max-width: var(--max);
    margin-left: auto;
    margin-right: auto;
}
.padres-editorial-grid {
    display: grid;
    grid-template-columns: 1fr 60px 1fr;
    max-width: var(--max);
    margin: 2rem auto 0;
    gap: 2rem;
    align-items: start;
}
.padre-editorial {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 1.2rem;
    padding: 2.5rem 1.5rem;
    border: 1px solid rgba(0,0,0,.08);
    background: transparent;
    position: relative;
}

.pe-family-row {
    display: flex;
    align-items: center;
    gap: .75rem;
    margin-bottom: .5rem;
}
.pe-lottie-inline {
    width: 80px;
    height: 80px;
}
.pe-family-tag {
    font-family: var(--sans);
    font-size: .52rem;
    font-weight: 600;
    letter-spacing: .25em;
    text-transform: uppercase;
    color: var(--gold);
    padding: .3rem .8rem;
    border: 1px solid var(--gold);
    display: inline-block;
}

.pe-text {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 1rem;
}
.pe-names {
    font-family: var(--serif);
    font-size: 1.1rem;
    font-weight: 400;
    line-height: 1.4;
    color: var(--ink);
}
.pe-amp {
    font-family: var(--script);
    font-size: 1.6rem;
    color: var(--gold);
    display: block;
    margin: .2rem 0;
}
.pe-quote {
    font-family: var(--serif);
    font-size: .88rem;
    font-style: italic;
    color: var(--ink-3);
    line-height: 1.65;
    text-align: center;
}

/* Center ornament */
.padres-center-col {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: .8rem;
    padding-top: 3rem;
}
.pcc-vert-text {
    font-family: var(--sans);
    font-size: .45rem;
    letter-spacing: .2em;
    text-transform: uppercase;
    color: var(--ink-3);
    opacity: .4;
    writing-mode: vertical-rl;
    text-orientation: mixed;
    transform: rotate(180deg);
    flex: 1;
    display: flex;
    align-items: center;
}
.pcc-circle {
    width: 50px; height: 50px;
    border-radius: 50%;
    border: 1px solid var(--gold);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    font-family: var(--serif);
    font-size: .7rem;
    font-style: italic;
    color: var(--gold);
    line-height: 1;
    flex-shrink: 0;
}
.pcc-circle span {
    font-size: .8rem;
    font-family: var(--script);
    color: var(--gold-l);
}


/* ════════════════════════════════════════════════════════
   SEC 4: PADRINOS
════════════════════════════════════════════════════════ */
.s-padrinos { background: var(--ink); }

.padrinos-banner {
    display: flex;
    align-items: stretch;
    border-bottom: 1px solid rgba(255,255,255,.08);
}
.pb-vert-label {
    padding: 2rem .8rem;
    writing-mode: vertical-rl;
    text-orientation: mixed;
    transform: rotate(180deg);
    font-family: var(--serif-alt);
    font-size: clamp(2rem, 6vw, 5rem);
    font-weight: 400;
    color: rgba(255,255,255,.07);
    letter-spacing: .05em;
    border-right: 1px solid rgba(255,255,255,.08);
    display: flex;
    align-items: center;
}
.pb-content {
    flex: 1;
    padding: 3rem var(--gap-lg);
    max-width: var(--max);
}

.padrinos-cards-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    border-top: 1px solid rgba(255,255,255,.06);
}
.pad-card {
    padding: 3rem 2.5rem;
    border-right: 1px solid rgba(255,255,255,.06);
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: .75rem;
    transition: background .35s;
    cursor: default;
}
.pad-card:last-child { border-right: none; }
.pad-card:hover { background: rgba(255,255,255,.03); }
.pad-num {
    font-family: var(--serif-alt);
    font-size: 4rem;
    font-weight: 400;
    color: rgba(255,255,255,.06);
    line-height: 1;
    align-self: flex-start;
}
.pad-lottie {
    width: 95px; height: 95px;
    margin: -.5rem 0 .25rem;
}
.pad-rol {
    font-family: var(--sans);
    font-size: .52rem;
    font-weight: 600;
    letter-spacing: .25em;
    text-transform: uppercase;
    color: var(--gold-l);
    padding: .25rem .7rem;
    border: 1px solid rgba(196,169,125,.3);
}
.pad-name {
    font-family: var(--serif);
    font-size: 1rem;
    font-weight: 300;
    line-height: 1.5;
    color: rgba(255,255,255,.75);
}
.pad-amp {
    font-family: var(--script);
    font-size: 1.4rem;
    color: var(--gold);
    display: block;
}


/* ════════════════════════════════════════════════════════
   SEC 5 & 6: EVENTOS — Split editorial (alternating)
════════════════════════════════════════════════════════ */
.s-eventos { }

.evento-split {
    display: grid;
    grid-template-columns: 1fr 1fr;
    min-height: 75vh;
}
.evento-split-rev { direction: rtl; }
.evento-split-rev > * { direction: ltr; }

/* Photo side */
.ev-photo-side {
    position: relative;
    overflow: hidden;
}
.ev-photo {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: grayscale(12%) contrast(1.06) brightness(.94);
    transition: transform 8s ease;
    display: block;
}
.ev-photo-side:hover .ev-photo { transform: scale(1.05); }
.ev-photo-dark { filter: grayscale(30%) contrast(1.05) brightness(.7); }
.ev-photo-caption {
    position: absolute;
    bottom: 0; left: 0; right: 0;
    background: var(--ink);
    padding: .55rem 1.2rem;
    font-family: var(--sans);
    font-size: .5rem;
    font-weight: 500;
    letter-spacing: .22em;
    text-transform: uppercase;
    color: rgba(255,255,255,.5);
}

/* Text side */
.ev-text-side {
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 5rem 4rem;
    gap: 1.25rem;
}
.ev-text-cream { background: var(--cream-2); }
.ev-text-dark  { background: var(--ink-2); }

/* Number + Lottie inline row */
.ev-num-lottie-row {
    display: flex;
    align-items: center;
    gap: 1rem;
}
.ev-lottie-inline {
    width: 90px;
    height: 90px;
    flex-shrink: 0;
}
.ev-lottie-inline-light {
    filter: brightness(1.5);
}

.ev-number {
    font-family: var(--serif-alt);
    font-size: 5rem;
    font-weight: 400;
    color: rgba(0,0,0,.06);
    line-height: 1;
}
.ev-number-light { color: rgba(255,255,255,.06); }
.ev-tag {
    font-family: var(--sans);
    font-size: .52rem;
    font-weight: 600;
    letter-spacing: .25em;
    text-transform: uppercase;
    color: var(--ink-3);
}
.ev-tag-light { color: var(--gold-l); }
.ev-title {
    font-family: var(--serif);
    font-size: clamp(2.2rem, 4vw, 3.5rem);
    font-weight: 300;
    line-height: 1.05;
    color: var(--ink);
}
.ev-title em { font-style: italic; color: var(--ink-3); }
.ev-title-light { color: var(--white); }
.ev-title-light em { color: rgba(255,255,255,.5); }

.ev-details {
    display: flex;
    flex-direction: column;
    gap: .6rem;
    border-top: 1px solid rgba(0,0,0,.1);
    border-bottom: 1px solid rgba(0,0,0,.1);
    padding: 1rem 0;
}
.ev-det-row {
    display: flex;
    gap: 1.5rem;
    align-items: baseline;
}
.ev-dk {
    font-family: var(--sans);
    font-size: .5rem;
    font-weight: 600;
    letter-spacing: .18em;
    text-transform: uppercase;
    color: var(--ink-3);
    min-width: 60px;
}
.ev-dv {
    font-family: var(--serif);
    font-size: .95rem;
    font-weight: 300;
    color: var(--ink);
}
.ev-det-light .ev-dk { color: rgba(255,255,255,.4); }
.ev-det-light .ev-dv { color: rgba(255,255,255,.8); }
.ev-det-light { border-color: rgba(255,255,255,.08); }

.ev-btn {
    display: inline-block;
    font-family: var(--sans);
    font-size: .55rem;
    font-weight: 600;
    letter-spacing: .2em;
    text-transform: uppercase;
    padding: .8rem 1.8rem;
    border: 1px solid var(--ink);
    color: var(--ink);
    transition: background .25s, color .25s;
    align-self: flex-start;
}
.ev-btn:hover { background: var(--ink); color: var(--cream); }
.ev-btn-light { border-color: rgba(255,255,255,.3); color: var(--white); }
.ev-btn-light:hover { background: var(--white); color: var(--ink); }


/* ════════════════════════════════════════════════════════
   SEC 7: CRONOGRAMA
════════════════════════════════════════════════════════ */
.s-cronograma {
    background: var(--cream);
    padding: 0;
}
.cron-layout {
    display: grid;
    grid-template-columns: 380px 1fr;
    max-width: var(--max);
    margin: 0 auto;
    min-height: 600px;
}

/* Left: Sticky title block */
.cron-title-block {
    padding: 5rem 3rem 3rem var(--gap-lg);
    border-right: 1px solid rgba(0,0,0,.1);
    display: flex;
    flex-direction: column;
    gap: 1rem;
    position: sticky;
    top: 0;
    height: fit-content;
}
.cron-desc {
    font-family: var(--serif);
    font-size: .9rem;
    font-style: italic;
    color: var(--ink-3);
    line-height: 1.7;
}
.cron-deco-photo {
    position: relative;
    margin-top: 1.5rem;
    overflow: hidden;
}
.cron-deco-photo img {
    width: 100%;
    aspect-ratio: 4/5;
    object-fit: cover;
    filter: grayscale(20%);
}
.cdp-caption {
    position: absolute;
    bottom: 0; left: 0; right: 0;
    background: var(--ink);
    color: rgba(255,255,255,.5);
    font-family: var(--sans);
    font-size: .5rem;
    letter-spacing: .2em;
    text-transform: uppercase;
    padding: .4rem .6rem;
    text-align: center;
}

/* Right: Steps */
.cron-steps {
    padding: 5rem var(--gap-lg) 3rem 4rem;
    display: flex;
    flex-direction: column;
}
.cron-step {
    display: grid;
    grid-template-columns: 50px 80px 1fr;
    gap: 2rem;
    padding: 2rem 0;
    border-bottom: 1px solid rgba(0,0,0,.08);
    align-items: center;
    transition: background .3s;
}
.cs-lottie-wrap {
    width: 80px;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--cream-2);
    border-radius: 50%;
    padding: 5px;
    border: 1px solid rgba(0,0,0,0.05);
}
.cs-lottie {
    width: 100%;
    height: 100%;
}
.pe-lottie {
    width: 100%;
    aspect-ratio: 3/4;
    background: var(--white);
    display: block;
}
.cron-step:first-child { padding-top: 0; }
.cron-step:last-child  { border-bottom: none; }
.cron-step:hover { background: rgba(0,0,0,.02); }

.cs-num {
    font-family: var(--serif-alt);
    font-size: 2rem;
    font-weight: 400;
    color: rgba(0,0,0,.12);
    line-height: 1;
    text-align: right;
}
.cs-num-final { color: rgba(0,0,0,.2); }
.cs-body { display: flex; flex-direction: column; gap: .3rem; }
.cs-time {
    font-family: var(--sans);
    font-size: .55rem;
    font-weight: 600;
    letter-spacing: .18em;
    color: var(--gold);
    text-transform: uppercase;
}
.cs-title {
    font-family: var(--serif);
    font-size: 1.3rem;
    font-weight: 400;
    color: var(--ink);
}
.cs-title-final { font-style: italic; color: var(--gold); }
.cs-desc {
    font-family: var(--serif);
    font-size: .88rem;
    font-style: italic;
    color: var(--ink-3);
    line-height: 1.6;
}


/* ════════════════════════════════════════════════════════
   SEC 8: HISTORIA — Mosaic magazine spread
════════════════════════════════════════════════════════ */
.s-historia { background: var(--ink); }

.historia-header {
    display: flex;
    align-items: stretch;
    border-bottom: 1px solid rgba(255,255,255,.07);
}
.hh-vert-label {
    writing-mode: vertical-rl;
    text-orientation: mixed;
    transform: rotate(180deg);
    font-family: var(--serif-alt);
    font-size: clamp(2rem, 5vw, 4rem);
    font-weight: 400;
    color: rgba(255,255,255,.06);
    padding: 2rem .8rem;
    border-right: 1px solid rgba(255,255,255,.07);
    display: flex;
    align-items: center;
}
.hh-center {
    flex: 1;
    padding: 4rem var(--gap-lg) 3rem;
}

/* Mosaic grid */
.historia-mosaic {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    grid-template-rows: 340px 340px;
    gap: 4px;
    background: var(--ink-2);
}
.hm-cell {
    position: relative;
    overflow: hidden;
    cursor: pointer;
}
.hm-cell img {
    width: 100%; height: 100%;
    object-fit: cover;
    filter: grayscale(15%) contrast(1.05) brightness(.88);
    transition: transform 6s ease, filter .5s;
    display: block;
}
.hm-cell:hover img {
    transform: scale(1.07);
    filter: grayscale(0%) contrast(1.05) brightness(.92);
}
.hm-large { grid-row: 1 / 3; }
.hm-wide  { grid-column: 2 / 4; }

.hm-caption {
    position: absolute;
    bottom: 0; left: 0; right: 0;
    padding: .6rem .8rem;
    background: linear-gradient(transparent, rgba(0,0,0,.7));
    display: flex;
    gap: .5rem;
    align-items: baseline;
    opacity: 0;
    transition: opacity .35s;
}
.hm-cell:hover .hm-caption { opacity: 1; }
.hm-caption span {
    font-family: var(--sans);
    font-size: .5rem;
    font-weight: 600;
    letter-spacing: .15em;
    color: var(--gold-l);
}
.hm-caption {
    font-family: var(--serif);
    font-size: .82rem;
    font-style: italic;
    color: rgba(255,255,255,.8);
}


/* ════════════════════════════════════════════════════════
   SEC 9: DRESS CODE
════════════════════════════════════════════════════════ */
.s-dresscode {
    background: var(--cream-2);
}
.dc-split {
    display: grid;
    grid-template-columns: 1fr 1.2fr;
    padding: 5rem var(--gap-lg);
    max-width: var(--max);
    margin: 0 auto;
    gap: 5rem;
    align-items: center;
}
.dc-tag {
    display: block;
    font-family: var(--sans);
    font-size: .52rem;
    font-weight: 500;
    letter-spacing: .25em;
    text-transform: uppercase;
    color: var(--ink-3);
    margin-bottom: 1rem;
}
.dc-big {
    font-family: var(--serif-alt);
    font-size: clamp(4rem, 8vw, 8rem);
    font-weight: 400;
    line-height: .9;
    color: var(--ink);
    letter-spacing: -.01em;
    margin-bottom: 1rem;
}
.dc-big em {
    font-family: var(--script);
    font-style: normal;
    font-size: .7em;
    color: var(--gold);
    display: block;
    margin-top: .2rem;
    letter-spacing: normal;
}
.dc-sub-tag {
    display: inline-block;
    font-family: var(--sans);
    font-size: .52rem;
    font-weight: 600;
    letter-spacing: .25em;
    text-transform: uppercase;
    padding: .4rem 1rem;
    border: 1px solid var(--ink);
    color: var(--ink);
}
.dc-right {
    display: grid;
    grid-template-columns: 1fr 1px 1fr;
    gap: 2rem;
    align-items: start;
}
.dc-col-title {
    font-family: var(--sans);
    font-size: .58rem;
    font-weight: 600;
    letter-spacing: .22em;
    text-transform: uppercase;
    color: var(--ink);
    margin-bottom: .6rem;
}
.dc-rule { height: 1px; background: var(--ink); opacity: .2; margin-bottom: 1rem; }
.dc-col-text {
    font-family: var(--serif);
    font-size: .92rem;
    color: var(--ink-3);
    line-height: 1.75;
    font-style: italic;
}
.dc-col-sep { background: rgba(0,0,0,.12); }

/* Photo band below dress code */
.dc-photo-band {
    position: relative;
    height: 380px;
    overflow: hidden;
}
.dc-pb-img {
    width: 100%; height: 100%;
    object-fit: cover;
    object-position: center 20%;
    filter: grayscale(25%) brightness(.6);
}
.dc-pb-overlay {
    position: absolute; inset: 0;
    background: rgba(0,0,0,.3);
}
.dc-quote {
    position: absolute;
    bottom: 3rem; left: 50%;
    transform: translateX(-50%);
    text-align: center;
    max-width: 600px;
    width: 90%;
}
.dc-quote p {
    font-family: var(--serif);
    font-size: clamp(1.2rem, 3vw, 2rem);
    font-style: italic;
    font-weight: 300;
    color: var(--white);
    line-height: 1.4;
    margin-bottom: .5rem;
}
.dc-quote cite {
    font-family: var(--sans);
    font-size: .55rem;
    font-weight: 500;
    letter-spacing: .2em;
    text-transform: uppercase;
    color: var(--gold-l);
}


/* ════════════════════════════════════════════════════════
   SEC 10: REGALOS
════════════════════════════════════════════════════════ */
.s-regalo {
    background: var(--cream);
    padding: 5rem var(--gap-lg);
}
.s-regalo .section-label-row,
.rg-title {
    max-width: var(--max);
    margin-left: auto;
    margin-right: auto;
}
.rg-title { margin-bottom: 3rem; }

.regalo-duo {
    display: grid;
    grid-template-columns: 1fr 1fr;
    max-width: var(--max);
    margin: 0 auto;
    gap: 2rem;
}

/* Card shared */
.rg-card {
    border: 1px solid rgba(0,0,0,.12);
    background: var(--white);
    display: flex;
    flex-direction: column;
    overflow: hidden;
}
.rg-card-dark { background: var(--ink); border-color: var(--ink); }

/* Tipografía especial para regalos */
.rg-card-special {
    display: flex;
    flex-direction: row;
    align-items: center;
    padding: 3rem 2rem;
    gap: 2rem;
}
.rg-special-number {
    font-family: var(--serif-alt);
    font-size: 8rem;
    font-weight: 400;
    color: rgba(0,0,0,.04);
    line-height: .8;
    writing-mode: vertical-rl;
    transform: rotate(180deg);
}
.rg-num-light { color: rgba(255,255,255,.04); }

.rg-special-content {
    display: flex;
    flex-direction: column;
    flex: 1;
}
.rg-special-tag {
    font-family: var(--sans);
    font-size: .52rem;
    font-weight: 600;
    letter-spacing: .25em;
    text-transform: uppercase;
    color: var(--gold);
    margin-bottom: 1rem;
}
.rg-tag-light { color: var(--gold-l); }
.rg-special-title {
    font-family: var(--serif);
    font-size: 2.5rem;
    font-weight: 300;
    color: var(--ink);
    line-height: 1.05;
    margin-bottom: 1.5rem;
}
.rg-special-title em {
    font-family: var(--script);
    font-size: 1.4em;
    font-style: normal;
    color: var(--ink-3);
    display: block;
    margin-top: -10px;
}
.rg-title-light { color: var(--white); }
.rg-title-light em { color: rgba(255,255,255,.6); }

.rg-special-rule {
    width: 50px; height: 1px;
    background: var(--ink); opacity: .2;
    margin-bottom: 1.5rem;
}
.rg-rule-light { background: var(--white); }

.rg-special-text {
    font-family: var(--serif);
    font-size: .95rem;
    font-style: italic;
    color: var(--ink-3);
    line-height: 1.7;
    margin-bottom: 2rem;
}
.rg-special-loc {
    font-family: var(--sans);
    font-size: .52rem;
    font-weight: 500;
    letter-spacing: .2em;
    text-transform: uppercase;
    color: var(--gold);
}

/* Bank info */
.rg-bank-info {
    display: flex;
    flex-direction: column;
    gap: .5rem;
    margin: .5rem 1.5rem;
    padding: 1rem;
    border: 1px solid rgba(255,255,255,.08);
}
.rg-bank-row {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 1rem;
    border-bottom: 1px solid rgba(255,255,255,.05);
    padding-bottom: .4rem;
    font-family: var(--sans);
}
.rg-bank-row span {
    font-size: .5rem;
    font-weight: 500;
    letter-spacing: .15em;
    text-transform: uppercase;
    color: rgba(255,255,255,.35);
}
.rg-bank-row strong {
    font-size: .85rem;
    font-weight: 300;
    font-family: var(--serif);
    color: rgba(255,255,255,.8);
}
.btn-show-qr {
    display: block;
    width: calc(100% - 3rem);
    margin: auto 1.5rem 1.5rem;
    padding: .85rem;
    background: transparent;
    border: 1px solid rgba(255,255,255,.2);
    color: rgba(255,255,255,.7);
    font-family: var(--sans);
    font-size: .6rem;
    font-weight: 500;
    letter-spacing: .18em;
    text-transform: uppercase;
    cursor: pointer;
    transition: background .25s, color .25s;
}
.btn-show-qr:hover { background: var(--white); color: var(--ink); }

/* Flip Card */
#flip-wrapper { perspective: 1200px; }
.flip-inner {
    position: relative;
    width: 100%;
    height: 100%;
    min-height: 380px;
    transform-style: preserve-3d;
    transition: transform .75s var(--ease);
}
.flip-inner.flipped { transform: rotateY(180deg); }
.flip-face {
    position: absolute;
    inset: 0;
    backface-visibility: hidden;
    display: flex;
    flex-direction: column;
}
.flip-front-face { background: var(--ink); }
.flip-back-face {
    background: var(--ink-2);
    transform: rotateY(180deg);
    align-items: center;
    justify-content: center;
    gap: 1rem;
    padding: 2rem;
}
.qr-label {
    font-family: var(--sans);
    font-size: .52rem;
    font-weight: 500;
    letter-spacing: .22em;
    text-transform: uppercase;
    color: var(--gold-l);
}
.qr-box {
    width: 180px; height: 180px;
    background: var(--white);
    padding: .8rem;
    border: 1px solid rgba(255,255,255,.1);
}
.qr-img { width: 100%; height: 100%; object-fit: contain; }
.btn-dl-qr {
    display: inline-block;
    font-family: var(--sans);
    font-size: .55rem;
    font-weight: 500;
    letter-spacing: .18em;
    text-transform: uppercase;
    padding: .65rem 1.5rem;
    border: 1px solid rgba(255,255,255,.2);
    color: rgba(255,255,255,.7);
    cursor: pointer;
    transition: background .25s, color .25s;
}
.btn-dl-qr:hover { background: var(--white); color: var(--ink); }
.btn-back-qr {
    background: transparent;
    border: none;
    font-family: var(--sans);
    font-size: .52rem;
    letter-spacing: .12em;
    color: rgba(255,255,255,.3);
    cursor: pointer;
    text-transform: uppercase;
    transition: color .2s;
}
.btn-back-qr:hover { color: rgba(255,255,255,.7); }


/* ════════════════════════════════════════════════════════
   SEC 11: RSVP
════════════════════════════════════════════════════════ */
.s-rsvp {
    background: var(--ink);
    padding: 0;
}
.rsvp-layout {
    display: grid;
    grid-template-columns: 1fr 1.2fr;
    max-width: var(--max);
    margin: 0 auto;
    min-height: 640px;
}

/* RSVP Left */
.rsvp-left {
    padding: 5rem var(--gap-lg) 3rem;
    border-right: 1px solid rgba(255,255,255,.07);
    display: flex;
    flex-direction: column;
    gap: 1rem;
}
.rsvp-left .slr-line { background: rgba(255,255,255,.15); }
.rsvp-left .slr-text { color: rgba(255,255,255,.4); }
.rsvp-big {
    font-family: var(--serif);
    font-size: clamp(2.5rem, 5vw, 4.5rem);
    font-weight: 300;
    line-height: 1.05;
    color: var(--white);
}
.rsvp-big em { font-style: italic; color: rgba(255,255,255,.5); }
.rsvp-sub {
    font-family: var(--serif);
    font-size: .9rem;
    font-style: italic;
    color: rgba(255,255,255,.4);
    line-height: 1.7;
    max-width: 320px;
}

/* Deco photos overlap */
.rsvp-deco-photos {
    position: relative;
    height: 200px;
    margin-top: auto;
}
.rsvp-dp {
    position: absolute;
    width: 140px;
    aspect-ratio: 3/4;
    object-fit: cover;
    filter: grayscale(20%) brightness(.7);
    border: 3px solid var(--ink-2);
}
.rsvp-dp-1 { bottom: 0; left: 0; z-index: 2; }
.rsvp-dp-2 { bottom: 20px; left: 80px; z-index: 1; filter: grayscale(30%) brightness(.5); }

/* RSVP Right: Form */
.rsvp-right {
    padding: 5rem var(--gap-lg) 3rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
    position: relative;
}
.rsvp-form-header {
    font-family: var(--sans);
    font-size: .52rem;
    font-weight: 500;
    letter-spacing: .22em;
    text-transform: uppercase;
    color: var(--gold-l);
    padding-bottom: 1.5rem;
    border-bottom: 1px solid rgba(255,255,255,.07);
    margin-bottom: 1.5rem;
}
.rsvp-form { display: flex; flex-direction: column; gap: 1.2rem; }
.rf-field { display: flex; flex-direction: column; gap: .4rem; }
.rf-field label {
    font-family: var(--sans);
    font-size: .52rem;
    font-weight: 500;
    letter-spacing: .18em;
    text-transform: uppercase;
    color: rgba(255,255,255,.4);
}
.rf-field input,
.rf-field select,
.rf-field textarea {
    background: rgba(255,255,255,.04);
    border: 1px solid rgba(255,255,255,.1);
    color: var(--white);
    font-family: var(--serif);
    font-size: 1rem;
    padding: .75rem 1rem;
    outline: none;
    transition: border-color .2s;
    width: 100%;
    appearance: none;
    -webkit-appearance: none;
    resize: none;
    font-style: italic;
}
.rf-field input::placeholder,
.rf-field textarea::placeholder { color: rgba(255,255,255,.2); }
.rf-field input:focus,
.rf-field select:focus,
.rf-field textarea:focus { border-color: var(--gold-l); }
.rf-field select option { background: var(--ink-2); color: var(--white); }

.btn-rsvp {
    width: 100%;
    padding: 1rem;
    background: var(--white);
    border: none;
    color: var(--ink);
    font-family: var(--sans);
    font-size: .62rem;
    font-weight: 600;
    letter-spacing: .22em;
    text-transform: uppercase;
    cursor: pointer;
    transition: background .3s, color .3s;
    margin-top: .5rem;
}
.btn-rsvp:hover { background: var(--gold-l); }

.rsvp-stamp {
    position: absolute;
    top: 50%; right: 3rem;
    transform: translateY(-50%) rotate(12deg);
    font-family: var(--serif-alt);
    font-size: 1.8rem;
    color: rgba(196,169,125,.6);
    border: 3px solid rgba(196,169,125,.4);
    padding: .5rem 1rem;
    letter-spacing: .08em;
    opacity: 0;
    transition: opacity .4s;
    pointer-events: none;
    white-space: nowrap;
}
.rsvp-stamp.visible { opacity: 1; }


/* ════════════════════════════════════════════════════════
   FOOTER
════════════════════════════════════════════════════════ */
.site-footer { background: var(--cream-3); }
.footer-photo-split {
    display: grid;
    grid-template-columns: 1fr 360px;
    max-width: var(--max);
    margin: 0 auto;
    min-height: 320px;
}
.footer-left {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: .6rem;
    padding: 4rem var(--gap-lg);
}
.footer-nameplate {
    font-family: var(--serif);
    font-size: clamp(2rem, 4vw, 3.5rem);
    font-weight: 300;
    color: var(--ink);
}
.footer-nameplate span {
    font-family: var(--script);
    font-size: .7em;
    color: var(--gold);
    margin: 0 .3rem;
}
.footer-date {
    font-family: var(--sans);
    font-size: .7rem;
    font-weight: 300;
    letter-spacing: .3em;
    color: var(--ink-3);
    text-transform: uppercase;
}
.footer-place {
    font-family: var(--serif);
    font-size: .95rem;
    font-style: italic;
    color: var(--ink-3);
}
.footer-rule { height: 1px; background: var(--ink); opacity: .12; margin: .5rem 0; }
.footer-verse {
    font-family: var(--serif);
    font-size: .85rem;
    font-style: italic;
    color: var(--gold);
    line-height: 1.5;
}
.footer-right {
    overflow: hidden;
}
.footer-right img {
    width: 100%; height: 100%;
    object-fit: cover;
    filter: grayscale(20%) brightness(.9);
    display: block;
}
.footer-bottom-bar {
    background: var(--ink);
    text-align: center;
    padding: .75rem;
    font-family: var(--sans);
    font-size: .5rem;
    font-weight: 400;
    letter-spacing: .15em;
    text-transform: uppercase;
    color: rgba(255,255,255,.3);
}


/* ════════════════════════════════════════════════════════
   RESPONSIVE — TABLET
════════════════════════════════════════════════════════ */
@media (max-width: 1024px) {
    .portada-split { grid-template-columns: 1fr; }
    .portada-text  { padding: 3rem var(--gap) 2rem; border-right: none; }
    .portada-photos { min-height: 55vw; }
    .portada-photo-strip { grid-template-rows: none; grid-template-columns: 1fr 1fr 1fr; height: 55vw; }

    .contador-inner { grid-template-columns: 1fr; padding: 3rem var(--gap); gap: 2rem; }

    .padres-editorial-grid { grid-template-columns: 1fr; gap: 2rem; }
    .padres-center-col { display: none; }

    .padrinos-cards-row { grid-template-columns: 1fr; }
    .pad-card {
        border-right: none;
        border-bottom: 1px solid rgba(255,255,255,.06);
        align-items: center;
        text-align: center;
    }
    .pad-card:last-child { border-bottom: none; }
    .pad-name { text-align: center; }
    .pad-quote { text-align: center; }

    .evento-split       { grid-template-columns: 1fr 1fr; min-height: auto; }
    .evento-split-rev   { direction: rtl; }
    .ev-photo-side      { height: auto; order: 0; }
    .ev-text-side       { padding: 2rem 1.5rem; order: 0; }
    .ev-title           { font-size: clamp(1.8rem, 3vw, 2.5rem); }
    .ev-details         { display: none; } /* Ocultamos detalles en tablet si no caben, o ajustamos */
    .ev-btn             { font-size: .45rem; padding: .6rem 1rem; }
    .ev-number          { font-size: 3rem; }
    .ev-lottie-inline   { width: 60px; height: 60px; }

    .cron-layout { grid-template-columns: 1fr; }
    .cron-title-block { position: static; padding: 3rem var(--gap); border-right: none; border-bottom: 1px solid rgba(0,0,0,.1); }
    .cron-deco-photo { display: none; }
    .cron-steps { padding: 2rem var(--gap); }

    .dc-split { grid-template-columns: 1fr; gap: 2rem; padding: 3rem var(--gap); }
    .dc-photo-band { height: 260px; }

    .regalo-duo { grid-template-columns: 1fr; }
    .flip-inner { min-height: 400px; }

    .rsvp-layout { grid-template-columns: 1fr; }
    .rsvp-left { padding: 3rem var(--gap); border-right: none; border-bottom: 1px solid rgba(255,255,255,.07); }
    .rsvp-right { padding: 3rem var(--gap); }
    .rsvp-deco-photos { display: none; }

    .footer-photo-split { grid-template-columns: 1fr; }
    .footer-right { height: 260px; }
}


/* ════════════════════════════════════════════════════════
   RESPONSIVE — MOBILE
════════════════════════════════════════════════════════ */
@media (max-width: 640px) {

    /* Welcome overlay — stacked */
    .welcome-split { grid-template-columns: 1fr; grid-template-rows: 1fr 45vh; }
    .wlc-left { padding: 2.5rem 1.5rem; border-right: none; border-bottom: 1px solid rgba(0,0,0,.08); }
    .wlc-big-word { font-size: clamp(3rem, 14vw, 5rem); }
    .photo-strip { height: 100%; grid-template-rows: none; grid-template-columns: 1fr 1fr 1fr; }
    .wlc-rotated-text { display: none; }

    /* Portada */
    .portada-vert-label { display: none; }
    .portada-text { padding: 2rem 1.25rem; }
    .pht-top, .pht-bottom { font-size: clamp(2.5rem, 14vw, 4.5rem); }
    .pht-script { font-size: clamp(1.8rem, 10vw, 3.5rem); }
    .portada-photo-strip { grid-template-columns: 1fr 1fr 1fr; height: 60vw; }
    .portada-sub-row { flex-wrap: wrap; gap: 1rem; }
    .psr-divider { display: none; }
    .portada-nav { flex-wrap: wrap; justify-content: flex-start; }
    .pnav-link { border-bottom: 1px solid rgba(0,0,0,.06); }

    /* Contador */
    .contador-inner { padding: 3rem 1.25rem; }
    .cnt-num { font-size: clamp(3rem, 14vw, 5rem); }

    /* Padres */
    .s-padres { padding: 3rem 1.25rem; }
    .pe-lottie-accent { width: 60px; height: 60px; }

    /* Padrinos */
    .pb-content { padding: 2rem 1.25rem; }
    .pb-vert-label { display: none; }
    .pad-card { padding: 2rem 1.25rem; }

    /* Padrinos mobile extra */
    .pad-card {
        align-items: center;
        text-align: center;
    }
    .pad-lottie { margin: 0 auto; }
    .pad-num { align-self: center; }
    .pad-quote { text-align: center; max-width: 90%; margin: 0 auto; }

    /* Eventos */
    .evento-split { grid-template-columns: 1fr 1fr; }
    .ev-photo-side { height: auto; order: 0; }
    .ev-text-side { padding: 1.5rem 1rem; order: 0; }
    .ev-lottie-inline { width: 50px; height: 50px; }
    .ev-number { font-size: 2rem; }
    .ev-title { font-size: 1.6rem; }
    .ev-btn { padding: .5rem .8rem; font-size: .4rem; letter-spacing: .1em; width: 100%; text-align: center; }
    .ev-photo-caption { font-size: .4rem; padding: .4rem; }

    /* Cronograma */
    .cron-title-block { padding: 2.5rem 1.25rem; }
    .cron-steps { padding: 1.5rem 1.25rem; }
    .cron-step { gap: 1rem; }

    /* Historia mosaic — single column on mobile */
    .historia-mosaic {
        grid-template-columns: 1fr 1fr;
        grid-template-rows: auto;
    }
    .hm-large { grid-row: auto; grid-column: 1 / 3; aspect-ratio: 16/9; }
    .hm-wide  { grid-column: 1 / 3; aspect-ratio: 16/9; }
    .hh-vert-label { display: none; }
    .hh-center { padding: 2.5rem 1.25rem; }

    /* Dress code */
    .dc-split { padding: 2.5rem 1.25rem; }
    .dc-right { grid-template-columns: 1fr; }
    .dc-col-sep { display: none; }
    .dc-photo-band { height: 220px; }
    .dc-quote p { font-size: 1.1rem; }

    /* Regalos */
    .s-regalo { padding: 3rem 1.25rem; }
    .rg-card-special { padding: 2rem 1.5rem; gap: 1rem; flex-direction: column; text-align: center; }
    .rg-special-number { writing-mode: horizontal-tb; transform: none; font-size: 5rem; }
    .rg-special-rule { margin: 1rem auto; }
    .flip-inner { min-height: 440px; }

    /* RSVP */
    .rsvp-big { font-size: clamp(2rem, 12vw, 3rem); }
    .rsvp-stamp { font-size: 1.2rem; right: 1rem; }

    /* Footer */
    .footer-left { padding: 3rem 1.25rem; }

    /* Galería */
    .s-galeria { padding: 3rem 1.25rem; }
    .lottie-camera-wrap { width: 100px; height: 100px; }

    /* Cronograma & Lotties mobile overrides */
    .cron-step { grid-template-columns: 40px 60px 1fr; gap: 1rem; align-items: center; }
    .cs-lottie-wrap { width: 60px; height: 60px; }
    .ev-lottie-inline { width: 45px; height: 45px; }
}

/* ── ADDITIONAL CLASSES FOR GALLERY ── */
.ev-photo-side {
    position: relative;
}

.s-galeria {
    background: var(--cream-2);
    padding: 6rem var(--gap-lg);
    border-bottom: 1px solid rgba(0,0,0,.12);
}
.galeria-content {
    max-width: 600px;
    margin: 0 auto;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
}
.lottie-camera-wrap {
    width: 120px;
    height: 120px;
    background: var(--white);
    border: 1px solid var(--ink);
    border-radius: 50%;
    padding: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 15px rgba(0,0,0,0.08);
}
.lottie-camera {
    width: 100%;
    height: 100%;
}
.galeria-desc {
    font-family: var(--serif);
    font-size: 1.1rem;
    font-style: italic;
    color: var(--ink-3);
    line-height: 1.6;
}
.btn-upload {
    display: inline-block;
    background: var(--ink);
    color: var(--cream);
    font-family: var(--sans);
    font-size: .65rem;
    font-weight: 500;
    letter-spacing: .2em;
    padding: 1rem 2.5rem;
    border: none;
    cursor: pointer;
    transition: background .3s, transform .2s;
    text-transform: uppercase;
}
.btn-upload:hover {
    background: var(--gold);
    transform: translateY(-2px);
}


/* ════════════════════════════════════════════════════════
   RESPONSIVE — MOBILE PORTADA
   3 capas apiladas con position absolute:
   Capa 1 (fondo)  = fotoportadamobil2.webp — derecha, full height
   Capa 2 (medio)  = nombresmovil.webp     — 9:16, overlay
   Capa 3 (frente) = video saludo         — derecha, ancho = capa 1
════════════════════════════════════════════════════════ */

/* Ocultar mobile layers en desktop */
.portada-mobile-layers {
    display: none;
}

@media (max-width: 1080px) {

    /* ── Ocultar layout desktop en mobile ─────────── */
    .portada-desktop-only {
        display: none !important;
    }

    /* ── PORTADA MOBILE: full screen ─────────────────── */
    .s-portada {
        height: 100dvh;
        overflow: hidden;
    }

    /* El split ahora no es grid — es un contenedor para las capas */
    .portada-split {
        display: block;
        position: relative;
        flex: 1;
        height: calc(100dvh - 32px);
        min-height: 0;
        overflow: hidden;
    }

    /* ── Contenedor de capas mobile ────────────────── */
    .portada-mobile-layers {
        display: block;
        position: relative;
        width: 100%;
        height: 100%;
        overflow: hidden;
        background: var(--white);
    }

    /* Base para todas las capas */
    .pm-layer {
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        pointer-events: none;
    }

    /* ~~~~~ CAPA 1: fotoportadamobil2 (fondo) ~~~~~
       371×1280 — pegada a la DERECHA, full height,
       sin márgenes arriba/abajo/derecha.
       El ancho se calcula para mantener 371:1280 = ~29% del alto */
    .pm-layer-bg {
        z-index: 1;
        display: flex;
        justify-content: flex-end;   /* alineada a la derecha */
        align-items: stretch;
    }
    .pm-layer-bg .pm-layer-img {
        height: 100%;
        width: auto;                 /* ancho proporcional al alto: 371/1280 * height */
        object-fit: cover;
        object-position: center center;
        display: block;
    }

    /* ~~~~~ CAPA 2: nombresmovil (medio) ~~~~~
       720×1280 = 9:16 — full height, centrado.
       Siempre respeta la relación 9:16 adaptada a la pantalla */
    .pm-layer-names {
        z-index: 2;
        display: flex;
        align-items: center;
        justify-content: flex-start;
        padding-left: 6vw; /* Margen izquierdo estético */
    }
    .pm-layer-names .pm-layer-img {
        /* Ya no forzamos el alto al 100%, dejamos que escale si falta espacio a lo ancho */
        height: auto;
        max-height: 95%; /* Límite por si la pantalla es muy ancha */
        width: 100%;
        /* El ancho máximo exacto para NUNCA chocar con el video ni el margen */
        max-width: calc(100vw - (100vh * 371 / 1280) - 8vw);
        object-fit: contain;
        object-position: left center;
        display: block;
    }

    /* ~~~~~ CAPA 3: video (frente) ~~~~~
       Alineado a la DERECHA.
       La caja del video imita exactamente el tamaño del fondo (371x1280).
       El video 9:16 se ajusta dentro de esta caja con object-fit: contain. */
    .pm-layer-video {
        z-index: 3;
        display: flex;
        justify-content: flex-end;   /* alineado a la derecha */
        align-items: center;         /* centrado vertical */
        pointer-events: auto;
    }
    .pm-layer-vid {
        height: 100%;
        width: auto;
        max-width: none;
        aspect-ratio: 371 / 1280; /* Asegura que la caja mida igual que el fondo */
        flex-shrink: 0;
        object-fit: contain;      /* Mantiene la proporción 9:16 original del video */
        object-position: center center;
        display: block;
    }

    /* ── Nav mobile compacto ──────────────────────── */
    .portada-nav {
        height: 32px;
        flex-shrink: 0;
        overflow-x: auto;
    }
    .pnav-link {
        font-size: .4rem;
        padding: .55rem .6rem;
        letter-spacing: .1em;
    }
}

