/* Google Fonts: Cinzel, Montserrat, Architects Daughter
   Se cargan via <link> en el HTML (con preconnect) para evitar la cadena de bloqueo del @import. */

:root {
    --navy-dark: #0a1128;
    --navy-light: #1c2a4a;
    --gold: #d4af37;
    --gold-light: #f3e5ab;
    --parchment: #fcfbf7;
    --parchment-dark: #f5eedc;
    --text-dark: #1f2937;
    --text-muted: #4b5563;
}

body {
    font-family: 'Montserrat', sans-serif;
    background-color: var(--navy-dark);
    color: #f3f4f6;
    margin: 0;
    padding: 0;
}

html {
    background-color: #060b18;
}

body.public-view {
    max-width: 28rem;
    margin-left: auto;
    margin-right: auto;
    min-height: 100vh;
    box-shadow: 0 0 30px rgba(0, 0, 0, 0.85);
    background-color: var(--navy-dark);
    position: relative;
}

body.public-view,
body.public-view .font-deco,
body.public-view input,
body.public-view button,
body.public-view textarea,
body.public-view select {
    font-family: 'Architects Daughter', cursive, sans-serif !important;
}

/* Tipografía */
.font-deco {
    font-family: 'Cinzel', serif;
    letter-spacing: 0.05em;
}

.parallax-section {
    position: relative;
    height: 90vh;
    height: 90dvh;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    z-index: 1;
    /* clip-path creates a new containing block for fixed children,
       clipping the fixed background to only show within this section.
       This is the modern, iOS-compatible alternative to background-attachment:fixed. */
    clip-path: inset(0);
    -webkit-clip-path: inset(0);
}

.parallax-section-small {
    height: 120px !important;
}

.parallax-bg {
    /* Fixed positioning keeps the image stationary during scroll.
       clip-path on the parent constrains visibility to the section bounds. */
    position: fixed;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100%;
    max-width: 28rem;
    height: 100vh;
    height: 100dvh;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    z-index: -1;
}

.parallax-content {
    position: relative;
    z-index: 10;
    text-align: center;
    padding: 1.5rem;
    background: rgba(10, 17, 40, 0.78);
    border: 1px solid rgba(212, 175, 55, 0.35);
    border-radius: 12px;
    max-width: 85%;
    backdrop-filter: blur(5px);
}

/* Tarjeta Principal de Pergamino */
.card-pergamino {
    background: radial-gradient(circle, var(--parchment) 0%, var(--parchment-dark) 100%);
    color: var(--text-dark);
    border: 3px double var(--gold);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.5);
    border-radius: 16px;
}

/* Botones de Opción Gigantes (Radio Cards para Mayores) */
.option-card {
    background-color: #ffffff;
    border: 2px solid #e5e7eb;
    border-radius: 12px;
    padding: 1.15rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    cursor: pointer;
    transition: all 0.2s ease;
    user-select: none;
}

.option-card:hover {
    border-color: #cbd5e1;
    background-color: #f8fafc;
}

.option-card.selected {
    border-color: var(--gold);
    background-color: #fefcf3;
    box-shadow: 0 0 10px rgba(212, 175, 55, 0.25);
}

.option-card-title {
    font-size: 1.2rem;
    font-weight: 800;
    color: var(--navy-dark);
}

.option-card-desc {
    font-size: 0.95rem;
    color: var(--text-muted);
    margin-top: 0.25rem;
    font-weight: 600;
}

.option-radio-dot {
    width: 22px;
    height: 22px;
    border-radius: 50%;
    border: 2px solid #cbd5e1;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}

.option-card.selected .option-radio-dot {
    border-color: var(--gold);
    background-color: var(--gold);
}

.option-card.selected .option-radio-dot::after {
    content: '';
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background-color: white;
}

/* Tarjeta de Éxito con Fondo GIF */
.gif-success-card {
    position: relative;
    background-image: url('../../fotos/gif.webp');
    /* Se cargará dinámicamente si se añade el archivo */
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    border-radius: 16px;
    overflow: hidden;
    border: 3px double var(--gold);
    min-height: 480px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 2rem 1.5rem;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.5);
}

.gif-success-overlay {
    position: absolute;
    inset: 0;
    background: rgba(10, 17, 40, 0.35);
    z-index: 1;
}

.gif-success-content {
    position: relative;
    z-index: 2;
    color: #ffffff;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.9), 0 0 15px rgba(0, 0, 0, 0.6);
}

/* Controles de Contador de Grupo */
.counter-btn {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background-color: var(--navy-light);
    color: white;
    font-size: 1.5rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    border: none;
    cursor: pointer;
    transition: all 0.15s ease;
}

.counter-btn:hover {
    background-color: #273b66;
}

.counter-btn:active {
    transform: scale(0.95);
}

/* Botón de Confirmación Principal */
.btn-invitar {
    background-color: var(--navy-dark);
    color: white;
    font-size: 1.3rem;
    font-weight: 800;
    padding: 1.25rem;
    border-radius: 12px;
    border: 2px solid var(--gold);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    width: 100%;
    transition: all 0.2s ease;
}

.btn-invitar:hover {
    background-color: var(--navy-light);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(212, 175, 55, 0.2);
}

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

/* Inputs de Teléfono e Info */
.big-input {
    font-size: 1.5rem;
    padding: 1rem 1.25rem;
    border-radius: 10px;
    border: 2px solid #94a3b8;
    width: 100%;
    color: var(--text-dark);
    font-weight: 700;
    text-align: center;
}

.big-input:focus {
    outline: none;
    border-color: var(--gold);
    box-shadow: 0 0 8px rgba(212, 175, 55, 0.2);
}

/* Divisor Simple */
.divider-simple {
    width: 60px;
    height: 3px;
    background-color: var(--gold);
    margin: 1.5rem auto;
    border-radius: 2px;
}

/* Estilos de Animación */
@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }

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

.animate-slide-down {
    animation: slideDown 0.3s ease-out forwards;
}

/* GIF Success Progress Bar */
.gif-progress-bar-container {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 6px;
    background: rgba(255, 255, 255, 0.2);
    z-index: 10;
}

.gif-progress-bar {
    height: 100%;
    width: 0%;
    background-color: var(--gold);
}

.gif-progress-bar.animate {
    animation: fillProgress 7s linear forwards;
}

@keyframes fillProgress {
    0% {
        width: 0%;
    }

    100% {
        width: 100%;
    }
}

/* Forzar ocultamiento de elementos con la clase .hidden de Tailwind que puedan ser sobreescritos por display: flex; en este archivo */
.hidden {
    display: none !important;
}