/* =====================================================================
   BODA ELENA & LUCAS (DEMO) — 15 DE NOVIEMBRE 2026
   Sistema de Diseño: Romántico, Nostálgico, Moderno y No-Plano
   (Neumorphism sutil, Glassmorphism, Relieves Dorados y Sombras Envolventes)
   ===================================================================== */

/* Las fuentes de Google Fonts se cargan de forma no bloqueante desde views/partials/pwa_head.php */

@font-face {
  font-family: 'La Luxes Script';
  src: local('La Luxes Script'), local('LaLuxesScript'), local('La-Luxes-Script');
  font-display: swap;
}

:root {
  /* Paleta principal */
  --bg-primary: #FAF8F5;
  --bg-surface: #F1ECE4;
  --text-primary: #1F1D1B;
  --text-secondary: #6E665E;
  --accent-gold: #B8935A;
  --accent-gold-hover: #9A7742;
  --border-subtle: #E2D9CC;

  /* Tokens semánticos y compatibilidad */
  --color-bg: var(--bg-primary);
  --color-bg-alt: var(--bg-surface);
  --color-surface: var(--bg-surface);
  --color-surface-glass: rgba(241, 236, 228, 0.82);
  --color-card-border: var(--border-subtle);

  --color-olive: #2E2A27;
  --color-olive-light: var(--text-secondary);
  --color-olive-dark: var(--text-primary);
  --color-burgundy: var(--color-olive);
  --color-burgundy-light: var(--color-olive-light);
  --color-burgundy-dark: var(--color-olive-dark);

  --color-gold: var(--accent-gold);
  --color-gold-light: var(--border-subtle);
  --color-gold-dark: var(--accent-gold-hover);
  --gold-gradient: linear-gradient(135deg, #CFAF7A 0%, #B8935A 50%, #9A7742 100%);
  --gold-glow: 0 0 25px rgba(184, 147, 90, 0.35);

  --color-rose: var(--bg-surface);
  --color-text-primary: var(--text-primary);
  --color-text-secondary: var(--text-secondary);
  --color-text-muted: #8C837A;

  --font-serif: 'Cormorant Garamond', Georgia, serif;
  --font-script: 'Corinthia', 'Alex Brush', cursive;
  --font-sans: 'Montserrat', 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;

  /* Sombras No-Planas con Profundidad Multicapa */
  --shadow-sm: 0 4px 12px rgba(31, 29, 27, 0.05), 0 1px 3px rgba(31, 29, 27, 0.04);
  --shadow-md: 0 12px 30px -5px rgba(31, 29, 27, 0.12), 0 4px 10px rgba(31, 29, 27, 0.04);
  --shadow-lg: 0 24px 50px -10px rgba(31, 29, 27, 0.18), 0 10px 20px -5px rgba(184, 147, 90, 0.14);
  --shadow-inset: inset 0 2px 4px rgba(255, 255, 255, 0.8), inset 0 -2px 4px rgba(31, 29, 27, 0.04);
  --shadow-card: 0 16px 36px -8px rgba(31, 29, 27, 0.12), 0 0 0 1px var(--border-subtle);

  --radius-sm: 10px;
  --radius-md: 18px;
  --radius-lg: 28px;
  --radius-full: 9999px;

  --transition-smooth: all 0.32s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Reset y Base */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  -webkit-tap-highlight-color: transparent;
}

body {
  font-family: var(--font-sans);
  background-color: var(--color-bg);
  color: var(--color-text-primary);
  line-height: 1.6;
  overflow-x: hidden;
  background-image: 
    radial-gradient(ellipse at 85% 15%, rgba(184, 147, 90, 0.14) 0%, transparent 45%),
    radial-gradient(ellipse at 15% 75%, rgba(110, 102, 94, 0.08) 0%, transparent 50%),
    radial-gradient(circle at 50% 50%, rgba(250, 248, 245, 0.8) 0%, var(--color-bg) 100%);
  background-attachment: fixed;
  min-height: 100vh;
}

/* Tipografía de Lujo */
h1, h2, h3, .font-serif {
  font-family: var(--font-serif);
  font-weight: 600;
  letter-spacing: -0.01em;
}

.script-font {
  font-family: var(--font-script);
  font-weight: 400;
  color: var(--color-gold);
}

/* Botones Modernos No-Planos con Acabado Joya */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 13px 26px;
  border-radius: var(--radius-full);
  font-family: var(--font-sans);
  font-size: 0.92rem;
  font-weight: 600;
  text-decoration: none;
  border: none;
  cursor: pointer;
  transition: var(--transition-smooth);
  position: relative;
  overflow: hidden;
}

.btn-primary {
  background: var(--gold-gradient);
  color: #1F1D1B;
  box-shadow: 0 8px 20px rgba(184, 147, 90, 0.32), inset 0 1px 1px rgba(255, 255, 255, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.3);
}

.btn-primary:hover {
  transform: translateY(-2.5px);
  box-shadow: 0 14px 28px rgba(184, 147, 90, 0.45), inset 0 1px 2px rgba(255, 255, 255, 0.8);
}

.btn-primary:active {
  transform: translateY(0);
  box-shadow: 0 4px 12px rgba(184, 147, 90, 0.25);
}

.btn-burgundy {
  background: linear-gradient(135deg, var(--color-burgundy-light) 0%, var(--color-burgundy) 60%, var(--color-burgundy-dark) 100%);
  color: #FFFFFF;
  box-shadow: 0 8px 24px rgba(31, 29, 27, 0.35), inset 0 1px 1px rgba(255, 255, 255, 0.3);
  border: 1px solid rgba(184, 147, 90, 0.35);
}

.btn-burgundy:hover {
  transform: translateY(-2.5px);
  box-shadow: 0 14px 32px rgba(31, 29, 27, 0.45);
  color: #FFF;
}

.btn-outline {
  background: rgba(255, 255, 255, 0.8);
  backdrop-filter: blur(8px);
  color: var(--color-burgundy);
  border: 1px solid rgba(184, 147, 90, 0.45);
  box-shadow: var(--shadow-sm);
}

.btn-outline:hover {
  background: #FFFFFF;
  border-color: var(--color-gold);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

/* Tarjetas y Paneles Glassmorphism */
.glass-panel {
  background: var(--color-surface-glass);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--color-card-border);
  box-shadow: var(--shadow-card);
  border-radius: var(--radius-lg);
  position: relative;
}

/* Header & Barra de Navegación */
/* Barra de Navegación Superior Fija Docked (Estilo App Nupcial) */
.site-nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  width: 100%;
  height: 62px;
  z-index: 1000;
  padding: 0 32px;
  border-radius: 0;
  transform: none;
  background: rgba(250, 248, 245, 0.94);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(184, 147, 90, 0.22);
  box-shadow: 0 4px 20px rgba(31, 29, 27, 0.05);
  display: flex;
  align-items: center;
  justify-content: space-between;
  transition: var(--transition-smooth);
}

@media (min-width: 1280px) {
  .site-nav {
    padding: 0 max(32px, calc((100vw - 1240px) / 2));
  }
}

.nav-brand {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  text-decoration: none;
  padding: 2px 0;
  transition: var(--transition-smooth);
}

.nav-brand:hover .brand-emblem {
  transform: translateY(-1px) scale(1.04);
}

.nav-brand:hover .brand-emblem .logo-star {
  filter: drop-shadow(0 0 4px rgba(184, 147, 90, 0.55));
}

.brand-emblem {
  width: 34px;
  height: 42px;
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--color-olive);
  transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

.brand-emblem svg {
  width: 100%;
  height: 100%;
  display: block;
  overflow: visible;
}

.brand-emblem .logo-heart-olive {
  opacity: 0.72;
}

.brand-emblem .logo-sprig-stem {
  opacity: 0.82;
}

.brand-emblem .logo-sprig-leaf {
  opacity: 0.72;
}

.brand-emblem .logo-sprig-leaf-soft {
  opacity: 0.56;
}

.brand-divider {
  width: 1px;
  height: 26px;
  flex-shrink: 0;
  background: linear-gradient(180deg, rgba(184, 147, 90, 0) 0%, rgba(184, 147, 90, 0.58) 50%, rgba(184, 147, 90, 0) 100%);
}

.brand-wordmark {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 1px;
  line-height: 1;
}

.brand-text {
  font-family: var(--font-serif);
  font-size: 1.32rem;
  font-weight: 500;
  color: var(--color-olive-dark);
  letter-spacing: 0.03em;
  line-height: 1.05;
  white-space: nowrap;
}

.brand-amp {
  font-family: var(--font-script);
  font-size: 1.18em;
  font-weight: 400;
  color: var(--color-gold);
  margin: 0 2px;
  vertical-align: -0.02em;
}

.brand-date {
  font-family: var(--font-sans);
  font-size: 0.58rem;
  font-weight: 500;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--color-gold-dark);
  opacity: 0.88;
  margin-top: 2px;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 20px;
  list-style: none;
}

.nav-link {
  color: var(--color-text-secondary);
  text-decoration: none;
  font-size: 0.88rem;
  font-weight: 500;
  padding: 6px 12px;
  border-radius: var(--radius-full);
  transition: var(--transition-smooth);
}

.nav-link:hover, .nav-link.active {
  color: var(--color-burgundy);
  background: rgba(184, 147, 90, 0.12);
}

.user-badge {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 16px;
  background: rgba(74, 21, 37, 0.06);
  border-radius: var(--radius-full);
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--color-burgundy);
  cursor: pointer;
  border: 1px solid rgba(184, 147, 90, 0.25);
  transition: var(--transition-smooth);
}

.user-badge:hover {
  background: rgba(74, 21, 37, 0.12);
}

/* =====================================================================
   HERO SECTION: Romántico, Cinematográfico y Full-Bleed (Sin Márgenes)
   ===================================================================== */
.hero-section {
  position: relative;
  min-height: 100vh;
  padding: 120px 20px 70px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  overflow: hidden;
  width: 100%;
}

.hero-bg-frame {
  position: absolute;
  inset: 0;
  border-radius: 0;
  overflow: hidden;
  box-shadow: none;
  border: none;
  z-index: 1;
}

.hero-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 30%;
  filter: brightness(0.92) contrast(1.02) saturate(1.04);
  transform: scale(1.02);
  transition: transform 10s ease-out;
}

.hero-section:hover .hero-image {
  transform: scale(1.05);
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, 
    rgba(15, 20, 12, 0.22) 0%, 
    rgba(30, 38, 26, 0.28) 40%, 
    rgba(20, 26, 17, 0.65) 75%, 
    rgba(10, 14, 8, 0.92) 100%
  );
  z-index: 2;
}

.hero-content {
  position: relative;
  z-index: 3;
  max-width: 820px;
  color: #FFFFFF;
  padding: 20px;
}

.hero-eyebrow {
  font-size: 0.85rem;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--color-gold-light);
  margin-bottom: 12px;
  font-weight: 600;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.4);
}

.hero-title {
  font-family: var(--font-serif);
  font-size: clamp(3.2rem, 8vw, 6.4rem);
  font-weight: 500;
  line-height: 1;
  margin-bottom: 8px;
  color: #FFF;
  text-shadow: 0 4px 30px rgba(0, 0, 0, 0.5);
}

.hero-title span {
  font-family: var(--font-script);
  color: var(--color-gold-light);
  font-size: clamp(3.6rem, 9vw, 7.2rem);
  display: inline-block;
  margin: 0 10px;
  filter: drop-shadow(0 2px 8px rgba(184, 147, 90, 0.4));
}

.hero-subtitle {
  font-size: clamp(1rem, 2.5vw, 1.35rem);
  color: #F8EBE8;
  max-width: 580px;
  margin: 16px auto 30px;
  font-weight: 300;
  letter-spacing: 0.02em;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.4);
}

.hero-date-badge {
  display: inline-flex;
  align-items: center;
  gap: 16px;
  padding: 10px 28px;
  border-radius: var(--radius-full);
  background: rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(12px);
  border: 1px solid rgba(184, 147, 90, 0.5);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.25);
  margin-bottom: 35px;
}

.hero-date-badge span {
  font-family: var(--font-serif);
  font-size: 1.15rem;
  letter-spacing: 0.1em;
  color: var(--color-gold-light);
  font-weight: 600;
}

/* Cuenta Regresiva Romántica Estilo Joya */
.countdown-box {
  display: flex;
  justify-content: center;
  gap: 16px;
  margin-top: 15px;
}

.countdown-item {
  min-width: 74px;
  padding: 14px 10px;
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.14);
  backdrop-filter: blur(14px);
  border: 1px solid rgba(255, 255, 255, 0.25);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.25), inset 0 1px 1px rgba(255, 255, 255, 0.3);
}

.countdown-num {
  font-family: var(--font-serif);
  font-size: 2.2rem;
  font-weight: 600;
  color: #FFFFFF;
  line-height: 1;
}

.countdown-lbl {
  font-size: 0.65rem;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: var(--color-gold-light);
  margin-top: 4px;
}

/* =====================================================================
   SECCIÓN INDEPENDIENTE: COMPARTE TUS MOMENTOS (ESTILO VERSION 1 ELEGANTE)
   ===================================================================== */
.upload-main-section {
  position: relative;
  padding: 60px 24px 40px;
}

.upload-card-wrapper {
  max-width: 840px;
  margin: 0 auto;
  background: #FFFFFF;
  border-radius: 24px;
  border: 1px solid rgba(184, 147, 90, 0.35);
  box-shadow: 0 16px 40px -10px rgba(31, 29, 27, 0.12), 0 4px 16px rgba(0, 0, 0, 0.04);
  overflow: hidden;
  transition: var(--transition-smooth);
}

.upload-card-wrapper:hover {
  box-shadow: 0 20px 48px -10px rgba(31, 29, 27, 0.18);
  border-color: rgba(184, 147, 90, 0.55);
}

.guest-status-banner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 26px;
  background: linear-gradient(135deg, #FAF8F5 0%, #F5EFE6 100%);
  border-bottom: 1px solid rgba(184, 147, 90, 0.22);
  gap: 14px;
  flex-wrap: wrap;
}

.guest-info-side {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
  flex: 1 1 240px;
}

.guest-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--gold-gradient);
  display: grid;
  place-items: center;
  color: #1F1D1B;
  font-weight: 700;
  flex-shrink: 0;
  box-shadow: 0 2px 8px rgba(184, 147, 90, 0.35);
}

.guest-texts {
  min-width: 0;
  flex: 1 1 auto;
}

.guest-album-tag {
  display: block;
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--color-gold-dark);
  font-weight: 600;
  line-height: 1.2;
  margin-bottom: 2px;
}

.guest-album-title {
  font-family: var(--font-sans);
  font-size: 0.98rem;
  font-weight: 700;
  color: var(--color-olive);
  margin: 0;
  line-height: 1.35;
  word-break: break-word;
}

.quota-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--color-olive);
  background: rgba(31, 29, 27, 0.08);
  border: 1px solid rgba(31, 29, 27, 0.2);
  padding: 6px 14px;
  border-radius: var(--radius-full);
  white-space: nowrap;
  flex-shrink: 0;
}

/* Dropzone interactivo espacioso (proporciones de Version 1) */
.upload-dropzone {
  border: 2px dashed rgba(184, 147, 90, 0.45);
  border-radius: 20px;
  padding: 44px 28px 40px;
  margin: 24px;
  text-align: center;
  background: linear-gradient(180deg, rgba(250, 248, 245, 0.85) 0%, rgba(255, 255, 255, 0.95) 100%);
  cursor: pointer;
  transition: all 0.25s ease;
  position: relative;
}

.upload-dropzone:hover,
.upload-dropzone.dragover {
  border-color: var(--color-gold);
  background: linear-gradient(180deg, rgba(245, 240, 230, 0.95) 0%, rgba(255, 255, 255, 1) 100%);
  transform: translateY(-2px);
  box-shadow: 0 12px 28px -6px rgba(184, 147, 90, 0.18);
}

.dropzone-icon-circle {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  margin: 0 auto 16px;
  background: linear-gradient(135deg, rgba(31, 29, 27, 0.12) 0%, rgba(184, 147, 90, 0.18) 100%);
  border: 1.5px solid rgba(184, 147, 90, 0.35);
  display: grid;
  place-items: center;
  color: var(--color-olive);
  transition: transform 0.25s ease;
}

.upload-dropzone:hover .dropzone-icon-circle {
  transform: scale(1.08);
  color: var(--color-gold-dark);
}

.dropzone-title {
  font-family: var(--font-serif);
  font-size: clamp(1.4rem, 2.8vw, 1.85rem);
  font-weight: 600;
  color: var(--color-olive);
  margin-bottom: 8px;
  line-height: 1.25;
}

.dropzone-subtitle {
  color: var(--color-text-secondary);
  font-size: 0.92rem;
  max-width: 520px;
  margin: 0 auto 24px;
  line-height: 1.45;
}

/* Dos botones de acción: Subir de Galería & Tomar con Cámara */
.upload-two-buttons {
  display: flex;
  flex-direction: row;
  justify-content: center;
  align-items: center;
  gap: 16px;
  max-width: 560px;
  margin: 0 auto;
}

.btn-upload-gallery,
.btn-upload-camera {
  flex: 1 1 0;
  min-width: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 50px;
  padding: 12px 22px;
  font-family: var(--font-sans);
  font-size: 0.95rem;
  font-weight: 600;
  border-radius: 30px;
  cursor: pointer;
  letter-spacing: 0.015em;
  transition: all 0.28s cubic-bezier(0.16, 1, 0.3, 1);
  white-space: nowrap;
  user-select: none;
}

.btn-action-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: transform 0.25s ease;
}

.btn-action-label {
  display: inline-block;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Botón 1: Subir de Galería (Blanco marfil + borde dorado elegante) */
#btnUploadFromDevice,
.btn-upload-gallery {
  background: #FFFFFF;
  border: 1.5px solid var(--color-gold);
  color: var(--color-olive);
  box-shadow: 0 4px 14px rgba(31, 29, 27, 0.08), inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

#btnUploadFromDevice:hover,
.btn-upload-gallery:hover {
  background: linear-gradient(135deg, #FAF8F5 0%, #FAF8F5 100%);
  border-color: var(--color-gold-dark);
  color: var(--color-olive-dark);
  transform: translateY(-2px);
  box-shadow: 0 8px 22px rgba(184, 147, 90, 0.22);
}

#btnUploadFromDevice:hover .btn-action-icon,
.btn-upload-gallery:hover .btn-action-icon {
  transform: translateY(-2px);
}

/* Botón 2: Tomar con Cámara (Oro champagne cálido con relieve sutil no-plano) */
#btnCaptureFromCamera,
.btn-upload-camera {
  background: var(--gold-gradient);
  border: 1px solid rgba(255, 255, 255, 0.45);
  color: #271406;
  box-shadow: 0 6px 18px rgba(184, 147, 90, 0.38), inset 0 1px 1px rgba(255, 255, 255, 0.6);
}

#btnCaptureFromCamera:hover,
.btn-upload-camera:hover {
  filter: brightness(1.05);
  transform: translateY(-2px);
  box-shadow: 0 10px 24px rgba(184, 147, 90, 0.48), inset 0 1px 1px rgba(255, 255, 255, 0.8);
}

#btnCaptureFromCamera:hover .btn-action-icon,
.btn-upload-camera:hover .btn-action-icon {
  transform: scale(1.12);
}

.btn-upload-gallery:active,
.btn-upload-camera:active {
  transform: scale(0.97);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
}

/* Divider ornamental para cabeceras de sección */
.section-divider {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  margin: 12px auto 16px;
}

.section-divider .divider-line {
  width: 50px;
  height: 1px;
  background: var(--color-gold);
  opacity: 0.6;
}

.section-divider svg {
  flex-shrink: 0;
}

/* Barra de Subida */
.upload-progress-wrapper {
  margin: 0 24px 24px;
  display: none;
}

.upload-progress-bar-bg {
  width: 100%;
  height: 8px;
  border-radius: var(--radius-full);
  background: rgba(31, 29, 27, 0.08);
  overflow: hidden;
}

.upload-progress-bar-fill {
  height: 100%;
  width: 0%;
  border-radius: var(--radius-full);
  background: var(--gold-gradient);
  box-shadow: 0 0 10px rgba(184, 147, 90, 0.5);
  transition: width 0.2s ease;
}

/* =====================================================================
   GALERÍA DE LA BODA (Masonry / Grid Elegante No-Plano)
   ===================================================================== */
.section-wrapper {
  max-width: 1240px;
  margin: 0 auto;
  padding: 80px 24px;
}

.section-head {
  text-align: center;
  max-width: 680px;
  margin: 0 auto 40px;
}

.section-tag {
  display: inline-block;
  font-size: 0.76rem;
  text-transform: uppercase;
  letter-spacing: 0.26em;
  color: var(--color-gold-dark);
  font-weight: 700;
  margin-bottom: 8px;
}

.section-title {
  font-size: clamp(2.4rem, 5vw, 3.8rem);
  color: var(--color-burgundy);
  line-height: 1.1;
  margin-bottom: 12px;
}

.section-desc {
  font-size: 1rem;
  color: var(--color-text-secondary);
}

.gallery-controls-bar {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  margin-bottom: 36px;
  flex-wrap: wrap;
}

.gallery-tabs {
  display: flex;
  justify-content: center;
  gap: 10px;
  flex-wrap: wrap;
}

.tab-btn {
  padding: 10px 22px;
  border-radius: var(--radius-full);
  background: rgba(255, 255, 255, 0.7);
  border: 1px solid rgba(184, 147, 90, 0.3);
  color: var(--color-text-secondary);
  font-weight: 600;
  font-size: 0.88rem;
  cursor: pointer;
  transition: var(--transition-smooth);
}

.tab-btn:hover {
  background: #FFF;
  color: var(--color-burgundy);
}

.tab-btn.active {
  background: var(--color-burgundy);
  color: #FFF;
  border-color: var(--color-burgundy);
  box-shadow: 0 6px 18px rgba(74, 21, 37, 0.25);
}

.btn-refresh-gallery {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  border-radius: var(--radius-full);
  background: #FFFFFF;
  border: 1.5px solid var(--color-gold);
  color: var(--color-olive);
  font-size: 0.86rem;
  font-weight: 600;
  cursor: pointer;
  box-shadow: var(--shadow-sm);
  transition: all 0.25s ease;
}

.btn-refresh-gallery:hover {
  background: rgba(184, 147, 90, 0.12);
  border-color: var(--color-gold-dark);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.btn-refresh-gallery:active svg {
  transform: rotate(180deg);
}

.btn-refresh-gallery svg {
  transition: transform 0.4s ease;
}

/* =====================================================================
   GRID ESTILO PINTEREST (Masonry Dinámico con Alturas Variables)
   ===================================================================== */
.gallery-grid {
  column-count: 4;
  column-gap: 20px;
  width: 100%;
}

@media (max-width: 1200px) {
  .gallery-grid {
    column-count: 3;
    column-gap: 18px;
  }
}

@media (max-width: 820px) {
  .gallery-grid {
    column-count: 2;
    column-gap: 14px;
  }
}

@media (max-width: 480px) {
  .gallery-grid {
    column-count: 1;
    column-gap: 0;
  }
}

/* Tarjeta Multimedia de la Galería (Masonry Pinterest) */
.media-card {
  break-inside: avoid;
  page-break-inside: avoid;
  margin-bottom: 20px;
  border-radius: var(--radius-md);
  overflow: hidden;
  background: #FFFFFF;
  box-shadow: var(--shadow-card);
  transition: var(--transition-smooth);
  position: relative;
  display: flex;
  flex-direction: column;
}

.media-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg);
}

.media-thumb-wrap {
  position: relative;
  width: 100%;
  background: #EFE8E1;
  overflow: hidden;
  cursor: pointer;
}

.media-thumb {
  width: 100%;
  height: auto;
  display: block;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.media-card:hover .media-thumb {
  transform: scale(1.05);
}

.media-type-badge {
  position: absolute;
  top: 12px;
  left: 12px;
  padding: 5px 12px;
  border-radius: var(--radius-full);
  background: rgba(0, 0, 0, 0.65);
  backdrop-filter: blur(6px);
  color: #FFFFFF;
  font-size: 0.74rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 5px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  z-index: 3;
}

.btn-delete-badge {
  position: absolute;
  top: 12px;
  right: 12px;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 6px 12px;
  border-radius: var(--radius-full);
  background: rgba(185, 28, 28, 0.88);
  backdrop-filter: blur(6px);
  color: #FFFFFF;
  border: 1px solid rgba(255, 255, 255, 0.3);
  font-size: 0.75rem;
  font-weight: 600;
  cursor: pointer;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
  transition: transform 0.2s, background 0.2s;
  z-index: 3;
}

.btn-delete-badge:hover {
  background: #DC2626;
  transform: scale(1.05);
}

.btn-delete-badge:active {
  transform: scale(0.95);
}

.media-card-footer {
  padding: 14px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: #FFFFFF;
  gap: 12px;
}

.media-author-info {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  flex: 1;
}

.media-author-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--gold-gradient);
  color: #1F1D1B;
  font-weight: 700;
  font-size: 0.82rem;
  display: grid;
  place-items: center;
  flex-shrink: 0;
  box-shadow: 0 2px 6px rgba(184, 147, 90, 0.35);
}

.media-author-meta {
  min-width: 0;
  display: flex;
  flex-direction: column;
}

.media-author-name {
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--color-burgundy);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.2;
}

.media-author-time {
  font-size: 0.72rem;
  color: var(--color-text-muted);
}

.media-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.btn-icon-action {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 1px solid rgba(74, 21, 37, 0.12);
  background: #FAF8F5;
  display: grid;
  place-items: center;
  color: var(--color-text-secondary);
  cursor: pointer;
  transition: var(--transition-smooth);
}

.btn-icon-action:hover {
  background: #FFFFFF;
  color: var(--color-burgundy);
  transform: scale(1.08);
}

.btn-like {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 36px;
  padding: 6px 14px;
  border-radius: var(--radius-full);
  border: 1px solid rgba(220, 53, 69, 0.25);
  background: rgba(220, 53, 69, 0.05);
  color: #C02942;
  font-size: 0.88rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.btn-like:hover {
  background: rgba(220, 53, 69, 0.12);
  transform: scale(1.04);
}

.btn-like:active {
  transform: scale(0.95);
}

.btn-like.liked {
  background: linear-gradient(135deg, #FF6B8B, #D32F2F);
  color: #FFFFFF;
  border-color: transparent;
  box-shadow: 0 4px 12px rgba(211, 47, 47, 0.35);
}

/* Vistas alternables del Libro de Firmas (Firmar / Ver Dedicatorias) */
.page-hero-header {
  text-align: center;
  padding: 120px 20px 40px;
  background: linear-gradient(180deg, #F5F7F3 0%, rgba(250, 248, 245, 0.5) 100%);
  border-bottom: 1px solid rgba(184, 147, 90, 0.25);
  margin-bottom: 30px;
}

.guestbook-view-tabs {
  display: flex;
  justify-content: center;
  gap: 12px;
  margin: 0 auto 36px;
  max-width: 440px;
}

.guestbook-tab-btn {
  flex: 1;
  padding: 12px 20px;
  border-radius: var(--radius-full);
  background: #FFFFFF;
  border: 1.5px solid rgba(184, 147, 90, 0.35);
  color: var(--color-olive);
  font-weight: 700;
  font-size: 0.92rem;
  cursor: pointer;
  transition: all 0.25s ease;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  box-shadow: var(--shadow-sm);
}

.guestbook-tab-btn:hover {
  background: rgba(184, 147, 90, 0.12);
  border-color: var(--color-gold);
}

.guestbook-tab-btn.active {
  background: var(--color-olive);
  color: #FFFFFF;
  border-color: var(--color-olive);
  box-shadow: 0 4px 14px rgba(31, 29, 27, 0.3);
}

.guestbook-view-pane {
  display: none;
  animation: fadeInPane 0.3s ease;
}

.guestbook-view-pane.active {
  display: block;
}

@keyframes fadeInPane {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: translateY(0); }
}

.guestbook-single-column {
  max-width: 680px;
  margin: 0 auto;
}

.guestbook-grid-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 20px;
}

.guestbook-empty-state {
  text-align: center;
  padding: 50px 20px;
}

.guestbook-form-card {
  padding: 32px;
}

.form-group {
  margin-bottom: 20px;
}

.form-label {
  display: block;
  font-size: 0.82rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--color-burgundy);
  margin-bottom: 8px;
}

.form-control {
  width: 100%;
  padding: 14px 18px;
  border-radius: var(--radius-md);
  border: 1px solid rgba(184, 147, 90, 0.35);
  background: #FFFFFF;
  font-family: inherit;
  font-size: 0.95rem;
  color: var(--color-text-primary);
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.03);
  transition: var(--transition-smooth);
}

.form-control:focus {
  outline: none;
  border-color: var(--color-gold);
  box-shadow: 0 0 0 3px rgba(184, 147, 90, 0.2), inset 0 2px 4px rgba(0, 0, 0, 0.02);
}

textarea.form-control {
  min-height: 120px;
  resize: vertical;
}

.guestbook-list {
  display: flex;
  flex-direction: column;
  gap: 18px;
  max-height: 600px;
  overflow-y: auto;
  padding-right: 8px;
}

.guestbook-item {
  padding: 22px;
  border-radius: var(--radius-md);
  background: #FFFFFF;
  border: 1px solid rgba(184, 147, 90, 0.22);
  box-shadow: var(--shadow-sm);
  position: relative;
  transition: var(--transition-smooth);
}

.guestbook-item:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  border-color: rgba(184, 147, 90, 0.45);
}

.guestbook-author {
  font-family: var(--font-serif);
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--color-burgundy);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.guestbook-date {
  font-family: var(--font-sans);
  font-size: 0.75rem;
  color: var(--color-text-muted);
  font-weight: 400;
}

.guestbook-message {
  margin-top: 10px;
  font-size: 0.94rem;
  color: var(--color-text-secondary);
  line-height: 1.6;
}

/* =====================================================================
   MODAL DE IDENTIFICACIÓN DE INVITADO Y ALERTAS ELEGANTES
   ===================================================================== */
.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(30, 9, 16, 0.72);
  backdrop-filter: blur(10px);
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  visibility: hidden;
  transition: var(--transition-smooth);
}

.modal-backdrop.active {
  opacity: 1;
  visibility: visible;
}

.modal-dialog {
  width: min(92%, 400px);
  background: #FFFFFF;
  border-radius: var(--radius-lg);
  padding: 36px 30px;
  box-shadow: var(--shadow-lg), 0 0 0 1px rgba(184, 147, 90, 0.35);
  text-align: center;
  transform: translateY(20px) scale(0.96);
  transition: var(--transition-smooth);
  position: relative;
}

.modal-close-btn {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 1px solid rgba(31, 29, 27, 0.2);
  background: #FAF8F5;
  color: var(--color-olive);
  display: grid;
  place-items: center;
  cursor: pointer;
  font-size: 1.4rem;
  line-height: 1;
  transition: all 0.2s ease;
  z-index: 10;
}

.modal-close-btn:hover {
  background: #FFFFFF;
  color: #DC2626;
  border-color: rgba(220, 38, 38, 0.4);
  transform: scale(1.08);
}

.modal-current-info {
  background: rgba(31, 29, 27, 0.08);
  border: 1px solid rgba(31, 29, 27, 0.18);
  border-radius: 14px;
  padding: 10px 16px;
  margin-bottom: 20px;
  font-size: 0.88rem;
  color: var(--color-olive);
}

.modal-current-info strong {
  color: var(--color-olive-dark);
  font-size: 0.98rem;
}

.modal-backdrop.active .modal-dialog {
  transform: translateY(0) scale(1);
}

.modal-icon-badge {
  width: 70px;
  height: 70px;
  margin: 0 auto 20px;
  border-radius: 50%;
  background: var(--gold-gradient);
  display: grid;
  place-items: center;
  color: #2D1807;
  box-shadow: var(--gold-glow);
}

.modal-title {
  font-size: 2rem;
  color: var(--color-burgundy);
  line-height: 1;
}

.modal-subtitle {
  font-size: 0.92rem;
  color: var(--color-text-secondary);
  margin-bottom: 24px;
}

/* =====================================================================
   SISTEMA DE NOTIFICACIONES TOAST Y ALERTAS DE LUJO (BODA E&L)
   ===================================================================== */
.toast-container {
  position: fixed;
  top: calc(18px + env(safe-area-inset-top, 0px));
  right: 20px;
  z-index: 100500;
  display: flex;
  flex-direction: column;
  gap: 10px;
  width: min(392px, calc(100vw - 28px));
  pointer-events: none;
}

.toast,
.toast-item {
  --toast-accent: #B8935A;
  --toast-accent-soft: rgba(184, 147, 90, 0.16);
  --toast-accent-border: rgba(184, 147, 90, 0.38);
  --toast-accent-glow: rgba(184, 147, 90, 0.28);
  --toast-icon-color: #9A7742;
  --toast-progress-bg: linear-gradient(90deg, #CFAF7A 0%, #B8935A 100%);
  --toast-duration: 4200ms;

  pointer-events: auto;
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: flex-start;
  gap: 13px;
  padding: 14px 16px 17px 15px;
  border-radius: 18px;
  background: linear-gradient(145deg, rgba(255, 254, 250, 0.96) 0%, rgba(250, 245, 236, 0.94) 100%);
  backdrop-filter: blur(18px) saturate(150%);
  -webkit-backdrop-filter: blur(18px) saturate(150%);
  border: 1px solid var(--toast-accent-border);
  box-shadow:
    0 18px 40px -10px rgba(31, 29, 27, 0.22),
    0 6px 16px -4px rgba(31, 29, 27, 0.08),
    inset 0 1px 0 rgba(255, 255, 255, 0.9);
  animation: toastSlideInRight 0.42s cubic-bezier(0.16, 1, 0.3, 1) both;
  transition: transform 0.28s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.28s ease, box-shadow 0.25s ease;
  touch-action: pan-y;
}

.toast::before,
.toast-item::before {
  content: '';
  position: absolute;
  top: 10px;
  bottom: 12px;
  left: 0;
  width: 4px;
  border-radius: 0 4px 4px 0;
  background: var(--toast-progress-bg);
}

.toast:hover,
.toast-item:hover {
  transform: translateY(-2px);
  box-shadow:
    0 22px 46px -10px rgba(31, 29, 27, 0.26),
    0 8px 20px -4px rgba(184, 147, 90, 0.16),
    inset 0 1px 0 rgba(255, 255, 255, 0.95);
}

.toast.is-leaving,
.toast-item.is-leaving {
  pointer-events: none;
  animation: toastSlideOutRight 0.3s cubic-bezier(0.4, 0, 1, 1) forwards;
}

@keyframes toastSlideInRight {
  0% {
    opacity: 0;
    transform: translate3d(38px, 0, 0) scale(0.95);
  }
  100% {
    opacity: 1;
    transform: translate3d(0, 0, 0) scale(1);
  }
}

@keyframes toastSlideOutRight {
  0% {
    opacity: 1;
    transform: translate3d(0, 0, 0) scale(1);
  }
  100% {
    opacity: 0;
    transform: translate3d(42px, 0, 0) scale(0.95);
  }
}

@keyframes toastSlideInDown {
  0% {
    opacity: 0;
    transform: translate3d(0, -24px, 0) scale(0.95);
  }
  100% {
    opacity: 1;
    transform: translate3d(0, 0, 0) scale(1);
  }
}

@keyframes toastSlideOutUp {
  0% {
    opacity: 1;
    transform: translate3d(0, 0, 0) scale(1);
  }
  100% {
    opacity: 0;
    transform: translate3d(0, -22px, 0) scale(0.95);
  }
}

@keyframes toastProgressShrink {
  from {
    transform: scaleX(1);
  }
  to {
    transform: scaleX(0);
  }
}

/* Variantes Semánticas */
.toast.toast-success,
.toast-item.success {
  --toast-accent: #2E6B3E;
  --toast-accent-soft: rgba(46, 107, 62, 0.13);
  --toast-accent-border: rgba(46, 107, 62, 0.3);
  --toast-accent-glow: rgba(46, 107, 62, 0.22);
  --toast-icon-color: #245A33;
  --toast-progress-bg: linear-gradient(90deg, #5A9468 0%, #2E6B3E 100%);
}

.toast.toast-error,
.toast-item.error {
  --toast-accent: #B52B34;
  --toast-accent-soft: rgba(181, 43, 52, 0.12);
  --toast-accent-border: rgba(181, 43, 52, 0.3);
  --toast-accent-glow: rgba(181, 43, 52, 0.2);
  --toast-icon-color: #A6242C;
  --toast-progress-bg: linear-gradient(90deg, #D9535C 0%, #B52B34 100%);
}

.toast.toast-warning,
.toast-item.warning {
  --toast-accent: #B87B1B;
  --toast-accent-soft: rgba(184, 123, 27, 0.14);
  --toast-accent-border: rgba(184, 123, 27, 0.35);
  --toast-accent-glow: rgba(184, 123, 27, 0.22);
  --toast-icon-color: #9A630D;
  --toast-progress-bg: linear-gradient(90deg, #E2A94B 0%, #B87B1B 100%);
}

.toast.toast-info,
.toast-item.info {
  --toast-accent: #B8935A;
  --toast-accent-soft: rgba(184, 147, 90, 0.16);
  --toast-accent-border: rgba(184, 147, 90, 0.4);
  --toast-accent-glow: rgba(184, 147, 90, 0.26);
  --toast-icon-color: #9A7742;
  --toast-progress-bg: linear-gradient(90deg, #CFAF7A 0%, #B8935A 60%, #9A7742 100%);
}

.toast-icon {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  flex-shrink: 0;
  display: grid;
  place-items: center;
  background: var(--toast-accent-soft);
  color: var(--toast-icon-color);
  border: 1px solid var(--toast-accent-border);
  box-shadow: 0 0 0 4px rgba(255, 255, 255, 0.55), 0 4px 12px var(--toast-accent-glow);
  margin-top: 1px;
}

.toast-icon svg {
  width: 18px;
  height: 18px;
  display: block;
}

.toast-content {
  flex: 1;
  min-width: 0;
  padding-right: 4px;
}

.toast-title {
  font-family: var(--font-serif);
  font-size: 1.08rem;
  font-weight: 700;
  line-height: 1.15;
  color: var(--color-olive-dark);
  letter-spacing: 0.01em;
  margin-bottom: 3px;
}

.toast-msg {
  font-family: var(--font-sans);
  font-size: 0.81rem;
  line-height: 1.44;
  color: var(--color-text-secondary);
  word-wrap: break-word;
}

.toast-close {
  flex-shrink: 0;
  width: 28px;
  height: 28px;
  margin: -2px -4px 0 0;
  border-radius: 50%;
  border: none;
  background: transparent;
  color: var(--color-text-muted);
  display: grid;
  place-items: center;
  cursor: pointer;
  transition: background-color 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.toast-close:hover {
  background: rgba(31, 29, 27, 0.08);
  color: var(--color-olive-dark);
  transform: scale(1.06);
}

.toast-close:active {
  transform: scale(0.94);
}

.toast-progress {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 3px;
  background: rgba(31, 29, 27, 0.07);
  overflow: hidden;
}

.toast-progress-bar {
  width: 100%;
  height: 100%;
  background: var(--toast-progress-bg);
  transform-origin: left center;
  animation: toastProgressShrink var(--toast-duration) linear forwards;
}

.toast:hover .toast-progress-bar,
.toast-item:hover .toast-progress-bar,
.toast.is-paused .toast-progress-bar,
.toast-item.is-paused .toast-progress-bar {
  animation-play-state: paused;
}

@media (max-width: 640px) {
  .toast-container {
    top: calc(12px + env(safe-area-inset-top, 0px));
    left: 50%;
    right: auto;
    transform: translateX(-50%);
    width: calc(100vw - 24px);
    max-width: 420px;
    gap: 8px;
  }

  .toast,
  .toast-item {
    padding: 13px 14px 16px 14px;
    border-radius: 16px;
    animation-name: toastSlideInDown;
  }

  .toast.is-leaving,
  .toast-item.is-leaving {
    animation-name: toastSlideOutUp;
  }

  .toast-icon {
    width: 34px;
    height: 34px;
  }

  .toast-icon svg {
    width: 16px;
    height: 16px;
  }

  .toast-title {
    font-size: 1.02rem;
  }

  .toast-msg {
    font-size: 0.79rem;
  }
}

/* Modal de Confirmación y Alerta Elegante (Reemplaza confirm() nativo) */
.app-confirm-backdrop {
  position: fixed;
  inset: 0;
  z-index: 100400;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  background: rgba(20, 26, 17, 0.64);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.28s ease, visibility 0.28s ease;
}

.app-confirm-backdrop.active {
  opacity: 1;
  visibility: visible;
}

.app-confirm-dialog {
  --confirm-accent: #B52B34;
  --confirm-accent-soft: rgba(181, 43, 52, 0.11);
  --confirm-accent-border: rgba(181, 43, 52, 0.28);
  --confirm-btn-bg: linear-gradient(135deg, #C93841 0%, #A3222B 100%);
  --confirm-btn-shadow: 0 10px 24px -6px rgba(163, 34, 43, 0.42);
  --confirm-btn-color: #FFFFFF;

  width: min(100%, 400px);
  padding: 28px 26px 26px;
  border-radius: 26px;
  text-align: center;
  background: linear-gradient(175deg, #FAF8F5 0%, #F7F1E5 100%);
  border: 1px solid rgba(184, 147, 90, 0.45);
  box-shadow:
    0 28px 64px -12px rgba(31, 29, 27, 0.42),
    0 0 0 1px rgba(255, 255, 255, 0.75) inset,
    0 0 36px rgba(184, 147, 90, 0.12);
  transform: translateY(18px) scale(0.94);
  transition: transform 0.34s cubic-bezier(0.16, 1, 0.3, 1);
}

.app-confirm-backdrop.active .app-confirm-dialog {
  transform: translateY(0) scale(1);
}

.app-confirm-dialog.is-warning {
  --confirm-accent: #A96D12;
  --confirm-accent-soft: rgba(184, 123, 27, 0.13);
  --confirm-accent-border: rgba(184, 123, 27, 0.34);
  --confirm-btn-bg: linear-gradient(135deg, #D99B38 0%, #B07213 100%);
  --confirm-btn-shadow: 0 10px 24px -6px rgba(176, 114, 19, 0.4);
  --confirm-btn-color: #FFFFFF;
}

.app-confirm-dialog.is-info {
  --confirm-accent: #9A7742;
  --confirm-accent-soft: rgba(184, 147, 90, 0.16);
  --confirm-accent-border: rgba(184, 147, 90, 0.42);
  --confirm-btn-bg: var(--gold-gradient);
  --confirm-btn-shadow: 0 10px 24px -6px rgba(184, 147, 90, 0.44);
  --confirm-btn-color: #1F1D1B;
}

.app-confirm-dialog.is-success {
  --confirm-accent: #2E6B3E;
  --confirm-accent-soft: rgba(46, 107, 62, 0.13);
  --confirm-accent-border: rgba(46, 107, 62, 0.32);
  --confirm-btn-bg: linear-gradient(135deg, #4A7C59 0%, #2E5A3B 100%);
  --confirm-btn-shadow: 0 10px 24px -6px rgba(46, 90, 59, 0.4);
  --confirm-btn-color: #FFFFFF;
}

.app-confirm-ornament {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-bottom: 16px;
  color: var(--color-gold);
  font-size: 0.72rem;
}

.app-confirm-ornament span {
  width: 34px;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(184, 147, 90, 0.65), transparent);
}

.app-confirm-ornament i {
  font-style: normal;
}

.app-confirm-icon {
  width: 60px;
  height: 60px;
  margin: 0 auto 16px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--confirm-accent-soft);
  color: var(--confirm-accent);
  border: 1px solid var(--confirm-accent-border);
  box-shadow:
    0 0 0 7px rgba(250, 248, 245, 0.9),
    0 0 0 8px var(--confirm-accent-soft);
}

.app-confirm-title {
  font-family: var(--font-serif);
  font-size: 1.72rem;
  font-weight: 700;
  line-height: 1.15;
  color: var(--color-olive-dark);
  margin-bottom: 8px;
}

.app-confirm-msg {
  font-size: 0.89rem;
  line-height: 1.55;
  color: var(--color-text-secondary);
  margin-bottom: 24px;
}

.app-confirm-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.app-confirm-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 18px;
  border-radius: var(--radius-full);
  font-family: var(--font-sans);
  font-size: 0.86rem;
  font-weight: 600;
  cursor: pointer;
  transition: transform 0.22s ease, box-shadow 0.22s ease, background-color 0.22s ease, border-color 0.22s ease;
}

.app-confirm-cancel {
  background: rgba(255, 255, 255, 0.85);
  color: var(--color-olive-dark);
  border: 1px solid rgba(31, 29, 27, 0.22);
  box-shadow: 0 2px 8px rgba(31, 29, 27, 0.05);
}

.app-confirm-cancel:hover {
  background: #FFFFFF;
  border-color: rgba(184, 147, 90, 0.55);
  transform: translateY(-1px);
}

.app-confirm-ok {
  background: var(--confirm-btn-bg);
  color: var(--confirm-btn-color);
  border: 1px solid rgba(255, 255, 255, 0.16);
  box-shadow: var(--confirm-btn-shadow);
}

.app-confirm-ok:hover {
  transform: translateY(-1px);
  filter: brightness(1.05);
}

.app-confirm-btn:active {
  transform: scale(0.97);
}

/* Alertas Inline Reutilizables (Banners Elegantes) */
.wedding-alert {
  --alert-accent: #B8935A;
  --alert-bg: linear-gradient(145deg, rgba(250, 248, 245, 0.95) 0%, rgba(249, 242, 229, 0.92) 100%);
  --alert-border: rgba(184, 147, 90, 0.38);
  --alert-icon-bg: rgba(184, 147, 90, 0.16);

  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 13px 16px;
  border-radius: 16px;
  background: var(--alert-bg);
  border: 1px solid var(--alert-border);
  border-left: 4px solid var(--alert-accent);
  box-shadow: var(--shadow-sm);
  color: var(--color-text-primary);
  font-size: 0.85rem;
  line-height: 1.48;
  text-align: left;
}

.wedding-alert-success {
  --alert-accent: #2E6B3E;
  --alert-bg: linear-gradient(145deg, rgba(246, 252, 247, 0.96) 0%, rgba(235, 246, 238, 0.94) 100%);
  --alert-border: rgba(46, 107, 62, 0.28);
  --alert-icon-bg: rgba(46, 107, 62, 0.14);
}

.wedding-alert-error {
  --alert-accent: #B52B34;
  --alert-bg: linear-gradient(145deg, rgba(255, 247, 247, 0.96) 0%, rgba(252, 237, 238, 0.94) 100%);
  --alert-border: rgba(181, 43, 52, 0.3);
  --alert-icon-bg: rgba(181, 43, 52, 0.13);
}

.wedding-alert-warning {
  --alert-accent: #B87B1B;
  --alert-bg: linear-gradient(145deg, rgba(255, 251, 242, 0.96) 0%, rgba(252, 243, 224, 0.94) 100%);
  --alert-border: rgba(184, 123, 27, 0.34);
  --alert-icon-bg: rgba(184, 123, 27, 0.15);
}

@media (prefers-reduced-motion: reduce) {
  .toast,
  .toast-item,
  .toast.is-leaving,
  .toast-item.is-leaving,
  .app-confirm-dialog {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
}

/* Lightbox Inmersivo */
.lightbox-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(14, 5, 8, 0.95);
  backdrop-filter: blur(12px);
  z-index: 2500;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.lightbox-backdrop.active {
  display: flex;
}

.lightbox-content {
  max-width: 90vw;
  max-height: 86vh;
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.lightbox-media {
  max-width: 100%;
  max-height: 75vh;
  border-radius: var(--radius-sm);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.8);
}

.lightbox-info {
  margin-top: 14px;
  color: #FFFFFF;
  display: flex;
  align-items: center;
  gap: 20px;
}

.lightbox-close {
  position: absolute;
  top: -45px;
  right: 0;
  background: transparent;
  border: none;
  color: #FFFFFF;
  font-size: 2rem;
  cursor: pointer;
  line-height: 1;
}

/* =====================================================================
   BOTTOM NAVIGATION BAR (Optimizado para Teléfonos / Escaneo QR Móvil)
   ===================================================================== */
.mobile-app-nav {
  display: none;
}

/* Responsive Breakpoints */
@media (max-width: 768px) {
  body {
    padding-bottom: 0;
    margin: 0;
  }

  .page-hero-header {
    padding: 88px 16px 24px;
  }

  /* ==================== CARRUSEL NUESTRA HISTORIA EN MÓVIL ==================== */
  .story-carousel-container {
    margin: 0 auto 20px !important;
    border-radius: 16px !important;
  }

  /* Foto principal en foco: más alta y cinematográfica en proporción vertical portrait */
  .story-stage {
    aspect-ratio: 4 / 5 !important;
    min-height: 480px !important;
    max-height: 560px !important;
  }

  /* Botones de navegación: elevados al 36% para que NUNCA tapen el título ni el texto */
  .story-nav-btn {
    top: 36% !important;
    transform: translateY(-50%) !important;
    width: 42px !important;
    height: 42px !important;
    background: rgba(31, 29, 27, 0.5) !important;
    border: 1px solid rgba(255, 255, 255, 0.45) !important;
    backdrop-filter: blur(10px) !important;
    -webkit-backdrop-filter: blur(10px) !important;
    color: #FFFFFF !important;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.3) !important;
    z-index: 25 !important;
  }

  .story-prev {
    left: 12px !important;
  }

  .story-next {
    right: 12px !important;
  }

  /* Degradado suave inferior para máxima legibilidad sin invadir la foto */
  .story-slide-overlay {
    padding: 24px 18px 22px !important;
    background: linear-gradient(to top, rgba(31, 29, 27, 0.95) 0%, rgba(31, 29, 27, 0.65) 45%, rgba(31, 29, 27, 0.1) 75%, transparent 100%) !important;
  }

  .story-slide-card {
    max-width: 100% !important;
  }

  .story-slide-title {
    font-size: 1.65rem !important;
    line-height: 1.2 !important;
    margin-bottom: 6px !important;
  }

  .story-slide-desc {
    font-size: 0.88rem !important;
    line-height: 1.45 !important;
    color: rgba(255, 255, 255, 0.9) !important;
  }

  .story-slide-tag {
    font-size: 0.72rem !important;
    padding: 3px 12px !important;
    margin-bottom: 8px !important;
  }

  .story-thumbnails-wrapper {
    padding: 4px 8px 16px !important;
  }

  .story-thumb-item {
    width: 95px !important;
    height: 70px !important;
    border-radius: 10px !important;
  }

  .story-thumb-num {
    font-size: 0.65rem !important;
  }

  .hero-bg-frame {
    inset: 0;
    border-radius: 0;
    border: none;
  }
  .guestbook-layout {
    grid-template-columns: 1fr;
    gap: 24px;
  }
  .upload-main-section {
    padding: 36px 14px 20px;
  }
  .upload-card-wrapper {
    border-radius: 18px;
  }
  .guest-status-banner {
    padding: 12px 14px;
    flex-wrap: wrap;
    gap: 8px 12px;
  }
  .guest-info-side {
    gap: 10px;
    flex: 1 1 180px;
  }
  .guest-avatar {
    width: 34px;
    height: 34px;
  }
  .guest-album-tag {
    font-size: 0.64rem;
  }
  .guest-album-title {
    font-size: 0.88rem;
    line-height: 1.25;
  }
  .quota-pill {
    padding: 4px 10px;
    font-size: 0.72rem;
    margin-left: auto;
  }
  .upload-dropzone {
    padding: 28px 14px 24px;
    margin: 14px;
    border-radius: 16px;
  }
  .dropzone-icon-circle {
    width: 56px;
    height: 56px;
    margin-bottom: 12px;
  }
  .dropzone-icon-circle svg {
    width: 32px;
    height: 32px;
  }
  .dropzone-title {
    font-size: 1.25rem;
  }
  .dropzone-subtitle {
    font-size: 0.8rem;
    margin-bottom: 18px;
  }
  .upload-two-buttons {
    flex-direction: row;
    gap: 10px;
    width: 100%;
  }
  .btn-upload-gallery,
  .btn-upload-camera {
    flex: 1 1 0;
    min-height: 44px;
    padding: 10px 8px;
    font-size: 0.82rem;
    gap: 6px;
    border-radius: 24px;
  }
  .btn-action-icon svg {
    width: 17px;
    height: 17px;
  }
}

/* Teléfonos móviles: Formato adaptable */
@media (max-width: 680px) {
  .section-wrapper {
    padding: 40px 14px;
  }
  .section-title {
    font-size: 2rem;
  }
  .gallery-tabs {
    gap: 6px;
    margin-bottom: 20px;
    flex-wrap: wrap;
  }
  .tab-btn {
    padding: 8px 16px;
    font-size: 0.8rem;
  }
  .gallery-grid {
    column-count: 2;
    column-gap: 12px;
    max-width: 100%;
    margin: 0 auto;
  }
  .media-card {
    margin-bottom: 12px;
  }
  .media-card-footer {
    padding: 10px 12px;
  }
  .media-author-name {
    max-width: 130px;
    font-size: 0.82rem;
  }
  .btn-like {
    min-height: 32px;
    padding: 4px 10px;
    font-size: 0.82rem;
  }
  .btn-icon-action {
    width: 32px;
    height: 32px;
  }
}

@media (max-width: 380px) {
  .gallery-grid {
    column-count: 1;
    column-gap: 0;
  }
}

/* =====================================================================
   TARJETA Y BOTONES DE CAPTURA DIRECTA EN EL ÁLBUM (Foto / Video)
   ===================================================================== */
.album-capture-card {
  max-width: 900px;
  margin: 0 auto 36px;
  padding: 24px 28px;
  border-radius: var(--radius-lg);
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.95), rgba(250, 244, 236, 0.9));
  border: 1px solid rgba(184, 147, 90, 0.35);
  box-shadow: var(--shadow-card);
  text-align: center;
}

.album-capture-header {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  margin-bottom: 20px;
  text-align: left;
}

.album-capture-icon {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--gold-gradient);
  display: grid;
  place-items: center;
  color: #1F1D1B;
  flex-shrink: 0;
  box-shadow: var(--gold-glow);
}

.album-capture-title {
  font-family: var(--font-serif);
  font-size: 1.35rem;
  font-weight: 600;
  color: var(--color-burgundy);
  line-height: 1.2;
}

.album-capture-sub {
  font-size: 0.86rem;
  color: var(--color-text-secondary);
}

/* =====================================================================
   MODAL DE CÁMARA EN VIVO (VISOR DIRECTO PARA FOTOS Y VIDEOS)
   ===================================================================== */
.camera-modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 10000;
  background: rgba(10, 6, 8, 0.94);
  backdrop-filter: blur(14px);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 12px;
}

.camera-modal-backdrop.active {
  display: flex;
}

.camera-modal-container {
  background: #140D0E;
  border: 1px solid rgba(184, 147, 90, 0.45);
  border-radius: var(--radius-lg);
  width: 100%;
  max-width: 520px;
  max-height: 94vh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.8), var(--gold-glow);
  position: relative;
  animation: cameraModalIn 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes cameraModalIn {
  from { opacity: 0; transform: scale(0.95) translateY(12px); }
  to { opacity: 1; transform: scale(1) translateY(0); }
}

.camera-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 18px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(0, 0, 0, 0.3);
}

.camera-title-wrap {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-serif);
  font-size: 1.1rem;
  color: #FFFFFF;
  font-weight: 600;
}

.camera-live-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #4ADE80;
  box-shadow: 0 0 10px #4ADE80;
  animation: pulseLiveDot 2s infinite;
}

@keyframes pulseLiveDot {
  0%, 100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.3); opacity: 0.6; }
}

.camera-header-actions {
  display: flex;
  gap: 8px;
}

.camera-icon-btn {
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: #FFFFFF;
  border-radius: 50%;
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  cursor: pointer;
  transition: all 0.2s ease;
}

.camera-icon-btn:hover {
  background: rgba(184, 147, 90, 0.25);
  border-color: var(--color-gold);
  color: var(--color-gold-light);
}

.camera-viewport-wrap {
  position: relative;
  width: 100%;
  aspect-ratio: 4/3;
  background: #000000;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}

#cameraVideo {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.camera-flash {
  position: absolute;
  inset: 0;
  background: #FFFFFF;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.12s ease;
  z-index: 10;
}

.camera-flash.flash-active {
  opacity: 0.95;
}

.camera-rec-badge {
  position: absolute;
  bottom: 14px;
  right: calc(14px + env(safe-area-inset-right, 0px));
  background: rgba(185, 28, 28, 0.92);
  color: #FFFFFF;
  font-size: 0.78rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  padding: 5px 12px;
  border-radius: 20px;
  display: flex;
  align-items: center;
  gap: 6px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.45);
  z-index: 12;
  pointer-events: none;
}

.rec-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #FFFFFF;
  animation: blinkRecDot 1s infinite;
}

@keyframes blinkRecDot {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.2; }
}

.camera-preview-overlay {
  position: absolute;
  inset: 0;
  background: #000000;
  z-index: 8;
  display: flex;
  flex-direction: column;
}

#cameraPreviewImg, #cameraPreviewVideo {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.camera-preview-bar {
  position: absolute;
  bottom: 14px;
  left: 0;
  right: 0;
  display: flex;
  justify-content: center;
  gap: 14px;
  padding: 0 16px;
  z-index: 9;
}

.camera-controls-panel {
  padding: 16px 20px 20px;
  background: #140D0E;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

.camera-mode-tabs {
  display: flex;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 24px;
  padding: 3px;
  gap: 4px;
}

.camera-mode-btn {
  border: none;
  background: transparent;
  color: rgba(255, 255, 255, 0.65);
  padding: 5px 18px;
  border-radius: 20px;
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}

.camera-mode-btn.active {
  background: var(--gold-gradient);
  color: #221203;
  box-shadow: 0 2px 8px rgba(184, 147, 90, 0.3);
}

.camera-shutter-row {
  margin: 6px 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.camera-shutter-btn {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  border: 4px solid #FFFFFF;
  background: transparent;
  display: grid;
  place-items: center;
  cursor: pointer;
  transition: all 0.2s ease;
  box-shadow: 0 0 20px rgba(255, 255, 255, 0.25);
}

.shutter-inner {
  width: 54px;
  height: 54px;
  border-radius: 50%;
  background: var(--gold-gradient);
  display: block;
  transition: transform 0.15s ease;
}

.camera-shutter-btn:active .shutter-inner {
  transform: scale(0.88);
}

.camera-record-btn {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  border: 4px solid #FFFFFF;
  background: transparent;
  display: grid;
  place-items: center;
  cursor: pointer;
  transition: all 0.2s ease;
  box-shadow: 0 0 20px rgba(220, 38, 38, 0.4);
}

.record-inner {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: #EF4444;
  display: block;
  transition: all 0.2s ease;
}

.camera-record-btn.recording .record-inner {
  border-radius: 8px;
  width: 32px;
  height: 32px;
  animation: pulseRecordBox 1s infinite;
}

@keyframes pulseRecordBox {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(0.9); }
}

.camera-native-fallback {
  text-align: center;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding-top: 12px;
  width: 100%;
}

.camera-native-title {
  display: block;
  font-size: 0.74rem;
  color: rgba(255, 255, 255, 0.65);
  margin-bottom: 8px;
}

.camera-native-buttons {
  display: flex;
  gap: 10px;
  justify-content: center;
}

.camera-pill-btn {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(184, 147, 90, 0.4);
  color: var(--color-gold-light);
  font-size: 0.78rem;
  font-weight: 600;
  padding: 6px 14px;
  border-radius: 20px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.camera-pill-btn:hover {
  background: rgba(184, 147, 90, 0.22);
  border-color: var(--color-gold);
  color: #FFFFFF;
}

/* =====================================================================
   ACTION SHEET MÓVIL PARA CÁMARA (NATIVA Y FLUIDA)
   ===================================================================== */
.mobile-sheet-backdrop {
  position: fixed;
  inset: 0;
  z-index: 10001;
  background: rgba(15, 8, 10, 0.75);
  backdrop-filter: blur(10px);
  display: none;
  align-items: flex-end;
  justify-content: center;
  transition: opacity 0.25s ease;
}

.mobile-sheet-backdrop.active {
  display: flex;
}

.mobile-sheet-card {
  width: 100%;
  max-width: 520px;
  background: #FFFFFF;
  border-radius: 28px 28px 0 0;
  padding: 16px 20px 28px;
  box-shadow: 0 -10px 40px rgba(0, 0, 0, 0.35);
  animation: slideUpSheet 0.28s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  flex-direction: column;
  gap: 16px;
}

@keyframes slideUpSheet {
  from { transform: translateY(100%); }
  to { transform: translateY(0); }
}

.mobile-sheet-drag-handle {
  width: 44px;
  height: 5px;
  background: rgba(0, 0, 0, 0.15);
  border-radius: 10px;
  margin: 0 auto 4px;
}

.mobile-sheet-head {
  text-align: center;
}

.mobile-sheet-title {
  font-family: var(--font-serif);
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--color-burgundy);
  margin-bottom: 4px;
}

.mobile-sheet-desc {
  font-size: 0.85rem;
  color: var(--color-text-secondary);
}

.mobile-sheet-options {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.mobile-sheet-btn {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px 18px;
  border-radius: var(--radius-md);
  border: 1.5px solid transparent;
  cursor: pointer;
  text-align: left;
  transition: all 0.2s ease;
  width: 100%;
}

.sheet-btn-primary {
  background: linear-gradient(135deg, #FFF8ED 0%, #FDF2E0 100%);
  border-color: rgba(184, 147, 90, 0.6);
  color: var(--color-burgundy);
}

.sheet-btn-primary:active {
  transform: scale(0.98);
  background: #F8E6C8;
}

.sheet-btn-burgundy {
  background: linear-gradient(135deg, #F4F6F2 0%, #E8EDE4 100%);
  border-color: rgba(31, 29, 27, 0.25);
  color: var(--color-burgundy);
}

.sheet-btn-burgundy:active {
  transform: scale(0.98);
  background: #DCE4D6;
}

.sheet-btn-icon {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background: var(--gold-gradient);
  display: grid;
  place-items: center;
  color: #1F1D1B;
  flex-shrink: 0;
  box-shadow: 0 4px 12px rgba(184, 147, 90, 0.35);
}

.sheet-btn-burgundy .sheet-btn-icon {
  background: linear-gradient(135deg, var(--color-burgundy-light), var(--color-burgundy-dark));
  color: #FFFFFF;
  box-shadow: 0 4px 12px rgba(31, 29, 27, 0.3);
}

.sheet-btn-text strong {
  display: block;
  font-size: 1rem;
  font-weight: 700;
  color: var(--color-burgundy);
  margin-bottom: 2px;
}

.sheet-btn-text span {
  display: block;
  font-size: 0.78rem;
  color: var(--color-text-secondary);
}

.mobile-sheet-cancel {
  background: #F5F1EB;
  border: none;
  border-radius: var(--radius-md);
  padding: 14px;
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--color-text-secondary);
  cursor: pointer;
  transition: background 0.2s;
  width: 100%;
}

.mobile-sheet-cancel:active {
  background: #E8E2D8;
}


/* =====================================================================
   PRELOADER INTERACTIVO DE LUJO (INSPIRADO EN WEDDING.JONGJEONGLEE.COM)
   Monograma EyL (Elena & Lucas) y Anillo Circular Progresivo
   ===================================================================== */
#interactive-preloader {
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100vh;
  height: 100dvh;
  background-color: #FAF8F5;
  z-index: 999999;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  transition: opacity 0.28s cubic-bezier(0.16, 1, 0.3, 1), visibility 0.28s cubic-bezier(0.16, 1, 0.3, 1);
  overflow: hidden;
  touch-action: none;
  cursor: pointer;
}

#interactive-preloader.is-hidden {
  opacity: 0 !important;
  visibility: hidden !important;
  pointer-events: none !important;
}

.preloader-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  animation: preloaderFloat 3s ease-in-out infinite alternate;
}

@keyframes preloaderFloat {
  0% { transform: translateY(0); }
  100% { transform: translateY(-4px); }
}

#preloader-svg {
  width: clamp(165px, 34vw, 220px);
  height: clamp(165px, 34vw, 220px);
  filter: drop-shadow(0 12px 28px rgba(184, 147, 90, 0.18));
}

#preloader-ring-circle {
  transition: stroke-dashoffset 0.15s linear;
  filter: drop-shadow(0 0 6px rgba(184, 147, 90, 0.45));
}

#preloader-percentage {
  font-family: var(--font-serif);
  font-size: clamp(1.2rem, 3.8vw, 1.5rem);
  color: #1F1D1B;
  letter-spacing: 4px;
  font-weight: 600;
  margin-top: -6px;
  transition: color 0.3s ease;
}

#pl-skip-btn {
  font-family: var(--font-sans);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: #6E665E;
  background: rgba(255, 255, 255, 0.85);
  border: 1px solid rgba(184, 147, 90, 0.35);
  padding: 8px 24px;
  border-radius: 9999px;
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(31, 29, 27, 0.06);
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  backdrop-filter: blur(8px);
}

#pl-skip-btn:hover {
  color: #1F1D1B;
  border-color: var(--color-gold);
  background: #FFFFFF;
  transform: translateY(-1.5px);
  box-shadow: 0 6px 18px rgba(184, 147, 90, 0.2);
}

body.loading {
  overflow: hidden !important;
}

body.loading.app-page-enter {
  animation: none !important;
  opacity: 1 !important;
}

@media (prefers-reduced-motion: reduce) {
  #interactive-preloader {
    transition: none;
  }
  .preloader-inner {
    animation: none;
  }
  #preloader-ring-circle {
    transition: none;
  }
}

/* =====================================================================
   DISEÑO DE GALERÍA DE ALTA GAMA (ESTILO WEDDING.JONGJEONGLEE.COM)
   ===================================================================== */
.gallery-screen-header {
  padding: 120px 20px 24px;
  text-align: center;
  max-width: 900px;
  margin: 0 auto;
}

@media (max-width: 768px) {
  .gallery-screen-header {
    padding: 32px 16px 20px;
  }
}

.gallery-screen-header .gallery-title {
  font-family: var(--font-serif);
  font-size: clamp(2.2rem, 5.5vw, 3.4rem);
  font-weight: 600;
  color: #1F1D1B;
  letter-spacing: 6px;
  text-transform: uppercase;
  margin-bottom: 8px;
  line-height: 1.1;
}

.gallery-screen-header .gallery-subtitle {
  font-family: var(--font-sans);
  font-size: 0.82rem;
  font-weight: 400;
  letter-spacing: 2.2px;
  text-transform: uppercase;
  color: #6E665E;
  margin-bottom: 26px;
}

.gallery-upload-area {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 24px;
}

.btn-gallery-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 11px 22px;
  border-radius: 999px;
  font-family: var(--font-sans);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  cursor: pointer;
  transition: all 0.28s cubic-bezier(0.16, 1, 0.3, 1);
  text-decoration: none;
}

.btn-gallery-upload {
  background: #1F1D1B;
  color: #FAF8F5;
  border: 1px solid #1F1D1B;
  box-shadow: 0 4px 16px rgba(31, 29, 27, 0.18);
}

.btn-gallery-upload:hover {
  background: #2E2A27;
  border-color: #2E2A27;
  color: #FFFFFF;
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(31, 29, 27, 0.25);
}

.btn-gallery-camera {
  background: #FFFFFF;
  color: #1F1D1B;
  border: 1px solid rgba(184, 147, 90, 0.45);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.04);
}

.btn-gallery-camera:hover {
  border-color: var(--color-gold);
  background: #FAF8F5;
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(184, 147, 90, 0.18);
}

.btn-gallery-refresh {
  background: #FFFFFF;
  color: #6E665E;
  border: 1px solid rgba(0, 0, 0, 0.12);
  padding: 11px 15px;
}

.btn-gallery-refresh:hover {
  color: #1F1D1B;
  border-color: var(--color-gold);
}

/* Pestañas de filtro minimalistas de lujo */
.gallery-tabs-row {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 5px 8px;
  background: rgba(255, 255, 255, 0.8);
  backdrop-filter: blur(12px);
  border: 1px solid rgba(184, 147, 90, 0.28);
  border-radius: 999px;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.04);
  margin: 0 auto;
}

.gallery-tab-item {
  padding: 8px 18px;
  border-radius: 999px;
  font-family: var(--font-sans);
  font-size: 0.74rem;
  font-weight: 600;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  color: #6E665E;
  background: transparent;
  border: none;
  cursor: pointer;
  transition: all 0.25s ease;
}

.gallery-tab-item:hover {
  color: #1F1D1B;
}

.gallery-tab-item.active {
  background: var(--gold-gradient);
  color: #241A0B;
  box-shadow: 0 3px 10px rgba(184, 147, 90, 0.28);
  font-weight: 700;
}

/* Contenedor del Grid */
.gallery-grid-wrap {
  width: 100%;
  max-width: 1180px;
  margin: 0 auto;
  padding: 10px 16px 80px;
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 6px;
  width: 100%;
}

@media (min-width: 768px) {
  .gallery-grid {
    grid-template-columns: repeat(auto-fill, minmax(175px, 1fr));
    gap: 8px;
  }
}

@media (min-width: 1200px) {
  .gallery-grid {
    grid-template-columns: repeat(auto-fill, minmax(195px, 1fr));
    gap: 10px;
  }
}

@media (max-width: 480px) {
  .gallery-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 4px;
  }
}

.gallery-grid-item {
  position: relative;
  aspect-ratio: 1;
  overflow: hidden;
  background: #EAE6DF;
  border-radius: 4px;
  cursor: pointer;
  opacity: 0;
  transform: translateY(16px) scale(0.97);
  transition: opacity 0.5s cubic-bezier(0.16, 1, 0.3, 1), transform 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.gallery-grid-item.visible {
  opacity: 1;
  transform: translateY(0) scale(1);
}

.gallery-item-aspect {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
}

.gallery-item-media {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.45s cubic-bezier(0.16, 1, 0.3, 1);
}

.gallery-grid-item:hover .gallery-item-media {
  transform: scale(1.07);
}

.gallery-video-indicator {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 26px;
  height: 26px;
  background: rgba(0, 0, 0, 0.65);
  backdrop-filter: blur(4px);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #FFFFFF;
  z-index: 2;
  pointer-events: none;
}

.gallery-item-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 8px;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.7) 0%, rgba(0, 0, 0, 0.1) 45%, transparent 70%);
  opacity: 0;
  transition: opacity 0.3s ease;
  z-index: 3;
}

.gallery-grid-item:hover .gallery-item-overlay {
  opacity: 1;
}

@media (hover: none) {
  .gallery-item-overlay {
    opacity: 1;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.65) 0%, transparent 50%);
  }
}

.gallery-overlay-top {
  display: flex;
  justify-content: flex-end;
}

.gallery-owner-badge {
  background: rgba(229, 57, 53, 0.85);
  color: #FFFFFF;
  border: none;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: transform 0.2s;
}

.gallery-owner-badge:hover {
  transform: scale(1.15);
}

.gallery-overlay-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
}

.gallery-item-author {
  font-family: var(--font-sans);
  font-size: 0.72rem;
  color: #FFFFFF;
  font-weight: 500;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.8);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 65%;
}

.gallery-item-like {
  background: rgba(255, 255, 255, 0.2);
  backdrop-filter: blur(4px);
  border: 1px solid rgba(255, 255, 255, 0.3);
  color: #FFFFFF;
  border-radius: 999px;
  padding: 2px 7px;
  font-size: 0.68rem;
  display: flex;
  align-items: center;
  gap: 3px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.gallery-item-like.liked {
  background: #E53935;
  border-color: #E53935;
  color: #FFFFFF;
}

.gallery-item-like:hover {
  transform: scale(1.1);
}

/* Estado de Carga y Vacío */
.gallery-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 70px 20px;
  text-align: center;
  color: #6E665E;
}

.gallery-empty-icon {
  color: var(--color-gold);
  margin-bottom: 12px;
  opacity: 0.8;
}

.gallery-empty-title {
  font-family: var(--font-serif);
  font-size: clamp(1.4rem, 4vw, 1.8rem);
  font-weight: 600;
  color: #1F1D1B;
  margin-bottom: 6px;
}

.gallery-empty-desc {
  font-family: var(--font-sans);
  font-size: 0.85rem;
  color: #6E665E;
  max-width: 380px;
  line-height: 1.5;
}

.gallery-spinner {
  width: 34px;
  height: 34px;
  border: 2.5px solid rgba(184, 147, 90, 0.2);
  border-top-color: #B8935A;
  border-radius: 50%;
  animation: gallerySpin 0.8s linear infinite;
  margin-bottom: 16px;
}

@keyframes gallerySpin {
  to { transform: rotate(360deg); }
}

/* Scroll Infinito y Botón de Respaldo en Galería */
.gallery-pagination-footer {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 26px 16px 14px;
  width: 100%;
}

.gallery-load-more-indicator {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-family: var(--font-sans);
  font-size: 0.78rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #6E665E;
  padding: 6px 14px;
}

.gallery-spinner-sm {
  width: 18px;
  height: 18px;
  border-width: 2px;
  margin-bottom: 0;
  flex-shrink: 0;
}

.btn-gallery-load-more {
  background: #FFFFFF;
  color: #1F1D1B;
  border: 1px solid rgba(184, 147, 90, 0.45);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.04);
  font-size: 0.82rem;
  padding: 11px 24px;
}

.btn-gallery-load-more:hover {
  border-color: var(--color-gold);
  background: #FAF8F5;
  color: #1F1D1B;
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(184, 147, 90, 0.18);
}

.btn-gallery-load-more:disabled {
  opacity: 0.6;
  cursor: wait;
  transform: none;
}

.gallery-sentinel {
  width: 100%;
  height: 1px;
  pointer-events: none;
}

/* =====================================================================
   LIGHTBOX ESTILO INSTAGRAM DE PANTALLA COMPLETA
   ===================================================================== */
.gallery-lightbox {
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100vh;
  height: 100dvh;
  background: rgba(8, 10, 8, 0.98);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  z-index: 100000;
  display: none;
  flex-direction: column;
  justify-content: space-between;
  align-items: stretch;
  opacity: 0;
  transition: opacity 0.28s ease;
  user-select: none;
  overflow: hidden;
}

.gallery-lightbox.active {
  display: flex !important;
  opacity: 1 !important;
}

/* Cabecera superior estilo Instagram */
.lightbox-header {
  flex-shrink: 0;
  width: 100%;
  padding: calc(12px + env(safe-area-inset-top, 0px)) 16px 12px;
  background: rgba(12, 15, 11, 0.92);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  z-index: 100005;
}

.lightbox-header-inner,
.lightbox-bottom-inner {
  width: 100%;
  max-width: 820px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.lightbox-user {
  display: flex;
  align-items: center;
  gap: 11px;
  min-width: 0;
  flex: 1;
}

.lightbox-avatar {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  flex-shrink: 0;
  background: linear-gradient(145deg, #273322 0%, #151C12 100%);
  color: var(--color-gold-light);
  font-family: var(--font-sans);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  display: grid;
  place-items: center;
  border: 2px solid transparent;
  background-image:
    linear-gradient(145deg, #253020, #141A11),
    linear-gradient(135deg, #E2D9CC 0%, #B8935A 55%, #9A7742 100%);
  background-origin: border-box;
  background-clip: padding-box, border-box;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.35);
}

.lightbox-user-info {
  display: flex;
  flex-direction: column;
  min-width: 0;
  gap: 1px;
}

.lightbox-author {
  font-family: var(--font-sans);
  font-size: 0.92rem;
  font-weight: 600;
  color: #FFFFFF;
  letter-spacing: 0.01em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.25;
}

.lightbox-time {
  font-family: var(--font-sans);
  font-size: 0.73rem;
  font-weight: 400;
  color: rgba(255, 255, 255, 0.56);
  line-height: 1.2;
}

.lightbox-header-right {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.lightbox-counter {
  font-family: var(--font-sans);
  font-size: 0.72rem;
  letter-spacing: 0.06em;
  color: rgba(255, 255, 255, 0.78);
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
}

.gallery-lightbox .lightbox-close {
  position: static;
  top: auto;
  right: auto;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.14);
  color: #FFFFFF;
  display: grid;
  place-items: center;
  cursor: pointer;
  z-index: 100005;
  transition: background 0.2s ease, transform 0.15s ease;
}

.gallery-lightbox .lightbox-close:hover {
  background: rgba(255, 255, 255, 0.18);
  transform: scale(1.06);
}

.gallery-lightbox .lightbox-close:active {
  transform: scale(0.94);
}

/* Escenario central del recuerdo */
.lightbox-media-container {
  flex: 1;
  min-height: 0;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  padding: 10px 0;
  overflow: hidden;
}

.lightbox-media {
  max-width: min(100%, 960px);
  max-height: 100%;
  width: auto;
  height: auto;
  object-fit: contain;
  border-radius: 4px;
  box-shadow: 0 18px 52px rgba(0, 0, 0, 0.65);
  animation: lightboxZoom 0.28s cubic-bezier(0.16, 1, 0.3, 1);
}

@media (max-width: 768px) {
  .lightbox-media-container {
    padding: 0;
  }
  .lightbox-media {
    max-width: 100%;
    border-radius: 0;
    box-shadow: none;
  }
}

@keyframes lightboxZoom {
  from { opacity: 0; transform: scale(0.97); }
  to { opacity: 1; transform: scale(1); }
}

.lightbox-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: rgba(10, 12, 10, 0.52);
  border: 1px solid rgba(255, 255, 255, 0.18);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  color: #FFFFFF;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 100004;
  transition: background 0.2s ease, transform 0.18s ease;
}

.lightbox-nav:hover {
  background: rgba(255, 255, 255, 0.22);
  transform: translateY(-50%) scale(1.08);
}

.lightbox-prev {
  left: 14px;
}

.lightbox-next {
  right: 14px;
}

@media (max-width: 600px) {
  .lightbox-nav { width: 34px; height: 34px; background: rgba(0, 0, 0, 0.38); }
  .lightbox-prev { left: 8px; }
  .lightbox-next { right: 8px; }
}

/* Corazón central para doble toque estilo Instagram */
.lightbox-heart-burst {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 92px;
  height: 92px;
  color: #FFFFFF;
  filter: drop-shadow(0 6px 22px rgba(0, 0, 0, 0.55));
  pointer-events: none;
  opacity: 0;
  transform: translate(-50%, -50%) scale(0.4);
  z-index: 100006;
}

.lightbox-heart-burst.is-bursting {
  animation: igHeartBurst 0.78s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes igHeartBurst {
  0% { opacity: 0; transform: translate(-50%, -50%) scale(0.4); }
  22% { opacity: 0.96; transform: translate(-50%, -50%) scale(1.16); }
  45% { opacity: 0.96; transform: translate(-50%, -50%) scale(0.96); }
  72% { opacity: 0.92; transform: translate(-50%, -50%) scale(1.02); }
  100% { opacity: 0; transform: translate(-50%, -50%) scale(1.22); }
}

/* Barra inferior de iconos estilo Instagram */
.lightbox-bottom {
  flex-shrink: 0;
  width: 100%;
  padding: 10px 16px calc(14px + env(safe-area-inset-bottom, 0px));
  background: rgba(12, 15, 11, 0.94);
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  z-index: 100005;
}

.lightbox-actions-row {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.lightbox-actions-left,
.lightbox-actions-right {
  display: flex;
  align-items: center;
  gap: 6px;
}

.lightbox-icon-btn {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  border: none;
  background: transparent;
  color: #F5F5F5;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  text-decoration: none;
  padding: 0;
  transition: color 0.18s ease, background 0.18s ease, transform 0.14s ease;
  -webkit-tap-highlight-color: transparent;
}

.lightbox-icon-btn:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #FFFFFF;
}

.lightbox-icon-btn:active {
  transform: scale(0.88);
}

.lightbox-like .lb-heart-svg {
  transition: transform 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275), fill 0.18s ease, stroke 0.18s ease;
}

.lightbox-like.liked {
  color: #FF3040;
}

.lightbox-like.liked .lb-heart-svg {
  fill: #FF3040;
  stroke: #FF3040;
  animation: lbHeartPop 0.36s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

@keyframes lbHeartPop {
  0% { transform: scale(1); }
  40% { transform: scale(1.28); }
  75% { transform: scale(0.92); }
  100% { transform: scale(1); }
}

.lightbox-likes-text {
  display: inline-flex;
  align-items: baseline;
  gap: 5px;
  font-family: var(--font-sans);
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.92);
  padding-right: 4px;
}

.lightbox-likes-text strong {
  font-weight: 700;
  color: #FFFFFF;
}

.lightbox-likes-text span {
  font-weight: 400;
  color: rgba(255, 255, 255, 0.68);
  font-size: 0.84rem;
}

.lightbox-download {
  color: #F5F5F5;
}

.lightbox-download.is-downloading,
.btn-download-single.is-downloading {
  opacity: 0.55;
  pointer-events: none;
  animation: lightboxDownloadPulse 0.9s ease-in-out infinite;
}

@keyframes lightboxDownloadPulse {
  0%, 100% { opacity: 0.55; }
  50% { opacity: 0.9; }
}

@media (prefers-reduced-motion: reduce) {
  .lightbox-download.is-downloading,
  .btn-download-single.is-downloading {
    animation: none;
  }
}

.lightbox-delete {
  color: #FF7875;
}

.lightbox-delete:hover {
  background: rgba(255, 59, 48, 0.16);
  color: #FF4D4F;
}

/* =====================================================================
   CARRUSEL INTERACTIVO DE LOS NOVIOS (SHOWCASE CON SELECTOR DE MINIATURAS)
   Diseño de Alta Gama con Relieves Dorados y Efectos de Profundidad No-Planos
   ===================================================================== */
.story-showcase-section {
  padding-top: 60px;
  padding-bottom: 70px;
}

.story-carousel-container {
  position: relative;
  max-width: 1040px;
  margin: 0 auto 28px;
  border-radius: 20px;
  overflow: hidden;
  background: #171E14;
  box-shadow: 0 24px 60px -10px rgba(31, 29, 27, 0.28), 0 0 0 1px rgba(184, 147, 90, 0.35);
  user-select: none;
}

.story-timer-bar {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: rgba(255, 255, 255, 0.15);
  z-index: 25;
}

.story-timer-fill {
  height: 100%;
  width: 0%;
  background: var(--gold-gradient);
  box-shadow: 0 0 10px rgba(184, 147, 90, 0.8);
  transition: width 0.1s linear;
}

.story-stage {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 10;
  min-height: 340px;
  max-height: 560px;
  overflow: hidden;
}

@media (max-width: 600px) {
  .story-stage {
    aspect-ratio: 4 / 3;
    min-height: 320px;
  }
}

.story-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  visibility: hidden;
  transform: scale(1.04);
  transition: opacity 0.75s cubic-bezier(0.16, 1, 0.3, 1), transform 0.85s cubic-bezier(0.16, 1, 0.3, 1), visibility 0.75s;
  z-index: 1;
}

.story-slide.active {
  opacity: 1;
  visibility: visible;
  transform: scale(1);
  z-index: 2;
}

.story-slide-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 30%;
  display: block;
}

.story-slide-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(31, 29, 27, 0.92) 0%, rgba(31, 29, 27, 0.4) 45%, transparent 75%);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 34px 44px;
}

@media (max-width: 600px) {
  .story-slide-overlay {
    padding: 22px 20px;
  }
}

.story-slide-card {
  max-width: 620px;
  animation: slideTextUp 0.6s cubic-bezier(0.16, 1, 0.3, 1) both;
}

@keyframes slideTextUp {
  from { opacity: 0; transform: translateY(18px); }
  to { opacity: 1; transform: translateY(0); }
}

.story-slide-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 14px;
  border-radius: 999px;
  background: rgba(184, 147, 90, 0.2);
  border: 1px solid rgba(184, 147, 90, 0.45);
  color: var(--color-gold-light);
  font-family: var(--font-sans);
  font-size: 0.72rem;
  letter-spacing: 2px;
  text-transform: uppercase;
  font-weight: 600;
  margin-bottom: 10px;
  backdrop-filter: blur(8px);
}

.story-slide-title {
  font-family: var(--font-serif);
  font-size: clamp(1.8rem, 4.2vw, 2.7rem);
  font-weight: 600;
  color: #FFFFFF;
  margin-bottom: 8px;
  line-height: 1.15;
  letter-spacing: -0.01em;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.6);
}

.story-slide-desc {
  font-family: var(--font-sans);
  font-size: clamp(0.85rem, 2vw, 1rem);
  color: rgba(255, 255, 255, 0.85);
  line-height: 1.5;
  font-weight: 300;
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.8);
}

/* Controles de navegación del carrusel */
.story-nav-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.35);
  backdrop-filter: blur(10px);
  color: #FFFFFF;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 20;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.25);
}

.story-nav-btn:hover {
  background: rgba(184, 147, 90, 0.45);
  border-color: var(--color-gold);
  transform: translateY(-50%) scale(1.1);
  color: #FFFFFF;
}

.story-prev { left: 20px; }
.story-next { right: 20px; }

@media (max-width: 600px) {
  .story-prev { left: 10px; width: 38px; height: 38px; }
  .story-next { right: 10px; width: 38px; height: 38px; }
}

.story-badge-indicator {
  position: absolute;
  top: 18px;
  right: 20px;
  padding: 5px 14px;
  border-radius: 999px;
  background: rgba(31, 29, 27, 0.65);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(184, 147, 90, 0.35);
  font-family: var(--font-sans);
  font-size: 0.74rem;
  letter-spacing: 2px;
  color: #FFFFFF;
  font-weight: 600;
  z-index: 20;
}

.story-badge-indicator span:first-child {
  color: var(--color-gold-light);
  font-weight: 700;
}

/* =====================================================================
   SELECTOR INTERACTIVO DE MINIATURAS (FOTOS CHICAS)
   ===================================================================== */
.story-thumbnails-wrapper {
  max-width: 1040px;
  margin: 0 auto;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: thin;
  padding: 4px 6px 16px;
}

.story-thumbnails-wrapper::-webkit-scrollbar {
  height: 5px;
}
.story-thumbnails-wrapper::-webkit-scrollbar-thumb {
  background: rgba(184, 147, 90, 0.4);
  border-radius: 999px;
}

.story-thumbnails-track {
  display: flex;
  gap: 12px;
  align-items: center;
  justify-content: flex-start;
  min-width: max-content;
  padding: 2px;
}

@media (min-width: 900px) {
  .story-thumbnails-track {
    justify-content: center;
  }
}

.story-thumb-item {
  position: relative;
  width: 110px;
  height: 75px;
  border-radius: 12px;
  overflow: hidden;
  cursor: pointer;
  border: 2px solid rgba(184, 147, 90, 0.25);
  background: #252F21;
  transition: all 0.32s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 4px 14px rgba(31, 29, 27, 0.08);
  flex-shrink: 0;
}

.story-thumb-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  filter: brightness(0.85);
  transition: transform 0.35s ease, filter 0.35s ease;
}

.story-thumb-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.7) 0%, transparent 60%);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 5px 6px;
}

.story-thumb-num {
  font-family: var(--font-sans);
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 1px;
  color: #FFFFFF;
}

.story-thumb-item:hover {
  transform: translateY(-3px);
  border-color: var(--color-gold);
  box-shadow: 0 8px 20px rgba(184, 147, 90, 0.25);
}

.story-thumb-item:hover img {
  filter: brightness(1);
  transform: scale(1.06);
}

.story-thumb-item.active {
  border-color: var(--color-gold);
  border-width: 2.5px;
  transform: translateY(-4px) scale(1.05);
  box-shadow: 0 10px 24px rgba(184, 147, 90, 0.4);
}

.story-thumb-item.active img {
  filter: brightness(1.05);
}

.story-thumb-item.active::after {
  content: '';
  position: absolute;
  top: 4px;
  right: 4px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #E2D9CC;
  box-shadow: 0 0 8px #B8935A;
}

/* =====================================================================
   ITINERARIO INTERACTIVO DE LA BODA ("EL GRAN DÍA")
   Relieves 3D y Sombras Multicapa
   ===================================================================== */
.itinerary-section {
  padding-top: 50px;
  padding-bottom: 60px;
}

.itinerary-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 20px;
  max-width: 1080px;
  margin: 0 auto;
}

.itinerary-card {
  position: relative;
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(14px);
  border-radius: 20px;
  padding: 30px 22px;
  text-align: center;
  border: 1px solid rgba(184, 147, 90, 0.28);
  box-shadow: 0 12px 32px rgba(31, 29, 27, 0.08), inset 0 1px 0 rgba(255, 255, 255, 0.9);
  transition: all 0.35s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  flex-direction: column;
  align-items: center;
}

.itinerary-card:hover {
  transform: translateY(-6px);
  border-color: var(--color-gold);
  box-shadow: 0 20px 45px rgba(31, 29, 27, 0.15), 0 0 20px rgba(184, 147, 90, 0.2);
}

.itinerary-card.highlight-card {
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.95) 0%, rgba(247, 241, 230, 0.95) 100%);
  border: 1.5px solid rgba(184, 147, 90, 0.55);
}

.itinerary-time {
  font-family: var(--font-sans);
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: #1F1D1B;
  background: rgba(184, 147, 90, 0.2);
  border: 1px solid rgba(184, 147, 90, 0.35);
  padding: 4px 14px;
  border-radius: 999px;
  margin-bottom: 16px;
}

.itinerary-icon-wrap {
  width: 58px;
  height: 58px;
  border-radius: 50%;
  background: linear-gradient(135deg, #FAF8F5 0%, #EFE8DC 100%);
  border: 1px solid rgba(184, 147, 90, 0.4);
  box-shadow: 0 6px 16px rgba(184, 147, 90, 0.15), inset 0 2px 4px rgba(255, 255, 255, 0.8);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #9A7742;
  margin-bottom: 16px;
  transition: transform 0.3s ease;
}

.itinerary-card:hover .itinerary-icon-wrap {
  transform: scale(1.1) rotate(5deg);
  color: #B8935A;
}

.itinerary-title {
  font-family: var(--font-serif);
  font-size: 1.4rem;
  font-weight: 600;
  color: #1F1D1B;
  margin-bottom: 6px;
  line-height: 1.2;
}

.itinerary-place {
  font-family: var(--font-sans);
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--color-olive);
  letter-spacing: 1px;
  margin-bottom: 10px;
}

.itinerary-desc {
  font-family: var(--font-sans);
  font-size: 0.84rem;
  color: #6E665E;
  line-height: 1.5;
  font-weight: 400;
}

/* =====================================================================
   CÓDIGO DE VESTIMENTA INTERACTIVO
   ===================================================================== */
.dresscode-box {
  max-width: 860px;
  margin: 0 auto;
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(14px);
  border-radius: 24px;
  padding: 38px 32px;
  border: 1px solid rgba(184, 147, 90, 0.32);
  box-shadow: 0 16px 40px rgba(31, 29, 27, 0.08);
  text-align: center;
}

.dresscode-badge {
  display: inline-block;
  font-family: var(--font-sans);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 3px;
  color: #1F1D1B;
  background: var(--gold-gradient);
  padding: 6px 20px;
  border-radius: 999px;
  margin-bottom: 24px;
  box-shadow: 0 4px 14px rgba(184, 147, 90, 0.3);
}

.dresscode-columns {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 24px;
  align-items: center;
  margin-bottom: 28px;
}

.dresscode-col h4 {
  font-family: var(--font-serif);
  font-size: 1.5rem;
  color: #1F1D1B;
  margin-bottom: 8px;
}

.dresscode-col p {
  font-family: var(--font-sans);
  font-size: 0.86rem;
  color: #6E665E;
  line-height: 1.55;
}

.dresscode-sep {
  width: 1px;
  height: 80px;
  background: rgba(184, 147, 90, 0.35);
}

@media (max-width: 640px) {
  .dresscode-columns {
    grid-template-columns: 1fr;
    gap: 18px;
  }
  .dresscode-sep {
    height: 1px;
    width: 60px;
    margin: 0 auto;
  }
}

.color-palette-wrap {
  padding-top: 20px;
  border-top: 1px solid rgba(184, 147, 90, 0.2);
}

.palette-title {
  font-family: var(--font-sans);
  font-size: 0.78rem;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: #6E665E;
  font-weight: 600;
  margin-bottom: 12px;
}

.palette-chips {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 12px;
}

.color-chip {
  width: 68px;
  height: 68px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15), inset 0 2px 4px rgba(255, 255, 255, 0.4);
  border: 2px solid #FFFFFF;
  transition: all 0.28s ease;
}

.color-chip span {
  font-family: var(--font-sans);
  font-size: 0.62rem;
  font-weight: 700;
  color: #FFFFFF;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.8);
}

.color-chip:hover {
  transform: translateY(-4px) scale(1.12);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.25);
}

/* =====================================================================
   BOTÓN FLOTANTE DE MÚSICA AMBIENTAL ROMÁNTICA
   ===================================================================== */
.floating-music-btn {
  position: fixed;
  bottom: 24px;
  left: 24px;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: rgba(31, 29, 27, 0.88);
  border: 1px solid rgba(184, 147, 90, 0.45);
  backdrop-filter: blur(12px);
  color: #E2D9CC;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 999;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.25);
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

@media (max-width: 768px) {
  .floating-music-btn {
    bottom: 84px; /* por encima de la barra móvil */
    left: 18px;
    width: 42px;
    height: 42px;
  }
}

.floating-music-btn:hover {
  transform: scale(1.1);
  background: #171E14;
  border-color: var(--color-gold);
  box-shadow: 0 8px 24px rgba(184, 147, 90, 0.35);
}

.eq-bars-wrap {
  display: flex;
  align-items: flex-end;
  gap: 3px;
  height: 18px;
}

.eq-bar {
  width: 3px;
  height: 4px;
  background: var(--color-gold);
  border-radius: 2px;
  transition: height 0.2s ease;
}

.floating-music-btn.playing .eq-bar:nth-child(1) { animation: eqAnim 0.7s infinite alternate ease-in-out; }
.floating-music-btn.playing .eq-bar:nth-child(2) { animation: eqAnim 1.1s infinite alternate ease-in-out 0.2s; }
.floating-music-btn.playing .eq-bar:nth-child(3) { animation: eqAnim 0.8s infinite alternate ease-in-out 0.4s; }

@keyframes eqAnim {
  0% { height: 4px; }
  100% { height: 18px; }
}

/* =====================================================================
   REDISENO DEL LIBRO DE FIRMAS NUPCIAL ("LIBRO DORADO DE RECUERDOS")
   Estilo pergamino de lujo, chips de inspiración rápida y cartas de amor
   ===================================================================== */
.guestbook-section {
  padding-top: 50px;
  padding-bottom: 90px;
}

.guestbook-redesign-container {
  max-width: 1100px;
  margin: 0 auto;
}

/* Tarjeta del Formulario Nupcial */
.guestbook-form-box {
  background: #FCFAF7;
  border-radius: 24px;
  border: 1px solid rgba(184, 147, 90, 0.35);
  box-shadow: 0 16px 45px rgba(31, 29, 27, 0.08), inset 0 1px 0 #FFFFFF;
  padding: 34px 30px;
  margin-bottom: 40px;
  position: relative;
  overflow: hidden;
}

@media (max-width: 600px) {
  .guestbook-form-box {
    padding: 24px 18px;
  }
}

.guestbook-form-box::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: var(--gold-gradient);
}

.guestbook-box-header {
  text-align: center;
  margin-bottom: 22px;
}

.guestbook-box-title {
  font-family: var(--font-serif);
  font-size: clamp(1.5rem, 3.8vw, 2.1rem);
  font-weight: 600;
  color: #1F1D1B;
  margin-bottom: 4px;
}

.guestbook-box-desc {
  font-family: var(--font-sans);
  font-size: 0.85rem;
  color: #6E665E;
}

/* Chips de inspiración rápida (un clic para autocompletar) */
.gb-chips-label {
  display: block;
  font-family: var(--font-sans);
  font-size: 0.74rem;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  color: #8C837A;
  font-weight: 600;
  margin-bottom: 10px;
}

.gb-chips-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 20px;
}

.gb-chip-btn {
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid rgba(184, 147, 90, 0.3);
  border-radius: 999px;
  padding: 6px 14px;
  font-family: var(--font-sans);
  font-size: 0.78rem;
  color: #2E2A27;
  cursor: pointer;
  transition: all 0.22s cubic-bezier(0.16, 1, 0.3, 1);
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.gb-chip-btn:hover {
  background: var(--color-gold-light);
  border-color: var(--color-gold);
  color: #1F1D1B;
  transform: translateY(-1.5px);
}

.gb-input-row {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
  margin-bottom: 18px;
}

.gb-input-field {
  width: 100%;
  padding: 13px 18px;
  border-radius: 12px;
  border: 1.5px solid rgba(184, 147, 90, 0.3);
  background: #FFFFFF;
  font-family: var(--font-sans);
  font-size: 0.95rem;
  color: #1F1D1B;
  outline: none;
  transition: border-color 0.25s, box-shadow 0.25s;
}

.gb-input-field:focus {
  border-color: var(--color-gold);
  box-shadow: 0 0 0 4px rgba(184, 147, 90, 0.15);
}

.gb-textarea-field {
  width: 100%;
  min-height: 110px;
  resize: vertical;
  padding: 14px 18px;
  border-radius: 12px;
  border: 1.5px solid rgba(184, 147, 90, 0.3);
  background: #FFFFFF;
  font-family: var(--font-sans);
  font-size: 0.95rem;
  color: #1F1D1B;
  line-height: 1.6;
  outline: none;
  transition: border-color 0.25s, box-shadow 0.25s;
}

.gb-textarea-field:focus {
  border-color: var(--color-gold);
  box-shadow: 0 0 0 4px rgba(184, 147, 90, 0.15);
}

.gb-submit-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  padding: 14px 28px;
  border-radius: 999px;
  background: #1F1D1B;
  color: #FAF8F5;
  font-family: var(--font-sans);
  font-size: 0.88rem;
  font-weight: 600;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  border: 1px solid #1F1D1B;
  cursor: pointer;
  box-shadow: 0 6px 20px rgba(31, 29, 27, 0.15);
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.gb-submit-btn:hover {
  background: var(--color-olive);
  border-color: var(--color-olive);
  color: #FFFFFF;
  transform: translateY(-2px);
  box-shadow: 0 10px 26px rgba(31, 29, 27, 0.22);
}

/* Barra de Encabezado de Dedicatorias */
.gb-entries-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 24px;
  padding: 0 4px;
  flex-wrap: wrap;
  gap: 12px;
}

.gb-entries-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-sans);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: #1F1D1B;
  background: rgba(255, 255, 255, 0.8);
  border: 1px solid rgba(184, 147, 90, 0.3);
  padding: 6px 16px;
  border-radius: 999px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.04);
}

.gb-entries-badge svg {
  color: #E53935;
}

/* Muro de Cartas de Amor (Mural de Firmas) */
.guestbook-letters-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(310px, 1fr));
  gap: 20px;
}

@media (max-width: 680px) {
  .guestbook-letters-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }
}

.guestbook-letter-card {
  position: relative;
  background: #FCFAF7;
  border-radius: 18px;
  padding: 24px 22px 20px;
  border: 1px solid rgba(184, 147, 90, 0.28);
  box-shadow: 0 10px 30px rgba(31, 29, 27, 0.06), inset 0 1px 0 #FFFFFF;
  transition: all 0.32s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.guestbook-letter-card:hover {
  transform: translateY(-4px);
  border-color: var(--color-gold);
  box-shadow: 0 16px 40px rgba(31, 29, 27, 0.12), 0 0 16px rgba(184, 147, 90, 0.18);
}

.gb-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}

.gb-author-badge {
  display: flex;
  align-items: center;
  gap: 12px;
}

.gb-avatar {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: linear-gradient(135deg, #FAF8F5 0%, #E8DFCF 100%);
  border: 1.5px solid rgba(184, 147, 90, 0.45);
  color: #9A7742;
  font-family: var(--font-serif);
  font-size: 1.1rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 3px 10px rgba(184, 147, 90, 0.15);
}

.gb-meta {
  display: flex;
  flex-direction: column;
}

.gb-author-name {
  font-family: var(--font-serif);
  font-size: 1.2rem;
  font-weight: 600;
  color: #1F1D1B;
  line-height: 1.2;
}

.gb-date {
  font-family: var(--font-sans);
  font-size: 0.72rem;
  color: #8C837A;
  letter-spacing: 0.5px;
}

.gb-wax-seal {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: rgba(184, 147, 90, 0.14);
  border: 1px solid rgba(184, 147, 90, 0.35);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-gold);
}

.gb-card-body {
  position: relative;
  padding: 4px 6px;
}

.gb-quote-mark {
  font-family: var(--font-serif);
  font-size: 1.8rem;
  color: rgba(184, 147, 90, 0.5);
  line-height: 1;
  display: inline-block;
  margin-right: 4px;
}

.gb-quote-mark.right {
  margin-right: 0;
  margin-left: 4px;
}

.gb-message-text {
  font-family: var(--font-sans);
  font-size: 0.92rem;
  color: #1F1D1B;
  line-height: 1.6;
  font-weight: 400;
  display: inline;
}

.gb-card-footer {
  margin-top: 14px;
  padding-top: 10px;
  border-top: 1px solid rgba(184, 147, 90, 0.15);
  display: flex;
  justify-content: flex-end;
}

.gb-like-btn {
  background: transparent;
  border: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 0.76rem;
  font-family: var(--font-sans);
  color: #8C837A;
  transition: all 0.2s ease;
}

.gb-like-btn:hover {
  color: #E53935;
  transform: scale(1.08);
}


/* =====================================================================
   PWA APP EXPERIENCE — TRANSICIONES, NAVBAR HAMBURGUESA, PORTADA CON
   PÉTALOS, CÁMARA EN VIVO MULTI-CAPTURA Y LIBRO DE FIRMAS TIPO LIBRO
   ===================================================================== */

/* Transiciones suaves tipo App entre pantallas (solo opacity en body para no afectar position:fixed) */
.app-page-enter {
  animation: appPageEnter 0.38s cubic-bezier(0.16, 1, 0.3, 1) both;
}

.app-page-leave {
  opacity: 0 !important;
  transition: opacity 0.18s ease !important;
}

@keyframes appPageEnter {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

/* =====================================================================
   NAVBAR UNIFICADA (ESCRITORIO + MÓVIL HAMBURGUESA CON CÁMARA DESTACADA)
   ===================================================================== */
.site-nav {
  height: calc(64px + env(safe-area-inset-top, 0px));
  padding-top: env(safe-area-inset-top, 0px);
  padding-left: 24px;
  padding-right: 24px;
}

.site-nav.nav-over-hero {
  background: linear-gradient(180deg, rgba(31, 29, 27, 0.62) 0%, rgba(31, 29, 27, 0.18) 100%);
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: none;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

.site-nav.nav-over-hero .brand-emblem {
  color: rgba(255, 255, 255, 0.88);
}

.site-nav.nav-over-hero .brand-divider {
  background: linear-gradient(180deg, rgba(226, 217, 204, 0) 0%, rgba(226, 217, 204, 0.6) 50%, rgba(226, 217, 204, 0) 100%);
}

.site-nav.nav-over-hero .brand-text {
  color: #FFFFFF;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.35);
}

.site-nav.nav-over-hero .brand-amp {
  color: var(--color-gold-light);
}

.site-nav.nav-over-hero .brand-date {
  color: rgba(226, 217, 204, 0.9);
}

.site-nav.nav-over-hero .nav-link {
  color: rgba(255, 255, 255, 0.88);
}

.site-nav.nav-over-hero .nav-link:hover,
.site-nav.nav-over-hero .nav-link.active {
  color: #FFFFFF;
  background: rgba(255, 255, 255, 0.16);
}

.site-nav.nav-over-hero .user-badge {
  background: rgba(255, 255, 255, 0.14);
  color: #FFFFFF;
  border-color: rgba(226, 217, 204, 0.45);
}

/* Botón Cámara Destacado en Escritorio */
.nav-camera-cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 18px;
  border-radius: 999px;
  background: var(--gold-gradient);
  color: #1F1D1B;
  font-size: 0.84rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  text-decoration: none;
  border: 1px solid rgba(255, 255, 255, 0.45);
  box-shadow: 0 6px 20px rgba(184, 147, 90, 0.42);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.nav-camera-cta:hover,
.nav-camera-cta.active {
  transform: translateY(-2px);
  box-shadow: 0 10px 26px rgba(184, 147, 90, 0.58);
  color: #1F1205;
}

/* Controles Móviles (Ocultos en Escritorio) */
.nav-mobile-actions {
  display: none;
  align-items: center;
  gap: 10px;
}

/* Botón Cámara Destacado en Teléfono */
.nav-camera-mobile-btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 8px 15px;
  border-radius: 999px;
  background: var(--gold-gradient);
  color: #231305;
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  text-decoration: none;
  border: 1.5px solid rgba(255, 255, 255, 0.72);
  box-shadow: 0 4px 18px rgba(184, 147, 90, 0.55);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
  z-index: 2;
}

.nav-camera-mobile-btn:active {
  transform: scale(0.95);
}

.nav-cam-pulse {
  position: absolute;
  inset: -3px;
  border-radius: 999px;
  border: 2px solid rgba(226, 217, 204, 0.7);
  animation: camRingPulse 2.4s cubic-bezier(0.24, 0, 0.38, 1) infinite;
  pointer-events: none;
}

@keyframes camRingPulse {
  0% { transform: scale(1); opacity: 0.75; }
  75% { transform: scale(1.14); opacity: 0; }
  100% { transform: scale(1.14); opacity: 0; }
}

/* Botón Hamburguesa */
.nav-hamburger-btn {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  background: rgba(31, 29, 27, 0);
  border: 1px solid rgba(184, 147, 90, 0);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
  cursor: pointer;
  padding: 0;
  transition: all 0.25s ease;
}

.site-nav.nav-over-hero .nav-hamburger-btn {
  background: rgba(255, 255, 255, 0.14);
  border-color: rgba(255, 255, 255, 0.28);
}

.hamburger-line {
  width: 20px;
  height: 2px;
  border-radius: 999px;
  background: rgba(184, 147, 90, 1);
  transition: transform 0.28s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.2s ease;
}

.site-nav.nav-over-hero .hamburger-line {
  background: #FFFFFF;
}

.nav-hamburger-btn.is-open .hamburger-line:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.nav-hamburger-btn.is-open .hamburger-line:nth-child(2) {
  opacity: 0;
}

.nav-hamburger-btn.is-open .hamburger-line:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

@media (max-width: 768px) {
  .site-nav {
    padding-left: 14px;
    padding-right: 14px;
  }

  .site-nav .nav-links {
    display: none !important;
  }

  .nav-mobile-actions {
    display: flex;
  }

  .nav-brand {
    gap: 8px;
  }

  .brand-emblem {
    width: 30px;
    height: 36px;
  }

  .brand-divider {
    height: 22px;
  }

  .brand-text {
    font-size: 1.12rem;
  }

  .brand-date {
    font-size: 0.52rem;
    letter-spacing: 0.22em;
  }
}

@media (max-width: 360px) {
  .brand-divider,
  .brand-date {
    display: none;
  }

  .brand-text {
    font-size: 1.02rem;
  }
}

@media (max-width: 320px) {
  .brand-wordmark {
    display: none;
  }
}

/* Menú Drawer Desplegable Tipo App */
.mobile-drawer-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(14, 19, 12, 0.56);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  z-index: 10040;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.mobile-drawer-backdrop.is-open {
  opacity: 1;
  visibility: visible;
}

.mobile-drawer {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  width: min(86vw, 330px);
  height: 100vh;
  height: 100dvh;
  background: linear-gradient(180deg, #FDFBF7 0%, #F5EFE4 100%);
  border-left: 1px solid rgba(184, 147, 90, 0.35);
  box-shadow: -16px 0 50px rgba(15, 22, 12, 0.28);
  z-index: 10050;
  display: flex;
  flex-direction: column;
  padding: calc(18px + env(safe-area-inset-top, 0px)) 18px calc(22px + env(safe-area-inset-bottom, 0px));
  transform: translateX(102%);
  transition: transform 0.34s cubic-bezier(0.16, 1, 0.3, 1);
  overflow-y: auto;
}

.mobile-drawer.is-open {
  transform: translateX(0);
}

.mobile-drawer-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-bottom: 16px;
  margin-bottom: 16px;
  border-bottom: 1px solid rgba(184, 147, 90, 0.25);
}

.drawer-brand {
  display: flex;
  align-items: center;
  gap: 11px;
  text-decoration: none;
  color: inherit;
}

.drawer-brand-emblem {
  width: 38px;
  height: 46px;
}

.drawer-brand-divider {
  height: 30px;
}

.drawer-brand-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.drawer-title {
  font-family: var(--font-serif);
  font-size: 1.36rem;
  font-weight: 500;
  color: var(--color-olive-dark);
  letter-spacing: 0.025em;
  line-height: 1.08;
}

.drawer-sub {
  font-size: 0.62rem;
  letter-spacing: 0.26em;
  text-transform: uppercase;
  color: var(--color-gold-dark);
  font-weight: 500;
  opacity: 0.9;
}

.drawer-close-btn {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 1px solid rgba(184, 147, 90, 0.3);
  background: #FFFFFF;
  color: var(--color-olive-dark);
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
  display: grid;
  place-items: center;
}

.drawer-camera-spotlight {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 14px;
  border-radius: 18px;
  background: var(--gold-gradient);
  color: #1F1D1B;
  text-decoration: none;
  box-shadow: 0 10px 26px rgba(184, 147, 90, 0.35);
  border: 1px solid rgba(255, 255, 255, 0.55);

  transition: transform 0.22s ease;
}

.drawer-camera-spotlight:active {
  transform: scale(0.98);
}

.drawer-cam-icon {
  width: 44px;
  height: 44px;
  border-radius: 14px;
  background: rgba(36, 20, 6, 0.14);
  display: grid;
  place-items: center;
  flex-shrink: 0;
}

.drawer-cam-text {
  flex: 1;
  min-width: 0;
}

.drawer-cam-text strong {
  display: block;
  font-size: 0.92rem;
  font-weight: 700;
  line-height: 1.2;
}

.drawer-cam-text span {
  display: block;
  font-size: 0.74rem;
  opacity: 0.86;
  margin-top: 2px;
}

.drawer-cam-arrow {
  flex-shrink: 0;
}

.drawer-nav-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex: 1;
}

.drawer-nav-item {
  display: flex;
  align-items: center;
  gap: 13px;
  width: 100%;
  padding: 13px 14px;
  border-radius: 14px;
  border: 1px solid transparent;
  background: transparent;
  color: var(--color-text-primary);
  font-family: var(--font-sans);
  font-size: 0.94rem;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  text-align: left;
  transition: all 0.22s ease;
}

.drawer-nav-item:hover,
.drawer-nav-item.active {
  background: #FFFFFF;
  border-color: rgba(184, 147, 90, 0.35);
  color: var(--color-olive-dark);
  box-shadow: 0 4px 14px rgba(31, 29, 27, 0.06);
}

.drawer-item-icon {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: rgba(184, 147, 90, 0.14);
  color: var(--color-gold-dark);
  display: grid;
  place-items: center;
  flex-shrink: 0;
}

.drawer-nav-item.active .drawer-item-icon {
  background: var(--color-olive);
  color: #FFFFFF;
}

.drawer-install-btn {
  margin-top: 6px;
  background: rgba(31, 29, 27, 0.08);
  border-color: rgba(31, 29, 27, 0.2);
}

/* Botón Hamburguesa Flotante exclusivo para Home (sin barra superior) */
.home-floating-hamburger {
  position: fixed;
  top: calc(16px + env(safe-area-inset-top, 0px));
  right: 16px;
  z-index: 10020;
  width: 40px;
  height: 40px;
  border-radius: 14px;
  background: rgba(31, 29, 27, 0.45);
  border: 1px solid rgba(226, 217, 204, 0);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.28);
}

.home-floating-hamburger .hamburger-line {
  background: #FFFFFF;
}

.home-floating-hamburger:hover {
  background: rgba(31, 29, 27, 0.68);
  border-color: var(--color-gold-light);
}

/* =====================================================================
   HOME FULLSCREEN APP COVER: SLIDESHOW TENUE + PÉTALOS DE CEREZO + SIN SCROLL
   ===================================================================== */
html.home-no-scroll {
  height: 100%;
  min-height: 0 !important;
  overflow: hidden;
  overscroll-behavior: none;
  background-color: #171513;
}

.page-home {
  background: #171513;
  position: fixed;
  inset: 0;
  width: 100%;
  height: var(--app-height, 100dvh);
  min-height: 0 !important;
  max-height: var(--app-height, 100dvh);
  overflow: hidden;
  overscroll-behavior: none;
  margin: 0;
  padding: 0;
}

.app-main-home {
  width: 100%;
  height: 100%;
  min-height: 0 !important;
  overflow: hidden;
}

.hero-app-cover {
  position: relative;
  height: 100%;
  min-height: 0 !important;
  width: 100%;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding: calc(16px + env(safe-area-inset-top, 0px)) 20px calc(38px + env(safe-area-inset-bottom, 0px));
  overflow: hidden;
  text-align: center;
}

.hero-slideshow {
  position: absolute;
  inset: 0;
  z-index: 1;
  background: #171513;
}

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transform: scale(1.06);
  transition: opacity 2.1s ease-in-out, transform 8s ease-out;
  z-index: 1;
  will-change: opacity, transform;
}

.hero-slide.is-active {
  opacity: 1;
  transform: scale(1);
  z-index: 2;
}

.hero-slide .hero-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 22%;
  filter: brightness(0.95) contrast(1.03) saturate(1.04);
  transform: none;
}

/* Degradado suave: parte superior despejada para lucir la foto de los novios, abajo legible */
.hero-overlay-lower {
  position: absolute;
  inset: 0;
  z-index: 3;
  background: linear-gradient(
    180deg,
    rgba(31, 29, 27, 0.24) 0%,
    rgba(31, 29, 27, 0.05) 28%,
    rgba(14, 20, 12, 0.22) 52%,
    rgba(12, 17, 10, 0.72) 76%,
    rgba(9, 13, 8, 0.94) 100%
  );
}

/* Lluvia de Pétalos */
.hero-petals-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 4;
  pointer-events: none;
}

/* Bloque de texto y 3 botones más abajo */
.hero-content-lower {
  position: relative;
  z-index: 5;
  width: 100%;
  max-width: 720px;
  padding: 0 4px;
  margin-bottom: 4px;
  animation: heroLowerRise 0.85s cubic-bezier(0.16, 1, 0.3, 1) both;
}

@keyframes heroLowerRise {
  from {
    opacity: 0;
    transform: translateY(22px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.hero-date-pill {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 5px 16px;
  border-radius: 999px;
  background: rgba(31, 29, 27, 0.48);
  border: 1px solid rgba(226, 217, 204, 0.36);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  color: var(--color-gold-light);
  font-size: 0.74rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  margin-bottom: 10px;
}

.hero-pill-dot {
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--color-gold-light);
}

.hero-content-lower .hero-title {
  font-size: clamp(2.8rem, 8.5vw, 5.2rem);
  line-height: 0.98;
  margin-bottom: 10px;
  text-shadow: 0 6px 26px rgba(0, 0, 0, 0.55);
}

.hero-content-lower .hero-title span {
  font-size: clamp(3.1rem, 9.2vw, 5.8rem);
  margin: 0 6px;
}

.hero-content-lower .hero-subtitle {
  font-size: clamp(0.88rem, 2.2vw, 1.06rem);
  max-width: 520px;
  margin: 0 auto 22px;
  color: rgba(250, 244, 236, 0.9);
  line-height: 1.5;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
}

/* 3 Botones Principales en la Portada */
.hero-action-buttons {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  gap: 12px;
  width: 100%;
  max-width: 680px;
  margin: 0 auto;
}

.hero-btn-secondary-row {
  display: contents;
}

.hero-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  padding: 8px 14px;
  border-radius: 999px;
  font-family: var(--font-sans);
  font-size: 0.88rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  text-decoration: none;
  cursor: pointer;
  transition: transform 0.26s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.26s ease, background 0.26s ease;
  white-space: nowrap;
}

.hero-btn-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.hero-btn-moments {
  background: var(--gold-gradient);
  color: #1F1D1B;
  border: 1.5px solid rgba(255, 255, 255, 0.65);
  box-shadow: 0 10px 28px rgba(184, 147, 90, 0.45);
}

.hero-btn-moments:hover {
  transform: translateY(-3px);
  box-shadow: 0 4px 10px rgba(184, 147, 90, 0.62);
}

.hero-btn-glass {
  background: rgba(20, 28, 17, 0.58);
  color: #FFFFFF;
  border: 1px solid rgba(226, 217, 204, 0.06);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.32);
}

.hero-btn-glass:hover {
  background: rgba(34, 46, 29, 0.78);
  border-color: var(--color-gold-light);
  transform: translateY(-3px);
}

.hero-btn:active {
  transform: scale(0.97);
}

@media (max-width: 768px) {
  body.page-home {
    position: fixed;
    inset: 0;
    width: 100%;
    height: var(--app-height, 100dvh);
    min-height: 0 !important;
    max-height: var(--app-height, 100dvh);
    overflow: hidden;
    touch-action: manipulation;
  }

  .hero-app-cover {
    height: 100%;
    min-height: 0 !important;
    max-height: 100%;
    padding: calc(16px + env(safe-area-inset-top, 0px)) 16px calc(30px + env(safe-area-inset-bottom, 0px));
  }

  .hero-content-lower {
    margin-bottom: 0;
    z-index: 10;
  }

  .hero-content-lower .hero-date-pill {
    font-size: 0.68rem;
    padding: 4px 13px;
    margin-bottom: 8px;
  }

  .hero-content-lower .hero-title {
    font-size: clamp(2.45rem, 9.5vw, 3.6rem);
    margin-bottom: 8px;
  }

  .hero-content-lower .hero-subtitle {
    margin-bottom: 16px;
    font-size: 0.84rem;
    line-height: 1.42;
  }

  .hero-action-buttons {
    flex-direction: column;
    gap: 10px;
    max-width: 420px;
  }

  .hero-btn-moments {
    width: 100%;
    padding: 8px 12px;
    font-size: 0.92rem;
  }

  .hero-btn-secondary-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    width: 100%;
  }

  .hero-btn-glass {
    width: 100%;
    padding: 9px 10px;
    font-size: 0.82rem;
    gap: 6px;
  }
}

@media (max-width: 768px) and (max-height: 680px) {
  .hero-app-cover {
    padding-bottom: calc(20px + env(safe-area-inset-bottom, 0px));
  }

  .hero-content-lower .hero-title {
    font-size: 2.25rem;
    margin-bottom: 6px;
  }

  .hero-content-lower .hero-subtitle {
    font-size: 0.78rem;
    margin-bottom: 12px;
  }

  .hero-btn-moments {
    padding: 8px 12px;
  }

  .hero-btn-glass {
    padding: 11px 8px;
  }
}

/* =====================================================================
   PÁGINA DEDICADA DE CÁMARA (/camara) Y GESTIÓN DE MIS RECUERDOS
   ===================================================================== */
.camera-hub-main {
  min-height: 100dvh;
  padding: calc(84px + env(safe-area-inset-top, 0px)) 16px calc(48px + env(safe-area-inset-bottom, 0px));
}

.camera-hub-container {
  max-width: 960px;
  margin: 0 auto;
}

.camera-hub-header {
  text-align: center;
  margin-bottom: 24px;
}

.camera-hub-title {
  font-family: var(--font-serif);
  font-size: clamp(2rem, 5.5vw, 3rem);
  color: var(--color-olive-dark);
  line-height: 1.1;
  margin: 6px 0 8px;
}

.camera-hub-desc {
  font-size: 0.92rem;
  color: var(--color-text-secondary);
  max-width: 900px;
  margin: 0 auto 20px;
}

/* Tarjeta de Cupo del Invitado */
.camera-quota-card {
  max-width: 640px;
  margin: 0 auto;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(14px);
  border: 1px solid rgba(184, 147, 90, 0.34);
  border-radius: 20px;
  padding: 16px 18px;
  box-shadow: var(--shadow-sm);
  text-align: left;
}

.camera-quota-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.camera-quota-user {
  display: flex;
  align-items: center;
  gap: 11px;
  min-width: 0;
}

.guest-avatar-sm {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: var(--gold-gradient);
  color: #1F1D1B;
  display: grid;
  place-items: center;
  flex-shrink: 0;
}

.camera-quota-label {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--color-gold-dark);
}

.camera-quota-name {
  font-family: var(--font-serif);
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--color-olive-dark);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.camera-edit-profile-btn {
  padding: 6px 14px;
  border-radius: 999px;
  border: 1px solid rgba(184, 147, 90, 0.45);
  background: #FAF8F5;
  color: var(--color-olive-dark);
  font-size: 0.76rem;
  font-weight: 700;
  cursor: pointer;
  flex-shrink: 0;
  transition: all 0.2s ease;
}

.camera-edit-profile-btn:hover {
  background: var(--color-gold-light);
}

.camera-quota-bar {
  position: relative;
  width: 100%;
  height: 8px;
  border-radius: 999px;
  background: rgba(31, 29, 27, 0.12);
  overflow: hidden;
  margin-bottom: 8px;
}

.camera-quota-fill {
  position: relative;
  z-index: 2;
  height: 100%;
  border-radius: 999px;
  background: var(--gold-gradient);
  transition: width 0.45s cubic-bezier(0.16, 1, 0.3, 1);
}

.camera-quota-fill-selected {
  position: absolute;
  top: 0;
  bottom: 0;
  z-index: 1;
  border-radius: 999px;
  background: rgba(31, 29, 27, 0.42);
  transition: left 0.35s cubic-bezier(0.16, 1, 0.3, 1), width 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

.camera-quota-numbers {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  flex-wrap: wrap;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--color-text-secondary);
}

/* Aviso elegante de cierre de subidas (después del 21 dic 2026) */
.upload-closed-banner {
  max-width: 680px;
  margin: 0 auto 24px;
  padding: 22px 22px;
  border-radius: 22px;
  background: linear-gradient(150deg, #FFFBF3 0%, #F7EFE0 100%);
  border: 1.5px solid rgba(184, 147, 90, 0.45);
  box-shadow: 0 12px 28px rgba(31, 29, 27, 0.08);
  display: flex;
  align-items: flex-start;
  gap: 16px;
}

.upload-closed-icon {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background: linear-gradient(135deg, #2E2A27 0%, #1F1D1B 100%);
  color: #E2D9CC;
  display: grid;
  place-items: center;
  flex-shrink: 0;
}

.upload-closed-body h3 {
  font-family: var(--font-serif);
  font-size: 1.45rem;
  color: var(--color-olive-dark);
  line-height: 1.2;
  margin-bottom: 6px;
}

.upload-closed-body p {
  font-size: 0.86rem;
  color: var(--color-text-secondary);
  line-height: 1.5;
}

@media (max-width: 600px) {
  .upload-closed-banner {
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 20px 18px;
  }
}

/* Grid de las 3 Opciones de Cámara */
.camera-options-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin-bottom: 28px;
}

@media (max-width: 768px) {
  .camera-options-grid {
    grid-template-columns: 1fr;
    gap: 12px;
  }
}

.camera-option-card {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 12px;
  padding: 26px 20px 22px;
  border-radius: 12px;
  border: 1.5px solid rgba(184, 147, 90, 0.35);
  background: #FFFFFF;
  cursor: pointer;
  box-shadow: 0 12px 30px rgba(31, 29, 27, 0.08);
  transition: transform 0.28s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.28s ease, border-color 0.28s ease;
  font-family: var(--font-sans);
}

.camera-option-card:hover {
  transform: translateY(-5px);
  border-color: var(--color-gold);
  box-shadow: 0 18px 40px rgba(31, 29, 27, 0.14);
}

.camera-option-card:active {
  transform: scale(0.98);
}

.camera-option-card.option-photo {
  background: linear-gradient(155deg, #FFFBF2 0%, #FBF1DC 100%);
  border-color: rgba(184, 147, 90, 0.6);
}

.camera-option-card.option-video,
.camera-option-card.option-gallery {
  background: #FFFFFF;
  border: 1.5px solid var(--color-gold);
  color: var(--color-olive);
  box-shadow: 0 4px 14px rgba(31, 29, 27, 0.08), inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

.camera-option-card.option-video:hover,
.camera-option-card.option-gallery:hover {
  background: linear-gradient(135deg, #FAF8F5 0%, #FAF8F5 100%);
  border-color: var(--color-gold-dark);
  color: var(--color-olive-dark);
  box-shadow: 0 8px 22px rgba(184, 147, 90, 0.22);
}

.option-icon-wrap {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--gold-gradient);
  color: #1F1D1B;
  box-shadow: 0 8px 20px rgba(184, 147, 90, 0.38);
  flex-shrink: 0;
}

.option-video .option-icon-wrap,
.option-gallery .option-icon-wrap {
  background: linear-gradient(135deg, #2E2A27 0%, #1F1D1B 100%);
  color: #E2D9CC;
  box-shadow: 0 8px 20px rgba(31, 29, 27, 0.28);
}

.option-body h3 {
  font-family: var(--font-serif);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--color-olive-dark);
  margin-bottom: 4px;
}

.option-body p {
  font-size: 0.84rem;
  color: var(--color-text-secondary);
  line-height: 1.45;
}

.option-pill {
  display: inline-block;
  padding: 5px 14px;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  background: rgba(184, 147, 90, 0.18);
  color: var(--color-gold-dark);
}

@media (max-width: 768px) {
  .camera-option-card {
    flex-direction: row;
    text-align: left;
    padding: 16px 16px;
    gap: 14px;
  }

  .option-icon-wrap {
    width: 54px;
    height: 54px;
  }

  .option-body {
    flex: 1;
    min-width: 0;
  }

  .option-body h3 {
    font-size: 1.25rem;
    margin-bottom: 2px;
  }

  .option-body p {
    font-size: 0.78rem;
  }

  .option-pill {
    display: none;
  }
}

/* Progreso de subida por lotes */
.camera-upload-progress {
  max-width: 640px;
  margin: 0 auto 24px;
  padding: 18px 20px;
  border-radius: 18px;
  background: linear-gradient(145deg, rgba(255, 254, 250, 0.96) 0%, rgba(249, 243, 232, 0.94) 100%);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid rgba(184, 147, 90, 0.42);
  box-shadow: 0 14px 32px -8px rgba(31, 29, 27, 0.14), inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

.camera-progress-label {
  font-size: 0.84rem;
  font-weight: 600;
  color: var(--color-olive-dark);
  text-align: center;
  margin-top: 10px;
  letter-spacing: 0.01em;
}

/* Gestión de Mis Fotos y Videos Subidos */
.my-uploads-section {
  background: rgba(255, 255, 255, 0.82);
  backdrop-filter: blur(12px);
  border: 1px solid rgba(184, 147, 90, 0.28);
  border-radius: 12px;
  padding: 22px 20px;
  box-shadow: var(--shadow-sm);
}

.my-uploads-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 18px;
}

.my-uploads-title {
  font-family: var(--font-serif);
  font-size: 1.55rem;
  color: var(--color-olive-dark);
  line-height: 1.15;
}

.my-uploads-sub {
  font-size: 0.82rem;
  color: var(--color-text-secondary);
}

.my-uploads-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}


.btn-mini-refresh {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: 1px solid rgba(184, 147, 90, 0.35);
  background: #FFFFFF;
  color: var(--color-olive-dark);
  display: grid;
  place-items: center;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-mini-refresh:hover {
  border-color: var(--color-gold);
  transform: rotate(30deg);
}

.btn-mini-gallery {
  padding: 8px 16px;
  border-radius: 999px;
  background: var(--color-olive-dark);
  color: #FAF8F5;
  font-size: 0.78rem;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.2s ease;
}

.btn-mini-gallery:hover {
  background: var(--color-olive);
}

.my-uploads-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(145px, 1fr));
  gap: 10px;
}

@media (max-width: 480px) {
  .my-uploads-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 6px;
  }
}

.my-upload-tile {
  position: relative;
  aspect-ratio: 1;
  border-radius: 12px;
  overflow: hidden;
  background: #EAE5DC;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(31, 29, 27, 0.08);
  animation: tilePopIn 0.35s cubic-bezier(0.16, 1, 0.3, 1) both;
}

@keyframes tilePopIn {
  from { opacity: 0; transform: scale(0.94); }
  to { opacity: 1; transform: scale(1); }
}

.my-upload-tile img,
.my-upload-tile video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.my-upload-delete {
  position: absolute;
  top: 6px;
  right: 6px;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  border: 1.5px solid rgba(255, 255, 255, 0.85);
  background: rgba(211, 47, 47, 0.92);
  color: #FFFFFF;
  display: grid;
  place-items: center;
  cursor: pointer;
  z-index: 4;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.35);
  transition: transform 0.2s ease;
}

.my-upload-delete:hover {
  transform: scale(1.1);
}

.my-upload-badge-vid {
  position: absolute;
  bottom: 6px;
  left: 6px;
  padding: 2px 7px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.68);
  color: #FFFFFF;
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  z-index: 3;
}

.my-uploads-empty {
  text-align: center;
  padding: 36px 16px;
  color: var(--color-text-secondary);
}

.my-uploads-empty-icon {
  color: var(--color-gold);
  margin-bottom: 10px;
}

.my-uploads-empty h3 {
  font-family: var(--font-serif);
  font-size: 1.35rem;
  color: var(--color-olive-dark);
  margin-bottom: 4px;
}

.my-uploads-empty p {
  font-size: 0.84rem;
  max-width: 360px;
  margin: 0 auto;
}

/* =====================================================================
   CARRETE TEMPORAL EN ESPERA (CACHÉ LOCAL + SELECCIÓN ANTES DE PUBLICAR)
   ===================================================================== */
.standby-section {
  background: linear-gradient(160deg, rgba(250, 248, 245, 0.96) 0%, rgba(250, 244, 232, 0.92) 100%);
  backdrop-filter: blur(14px);
  border: 1.5px solid rgba(184, 147, 90, 0.44);
  border-radius: 12px;
  padding: 22px 20px;
  margin-bottom: 24px;
  box-shadow: 0 14px 34px rgba(31, 29, 27, 0.08);
}

.standby-head {
  margin-bottom: 16px;
}

.standby-title-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 6px;
}

.standby-title {
  font-family: var(--font-serif);
  font-size: 1.6rem;
  color: var(--color-olive-dark);
  line-height: 1.15;
}

.standby-count-pill {
  display: inline-flex;
  align-items: center;
  padding: 4px 11px;
  border-radius: 999px;
  background: rgba(184, 147, 90, 0.2);
  color: var(--color-gold-dark);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.standby-sub {
  font-size: 0.84rem;
  color: var(--color-text-secondary);
  line-height: 1.48;
  margin-bottom: 8px;
}

.standby-cache-note {
  display: inline-flex;
  align-items: flex-start;
  gap: 6px;
  font-size: 0.74rem;
  color: #6B7765;
  background: rgba(31, 29, 27, 0.07);
  padding: 7px 11px;
  border-radius: 10px;
  line-height: 1.4;
}

.standby-cache-note svg {
  flex-shrink: 0;
  margin-top: 2px;
  color: var(--color-olive);
}

.standby-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  padding: 12px 14px;
  margin-bottom: 16px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.88);
  border: 1px solid rgba(184, 147, 90, 0.32);
}

.standby-selection-info {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}

.standby-sel-counter {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--color-olive-dark);
}

.standby-quick-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
}

.btn-standby-ghost {
  padding: 5px 11px;
  border-radius: 999px;
  border: 1px solid rgba(31, 29, 27, 0.22);
  background: #FAF8F5;
  color: var(--color-olive-dark);
  font-size: 0.74rem;
  font-weight: 600;
  font-family: var(--font-sans);
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-standby-ghost:hover {
  border-color: var(--color-gold);
  background: #FFFBF0;
}

.btn-standby-ghost.is-danger {
  color: #A82E2E;
  border-color: rgba(185, 45, 45, 0.22);
  background: #FFF6F6;
}

.btn-standby-ghost.is-danger:hover {
  border-color: rgba(185, 45, 45, 0.48);
  background: #FEEBEB;
}

.btn-publish-standby {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 11px 20px;
  border-radius: 999px;
  border: none;
  background: linear-gradient(135deg, #3A4933 0%, #24301E 100%);
  color: #FAF4E6;
  font-family: var(--font-sans);
  font-size: 0.86rem;
  font-weight: 700;
  letter-spacing: 0.01em;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease, opacity 0.2s ease;
}

.btn-publish-standby:hover:not(:disabled) {
  transform: translateY(-2px);
  box-shadow: 0 12px 24px rgba(31, 29, 27, 0.2);
}

.btn-publish-standby:active:not(:disabled) {
  transform: scale(0.98);
}

.btn-publish-standby:disabled {
  opacity: 0.45;
  cursor: not-allowed;
  box-shadow: none;
}

.publish-count-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 22px;
  height: 22px;
  padding: 0 6px;
  border-radius: 999px;
  background: var(--gold-gradient);
  color: #1F1D1B;
  font-size: 0.74rem;
  font-weight: 800;
}

@media (max-width: 640px) {
  .standby-section {
    padding: 18px 14px;
  }
  .standby-toolbar {
    flex-direction: column;
    align-items: stretch;
  }
  .standby-selection-info {
    justify-content: space-between;
  }
  .btn-publish-standby {
    width: 100%;
    padding: 13px 18px;
  }
}

.standby-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(145px, 1fr));
  gap: 10px;
}

@media (max-width: 480px) {
  .standby-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 7px;
  }
}

.standby-tile {
  position: relative;
  aspect-ratio: 1;
  border-radius: 14px;
  overflow: hidden;
  background: #EAE5DC;
  cursor: pointer;
  border: 2.5px solid transparent;
  box-shadow: 0 4px 12px rgba(31, 29, 27, 0.08);
  transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease, opacity 0.2s ease;
  animation: tilePopIn 0.3s cubic-bezier(0.16, 1, 0.3, 1) both;
  user-select: none;
  -webkit-tap-highlight-color: transparent;
}

.standby-tile:not(.is-selected) img,
.standby-tile:not(.is-selected) video {
  opacity: 0.72;
  filter: saturate(0.85);
}

.standby-tile.is-selected {
  border-color: var(--color-gold);
  box-shadow: 0 8px 20px rgba(184, 147, 90, 0.35);
}

.standby-tile img,
.standby-tile video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: opacity 0.2s ease, filter 0.2s ease, transform 0.25s ease;
}

.standby-tile.is-selected img,
.standby-tile.is-selected video {
  opacity: 1;
  filter: none;
}

.standby-select-badge {
  position: absolute;
  top: 7px;
  left: 7px;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, 0.92);
  background: rgba(25, 32, 22, 0.48);
  color: #FFFFFF;
  font-size: 0.74rem;
  font-weight: 800;
  display: grid;
  place-items: center;
  z-index: 4;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.28);
  transition: transform 0.2s ease, background 0.2s ease, border-color 0.2s ease;
}

.standby-tile.is-selected .standby-select-badge {
  background: var(--gold-gradient);
  border-color: #FFFFFF;
  color: #1F1D1B;
  transform: scale(1.06);
}

.standby-delete-btn {
  position: absolute;
  top: 7px;
  right: 7px;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: 1.5px solid rgba(255, 255, 255, 0.85);
  background: rgba(205, 45, 45, 0.88);
  color: #FFFFFF;
  display: grid;
  place-items: center;
  cursor: pointer;
  z-index: 5;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.28);
  transition: transform 0.18s ease;
}

.standby-delete-btn:hover {
  transform: scale(1.1);
}

.standby-preview-btn {
  position: absolute;
  bottom: 7px;
  right: 7px;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: 1.5px solid rgba(255, 255, 255, 0.8);
  background: rgba(25, 32, 22, 0.68);
  color: #FFFFFF;
  display: grid;
  place-items: center;
  cursor: pointer;
  z-index: 5;
  backdrop-filter: blur(4px);
  transition: transform 0.18s ease, background 0.18s ease;
}

.standby-preview-btn:hover {
  transform: scale(1.1);
  background: rgba(25, 32, 22, 0.9);
}

.standby-vid-pill {
  position: absolute;
  bottom: 7px;
  left: 7px;
  padding: 2px 7px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.72);
  color: #FFFFFF;
  font-size: 0.64rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  z-index: 4;
}

.standby-empty {
  text-align: center;
  padding: 26px 14px;
  color: var(--color-text-secondary);
}

.standby-empty-icon {
  color: var(--color-gold);
  margin-bottom: 8px;
}

.standby-empty h3 {
  font-family: var(--font-serif);
  font-size: 1.28rem;
  color: var(--color-olive-dark);
  margin-bottom: 4px;
}

.standby-empty p {
  font-size: 0.82rem;
  max-width: 390px;
  margin: 0 auto;
  line-height: 1.45;
}

/* Botón de selección de borrador dentro del Lightbox */
.lightbox-standby-select-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 15px;
  border-radius: 999px;
  border: 1.5px solid rgba(255, 255, 255, 0.5);
  background: rgba(255, 255, 255, 0.12);
  color: #FFFFFF;
  font-family: var(--font-sans);
  font-size: 0.82rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
}

.lightbox-standby-select-btn .lb-sel-check {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  border: 1.5px solid rgba(255, 255, 255, 0.75);
  display: grid;
  place-items: center;
  font-size: 0.72rem;
  opacity: 0.55;
}

.lightbox-standby-select-btn.is-selected {
  background: var(--gold-gradient);
  border-color: #E2D9CC;
  color: #1F1D1B;
}

.lightbox-standby-select-btn.is-selected .lb-sel-check {

  color: #E2D9CC;
  opacity: 1;
}

/* Inputs de archivo ocultos de forma segura para iOS/Android */
.sr-only-file-input {
  position: fixed;
  top: 0;
  left: -9999px;
  width: 1px;
  height: 1px;
  opacity: 0;
  overflow: hidden;
  z-index: -1;
}

/* =====================================================================
   VISOR DE CÁMARA EN VIVO FULLSCREEN (APP NATIVA, MULTI-CAPTURA)
   ===================================================================== */
.live-camera-modal {
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100vh;
  height: 100dvh;
  background: #141210;
  z-index: 100020;
  display: none;
  flex-direction: column;
  overflow: hidden;
  user-select: none;
}

.live-camera-modal.is-open {
  display: flex;
  animation: camFadeIn 0.26s ease both;
}

@keyframes camFadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

.live-cam-topbar {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  z-index: 30;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: calc(14px + env(safe-area-inset-top, 0px)) 16px 14px;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.72) 0%, transparent 100%);
}

.live-cam-mode-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  border-radius: 999px;
  background: rgba(31, 29, 27, 0.65);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(226, 217, 204, 0.32);
  color: #FFFFFF;
  font-size: 0.8rem;
  font-weight: 600;
}

.live-cam-top-right {
  display: flex;
  align-items: center;
  gap: 8px;
}

.live-cam-quota-chip {
  padding: 6px 12px;
  border-radius: 999px;
  background: rgba(184, 147, 90, 0.24);
  border: 1px solid rgba(226, 217, 204, 0.45);
  color: var(--color-gold-light);
  font-size: 0.76rem;
  font-weight: 700;
}

.live-cam-icon-btn {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.24);
  background: rgba(0, 0, 0, 0.45);
  backdrop-filter: blur(8px);
  color: #FFFFFF;
  display: grid;
  place-items: center;
  cursor: pointer;
  transition: background 0.2s ease;
}

.live-cam-icon-btn:hover {
  background: rgba(184, 147, 90, 0.35);
}

.live-cam-viewport {
  position: relative;
  flex: 1;
  width: 100%;
  overflow: hidden;
  background: #000000;
  display: flex;
  align-items: center;
  justify-content: center;
}

.live-cam-viewport #cameraVideo {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.live-cam-viewport #cameraVideo.is-mirrored {
  transform: scaleX(-1);
}

.rec-limit-label {
  opacity: 0.75;
  font-weight: 500;
}

.live-cam-permission {
  position: absolute;
  inset: 0;
  z-index: 20;
  background: rgba(31, 29, 27, 0.94);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: calc(76px + env(safe-area-inset-top, 0px)) 20px 24px;
  overflow-y: auto;
}

.live-cam-perm-card {
  position: relative;
  max-width: 390px;
  width: 100%;
  text-align: center;
  background: linear-gradient(165deg, rgba(31, 29, 27, 0.96) 0%, rgba(20, 26, 18, 0.96) 100%);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(184, 147, 90, 0.45);
  border-radius: 26px;
  padding: 34px 24px 26px;
  color: #FFFFFF;
  box-shadow: 0 24px 56px rgba(0, 0, 0, 0.55), inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.live-cam-perm-close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.24);
  background: rgba(255, 255, 255, 0.08);
  color: #FFFFFF;
  font-size: 1.4rem;
  line-height: 1;
  display: grid;
  place-items: center;
  cursor: pointer;
  transition: background 0.2s ease, transform 0.15s ease;
}

.live-cam-perm-close:hover,
.live-cam-perm-close:active {
  background: rgba(184, 147, 90, 0.32);
  transform: scale(0.95);
}

.live-cam-perm-icon {
  width: 66px;
  height: 66px;
  margin: 0 auto 16px;
  border-radius: 50%;
  background: var(--gold-gradient);
  color: #1F1D1B;
  display: grid;
  place-items: center;
  box-shadow: 0 0 0 8px rgba(184, 147, 90, 0.14), 0 10px 24px rgba(184, 147, 90, 0.32);
}

.live-cam-perm-card h3 {
  font-family: var(--font-serif);
  font-size: 1.55rem;
  margin-bottom: 8px;
}

.live-cam-perm-card p {
  font-size: 0.86rem;
  color: rgba(240, 245, 236, 0.82);
  margin-bottom: 20px;
  line-height: 1.5;
}

.live-cam-perm-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
  width: 100%;
}

.live-cam-perm-actions .btn {
  width: 100%;
  justify-content: center;
}

.btn-outline-light {
  background: rgba(255, 255, 255, 0.08);
  color: #FAF8F5;
  border: 1px solid rgba(226, 217, 204, 0.45);
  border-radius: 999px;
  padding: 12px 20px;
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s ease, border-color 0.2s ease, transform 0.15s ease;
}

.btn-outline-light:hover,
.btn-outline-light:active {
  background: rgba(184, 147, 90, 0.22);
  border-color: rgba(226, 217, 204, 0.78);
}

.live-cam-perm-dismiss {
  background: transparent;
  border: none;
  color: rgba(240, 245, 236, 0.72);
  font-size: 0.84rem;
  font-weight: 500;
  padding: 8px 12px;
  margin-top: 2px;
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 3px;
  transition: color 0.2s ease;
}

.live-cam-perm-dismiss:hover {
  color: #FFFFFF;
}

.live-cam-item-preview {
  position: absolute;
  inset: 0;
  z-index: 22;
  background: #000000;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.live-cam-item-preview img,
.live-cam-item-preview video {
  max-width: 100%;
  max-height: calc(100% - 88px);
  object-fit: contain;
}

.live-cam-preview-actions {
  position: absolute;
  bottom: 20px;
  left: 0;
  right: 0;
  display: flex;
  justify-content: center;
  gap: 12px;
  padding: 0 16px;
}

.btn-danger-soft {
  background: rgba(211, 47, 47, 0.9);
  color: #FFFFFF;
  border: 1px solid rgba(255, 255, 255, 0.25);
}

/* Panel Inferior de la Cámara En Vivo */
.live-cam-bottom {
  position: relative;
  z-index: 15;
  background: linear-gradient(180deg, rgba(10, 13, 9, 0.78) 0%, #141210 30%);
  padding: 12px 16px calc(20px + env(safe-area-inset-bottom, 0px));
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.live-cam-tray-wrap {
  width: 100%;
  overflow-x: auto;
  scrollbar-width: thin;
  scroll-behavior: smooth;
}

.live-cam-mode-switch {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  margin: 0 auto;
  padding: 3px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.16);
  backdrop-filter: blur(8px);
}

.live-cam-mode-tab {
  min-width: 76px;
  min-height: 34px;
  padding: 6px 16px;
  border-radius: 999px;
  border: none;
  background: transparent;
  color: rgba(255, 255, 255, 0.72);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  cursor: pointer;
  transition: background 0.18s ease, color 0.18s ease, transform 0.14s ease;
}

.live-cam-mode-tab.is-active {
  background: var(--gold-gradient);
  color: #FFFFFF;
  box-shadow: 0 3px 12px rgba(184, 147, 90, 0.42);
}

.live-cam-mode-tab:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.live-cam-tray {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 4px 2px;
  min-width: max-content;
}

.cam-tray-thumb {
  position: relative;
  width: 58px;
  height: 58px;
  border-radius: 12px;
  overflow: hidden;
  border: 2px solid var(--color-gold);
  background: #1B2118;
  cursor: pointer;
  flex-shrink: 0;
  animation: tilePopIn 0.24s ease both;
}

.cam-tray-thumb img,
.cam-tray-thumb video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.cam-tray-remove {
  position: absolute;
  top: 2px;
  right: 2px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  border: none;
  background: rgba(211, 47, 47, 0.92);
  color: #FFFFFF;
  font-size: 13px;
  line-height: 1;
  display: grid;
  place-items: center;
  cursor: pointer;
}

.cam-tray-vid-tag {
  position: absolute;
  bottom: 2px;
  left: 2px;
  background: rgba(0, 0, 0, 0.72);
  color: #FFFFFF;
  font-size: 0.56rem;
  padding: 1px 4px;
  border-radius: 4px;
  font-weight: 700;
}

.live-cam-controls-row {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 12px;
  max-width: 540px;
  width: 100%;
  margin: 0 auto;
}

.live-cam-left-slot {
  text-align: left;
}

.live-cam-hint {
  font-size: 0.74rem;
  color: rgba(255, 255, 255, 0.72);
  font-weight: 500;
}

.live-cam-center-slot {
  display: flex;
  justify-content: center;
}

.live-cam-right-slot {
  display: flex;
  justify-content: flex-end;
}

.live-cam-upload-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 18px;
  border-radius: 999px;
  border: 1.5px solid rgba(255, 255, 255, 0.65);
  background: var(--gold-gradient);
  color: #1F1D1B;
  font-size: 0.84rem;
  font-weight: 800;
  cursor: pointer;
  box-shadow: 0 6px 22px rgba(184, 147, 90, 0.5);
  transition: transform 0.2s ease;
}

.live-cam-upload-btn:active {
  transform: scale(0.95);
}

.upload-batch-badge {
  min-width: 22px;
  height: 22px;
  padding: 0 6px;
  border-radius: 999px;
  background: #1F1D1B;
  color: var(--color-gold-light);
  font-size: 0.74rem;
  display: inline-grid;
  place-items: center;
}

/* Modal de Selección Post-Captura (Elegir qué publicar o guardar en temporales) */
.capture-review-modal {
  position: fixed;
  inset: 0;
  z-index: 9500;
  display: none;
  background: rgba(18, 22, 16, 0.72);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  padding: env(safe-area-inset-top, 0px) 0 env(safe-area-inset-bottom, 0px);
}

.capture-review-modal.is-open {
  display: flex;
  align-items: flex-end;
  justify-content: center;
  animation: camFadeIn 0.2s ease both;
}

.capture-review-shell {
  width: 100%;
  max-width: 680px;
  height: 100%;
  max-height: 100dvh;
  background: var(--color-ivory, #FAF8F5);
  color: var(--color-ink, #2B2A26);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.35);
}

@media (min-width: 640px) {
  .capture-review-modal.is-open {
    align-items: center;
    padding: 20px;
  }

  .capture-review-shell {
    height: auto;
    max-height: 88dvh;
    border-radius: 24px;
    border: 1px solid rgba(184, 147, 90, 0.32);
  }
}

.capture-review-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 18px 12px;
  border-bottom: 1px solid rgba(31, 29, 27, 0.12);
  background: rgba(255, 255, 255, 0.72);
}

.capture-review-heading {
  min-width: 0;
}

.capture-review-title {
  font-family: var(--font-serif);
  font-size: 1.45rem;
  font-weight: 600;
  line-height: 1.15;
  color: var(--color-olive-dark, #2B2724);
  margin: 0;
}

.capture-review-subtitle {
  margin: 3px 0 0;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--color-olive, #2E2A27);
}

.capture-review-close {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 1px solid rgba(31, 29, 27, 0.2);
  background: #FFFFFF;
  color: var(--color-olive-dark, #2B2724);
  display: grid;
  place-items: center;
  cursor: pointer;
  flex-shrink: 0;
  transition: background 0.18s ease, transform 0.15s ease;
}

.capture-review-close:active {
  transform: scale(0.94);
}

.capture-review-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
  padding: 10px 18px;
  background: rgba(250, 248, 245, 0.92);
  border-bottom: 1px solid rgba(31, 29, 27, 0.08);
}

.capture-review-count {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--color-text-muted, #6A6860);
}

.capture-review-quick-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.capture-review-body {
  flex: 1;
  overflow-y: auto;
  padding: 14px 16px;
  -webkit-overflow-scrolling: touch;
}

.capture-review-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

@media (min-width: 420px) {
  .capture-review-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (min-width: 640px) {
  .capture-review-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
  }
}

.capture-review-grid .standby-tile {
  opacity: 0.72;
  transition: opacity 0.18s ease, transform 0.18s ease, box-shadow 0.18s ease;
}

.capture-review-grid .standby-tile.is-selected {
  opacity: 1;
}

.capture-review-empty {
  text-align: center;
  padding: 36px 18px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  color: var(--color-text-muted, #6A6860);
  font-size: 0.9rem;
}

.capture-review-footer {
  padding: 12px 16px calc(14px + env(safe-area-inset-bottom, 0px));
  border-top: 1px solid rgba(31, 29, 27, 0.14);
  background: #FFFFFF;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.capture-review-note {
  margin: 0;
  font-size: 0.74rem;
  line-height: 1.4;
  color: var(--color-text-muted, #6A6860);
  text-align: center;
}

.capture-review-secondary-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
}

.capture-review-btn-more,
.capture-review-btn-cancel {
  min-height: 44px;
  padding: 10px 14px;
  border-radius: 999px;
  font-size: 0.84rem;
  font-weight: 600;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  transition: background 0.18s ease, transform 0.15s ease;
}

.capture-review-btn-more {
  border: 1.5px solid rgba(31, 29, 27, 0.35);
  background: rgba(31, 29, 27, 0.08);
  color: var(--color-olive-dark, #2B2724);
}

.capture-review-btn-more:hover {
  background: rgba(31, 29, 27, 0.14);
}

.capture-review-btn-cancel {
  border: 1px solid rgba(31, 29, 27, 0.22);
  background: transparent;
  color: var(--color-text-muted, #5C5B54);
  padding-inline: 18px;
}

.capture-review-btn-cancel:hover {
  background: rgba(31, 29, 27, 0.06);
}

.capture-review-btn-publish {
  width: 100%;
  min-height: 48px;
  padding: 12px 18px;
  border-radius: 999px;
  border: none;
  background: var(--gold-gradient);
  color: #FFFFFF;
  font-size: 0.94rem;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  box-shadow: 0 8px 22px rgba(184, 147, 90, 0.36);
  transition: transform 0.16s ease, opacity 0.16s ease;
}

.capture-review-btn-publish:disabled {
  opacity: 0.45;
  cursor: not-allowed;
  box-shadow: none;
}

.capture-review-btn-publish:not(:disabled):active {
  transform: scale(0.98);
}

@media (prefers-reduced-motion: reduce) {
  .capture-review-modal.is-open {
    animation: none;
  }
}

/* =====================================================================
   LIBRO DE FIRMAS — LIBRO NUPCIAL INTERACTIVO 3D (TAMAÑO PANTALLA, SIN SCROLL)
   ===================================================================== */
html:has(body.page-guestbook) {
  height: 100vh;
  height: 100dvh;
  overflow: hidden;
}

.page-guestbook {
  height: 100vh;
  height: 100dvh;
  min-height: 0;
  overflow: hidden;
}

.book-page-main {
  height: 100vh;
  height: 100dvh;
  padding: calc(70px + env(safe-area-inset-top, 0px)) 12px calc(12px + env(safe-area-inset-bottom, 0px));
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.wedding-book-stage {
  width: 100%;
  max-width: 600px;
  height: 100%;
  max-height: 860px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
}

/* Pasta dura del libro */
.wedding-book-cover {
  position: relative;
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  background: linear-gradient(145deg, #2B2724 0%, #1F1D1B 60%, #171513 100%);
  padding: 9px 10px 10px 18px;
  border-radius: 10px 22px 22px 10px;
  box-shadow:
    0 22px 52px rgba(31, 29, 27, 0.28),
    0 6px 16px rgba(31, 29, 27, 0.16),
    inset 1px 1px 0 rgba(226, 217, 204, 0.28);
  overflow: hidden;
}

/* Lomo del libro */
.wedding-book-spine {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  width: 16px;
  border-radius: 10px 0 0 10px;
  background: linear-gradient(90deg, #131910 0%, #2C3826 55%, #12180F 100%);
  border-right: 1px solid rgba(184, 147, 90, 0.35);
  z-index: 3;
}

/* Listón separador dorado */
.wedding-book-ribbon {
  position: absolute;
  top: -3px;
  right: 28px;
  width: 15px;
  height: 30px;
  background: var(--gold-gradient);
  clip-path: polygon(0 0, 100% 0, 100% 100%, 50% 78%, 0 100%);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.22);
  z-index: 6;
  pointer-events: none;
}

/* Contenedor interior del libro */
.wedding-book-sheet {
  position: relative;
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  background:
    linear-gradient(90deg, rgba(31, 29, 27, 0.08) 0%, rgba(250, 248, 245, 0) 5%),
    linear-gradient(180deg, #FAF8F5 0%, #FBF5E9 100%);
  border-radius: 4px;
  border: 1px solid rgba(184, 147, 90, 0.42);
  padding: 14px 16px 12px;
  box-shadow: inset 0 0 0 3px rgba(250, 248, 245, 0.88), inset 0 0 0 4px rgba(184, 147, 90, 0.2);
  overflow: hidden;
}

@media (max-width: 600px) {
  .book-page-main {
    padding: calc(68px + env(safe-area-inset-top, 0px)) 8px calc(8px + env(safe-area-inset-bottom, 0px));
  }

  .wedding-book-cover {
    padding: 7px 7px 8px 14px;
    border-radius: 8px 18px 18px 8px;
  }

  .wedding-book-spine {
    width: 12px;
  }

  .wedding-book-sheet {
    padding: 11px 11px 10px;
  }
}

.book-sheet-header {
  flex-shrink: 0;
  text-align: center;
  padding-bottom: 10px;
  margin-bottom: 10px;
  border-bottom: 1px solid rgba(184, 147, 90, 0.26);
}

.book-ornament {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--color-gold);
  margin-bottom: 2px;
}

.book-ornament span {
  width: 30px;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--color-gold), transparent);
}

.book-eyebrow {
  font-family: var(--font-sans);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  line-height: 1.2;
  color: var(--color-gold-dark);
  margin: 2px 0 8px;
}

.book-main-title {
  font-family: var(--font-serif);
  font-size: clamp(1.5rem, 4.8vw, 2.15rem);
  color: var(--color-olive-dark);
  line-height: 1.05;
  margin: 1px 0 9px;
}

.book-main-title span {
  font-family: var(--font-script);
  color: var(--color-gold);
  font-size: 1.15em;
  margin: 0 3px;
}

/* Selector de Hoja: Escribir / Ver Firmas */
.book-mode-bar {
  display: inline-grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
  padding: 3px;
  border-radius: 999px;
  background: rgba(31, 29, 27, 0.08);
  border: 1px solid rgba(184, 147, 90, 0.3);
  width: 100%;
  max-width: 340px;
}

.book-mode-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 7px 12px;
  border-radius: 999px;
  border: none;
  background: transparent;
  color: var(--color-text-secondary);
  font-family: var(--font-sans);
  font-size: 0.78rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.25s ease;
}

.book-mode-btn.is-active {
  background: var(--color-olive-dark);
  color: #FAF8F5;
  box-shadow: 0 4px 12px rgba(31, 29, 27, 0.22);
}

.book-count-pill {
  padding: 1px 7px;
  border-radius: 999px;
  background: rgba(184, 147, 90, 0.25);
  color: var(--color-gold-dark);
  font-size: 0.7rem;
}

.book-mode-btn.is-active .book-count-pill {
  background: var(--color-gold);
  color: #1F1D1B;
}

/* Vistas del libro */
.book-view {
  display: none;
}

.book-view.is-active {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-height: 0;
  animation: bookViewFade 0.3s cubic-bezier(0.16, 1, 0.3, 1) both;
}

.book-view-write.is-active {
  overflow-y: auto;
  scrollbar-width: thin;
}

.book-view-read.is-active {
  overflow: visible;
}

@keyframes bookViewFade {
  from {
    opacity: 0;
    transform: translateY(6px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.book-prompt-note {
  text-align: center;
  font-size: 0.82rem;
  color: var(--color-text-secondary);
  margin-bottom: 10px;
}

.book-chips-strip {
  display: flex;
  flex-wrap: nowrap;
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 4px;
  margin-bottom: 10px;
  scrollbar-width: thin;
  -webkit-overflow-scrolling: touch;
  flex-shrink: 0;
}

.book-chips-strip .gb-chip-btn {
  flex-shrink: 0;
  font-size: 0.74rem;
  padding: 6px 11px;
}

.book-form {
  display: flex;
  flex-direction: column;
  gap: 10px;
  flex: 1;
}

.book-label {
  display: block;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--color-olive);
  margin-bottom: 4px;
}

.book-input,
.book-textarea {
  width: 100%;
  padding: 10px 13px;
  border-radius: 12px;
  border: 1.5px solid rgba(184, 147, 90, 0.34);
  background: rgba(255, 255, 255, 0.92);
  font-family: var(--font-sans);
  font-size: 1rem;
  color: var(--color-olive-dark);
  outline: none;
  touch-action: manipulation;
  transition: border-color 0.22s ease, box-shadow 0.22s ease;
}

.book-textarea {
  min-height: 86px;
  resize: none;
  line-height: 1.5;
  background-image: repeating-linear-gradient(
    transparent,
    transparent 27px,
    rgba(184, 147, 90, 0.12) 28px
  );
}

.book-input:focus,
.book-textarea:focus {
  border-color: var(--color-gold);
  box-shadow: 0 0 0 3px rgba(184, 147, 90, 0.16);
}

.book-form-actions {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: auto;
  padding-top: 4px;
}

.book-submit-btn {
  width: 100%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  padding: 12px 18px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.45);
  background: var(--gold-gradient);
  color: #1F1D1B;
  font-family: var(--font-sans);
  font-size: 0.86rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  cursor: pointer;
  box-shadow: 0 8px 20px rgba(184, 147, 90, 0.35);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.book-submit-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 24px rgba(184, 147, 90, 0.46);
}

.book-secondary-btn {
  width: 100%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 9px 14px;
  border-radius: 999px;
  border: 1px solid rgba(31, 29, 27, 0.25);
  background: rgba(255, 255, 255, 0.72);
  color: var(--color-olive-dark);
  font-family: var(--font-sans);
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}

.book-secondary-btn:hover {
  background: #FFFFFF;
  border-color: var(--color-gold);
}

/* =====================================================================
   VISTA DE LECTURA: HOJA DE LIBRO REAL CON EFECTO PAGE-FLIP 3D TÁCTIL
   ===================================================================== */
.book-read-topbar {
  position: relative;
  z-index: 2;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 8px;
}

.book-read-counter {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--color-gold-dark);
}

.book-back-write-btn {
  padding: 5px 12px;
  border-radius: 999px;
  border: 1px solid rgba(184, 147, 90, 0.45);
  background: #FFFFFF;
  color: var(--color-olive-dark);
  font-size: 0.74rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
}

.book-back-write-btn:hover {
  border-color: var(--color-gold);
  background: #FAF8F5;
}

/* Escenario 3D del libro (ocupa todo el alto disponible, sin scroll) */
.book-flip-stage {
  position: relative;
  z-index: 5;
  flex: 1;
  min-height: 0;
  perspective: 1800px;
  perspective-origin: 42% 50%;
  touch-action: none;
  user-select: none;
  -webkit-user-select: none;
  cursor: grab;
  border-radius: 3px;
}

.book-flip-stage.is-dragging {
  cursor: grabbing;
}

/* Ilusión de bloque de hojas apiladas en el borde derecho */
.book-pages-stack {
  position: absolute;
  top: 0px;
  bottom: 0px;
  right: 0;
  width: 9px;
  border-radius: 3px;
  background:
    repeating-linear-gradient(
      90deg,
      #EDE2CE 0px,
      #FAF8F5 1.5px,
      #E3D5BC 3px
    );
  border: 1px solid rgba(182, 152, 98, 0.45);
  border-left: none;
  box-shadow: 2px 3px 8px rgba(31, 29, 27, 0.12);
  transition: width 0.3s ease, opacity 0.3s ease;
  pointer-events: none;
  z-index: 1;
}

.book-pages-stack[data-depth="0"] {
  width: 0;
  opacity: 0;
}

.book-pages-stack[data-depth="1"] {
  width: 4px;
  opacity: 0.85;
}

.book-pages-stack[data-depth="2"] {
  width: 7px;
  opacity: 0.95;
}

.book-pages-stack[data-depth="3"] {
  width: 10px;
  opacity: 1;
}

/* Contenedor de StPageFlip (física real de doblado de hoja) */
.book-flip-host-wrap {
  position: absolute;
  inset: 0 9px 0 0;
  z-index: 4;
  border-radius: 3px;
}

.book-flip-host {
  width: 100%;
  height: 100%;
}

/* Estilos base oficiales de StPageFlip (ajustados a móvil sin scroll) */
.book-flip-host-wrap .stf__parent {
  position: relative;
  display: block;
  box-sizing: border-box;
  transform: translateZ(0);
  -ms-touch-action: none;
  touch-action: none;
  margin: 0 auto;
}

.book-flip-host-wrap .stf__wrapper,
.book-flip-host-wrap .sft__wrapper {
  position: relative;
  width: 100%;
  height: 100%;
  box-sizing: border-box;
}

.book-flip-host-wrap .stf__parent canvas {
  position: absolute;
  width: 100%;
  height: 100%;
  left: 0;
  top: 0;
}

.book-flip-host-wrap .stf__block {
  position: absolute;
  width: 100%;
  height: 100%;
  box-sizing: border-box;
  perspective: 2000px;
}

.book-flip-host-wrap .stf__item {
  display: none;
  position: absolute;
  transform-style: preserve-3d;
}

.book-flip-host-wrap .stf__outerShadow,
.book-flip-host-wrap .stf__innerShadow,
.book-flip-host-wrap .stf__hardShadow,
.book-flip-host-wrap .stf__hardInnerShadow {
  position: absolute;
  left: 0;
  top: 0;
  pointer-events: none;
}

.book-stf-page {
  width: 100%;
  height: 100%;
  overflow: hidden;
  border-radius: 3px;
  box-shadow: 0 4px 14px rgba(31, 29, 27, 0.12);
}

.book-stf-page .book-paper-page {
  width: 100%;
  height: 100%;
}

/* Sutil esquina doblada decorativa en la esquina inferior derecha */
.book-paper-corner-hint {
  position: absolute;
  right: 0;
  bottom: 0;
  width: 28px;
  height: 28px;
  background: linear-gradient(
    315deg,
    #E6D6B8 0%,
    #F5EAD4 46%,
    #FFFDF7 51%,
    transparent 52%
  );
  box-shadow: -2px -2px 6px rgba(31, 29, 27, 0.11);
  border-top-left-radius: 5px;
  pointer-events: none;
  z-index: 4;
}

/* =====================================================================
   HOJA DE PERGAMINO INTERIOR Y FIRMAS MANUSCRITAS
   ===================================================================== */
.book-paper-page {
  position: relative;
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  padding: 10px 14px 7px 24px;
  background:
    /* Sombra del doblez izquierdo (lomo) */
    linear-gradient(
      90deg,
      rgba(36, 46, 30, 0.15) 0%,
      rgba(36, 46, 30, 0.05) 3.5%,
      rgba(250, 248, 245, 0) 10%
    ),
    /* Margen vertical sutil tipo cuaderno de honor */
    linear-gradient(
      90deg,
      transparent 16px,
      rgba(184, 147, 90, 0.24) 16px,
      rgba(184, 147, 90, 0.24) 17px,
      transparent 17px
    ),
    /* Renglones muy tenues de papel de firmas */
    repeating-linear-gradient(
      180deg,
      transparent 0px,
      transparent 29px,
      rgba(184, 147, 90, 0.1) 30px
    ),
    /* Tono papel algodón cálido */
    linear-gradient(170deg, #FAF8F5 0%, #FDF7EA 58%, #F8EEDB 100%);
  border: 1px solid rgba(196, 162, 99, 0.44);
  border-radius: 3px;
  overflow: hidden;
}

.book-paper-running-head {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-bottom: 5px;
  margin-bottom: 4px;
  border-bottom: 1px solid rgba(184, 147, 90, 0.28);
  font-family: var(--font-serif);
  font-size: 0.72rem;
  font-style: italic;
  letter-spacing: 0.06em;
  color: rgba(124, 96, 42, 0.85);
}

.book-paper-entries {
  flex: 1;
  min-height: 0;
  display: grid;
  grid-template-rows: repeat(var(--page-slots, 5), minmax(0, 1fr));
  gap: 2px;
  overflow: hidden;
}

/* Cada firma escrita directamente sobre el papel */
.book-signature-entry {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: 0;
  overflow: visible;
  padding: 3px 10px 4px;
  border-bottom: 1px dashed rgba(184, 147, 90, 0.3);
  transition: background-color 0.2s ease;
}

.book-signature-entry:last-child {
  border-bottom: none;
}

.book-signature-entry:nth-child(odd) {
  transform: rotate(-0.3deg);
  padding-right: 12px;
}

.book-signature-entry:nth-child(even) {
  transform: rotate(0.28deg);
  padding-left: 12px;
}

.book-signature-entry.is-clickable {
  cursor: pointer;
}

.book-signature-entry.is-clickable:active {
  background-color: rgba(184, 147, 90, 0.08);
  border-radius: 8px;
}

.book-sig-message {
  margin: -0.08em -0.14em 2px -0.1em;
  padding: 0.14em 0.22em 0.12em 0.14em;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: var(--sig-lines, 2);
  overflow: hidden;
  text-overflow: ellipsis;
  word-break: break-word;
  overflow-wrap: anywhere;
}

.book-sig-footer {
  display: flex;
  align-items: baseline;
  justify-content: flex-end;
  gap: 8px;
  flex-shrink: 0;
  min-width: 0;
}

.book-sig-author {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
  padding: 0.14em 0.26em 0.14em 0.16em;
  margin: -0.1em -0.16em -0.1em 0;
  opacity: 0.86;
}

/* =====================================================================
   LAS 7 TIPOGRAFÍAS MANUSCRITAS (CALIBRADAS PARA 5 FIRMAS SIN RECORTES)
   ===================================================================== */

/* 1. Ballet — Caligrafía Spenceriana ornamentada (trazos altos y fluidos) */
.sig-font-ballet .book-sig-message {
  font-family: 'Ballet', cursive;
  font-size: clamp(0.92rem, 2.9vw, 1.16rem);
  line-height: 1.48;
  padding: 0.22em 0.34em 0.2em 0.24em;
  margin: -0.14em -0.2em 1px -0.16em;
  color: #3E232C;
}

.sig-font-ballet .book-sig-author {
  font-family: 'Ballet', cursive;
  font-size: clamp(0.76rem, 2.2vw, 0.92rem);
  line-height: 1.38;
  padding: 0.18em 0.32em 0.18em 0.22em;
  color: #6E3345;
}

/* 2. Lavishly Yours — Caligrafía fluida y elegante */
.sig-font-lavishly_yours .book-sig-message {
  font-family: 'Lavishly Yours', cursive;
  font-size: clamp(1.12rem, 3.6vw, 1.44rem);
  line-height: 1.24;
  padding: 0.18em 0.28em 0.16em 0.18em;
  color: #242E1F;
}

.sig-font-lavishly_yours .book-sig-author {
  font-family: 'Lavishly Yours', cursive;
  font-size: clamp(0.84rem, 2.4vw, 1.02rem);
  line-height: 1.22;
  padding: 0.16em 0.28em 0.14em 0.18em;
  color: #2E2A27;
}

/* 3. Tangerine — Caligrafía nupcial clásica estilizada */
.sig-font-tangerine .book-sig-message {
  font-family: 'Tangerine', cursive;
  font-size: clamp(1.2rem, 3.9vw, 1.54rem);
  font-weight: 700;
  line-height: 1.16;
  padding: 0.14em 0.24em 0.14em 0.14em;
  color: #3B2B1E;
}

.sig-font-tangerine .book-sig-author {
  font-family: 'Tangerine', cursive;
  font-size: clamp(0.9rem, 2.6vw, 1.08rem);
  font-weight: 700;
  line-height: 1.15;
  padding: 0.12em 0.24em 0.12em 0.14em;
  color: #7D5920;
}

/* 4. Annie Use Your Telescope — Letra manuscrita alta y espontánea */
.sig-font-annie_use_your_telescope .book-sig-message {
  font-family: 'Annie Use Your Telescope', cursive;
  font-size: clamp(0.88rem, 2.7vw, 1.08rem);
  line-height: 1.26;
  padding: 0.1em 0.16em 0.1em 0.1em;
  color: #253646;
}

.sig-font-annie_use_your_telescope .book-sig-author {
  font-family: 'Annie Use Your Telescope', cursive;
  font-size: clamp(0.7rem, 2vw, 0.84rem);
  font-weight: 600;
  line-height: 1.2;
  padding: 0.1em 0.16em;
  color: #364B5E;
}

/* 5. Indie Flower — Letra a mano casual y amigable */
.sig-font-indie_flower .book-sig-message {
  font-family: 'Indie Flower', cursive;
  font-size: clamp(0.8rem, 2.4vw, 0.96rem);
  line-height: 1.28;
  padding: 0.08em 0.14em;
  color: #253646;
}

.sig-font-indie_flower .book-sig-author {
  font-family: 'Indie Flower', cursive;
  font-size: clamp(0.64rem, 1.85vw, 0.74rem);
  font-weight: 600;
  line-height: 1.2;
  padding: 0.08em 0.14em;
  color: #364B5E;
}

/* 6. Oooh Baby — Manuscrita cálida y natural */
.sig-font-oooh_baby .book-sig-message {
  font-family: 'Oooh Baby', cursive;
  font-size: clamp(0.94rem, 3vw, 1.18rem);
  line-height: 1.26;
  padding: 0.12em 0.2em 0.12em 0.12em;
  color: #2F3A28;
}

.sig-font-oooh_baby .book-sig-author {
  font-family: 'Oooh Baby', cursive;
  font-size: clamp(0.74rem, 2.1vw, 0.88rem);
  line-height: 1.2;
  padding: 0.1em 0.2em;
  color: #55664B;
}

/* 7. Italianno — Caligrafía italiana refinada */
.sig-font-italianno .book-sig-message {
  font-family: 'Italianno', cursive;
  font-size: clamp(1.18rem, 3.8vw, 1.5rem);
  line-height: 1.18;
  padding: 0.16em 0.28em 0.14em 0.16em;
  color: #352820;
}

.sig-font-italianno .book-sig-author {
  font-family: 'Italianno', cursive;
  font-size: clamp(0.88rem, 2.5vw, 1.06rem);
  line-height: 1.16;
  padding: 0.14em 0.26em 0.14em 0.16em;
  color: #7A5630;
}

/* Ajuste fino cuando hay 4 firmas por página (espacio más holgado) */
.book-paper-entries[data-slots="4"] .sig-font-ballet .book-sig-message {
  font-size: clamp(1rem, 3.2vw, 1.26rem);
}
.book-paper-entries[data-slots="4"] .sig-font-lavishly_yours .book-sig-message {
  font-size: clamp(1.2rem, 3.9vw, 1.54rem);
}
.book-paper-entries[data-slots="4"] .sig-font-tangerine .book-sig-message {
  font-size: clamp(1.28rem, 4.2vw, 1.66rem);
}
.book-paper-entries[data-slots="4"] .sig-font-annie_use_your_telescope .book-sig-message {
  font-size: clamp(0.94rem, 2.9vw, 1.14rem);
}
.book-paper-entries[data-slots="4"] .sig-font-indie_flower .book-sig-message {
  font-size: clamp(0.84rem, 2.5vw, 1rem);
}
.book-paper-entries[data-slots="4"] .sig-font-oooh_baby .book-sig-message {
  font-size: clamp(1rem, 3.2vw, 1.26rem);
}
.book-paper-entries[data-slots="4"] .sig-font-italianno .book-sig-message {
  font-size: clamp(1.26rem, 4.1vw, 1.62rem);
}

/* Estado vacío sobre el pergamino */
.book-paper-empty {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 20px 14px;
  color: var(--color-olive);
}

.book-paper-empty-title {
  font-family: 'Italianno', cursive;
  font-size: clamp(2rem, 6.2vw, 2.55rem);
  color: var(--color-olive-dark);
  margin-bottom: 6px;
}

.book-paper-empty-sub {
  font-size: 0.82rem;
  color: var(--color-text-secondary);
  max-width: 280px;
}

/* Pie integrado dentro de cada hoja: pista táctil + flechas en las esquinas */
.book-paper-footer {
  position: relative;
  z-index: 5;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  margin: 4px -7px 0 -4px;
  padding-top: 5px;
  border-top: 1px solid rgba(184, 147, 90, 0.26);
}

.book-paper-corner-btn {
  position: relative;
  width: 28px;
  height: 28px;
  padding: 0;
  display: inline-grid;
  place-items: center;
  border-radius: 50%;
  border: 1px solid rgba(184, 147, 90, 0.5);
  background: rgba(250, 248, 245, 0.86);
  color: var(--color-olive-dark);
  font-family: var(--font-sans);
  font-size: 0.84rem;
  font-weight: 700;
  line-height: 1;
  cursor: pointer;
  flex-shrink: 0;
  box-shadow: 0 1px 4px rgba(31, 29, 27, 0.08);
  transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease, transform 0.15s ease;
}

/* Área táctil ampliada para facilidad en móvil sin perder sutileza visual */
.book-paper-corner-btn::after {
  content: '';
  position: absolute;
  inset: -6px;
  border-radius: 50%;
}

.book-paper-corner-btn:hover:not(:disabled) {
  background: var(--color-olive-dark);
  color: #FAF8F5;
  border-color: var(--color-olive-dark);
}

.book-paper-corner-btn:active:not(:disabled) {
  transform: scale(0.92);
}

.book-paper-corner-btn:disabled {
  opacity: 0.26;
  cursor: default;
  box-shadow: none;
}

.book-paper-corner-btn.is-hidden {
  visibility: hidden;
  pointer-events: none;
}

.book-paper-swipe-hint {
  flex: 1;
  min-width: 0;
  text-align: center;
  font-family: var(--font-serif);
  font-size: 0.75rem;
  font-style: italic;
  letter-spacing: 0.02em;
  line-height: 1.18;
  color: rgba(124, 96, 42, 0.88);
  padding: 0 2px;
}

/* Modal ligero para leer dedicatorias largas completas */
.book-sig-modal {
  position: fixed;
  inset: 0;
  z-index: 2500;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
  background: rgba(31, 29, 27, 0.56);
  backdrop-filter: blur(5px);
  -webkit-backdrop-filter: blur(5px);
}

.book-sig-modal.is-open {
  display: flex;
  animation: bookViewFade 0.22s ease both;
}

.book-sig-modal-card {
  position: relative;
  width: 100%;
  max-width: 440px;
  max-height: 78dvh;
  overflow-y: auto;
  padding: 26px 22px 22px;
  border-radius: 16px;
  background: linear-gradient(170deg, #FAF8F5 0%, #F8EEDB 100%);
  border: 1px solid rgba(184, 147, 90, 0.55);
  box-shadow: 0 24px 60px rgba(31, 29, 27, 0.35), inset 0 0 0 4px rgba(250, 248, 245, 0.9);
  text-align: center;
}

.book-sig-modal-close {
  position: absolute;
  top: 10px;
  right: 12px;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  border: 1px solid rgba(184, 147, 90, 0.1);
  background: rgba(255, 255, 255, 0.5);
  color: var(--color-olive-dark);
  font-size: 1.2rem;
  line-height: 1;
  cursor: pointer;
}

.book-sig-modal-ornament {
  color: var(--color-gold);
  font-size: 0.95rem;
  margin-bottom: 10px;
}

.book-sig-modal-body .book-sig-message {
  display: block;
  -webkit-line-clamp: unset;
  overflow: visible;
  margin: 0 0 14px;
  padding: 0.16em 0.24em;
}

.book-sig-modal-body .book-sig-footer {
  justify-content: center;
  flex-wrap: wrap;
}

.book-sig-modal-body .book-sig-author {
  white-space: normal;
  overflow: visible;
  margin: 0;
  padding: 0.14em 0.24em;
  max-width: 100%;
}

/* =====================================================================
   ANIMACIÓN DE CARGA: PLUMA FIRMANDO EL LIBRO
   ===================================================================== */
.book-signing-overlay {
  position: absolute;
  inset: 0;
  z-index: 30;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  border-radius: 4px 15px 15px 4px;
  background:
    radial-gradient(circle at 50% 42%, rgba(250, 248, 245, 0.98) 0%, rgba(248, 238, 219, 0.96) 100%);
  backdrop-filter: blur(5px);
  -webkit-backdrop-filter: blur(5px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.28s ease;
}

.book-signing-overlay.is-active {
  opacity: 1;
  pointer-events: auto;
}

.book-signing-stage {
  width: 100%;
  max-width: 300px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.book-signing-svg {
  width: 100%;
  max-width: 280px;
  height: auto;
  overflow: visible;
  filter: drop-shadow(0 6px 14px rgba(31, 29, 27, 0.14));
  margin-bottom: 10px;
}

.book-signing-title {
  font-family: var(--font-serif);
  font-size: 1.2rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  color: var(--color-olive-dark);
  margin-bottom: 4px;
  animation: signingTextPulse 1.4s ease-in-out infinite;
}

.book-signing-author {
  font-family: 'Italianno', cursive;
  font-size: 1.85rem;
  line-height: 1.1;
  color: var(--color-gold-dark);
  min-height: 1.9rem;
  max-width: 100%;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

@keyframes signingTextPulse {
  0%, 100% {
    opacity: 0.72;
  }
  50% {
    opacity: 1;
  }
}

.book-submit-btn:disabled {
  opacity: 0.65;
  cursor: wait;
  transform: none;
}

/* Teléfonos muy compactos en altura (ej. iPhone SE 667px o Android 640px) */
@media (max-height: 700px) {
  .book-sheet-header {
    padding-bottom: 7px;
    margin-bottom: 7px;
  }

  .book-ornament {
    display: none;
  }

  .book-eyebrow {
    font-size: 0.62rem;
    margin: 0 0 6px;
  }

  .book-mode-btn {
    padding: 6px 10px;
    font-size: 0.74rem;
  }

  .book-paper-page {
    padding: 8px 12px 6px 20px;
  }

  .book-paper-footer {
    margin: 3px -6px 0 -2px;
    padding-top: 4px;
  }

  .book-paper-corner-btn {
    width: 26px;
    height: 26px;
    font-size: 0.78rem;
  }

  .book-paper-swipe-hint {
    font-size: 0.7rem;
  }
}

/* Galería: ajustar padding superior en móvil para la barra hamburguesa fija */
@media (max-width: 768px) {
  .gallery-screen-header {
    padding: calc(84px + env(safe-area-inset-top, 0px)) 16px 20px;
  }
}

/* =====================================================================
   BLOQUEO ELEGANTE DE ORIENTACIÓN HORIZONTAL EN TELÉFONOS
   (Evita que la página se reacomode en horizontal; permite giro libre
    únicamente en Cámara en Vivo y Visor Lightbox de fotos/videos)
   ===================================================================== */
.orientation-lock-overlay {
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100vh;
  height: 100dvh;
  z-index: 999990;
  display: none;
  align-items: center;
  justify-content: center;
  padding:
    calc(18px + env(safe-area-inset-top, 0px))
    calc(24px + env(safe-area-inset-right, 0px))
    calc(18px + env(safe-area-inset-bottom, 0px))
    calc(24px + env(safe-area-inset-left, 0px));
  background:
    radial-gradient(ellipse at 20% 18%, rgba(184, 147, 90, 0.2) 0%, transparent 52%),
    radial-gradient(ellipse at 82% 84%, rgba(106, 123, 97, 0.26) 0%, transparent 56%),
    linear-gradient(155deg, #151C12 0%, #222D1D 52%, #121810 100%);
  color: #FAF8F5;
  opacity: 0;
  pointer-events: none;
  user-select: none;
  overscroll-behavior: none;
  touch-action: none;
}

.orientation-lock-card {
  position: relative;
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  gap: 28px;
  width: min(100%, 540px);
  padding: 24px 30px;
  border-radius: 24px;
  background: linear-gradient(165deg, rgba(34, 45, 29, 0.86) 0%, rgba(18, 24, 16, 0.92) 100%);
  border: 1px solid rgba(184, 147, 90, 0.42);
  box-shadow:
    0 24px 60px rgba(0, 0, 0, 0.55),
    inset 0 1px 0 rgba(226, 217, 204, 0.18),
    0 0 0 4px rgba(184, 147, 90, 0.08);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}

.orientation-lock-visual {
  position: relative;
  width: 84px;
  height: 84px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.orientation-phone-frame {
  width: 44px;
  height: 74px;
  border-radius: 11px;
  border: 2px solid var(--color-gold-light);
  background: linear-gradient(160deg, rgba(184, 147, 90, 0.18) 0%, rgba(20, 26, 18, 0.9) 100%);
  box-shadow: 0 8px 22px rgba(0, 0, 0, 0.4), 0 0 18px rgba(184, 147, 90, 0.24);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  padding: 6px 4px;
  transform-origin: center center;
  animation: orientationPhoneTurn 2.6s cubic-bezier(0.45, 0.05, 0.25, 1) infinite;
}

.orientation-phone-notch {
  width: 14px;
  height: 2.5px;
  border-radius: 999px;
  background: rgba(226, 217, 204, 0.65);
}

.orientation-phone-monogram {
  font-family: var(--font-serif);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--color-gold-light);
  line-height: 1;
}

.orientation-phone-bar {
  width: 16px;
  height: 2px;
  border-radius: 999px;
  background: rgba(226, 217, 204, 0.5);
}

.orientation-rotate-arrow {
  position: absolute;
  top: -4px;
  right: -4px;
  color: var(--color-gold);
  opacity: 0.9;
  filter: drop-shadow(0 2px 6px rgba(0, 0, 0, 0.45));
  animation: orientationArrowPulse 2.6s ease-in-out infinite;
}

@keyframes orientationPhoneTurn {
  0%, 18% {
    transform: rotate(-90deg);
  }
  52%, 82% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(-90deg);
  }
}

@keyframes orientationArrowPulse {
  0%, 18% {
    opacity: 0.95;
    transform: scale(1) rotate(0deg);
  }
  52%, 82% {
    opacity: 0.35;
    transform: scale(0.92) rotate(-25deg);
  }
  100% {
    opacity: 0.95;
    transform: scale(1) rotate(0deg);
  }
}

.orientation-lock-copy {
  text-align: left;
  min-width: 0;
}

.orientation-lock-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-sans);
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--color-gold-light);
  margin-bottom: 6px;
}

.orientation-lock-eyebrow span:first-child,
.orientation-lock-eyebrow span:last-child {
  display: inline-block;
  width: 16px;
  height: 1px;
  background: rgba(184, 147, 90, 0.5);
}

.orientation-lock-eyebrow i {
  font-style: normal;
  font-size: 0.62rem;
  color: var(--color-gold);
}

.orientation-lock-title {
  font-family: var(--font-serif);
  font-size: clamp(1.45rem, 3.4vw, 1.95rem);
  font-weight: 600;
  color: #FFFFFF;
  line-height: 1.15;
  margin-bottom: 6px;
}

.orientation-lock-desc {
  font-family: var(--font-sans);
  font-size: 0.84rem;
  line-height: 1.48;
  color: rgba(244, 240, 232, 0.8);
  margin: 0;
}

/* Activación instantánea por CSS en teléfonos horizontales (sin esperar al teclado virtual: min-width: 520px) */
@media (pointer: coarse) and (orientation: landscape) and (min-width: 520px) and (max-height: 520px) {
  html:not(.allow-landscape-mode) .orientation-lock-overlay {
    display: flex;
    opacity: 1;
    pointer-events: auto;
  }

  html:not(.allow-landscape-mode),
  html:not(.allow-landscape-mode) body {
    overflow: hidden !important;
    touch-action: none !important;
  }

  html:not(.allow-landscape-mode) main,
  html:not(.allow-landscape-mode) .site-nav,
  html:not(.allow-landscape-mode) .home-floating-hamburger {
    pointer-events: none !important;
  }
}

/* Refuerzo sincronizado por JS (cubre teléfonos altos o navegadores sin pointer: coarse) */
html.is-landscape-locked:not(.allow-landscape-mode) .orientation-lock-overlay {
  display: flex;
  opacity: 1;
  pointer-events: auto;
}

html.is-landscape-locked:not(.allow-landscape-mode),
html.is-landscape-locked:not(.allow-landscape-mode) body {
  overflow: hidden !important;
  touch-action: none !important;
}

html.is-landscape-locked:not(.allow-landscape-mode) main,
html.is-landscape-locked:not(.allow-landscape-mode) .site-nav,
html.is-landscape-locked:not(.allow-landscape-mode) .home-floating-hamburger {
  pointer-events: none !important;
}

html.allow-landscape-mode .orientation-lock-overlay {
  display: none !important;
  opacity: 0 !important;
  pointer-events: none !important;
}

/* Ajustes compactos para Lightbox y Cámara en Vivo cuando se giran a horizontal */
@media (orientation: landscape) and (max-height: 520px) {
  html.allow-landscape-mode .lightbox-header {
    padding: 8px calc(16px + env(safe-area-inset-right, 0px)) 8px calc(16px + env(safe-area-inset-left, 0px));
  }

  html.allow-landscape-mode .lightbox-bottom {
    padding: 7px calc(16px + env(safe-area-inset-right, 0px)) calc(8px + env(safe-area-inset-bottom, 0px)) calc(16px + env(safe-area-inset-left, 0px));
  }
}

/* Diseño horizontal tipo cámara nativa: visor a altura completa + barra lateral de controles */
@media (orientation: landscape) and (max-height: 540px) {
  .live-camera-modal {
    --cam-rail-w: calc(124px + env(safe-area-inset-right, 0px));
    flex-direction: row;
  }

  .live-camera-modal .live-cam-viewport {
    flex: 1 1 auto;
    min-width: 0;
    width: auto;
    height: 100%;
  }

  .live-camera-modal .live-cam-topbar {
    left: 0;
    right: var(--cam-rail-w);
    padding: calc(10px + env(safe-area-inset-top, 0px)) 12px 10px calc(14px + env(safe-area-inset-left, 0px));
    pointer-events: none;
  }

  .live-camera-modal .live-cam-topbar > * {
    pointer-events: auto;
  }

  .live-camera-modal .live-cam-mode-pill {
    padding: 5px 11px;
    font-size: 0.74rem;
    gap: 6px;
  }

  .live-camera-modal .live-cam-quota-chip {
    padding: 5px 10px;
    font-size: 0.72rem;
  }

  .live-camera-modal .live-cam-icon-btn {
    width: 36px;
    height: 36px;
  }

  .live-camera-modal .camera-rec-badge {
    top: calc(52px + env(safe-area-inset-top, 0px));
    right: 12px;
    bottom: auto;
    padding: 4px 10px;
    font-size: 0.74rem;
  }

  .live-camera-modal .live-cam-bottom {
    width: var(--cam-rail-w);
    flex: 0 0 var(--cam-rail-w);
    height: 100%;
    padding: calc(12px + env(safe-area-inset-top, 0px)) calc(10px + env(safe-area-inset-right, 0px)) calc(12px + env(safe-area-inset-bottom, 0px)) 10px;
    background: linear-gradient(90deg, rgba(10, 13, 9, 0.84) 0%, #141210 28%);
    border-left: 1px solid rgba(255, 255, 255, 0.08);
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
  }

  .live-camera-modal .live-cam-mode-switch {
    width: 100%;
    max-width: 104px;
    padding: 3px;
    gap: 2px;
    margin: 0;
  }

  .live-camera-modal .live-cam-mode-tab {
    flex: 1 1 0;
    min-width: 0;
    min-height: 30px;
    padding: 4px 6px;
    font-size: 0.68rem;
    letter-spacing: 0.02em;
  }

  .live-camera-modal .live-cam-controls-row {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 12px;
    max-width: none;
    width: 100%;
    flex: 1 1 auto;
    margin: 0;
  }

  .live-camera-modal .live-cam-left-slot {
    display: none;
  }

  .live-camera-modal .live-cam-center-slot {
    align-items: center;
  }

  .live-camera-modal .live-cam-right-slot {
    width: 100%;
    justify-content: center;
  }

  .live-camera-modal .camera-shutter-btn,
  .live-camera-modal .camera-record-btn {
    width: 64px;
    height: 64px;
    border-width: 3.5px;
  }

  .live-camera-modal .shutter-inner {
    width: 48px;
    height: 48px;
  }

  .live-camera-modal .record-inner {
    width: 46px;
    height: 46px;
  }

  .live-camera-modal .camera-record-btn.recording .record-inner {
    width: 26px;
    height: 26px;
  }

  .live-camera-modal .live-cam-upload-btn {
    width: 100%;
    justify-content: center;
    padding: 8px 10px;
    gap: 6px;
    font-size: 0.76rem;
  }

  .live-camera-modal .upload-batch-badge {
    min-width: 20px;
    height: 20px;
    font-size: 0.7rem;
  }

  .live-camera-modal .live-cam-tray-wrap {
    position: fixed;
    left: calc(12px + env(safe-area-inset-left, 0px));
    right: calc(var(--cam-rail-w) + 12px);
    bottom: calc(10px + env(safe-area-inset-bottom, 0px));
    width: auto;
    z-index: 25;
    padding: 4px 8px;
    border-radius: 14px;
    background: rgba(10, 13, 9, 0.56);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
  }

  .live-camera-modal .live-cam-tray {
    gap: 8px;
    padding: 2px;
  }

  .live-camera-modal .cam-tray-thumb {
    width: 44px;
    height: 44px;
    border-radius: 10px;
  }

  .live-camera-modal .live-cam-permission {
    padding: calc(52px + env(safe-area-inset-top, 0px)) 16px 14px;
  }

  .live-camera-modal .live-cam-perm-card {
    max-width: 460px;
    padding: 18px 20px 14px;
    border-radius: 20px;
  }

  .live-camera-modal .live-cam-perm-icon {
    width: 44px;
    height: 44px;
    margin: 0 auto 10px;
  }

  .live-camera-modal .live-cam-perm-card h3 {
    font-size: 1.2rem;
    margin-bottom: 6px;
  }

  .live-camera-modal .live-cam-perm-card p {
    font-size: 0.78rem;
    margin-bottom: 12px;
    line-height: 1.4;
  }

  .live-camera-modal .live-cam-perm-actions {
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: center;
    gap: 8px;
  }

  .live-camera-modal .live-cam-perm-actions .btn {
    width: auto;
    padding: 9px 14px;
    font-size: 0.8rem;
  }

  .live-camera-modal .live-cam-item-preview img,
  .live-camera-modal .live-cam-item-preview video {
    max-height: calc(100% - 64px);
  }

  .live-camera-modal .live-cam-preview-actions {
    bottom: 10px;
    gap: 10px;
  }
}

@media (orientation: landscape) and (max-height: 360px) {
  .live-camera-modal {
    --cam-rail-w: calc(110px + env(safe-area-inset-right, 0px));
  }

  .live-camera-modal .camera-shutter-btn,
  .live-camera-modal .camera-record-btn {
    width: 56px;
    height: 56px;
  }

  .live-camera-modal .shutter-inner {
    width: 42px;
    height: 42px;
  }

  .live-camera-modal .record-inner {
    width: 40px;
    height: 40px;
  }

  .live-camera-modal .cam-tray-thumb {
    width: 38px;
    height: 38px;
  }
}

@media (max-height: 360px) and (orientation: landscape) {
  .orientation-lock-card {
    gap: 18px;
    padding: 16px 20px;
  }

  .orientation-lock-visual {
    width: 68px;
    height: 68px;
  }

  .orientation-phone-frame {
    width: 38px;
    height: 62px;
  }

  .orientation-lock-title {
    font-size: 1.3rem;
  }

  .orientation-lock-desc {
    font-size: 0.78rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .orientation-phone-frame,
  .orientation-rotate-arrow {
    animation: none !important;
  }
}

/* Identidad E&L y controles transl?cidos. */
.brand-emblem { width: 52px; height: 56px; background: transparent; border: 0; box-shadow: none; color: var(--color-olive); }
.brand-emblem svg { width: 100%; height: 100%; overflow: visible; }
.drawer-brand-emblem { width: 112px; height: 116px; flex-shrink: 0; }
.drawer-brand { position: relative; gap: 16px; }
.drawer-brand > * { position: relative; }
.drawer-brand-divider { display: none; }
.drawer-sub, .hero-date-pill, .nav-link, .drawer-nav-item, .drawer-cam-text strong { font-family: var(--font-sans); font-weight: 400; text-transform: uppercase; letter-spacing: .1em; }
:is(a, button, [role="button"]) { font-weight: 400 !important; }
:is(a, button, [role="button"]) :is(strong, b, span, .option-title) { font-weight: 400 !important; }
.option-icon-wrap, .option-video .option-icon-wrap, .option-gallery .option-icon-wrap, .drawer-cam-icon, .drawer-item-icon { background: rgba(31, 29, 27, .05); color: #9A7742; border: 1px solid rgb(88 77 66 / 10%); box-shadow: inset 0 1px 0 rgba(250, 248, 245, .7); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); }
.hero-btn-moments { background: rgba(250, 248, 245, .84); color: var(--color-olive-dark); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); box-shadow: 0 4px 18px rgba(31, 29, 27, .12); }
.ui-icon { display: inline-block; width: 1.5em; height: 1.5em; vertical-align: -.16em; flex-shrink: 0; }
a:focus-visible, button:focus-visible { outline: 2px solid var(--color-gold-dark); outline-offset: 4px; }
@media (prefers-reduced-motion: reduce) { .brand-emblem, .hero-btn { animation: none !important; transition: none !important; } }


/* Referencia caligrafica: Corinthia; rotulos geometricos: Montserrat. */
.hero-date-pill, .brand-date, .drawer-sub { font-family: var(--font-sans); font-weight: 400; letter-spacing: .2em; }
.nav-link, .drawer-nav-item { font-size: .78rem; letter-spacing: .1em; }
.hero-date-pill { max-width: 100%; white-space: normal; line-height: 1.6; }

/* Textura original de papel: capa independiente del contenido del libro. */
.book-paper-page::before { content: ""; position: absolute; inset: 0; background: url("/assets/img/2.jpg") center / cover no-repeat; opacity: .4; pointer-events: none; border-radius: inherit; z-index: -1; }
.book-paper-page { isolation: isolate; }
/* Monograma aportado y navegación editorial. */
.brand-monogram { display: block; width: 100%; height: 100%; object-fit: contain; filter: brightness(0) saturate(100%) invert(31%) sepia(12%) saturate(730%) hue-rotate(57deg) brightness(96%) contrast(89%); }
.site-nav.nav-over-hero .brand-monogram { filter: none; }
.preloader-monogram { filter: brightness(0) saturate(100%) invert(31%) sepia(12%) saturate(730%) hue-rotate(57deg) brightness(96%) contrast(89%); }
/* Ampersand tipografico: escala junto con los nombres. */
.hero-content-lower .hero-title .hero-amp {
  display: inline-block; position: static; width: auto; margin: 0em;
  vertical-align: -.08em; font-family: 'Tangerine', cursive;
  font-size: 1.12em; font-weight: 400; line-height: .8;
  pointer-events: none; filter: none;
}
.hero-content-lower .hero-subtitle { position: relative; z-index: 2; }
.mobile-drawer-head { align-items: flex-start; }
.drawer-close-btn { margin-top: -8px; width: 44px; height: 44px; flex-shrink: 0; border: 0; background: transparent; }
.drawer-camera-spotlight { border-radius: 999px; }
.drawer-cam-icon, .drawer-item-icon, .drawer-nav-item.active .drawer-item-icon { background: transparent; border: 0; box-shadow: none; backdrop-filter: none; -webkit-backdrop-filter: none; color: inherit; }
.drawer-nav-list { gap: 0; }
.drawer-nav-item { position: relative; border: 0; border-radius: 0; background: transparent; transition: transform .22s ease, color .22s ease; }
.drawer-nav-item::after { content: ''; position: absolute; bottom: 0; left: 14px; right: 14px; height: 1px; background: linear-gradient(90deg, transparent, rgba(184, 147, 90,.32) 20%, rgba(31, 29, 27,.14) 80%, transparent); }
.drawer-nav-item:hover, .drawer-nav-item.active { background: transparent; box-shadow: none; color: var(--color-olive); }
.drawer-install-btn { margin-top: 0; background: transparent; }
.mobile-drawer { background: #FAF8F5; color: var(--color-olive-dark); }
.hero-btn { backdrop-filter: blur(28px) saturate(145%); -webkit-backdrop-filter: blur(28px) saturate(145%); box-shadow: inset 0 1px 0 rgba(255,255,255,.18), 0 8px 24px rgba(0,0,0,.24); }
.hero-btn-moments { background: rgba(184, 147, 90,.22); color: var(--color-gold-light); border: 1px solid var(--color-gold); }
.hero-btn-moments:hover { background: rgba(184, 147, 90,.32); }
.hero-btn-glass { background: rgba(31, 29, 27,.28); color: #FAF8F5; border: 1px solid var(--color-olive); backdrop-filter: blur(28px) saturate(145%); -webkit-backdrop-filter: blur(28px) saturate(145%); }
.hero-btn-glass:hover { background: rgba(31, 29, 27,.4); }
@media (hover: hover) { .drawer-nav-item:hover, .drawer-camera-spotlight:hover, .drawer-close-btn:hover { transform: translateY(-2px); } }
@media (prefers-reduced-motion: reduce) { .drawer-nav-item, .drawer-camera-spotlight, .drawer-close-btn { transition: none; } .drawer-nav-item:hover, .drawer-camera-spotlight:hover, .drawer-close-btn:hover { transform: none; } }

/* Respetar los colores originales de la variante vegetal del monograma. */
.nav-brand .brand-monogram, .drawer-brand .brand-monogram { filter: none; }
/* Libro a primer plano en escritorio (reemplazado más abajo por .page-guestbook .book-page-main). */
.book-page-main { position: relative; z-index: 1001; padding: 12px; pointer-events: none; }
.book-page-main .wedding-book-stage { pointer-events: auto; }
@media (max-width: 1140px) { .site-nav .nav-mobile-actions { display: flex; } .site-nav .brand-wordmark, .site-nav .brand-divider, .site-nav .nav-links { display: none; } }
@media (max-width: 800px) { .book-page-main { z-index: auto; padding: calc(70px + env(safe-area-inset-top, 0px)) 12px calc(12px + env(safe-area-inset-bottom, 0px)); } }
@media (max-width: 600px) { .book-page-main { padding: calc(68px + env(safe-area-inset-top, 0px)) 8px calc(8px + env(safe-area-inset-bottom, 0px)); } }

/* Libro de honor: pasta cerrada y hojas al abrir. */
.wedding-book-sheet:not(.is-open) {
  background: linear-gradient(110deg, #171513, #1F1D1B 18%, #1F1D1B 66%, #171513);
  box-shadow: inset 3px 0 9px rgba(0,0,0,.38), inset 0 1px 0 rgba(226, 217, 204,.16);
  color: var(--color-gold-light);
}
.wedding-book-sheet:not(.is-open)::before {
  content: ''; position: absolute; inset: 22px; pointer-events: none;
  background: url('/assets/img/d-rama.svg') center / contain no-repeat; opacity: .045;
}
.book-cover-monogram {
  display: block; width: min(72%, 320px); height: auto; max-height: 46dvh; object-fit: contain;
  margin: 0 auto 20px; filter: drop-shadow(0 1px 0 rgba(255,241,196,.1)) drop-shadow(0 -2px 1px rgba(0,0,0,.2));
}
.wedding-book-sheet:not(.is-open) .book-sheet-header {
  position: relative; display: flex; flex-direction: column; align-items: center;
  justify-content: center; flex: 1; min-height: 0; margin: 0; padding: 16px 0; border: 0;
}
.wedding-book-sheet:not(.is-open) .book-ornament { display: none; }
.wedding-book-sheet:not(.is-open) .book-eyebrow {
  font-family: var(--font-serif); font-style: italic; font-size: clamp(1.8rem, 5vw, 2.6rem);
  text-transform: none; letter-spacing: .025em; color: var(--color-gold-light); margin-bottom: 24px;
}
.wedding-book-sheet:not(.is-open) .book-mode-bar { background: rgba(250, 248, 245,.05); }
.wedding-book-sheet:not(.is-open) .book-mode-btn { color: var(--color-gold-light); min-height: 44px; }
.wedding-book-sheet:not(.is-open) .book-mode-btn:hover { background: rgba(184, 147, 90,.14); }
.wedding-book-sheet:not(.is-open) .book-view { display: none; }
.wedding-book-sheet.is-open .book-cover-monogram { display: none; }
.wedding-book-sheet.is-open { animation: bookOpenReveal .65s ease both; transform-origin: left center; }
#bookFlipStage[hidden] { display: none; }
#bookReadView > #bookWriteView.is-active {
  padding: 16px 20px; border-radius: 3px;
  background: linear-gradient(90deg, rgba(36,46,30,.12), transparent 8%), #FAF8F5;
  border: 1px solid rgba(196,162,99,.44); box-shadow: 3px 3px 0 #E9DFC9, 5px 5px 0 #D8CDB5;
}
/* El reverso conserva papel opaco sin texto reflejado. */
.book-stf-page { background: #FAF8F5; }
.book-stf-page .book-paper-page { backface-visibility: hidden; -webkit-backface-visibility: hidden; }
/* Escritura luminosa exclusiva de la firma recien guardada. */
.book-signature-entry.is-new-signature { position: relative; transform: none; }
.book-signature-entry.is-new-signature:not(.signature-revealing) :is(.book-sig-message,.book-sig-author) { opacity: 0; }
.signature-magic-layer { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; pointer-events: none; z-index: 7; }
.signature-light-trail { stroke: none; filter: drop-shadow(0 0 2px #E2D9CC) drop-shadow(0 0 5px #B8935A); }
.signature-light-tip { fill: #FAF8F5; stroke: #B8935A; stroke-width: 1; filter: drop-shadow(0 0 4px #B8935A) drop-shadow(0 0 8px #B8935A); }
.signature-light-spark { fill: #FAF8F5; stroke: #E2D9CC; stroke-width: .35; filter: drop-shadow(0 0 2px #E2D9CC) drop-shadow(0 0 4px #B8935A); }
@keyframes bookOpenReveal { from { opacity: .45; transform: perspective(1200px) rotateY(-12deg); } to { opacity: 1; transform: perspective(1200px) rotateY(0); } }
@media (prefers-reduced-motion: reduce) {
  .wedding-book-sheet.is-open { animation: none; }
  .book-signature-entry.is-new-signature:not(.signature-revealing) :is(.book-sig-message,.book-sig-author) { opacity: revert; }
  .signature-magic-layer { display: none; }
}

.book-stf-page.is-turning-verso .book-paper-page > * { visibility: hidden; }

/* Tangerine en todos los nombres, sin el solapamiento del SVG. */
.brand-text .brand-amp { display: inline-block; position: static; width: auto; font-family: 'Tangerine', cursive; font-size: 1.16em; font-weight: 400; line-height: .8; vertical-align: -.08em; margin: 0em; }
.drawer-brand .brand-wordmark { display: flex; }
.drawer-brand .brand-text { font-size: clamp(1.45rem, 5.8vw, 1.75rem); }
.mobile-drawer-head, .drawer-camera-spotlight, .drawer-nav-list { position: relative; z-index: 1; }
.drawer-monogram-watermark { position: absolute; right: 12px; bottom: calc(12px + env(safe-area-inset-bottom, 0px)); width: 200px; height: auto; opacity: .1; pointer-events: none; user-select: none; filter: none; z-index: 0; }

/* Controles de carrete con vidrio transparente sobre las miniaturas. */
#standbySection > .camera-quota-meter { margin-top: 22px; }
.standby-select-badge,
.standby-tile.is-selected .standby-select-badge,
.standby-delete-btn {
  background: #00000050;
  backdrop-filter: blur(14px) saturate(130%);
  -webkit-backdrop-filter: blur(14px) saturate(130%);
  box-shadow: 0 4px 10px rgba(0,0,0,.34);
  text-shadow: 0 2px 3px rgba(0,0,0,.4);
}
.standby-select-badge { color: #192016; border-color: currentColor; }
.standby-tile.is-selected .standby-select-badge { color: white; border-color: currentColor; }
.standby-delete-btn { color: #CD2D2D; border-color: currentColor; }
.standby-delete-btn svg, .btn-publish-standby svg { filter: drop-shadow(0 2px 2px rgba(0,0,0,.35)); }
.btn-mini-gallery, .btn-mini-gallery:hover { background: transparent; color: var(--color-olive-dark); }

/* Marcas discretas y del mismo grosor en el carrete. */
.standby-select-badge { border: 1.5px solid rgba(25,32,22,.3); }
.standby-tile.is-selected .standby-select-badge { border-color: rgba(184, 147, 90,.3); }
.standby-delete-btn { border-color: rgba(205,45,45,.3); }
.standby-preview-btn { border-color: rgba(255,255,255,.3); }

/* Mosaico con alturas alternadas independientes del archivo original (conserva transición en cascada). */
.gallery-grid.gallery-wall { display: grid; grid-template-columns: repeat(4, minmax(0,1fr)); grid-auto-rows: 4px; grid-auto-flow: row dense; gap: 10px; align-items: stretch; width: 100%; }
.gallery-wall .gallery-grid-item { position: relative; display: block; width: 100%; height: 100%; min-height: 0; aspect-ratio: auto; margin: 0; border-radius: 12px; }
.gallery-wall .gallery-item-aspect { position: absolute; inset: 0; width: 100%; height: 100%; }
.gallery-wall .gallery-item-media { width: 100%; height: 100%; object-fit: cover; }
.gallery-wall video.gallery-item-media { min-height: 0; }
@media (max-width: 1200px) { .gallery-grid.gallery-wall { grid-template-columns: repeat(4, minmax(0,1fr)); } }
@media (max-width: 900px) { .gallery-grid.gallery-wall { grid-template-columns: repeat(3, minmax(0,1fr)); } }
@media (max-width: 600px) { .gallery-grid.gallery-wall { grid-template-columns: repeat(2, minmax(0,1fr)); } }
.gallery-wall .gallery-item-overlay { opacity: 1; background: linear-gradient(to top, rgba(15,22,12,.66), transparent 45%); }
.gallery-wall .gallery-item-author { opacity: 0; transform: translateY(5px); transition: opacity .2s ease, transform .2s ease; }
.gallery-wall .gallery-grid-item:hover .gallery-item-author, .gallery-wall .gallery-grid-item:focus-within .gallery-item-author { opacity: 1; transform: none; }
.gallery-wall .gallery-item-like { margin-left: auto; min-height: 32px; }
.gallery-wall .gallery-owner-badge { opacity: 0; }
.gallery-wall .gallery-grid-item:hover .gallery-owner-badge, .gallery-wall .gallery-grid-item:focus-within .gallery-owner-badge { opacity: 1; }
@media (hover: none) { .gallery-wall .gallery-item-author, .gallery-wall .gallery-owner-badge { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { .gallery-wall .gallery-grid-item { opacity: 1; transform: none; transition: none; } .gallery-wall .gallery-item-author, .gallery-wall .gallery-item-media { transition: none; } }

/* Los recuerdos populares conservan la misma altura y las columnas adaptables. */
/* La barra conserva su fondo fuera del libro y acompana el sentido del scroll. */
.site-nav { transition: transform .32s cubic-bezier(.22,1,.36,1); }
.site-nav.is-scroll-hidden { transform: translateY(-110%); pointer-events: none; }
@media (prefers-reduced-motion: reduce) { .site-nav { transition: none; } }

/* Abierto: la hoja ocupa todo el interior; cambiar de modo desde su pie. */
.wedding-book-sheet.is-open .book-sheet-header { display: none; }
.wedding-book-sheet.is-open #bookReadView { flex: 1; min-height: 0; }
.book-write-footer { display: flex; justify-content: flex-end; flex-shrink: 0; margin-top: auto; padding: 12px 0 4px; }
.book-mode-switch { overflow: visible; }
.book-mode-switch svg { width: 16px; height: 16px; }
.book-mode-tooltip { position: absolute; bottom: calc(100% + 9px); right: 0; width: max-content; max-width: 180px; padding: 7px 11px; border-radius: 8px; background: var(--color-olive-dark); color: #FAF8F5; font-family: var(--font-sans); font-size: .72rem; line-height: 1.3; font-weight: 400; white-space: nowrap; box-shadow: 0 4px 12px rgba(31, 29, 27,.2); opacity: 0; visibility: hidden; transform: translateY(3px); pointer-events: none; transition: opacity .18s ease, transform .18s ease, visibility .18s ease; z-index: 8; }
.book-mode-tooltip::after { content: ''; position: absolute; top: 100%; right: 10px; border: 5px solid transparent; border-top-color: var(--color-olive-dark); }
.book-mode-switch:hover .book-mode-tooltip, .book-mode-switch:focus-visible .book-mode-tooltip { opacity: 1; visibility: visible; transform: none; }
@media (prefers-reduced-motion: reduce) { .book-mode-tooltip { transition: none; } }

/* Inspiracion y formulario centrados, con las seis opciones a la vista. */
#bookWriteView .book-chips-strip { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 8px; width: 100%; max-width: 440px; margin: 4px auto 18px; padding: 4px; overflow: visible; }
#bookWriteView .book-chips-strip .gb-chip-btn { min-width: 0; min-height: 40px; white-space: normal; overflow-wrap: anywhere; line-height: 1.35; text-align: center; justify-content: center; }
#guestbookForm { width: 100%; max-width: 440px; margin-inline: auto; }
#bookWriteView .book-prompt-note { max-width: 440px; margin-inline: auto; text-align: center; }

/* El libro vuelve debajo de la barra, en cualquier ancho. */
.page-guestbook .book-page-main { z-index: auto; padding: calc(80px + env(safe-area-inset-top, 0px)) 12px calc(12px + env(safe-area-inset-bottom, 0px)); }
.book-static-spread { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); height: 100%; }
.book-static-spread > .book-stf-page { min-width: 0; }
@media (min-width: 1000px) {
  .page-guestbook.has-open-book .wedding-book-stage { max-width: 1180px; }
  .wedding-book-sheet.is-two-page { padding: 10px; }
  .wedding-book-sheet.is-two-page::after { content: ''; position: absolute; top: 10px; bottom: 10px; left: calc(50% - 12px); width: 24px; z-index: 8; pointer-events: none; background: linear-gradient(90deg, transparent, rgba(31, 29, 27,.12) 42%, rgba(31, 29, 27,.25) 50%, rgba(250, 248, 245,.5) 56%, transparent); }
  .wedding-book-sheet.is-two-page #bookReadView { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); grid-template-rows: minmax(0,1fr); gap: 0; align-items: stretch; }
  .wedding-book-sheet.is-two-page[data-mode="read"] #bookFlipStage { grid-column: 1 / -1; }
  .wedding-book-sheet.is-two-page[data-mode="write"] #bookWriteView { grid-column: 1; grid-row: 1; min-width: 0; margin: 0; border-radius: 3px; box-shadow: none; padding: 16px 22px 12px; }
  .wedding-book-sheet.is-two-page[data-mode="write"] #bookFlipStage { grid-column: 2; grid-row: 1; }
  .wedding-book-sheet.is-two-page .book-flip-host-wrap { right: 0; }
  .wedding-book-sheet.is-two-page .book-paper-page { border-radius: 3px; }
  .wedding-book-sheet.is-two-page[data-mode="read"] [data-book-side="left"] .book-corner-next,
  .wedding-book-sheet.is-two-page[data-mode="read"] [data-book-side="left"] .book-mode-switch,
  .wedding-book-sheet.is-two-page[data-mode="read"] [data-book-side="right"] .book-corner-prev { display: none; }
  .wedding-book-sheet.is-two-page[data-mode="write"] .book-paper-page .book-mode-switch { display: none; }
}

/* La pasta mantiene el lomo lateral cerrada; abierto se centra en la doble hoja. */
.wedding-book-cover.is-open-book { border-radius: 12px; padding: 10px; }
.wedding-book-cover.is-spread-open .wedding-book-spine { left: 50%; transform: translateX(-50%); width: 16px; top: 10px; bottom: 10px; border: 0; border-radius: 0; background: linear-gradient(90deg, transparent, rgba(31, 29, 27,.25) 40%, rgba(31, 29, 27,.5) 50%, rgba(31, 29, 27,.25) 60%, transparent); z-index: 6; pointer-events: none; }
.wedding-book-cover.is-spread-open .wedding-book-ribbon { right: auto; left: calc(50% + 18px); }

/* Desplazamiento fino en paginas, modales y paneles interiores. */
* { scrollbar-width: thin; scrollbar-color: rgba(31, 29, 27,.58) rgba(31, 29, 27,.06); }
*::-webkit-scrollbar { width: 6px; height: 6px; }
*::-webkit-scrollbar-track { background: rgba(31, 29, 27,.06); border-radius: 999px; margin-block: 8px; }
*::-webkit-scrollbar-thumb { background: rgba(31, 29, 27,.58); border-radius: 999px; }
*::-webkit-scrollbar-thumb:hover { background: var(--color-gold-dark); }
*::-webkit-scrollbar-thumb:active { background: var(--color-olive-dark); }
*::-webkit-scrollbar-corner { background: transparent; }
.book-sig-modal-card { scrollbar-gutter: stable; }
@media (forced-colors: active) { * { scrollbar-color: auto; } }

/* Perfil del invitado y rotulos sobre acentos dorados. */
#guestModal .modal-dialog, #guestNameInput, #guestModal .modal-current-info { border-radius: 12px; }
#guestModal .modal-icon-badge { color: var(--color-gold); background: rgba(226, 217, 204,.85); box-shadow: none; }
#guestModal .modal-icon-badge svg { fill: var(--color-gold); stroke: var(--color-gold); }
#guestModal .modal-current-info { background: rgba(226, 217, 204,.85); }
.btn-primary, .drawer-camera-spotlight, .gallery-tab-item.active,
#btnCaptureFromCamera, .btn-upload-camera, .camera-mode-btn.active,
.hero-btn-moments, .lightbox-standby-select-btn.is-selected,
.book-submit-btn, .book-mode-btn.is-active .book-count-pill { color: #FFFFFF; }

.btn-primary,
#btnCaptureFromCamera,
.btn-upload-camera,
.camera-mode-btn.active,
.nav-camera-cta,
.nav-camera-mobile-btn,
.hero-btn-moments,
.lightbox-standby-select-btn.is-selected,
.live-cam-upload-btn,
.book-mode-btn.is-active .book-count-pill,
.book-submit-btn { color: #FFFFFF; }

/* Bloques de camara: bordes finos y fondos al cincuenta por ciento. */
.page-camera .camera-option-card,
.page-camera .camera-option-card.option-video,
.page-camera .camera-option-card.option-gallery,
.page-camera .standby-section,
.page-camera .my-uploads-section { border-width: 1px; }
.page-camera .camera-option-card { background: rgba(255,255,255,.5); }
.page-camera .camera-option-card.option-photo { background: linear-gradient(155deg,rgba(255,251,242,.5),rgba(251,241,220,.5)); }
.page-camera .camera-option-card.option-video,
.page-camera .camera-option-card.option-gallery { background: rgba(255,255,255,.5); }
.page-camera .camera-option-card.option-video:hover,
.page-camera .camera-option-card.option-gallery:hover { background: linear-gradient(135deg,rgba(250, 248, 245,.5),rgba(251,246,236,.5)); }
.page-camera .standby-section { background: linear-gradient(160deg,rgba(250, 248, 245,.5),rgba(250,244,232,.5)); }
.page-camera .my-uploads-section { background: rgba(255,255,255,.5); }

/* Hoja de escritura: identidad centrada y dedicatoria a toda la altura disponible. */
#bookWriteView .book-write-wordmark { display:flex; flex-direction:column; flex-shrink:0; align-items:center; width:100%; text-align:center; gap:6px; margin:8px auto 12px; }
#bookWriteView .book-write-wordmark .brand-text { font-size:clamp(2rem,4vw,2.8rem); line-height:1.15; white-space:normal; }
#bookWriteView .book-write-divider { display:block; flex-shrink:0; width:min(100%,440px); height:1px; margin:0 auto 18px; background:linear-gradient(90deg,transparent,rgba(184, 147, 90,.6),transparent); }
#bookWriteView #guestbookForm { flex:1 0 260px; min-height:260px; }
#guestbookForm .book-message-field { display:flex; flex-direction:column; flex:1; min-height:120px; }
#guestbookForm #gbMessage { flex:1; height:100%; min-height:100px; }
#guestbookForm .book-form-actions { flex-shrink:0; margin-top:0; }

/* Acciones alineadas en la hoja de escritura. */
#bookWriteView .book-label, #bookWriteView .book-prompt-note { font-family: var(--font-serif); }
#guestbookForm .book-form-actions { display:flex; flex-direction:row; align-items:center; gap:12px; }
#guestbookForm .book-write-footer { flex:0 0 48px; width:48px; height:48px; margin:0; padding:0; }
#guestbookForm .book-write-footer .book-mode-switch { width:48px; height:48px; border-radius:50%; padding:0; }
#guestbookForm .book-submit-btn { flex:1; width:auto; height:48px; min-width:0; padding:8px 12px; }

/* PWA standalone/fullscreen (iOS/Android): cubrir pantalla completa edge-to-edge en Home y Libro de Firmas */
@media (display-mode: standalone), (display-mode: fullscreen) {
  html.home-no-scroll {
    height: 100%;
    min-height: 100vh;
    min-height: 100lvh;
    background-color: #171513;
  }

  body.page-home {
    position: fixed;
    inset: 0;
    width: 100%;
    height: auto;
    max-height: none;
    display: flex;
    flex-direction: column;
  }

  body.page-home .app-main-home {
    flex: 1 1 auto;
    height: 100%;
    min-height: 0;
  }

  html:has(body.page-guestbook) {
    height: 100%;
    min-height: 100vh;
    min-height: 100lvh;
  }

  body.page-guestbook {
    position: fixed;
    inset: 0;
    width: 100%;
    height: auto;
    min-height: 0;
    max-height: none;
    display: flex;
    flex-direction: column;
  }

  body.page-guestbook .book-page-main {
    flex: 1 1 auto;
    height: 100%;
    min-height: 0;
  }
}

html.is-pwa-standalone.home-no-scroll {
  height: 100%;
  min-height: 100vh;
  min-height: 100lvh;
  background-color: #171513;
}

html.is-pwa-standalone body.page-home {
  position: fixed;
  inset: 0;
  width: 100%;
  height: auto;
  max-height: none;
  display: flex;
  flex-direction: column;
}

html.is-pwa-standalone body.page-home .app-main-home {
  flex: 1 1 auto;
  height: 100%;
  min-height: 0;
}

html.is-pwa-standalone:has(body.page-guestbook) {
  height: 100%;
  min-height: 100vh;
  min-height: 100lvh;
}

html.is-pwa-standalone body.page-guestbook {
  position: fixed;
  inset: 0;
  width: 100%;
  height: auto;
  min-height: 0;
  max-height: none;
  display: flex;
  flex-direction: column;
}

html.is-pwa-standalone body.page-guestbook .book-page-main {
  flex: 1 1 auto;
  height: 100%;
  min-height: 0;
}

@media (max-width: 768px) {
  .page-guestbook .wedding-book-stage {
    max-height: none;
  }
}

/* =====================================================================
   CONTRAPORTADA, ANIMACIÓN DE CIERRE Y HOJA DE GUARDA DEL LIBRO DE FIRMAS
   ===================================================================== */
.wedding-book-cover.is-back-cover {
  padding: 9px 18px 10px 10px;
  border-radius: 22px 10px 10px 22px;
}

.wedding-book-cover.is-back-cover .wedding-book-spine {
  left: auto;
  right: 0;
  border-radius: 0 10px 10px 0;
  border-right: 0;
  border-left: 1px solid rgba(184, 147, 90, 0.35);
}

.wedding-book-cover.is-back-cover .wedding-book-ribbon {
  right: auto;
  left: 28px;
}

@media (max-width: 600px) {
  .wedding-book-cover.is-back-cover {
    padding: 7px 14px 8px 7px;
    border-radius: 18px 8px 8px 18px;
  }
}

.wedding-book-sheet[data-mode="back-cover"] {
  background: linear-gradient(250deg, #171513, #1F1D1B 18%, #1F1D1B 66%, #171513);
  box-shadow: inset -3px 0 9px rgba(0, 0, 0, 0.38), inset 0 1px 0 rgba(226, 217, 204, 0.16);
  animation: bookBackCoverReveal 0.44s cubic-bezier(0.22, 1, 0.36, 1) both;
  transform-origin: right center;
}

.wedding-book-sheet[data-mode="back-cover"] .book-sheet-header,
.wedding-book-sheet[data-mode="back-cover"] .book-view {
  display: none;
}

.wedding-book-sheet.is-closing-book {
  animation: bookCloseFold 0.34s cubic-bezier(0.4, 0, 0.2, 1) forwards;
  transform-origin: left center;
  pointer-events: none;
}

@keyframes bookCloseFold {
  0% {
    opacity: 1;
    transform: perspective(1400px) rotateY(0deg) scaleX(1);
  }
  100% {
    opacity: 0.3;
    transform: perspective(1400px) rotateY(-26deg) scaleX(0.9);
  }
}

@keyframes bookBackCoverReveal {
  0% {
    opacity: 0.45;
    transform: perspective(1200px) rotateY(16deg) scale(0.97);
  }
  100% {
    opacity: 1;
    transform: perspective(1200px) rotateY(0deg) scale(1);
  }
}

.book-back-cover-view {
  position: relative;
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  padding: 12px 10px 4px;
  color: var(--color-gold-light);
}

.book-back-cover-view[hidden] {
  display: none;
}

.book-back-cover-view::after {
  content: '';
  position: absolute;
  inset: 2px;
  border: 1px solid rgba(184, 147, 90, 0.26);
  border-radius: 2px;
  pointer-events: none;
  z-index: 0;
}

.book-back-cover-body {
  position: relative;
  z-index: 1;
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: 8px;
  padding: 12px 10px;
}

.book-back-cover-monogram {
  display: block;
  width: min(44%, 152px);
  height: auto;
  max-height: 24dvh;
  object-fit: contain;
  margin-bottom: 4px;
  filter: drop-shadow(0 1px 0 rgba(255, 241, 196, 0.1)) drop-shadow(0 -2px 1px rgba(0, 0, 0, 0.2));
}

.book-back-cover-ornament {
  margin: 2px 0 4px;
  color: var(--color-gold);
}

.book-back-cover-quote {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: clamp(1.18rem, 3.8vw, 1.56rem);
  line-height: 1.28;
  letter-spacing: 0.015em;
  color: var(--color-gold-light);
  max-width: 26ch;
  margin: 0;
}

.book-back-cover-couple {
  font-family: var(--font-serif);
  font-size: clamp(1.05rem, 3.2vw, 1.32rem);
  letter-spacing: 0.04em;
  color: rgba(250, 248, 245, 0.92);
  margin: 6px 0 0;
}

.book-back-cover-couple .brand-amp {
  display: inline-block;
  font-family: 'Tangerine', cursive;
  font-size: 1.28em;
  color: var(--color-gold);
  line-height: 0.8;
  margin: 0 2px;
}

.book-back-cover-date {
  font-family: var(--font-sans);
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: rgba(184, 147, 90, 0.88);
  margin: 0;
}

.book-back-cover-count {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 0.86rem;
  color: rgba(226, 217, 204, 0.72);
  margin: 2px 0 6px;
}

.book-back-cover-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: 6px;
  width: 100%;
  max-width: 310px;
}

.book-back-cover-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: 40px;
  padding: 8px 14px;
  border-radius: 999px;
  border: 1px solid rgba(184, 147, 90, 0.42);
  background: rgba(250, 248, 245, 0.06);
  color: var(--color-gold-light);
  font-family: var(--font-sans);
  font-size: 0.76rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  cursor: pointer;
  transition: background-color 0.2s ease, border-color 0.2s ease, transform 0.15s ease;
}

.book-back-cover-btn--primary {
  background: rgba(184, 147, 90, 0.18);
  border-color: rgba(184, 147, 90, 0.65);
}

.book-back-cover-btn:hover,
.book-back-cover-btn:focus-visible {
  background: rgba(184, 147, 90, 0.26);
  border-color: var(--color-gold-light);
  outline: none;
}

.book-back-cover-btn:active {
  transform: scale(0.97);
}

.book-back-cover-view .book-paper-footer {
  margin: 4px 0 0;
  border-top-color: rgba(184, 147, 90, 0.24);
}

.book-back-cover-view .book-paper-swipe-hint {
  color: rgba(226, 217, 204, 0.76);
}

.book-back-cover-view .book-paper-corner-btn {
  background: rgba(250, 248, 245, 0.08);
  border-color: rgba(184, 147, 90, 0.45);
  color: var(--color-gold-light);
  box-shadow: none;
}

.book-back-cover-view .book-paper-corner-btn:hover:not(:disabled) {
  background: rgba(184, 147, 90, 0.24);
  border-color: var(--color-gold-light);
  color: #FAF8F5;
}

/* Hoja de guarda interior (en doble página cuando el total de hojas de firmas es impar) */
.book-paper-guard-body {
  display: flex;
  align-items: center;
  justify-content: center;
}

.book-guard-ornament {
  display: block;
  width: min(56%, 180px);
  aspect-ratio: 1;
  background: url('/assets/img/d-rama.svg') center / contain no-repeat;
  opacity: 0.11;
}

@media (max-height: 680px), (max-width: 430px) {
  .book-back-cover-body {
    gap: 5px;
    padding: 6px;
  }

  .book-back-cover-monogram {
    width: min(36%, 116px);
    max-height: 17dvh;
  }

  .book-back-cover-btn {
    min-height: 36px;
    padding: 6px 12px;
    font-size: 0.73rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .wedding-book-sheet[data-mode="back-cover"],
  .wedding-book-sheet.is-closing-book {
    animation: none;
  }
  .book-back-cover-btn {
    transition: none;
  }
  .book-back-cover-btn:active {
    transform: none;
  }
}

/* =====================================================================
   LIBRO DE FIRMAS FÍSICO REAL (StPageFlip CON TAPAS DURAS + INTERIOR DE PASTA)
   ===================================================================== */
.wedding-book-stage.is-real-book {
  width: 100%;
  max-width: 520px;
  height: 100%;
  max-height: 780px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  overflow: visible;
}

@media (min-width: 1000px) {
  .wedding-book-stage.is-real-book,
  .page-guestbook.has-open-book .wedding-book-stage.is-real-book {
    max-width: 1080px;
    max-height: 760px;
  }
}

.book-physical-shell {
  position: relative;
  flex: 1;
  min-height: 0;
  width: 100%;
  display: flex;
  flex-direction: column;
  overflow: visible;
}

.wedding-book-stage.is-real-book .book-flip-stage {
  position: relative;
  flex: 1;
  min-height: 0;
  width: 100%;
  overflow: visible;
}

.wedding-book-stage.is-real-book .book-flip-host-wrap {
  position: absolute;
  inset: 0;
  transition: transform 0.62s cubic-bezier(0.22, 1, 0.36, 1);
  will-change: transform;
}

/* En escritorio, centrar el libro cuando está cerrado en portada o contraportada */
@media (min-width: 1000px) {
  .wedding-book-stage.is-real-book[data-spread="true"][data-book-state="front"] .book-flip-host-wrap {
    transform: translateX(-25%);
  }

  .wedding-book-stage.is-real-book[data-spread="true"][data-book-state="open"] .book-flip-host-wrap {
    transform: translateX(0);
  }

  .wedding-book-stage.is-real-book[data-spread="true"][data-book-state="back"] .book-flip-host-wrap {
    transform: translateX(25%);
  }
}

.wedding-book-stage.is-real-book .stf__block {
  filter: drop-shadow(0 22px 34px rgba(31, 29, 27, 0.28)) drop-shadow(0 6px 12px rgba(31, 29, 27, 0.16));
}

/* Pasta dura (portada, interior de pasta delantera/trasera, contraportada) */
.book-stf-hard-page {
  background: transparent;
  box-shadow: none;
  border-radius: 0;
}

.book-hardcover {
  position: relative;
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  background:
    radial-gradient(circle at 25% 18%, rgba(184, 147, 90, 0.12), transparent 55%),
    linear-gradient(145deg, #2B2724 0%, #222D1D 56%, #151D12 100%);
  color: var(--color-gold-light);
  padding: 18px 18px 16px 26px;
  border-radius: 6px 18px 18px 6px;
  box-shadow:
    inset 1px 1px 0 rgba(226, 217, 204, 0.26),
    inset -2px -2px 6px rgba(0, 0, 0, 0.35);
  overflow: hidden;
}

.book-hardcover--back {
  padding: 18px 26px 16px 18px;
  border-radius: 18px 6px 6px 18px;
}

.book-hardcover--inside-front {
  padding: 20px 22px 14px 20px;
  border-radius: 14px 3px 3px 14px;
  background:
    linear-gradient(90deg, rgba(31, 29, 27, 0.25), transparent 10%, transparent 88%, rgba(12, 17, 10, 0.42)),
    linear-gradient(155deg, #283423 0%, #1D2719 60%, #171513 100%);
}

.book-hardcover--inside-back {
  padding: 20px 20px 14px 22px;
  border-radius: 3px 14px 14px 3px;
  background:
    linear-gradient(90deg, rgba(12, 17, 10, 0.42), transparent 12%, transparent 90%, rgba(31, 29, 27, 0.25)),
    linear-gradient(155deg, #283423 0%, #1D2719 60%, #171513 100%);
}

.book-hardcover-spine {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  width: 18px;
  background: linear-gradient(90deg, #10160E 0%, #2C3926 52%, #11170E 100%);
  border-right: 1px solid rgba(184, 147, 90, 0.38);
  pointer-events: none;
  z-index: 2;
}

.book-hardcover-spine--right {
  left: auto;
  right: 0;
  border-right: none;
  border-left: 1px solid rgba(184, 147, 90, 0.38);
}

.book-hardcover-ribbon {
  position: absolute;
  top: -2px;
  right: 26px;
  width: 15px;
  height: 34px;
  background: var(--gold-gradient);
  clip-path: polygon(0 0, 100% 0, 100% 100%, 50% 78%, 0 100%);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.28);
  pointer-events: none;
  z-index: 3;
}

.book-hardcover-ribbon--left {
  right: auto;
  left: 26px;
}

.book-hardcover-frame {
  position: relative;
  z-index: 2;
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: 8px;
  padding: 20px 16px 14px;
  border: 1px solid rgba(184, 147, 90, 0.38);
  border-radius: 6px;
  box-shadow: inset 0 0 0 4px rgba(184, 147, 90, 0.08);
}

.book-hardcover .book-cover-monogram {
  display: block;
  width: min(46%, 168px);
  height: auto;
  max-height: 24dvh;
  object-fit: contain;
  margin-bottom: 4px;
  filter: drop-shadow(0 1px 0 rgba(255, 241, 196, 0.14)) drop-shadow(0 6px 14px rgba(0, 0, 0, 0.28));
}

.book-cover-title {
  font-family: var(--font-sans);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--color-gold);
  margin: 2px 0 0;
}

.book-cover-couple {
  font-family: var(--font-serif);
  font-size: clamp(1.55rem, 4.4vw, 2.15rem);
  line-height: 1.1;
  color: #FAF8F5;
  margin: 2px 0 0;
}

.book-cover-couple .brand-amp {
  display: inline-block;
  font-family: 'Tangerine', cursive;
  font-size: 1.25em;
  color: var(--color-gold);
  line-height: 0.8;
  margin: 0 2px;
}

.book-cover-date {
  font-family: var(--font-sans);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: rgba(226, 217, 204, 0.8);
  margin: 0 0 10px;
}

.book-cover-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  max-width: 320px;
  margin-top: 4px;
}

.book-cover-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-height: 42px;
  padding: 9px 16px;
  border-radius: 999px;
  border: 1px solid rgba(184, 147, 90, 0.5);
  background: rgba(250, 248, 245, 0.08);
  color: var(--color-gold-light);
  font-family: var(--font-sans);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  cursor: pointer;
  transition: background-color 0.2s ease, border-color 0.2s ease, transform 0.16s ease;
}

.book-cover-cta--primary {
  background: var(--gold-gradient);
  border-color: rgba(255, 255, 255, 0.4);
  color: #FFFFFF;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.25);
}

.book-cover-cta:hover,
.book-cover-cta:focus-visible {
  border-color: var(--color-gold-light);
  transform: translateY(-1px);
  outline: none;
}

.book-cover-count-pill {
  padding: 1px 7px;
  border-radius: 999px;
  background: rgba(184, 147, 90, 0.26);
  color: #FAF8F5;
  font-size: 0.7rem;
}

.book-cover-hint {
  margin: auto 0 0;
  padding-top: 10px;
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 0.84rem;
  color: rgba(226, 217, 204, 0.68);
}

/* Interior de la pasta (solo escritorio) */
.book-inside-frame {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: 14px;
  padding: 28px 26px;
  border: 1px solid rgba(184, 147, 90, 0.3);
  border-radius: 4px;
  background: radial-gradient(circle at 50% 45%, rgba(184, 147, 90, 0.07), transparent 68%);
}

.book-inside-eyebrow {
  font-family: var(--font-sans);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--color-gold);
  margin: 0;
}

.book-inside-quote {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: clamp(1.22rem, 2.2vw, 1.56rem);
  line-height: 1.42;
  color: var(--color-gold-light);
  max-width: 24ch;
  margin: 0;
}

.book-inside-quote--subtle {
  font-size: 1.15rem;
  color: rgba(226, 217, 204, 0.8);
}

.book-inside-divider {
  display: block;
  width: 64px;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--color-gold), transparent);
}

.book-inside-sign {
  font-family: var(--font-serif);
  font-size: 1rem;
  line-height: 1.45;
  color: rgba(250, 248, 245, 0.86);
  margin: 0;
}

.book-inside-sign strong {
  font-weight: 600;
  color: var(--color-gold-light);
}

.book-inside-botanical {
  display: block;
  width: 110px;
  height: 110px;
  background: url('/assets/img/d-rama.svg') center / contain no-repeat;
  opacity: 0.22;
  filter: sepia(0.5) brightness(1.4);
}

.book-inside-footer {
  width: 100%;
  margin: 10px 0 0;
  border-top-color: rgba(184, 147, 90, 0.24);
}

.book-hardcover .book-paper-swipe-hint {
  color: rgba(226, 217, 204, 0.74);
}

.book-hardcover .book-paper-corner-btn {
  background: rgba(250, 248, 245, 0.08);
  border-color: rgba(184, 147, 90, 0.45);
  color: var(--color-gold-light);
  box-shadow: none;
}

.book-hardcover .book-paper-corner-btn:hover:not(:disabled) {
  background: rgba(184, 147, 90, 0.24);
  border-color: var(--color-gold-light);
  color: #FAF8F5;
}

/* Hojas de papel (escritura y dedicatorias) dentro de StPageFlip */
.wedding-book-stage.is-real-book .book-stf-write-page,
.wedding-book-stage.is-real-book .book-stf-sig-page {
  background: #FAF8F5;
  border-radius: 3px;
}

.book-write-paper {
  display: flex;
  flex-direction: column;
  height: 100%;
  padding: 14px 18px 10px;
  background:
    linear-gradient(90deg, rgba(36, 46, 30, 0.1) 0%, transparent 7%),
    linear-gradient(180deg, #FAF8F5 0%, #FBF5E9 100%);
  border: 1px solid rgba(196, 162, 99, 0.42);
}

.book-write-paper #bookWriteView {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-height: 0;
  padding: 0;
  background: transparent;
  border: none;
  box-shadow: none;
  overflow: hidden;
}

.book-write-paper .book-write-wordmark {
  margin: 4px auto 8px;
}

.book-write-paper .book-write-divider {
  margin: 0 auto 10px;
}

.book-write-paper .book-prompt-note {
  margin-bottom: 8px;
}

.book-write-paper #guestbookForm {
  flex: 1 1 auto;
  min-height: 0;
  gap: 8px;
}

.book-write-paper #guestbookForm .book-message-field {
  min-height: 76px;
}

.book-write-paper #guestbookForm #gbMessage {
  min-height: 70px;
}

.book-write-paper #guestbookForm .book-form-actions {
  padding: 4px 8px 8px;
}

.book-write-paper #guestbookForm .book-submit-btn {
  border: 0;
  background-clip: padding-box;
  box-shadow: 0 2px 5px rgba(31, 29, 27, 0.12);
  -webkit-font-smoothing: antialiased;
}

.book-write-paper #guestbookForm .book-submit-btn:hover {
  box-shadow: 0 4px 9px rgba(31, 29, 27, 0.16);
}

.book-write-paper .book-write-paper-footer {
  margin: 8px 0 0;
  padding: 6px 2px 2px;
}

/* En escritorio, ocultar botón prev en la hoja derecha de firma porque la pasta izquierda ya lo tiene */
@media (min-width: 1000px) {
  .book-write-paper[data-book-side="right"] .book-write-paper-footer .book-corner-prev {
    visibility: hidden;
    pointer-events: none;
  }

  .wedding-book-stage.is-real-book .book-stf-sig-page [data-book-side="left"] .book-corner-next,
  .wedding-book-stage.is-real-book .book-stf-sig-page [data-book-side="left"] .book-mode-switch,
  .wedding-book-stage.is-real-book .book-stf-sig-page [data-book-side="right"] .book-corner-prev {
    display: none;
  }

  /* Sombra de lomo central en hojas internas */
  .wedding-book-stage.is-real-book [data-book-side="left"] {
    box-shadow: inset -14px 0 22px -12px rgba(25, 34, 21, 0.22);
  }

  .wedding-book-stage.is-real-book [data-book-side="right"] {
    box-shadow: inset 14px 0 22px -12px rgba(25, 34, 21, 0.22);
  }
}

@media (max-width: 600px) {
  .book-hardcover {
    padding: 14px 12px 12px 20px;
  }
  .book-hardcover--back {
    padding: 14px 20px 12px 12px;
  }
  .book-hardcover-spine {
    width: 14px;
  }
  .book-write-paper {
    padding: 12px 13px 8px;
  }
  .book-write-paper .book-write-wordmark .brand-text {
    font-size: 1.65rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .wedding-book-stage.is-real-book .book-flip-host-wrap,
  .book-portrait-lid {
    transition: none;
  }
}

/* =====================================================================
   TAPAS DURAS 3D EN MÓVIL Y TABLETA VERTICAL (SIN BUG DE drawHard EN PORTRAIT)
   ===================================================================== */
.wedding-book-stage.is-real-book .book-flip-stage {
  perspective: 1800px;
  transform-style: preserve-3d;
}

.book-portrait-lid {
  position: absolute;
  inset: 0;
  z-index: 12;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  will-change: transform, opacity;
  transition:
    transform 0.62s cubic-bezier(0.22, 1, 0.36, 1),
    opacity 0.38s ease,
    visibility 0.62s ease;
  filter: drop-shadow(0 18px 28px rgba(31, 29, 27, 0.28));
}

.wedding-book-stage.is-real-book[data-spread="true"] .book-portrait-lid {
  display: none;
}

.book-portrait-lid--front {
  transform-origin: left center;
  transform: rotateY(-108deg);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.book-portrait-lid--back {
  transform-origin: right center;
  transform: rotateY(108deg);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.wedding-book-stage.is-real-book[data-spread="false"][data-book-state="front"] .book-portrait-lid--front {
  transform: rotateY(0deg);
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

.wedding-book-stage.is-real-book[data-spread="false"][data-book-state="back"] .book-portrait-lid--back {
  transform: rotateY(0deg);
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

/* En tableta vertical (601px - 999px), proporciones cómodas de libro cerrado/abierto */
@media (min-width: 601px) and (max-width: 999px) {
  .wedding-book-stage.is-real-book {
    max-width: 560px;
    max-height: 820px;
  }
}

/* Portada delantera con el diseño clásico original */
.book-hardcover--front {
  padding: 9px 10px 10px 18px;
  border-radius: 10px 22px 22px 10px;
  background: linear-gradient(145deg, #2B2724 0%, #1F1D1B 60%, #171513 100%);
  box-shadow:
    inset 1px 1px 0 rgba(226, 217, 204, 0.28);
}

.book-front-cover-sheet {
  position: relative;
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  background: linear-gradient(110deg, #171513, #1F1D1B 18%, #1F1D1B 66%, #171513);
  border-radius: 4px;
  border: 1px solid rgba(184, 147, 90, 0.42);
  padding: 14px 16px 12px;
  box-shadow: inset 3px 0 9px rgba(0, 0, 0, 0.38), inset 0 1px 0 rgba(226, 217, 204, 0.16);
  color: var(--color-gold-light);
  overflow: hidden;
}

.book-front-cover-sheet::before {
  content: '';
  position: absolute;
  inset: 22px;
  pointer-events: none;
  background: url('/assets/img/d-rama.svg') center / contain no-repeat;
  opacity: 0.045;
}

.book-front-cover-header {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  flex: 1;
  min-height: 0;
  margin: 0;
  padding: 16px 0;
  border: 0;
}

.book-front-cover-header .book-cover-monogram {
  display: block;
  width: min(72%, 320px);
  height: auto;
  max-height: 46dvh;
  object-fit: contain;
  margin: 0 auto 20px;
  filter: drop-shadow(0 1px 0 rgba(255, 241, 196, 0.1)) drop-shadow(0 -2px 1px rgba(0, 0, 0, 0.2));
}

.book-front-cover-header .book-eyebrow {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: clamp(1.8rem, 5vw, 2.6rem);
  font-weight: 600;
  text-transform: none;
  letter-spacing: 0.025em;
  color: var(--color-gold-light);
  margin: 0 0 24px;
}

.book-front-cover-header .book-mode-bar {
  background: rgba(250, 248, 245, 0.05);
}

.book-front-cover-header .book-mode-btn {
  color: var(--color-gold-light);
  min-height: 44px;
}

.book-front-cover-header .book-mode-btn:hover {
  background: rgba(184, 147, 90, 0.14);
}

@media (max-width: 600px) {
  .book-hardcover--front {
    padding: 7px 7px 8px 14px;
    border-radius: 8px 18px 18px 8px;
  }
  .book-front-cover-sheet {
    padding: 11px 11px 10px;
  }
}

/* Contraportada editorial (idéntica al PDF del Libro de Honor + botones de navegación) */
.book-hardcover--back {
  background: linear-gradient(215deg, #2B2724 0%, #1F1D1B 58%, #171513 100%);
  padding: 16px 26px 16px 16px;
}

.book-hardcover-frame--back {
  justify-content: space-between;
  gap: 10px;
  padding: 24px 20px 18px;
  border: 1.5px solid rgba(184, 147, 90, 0.58);
  border-radius: 2px;
  box-shadow:
    inset 0 0 0 4px rgba(31, 29, 27, 0.45),
    inset 0 0 0 5px rgba(184, 147, 90, 0.28);
}

.book-back-cover-top {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.book-back-cover-eyebrow {
  font-family: var(--font-sans);
  font-size: clamp(0.6rem, 1.8vw, 0.72rem);
  font-weight: 600;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--color-gold);
  line-height: 1.4;
}

.book-back-cover-center {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  max-width: 34ch;
}

.book-hardcover-frame--back .book-back-cover-ornament {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  color: var(--color-gold);
  margin: 0;
}

.book-hardcover-frame--back .book-back-cover-ornament span {
  display: block;
  width: clamp(44px, 14vw, 88px);
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--color-gold), transparent);
}

.book-hardcover-frame--back .book-back-cover-quote {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: clamp(0.98rem, 2.9vw, 1.32rem);
  line-height: 1.56;
  color: #FAF8F5;
  font-weight: 400;
  max-width: 34ch;
  margin: 0;
}

.book-back-cover-divider {
  display: block;
  width: clamp(80px, 24vw, 130px);
  height: 1px;
  margin: 2px auto;
  background: linear-gradient(90deg, transparent, rgba(184, 147, 90, 0.7), transparent);
}

.book-back-cover-closing {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
}

.book-back-cover-love {
  font-family: var(--font-serif);
  font-size: clamp(0.76rem, 2vw, 0.92rem);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(226, 217, 204, 0.85);
}

.book-back-cover-sign {
  font-family: 'Italianno', 'Tangerine', cursive;
  font-size: clamp(2.15rem, 6.4vw, 3.05rem);
  line-height: 1.06;
  color: var(--color-gold-light);
}

.book-back-cover-bottom {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  width: 100%;
}

.book-back-cover-footer {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
}

.book-hardcover-frame--back .book-back-cover-monogram {
  width: clamp(54px, 16vw, 84px);
  max-height: 11dvh;
  height: auto;
  margin: 0;
  opacity: 0.9;
}

.book-hardcover-frame--back .book-back-cover-date {
  font-family: var(--font-serif);
  font-size: clamp(0.78rem, 2vw, 0.92rem);
  font-weight: 400;
  letter-spacing: 0.24em;
  text-transform: none;
  color: rgba(226, 217, 204, 0.78);
  margin: 0;
}

.book-hardcover-frame--back .book-back-cover-actions {
  margin-top: 0;
  max-width: 100%;
  gap: 8px;
}

@media (max-width: 600px), (max-height: 700px) {
  .book-hardcover--back {
    padding: 12px 20px 12px 12px;
  }

  .book-hardcover-frame--back {
    padding: 16px 14px 14px;
    gap: 8px;
  }

  .book-back-cover-center {
    gap: 8px;
  }

  .book-hardcover-frame--back .book-back-cover-quote {
    font-size: clamp(0.9rem, 3.3vw, 1.06rem);
    line-height: 1.46;
  }

  .book-back-cover-sign {
    font-size: clamp(1.9rem, 7.2vw, 2.45rem);
  }

  .book-back-cover-bottom {
    gap: 9px;
  }

  .book-hardcover-frame--back .book-back-cover-monogram {
    width: clamp(46px, 14vw, 66px);
    max-height: 9dvh;
  }
}

/* Bloquear gestos de zoom táctil y evitar desplazamiento del texto si el navegador fuerza zoom en Home */
html.home-no-scroll {
  position: relative;
  width: 100%;
  height: var(--app-height, 100dvh);
  touch-action: pan-x pan-y;
}

body.page-home {
  position: relative;
  inset: auto;
  width: 100%;
  height: 100%;
  max-height: none;
  touch-action: pan-x pan-y;
}

body.page-home .hero-app-cover,
body.page-home .hero-btn {
  touch-action: manipulation;
}

/* Home en pantalla completa / PWA (iOS y Android): foto de fondo edge-to-edge sin franja inferior ni superior */
@media (display-mode: standalone), (display-mode: fullscreen) {
  html.home-no-scroll {
    height: 100%;
    min-height: 100vh !important;
    min-height: 100lvh !important;
    background-color: #171513;
  }

  body.page-home {
    position: fixed;
    inset: 0;
    width: 100%;
    height: 100%;
    min-height: 100vh !important;
    min-height: 100lvh !important;
    max-height: none;
    display: flex;
    flex-direction: column;
  }

  body.page-home .app-main-home,
  body.page-home .hero-app-cover {
    flex: 1 1 auto;
    height: 100%;
    min-height: 100vh !important;
    min-height: 100lvh !important;
    max-height: none;
  }

  body.page-home .hero-slideshow {
    position: fixed;
    inset: 0;
    width: 100%;
    height: 100%;
    min-height: 100vh;
    min-height: 100lvh;
  }
}

html.is-pwa-standalone.home-no-scroll {
  height: 100%;
  min-height: 100vh !important;
  min-height: 100lvh !important;
  background-color: #171513;
}

html.is-pwa-standalone body.page-home {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  min-height: 100vh !important;
  min-height: 100lvh !important;
  max-height: none;
  display: flex;
  flex-direction: column;
}

html.is-pwa-standalone body.page-home .app-main-home,
html.is-pwa-standalone body.page-home .hero-app-cover {
  flex: 1 1 auto;
  height: 100%;
  min-height: 100vh !important;
  min-height: 100lvh !important;
  max-height: none;
}

html.is-pwa-standalone body.page-home .hero-slideshow {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  min-height: 100vh;
  min-height: 100lvh;
}
