/* ==========================================================================
   Nuestro rincón — hoja de estilos
   Paleta: papel envejecido + corcho + vino + oro viejo + salvia
   Tipos: Playfair Display (títulos), Caveat (manuscrito), Nunito (cuerpo)
   ========================================================================== */

:root {
  /* --- color --- */
  --paper: #f2ead8;
  --paper-soft: #f8f3e6;
  --paper-dark: #e6d9bc;
  --cork: #c8a165;
  --cork-dark: #a9814c;
  --ink: #3a2e27;
  --ink-soft: #6b5c4f;
  --wine: #7c2d3b;
  --wine-dark: #5e2029;
  --rose: #c97e8b;
  --gold: #b8892b;
  --sage: #6e7f5c;
  --cream-line: rgba(58, 46, 39, 0.14);
  --shadow-soft: 0 10px 24px rgba(58, 34, 24, 0.16);
  --shadow-lift: 0 18px 34px rgba(58, 34, 24, 0.22);

  /* --- tipografía --- */
  --font-display: 'Playfair Display', Georgia, 'Times New Roman', serif;
  --font-hand: 'Caveat', 'Segoe Script', cursive;
  --font-body: 'Nunito', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;

  --radius-m: 14px;
  --radius-l: 22px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--paper);
  min-height: 100vh;
  padding-bottom: 40px;
  -webkit-font-smoothing: antialiased;
}

body.no-scroll { overflow: hidden; }

h1, h2, h3 { font-family: var(--font-display); font-weight: 600; margin: 0 0 6px; color: var(--wine-dark); }
p { margin: 0 0 10px; line-height: 1.55; }
a { color: inherit; }
.muted { color: var(--ink-soft); font-size: 0.92rem; }

img { max-width: 100%; display: block; }

button { font-family: inherit; cursor: pointer; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

:focus-visible {
  outline: 3px solid var(--gold);
  outline-offset: 2px;
}

/* --- textura de papel de fondo --- */
.paper-texture {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background-image:
    radial-gradient(circle at 15% 20%, rgba(184, 137, 43, 0.08), transparent 40%),
    radial-gradient(circle at 85% 75%, rgba(124, 45, 59, 0.07), transparent 45%),
    repeating-linear-gradient(0deg, rgba(58,46,39,0.015) 0 2px, transparent 2px 4px);
  background-color: var(--paper);
}

/* ==========================================================================
   Encabezado + navegación
   ========================================================================== */

.topbar {
  position: sticky;
  top: 0;
  z-index: 40;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 16px;
  background: linear-gradient(180deg, var(--paper-soft) 70%, rgba(248,243,230,0.85));
  border-bottom: 1px solid var(--cream-line);
  backdrop-filter: blur(6px);
}

.icon-btn {
  width: 40px; height: 40px;
  border: none; background: transparent;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.15rem;
  color: var(--wine-dark);
  transition: background 0.2s ease;
}
.icon-btn:hover { background: rgba(124,45,59,0.08); }

.hamburger { display: flex; flex-direction: column; gap: 4px; width: 20px; }
.hamburger span { display: block; height: 2px; background: var(--wine-dark); border-radius: 2px; }

.brand {
  display: flex; align-items: center; gap: 8px;
  text-decoration: none;
  font-family: var(--font-display);
  font-style: italic;
  font-size: 1.25rem;
  color: var(--wine-dark);
}
.brand-mark { color: var(--rose); font-size: 1.1rem; }

.nav-drawer {
  position: fixed;
  top: 0; left: 0; bottom: 0;
  width: min(78vw, 300px);
  background: var(--paper-soft);
  border-right: 1px solid var(--cream-line);
  box-shadow: var(--shadow-lift);
  transform: translateX(-105%);
  transition: transform 0.28s cubic-bezier(.4,0,.2,1);
  z-index: 60;
  padding: 90px 20px 24px;
  display: flex;
  flex-direction: column;
}
.nav-drawer.is-open { transform: translateX(0); }
.nav-drawer ul { list-style: none; margin: 0; padding: 0; flex: 1; }
.nav-drawer li + li { margin-top: 4px; }
.nav-drawer a {
  display: flex; align-items: center; gap: 12px;
  text-decoration: none;
  padding: 12px 14px;
  border-radius: var(--radius-m);
  color: var(--ink);
  font-weight: 600;
  transition: background 0.2s ease, color 0.2s ease;
}
.nav-drawer a:hover { background: rgba(124,45,59,0.08); }
.nav-drawer a.is-active { background: var(--wine); color: var(--paper-soft); }
.nav-ico { font-size: 1.1rem; }

.drawer-surprise {
  border: none;
  background: var(--rose);
  color: #fff;
  padding: 12px;
  border-radius: 999px;
  font-weight: 700;
  box-shadow: var(--shadow-soft);
}

.drawer-overlay {
  position: fixed; inset: 0;
  background: rgba(58,34,24,0.35);
  opacity: 0; pointer-events: none;
  transition: opacity 0.25s ease;
  z-index: 55;
}
.drawer-overlay.is-open { opacity: 1; pointer-events: auto; }

/* ==========================================================================
   Botones genéricos
   ========================================================================== */

.btn {
  display: inline-flex; align-items: center; justify-content: center;
  gap: 6px;
  border: none;
  border-radius: 999px;
  padding: 12px 22px;
  font-weight: 700;
  font-size: 0.95rem;
  text-decoration: none;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.2s ease;
}
.btn:active { transform: scale(0.97); }
.btn-primary { background: var(--wine); color: var(--paper-soft); box-shadow: var(--shadow-soft); }
.btn-primary:hover { background: var(--wine-dark); }
.btn-ghost { background: transparent; color: var(--wine-dark); border: 2px solid var(--wine); }
.btn-ghost:hover { background: rgba(124,45,59,0.08); }
.btn-text { background: transparent; color: var(--ink-soft); text-decoration: underline; padding: 8px 10px; }
.btn-danger { background: var(--wine-dark); color: #fff; }

/* ==========================================================================
   Vistas / layout general
   ========================================================================== */

main { max-width: 960px; margin: 0 auto; padding: 0 16px; }

.view-header {
  display: flex; align-items: flex-end; justify-content: space-between;
  gap: 12px; flex-wrap: wrap;
  margin: 28px 0 22px;
}
.eyebrow {
  font-family: var(--font-hand);
  font-size: 1.15rem;
  color: var(--gold);
  margin: 0;
}
.view-header h2 { font-size: 1.7rem; margin: 2px 0 0; }

.empty-state {
  text-align: center;
  color: var(--ink-soft);
  font-family: var(--font-hand);
  font-size: 1.3rem;
  padding: 50px 20px;
}

/* ==========================================================================
   Portada
   ========================================================================== */

.cover {
  position: relative;
  margin: 18px auto 0;
  border-radius: var(--radius-l);
  overflow: hidden;
  background: linear-gradient(160deg, var(--paper-dark), var(--paper));
  min-height: auto;
  max-width: 700px;
  width: min(100%, 700px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px 14px;
  border: 1px solid var(--cream-line);
}

.cover-photos {
  position: absolute; inset: 0;
  overflow: hidden;
  pointer-events: none;
}
.cover-photo {
  position: absolute;
  width: 82px; height: 98px;
  object-fit: cover;
  border: 5px solid #fff;
  border-bottom-width: 18px;
  box-shadow: var(--shadow-soft);
  transform: rotate(var(--rot));
  opacity: 0.55;
}
.cover-photo:nth-child(1) { top: 8%; left: 4%; }
.cover-photo:nth-child(2) { top: 62%; left: 8%; width: 72px; height: 86px; }
.cover-photo:nth-child(3) { top: 14%; right: 6%; }
.cover-photo:nth-child(4) { bottom: 10%; right: 10%; width: 84px; height: 98px; }
.cover-photo:nth-child(5) { top: 42%; left: 46%; width: 70px; height: 82px; opacity: 0.35; }
.cover-photo:nth-child(6) { display: none; }

.cover-card {
  position: relative;
  z-index: 2;
  text-align: center;
  width: min(100%, 460px);
  background: rgba(248,243,230,0.96);
  padding: 20px 18px;
  border-radius: var(--radius-l);
  box-shadow: var(--shadow-lift);
  border: 1px solid var(--cream-line);
}
.cover-title {
  font-size: clamp(1.8rem, 6vw, 2.4rem);
  font-style: italic;
  margin-bottom: 6px;
}
.cover-names {
  font-family: var(--font-hand);
  font-size: 1.3rem;
  color: var(--wine);
  margin-bottom: 6px;
}
.cover-counter {
  color: var(--ink-soft);
  font-size: 0.88rem;
  margin-bottom: 14px;
}
.cover-actions { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; }

@media (max-width: 820px) {
  .cover { min-height: auto; max-height: 380px; padding: 16px 12px; }
  .cover-card { width: min(100%, 360px); padding: 18px 14px; }
  .cover-title { font-size: 1.95rem; }
  .cover-names { font-size: 1.15rem; }
  .cover-photo { width: 70px; height: 82px; border-width: 4px; border-bottom-width: 14px; }
}

@media (max-width: 640px) {
  .cover { min-height: 34vh; max-height: 440px; padding: 16px 12px; }
  .cover-card { width: min(100%, 420px); padding: 18px 14px; }
  .cover-title { font-size: 2rem; }
  .cover-names { font-size: 1.2rem; }
  .cover-photo { display: none; }
}

#sub-frame-error,
#sub-frame-error-details,
.sub-frame-error,
iframe#sub-frame-error,
iframe[src*="open.spotify.com"] + #sub-frame-error {
  display: none !important;
}

@media (max-width: 820px) {
  .cover { min-height: 34vh; max-height: 360px; padding: 20px 14px; }
  .cover-card { width: min(100%, 380px); padding: 20px 16px; }
  .cover-photo { width: 78px; height: 94px; border-width: 4px; border-bottom-width: 16px; }
}

.access-gate {
  position: fixed;
  inset: 0;
  z-index: 120;
  display: grid;
  place-items: center;
  background: rgba(20, 14, 11, 0.92);
  padding: 20px;
}
.access-gate-card {
  width: min(100%, 440px);
  background: rgba(255, 255, 255, 0.96);
  border-radius: var(--radius-l);
  padding: 30px 24px;
  box-shadow: var(--shadow-lift);
  border: 1px solid rgba(58, 46, 39, 0.14);
  text-align: center;
}
.access-gate-card h2 {
  margin-bottom: 12px;
  font-family: var(--font-display);
  font-size: 1.9rem;
  color: var(--wine-dark);
}
.access-gate-card p {
  margin-bottom: 18px;
  color: var(--ink);
}
#access-link-input {
  width: 100%;
  border: 1px solid var(--cream-line);
  border-radius: var(--radius-m);
  padding: 14px 16px;
  font-size: 1rem;
  margin-bottom: 14px;
}
#access-link-input.is-invalid {
  border-color: var(--wine);
}
.access-gate-help {
  margin-top: 10px;
  font-size: 0.92rem;
  color: var(--ink-soft);
}
.access-gate.hidden { display: none; }

.home-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 16px;
  margin: 30px 0 40px;
}
.home-tile {
  text-decoration: none;
  color: var(--ink);
  background: var(--paper-soft);
  border: 1px solid var(--cream-line);
  border-radius: var(--radius-m);
  padding: 20px 16px;
  text-align: center;
  box-shadow: var(--shadow-soft);
  transform: rotate(var(--tilt, 0deg));
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.home-tile:hover { transform: rotate(0deg) translateY(-4px); box-shadow: var(--shadow-lift); }
.home-tile-ico { font-size: 1.8rem; display: block; margin-bottom: 6px; }
.home-tile h3 { font-size: 1.1rem; margin-bottom: 4px; }
.home-tile p { font-size: 0.85rem; color: var(--ink-soft); margin: 0; }

/* ==========================================================================
   Álbum de fotos — corcho + polaroids
   ========================================================================== */

.corkboard {
  background: var(--cork);
  background-image:
    radial-gradient(circle at 20% 30%, rgba(0,0,0,0.06) 0, transparent 3%),
    radial-gradient(circle at 70% 60%, rgba(0,0,0,0.05) 0, transparent 3%),
    radial-gradient(circle at 40% 80%, rgba(0,0,0,0.05) 0, transparent 3%);
  border-radius: var(--radius-l);
  padding: 30px 22px 40px;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 26px;
  box-shadow: inset 0 0 40px rgba(0,0,0,0.18);
}

.polaroid {
  background: #fff;
  padding: 10px 10px 26px;
  border-radius: 3px;
  box-shadow: 0 8px 16px rgba(0,0,0,0.28);
  position: relative;
  transform: rotate(var(--rot, 0deg));
  cursor: pointer;
  animation: pop-in 0.4s both;
  animation-delay: var(--delay, 0s);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.polaroid:hover { transform: rotate(0deg) scale(1.04); box-shadow: 0 14px 24px rgba(0,0,0,0.32); z-index: 2; }
.polaroid-photo { aspect-ratio: 1 / 1; overflow: hidden; background: var(--paper-dark); }
.polaroid-photo img { width: 100%; height: 100%; object-fit: cover; }
.polaroid-caption { font-family: var(--font-hand); font-size: 1.2rem; text-align: center; margin: 10px 0 0; color: var(--ink); }
.polaroid-date { text-align: center; font-size: 0.72rem; color: var(--ink-soft); margin: 0; }

.pin {
  position: absolute;
  top: -10px; left: 50%; transform: translateX(-50%);
  width: 16px; height: 16px;
  border-radius: 50%;
  background: radial-gradient(circle at 30% 30%, #e8b23d, var(--gold) 70%);
  box-shadow: 0 3px 4px rgba(0,0,0,0.4);
}

@keyframes pop-in {
  from { opacity: 0; transform: translateY(14px) rotate(var(--rot, 0deg)); }
  to { opacity: 1; transform: translateY(0) rotate(var(--rot, 0deg)); }
}

.polaroid-big { background: #fff; padding: 16px 16px 24px; border-radius: 4px; max-width: 420px; }
.polaroid-big-photo { max-height: 55vh; overflow: hidden; border-radius: 2px; margin-bottom: 14px; }
.polaroid-big-photo img { width: 100%; height: 100%; object-fit: cover; }
.polaroid-story { white-space: pre-line; }

/* ==========================================================================
   Cartas y notas
   ========================================================================== */

.notes-pinned {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 18px;
  margin-bottom: 14px;
}
.notes-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(190px, 1fr));
  gap: 18px;
}

.note-card {
  background: var(--paper-soft);
  border-radius: var(--radius-m) var(--radius-m) 2px 2px;
  padding: 18px 16px 16px;
  box-shadow: var(--shadow-soft);
  border-top: 4px solid var(--rose);
  position: relative;
  cursor: pointer;
  transform: rotate(var(--rot, 0deg));
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  animation: pop-in 0.4s both;
  animation-delay: var(--delay, 0s);
}
.note-card:hover { transform: rotate(0deg) translateY(-4px); box-shadow: var(--shadow-lift); }
.note-card--pinned { border-top-color: var(--gold); background: #fbf3df; }
.note-star { position: absolute; top: -10px; right: 12px; font-size: 1.2rem; filter: drop-shadow(0 2px 2px rgba(0,0,0,0.25)); }
.note-card-title { font-family: var(--font-display); font-weight: 600; font-size: 1.05rem; margin-bottom: 6px; color: var(--wine-dark); }
.note-card-excerpt { font-size: 0.88rem; color: var(--ink-soft); min-height: 40px; }
.note-card-date { font-size: 0.75rem; color: var(--gold); margin: 0; text-transform: uppercase; letter-spacing: 0.04em; }

.letter-paper {
  background: var(--paper-soft);
  background-image: repeating-linear-gradient(var(--paper-soft) 0 27px, var(--cream-line) 27px 28px);
  padding: 30px 26px;
  border-radius: 4px;
  max-width: 480px;
  box-shadow: var(--shadow-soft);
}
.letter-date { font-size: 0.8rem; color: var(--gold); text-transform: uppercase; letter-spacing: 0.05em; margin-bottom: 4px; }
.letter-title { font-style: italic; }
.letter-body { font-family: var(--font-hand); font-size: 1.35rem; line-height: 1.6; white-space: pre-line; color: var(--ink); }

/* ==========================================================================
   Canciones — playlist tipo tocadiscos
   ========================================================================== */

.playlist { display: flex; flex-direction: column; gap: 12px; }

.song-row {
  background: var(--paper-soft);
  border: 1px solid var(--cream-line);
  border-radius: var(--radius-m);
  overflow: hidden;
  box-shadow: var(--shadow-soft);
  animation: pop-in 0.4s both;
  animation-delay: var(--delay, 0s);
}

.song-row-head {
  width: 100%;
  display: flex; align-items: center; gap: 14px;
  background: none; border: none;
  padding: 14px 16px;
  text-align: left;
}

.vinyl {
  width: 44px; height: 44px; border-radius: 50%;
  flex-shrink: 0;
  background:
    radial-gradient(circle at center, var(--paper-soft) 0 6%, transparent 7%),
    repeating-radial-gradient(circle at center, #2b2320 0 2px, #3a2f2a 2px 4px);
  border: 2px solid var(--ink);
  transition: transform 0.6s ease;
}
.song-row-head:hover .vinyl { transform: rotate(60deg); }
.song-row.is-open .vinyl { animation: spin 3.5s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

.song-meta { flex: 1; min-width: 0; }
.song-name { display: block; font-family: var(--font-display); font-weight: 600; color: var(--wine-dark); }
.song-artist { display: block; font-size: 0.85rem; color: var(--ink-soft); }
.song-chevron { transition: transform 0.2s ease; color: var(--ink-soft); }
.song-row.is-open .song-chevron { transform: rotate(180deg); }

.song-detail {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease, padding 0.3s ease;
  padding: 0 16px;
}
.song-row.is-open .song-detail { max-height: 720px; padding: 0 16px 16px; }
.song-note { font-family: var(--font-hand); font-size: 1.15rem; }
.song-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 4px 10px;
  border-radius: 999px;
  background: #1db954;
  color: white;
  font-size: 0.8rem;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}
.song-cover {
  margin-top: 12px;
  border-radius: 16px;
  overflow: hidden;
  display: grid;
  place-items: center;
  min-height: 180px;
}
.song-cover img {
  width: 35%;
  height: auto;
  display: block;
  opacity: 0;
  border-radius: 2rem;
  border: 2px solid; 
  border-color:rgba(58, 34, 24, 0.16);  
  transition: opacity 0.8s ease;
}
.song-cover img.is-loaded {
  opacity: 1;
}
.song-cover--placeholder {
  color: white;
  font-size: 0.95rem;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  font-weight: 700;
  padding: 18px;
}
.song-embed { margin-top: 12px; }
.embed { border-radius: 10px; margin-top: 6px; }
.embed-youtube { width: 100%; aspect-ratio: 16/9; height: auto; }
.song-link { color: var(--wine); font-weight: 700; text-decoration: underline; }

/* ==========================================================================
   Línea de tiempo
   ========================================================================== */

.timeline {
  position: relative;
  padding: 20px 0;
}
.timeline::before {
  content: '';
  position: absolute;
  left: 50%;
  top: 0; bottom: 0;
  width: 3px;
  transform: translateX(-50%);
  background: repeating-linear-gradient(180deg, var(--gold) 0 8px, transparent 8px 16px);
}

.timeline-item {
  position: relative;
  width: 50%;
  padding: 0 34px 34px;
  animation: pop-in 0.5s both;
  animation-delay: var(--delay, 0s);
}
.timeline-item--left { left: 0; text-align: right; }
.timeline-item--right { left: 50%; text-align: left; }

.timeline-dot {
  position: absolute;
  top: 4px;
  width: 16px; height: 16px;
  border-radius: 50%;
  background: var(--wine);
  border: 3px solid var(--paper-soft);
  box-shadow: 0 0 0 2px var(--gold);
}
.timeline-item--left .timeline-dot { right: -8px; }
.timeline-item--right .timeline-dot { left: -8px; }

.timeline-card {
  display: inline-block;
  text-align: left;
  background: var(--paper-soft);
  border: 1px solid var(--cream-line);
  border-radius: var(--radius-m);
  padding: 16px 18px;
  box-shadow: var(--shadow-soft);
  max-width: 340px;
}
.timeline-date { font-size: 0.75rem; text-transform: uppercase; letter-spacing: 0.05em; color: var(--gold); }
.timeline-title { font-size: 1.15rem; }
.timeline-desc { font-size: 0.92rem; color: var(--ink-soft); }
.timeline-photos { display: flex; gap: 6px; flex-wrap: wrap; margin: 8px 0; }
.timeline-photos img { width: 52px; height: 52px; object-fit: cover; border-radius: 6px; border: 2px solid #fff; box-shadow: 0 2px 6px rgba(0,0,0,0.25); cursor: pointer; }

/* ==========================================================================
   Cápsulas del tiempo
   ========================================================================== */

.capsules-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 18px;
}
.capsule-card {
  background: linear-gradient(160deg, var(--paper-soft), var(--paper-dark));
  border-radius: var(--radius-m);
  padding: 26px 18px;
  text-align: center;
  box-shadow: var(--shadow-soft);
  cursor: pointer;
  animation: pop-in 0.4s both;
  animation-delay: var(--delay, 0s);
  transition: transform 0.2s ease;
  border: 1px dashed var(--gold);
}
.capsule-card:hover { transform: translateY(-4px); }
.capsule-card--unlocked { border-style: solid; border-color: var(--sage); }
.capsule-ico { font-size: 2rem; display: block; margin-bottom: 8px; }
.capsule-status { font-size: 0.85rem; color: var(--ink-soft); }
.capsule-countdown { font-family: var(--font-hand); font-size: 1.2rem; color: var(--wine); margin: 0; }

/* ==========================================================================
   Modales
   ========================================================================== */

.modal-overlay {
  position: fixed; inset: 0;
  background: rgba(58,34,24,0.42);
  z-index: 90;
  opacity: 0; pointer-events: none;
  transition: opacity 0.2s ease;
}
.modal-overlay.is-open { opacity: 1; pointer-events: auto; }

.modal {
  position: fixed;
  z-index: 95;
  left: 50%; top: 50%;
  transform: translate(-50%, -46%) scale(0.96);
  opacity: 0;
  pointer-events: none;
  transition: transform 0.2s ease, opacity 0.2s ease;
  background: var(--paper-soft);
  border-radius: var(--radius-l);
  padding: 26px 24px;
  width: min(92vw, 480px);
  max-height: 88vh;
  overflow-y: auto;
  box-shadow: var(--shadow-lift);
}
.modal.is-open { opacity: 1; pointer-events: auto; transform: translate(-50%, -50%) scale(1); }
.modal-photo-view, .modal-note-view { background: transparent; box-shadow: none; padding: 0; }
.modal-photo-view .polaroid-big, .modal-note-view .letter-paper { margin: 0 auto; }

.modal-close {
  position: absolute; top: 10px; right: 10px;
  width: 34px; height: 34px;
  border: none; border-radius: 50%;
  background: rgba(58,34,24,0.08);
  color: var(--ink);
  font-size: 1rem;
  z-index: 2;
}
.modal-close:hover { background: rgba(58,34,24,0.16); }

.modal-confirm { text-align: center; }

.modal-surprise { text-align: center; overflow: visible; }
.surprise-eyebrow { font-family: var(--font-hand); color: var(--gold); font-size: 1.2rem; }
.surprise-card { text-align: center; align-items: center; align-content: center; display: block; margin: 18px auto 0; width: 100%; max-width: 420px; }
.surprise-tag { text-transform: uppercase; letter-spacing: 0.06em; font-size: 0.75rem; color: var(--gold); }
.surprise-empty { text-align: center; padding: 30px 10px; }

.surprise-cover {
  margin: 12px auto 0;
  padding: auto;
  border-radius: 12px;
  justify-content: center;
  overflow: hidden;
  align-items: center;
  align-content: center;
  display: block;
  width: 100%;
  max-width: 420px;
  max-height: 220px;
}
.surprise-cover img {
  width: 40%;
  height: 40%;
  margin-left: auto;
  margin-right: auto;
  object-fit: cover;
  display: block;
  opacity: 0;
  transition: opacity 0.4s ease, transform 0.3s ease;
  transform: scale(1.02);
}
.surprise-cover img.is-loaded { opacity: 1; transform: scale(1); }

.floating-heart {
  position: absolute;
  bottom: 10px;
  color: var(--rose);
  font-size: 1.4rem;
  pointer-events: none;
  animation: float-up 2s ease-out forwards;
}
@keyframes float-up {
  0% { opacity: 0; transform: translate(0, 0) scale(0.6); }
  15% { opacity: 1; }
  100% { opacity: 0; transform: translate(var(--drift, 0px), -160px) scale(1.1); }
}

/* ==========================================================================
   Formularios
   ========================================================================== */

.field { display: block; margin-bottom: 14px; }
.field span { display: block; font-weight: 700; font-size: 0.85rem; margin-bottom: 5px; color: var(--wine-dark); }
.field input[type=text], .field input[type=date], .field input[type=url], .field textarea, .field select {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--cream-line);
  border-radius: 10px;
  background: #fff;
  font-family: var(--font-body);
  font-size: 0.95rem;
  color: var(--ink);
}
.field textarea { resize: vertical; }
.field small { color: var(--ink-soft); font-size: 0.78rem; }
.field-checkbox { display: flex; align-items: center; gap: 8px; }
.field-checkbox input { width: 18px; height: 18px; }
.field-checkbox span { margin: 0; }

.file-preview { margin: -6px 0 14px; border-radius: 10px; overflow: hidden; max-height: 180px; }
.file-preview img { width: 100%; height: 180px; object-fit: cover; }

.form-actions { display: flex; justify-content: flex-end; gap: 10px; margin-top: 16px; flex-wrap: wrap; }
.form-actions-split { justify-content: space-between; }

/* ==========================================================================
   Botón flotante + toast
   ========================================================================== */

.fab {
  position: fixed;
  right: 18px; bottom: 18px;
  width: 56px; height: 56px;
  border-radius: 50%;
  border: none;
  background: var(--wine);
  color: #fff;
  font-size: 1.5rem;
  box-shadow: var(--shadow-lift);
  z-index: 50;
  transition: transform 0.2s ease;
}
.fab:hover { transform: scale(1.08); }
.fab:active { transform: scale(0.95); }

.toast {
  position: fixed;
  left: 50%; bottom: 20px;
  transform: translate(-50%, 20px);
  background: var(--ink);
  color: var(--paper-soft);
  padding: 12px 20px;
  border-radius: 999px;
  font-size: 0.9rem;
  opacity: 0;
  transition: opacity 0.25s ease, transform 0.25s ease;
  z-index: 120;
  box-shadow: var(--shadow-soft);
}
.toast.is-open { opacity: 1; transform: translate(-50%, 0); }

/* ==========================================================================
   Responsive
   ========================================================================== */

@media (max-width: 640px) {
  .timeline::before { left: 18px; }
  .timeline-item, .timeline-item--left, .timeline-item--right {
    width: 100%; left: 0; text-align: left; padding: 0 0 28px 44px;
  }
  .timeline-item--left .timeline-dot, .timeline-item--right .timeline-dot { left: 10px; }
  .timeline-card { max-width: 100%; }
  .cover { min-height: 34vh; max-height: 420px; padding: 16px 12px; }
  .cover-photo { display: none; }
}

@media (min-width: 900px) {
  .brand-text { letter-spacing: 0.01em; }
}
