/* ==========================================
   RESET & PALETA DE COLORES
   ========================================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --verde-suave: #687057;
    --verde-oscuro-sobre: #59614D;
    --bg-papel: #faf7f2;
    --texto-verde: #4c5643;
    --texto-negro: #111111;
    --dorado-accent: #c5a059;
    --texto-suave: #737b6c;
    --blanco-fondo: #ffffff;
    --verde-confirmar: #28c76f;

    --font-script: 'Pinyon Script', cursive;
    --font-serif: 'Cormorant Garamond', serif;
    --font-display: 'Bodoni Moda', serif;
    --font-sans: 'Montserrat', sans-serif;
}

html {
    -webkit-text-size-adjust: 100%;
}

html.text-scale-110 { font-size: 110%; }
html.text-scale-120 { font-size: 120%; }
html.text-scale-130 { font-size: 130%; }
html.text-scale-140 { font-size: 140%; }

body {
    background-color: #2b3028;
    font-family: var(--font-sans);
    min-height: 100vh;
    display: flex;
    justify-content: center;
    color: var(--texto-verde);
    overflow-x: hidden;
    width: 100%;
}

/* Evita que nombres largos o textos personalizados desborden en pantallas angostas */
h1, h2, h3, p, span, a {
    overflow-wrap: break-word;
    word-wrap: break-word;
}

img {
    max-width: 100%;
}

.oculto {
    display: none !important;
}

.text-size-controls {
    position: fixed;
    top: 12px;
    right: max(12px, calc((100vw - 460px) / 2 + 12px));
    z-index: 1100;
    display: flex;
    gap: 4px;
    padding: 4px;
    border: 1px solid rgba(255, 255, 255, 0.35);
    border-radius: 8px;
    background: rgba(43, 48, 40, 0.92);
    box-shadow: 0 3px 12px rgba(0, 0, 0, 0.2);
}

.text-size-controls button {
    min-width: 38px;
    min-height: 38px;
    padding: 0 8px;
    border: 0;
    border-radius: 5px;
    background: transparent;
    color: #ffffff;
    font: 600 0.9rem var(--font-sans);
    cursor: pointer;
}

.text-size-controls button:hover:not(:disabled) {
    background: rgba(255, 255, 255, 0.16);
}

.text-size-controls button:focus-visible {
    outline: 2px solid #e3c783;
    outline-offset: 1px;
}

.text-size-controls button:disabled {
    color: rgba(255, 255, 255, 0.45);
    cursor: default;
}

.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* Audio Flotante */
.audio-control {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 1000;
    background: rgba(255, 255, 255, 0.9);
    border: 1px solid var(--verde-suave);
    border-radius: 50%;
    width: 42px;
    height: 42px;
    font-size: 1.1rem;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* ==========================================
   PORTADA: SOBRE CERRADO
   ========================================== */
.envelope-screen {
    position: fixed;
    inset: 0;
    background-color: #2b3028;
    z-index: 500;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 0;
    transition: opacity 1.0s ease, visibility 1.0s ease;
}

.envelope-wrapper {
    position: relative;
    width: min(100%, 420px);
    height: min(600px, calc(100vh - 40px));
    overflow: hidden;
    border-radius: 10px;
    background-color: #4a523f;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.55);
    transition: width 0.3s ease, height 0.3s ease;
}

.envelope {
    position: relative;
    width: 100%;
    max-width: 420px;
    height: 600px;
    background-color: #4a523f;
    border-radius: 12px;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.55);
    overflow: hidden;
    background-image: 
        radial-gradient(circle at 50% 50%, rgba(255, 255, 255, 0.08) 0%, rgba(0, 0, 0, 0.3) 100%),
        url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='paperNoise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.035' numOctaves='4' result='noise'/%3E%3CfeDiffuseLighting in='noise' lighting-color='%23fff' surfaceScale='2.5'%3E%3CfeDistantLight azimuth='60' elevation='50'/%3E%3C/feDiffuseLighting%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23paperNoise)' opacity='0.22'/%3E%3C/svg%3E");
    background-blend-mode: overlay, normal;
}

.flap-top {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 56%;
    background-color: #687057;
    clip-path: polygon(0 0, 100% 0, 52% 96%, 50% 100%, 48% 96%);
    transform-origin: top;
    transition: transform 0.8s ease-in-out;
    z-index: 5;
    filter: drop-shadow(0 12px 14px rgba(0, 0, 0, 0.5));
    background-image: 
        linear-gradient(to bottom, rgba(255, 255, 255, 0.22) 0%, rgba(0, 0, 0, 0.25) 100%),
        url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='paperNoise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.035' numOctaves='4' result='noise'/%3E%3CfeDiffuseLighting in='noise' lighting-color='%23fff' surfaceScale='2.5'%3E%3CfeDistantLight azimuth='60' elevation='50'/%3E%3C/feDiffuseLighting%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23paperNoise)' opacity='0.22'/%3E%3C/svg%3E");
    background-blend-mode: overlay, normal;
}

.pocket-front {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 60%;
    z-index: 4;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
    filter: drop-shadow(0 -8px 15px rgba(0, 0, 0, 0.35));
    transition: transform 0.45s ease-out, opacity 0.25s ease-out;
}

.pocket-front-face {
    position: absolute;
    inset: 0;
    background-color: #515946;
    clip-path: polygon(0 100%, 100% 100%, 52% 2%, 50% 0%, 48% 2%);
    background-image: 
        linear-gradient(to top, rgba(0, 0, 0, 0.35) 0%, rgba(255, 255, 255, 0.08) 100%),
        url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='paperNoise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.035' numOctaves='4' result='noise'/%3E%3CfeDiffuseLighting in='noise' lighting-color='%23fff' surfaceScale='2.5'%3E%3CfeDistantLight azimuth='60' elevation='50'/%3E%3C/feDiffuseLighting%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23paperNoise)' opacity='0.22'/%3E%3C/svg%3E");
    background-blend-mode: overlay, normal;
}

.pocket-front-face::before,
.pocket-front-face::after {
    content: "";
    position: absolute;
    inset: 0;
    pointer-events: none;
}

.pocket-front-face::before {
    clip-path: polygon(0 100%, 0 0, 50% 0);
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.15), rgba(255, 255, 255, 0) 58%);
    box-shadow: inset 8px -8px 16px rgba(0, 0, 0, 0.12);
}

.pocket-front-face::after {
    clip-path: polygon(50% 0, 100% 0, 100% 100%);
    background: linear-gradient(225deg, rgba(0, 0, 0, 0.22), rgba(0, 0, 0, 0) 58%);
    box-shadow: inset -8px -8px 16px rgba(0, 0, 0, 0.14);
}

/* ==========================================
   🖼️ HOJA INTERNA REDISEÑADA (CON FOTO ABAJO)
   ========================================== */
.inner-card {
    position: absolute;
    bottom: 15px;
    left: 6%;
    width: 88%;
    height: 64%;
    background: #ffffff;
    border-radius: 12px;
    padding: 0; /* Sin padding general para ajustar la foto */
    text-align: center;
    z-index: 3;
    opacity: 0;
    transform: translateY(18%);
    transition: transform 1.2s cubic-bezier(0.25, 1, 0.5, 1) 0.3s, opacity 0.5s ease 0.2s;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: space-between;
    overflow: hidden;
    box-shadow: 0 15px 24px rgba(0, 0, 0, 0.28), 0 0 0 1px rgba(76, 86, 67, 0.1);
}

.inner-card-content {
    padding: 20px 15px 10px 15px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
}

.img-monograma-sobre {
    width: 65px;
    height: auto;
    object-fit: contain;
}

.nombres-vista-sobre {
    font-family: var(--font-display);
    font-size: 1.2rem;
    color: var(--texto-verde);
    margin-top: 4px;
}

.frase-vista-sobre {
    font-size: 0.65rem;
    letter-spacing: 2px;
    color: var(--dorado-accent);
    font-weight: 600;
}

.fecha-vista-sobre {
    font-family: var(--font-serif);
    font-size: 1.85rem;
    letter-spacing: 2.5px;
    color: var(--texto-suave);
    font-weight: 600;
    margin-top: 2px;
}

/* Foto del anillo completando la zona marcada */
.inner-card-image-box {
    width: 100%;
    height: 52%;
    overflow: hidden;
    position: relative;
}

.img-inner-anillo {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center 40%;
    display: block;
}

.info-reservada-frente {
    position: absolute;
    bottom: clamp(22px, 65%, 34px);
    left: 50%;
    transform: translateX(-50%);
    width: min(86%, 300px);
    text-align: center;
    z-index: 6;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}

.label-reservada-frente {
    font-size: 0.75rem;
    line-height: 1.4;
    letter-spacing: 0.08em;
    color: #ffffff;
    font-weight: 600;
    opacity: 0.95;
    text-transform: uppercase;
    white-space: normal;
}

.nombre-invitado-frente {
    font-family: var(--font-serif);
    font-size: 1.4rem;
    color: #ffffff;
    font-weight: 600;
    line-height: 1.2;
    text-shadow: 0 2px 6px rgba(0, 0, 0, 0.4);
}

.btn-abrir-transparente {
    background: rgba(255, 255, 255, 0.2);
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.5);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    padding: 10px 24px;
    border-radius: 25px;
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 1px;
    cursor: pointer;
    margin-top: 6px;
    transition: background 0.3s, transform 0.2s;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.btn-abrir-transparente:active {
    transform: scale(0.96);
}

.btn-sello-png {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 10;
    background: none;
    border: none;
    cursor: pointer;
    width: 88px;
    height: 88px;
    border-radius: 50%;
    transition: transform 0.3s, opacity 0.5s;
    isolation: isolate;
}

.btn-sello-png.seal-effects::after {
    content: "";
    position: absolute;
    inset: -8px;
    z-index: -1;
    border: 2px solid transparent;
    border-radius: 50%;
    background: conic-gradient(from 0deg, transparent 0deg 250deg, #f3d88f 300deg, #c5a059 330deg, transparent 360deg) border-box;
    -webkit-mask: linear-gradient(#fff 0 0) padding-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask: linear-gradient(#fff 0 0) padding-box, linear-gradient(#fff 0 0);
    mask-composite: exclude;
    opacity: 0.8;
    animation: sealOrbit 3.4s linear infinite;
    pointer-events: none;
}

.btn-sello-png.seal-effects:hover {
    transform: translate(-50%, -50%) translateY(-2px) scale(1.025);
}

.btn-sello-png.seal-effects:active {
    transform: translate(-50%, -50%) scale(0.96);
}

.btn-sello-png:not(.seal-effects):hover {
    transform: translate(-50%, -50%) scale(1.08);
}

.btn-sello-png:focus-visible {
    outline: 2px solid #f3d88f;
    outline-offset: 12px;
}

.img-sello {
    width: 100%;
    height: 100%;
    object-fit: contain;
    filter: drop-shadow(0 6px 12px rgba(0, 0, 0, 0.5));
}

.seal-effects .img-sello {
    animation: sealBreath 3.8s ease-in-out infinite;
}

@keyframes sealBreath {
    0%, 100% { filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.4)); }
    50% { filter: drop-shadow(0 9px 16px rgba(197, 160, 89, 0.68)); }
}

@keyframes sealOrbit {
    to { transform: rotate(360deg); }
}

/* ESTADO ABIERTO DEL SOBRE */
.envelope-wrapper.open .flap-top {
    transform: rotateX(-180deg);
    z-index: 1;
}

.envelope-wrapper.open .inner-card {
    opacity: 1;
    transform: translateY(-22%);
}

.envelope-wrapper.open .pocket-front {
    transform: translateY(105%);
    opacity: 0;
}

.envelope-wrapper.open .btn-sello-png,
.envelope-wrapper.open .info-reservada-frente {
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.envelope-wrapper.open .btn-sello-png.seal-effects::after,
.envelope-wrapper.open .btn-sello-png.seal-effects .img-sello {
    animation-play-state: paused;
}

.envelope-screen.fade-out {
    opacity: 0;
    visibility: hidden;
}

/* ==========================================
   ESTRUCTURA GENERAL INVITACIÓN
   ========================================== */
.invitacion-container {
    width: 100%;
    max-width: 460px;
    min-height: 100vh;
    padding: 0 0 45px 0;
    display: flex;
    flex-direction: column;
    box-shadow: 0 0 35px rgba(0,0,0,0.3);
    overflow: hidden;
    background-color: var(--bg-papel);
    background-image: 
        radial-gradient(rgba(0, 0, 0, 0.03) 1px, transparent 0),
        radial-gradient(rgba(0, 0, 0, 0.02) 1px, transparent 0);
    background-size: 8px 8px, 12px 12px;
    background-position: 0 0, 4px 4px;
}

.section-block {
    text-align: center;
}

.scroll-cue {
    position: fixed;
    right: max(12px, calc((100vw - 460px) / 2 + 12px));
    bottom: 28px;
    z-index: 1200;
    pointer-events: none;
    transition: opacity 0.4s ease, transform 0.4s ease;
}

.scroll-cue-light {
    position: absolute;
    left: 50%;
    bottom: 100%;
    width: 2px;
    height: 48px;
    overflow: hidden;
    transform: translateX(-50%);
    background: linear-gradient(to bottom, transparent, rgba(243, 216, 143, 0.65));
}

.scroll-cue-light::after {
    content: "";
    position: absolute;
    top: -8px;
    left: 50%;
    width: 5px;
    height: 8px;
    border-radius: 50%;
    background: #f3d88f;
    box-shadow: 0 0 10px 3px rgba(243, 216, 143, 0.7);
    transform: translateX(-50%);
    animation: bajarLuz 2.8s ease-in-out infinite;
}

.scroll-cue-circle {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    background: rgba(43, 48, 40, 0.94);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    border: 2px solid #d7b56d;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ffffff;
    box-shadow: 0 3px 14px rgba(0, 0, 0, 0.35);
    animation: flotarFlecha 1.8s ease-in-out infinite, pulsoAnillo 1.8s ease-out infinite;
}

.scroll-cue-arrow {
    width: 24px;
    height: 24px;
}

.scroll-cue.is-hidden {
    opacity: 0;
    transform: translateY(14px);
}

@keyframes flotarFlecha {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(7px); }
}

@keyframes pulsoAnillo {
    0% { box-shadow: 0 0 0 0 rgba(255, 255, 255, 0.28); }
    70% { box-shadow: 0 0 0 10px rgba(255, 255, 255, 0); }
    100% { box-shadow: 0 0 0 0 rgba(255, 255, 255, 0); }
}

@keyframes bajarLuz {
    0% { top: -8px; opacity: 0; }
    18% { opacity: 1; }
    82% { opacity: 0.85; }
    100% { top: 100%; opacity: 0; }
}

.header-imagen-wrapper {
    position: relative;
    width: 100%;
    padding-top: 1px;
    margin-bottom: 20px;
}

.img-monograma-superpuesto {
    position: absolute;
    top: 150px;
    left: 90%;
    transform: translateX(-50%);
    width: 85px;
    height: auto;
    object-fit: contain;
    z-index: 10;
}

.contenedor-imagen-anillo {
    width: 100%;
    height: 230px;
    margin: 0;
    overflow: hidden;
}

.img-anillo {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center 50%;
    display: block;
}

.frase-bendicion,
.seccion-padres,
.bloque-central,
.frase,
.banner-fecha-boda {
    padding-left: 25px;
    padding-right: 25px;
}

.frase-bendicion {
    font-size: 0.68rem;
    letter-spacing: 2px;
    color: var(--texto-suave);
    font-weight: 600;
    margin-top: 15px;
    margin-bottom: 20px;
    line-height: 1.4;
}

.seccion-padres {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
    margin-bottom: 25px;
}

.rol-padres {
    font-size: 0.65rem;
    letter-spacing: 1.5px;
    color: var(--dorado-accent);
    font-weight: 600;
    margin-bottom: 6px;
}

.rol-padres-novia {
    color: var(--texto-negro);
}

.nombre-padre {
    font-family: var(--font-serif);
    font-size: 0.95rem;
    color: var(--texto-negro);
    margin-bottom: 2px;
}

.detalle-top {
    font-family: var(--font-script);
    font-size: 2.5rem;
    color: var(--verde-suave);
    font-weight: 600;
}

.contenedor-nombres-novios {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0;
}

.nombre-novio, .nombre-novia {
    font-family: var(--font-serif);
    font-size: 2rem;
    font-weight: 700;
    color: var(--texto-negro);
    font-style: italic;
    letter-spacing: 0.5px;
    line-height: 1.15;
}

.ampersand-destacado {
    font-family: 'Times New Roman', serif;
    font-size: 1.2rem;
    color: var(--dorado-accent);
    display: block;
    line-height: 1;
    margin: 1dvb 0;
}

.frase-negra {
    font-family: var(--font-serif);
    font-style: italic;
    font-size: 1.25rem;
    color: var(--texto-negro);
    line-height: 1.5;
    margin: 18px 0;
}

.banner-fecha-boda {
    background-color: rgba(255, 255, 255, 0.85);
    border: 1px solid var(--dorado-accent);
    border-radius: 8px;
    padding: 12px 10px;
    margin: 15px 25px 0 25px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.05);
    display: flex;
    align-items: center;
    gap: 14px;
    text-align: left;
}

.icono-fecha-boda {
    width: 42px;
    height: 42px;
    object-fit: contain;
    flex-shrink: 0;
}

.texto-fecha-boda {
    display: flex;
    flex-direction: column;
}

.label-nos-casamos {
    font-size: 0.8rem;
    letter-spacing: 2px;
    color: var(--dorado-accent);
    font-weight: 600;
    display: block;
    text-transform: uppercase;
}

.fecha-destacada {
    font-family: var(--font-serif);
    font-size: 1.15rem;
    font-weight: 600;
    color: var(--texto-verde);
    letter-spacing: 0.8px;
    margin-top: 4px;
    font-variant-numeric: lining-nums;
}

/* SECCIÓN VERDE */
.section-verde {
    position: relative;
    background-color: #687057;
    color: #ffffff;
    padding: 50px 25px 40px 25px;
    margin-top: 30px;
    overflow: hidden;
    background-image: 
        radial-gradient(rgba(0, 0, 0, 0.08) 1px, transparent 0),
        radial-gradient(rgba(255, 255, 255, 0.05) 1px, transparent 0);
    background-size: 10px 10px, 14px 14px;
    background-position: 0 0, 5px 5px;
    box-shadow: inset 0 8px 12px rgba(0,0,0,0.06);
}

.decoracion-hojas-lateral {
    position: absolute;
    top: 50%;
    left: 0;
    transform: translateY(-50%);
    width: 300px;
    pointer-events: none;
    z-index: 1;
}

.img-hojas-lateral {
    width: 100%;
    height: auto;
    object-fit: contain;
    opacity: 0.75;
}

.contenido-celebracion {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.titulo-celebracion {
    font-family: var(--font-serif);
    font-size: 2.1rem;
    font-weight: 400;
    color: #ffffff;
    letter-spacing: 1px;
}

.linea-divisora {
    width: 50px;
    height: 1px;
    background-color: rgba(255, 255, 255, 0.5);
    margin: 12px 0 20px 0;
}

.lugar-texto {
    font-family: var(--font-serif);
    font-size: 1.15rem;
    font-weight: 600;
    color: #ffffff;
    margin-bottom: 6px;
}

.hora-texto {
    font-size: 0.9rem;
    color: #f0f2ed;
    font-weight: 300;
    margin-bottom: 25px;
    letter-spacing: 0.5px;
}

.bloque-eventos {
    display: flex;
    flex-direction: column;
    gap: 15px;
    width: 100%;
    max-width: 280px;
    margin-bottom: 25px;
}

.item-evento {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    background: rgba(255, 255, 255, 0.12);
    padding: 10px 18px;
    border-radius: 30px;
    border: 1px solid rgba(255, 255, 255, 0.25);
    backdrop-filter: blur(4px);
}

.icono-evento {
    font-size: 1.2rem;
}

.nombre-evento {
    font-family: var(--font-serif);
    font-size: 1.05rem;
    color: #ffffff;
    letter-spacing: 0.5px;
}

.contenedor-copas {
    width: 70px;
    height: auto;
    margin: 15px 0 20px 0;
    display: flex;
    justify-content: center;
}

.img-brindis {
    width: 100%;
    max-width: 65px;
    height: auto;
    object-fit: contain;
    filter: drop-shadow(0 2px 4px rgba(0,0,0,0.15));
}

.btn-mapa {
    display: inline-block;
    background-color: #ffffff;
    color: #2b3028;
    text-decoration: none;
    font-size: 0.82rem;
    font-weight: 600;
    padding: 12px 22px;
    border-radius: 25px;
    box-shadow: 0 4px 14px rgba(0,0,0,0.15);
    transition: transform 0.25s ease, box-shadow 0.25s ease, background-color 0.2s;
    letter-spacing: 0.5px;
    animation: latidoMapa 2.6s ease-in-out infinite;
}

.btn-mapa:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 22px rgba(0,0,0,0.22);
    background-color: #fdfdfd;
    animation-play-state: paused;
}

.btn-mapa:active {
    transform: scale(0.96);
    background-color: #f0f2ed;
    box-shadow: 0 4px 10px rgba(0,0,0,0.15);
}

@keyframes latidoMapa {
    0%, 100% { box-shadow: 0 4px 14px rgba(0,0,0,0.15), 0 0 0 0 rgba(255, 255, 255, 0.5); }
    50% { box-shadow: 0 4px 14px rgba(0,0,0,0.15), 0 0 0 10px rgba(255, 255, 255, 0); }
}

/* ==========================================
   VISTA 4: CONFIRMACIÓN PANTALLA DIVIDIDA LADO A LADO
   ========================================== */
.tarjeta-confirmacion-full {
    position: relative;
    width: 100%;
    min-height: 100vh;
    display: flex;
    flex-direction: row;
    background-color: var(--blanco-fondo);
    overflow: hidden;
}

.contenedor-imagen-juntos {
    position: relative;
    flex: 1 1 50%;
    height: 100vh;
    overflow: hidden;
}

.img-juntos-foto {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center 20%;
}

.degradado-integracion {
    position: absolute;
    inset: 0;
    background: linear-gradient(to left, var(--blanco-fondo) 0%, rgba(255,255,255,0) 25%);
}

.panel-confirmacion {
    flex: 0 0 50%;
    height: 100vh;
    background-color: var(--blanco-fondo);
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 18px;
    z-index: 2;
    box-shadow: -10px 0 20px rgba(0,0,0,0.03);
}

.contenido-panel {
    width: 100%;
    max-width: 340px;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
}

/* Estilo del título con 'de' en minúscula */
.titulo-confirmacion-lateral {
    font-family: var(--font-serif);
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--texto-verde);
    margin-bottom: 8px;
}

.panel-confirmacion .linea-divisora {
    width: 50px;
    height: 1px;
    background-color: var(--dorado-accent);
    margin-bottom: 25px;
}

.mensaje-bienvenida-lateral {
    font-family: var(--font-serif);
    font-size: 1.05rem;
    color: #000000;
    line-height: 1.6;
    font-weight: 400;
    margin-bottom: 20px;
}

.bloque-fecha-elegante {
    display: flex;
    align-items: center;
    gap: 16px;
    margin: 10px 0;
    text-align: left;
    width: 100%;
    justify-content: center;
}

.badge-icono-calendario {
    width: 52px;
    height: 52px;
    min-width: 52px;
    background-color: #dbe4ce;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.icono-calendario-svg {
    width: 26px;
    height: 26px;
    color: #3e4735;
}

.info-fecha-texto {
    display: flex;
    flex-direction: column;
}

.subtitulo-limite-muestra {
    font-family: var(--font-sans);
    font-size: 0.65rem;
    letter-spacing: 2px;
    color: var(--texto-suave);
    font-weight: 600;
    text-transform: uppercase;
}

.fecha-limite-muestra {
    font-family: var(--font-sans);
    font-size: 0.8rem;
    font-weight: 700;
    color: #1e3322;
    line-height: 1.2;
    margin-top: 2px;
}

.linea-subrayado-fecha {
    width: 100px;
    height: 2px;
    background-color: #c0cbaf;
    border-radius: 2px;
    margin-top: 6px;
}

.aclaracion-cupo-muestra {
    font-family: var(--font-sans);
    font-style: italic;
    font-size: 0.82rem;
    color: var(--texto-suave);
    margin-top: 5px;
    margin-bottom: 25px;
    text-align: center;
}

.btn-whatsapp-compacto {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    background-color: var(--verde-confirmar);
    color: #ffffff;
    padding: 12px 20px;
    border-radius: 25px;
    text-decoration: none;
    font-family: var(--font-sans);
    font-weight: 400;
    font-size: 0.85rem;
    letter-spacing: 1px;
    white-space: nowrap;
    transition: background 0.3s, transform 0.2s, box-shadow 0.3s;
    box-shadow: 0 4px 12px rgba(40, 199, 111, 0.3);
    animation: latidoWhatsapp 2.6s ease-in-out infinite;
}

.btn-whatsapp-compacto:hover {
    background-color: #21a65c;
    transform: translateY(-3px);
    animation-play-state: paused;
    box-shadow: 0 10px 20px rgba(40, 199, 111, 0.4);
}

.btn-whatsapp-compacto:active {
    transform: scale(0.97);
}

@keyframes latidoWhatsapp {
    0%, 100% { box-shadow: 0 4px 12px rgba(40, 199, 111, 0.3), 0 0 0 0 rgba(40, 199, 111, 0.45); }
    50% { box-shadow: 0 4px 12px rgba(40, 199, 111, 0.3), 0 0 0 10px rgba(40, 199, 111, 0); }
}

.icono-ws {
    width: 20px;
    height: 20px;
}

/* ==========================================
   BOTÓN DE MÚSICA
   ========================================== */
.music-floating-wrapper {
    position: fixed;
    top: 70%;
    left: 20px;
    transform: translateY(-50%);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
}

.music-disc-btn {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: #faf7f2;
    border: 2px solid var(--verde-suave);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    outline: none;
    transition: transform 0.2s ease;
    position: relative;
    z-index: 2;
}

.music-disc-btn:active {
    transform: scale(0.92);
}

.disc-icon {
    font-size: 1.3rem;
    display: inline-block;
}

.music-disc-btn.playing {
    animation: girarDisco 4s linear infinite;
}

@keyframes girarDisco {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.notes-container {
    position: absolute;
    bottom: 35px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 120px;
    pointer-events: none;
    z-index: 1;
}

.music-note {
    position: absolute;
    bottom: 0;
    font-size: 1.4rem;
    color: var(--verde-oscuro-sobre);
    opacity: 0;
    animation: flotarNota 2.5s ease-out forwards;
}

.music-note--left-18 { left: calc(50% - 18px); }
.music-note--left-12 { left: calc(50% - 12px); }
.music-note--left-6 { left: calc(50% - 6px); }
.music-note--left-0 { left: 50%; }
.music-note--left-6-positive { left: calc(50% + 6px); }
.music-note--left-12-positive { left: calc(50% + 12px); }
.music-note--left-18-positive { left: calc(50% + 18px); }

@media (prefers-reduced-motion: reduce) {
    .btn-sello-png.seal-effects::after,
    .btn-sello-png.seal-effects .img-sello,
    .scroll-cue-light::after {
        animation: none;
    }
}

@keyframes flotarNota {
    0% { transform: translateY(0) scale(0.7) rotate(0deg); opacity: 0; }
    20% { opacity: 0.9; }
    100% { transform: translateY(-110px) scale(1.3) rotate(25deg); opacity: 0; }
}

/* ==========================================
   📱 ADAPTABILIDAD MÓVIL LADO A LADO
   ========================================== */
@media (max-width: 768px) {
    .envelope-screen {
        padding: 0;
        overflow-y: auto;
        align-items: flex-start;
    }

    .envelope-wrapper {
        width: 100vw;
        height: max(100vh, 480px);
        height: max(100dvh, 480px);
        max-height: none;
        flex: 0 0 auto;
        border-radius: 0;
        box-shadow: none;
    }

    .inner-card {
        left: 5%;
        width: 90%;
    }

    .nombres-vista-sobre {
        font-size: 1.4rem;
    }

    .info-reservada-frente {
        width: 86%;
        padding: 0 20px;
        bottom: clamp(22px, 5%, 34px);
    }

    .label-reservada-frente {
        font-size: 0.8rem;
        letter-spacing: 0.06em;
    }

    .nombre-invitado-frente {
        font-size: 1.6rem;
        word-break: break-word;
    }

    .btn-sello-png {
        width: 78px;
        height: 78px;
    }
}

@media (max-width: 768px) {
    .tarjeta-confirmacion-full {
        flex-direction: row !important;
        min-height: 100vh;
        align-items: stretch;
    }

    .contenedor-imagen-juntos {
        flex: 0 0 50% !important;
        height: 88vh !important;
        align-self: center;
    }

    .img-juntos-foto {
        object-position: 58% center;
    }

    .degradado-integracion {
        background: linear-gradient(to left, var(--blanco-fondo) 5%, rgba(255,255,255,0) 100%);
    }

    .panel-confirmacion {
        flex: 0 0 50% !important;
        height: 88vh !important;
        align-self: center;
        padding: 15px 10px !important;
    }

    .contenido-panel {
        max-width: 100%;
        gap: 12px;
    }

    .titulo-confirmacion-lateral {
        font-size: 1.8rem;
        line-height: 1.1;
    }

    .mensaje-bienvenida-lateral {
        font-size: 1.10rem;
        line-height: 1.35;
        margin-bottom: 10px;
    }

    .bloque-fecha-elegante {
        gap: 8px;
        margin: 5px 0;
    }

    .badge-icono-calendario {
        width: 38px;
        height: 38px;
        min-width: 38px;
    }

    .icono-calendario-svg {
        width: 20px;
        height: 20px;
    }

    .subtitulo-limite-muestra {
        font-size: 0.52rem;
        letter-spacing: 1px;
    }

    .fecha-limite-muestra {
        font-size: 0.85rem;
    }

    .linea-subrayado-fecha {
        width: 60px;
    }

    .aclaracion-cupo-muestra {
        font-size: 0.80rem;
        margin-bottom: 12px;
    }

    .btn-whatsapp-compacto {
        padding: 9px 12px;
        font-size: 0.72rem;
        letter-spacing: 0.3px;
        gap: 7px;
    }

    .icono-ws {
        width: 16px;
        height: 16px;
    }
}

/* ==========================================
   📱 TELÉFONOS ANGOSTOS: mismo diseño lado a lado, solo más compacto
   ========================================== */
@media (max-width: 480px) {
    .contenedor-imagen-juntos {
        flex: 0 0 42% !important;
    }

    .panel-confirmacion {
        flex: 0 0 58% !important;
        padding: 12px 8px !important;
    }

    .contenido-panel {
        gap: 10px;
    }

    .titulo-confirmacion-lateral {
        font-size: 1.8rem;
        line-height: 1.1;
    }

    .mensaje-bienvenida-lateral {
        font-size: 1.05rem;
        line-height: 1.35;
        margin-bottom: 8px;
    }

    .bloque-fecha-elegante {
        gap: 6px;
    }

    .badge-icono-calendario {
        width: 32px;
        height: 32px;
        min-width: 32px;
    }

    .icono-calendario-svg {
        width: 16px;
        height: 16px;
    }

    .subtitulo-limite-muestra {
        font-size: 0.46rem;
    }

    .fecha-limite-muestra {
        font-size: 0.75rem;
    }

    .linea-subrayado-fecha {
        width: 45px;
    }

    .aclaracion-cupo-muestra {
        font-size: 0.82rem;
        margin-bottom: 8px;
    }

    .btn-whatsapp-compacto {
        padding: 8px 10px;
        font-size: 0.80rem;
        letter-spacing: 0.2px;
        gap: 5px;
    }

    .icono-ws {
        width: 14px;
        height: 14px;
    }
}

/* ==========================================
   📱 TELÉFONOS MUY PEQUEÑOS (320px-360px)
   ========================================== */
@media (max-width: 380px) {
    .img-monograma-superpuesto {
        top: 100px;
        width: 65px;
    }

    .contenedor-imagen-anillo {
        height: 190px;
    }

    .detalle-top {
        font-size: 2rem;
    }

    .nombre-novio, .nombre-novia {
        font-size: 1.65rem;
    }

    .ampersand-destacado {
        font-size: 1.1rem;
    }

    .frase-negra {
        font-size: 0.95rem;
    }

    .titulo-celebracion {
        font-size: 1.7rem;
    }

    .lugar-texto {
        font-size: 1rem;
    }

    .nombre-evento {
        font-size: 0.95rem;
    }

    .frase-bendicion,
    .seccion-padres,
    .bloque-central,
    .frase,
    .banner-fecha-boda {
        padding-left: 18px;
        padding-right: 18px;
    }

    .fecha-destacada {
        font-size: 0.85rem;
    }
}