/* =========================================
   ESTILOS DE SCROLL SUAVE Y PERSONALIZADO
========================================= */

/* 1. Scroll Suave global */
html {
    scroll-behavior: smooth;
}

/* 2. Barra de Desplazamiento Personalizada (Webkit: Chrome, Safari, Edge) */
::-webkit-scrollbar {
    width: 8px; /* Ancho de la barra */
}

::-webkit-scrollbar-track {
    background: #121212; /* Fondo de la barra (oscuro) */
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, var(--accent-gold, #D4AF37), #997A15); /* Degradado dorado */
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #E5C158; /* Dorado más brillante al pasar el cursor */
}

/* 3. Soporte para Firefox */
* {
    scrollbar-width: thin;
    scrollbar-color: var(--accent-gold, #D4AF37) #121212;
}

/* VARIABLES GLOBALES */
:root {
    --bg-color: #FAFAFA; /* Blanco hueso muy elegante */
    --text-main: #333333; /* Gris carbón para no cansar la vista */
    --accent-gold: #0080ff;
    --font-titles: 'Playfair Display', serif;
    --font-text: 'Montserrat', sans-serif;
}


/* RESETEO BÁSICO */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background-color: var(--bg-color);
    color: var(--text-main);
    font-family: var(--font-text);
    text-align: center;
    overflow-x: hidden;
}

/* TIPOGRAFÍA */
h1, h2, h3 {
    font-family: var(--font-titles);
    font-weight: 400;
}

h2 {
    font-size: 2rem;
    margin-bottom: 1.5rem;
    color: var(--accent-gold);
}

/* HERO SECTION (PORTADA) */
.hero-section {
    height: 100vh;
    display: flex;
    align-items: flex-end; /* Cambiamos 'center' por 'flex-end' para enviarlo abajo */
    justify-content: center;
    padding-bottom: 15vh; /* Le damos un respiro para que no pegue al borde del celular */
}

.hero-content {
    text-align: center;
    /* El efecto de Cristal Esmerilado */
    background: rgba(255, 255, 255, 0.55); /* Blanco al 55% de opacidad */
    backdrop-filter: blur(8px); /* Difumina lo que hay exactamente detrás del cuadro */
    -webkit-backdrop-filter: blur(8px); /* Soporte para Safari/iPhone */
    
    /* Espaciado y forma */
    padding: 40px 50px;
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.6); /* Borde sutil brillante */
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1); /* Sombra suave para separar el cuadro */
    
    max-width: 90%;
    margin: 0 auto;
}

.hero-content .subtitle {
    font-size: 0.9rem;
    letter-spacing: 2px;
    text-transform: uppercase;
    margin-bottom: 10px;
    color: #222; /* Súper oscuro para contraste perfecto */
    font-weight: 700;
}

.hero-content .title {
    font-size: 4rem;
    font-style: italic;
    color: var(--accent-gold);
    margin-bottom: 15px;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.15); /* Pequeña sombra al oro para resaltarlo */
}

/* SECCIONES GENERALES */
section {
    padding: 4rem 1.5rem;
}

/* TARJETAS DE DETALLES */
.card-container {
    display: flex;
    flex-direction: column;
    gap: 20px;
    max-width: 600px;
    margin: 0 auto;
}

.detail-card {
    background: #fff;
    padding: 2rem;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
}

.detail-card h3 {
    font-size: 1.5rem;
    margin-bottom: 10px;
}

/* BOTONES */
.btn-primary, .btn-gold {
    display: inline-block;
    margin-top: 15px;
    padding: 10px 25px;
    text-decoration: none;
    border-radius: 30px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.btn-primary {
    background: transparent;
    color: var(--text-main);
    border: 1px solid var(--text-main);
}

.btn-gold {
    background: var(--accent-gold);
    color: #fff;
    border: none;
    cursor: pointer;
    font-size: 1rem;
}

.btn-primary:hover {
    background: var(--text-main);
    color: #fff;
}

.btn-gold:hover {
    background: #b5952f;
    transform: scale(1.05);
}

/* PLACEHOLDER DEL ÁLBUM */
.placeholder-box {
    border: 2px dashed #ccc;
    padding: 3rem;
    border-radius: 10px;
    color: #888;
    margin-top: 1rem;
}

/* CLASES DE ANIMACIÓN (Aparecer al hacer scroll) */
.fade-in {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

/* =========================================
   LÍNEA DE TIEMPO (ITINERARIO) - PREMIUM
========================================= */
.timeline-section {
    padding: 4rem 1.5rem;
    max-width: 600px;
    margin: 0 auto;
}

.timeline-evento {
    position: relative;
    padding-left: 45px; /* Espacio para que respire la línea */
    margin-bottom: 30px;
    border-left: 2px solid var(--accent-gold); /* La línea principal */
}

/* El punto elegante sobre la línea */
.timeline-evento::before {
    content: '';
    position: absolute;
    left: -9px; /* Centrado exacto sobre la línea de 2px */
    top: 50%;
    transform: translateY(-50%); /* Centrado vertical con la tarjeta */
    width: 16px;
    height: 16px;
    background-color: var(--bg-light, #FAFAFA);
    border: 3px solid var(--accent-gold);
    border-radius: 50%;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
}

/* Tarjeta del evento con volumen y sombra */
.timeline-contenido {
    background-color: #FFFFFF;
    padding: 20px 25px;
    border-radius: 15px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05); /* Sombra muy sutil y elegante */
    display: flex;
    justify-content: space-between;
    align-items: center;
    border: 1px solid rgba(0, 0, 0, 0.03); /* Borde casi invisible para dar forma */
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

/* Animación al pasar el mouse */
.timeline-contenido:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.08);
}

.timeline-textos {
    text-align: left;
}

.timeline-hora {
    font-weight: 800;
    color: var(--accent-gold);
    font-size: 1.1rem;
    letter-spacing: 1px;
    margin-bottom: 5px;
}

/* Insignia circular de fondo para el ícono */
.timeline-icono-derecha {
    width: 55px;
    height: 55px;
    border-radius: 50%;
    background-color: rgba(0, 0, 0, 0.03); /* Un círculo gris/crema de fondo */
    display: flex;
    justify-content: center;
    align-items: center;
    flex-shrink: 0; /* Evita que el círculo se aplaste en celulares */
    margin-left: 15px;
}

/* Ajuste de tamaño del ícono */
.timeline-icono-derecha svg {
    width: 28px;
    height: 28px;
    stroke-width: 1.5;
}

/* =========================================
   MAPAS
========================================= */
.mapa-contenedor {
    margin: 15px 0;
    border-radius: 8px;
    overflow: hidden; /* Evita que el mapa sobresalga de los bordes curvos */
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

/* =========================================
   FORMULARIOS LIMPIOS
========================================= */
.formulario-limpio {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
    max-width: 400px;
    margin: 0 auto;
}

.input-estilizado {
    width: 100%;
    padding: 15px;
    border: 1px solid #ccc;
    border-radius: 30px; /* Bordes redondeados para un look moderno */
    font-family: var(--font-text);
    font-size: 1rem;
    text-align: center;
    transition: border-color 0.3s;
}

.input-estilizado:focus {
    outline: none;
    border-color: var(--accent-gold);
}

/* =========================================
   REPRODUCTOR DE MÚSICA FLOTANTE
========================================= */
.music-player {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background-color: var(--accent-gold);
    color: #fff;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
    cursor: pointer;
    z-index: 100;
    transition: transform 0.3s, background-color 0.3s;
}

.music-player:hover {
    transform: scale(1.1);
}

/* Animación cuando la música está sonando */
.music-player.playing {
    animation: pulsar 2s infinite;
}

@keyframes pulsar {
    0% { box-shadow: 0 0 0 0 rgba(212, 175, 55, 0.7); }
    70% { box-shadow: 0 0 0 15px rgba(212, 175, 55, 0); }
    100% { box-shadow: 0 0 0 0 rgba(212, 175, 55, 0); }
}

/* =========================================
   CÓDIGO DE VESTIMENTA
========================================= */
.colores-container {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-top: 15px;
}

.color-box {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 2px solid #ddd;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

/* =========================================
   MESA DE REGALOS / LLUVIA DE SOBRES
========================================= */
.regalos-section p {
    max-width: 600px;
    margin: 0 auto 2rem auto;
    font-size: 1.05rem;
}

/* Modificamos el card-container específicamente para regalos */
.regalos-container {
    display: flex;
    flex-direction: row; /* En pantallas grandes, una al lado de la otra */
    flex-wrap: wrap; /* Si no caben, se apilan hacia abajo */
    justify-content: center;
    gap: 20px;
    max-width: 800px;
}

.regalo-card {
    flex: 1 1 250px; /* Crecen pero no bajan de 250px de ancho */
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
}

.regalo-card h3 {
    color: var(--text-main);
    font-size: 1.2rem;
}

.regalo-card p {
    font-size: 0.9rem;
    margin-bottom: 1rem;
    color: #555;
    line-height: 1.5;
}

/* =========================================
   FORMULARIO DE RSVP
========================================= */
.rsvp-form {
    background: #fff;
    padding: 2rem;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
    width: 100%;
}

.select-estilizado {
    appearance: none; /* Quita la flecha por defecto fea de algunos navegadores */
    background-image: url('data:image/svg+xml;utf8,<svg fill="%23333" height="24" viewBox="0 0 24 24" width="24" xmlns="http://www.w3.org/2000/svg"><path d="M7 10l5 5 5-5z"/></svg>');
    background-repeat: no-repeat;
    background-position-x: 95%;
    background-position-y: center;
    cursor: pointer;
}

.textarea-estilizado {
    resize: vertical; /* Permite hacer más grande la caja solo hacia abajo */
    min-height: 80px;
    font-family: var(--font-text);
}

.btn-block {
    width: 100%;
    padding: 15px;
    font-size: 1.1rem;
    border-radius: 30px;
}

/* MENSAJE DE ÉXITO */
.mensaje-exito {
    background: #fff;
    padding: 3rem 2rem;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
    max-width: 400px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
}

.mensaje-exito.oculto {
    display: none;
}

.mensaje-exito h3 {
    color: var(--accent-gold);
    font-size: 1.5rem;
    margin: 0;
}

/* =========================================
   CONTADOR REGRESIVO
========================================= */
.countdown-section {
    text-align: center;
    padding: 3rem 1rem;
}

.countdown-container {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 15px;
    margin-top: 20px;
}

.time-box {
    background: rgba(212, 175, 55, 0.05); /* Fondo dorado casi transparente */
    border: 1px solid var(--accent-gold);
    border-radius: 10px;
    padding: 15px 10px;
    min-width: 75px;
    display: flex;
    flex-direction: column;
    align-items: center;
    box-shadow: 0 4px 10px rgba(0,0,0,0.05);
}

.time-box span {
    font-size: 2.2rem;
    font-weight: 600;
    color: var(--accent-gold);
}

.time-box p {
    margin: 5px 0 0 0;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--text-main);
}

/* =========================================
   PADRES Y PADRINOS
========================================= */
.familia-section {
    text-align: center;
    padding: 4rem 1rem;
    background-color: rgba(0, 0, 0, 0.03); /* Un gris muy sutil para hacer contraste */
    border-top: 1px solid rgba(0, 0, 0, 0.1); /* Línea separadora arriba */
    border-bottom: 1px solid rgba(0, 0, 0, 0.1); /* Línea separadora abajo */
    margin: 2rem 0;
}

.familia-bloque {
    margin-bottom: 2.5rem;
}

.familia-bloque:last-child {
    margin-bottom: 0;
}

.familia-titulo {
    font-size: 0.85rem;
    color: var(--text-main);
    text-transform: uppercase;
    letter-spacing: 3px;
    margin-bottom: 10px;
    opacity: 0.8;
}

.familia-nombres {
    font-size: 1.8rem;
    color: var(--accent-gold);
    font-weight: 400;
    line-height: 1.4;
    /* Si tienes una fuente cursiva o Serif en tu proyecto, aplícala aquí */
}

/* =========================================
   GALERÍA DE FOTOS Y MODAL
========================================= */
.galeria-section {
    padding: 3rem 1rem;
}

.galeria-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center; /* Centra las fotos si sobran espacios */
    gap: 20px;
    padding: 0 10px;
}

/* Configuración por defecto (PC y Tablets) */
.galeria-img {
    width: 100%;
    max-width: 280px;
    height: 350px;
    object-fit: cover;
    border-radius: 8px;
    cursor: pointer;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

/* =========================================
   ADAPTACIÓN PARA CELULARES (MÓVIL)
========================================= */
@media (max-width: 600px) {
    .galeria-img {
        /* Fuerza a que siempre quepan 2 fotos por fila repartiendo el espacio */
        width: calc(50% - 10px); 
        
        /* Reducimos la altura para que no se vean tan estiradas */
        height: 200px; 
    }
    
    .galeria-grid {
        gap: 10px; /* Juntamos un poquito más las fotos en móvil */
        padding: 0 5px;
    }
}

.galeria-img:hover {
    transform: scale(1.03);
    box-shadow: 0 5px 15px var(--accent-gold); /* La sombra ahora usa el color seleccionado */
}

/* Modal Background */
.modal-galeria {
    display: none; 
    position: fixed; 
    z-index: 9999; 
    left: 0; 
    top: 0; 
    width: 100%; 
    height: 100%; 
    background-color: rgba(0, 0, 0, 0.9);
    backdrop-filter: blur(5px);
}

.modal-contenido {
    margin: auto;
    display: block;
    max-width: 90%;
    max-height: 90vh;
    position: relative;
    top: 50%;
    transform: translateY(-50%);
    border-radius: 5px;
    box-shadow: 0 0 25px var(--accent-gold); /* Contorno brillante con el color de la quinceañera */
}

.cerrar-modal {
    position: absolute;
    top: 20px;
    right: 35px;
    color: #f1f1f1;
    font-size: 40px;
    font-weight: bold;
    cursor: pointer;
    transition: 0.3s;
    z-index: 10000;
}

.cerrar-modal:hover,
.cerrar-modal:focus {
    color: var(--accent-gold);
}

/* =========================================
   HASHTAG SOCIAL
========================================= */
.hashtag-section {
    text-align: center;
    padding: 4rem 1rem;
}

.hashtag-container {
    max-width: 500px;
    margin: 0 auto;
    padding: 2.5rem 1rem;
    border: 2px dashed;
    color: var(--accent-gold);
    border-radius: 15px;
    background-color: rgba(212, 175, 55, 0.02);
    transition: transform 0.3s ease;
}

.hashtag-container:hover {
    transform: translateY(-5px);
    border-color: var(--accent-gold);
}

.icono-social {
    margin-bottom: 15px;
}

.el-hashtag {
    font-size: 2.5rem;
    color: var(--accent-gold);
    margin-top: 15px;
    letter-spacing: 1px;
    word-break: break-word;
}