/* -------------- Fuentes -------------- */
@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:wght@400;700&family=Poppins:wght@300;400;600;700&display=swap');

/* ---- VARIABLES DE COLOR Y TIPOGRAFÍA ---- */
:root{
  --primary: #C47C6D;      /* acento cálido */
  --accent: #3E6B58;       /* verde profundo */
  --muted: #F7F4F2;        /* fondo suave */
  --card-bg: rgba(255,255,255,0.78);
  --glass-bg: rgba(255,255,255,0.12);
  --text: #3F2F2B;
  --subtle: rgba(63,47,43,0.06);
  --shadow: 0 8px 30px rgba(46,46,46,0.08);
  --radius-lg: 18px;
  --radius-md: 12px;
  --transition: 280ms cubic-bezier(.2,.9,.3,1);
  --heading-font: 'Playfair Display', serif;
  --body-font: 'Poppins', sans-serif;
}

/* ---- RESET Y BASE ---- */
*{box-sizing:border-box}
html,body{height:100%}
body{
  margin:0;
  font-family:var(--body-font);
  /* fondo unificado: naranja sutil y elegante */
  background: #FFF3E0; /* color suave naranja (puedes cambiar a #FFE8D6 o #FFF2E6) */
  color:var(--text);
  -webkit-font-smoothing:antialiased;
  -moz-osx-font-smoothing:grayscale;
  line-height:1.48;
  padding-bottom:4rem;
}

/* ---- NAVEGACIÓN Y CABECERA ---- */
header{
  background: transparent;
  padding:1.25rem 2rem;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:1rem;
  position:relative;
  z-index:40;
}
.logo{
  display:flex;
  align-items:center;
  gap:.75rem;
  font-family:var(--heading-font);
  color:var(--accent);
  font-size:1.25rem;
  font-weight:700;
  letter-spacing:0.6px;
}
.logo .mark{
  width:48px;height:48px;border-radius:12px;
  background:linear-gradient(135deg,var(--primary),#eaa79f);
  display:grid;place-items:center;color:white;font-weight:700;
  box-shadow: var(--shadow);
}

/* simple nav links */
.nav{
  display:flex;
  gap:.75rem;
  align-items:center;
}
.nav a{
  color:rgba(63,47,43,0.8);
  text-decoration:none;
  padding:.5rem .75rem;
  border-radius:8px;
  font-weight:600;
  transition:background var(--transition), transform var(--transition);
}
.nav a:hover{ background: rgba(62,107,88,0.06); transform:translateY(-2px) }

/* ---- HERO / INVITACIÓN PRINCIPAL ---- */
.hero{
  max-width:1100px;
  margin:2.25rem auto;
  padding:2rem;
  display:grid;
  grid-template-columns: 1fr 420px;
  gap:2rem;
  align-items:center;
}
@media (max-width:920px){
  .hero{ grid-template-columns: 1fr; padding:1.25rem; gap:1rem }
}

/* texto hero */
.hero .intro{
  padding:1.25rem 1.75rem;
  background: linear-gradient(180deg, rgba(255,255,255,0.86), rgba(255,255,255,0.78));
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  border: 1px solid var(--subtle);
}
.hero h1{
  font-family:var(--heading-font);
  color:var(--accent);
  font-size:2.6rem;
  margin:0 0 .5rem 0;
  letter-spacing:0.4px;
}
.hero p.lead{
  margin:0 0 1rem 0;
  color:rgba(63,47,43,0.82);
  font-size:1.05rem;
}

/* botones */
.cta-row{ display:flex; gap:1rem; margin-top:1rem; align-items:center }
.btn{
  padding:.75rem 1.25rem;
  border-radius:12px;
  font-weight:600;
  border:none;
  cursor:pointer;
  transition: all var(--transition);
  box-shadow: 0 6px 18px rgba(0,0,0,0.06);
}
.btn-primary{
  background: linear-gradient(90deg,var(--primary), #eaa79f);
  color:white;
}
.btn-primary:hover{ transform:translateY(-4px); box-shadow: 0 14px 32px rgba(196,124,109,0.16) }
.btn-ghost{
  background:transparent;
  border: 1px solid rgba(63,47,43,0.08);
  color:var(--text);
}

/* tarjeta de invitación lateral (glass) */
.hero .hero-card{
  background: linear-gradient(135deg, rgba(255,255,255,0.7), rgba(255,255,255,0.55));
  border-radius: var(--radius-lg);
  padding:1.5rem;
  border: 1px solid rgba(63,47,43,0.05);
  box-shadow: 0 10px 30px rgba(46,46,46,0.06);
  position:relative;
  overflow:hidden;
}
.hero .hero-card::before{
  content:"";
  position:absolute; inset:0;
  background: radial-gradient(circle at 10% 15%, rgba(62,107,88,0.03), transparent 2%),
              radial-gradient(circle at 80% 85%, rgba(196,124,109,0.03), transparent 2%);
  pointer-events:none;
}
.invitation-title{
  font-family:var(--heading-font);
  color:var(--accent);
  font-size:1.35rem;
  margin:0 0 .25rem 0;
}
.invitation-sub{
  color:rgba(63,47,43,0.75);
  font-size:.98rem;
  margin-bottom:1rem;
}
.invitation-details{
  display:flex;
  gap:.6rem;
  flex-direction:column;
}
.detail-item{
  display:flex;
  gap:.75rem;
  align-items:center;
  padding:.5rem;
  border-radius:10px;
  background: linear-gradient(180deg, rgba(255,255,255,0.9), rgba(255,255,255,0.82));
  border: 1px solid rgba(63,47,43,0.03);
}

/* ---- GLASS CARDS / COMPONENTES ---- */
.glass{
  background: var(--card-bg);
  border-radius: var(--radius-md);
  padding:1rem;
  border:1px solid rgba(255,255,255,0.6);
  box-shadow: var(--shadow);
}

/* ---- CONTADOR ---- */
.countdown{
  margin-top:1rem;
  display:flex;
  gap:1rem;
  align-items:center;
  flex-wrap:wrap;
}
.timer-box{
  min-width:88px;
  background:linear-gradient(180deg, rgba(255,255,255,0.96), rgba(255,255,255,0.85));
  border-radius:12px;
  padding: .85rem .6rem;
  text-align:center;
  box-shadow: 0 8px 20px rgba(46,46,46,0.06);
  border:1px solid rgba(63,47,43,0.03);
  transition: transform var(--transition);
}
.timer-number{
  font-family:var(--heading-font);
  font-size:2.25rem;
  color:var(--primary);
  margin:0;
}
.timer-label{
  font-size:.78rem;
  color:rgba(63,47,43,0.65);
  margin-top:.25rem;
}
.timer-box:hover{ transform: translateY(-6px) }

/* ---- GALERÍA ---- */
.gallery{
  display:grid;
  grid-template-columns: repeat(auto-fit,minmax(180px,1fr));
  gap:1rem;
  margin-top:1.25rem;
}
.gallery .photo{
  position:relative;
  overflow:hidden;
  border-radius:12px;
  height:160px;
  background-size:cover;
  background-position:center;
  transition: transform var(--transition), box-shadow var(--transition);
  border:1px solid rgba(0,0,0,0.03);
}
.gallery .photo::after{
  content:"";
  position:absolute; inset:0;
  background:linear-gradient(180deg, rgba(0,0,0,0) 40%, rgba(0,0,0,0.25));
  opacity:0;
  transition:opacity var(--transition);
}
.gallery .photo:hover{ transform:scale(1.04); box-shadow: 0 18px 40px rgba(0,0,0,0.08) }
.gallery .photo:hover::after{ opacity:1 }

/* ---- MAP / EMBED ---- */
.map-container{
  border-radius:12px;
  overflow:hidden;
  border:1px solid rgba(63,47,43,0.04);
  box-shadow: 0 10px 30px rgba(46,46,46,0.05);
}

/* ---- FORMAS, MODAL, Y LISTAS ---- */
.modal-content{ border-radius:12px; padding:1rem; }
.list-group-item{ border:none; padding:.75rem 1rem; border-radius:10px; background:linear-gradient(180deg, #fff, #fff); }
.card{ border-radius:12px; overflow:hidden; transition:transform var(--transition); }
.card:hover{ transform:translateY(-6px); box-shadow:0 18px 40px rgba(0,0,0,0.06) }

/* Centrar texto y botones dentro de cards (puntos de recogida) */
.card .card-body {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}

/* Asegura que los botones queden centrados */
.card .btn {
  margin: 0.5rem auto 0;
}

/* También centrar botones y texto en panels personalizados (.place-panel) */
.place-panel {
  text-align: center;
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
  align-items: center;
}
.place-panel .btn {
  margin-top: 0.5rem;
}

/* ---- BOTONES RSVP MÁS SUTILES ---- */
.rsvp-btn{
  display:inline-flex;
  gap:.6rem;
  align-items:center;
  padding:.7rem 1rem;
  border-radius:10px;
  border:none;
  background: linear-gradient(90deg, var(--primary), #eaa79f);
  color:#fff;
  font-weight:700;
  box-shadow: 0 12px 30px rgba(196,124,109,0.12);
  transition: transform var(--transition), box-shadow var(--transition);
}
.rsvp-btn:hover{ transform:translateY(-6px); box-shadow: 0 20px 46px rgba(196,124,109,0.18) }

/* ---- FOOTER ---- */
footer{
  margin-top: 2.5rem;
  background: var(--primary); /* ahora usa --primary */
  color: #fff;
  padding: 1.5rem 2rem;
  border-radius: 0; /* esquinas rectas */
  width: 100%; /* ocupa todo el ancho */
  box-shadow: none; /* estilo más plano */
  font-family: var(--heading-font);
}

/* --- HERO FULLSCREEN: fija, visible al cargar y se oculta al abrir --- */
.hero-fullscreen {
  position: fixed;
  inset: 0;
  z-index: 9999 !important;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  width: 100%;
  padding: 0;
  transition: transform 0.65s cubic-bezier(.2,.9,.3,1), opacity 0.45s ease;
  will-change: transform, opacity;
  background: linear-gradient(180deg, rgba(255,243,230,1), rgba(255,245,235,1));
}

/* estado oculto: se desplaza hacia arriba y deja pasar contenido */
.hero-fullscreen.hero-hidden {
  transform: translateY(-110%);
  opacity: 0;
  pointer-events: none;
}

/* Asegura que el contenido posterior no quede cubierto al hacer scroll */
#countdown { scroll-margin-top: 96px; }

/* Ajustes visuales fuertes para que se vea en primer plano */
html, body { height: 100%; }
.hero-inner { transform: translateY(-2%); padding: 2.5rem 1.25rem; max-width: 980px; text-align: center; }

/* Hero: tamaños más grandes y logo nuevo */
.heart-logo {
  width: 96px;
  height: 96px;
  margin: 0 auto 0.6rem;
  display: grid;
  place-items: center;
  background: transparent; /* sin fondo para mostrar el SVG relleno */
  border-radius: 999px;
  box-shadow: 0 12px 36px rgba(0,0,0,0.06);
}
.heart-logo svg { width: 84%; height: 84%; display: block; }

/* Texto más grande e impacto visual */
.hero-subtitle {
  font-size: 1.05rem;
  letter-spacing: 2.5px;
  font-weight: 700;
}
.hero-names {
  font-size: clamp(4rem, 12vw, 8rem); /* mucho más grande en desktop */
  line-height: 0.95;
  margin: 0.25rem 0;
}
.hero-names .name { display:block; letter-spacing: -0.5px; }
.hero-names .ampersand {
  font-size: clamp(1.8rem, 5vw, 3rem);
  color: var(--primary);
  margin: 0.35rem 0;
  font-weight: 800;
}

/* Fecha un poco mayor */
.hero-date {
  margin-top: 0.6rem;
  font-size: 1.15rem;
  color: rgba(15,23,32,0.75);
}

/* pequeño ajuste responsive */
@media (max-width: 720px) {
  .heart-logo { width: 72px; height: 72px; }
  .hero-names { font-size: clamp(2.4rem, 12vw, 4rem); }
  .hero-names .ampersand { font-size: 1.4rem; }
  .hero-subtitle { font-size: 0.95rem; }
  .hero-date { font-size: 1rem; }
}

/* ------------------ Nuestra historia (sin estilo "card") ------------------ */
.narrative-section {
  padding: 0 rem 0; /* menos espacio para acercar la sección al contador */
  color: var(--text);
}
.section-header h2 {
  font-family: var(--heading-font);
  font-size: clamp(1.6rem, 3.6vw, 2.6rem);
  margin: 0 0 .5rem;
  color: #0f1720;
  letter-spacing: 0.2px;
}
.section-underline{
  display: inline-block;
  width: 72px;
  height: 4px;
  background: linear-gradient(90deg, var(--primary), #eaa79f);
  border-radius: 6px;
  margin-top: .5rem;
}

/* grid contenedor de las dos historias */
.story-grid {
  display: grid;
  gap: 2.25rem;
  max-width: 1100px;
  margin: 0 auto;
}

/* Recuadro para la sección de historia: fondo, borde y sombra */
.narrative-section .story-grid {
  background: var(--card-bg);
  padding: 1.25rem;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  border: 1px solid rgba(0,0,0,0.04);
  margin-top: 0 rem; /* un poco más cerca del countdown */
}

/* cada item: imagen + texto, sin fondo tipo "card" */
.story-item {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 1.5rem;
  align-items: center;
  align-content: center;
  padding: 0.6rem 0;
}

/* invertir columnas para el segundo item */
.story-item.story-right { grid-template-columns: 1fr 220px; }

/* figura / imagen */
.story-figure {
  margin: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}
.story-image {
  width: 100%;
  max-width: 220px;
  height: 160px;
  object-fit: cover;
  border-radius: 14px;
  box-shadow: 0 10px 28px rgba(0,0,0,0.06);
  display: block;
}

/* texto */
.story-text h3 {
  margin: 0 0 0.5rem 0;
  font-family: var(--heading-font);
  font-size: 1.15rem;
  color: var(--accent);
}
.story-text .lead {
  margin: 0 0 0.5rem;
  color: rgba(63,47,43,0.8);
  line-height: 1.6;
}
.story-text .muted {
  margin: 0;
  color: rgba(63,47,43,0.55);
  font-size: 0.95rem;
}

/* responsive: en móviles apilar (imagen arriba, texto abajo) */
@media (max-width: 860px) {
  .story-item, .story-item.story-right {
    grid-template-columns: 1fr;
    text-align: center;
  }
  .story-image {
    max-width: 100%;
    width: 100%;
    height: 220px;
  }
  .story-text { padding: 0.5rem 1rem; }
  .story-text h3 { text-align: center; }
}

/* ---- ACCESIBILIDAD Y DETALLES ---- */
a:focus, button:focus { outline: 3px solid rgba(62,107,88,0.14); outline-offset:2px; border-radius:8px; }

/* ---- ANIMACIONES SUTILES ---- */
@keyframes floatIn {
  from { opacity:0; transform: translateY(12px) scale(.995) }
  to   { opacity:1; transform: translateY(0) scale(1) }
}
.hero .intro, .hero .hero-card, .gallery .photo {
  animation: floatIn .6s var(--transition) both;
}

/* ---- PEQUEÑOS AJUSTES RESPONSIVE ---- */
@media (max-width:600px){
  .hero h1{ font-size:1.85rem }
  .timer-number{ font-size:1.6rem }
  header{ padding: .75rem 1rem }
  .logo .mark{ width:40px;height:40px }
}

/* Mapas: que ocupen todo el ancho del panel y no queden centrados */
.place-map {
  width: 100%;
  align-self: stretch; /* si el padre es flex column, obliga a estirarse */
}

/* Asegura que el iframe llene su contenedor */
.place-map iframe {
  display: block;
  width: 100%;
  height: 220px; /* mantiene la altura prevista */
  border: 0;
}

/* Botón pequeño y transparente para scroll-down (solo icono visible) */
.scroll-down{
  background: transparent;
  border: none;
  padding: 0;
  width: 44px;
  height: 44px;
  display: inline-grid;
  place-items: center;
  border-radius: 50%;
  box-shadow: none;
  cursor: pointer;
  opacity: 0.9;
  transition: transform var(--transition), opacity var(--transition);
}
.scroll-down img{
  width: 22px;
  height: auto;
  display: block;
}
.scroll-down:hover{ transform: translateY(-4px); opacity: 1; }
.scroll-down:focus{ outline: 3px solid rgba(62,107,88,0.14); outline-offset: 2px; border-radius:50%; }

/* Botón flotante de música */
.music-toggle {
  position: fixed;
  right: 1rem;
  top: 1rem;
  width: 48px;
  height: 48px;
  border-radius: 999px;
  display: inline-grid;
  place-items: center;
  background: linear-gradient(90deg, var(--primary), #eaa79f);
  color: #fff;
  border: none;
  box-shadow: 0 10px 28px rgba(0,0,0,0.12);
  z-index: 11000;
  cursor: pointer;
}
.music-toggle svg { display:block; }
.music-toggle.playing { background: linear-gradient(90deg, #6bbf9a, #3e6b58); }
.music-toggle:focus { outline: 3px solid rgba(62,107,88,0.18); outline-offset: 2px }

/* estado silenciado: visual distinta */
.music-toggle.muted { background: linear-gradient(90deg, #cfcfcf, #a9a9a9); color: #222; filter: grayscale(0.15); }