/* =========================
   RESET / BASE
========================= */
body {
  margin: 0;
  font-family: 'Lora', serif;
  background: #FAF8F5;
  color: #2A1F19;
  overflow-x: hidden;
}

/* Toast de confirmación */
.toast {
  position: fixed;
  bottom: 24px;
  right: 24px;
  background: #4CAF50;
  color: white;
  padding: 16px 24px;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  z-index: 10000;
  animation: slideInRight 0.3s ease;
  font-weight: 500;
}

.toast.error {
  background: #f44336;
}

.toast.info {
  background: #2196F3;
}

@keyframes slideInRight {
  from {
    transform: translateX(400px);
    opacity: 0;
  }
  to {
    transform: translateX(0);
    opacity: 1;
  }
}

@keyframes slideOutRight {
  from {
    transform: translateX(0);
    opacity: 1;
  }
  to {
    transform: translateX(400px);
    opacity: 0;
  }
}

.toast.hide {
  animation: slideOutRight 0.3s ease forwards;
}

/* TIPOGRAFÍA */
h1, h2, h3, .brand-logo {
  font-family: 'Playfair Display', serif;
  letter-spacing: 0.5px;
  text-align: center;
  font-weight: 400;
}

p, li, input, textarea {
  font-weight: 300;
}

p, li {
    color: #4A3A32;
}

/* =========================
   ANIMACIONES
========================= */
body.fade-in {
  opacity: 0;
  animation: fadeIn 1s ease forwards;
}

@keyframes fadeIn {
  to { opacity: 1; }
}

@keyframes slideUp {
  from { transform: translateY(40px); opacity: 0; }
  to { transform: translateY(0); opacity: 1; }
}

/* =========================
   HERO
========================= */
.hero {
  position: relative;
  height: 100vh;
  background-size: cover;
  background-position: center;
  display: flex;
  align-items: center;
  justify-content: center;
  padding-top: 40px;
}

.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(
      to bottom,
      rgba(42, 31, 25, 0.25) 0%,
      rgba(42, 31, 25, 0.55) 40%,
      rgba(250, 248, 245, 0.95) 100%
    );
}


.hero-content {
  position: relative;
  text-align: center;
  z-index: 2;
  animation: slideUp 1s ease;
  max-width: 760px;
  padding: 32px 28px;
  border-radius: 24px;
  background: rgba(20, 14, 10, 0.30);
  backdrop-filter: blur(2px);
}

.hero img:not(.brand-logo) {
  width: 210px;
  height: 210px;
  border-radius: 50%;
  object-fit: cover;
  margin-bottom: 15px;
  border: 4px solid rgba(255, 255, 255, 0.85);
  box-shadow: 0 10px 28px rgba(42, 31, 25, 0.18);
}

.hero h1 {
  font-size: 3.75rem;
  font-weight: 500;
  letter-spacing: 1px;
  text-transform: capitalize;
  margin: 10px 0;
  color: #FAF8F5;
  text-shadow: 0 2px 20px rgba(0, 0, 0, 0.5);
}

.hero-dates {
  font-family: 'Lora', serif;
  font-size: 1.5em;
  font-weight: 300;
  letter-spacing: 0.5px;
  color: rgba(250, 248, 245, 0.90);
  margin: 4px 0 28px;
}

.hero p {
  max-width: 600px;
  margin: 20px auto 0;
  color: rgba(250, 248, 245, 0.88);
  text-shadow: 0 1px 8px rgba(0, 0, 0, 0.4);
}

/* =========================
   SECCIONES
========================= */
.section {
  padding: 60px 20px;
  max-width: 1000px;
  margin: auto;
  opacity: 0;
  transform: translateY(30px);
  transition: all 0.6s ease;
  color: #2A1F19;
}

.section.visible {
  opacity: 1;
  transform: translateY(0);
}

h2 {
  font-size: 2.25em;
  margin-bottom: 20px;
}

h3 {
  font-size: 1.75em;
  margin-bottom: 12px;
}

h2, h3 {
  color: #2A1F19;
}

/* =========================
   GALERÍA
========================= */
.gallery {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(288px,1fr));
  gap: 12px;
}

.gallery img, .gallery video, .gallery audio {
  width: 100%;
  height: 256px;
  object-fit: cover;
  border-radius: 10px;
  cursor: pointer;
  transition: transform 0.3s, opacity 0.3s;
  box-shadow: 0 8px 20px rgba(42, 31, 25, 0.08);
}

.gallery img:hover, .gallery video:hover, .gallery audio:hover {
  transform: scale(1.05);
  opacity: 0.96;
}

/* =========================
   LIGHTBOX
========================= */


.lightbox {
  position: fixed;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 999;
  background: rgba(42, 31, 25, 0.9)
  /*   background: rgba(0,0,0,0.9); */
}

.lightbox.active {
  display: flex;
}

.lightbox img {
  max-width: 90%;
  max-height: 90%;
}

.lightbox img {
  max-width: 90%;
  max-height: 90%;
  border-radius: 10px;
}

.lightbox-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 52px;
  height: 52px;
  border: none;
  border-radius: 50%;
  background: rgba(255,255,255,0.18);
  color: white;
  font-size: 2rem;
  line-height: 1;
  cursor: pointer;
  backdrop-filter: blur(6px);
  transition: background 0.25s ease;
}

.lightbox-arrow:hover {
  background: rgba(255,255,255,0.28);
}

.lightbox-arrow.left {
  left: 24px;
}

.lightbox-arrow.right {
  right: 24px;
}

.lightbox-content {
  display: flex;
  align-items: center;
  justify-content: center;
  max-width: 90%;
  max-height: 90%;
}

.lightbox-content img,
.lightbox-content video {
  max-width: 100%;
  max-height: 90vh;
  border-radius: 10px;
}

.lightbox-content audio {
  width: min(90vw, 600px);
}

/* =========================
   MENSAJES
========================= */

.messages-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 20px;
  margin-bottom: 48px;
}

.message-card {
  background: #F3EEE8;
  border: 1px solid rgba(42, 31, 25, 0.08);
  border-radius: 12px;
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.message-text {
  font-family: 'Lora', serif;
  font-style: italic;
  font-size: 1.05em;
  line-height: 1.7;
  color: #2A1F19;
  margin: 0;
}

.message-author {
  font-size: 0.88em;
  font-weight: 500;
  color: #7A6A62;
  text-align: right;
  margin: 0;
}

/* =========================
   FORMULARIOS (BASE COMPARTIDA)
========================= */
form input,
form textarea,
form select {
  width: 100%;
  margin-bottom: 10px;
  padding: 10px;
  border-radius: 6px;
  border: none;
}

/* BOTÓN */
form button {
  background: #2A1F19;
  color: #FAF8F5;
  border: 1px solid rgba(255,255,255,0.2);
  padding: 12px 22px;
  border-radius: 999px;
  backdrop-filter: blur(6px);
  font-weight: 500;
  letter-spacing: 0.6px;
  transition: all 0.3s ease;
  cursor: pointer;
}

form button:hover {
  background: #4a382f;
  border-color: #4a382f;
  transform: translateY(-1px);
  box-shadow: 0 8px 22px rgba(42, 31, 25, 0.25);
}

form input::placeholder,
form textarea::placeholder {
  color: #8A776C;
}

form input:focus,
form textarea:focus,
form select:focus {
  outline: none;
  border-color: rgba(42, 31, 25, 0.25);
  box-shadow: 0 0 0 3px rgba(42, 31, 25, 0.08);
}
/* =========================
   NAV
========================= */
.nav {
  position: absolute;
  top: 20px;
  right: 30px;
  z-index: 3;
}

.nav a, .nav-fixed a {
  /* margin-left: 15px; */
  margin-right: 15px;
  color: white;
  text-decoration: none;
  font-size: 0.95em;
  opacity: 0.8;
}

.nav a:hover, .nav-fixed a:hover {
  opacity: 1;
}

.nav-fixed {
  position: fixed;
  top: 0;
  width: 100%;
  background: rgba(0,0,0,0.6);
  padding: 10px;
  text-align: right;
  opacity: 0;
  pointer-events: none;
  z-index: 1000;
  backdrop-filter: blur(6px);
}

.nav-fixed.visible {
  opacity: 1;
  pointer-events: auto;
}

/* =========================
   LOGO
========================= */

.brand-logo {
  position: fixed;
  top: 16px;
  left: 16px;
  width: 72px;
  height: 72px;
  object-fit: cover;
  border: none;
  border-radius: 50%;
  z-index: 1050;
  box-shadow: 0 4px 14px rgba(42, 31, 25, 0.18);
  pointer-events: none;
}

/* Separación visual suave entre secciones */
.section:not(:last-child) {
  border-bottom: 1px solid rgba(42, 31, 25, 0.06);
}

.gallery-thumb {
  position: relative;
  display: inline-block;
  width: fit-content;
  line-height: 0; /* evita espacio inline */
}

.gallery-thumb img {
  display: block;
  width: 100%;
  
}

.play-icon {
  position: absolute;
  inset: 0; /* ocupa exactamente el thumbnail */

  display: flex;
  align-items: center;
  justify-content: center;

  pointer-events: none;
}

.play-icon::before {
  content: "▶";

  width: 56px;
  height: 56px;
  border-radius: 50%;

  display: flex;
  align-items: center;
  justify-content: center;

  background: rgba(0, 0, 0, 0.45);
  color: white;
  font-size: 24px;
  line-height: 1;

  box-shadow: 0 4px 14px rgba(0,0,0,0.25);
}

.hamburger {
  display: none;
  position: fixed;
  top: 16px;
  right: 16px;
  z-index: 1100;

  width: 40px;
  height: 40px;

  background: rgba(0,0,0,0.5);
  border: none;
  border-radius: 8px;
  backdrop-filter: blur(6px);

  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 5px;

  cursor: pointer;
}

.hamburger span {
  width: 20px;
  height: 2px;
  background: white;
  display: block;
}

/* =========================
   MOBILE (<= 768px)
========================= */

@media (max-width: 768px) {

  .hero {
    height: auto;
    min-height: 80vh;
    padding: 80px 16px 40px;
  }

  .hero-content {
    padding: 20px;
    border-radius: 16px;
  }

  .hero img:not(.brand-logo) {
    width: 120px;
    height: 120px;
  }

  .hero h1 {
    font-size: 3.2em;
  }

  .hero p {
    font-size: 0.95em;
  }

  .nav {
    top: 10px;
    right: 10px;
    font-size: 0.85em;
  }

  .nav a {
    margin-right: 10px;
  }

  .brand-logo {
    width: 40px;
    height: 40px;
    top: 10px;
    left: 10px;
  }

  .section {
    padding: 40px 16px;
  }

  h2 {
    font-size: 1.4em;
  }

  .gallery {
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 8px;
  }

  .gallery img,
  .gallery video,
  .gallery audio {
    height: 160px;
  }

  .lightbox-arrow {
    width: 40px;
    height: 40px;
    font-size: 1.5rem;
  }

  .nav-fixed {
    opacity: 0 !important;
    pointer-events: none !important;
  }

  .hamburger {
    display: flex;
  }

  .nav-fixed.mobile-open {
    opacity: 1 !important;
    pointer-events: auto !important;

    position: fixed;
    top: 0;
    right: 0;
    width: fit-content;
    max-width: 85vw;
    height: 100vh;

    background: rgba(42, 31, 25, 0.95);
    backdrop-filter: blur(10px);

    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: flex-start;

    padding: 80px 24px 24px;
    gap: 16px;

    text-align: left;
  }

  .nav-fixed.mobile-open a {
    font-size: 1.2em;
    color: #FAF8F5;
  }

  .lightbox-arrow {
    width: 64px;
    height: 64px;
    font-size: 2rem;

    /* mejora interacción táctil */
    background: rgba(255,255,255,0.25);
  }

  .lightbox-arrow:active {
    transform: translateY(-50%) scale(0.95);
  }
}

.site-footer {
  text-align: center;
  padding: 32px 20px;
  border-top: 1px solid rgba(42, 31, 25, 0.06);
  font-size: 0.82rem;
  color: #9E8E85;
  font-weight: 300;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.site-footer a {
  color: #6E5B52;
  text-decoration: none;
}

.site-footer a:hover {
  text-decoration: underline;
}

.bio-content {
  display: flex;
  align-items: flex-start;
  gap: 32px;
}

.bio-photo {
  flex: 0 0 40%;
  min-width: 0;
  border-radius: 12px;
  object-fit: cover;
  align-self: stretch;
  box-shadow: 0 8px 24px rgba(42, 31, 25, 0.12);
}

@media (max-width: 768px) {
  .bio-content {
    flex-direction: column;
    align-items: center;
  }

  .bio-photo {
    width: 100%;
    max-width: 320px;
  }
}

.section-title-underline {
  background-color: lab(71.2019% 8.2458 52.3464);
  width: 7rem;
  height: 0.1rem;
  margin-inline: auto;
  margin-bottom: 3rem;
}

.quote {
  font-size: 1.2em;
  font-style: italic;
}

p.quote-attribution {
  font-size: 0.9em;
  margin: 10px;
}

#biografia,
#mensajes {
  background: #ffffff;
}

#historia {
  background: #FAF8F5;
}

#biografia,
#historia,
#mensajes {
  max-width: 100%;
  padding-left: 0;
  padding-right: 0;
}

#biografia > *,
#historia > *,
#mensajes > * {
  max-width: 1000px;
  margin-left: auto;
  margin-right: auto;
  padding-left: 20px;
  padding-right: 20px;
}

#mensajes form {
  width: 50%;
}

#mensajes form input,
#mensajes form textarea {
  background: #F3EEE8;
  border: 1px solid rgba(42, 31, 25, 0.12);
}
