/* ==========================================================================
   INVITACIÓN DE BODA — Hoja de estilos
   --------------------------------------------------------------------------
   Índice:
     1. Variables (colores, fuentes, medidas)
     2. Base y reseteo
     3. Utilidades (contenedor, textos, botones, íconos)
     4. Encabezado y navegación
     5. Portada (hero)
     6. Introducción y cuenta regresiva
     7. Títulos de sección
     8. El gran día (eventos)
     9. Banda de foto
    10. Los detalles (dress code, regalos, preguntas)
    11. Confirmación de asistencia (RSVP)
    12. Pie de página
    13. Ventana de regalo (dialog)
    14. Animaciones
    15. Responsive (celulares)
    16. Accesibilidad: movimiento reducido
   ========================================================================== */


/* ==========================================================================
   1. VARIABLES
   Cambiá acá los colores y fuentes y se actualiza todo el sitio.
   ========================================================================== */

:root {
	/* Colores principales */
	--paper: #f7f8f5;        /* Fondo general (blanco hueso) */
	--ink: #262c28;          /* Texto principal */
	--muted: #626a63;        /* Texto secundario */
	--green: #344c40;        /* Verde de marca (botones, RSVP) */
	--line: #d8ded6;         /* Líneas divisorias */
	--rose: #f0e3e2;         /* Rosa suave */
	--rose-strong: #e8c7c1;  /* Subrayado de "Elegante" (dress code) */
	--white: #fff;

	/* Colores de apoyo */
	--green-dark: #243b2f;          /* Hover del botón verde */
	--paper-dark: #e4e9e1;          /* Hover del botón claro */
	--green-tint: #e8ede6;          /* Hover del botón con borde */
	--accent: #b37a68;              /* Contorno de foco (teclado) */
	--index-gray: #929b91;          /* Números 01 / 02 de los eventos */
	--rsvp-text: #dbe3da;           /* Texto suave sobre fondo verde */
	--rsvp-border: #809187;         /* Bordes de campos del formulario */
	--rsvp-radio: #d4e1c9;          /* Color de los botones de opción */

	/* Fuentes */
	--font-body: 'Playfair Display', Georgia, serif;
	--font-display: 'Playfair Display', Georgia, serif;
	--font-ui: 'DM Sans', system-ui, sans-serif;  /* Botones, navegación y pie */

	/* Medidas */
	--max-width: 1080px;     /* Ancho máximo del contenido */
	--header-height: 78px;
}


/* ==========================================================================
   2. BASE Y RESETEO
   ========================================================================== */

* {
	box-sizing: border-box;
	letter-spacing: 0;
}

html {
	scroll-behavior: smooth;
	scroll-padding-top: 24px;
}

body {
	margin: 0;
	background: var(--paper);
	color: var(--ink);
	font: 15px/1.65 var(--font-body);
}

h1, h2, h3, p {
	margin: 0;
}

/* Títulos y números usan la fuente decorativa */
h1, h2, h3,
.monogram,
.number {
	font-family: var(--font-display);
	font-weight: 400;
}

/* Los títulos van en cursiva */
h1, h2, h3 {
	font-style: italic;
}

h2 {
	font-size: 48px;
	line-height: 1.12;
}

h3 {
	font-size: 32px;
	line-height: 1.2;
}

a {
	color: inherit;
	text-underline-offset: 5px;
}

button, input, textarea {
	font: inherit;
}

button, a, input, textarea, summary {
	-webkit-tap-highlight-color: transparent;
}

button {
	cursor: pointer;
}

:focus-visible {
	outline: 3px solid var(--accent);
	outline-offset: 5px;
}

[hidden] {
	display: none !important;
}


/* ==========================================================================
   3. UTILIDADES
   ========================================================================== */

/* Contenedor centrado con ancho máximo */
.wrap {
	width: min(var(--max-width), calc(100% - 64px));
	margin-inline: auto;
}

/* Texto chiquito en mayúsculas sobre los títulos */
.eyebrow {
	font-size: 11px;
	font-weight: 600;
	text-transform: uppercase;
}

.muted {
	color: var(--muted);
}

/* --- Botones ------------------------------------------------------------ */

.button {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 10px;
	min-height: 40px;
	padding: 9px 20px;
	border: 1px solid var(--green);
	border-radius: 999px;
	font-family: var(--font-ui);
	font-size: 14px;
	background: var(--green);
	color: var(--white);
	text-decoration: none;
	font-weight: 500;
	transition: background .2s;
}

.button:hover {
	background: var(--green-dark);
}

/* Variante clara (sobre fotos o fondo verde) */
.button.light {
	background: var(--paper);
	border-color: var(--paper);
	color: var(--ink);
}

.button.light:hover {
	background: var(--paper-dark);
}

/* Variante con borde y fondo transparente */
.button.outline {
	background: transparent;
	color: var(--green);
}

.button.outline:hover {
	background: var(--green-tint);
}

/* Botón que parece link subrayado */
.text-button {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	border: 0;
	border-bottom: 1px solid var(--line);
	background: transparent;
	padding: 10px 0;
	color: inherit;
	font-size: 12px;
}

/* --- Íconos (Lucide) ---------------------------------------------------- */

.icon {
	width: 18px;
	height: 18px;
	flex-shrink: 0;
}


/* ==========================================================================
   4. ENCABEZADO Y NAVEGACIÓN
   ========================================================================== */

header {
	height: var(--header-height);
	background: var(--paper);
}

.nav {
	height: 100%;
	display: flex;
	justify-content: space-between;
	align-items: center;
	gap: 20px;
}

/* Iniciales "S / G" */
.monogram {
	font-size: 28px;
	text-decoration: none;
}

.nav-links {
	display: flex;
	align-items: center;
	gap: 30px;
	font-family: var(--font-ui);
	font-size: 12px;
	font-weight: 500;
	text-transform: uppercase;
	letter-spacing: .12em;
}

.nav-links a {
	text-decoration: none;
	padding-block: 10px;
}

/* Sin subrayado fijo: solo aparece al pasar el mouse */
.nav-links a {
	border-bottom: 1px solid transparent;
	transition: border-color .2s;
}

.nav-links a:hover {
	border-color: var(--accent);
}


/* ==========================================================================
   5. PORTADA (HERO)
   ========================================================================== */

.hero {
	position: relative;
	height: min(760px, calc(80svh - var(--header-height)));
	min-height: 430px;
	display: grid;
	place-items: center;
	text-align: center;
	color: var(--white);
	background: #566254; /* Color de respaldo mientras carga la foto */
	overflow: hidden;
}

.hero-photo {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	object-fit: cover;
	object-position: center 58%;
}

/* Capa oscura sobre la foto para que se lea el texto */
.hero::after {
	content: '';
	position: absolute;
	inset: 0;
	background: linear-gradient(180deg, rgba(18, 29, 21, .2), rgba(18, 29, 21, .5));
}

.hero-content {
	position: relative;
	z-index: 1;
	padding: 30px 20px;
	animation: arrive 1s ease-out both;
}

/* Nombres de los novios */
.hero h1 {
	font-size: 100px;
	line-height: 1.08;
	margin: 20px 0;
}

/* El "&" entre los nombres */
.hero h1 span {
	font-size: 65px;
	font-style: italic;
	color: var(--rose-strong);
}

/* Fecha en cursiva, más liviana que los nombres */
.hero-date {
	font: italic 24px/1.4 var(--font-display);
	color: rgba(255, 255, 255, .85);
}

/* Línea rosa entre la fecha y la ubicación */
.hero-divider {
	display: block;
	width: 56px;
	height: 1px;
	margin: 26px auto;
	background: var(--rose-strong);
}

/* "Nos casamos" y la ubicación comparten estilo */
.hero .eyebrow,
.hero-location {
	font-size: 15px;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: .16em;
}

.hero-location {
	font-size: 12px;
}


/* ==========================================================================
   6. INTRODUCCIÓN Y CUENTA REGRESIVA
   ========================================================================== */

.intro {
	text-align: center;
	padding: 74px 0 62px;
}

.intro h2 {
	margin: 16px 0 20px;
}

.intro p {
	font-size: 18px;
}

/* Cuatro columnas: días, horas, minutos, segundos */
.countdown {
	display: grid;
	grid-template-columns: repeat(4, 1fr);
	margin: 48px 0 44px;
}

/* Línea separadora entre cada columna */
.countdown > div + div {
	border-left: 1px solid var(--line);
}

.number {
	display: block;
	font-size: 48px;
	line-height: 1.2;
	font-variant-numeric: tabular-nums;
}

.countdown small {
	font-size: 14px;
	color: var(--muted);
}


/* ==========================================================================
   7. TÍTULOS DE SECCIÓN
   ========================================================================== */

.section-heading {
	padding-bottom: 32px;
}

.section-heading .eyebrow {
	margin-bottom: 14px;
	font-size: 14px;
}

/* Bajada debajo del título */
.section-lead {
	margin-top: 16px;
	font-size: 18px;
}

/* Título de bloque con el tamaño de los títulos de sección */
.section-title {
	font-size: 48px;
	line-height: 1.12;
}


/* ==========================================================================
   8. EL GRAN DÍA (CEREMONIA Y CELEBRACIÓN)
   ========================================================================== */

.day {
	padding: 48px 0 76px;
	border-top: 1px solid var(--line);
}

.events {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 56px;
}

.event {
	border-top: 1px solid var(--line);
	padding-top: 28px;
}

.event-top {
	display: flex;
	align-items: baseline;
	gap: 14px;
	margin-bottom: 24px;
}

/* Números "01" y "02" */
.event-index {
	color: var(--accent);
	font-family: var(--font-display);
	font-size: 26px;
}

.event-top .eyebrow {
	color: var(--green);
	font-size: 13px;
}

.event h3 {
	margin-bottom: 14px;
}

.event p {
	font-size: 16px;
}

/* Nombre del lugar, igual que los títulos de la línea de tiempo */
.event .event-place {
	margin-bottom: 6px;
	font-size: 17px;
	font-weight: 500;
}

.event .time {
	margin-bottom: 14px;
	font-weight: 600;
}

.event a {
	margin-top: 22px;
}

/* --- Línea de tiempo de la noche (hora a la izquierda, detalle a la derecha) */

.timeline {
	list-style: none;
	margin: 0;
	padding: 0;
}

.timeline li {
	display: grid;
	grid-template-columns: 96px 1fr;
	gap: 16px;
	padding: 14px 0;
}

/* Línea separadora entre cada momento */
.timeline li + li {
	border-top: 1px solid var(--line);
}

.timeline-time {
	font-size: 15px;
	font-weight: 600;
}

.timeline-title {
	margin-bottom: 6px;
	font-size: 17px;
	font-weight: 500;
}


/* ==========================================================================
   9. BANDA DE FOTO (frase sobre imagen)
   ========================================================================== */

.photo-band {
	position: relative;
	height: 340px;
	background: #718075; /* Color de respaldo mientras carga la foto */
	overflow: hidden;
}

.photo-band img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	object-position: center 55%;
}

/* Capa oscura sobre la foto */
.photo-band::after {
	content: '';
	position: absolute;
	inset: 0;
	background: rgba(15, 25, 17, .3);
}

/* Frase centrada */
.photo-band p {
	position: absolute;
	z-index: 1;
	inset: 0;
	display: grid;
	place-content: center;
	text-align: center;
	padding: 24px;
	color: var(--white);
	font: 44px/1.2 var(--font-display);
}


/* ==========================================================================
   10. LOS DETALLES
   ========================================================================== */

.details-section {
	padding: 76px 0;
}

/* Dress code y Regalos, en dos columnas */
.detail-grid {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 56px;
}

.detail-grid article {
	padding-top: 28px;
	border-top: 1px solid var(--line);
}

.detail-grid h3 {
	margin: 12px 0 18px;
}

.detail-grid .eyebrow {
	font-size: 14px;
}

.detail-grid p:not(.eyebrow) {
	font-size: 16px;
}

.detail-grid p:not(.eyebrow) + p {
	margin-top: 14px;
}

.detail-grid .button {
	margin-top: 25px;
}

/* "Dress code" con la etiqueta "Elegante" al lado */
.detail-label {
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	gap: 14px;
}

/* "Elegante", subrayado con color */
.dress-tag {
	padding: 0 4px;
	font: italic 19px/1.2 var(--font-display);
	background: linear-gradient(transparent 58%, var(--rose-strong) 58%);
}

/* --- Antes de venir (preguntas desplegables) ---------------------------- */

.travel {
	margin-top: 80px;
}

details {
	border-bottom: 1px solid var(--line);
}

details:first-child {
	border-top: 1px solid var(--line);
}

summary {
	list-style: none;
	cursor: pointer;
	padding: 20px 0;
	display: flex;
	justify-content: space-between;
	align-items: center;
	gap: 20px;
	font-size: 17px;
}

/* Oculta la flechita por defecto de Safari */
summary::-webkit-details-marker {
	display: none;
}

/* Signo "+" cuando está cerrado, "-" cuando está abierto */
summary::after {
	content: '+';
	font-size: 22px;
	font-weight: 400;
}

details[open] summary::after {
	content: '-';
}

details p {
	padding: 0 28px 22px 0;
	color: var(--muted);
	font-size: 15px;
}


/* ==========================================================================
   11. CONFIRMACIÓN DE ASISTENCIA (RSVP)
   ========================================================================== */

.rsvp {
	background: var(--green);
	color: var(--white);
	padding: 76px 0;
}

.rsvp-grid {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 80px;
}

.rsvp h2 {
	margin: 18px 0 24px;
	font-size: 56px;
}

.rsvp-copy .eyebrow {
	font-size: 14px;
}

.rsvp-copy > p:not(.eyebrow) {
	color: var(--rsvp-text);
	font-size: 17px;
}

/* Fecha límite, en rosa */
.rsvp-copy > p.deadline {
	margin-top: 30px;
	color: var(--rose-strong);
	font-size: 15px;
	font-weight: 600;
}

/* --- Formulario --------------------------------------------------------- */

.form-field {
	display: grid;
	gap: 8px;
	margin-bottom: 20px;
}

label, legend {
	font-size: 14px;
}

input:not([type=radio]),
textarea {
	width: 100%;
	min-width: 0;
	min-height: 40px;
	padding: 8px 18px;
	color: var(--white);
	background: transparent;
	border: 1px solid var(--rsvp-border);
	border-radius: 10px;
}

/* Borde rosa en el campo activo */
input:not([type=radio]):focus,
textarea:focus {
	border-color: var(--rose-strong);
}

textarea {
	resize: vertical;
	min-height: 86px;
	padding-block: 12px;
}

fieldset {
	padding: 0;
	border: 0;
	margin: 0 0 20px;
}

legend {
	margin-bottom: 12px;
}

.radio-options {
	display: flex;
	flex-wrap: wrap;
	gap: 14px 24px;
}

.radio-options label {
	display: flex;
	align-items: center;
	gap: 8px;
	min-height: 36px;
	cursor: pointer;
}

/* Botón de opción propio: círculo con borde, punto rosa al elegirlo */
input[type=radio] {
	appearance: none;
	display: grid;
	place-items: center;
	width: 22px;
	height: 22px;
	margin: 0;
	border: 2px solid var(--rsvp-text);
	border-radius: 50%;
	background: transparent;
	cursor: pointer;
	transition: border-color .2s, background .2s;
}

input[type=radio]::after {
	content: '';
	width: 10px;
	height: 10px;
	border-radius: 50%;
	background: var(--rose-strong);
	transform: scale(0);
	transition: transform .2s;
}

/* Hover: rosa más apagado */
.radio-options label:hover input[type=radio] {
	border-color: rgba(232, 199, 193, .6);
	background: rgba(232, 199, 193, .12);
}

/* Elegido: borde, punto y texto en rosa */
input[type=radio]:checked {
	border-color: var(--rose-strong);
}

input[type=radio]:checked::after {
	transform: scale(1);
}

.radio-options label:has(input:checked) {
	color: var(--rose-strong);
}

.demo-note {
	color: var(--rsvp-text);
	font-size: 12px;
	margin-top: 16px;
}

/* --- Mensaje de confirmación -------------------------------------------- */

.confirmation {
	padding: 18px 0;
}

.confirmation h3 {
	margin-bottom: 18px;
}

.confirmation p {
	margin-bottom: 20px;
}


/* ==========================================================================
   12. PIE DE PÁGINA
   ========================================================================== */

footer {
	padding: 36px 0;
	text-align: center;
}

footer .monogram {
	font-size: 32px;
}

footer p {
	font-family: var(--font-ui);
	font-size: 13px;
	color: var(--muted);
	margin-top: 8px;
}


/* ==========================================================================
   13. VENTANA DE REGALO (DIALOG)
   ========================================================================== */

dialog {
	width: min(620px, calc(100% - 32px));
	max-height: calc(100svh - 32px);
	padding: 40px;
	border: 1px solid var(--line);
	border-radius: 16px;
	background: var(--paper);
	color: var(--ink);
}

/* Fondo oscuro detrás de la ventana */
dialog::backdrop {
	background: rgba(20, 30, 23, .6);
}

.dialog-heading {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
	margin-bottom: 20px;
}

/* Botón "×" para cerrar */
.close-button {
	border: 0;
	background: transparent;
	padding: 10px;
	min-width: 44px;
	min-height: 44px;
	margin: -10px -10px -10px 0; /* No suma alto extra arriba */
	font-size: 24px;
	color: var(--ink);
}

dialog p {
	margin-bottom: 24px;
	font-size: 16px;
}

/* --- Cuentas para regalo (desplegables) -------------------------------- */

/* Las cuentas usan los mismos estilos de <details> de "Antes de venir".
   Esto corrige la línea superior, porque acá el primer bloque no es
   el primer elemento de la ventana. */
.accounts details:first-child {
	border-top: 1px solid var(--line);
}

/* Moneda y país al lado del nombre de la cuenta */
.accounts summary {
	font-weight: 500;
}

/* País y moneda en rosa */
.accounts summary small {
	margin-left: 8px;
	color: var(--accent);
	font: 400 12px var(--font-ui);
	letter-spacing: .04em;
}

/* Panel con los datos de la cuenta abierta (se arma en script) */
.account-panel {
	display: grid;
	margin: 0 0 20px;
	padding: 16px 20px 20px;
	border: 1px solid var(--line);
	border-radius: 12px;
	background: var(--white);
}

/* Botón "Copiar todo", arriba a la derecha del panel */
.copy-all {
	justify-self: end;
	display: inline-flex;
	align-items: center;
	gap: 8px;
	margin-bottom: 8px;
	padding: 7px 14px;
	border: 0;
	border-radius: 999px;
	background: var(--green-tint);
	color: var(--green);
	font: 600 13px var(--font-ui);
	transition: background .2s;
}

.copy-all:hover {
	background: var(--paper-dark);
}

.copy-all .icon {
	width: 16px;
	height: 16px;
}

.account-fields {
	display: grid;
	gap: 14px;
	margin: 0;
}

.account-field dt {
	margin-bottom: 2px;
	font: 600 11px var(--font-ui);
	letter-spacing: .08em;
	text-transform: uppercase;
	color: var(--muted);
}

/* Valor a la izquierda, botón de copiar a la derecha */
.account-field dd {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	margin: 0;
}

.account-field code {
	font: 500 15px var(--font-ui);
	font-variant-numeric: tabular-nums;
	color: var(--ink);
	overflow-wrap: anywhere;
}

.copy-button {
	display: grid;
	place-items: center;
	flex-shrink: 0;
	width: 38px;
	height: 38px;
	padding: 0;
	border: 0;
	border-radius: 50%;
	background: transparent;
	color: var(--green);
	transition: background .2s;
}

.copy-button:hover {
	background: var(--green-tint);
}

/* Aclaración debajo de una cuenta (ej: "solo desde otra cuenta en dólares") */
dialog .account-note {
	margin: 16px 0 0;
	padding: 0;
	font-size: 13px;
	color: var(--muted);
}

/* Solo ocupa lugar cuando hay un mensaje */
#copy-status:empty {
	display: none;
}

#copy-status {
	margin: 16px 0 0;
	color: var(--green);
	font: 500 14px var(--font-ui);
}


/* ==========================================================================
   14. ANIMACIONES
   ========================================================================== */

/* Entrada suave del texto de la portada */
@keyframes arrive {
	from {
		opacity: 0;
		transform: translateY(14px);
	}
	to {
		opacity: 1;
		transform: translateY(0);
	}
}


/* ==========================================================================
   15. RESPONSIVE
   ========================================================================== */

/* --- Celulares y tablets chicas (hasta 700px) --------------------------- */
@media (max-width: 700px) {
	:root {
		--header-height: 68px;
	}

	.wrap {
		width: calc(100% - 40px);
	}

	/* Navegación */
	.nav-links {
		gap: 18px;
		font-size: 11px;
	}

	.nav-links .extra-link {
		display: none; /* Se oculta "Los detalles" para que entre todo */
	}

	.monogram {
		font-size: 24px;
	}

	/* Portada */
	.hero {
		height: calc(80svh - var(--header-height));
		min-height: 360px;
	}

	.hero h1 {
		font-size: 64px;
		max-width: 350px;
	}

	.hero h1 span {
		font-size: 44px;
	}

	.hero-date {
		font-size: 20px;
	}

	.hero .eyebrow,
	.hero-location {
		font-size: 13px;
	}

	.hero-location {
		font-size: 11px;
	}

	/* Títulos */
	h2 {
		font-size: 38px;
	}

	h3 {
		font-size: 30px;
	}

	/* Introducción y cuenta regresiva */
	.intro {
		padding: 50px 0;
	}

	.intro p {
		font-size: 16px;
	}

	.number {
		font-size: 38px;
	}

	.countdown {
		margin-top: 30px;
	}

	/* Títulos de sección: el texto chico pasa abajo */
	.section-title {
		font-size: 38px;
	}

	.section-lead {
		font-size: 16px;
	}

	/* Todas las grillas pasan a una sola columna */
	.events,
	.detail-grid,
	.travel,
	.rsvp-grid {
		grid-template-columns: 1fr;
		gap: 36px;
	}

	.day,
	.details-section,
	.rsvp {
		padding-block: 50px;
	}

	/* Banda de foto */
	.photo-band {
		height: 260px;
	}

	.photo-band p {
		font-size: 34px;
		font-style: italic;
	}

	/* Antes de venir */
	.travel {
		margin-top: 44px;
		gap: 20px;
	}

	/* RSVP */
	.rsvp h2 {
		font-size: 44px;
	}

	/* Ventana de regalo */
	dialog {
		padding: 24px;
	}

	.account-panel {
		padding: 14px 16px 16px;
	}
}

/* --- Celulares muy chicos (hasta 360px) --------------------------------- */
@media (max-width: 360px) {
	.wrap {
		width: calc(100% - 32px);
	}

	.nav-links {
		gap: 12px;
	}

	.hero h1 {
		font-size: 54px;
	}
}


/* ==========================================================================
   16. ACCESIBILIDAD: MOVIMIENTO REDUCIDO
   Si la persona tiene activado "reducir movimiento" en su dispositivo,
   se desactivan animaciones y transiciones.
   ========================================================================== */

@media (prefers-reduced-motion: reduce) {
	html {
		scroll-behavior: auto;
	}

	*,
	*::before,
	*::after {
		animation: none !important;
		transition: none !important;
	}
}

