/* --------------------------------------------------
   Reset básico
-------------------------------------------------- */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

/* Variables de color: modo claro por defecto; modo oscuro bajo la clase `dark` en body */
:root {
  --bg: #faf8f4;
  --surface: #ffffff;
  --muted: #777;
  --heading-tone: #5a4024;
  --text: #222222;
  --primary: #d09b5f;
  --primary-contrast: #ffffff;
  --accent: #b06a28;
  --card-border: #e0d6ca;
  --header-bg: rgba(250, 248, 244, 0.95);
  --section-alt-bg: #f3eee5;
  --footer-bg: #f7f2ea;
  --shadow: rgba(0,0,0,0.14);
}

body.dark {
  --bg: #0f1115;
  --surface: #111214;
  --muted: #a0a6af;
  --heading-tone: var(--muted);
  --text: #e6eef6;
  --primary: #b27b3f;
  --primary-contrast: #0f1115;
  --accent: #caa26a;
  --card-border: #1e2226;
  --header-bg: rgba(16,18,21,0.7);
  --section-alt-bg: #0d1013;
  --footer-bg: #0b0d10;
  --shadow: rgba(0,0,0,0.6);
}

body {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--text);
  background-color: var(--bg);
  line-height: 1.6;
}

.paragraph-justified,
.prefacio-text,
.prefacio-text p {
  text-align: justify;
  text-justify: inter-word;
}

.paragraph-center {
  text-align: center;
  margin-bottom: 0.8rem;
}

/* Contenedor genérico */
.container {
  width: 100%;
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 16px;
}

/* --------------------------------------------------
   Header / Navegación
-------------------------------------------------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background-color: var(--header-bg);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--card-border);
  overflow: visible;
  transition: transform 0.3s ease;
}

.site-header.hidden {
  transform: translateY(-100%);
}

.header-bg-image {
  position: absolute;
  top: 0;
  right: -100px;
  width: 600px;
  height: 250px;
  background-image: url('images/orquesta 01.jpg');
  background-size: cover;
  background-position: center right;
  opacity: 0.15;
  pointer-events: none;
  z-index: 0;
}

.header-inner {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 0;
  gap: 32px;
}

.logo {
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.logo-img {
  height: 60px;
  width: auto;
  display: block;
}

.logo-title {
  display: block;
  font-weight: 600;
  font-size: 1rem;
}

.logo-subtitle {
  display: block;
  font-size: 0.8rem;
  color: var(--muted);
}

.main-nav {
  display: flex;
  gap: 24px;
  flex-wrap: wrap;
  flex: 1;
  justify-content: center;
}

.main-nav a {
  font-size: 0.95rem;
  text-decoration: none;
  color: var(--text);
  padding: 8px 12px;
  border-radius: 4px;
  transition: background-color 0.2s ease, color 0.2s ease;
  position: relative;
}

.main-nav a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background-color: var(--primary);
  transition: width 0.3s ease;
}

.main-nav a:hover {
  background-color: rgba(180,150,110,0.12);
  color: var(--text);
}

.main-nav a:hover::after {
  width: 100%;
}

/* Por defecto, elementos móviles están ocultos en escritorio */
.mobile-menu-button {
  display: none;
}

.mobile-nav {
  display: none;
}

/* Botones de reproducción de audio - Estilos principales */
/* (Los estilos específicos están definidos en la sección de listado de obras) */

/* --------------------------------------------------
   Secciones generales
-------------------------------------------------- */
.section {
  padding: 64px 0;
}

.section-alt {
  background-color: var(--section-alt-bg);
}

.section-header {
  text-align: center;
  margin-bottom: 32px;
}

.section-header h2 {
  font-size: 2rem;
  margin-bottom: 8px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  position: relative;
  display: inline-block;
  padding-bottom: 6px;
  color: var(--accent);
}

.section-header h2::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: 0;
  transform: translateX(-50%);
  width: 64px;
  height: 2px;
  background: linear-gradient(to right, #d09b5f, #b06a28);
  border-radius: 999px;
}

.section-header p {
  color: var(--muted);
  max-width: 640px;
  margin: 0 auto;
}

/* --------------------------------------------------
   Hero
-------------------------------------------------- */
.hero {
  padding-top: 80px;
  padding-bottom: 72px;
  background: radial-gradient(circle at top left, rgba(243,229,214,0.6) 0, var(--bg) 45%, var(--bg) 100%);
}

.hero-inner {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr);
  gap: 32px;
  align-items: center;
}

.hero-text h1 {
  font-size: 2.8rem;
  margin-bottom: 16px;
  margin-top: 20px;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.hero-logo {
  margin-bottom: 20px;
}

.hero-logo img {
  max-height: 80px;
  width: auto;
  object-fit: contain;
}

.hero-subtitle {
  font-size: 1.1rem;
  margin-bottom: 8px;
}

.hero-description {
  color: var(--muted);
  margin-bottom: 20px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

/* Botones */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 18px;
  border-radius: 999px;
  font-size: 0.95rem;
  text-decoration: none;
  cursor: pointer;
  font-weight: 600;
  letter-spacing: 0.03em;
  transition:
    background-color 0.25s ease,
    color 0.25s ease,
    box-shadow 0.25s ease,
    transform 0.25s ease;
}

/* Botón principal: tono cálido */
.btn.primary {
  background-color: var(--primary);
  color: var(--primary-contrast);
  box-shadow: 0 4px 10px var(--shadow);
}

.btn.primary:hover {
  filter: brightness(0.95);
  box-shadow: 0 8px 20px rgba(0,0,0,0.28);
  transform: translateY(-2px);
}

/* Botón secundario */
.btn.secondary {
  border: 1px solid var(--primary);
  color: var(--accent);
  background-color: transparent;
  box-shadow: none;
}

.btn.secondary:hover {
  background-color: rgba(200,170,130,0.06);
  box-shadow: 0 6px 16px rgba(0,0,0,0.18);
  transform: translateY(-2px);
}

/* Foto del hero */
.hero-image {
  display: flex;
  justify-content: center;
  position: relative;
}

.hero-photo {
  width: 100%;
  max-width: 500px;
  height: auto;
  border-radius: 12px;
  border: none;
  object-fit: cover;
  box-shadow: 0 12px 30px var(--shadow);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  display: block;
}

.hero-photo:hover {
  transform: translateY(-4px);
  box-shadow: 0 16px 40px var(--shadow);
}

/* Transición y ajustes para imágenes en modo oscuro */
img {
  transition: filter 0.25s ease, opacity 0.25s ease;
}

body.dark img {
  filter: brightness(0.95) contrast(0.92);
}

/* --------------------------------------------------
   Layouts de columnas y tarjetas
-------------------------------------------------- */
.two-columns {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 32px;
  max-width: 760px;
  margin: 0 auto;
  text-align: center;
}

.two-columns h3 {
  margin-bottom: 8px;
  font-size: 1.05rem;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: var(--heading-tone);
}

.two-columns p {
  color: #555;
}

.cards-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 20px;
}

/* Centramos el contenido de las tarjetas en las secciones "Explora mi obra" y "Lugares" */
#explora-obra .card,
#lugares .card {
  text-align: center;
}

.card {
  background-color: var(--surface);
  border-radius: 12px;
  padding: 1.5rem;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.06);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.card:hover {
  transform: translateY(-6px);
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.12);
}

.card h3 {
  font-size: 1.1rem;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: var(--accent);
}

.card p {
  font-size: 0.95rem;
  color: var(--muted);
}

.card-link {
  margin-top: auto;
  font-size: 0.9rem;
  color: #b06a28;
  text-decoration: none;
}

/* --------------------------------------------------
   Estilos móviles: menú hamburguesa y posicionamiento
   - Mantener versión de escritorio intacta
-------------------------------------------------- */
@media (max-width: 768px) {
  .main-nav { display: none; }

  .header-inner { 
    padding: 12px 16px;
    gap: 8px;
    justify-content: flex-start;
    align-items: center;
    flex-wrap: nowrap;
    flex-direction: row;
  }

  .logo { 
    flex-shrink: 0;
    margin-right: auto;
  }

  /* Header actions (tema + idioma) */
  .header-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    z-index: 105;
    flex-shrink: 0;
  }

  /* Botón hamburguesa a la derecha */
  .mobile-menu-button {
    display: inline-flex;
    width: 42px;
    height: 36px;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: none;
    cursor: pointer;
    z-index: 110;
    flex-direction: column;
    flex-shrink: 0;
  }

  .mobile-menu-button .bar {
    display: block;
    width: 22px;
    height: 2px;
    background: var(--text);
    margin: 3px 0;
    border-radius: 2px;
    transition: transform 0.2s ease, opacity 0.2s ease;
  }

  /* Menú móvil desplegable — aparece debajo, alineado a la izquierda */
  .mobile-nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 16px;
    min-width: 200px;
    background: var(--surface);
    border: 1px solid var(--card-border);
    border-radius: 10px;
    padding: 8px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.18);
    flex-direction: column;
    gap: 6px;
    z-index: 120;
  }

  .mobile-nav.open { display: flex; }

  .mobile-nav a {
    color: var(--text);
    text-decoration: none;
    padding: 8px 12px;
    border-radius: 6px;
  }

  .mobile-nav a:hover {
    background: rgba(180,150,110,0.08);
  }

  /* Ajustes generales del layout móvil */
  .hero-inner { grid-template-columns: 1fr; }
  .cards-grid { grid-template-columns: repeat(1, 1fr); }
  .two-columns { grid-template-columns: 1fr; }

  /* INTRO móvil 1:1 */
  #intro-video-container {
    align-items: center;
    justify-content: center;
    background: #000;
  }

  #intro-video-container video {
    width: min(90vw, 90vh);
    height: min(90vw, 90vh);
    object-fit: cover;
    border-radius: 12px;
  }
}

.card-link:hover {
  text-decoration: underline;
}

/* Imágenes para la sección "Lugares" */
.place-photo {
  width: 100%;
  height: 140px;
  object-fit: cover;
  border-radius: 10px;
  border: 1px solid var(--card-border);
  display: block;
  margin-bottom: 10px;
}

@media (max-width: 900px) {
  .place-photo {
    height: 120px;
  }
}

/* --------------------------------------------------
   Single column / texto
-------------------------------------------------- */
.single-column {
  max-width: 720px;
  margin: 0 auto;
  color: var(--text);
}

.single-column p + p {
  margin-top: 12px;
}

.paragraph-justified {
  text-align: justify;
}

.paragraph.paragraph-justified {
  text-align: justify;
}

/* --------------------------------------------------
   Listado de obras
-------------------------------------------------- */
.works-list {
  margin-top: 24px;
  display: grid;
  gap: 16px;
}

.work-item {
  padding: 14px 16px;
  border-radius: 10px;
  background-color: var(--surface);
  border: 1px solid var(--card-border);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.work-item:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.14);
}

/* Obras con portada pequeña */
.work-inner {
  display: flex;
  gap: 12px;
  align-items: start;
}

.work-cover {
  position: relative;
  width: 64px;
  height: 64px;
  border-radius: 8px;
  background-color: rgba(240,230,216,0.06);
  flex-shrink: 0;
  overflow: visible;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.7rem;
  color: var(--accent);
}

.work-cover img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  border-radius: 8px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.08);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  cursor: pointer;
}

.work-cover img.zoomed {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 50vw;
  height: auto;
  max-height: 70vh;
  border-radius: 12px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
  z-index: 10000;
  object-fit: contain;
}

.zoom-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.7);
  z-index: 9999;
  cursor: pointer;
}

.play-btn {
  width: 40px;
  height: 40px;
  border: 2px solid var(--primary);
  border-radius: 50%;
  background: var(--surface);
  color: var(--primary);
  font-size: 1rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background-color 0.2s ease, color 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
  flex-shrink: 0;
}

.play-btn:hover {
  background: var(--primary);
  color: var(--primary-contrast);
  transform: scale(1.1);
  border-color: var(--accent);
  box-shadow: 0 0 0 4px rgba(208, 155, 95, 0.15);
}

.play-btn.playing {
  background-color: var(--primary);
  color: var(--primary-contrast);
  border-color: var(--accent);
  box-shadow: 0 0 0 8px rgba(208, 155, 95, 0.25);
  transform: scale(1.05);
}

.prefacio-btn {
  margin-top: 10px;
  padding: 8px 16px;
  border: 1px solid var(--card-border);
  border-radius: 20px;
  background: var(--surface);
  color: var(--primary);
  font-size: 0.85rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.prefacio-btn::before {
  content: '📖';
  font-size: 1rem;
}

.prefacio-btn:hover {
  background: var(--primary);
  color: var(--primary-contrast);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.prefacio-text {
  margin-top: 10px;
  padding: 12px 16px;
  border-radius: 12px;
  background: var(--section-alt-bg);
  color: var(--text);
  line-height: 1.6;
  border-left: 4px solid var(--primary);
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s ease, padding 0.4s ease;
}

.prefacio-text.open {
  max-height: 1000px;
  padding: 12px 16px;
}

.work-content h3 {
  margin-bottom: 4px;
  font-size: 1.05rem;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: var(--heading-tone);
}

.work-desc {
  font-size: 0.95rem;
  color: var(--text);
}

/* En modo oscuro, cajetín sutil para mejorar legibilidad */
body.dark .two-columns h3,
body.dark .work-content h3 {
  background: rgba(255,255,255,0.03);
  padding: 6px 12px;
  border-radius: 8px;
  display: inline-block;
  color: var(--heading-tone);
}

body.dark .work-desc {
  color: var(--accent);
}

/* En pantallas pequeñas, portada encima del texto */
@media (max-width: 600px) {
  .work-inner {
    flex-direction: column;
  }

  .work-cover {
    width: 72px;
    height: 72px;
  }
}

/* --------------------------------------------------
   Galería
-------------------------------------------------- */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.gallery-item {
  background-color: rgba(233,223,209,0.04);
  border-radius: 10px;
  height: 120px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent);
  font-size: 0.9rem;
}

/* --------------------------------------------------
   Videos
-------------------------------------------------- */
.videos-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 20px;
  max-width: 100%;
}

.video-item {
  background-color: rgba(233,223,209,0.04);
  border-radius: 10px;
  padding: 10px;
  display: flex;
  justify-content: center;
  align-items: center;
}

.video-item iframe {
  width: 100%;
  height: 315px;
  border-radius: 8px;
}

/* --------------------------------------------------
   Contacto
-------------------------------------------------- */
.contact-details {
  max-width: 480px;
  margin: 0 auto;
  text-align: center;
  color: var(--text);
}

.contact-details a {
  color: var(--accent);
  text-decoration: none;
}

.contact-details a:hover {
  text-decoration: underline;
}

/* --------------------------------------------------
   Footer
-------------------------------------------------- */
.site-footer {
  border-top: 1px solid var(--card-border);
  background-color: var(--footer-bg);
  padding: 16px 0 20px;
  font-size: 0.85rem;
  color: var(--muted);
}

.footer-inner {
  text-align: center;
}

.footer-inner p + p {
  margin-top: 6px;
}

/* --------------------------------------------------
   Responsivo
-------------------------------------------------- */
@media (max-width: 900px) {
  .hero-inner {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .hero-image {
    order: -1;
  }

  .hero-photo {
    width: 180px;
    height: 180px;
  }

  .two-columns {
    grid-template-columns: 1fr;
  }

  .cards-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .gallery-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .header-inner {
    flex-direction: column;
    align-items: flex-start;
  }

  .main-nav {
    justify-content: flex-start;
  }
}

@media (max-width: 600px) {
  .section {
    padding: 40px 0;
  }

  .hero {
    padding-top: 64px;
    padding-bottom: 56px;
  }

  .hero-text h1 {
    font-size: 1.5rem;
  }

  .section-header h2 {
    font-size: 1.6rem;
  }

  .cards-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .card {
    padding: 1.25rem;
  }

  .gallery-grid {
    grid-template-columns: 1fr 1fr;
  }
}

/* Toggle de tema e idioma */
.header-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.theme-toggle {
  background: transparent;
  border: 1px solid rgba(0,0,0,0.08);
  color: var(--text);
  padding: 6px 10px;
  border-radius: 999px;
  cursor: pointer;
  font-size: 0.85rem;
  font-weight: 500;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: background-color 0.15s ease, color 0.15s ease, transform 0.12s ease;
}

.theme-toggle:hover {
  transform: translateY(-2px);
  background-color: rgba(208, 155, 95, 0.1);
}

.theme-toggle:focus {
  outline: 2px solid rgba(0,0,0,0.12);
}

/* Language toggle - flag indicators */
.lang-toggle-group {
  display: inline-flex;
  gap: 6px;
}

.lang-toggle {
  width: 24px;
  height: 16px;
  border-radius: 3px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  box-shadow: inset 0 0 0 0.5px rgba(0,0,0,0.2);
}

.lang-toggle:hover {
  transform: scale(1.15);
}

.lang-toggle:focus {
  outline: 2px solid rgba(0,0,0,0.12);
  outline-offset: 2px;
}

.lang-toggle.active {
  box-shadow: 0 0 0 2px rgba(0,0,0,0.3);
}

/* Spain flag - red and yellow gradient */
.lang-toggle.flag-es {
  background: linear-gradient(to bottom, 
    #FF0000 0%,
    #FF0000 25%,
    #FFC400 25%,
    #FFC400 75%,
    #FF0000 75%,
    #FF0000 100%);
}

/* United Kingdom flag - image */
.lang-toggle.flag-en {
  background-image: url('../images/uk.jpg');
}

@media (max-width: 900px) {
  .theme-toggle {
    margin-top: 8px;
    font-size: 0.75rem;
    padding: 5px 8px;
  }
}

/* --------------------------------------------------
   Estilos para Carrusel de Galería
-------------------------------------------------- */
.gallery-carousel {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.carousel-container {
  display: grid;
  grid-template-columns: 60px 1fr 60px;
  gap: 16px;
  align-items: center;
  background-color: var(--surface);
  padding: 24px;
  border-radius: 12px;
  box-shadow: 0 4px 10px var(--shadow);
}

.carousel-main {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.carousel-image-wrapper {
  overflow: hidden;
  border-radius: 8px;
  background-color: var(--bg);
  display: flex;
  align-items: center;
  justify-content: center;
  aspect-ratio: 4 / 3;
}

.carousel-image {
  width: 100%;
  height: 100%;
  object-fit: contain;
  transition: transform 0.3s ease;
}

.carousel-image:hover {
  transform: scale(1.02);
}

.carousel-description {
  min-height: 60px;
  padding: 12px;
  background-color: var(--section-alt-bg);
  border-radius: 6px;
  border-left: 4px solid var(--primary);
}

.description-text {
  font-size: 0.95rem;
  color: var(--text);
  line-height: 1.5;
  margin: 0;
}

.carousel-control {
  background-color: var(--primary);
  color: var(--primary-contrast);
  border: none;
  border-radius: 50%;
  width: 50px;
  height: 50px;
  font-size: 24px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background-color 0.3s ease, transform 0.2s ease;
}

.carousel-control:hover {
  background-color: var(--accent);
  transform: scale(1.1);
}

.carousel-control:active {
  transform: scale(0.95);
}

.carousel-indicators {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

.image-counter {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--muted);
}

.carousel-dots {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  justify-content: center;
  max-width: 400px;
}

.carousel-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background-color: var(--card-border);
  cursor: pointer;
  transition: background-color 0.3s ease, transform 0.2s ease;
}

.carousel-dot:hover {
  transform: scale(1.2);
}

.carousel-dot.active {
  background-color: var(--primary);
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .carousel-container {
    grid-template-columns: 48px 1fr 48px;
    padding: 16px;
    gap: 12px;
  }

  .carousel-control {
    width: 48px;
    height: 48px;
    font-size: 20px;
  }

  .carousel-image-wrapper {
    aspect-ratio: 16 / 9;
  }

  .carousel-dots {
    max-width: 300px;
  }
}

@media (max-width: 480px) {
  .carousel-container {
    grid-template-columns: 40px 1fr 40px;
    padding: 12px;
    gap: 8px;
  }

  .carousel-control {
    width: 40px;
    height: 40px;
    font-size: 18px;
  }

  .carousel-image-wrapper {
    aspect-ratio: 16 / 9;
  }

  .carousel-description {
    min-height: 50px;
    padding: 8px;
  }

  .carousel-dots {
    max-width: 250px;
  }

  .image-counter {
    font-size: 0.85rem;
  }
}

/* --------------------------------------------------
   Estilos para Prefacios
-------------------------------------------------- */
.prefacio-text {
  max-height: 400px;
  overflow-y: auto;
  font-size: 0.9rem;
  line-height: 1.5;
  padding: 12px;
  background-color: var(--surface);
  border-radius: 6px;
  border-left: 4px solid var(--primary);
  margin-top: 8px;
}

.prefacio-text p {
  margin-bottom: 12px;
}

.prefacio-text p:last-child {
  margin-bottom: 0;
}
