/* css/estilo.css */
:root {
  --color-eleggua: #c00000;     /* Rojo */
  --color-oshun: #d4af37;       /* Dorado */
  --color-yemaya: #0077be;      /* Azul */
  --color-obatala: #ffffff;     /* Blanco */
  --color-fondo: #f9f6f0;       /* Crema suave */
  --color-texto: #333333;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Open Sans', 'Lato', Arial, sans-serif;
  background-color: var(--color-fondo);
  color: var(--color-texto);
  line-height: 1.6;
}

h1, h2, h3 {
  font-family: 'Playfair Display', 'Libre Baskerville', Georgia, serif;
  margin-bottom: 1rem;
  color: var(--color-eleggua);
}

header {
  background-color: white;
  padding: 1rem;
  box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

main {
  max-width: 1000px;
  margin: 2rem auto;
  padding: 0 1.5rem;
}

footer {
  text-align: center;
  padding: 2rem 1rem;
  color: #666;
  font-size: 0.9rem;
  border-top: 1px solid #eee;
  margin-top: 3rem;
}

/* === Enlaces === */
a {
  color: var(--color-eleggua);
  text-decoration: none;
  transition: color 0.2s;
}

a:hover {
  text-decoration: underline;
}

footer a {
  color: var(--color-eleggua);
  font-weight: 600;
}

/* === Fotos de perfil === */
.profile-photo,
.member-photo,
.teacher-photo {
  width: 200px;
  height: 200px;
  border-radius: 8px;
  object-fit: cover;
  border: 3px solid var(--color-oshun);
  background: #eee;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 60px;
  color: var(--color-eleggua);
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.profile-photo img,
.member-photo img,
.teacher-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 8px;
  display: block;
}

/* === Información oculta === */
.hidden-info {
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px dashed #ccc;
  text-align: left;
}

.hidden-info p {
  margin: 0.4rem 0;
  font-size: 0.95rem;
  color: #444;
  line-height: 1.5;
}

/* === Audio === */
.audio-control {
  position: fixed;
  bottom: 20px;
  right: 20px;
  background: var(--color-eleggua);
  color: white;
  border: none;
  border-radius: 50%;
  width: 50px;
  height: 50px;
  cursor: pointer;
  box-shadow: 0 2px 8px rgba(0,0,0,0.3);
  font-size: 18px;
}

/* === Galería === */
.gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 1rem;
  margin-top: 1.5rem;
}

.gallery img {
  width: 100%;
  height: auto;
  border-radius: 8px;
  box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

/* === Banner === */
.banner-container {
  position: relative;
  width: 100%;
  height: 700px;
  overflow: hidden;
  border-radius: 12px;
  box-shadow: 0 4px 16px rgba(0,0,0,0.1);
  margin-bottom: 2rem;
  display: flex;
  align-items: center;
  justify-content: center;
}

@media (max-width: 1024px) and (min-width: 769px) {
  .banner-container { height: 450px; }
}
@media (max-width: 768px) {
  .banner-container { height: 320px; } /* ✅ Ajustado para evitar cortes en móvil */
}

#banner-slide img,
#banner-slide video {
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center top; /* ✅ Muestra cabeza y cuerpo completo */
  border-radius: 8px;
}

/* === Selector de idioma (estilo común para todas las páginas) === */
.language-selector-container {
  text-align: center;
  margin: 1rem 0;
}
.language-selector {
  display: inline-block;
  position: relative;
}
.language-selector button {
  background: white;
  border: 1px solid var(--color-eleggua);
  color: var(--color-eleggua);
  font-weight: bold;
  padding: 0.5rem 1rem;
  border-radius: 8px;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
#lang-menu {
  display: none;
  position: absolute;
  background: white;
  border: 1px solid #ccc;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
  z-index: 1000;
  min-width: 120px;
  top: 100%;
  left: 0;
  margin-top: 0.5rem;
}
#lang-menu a {
  padding: 0.75rem 1rem;
  display: block;
  text-decoration: none;
  font-weight: bold;
}
#lang-menu a[href$="/de/"] { color: #c00000; }
#lang-menu a[href$="/es/"] { color: #0077be; }
#lang-menu a[href$="/en/"] { color: #2e7d32; }
#lang-menu a[href$="/it/"] { color: #000000; }
#lang-menu a.active {
  background: #f9f6f0;
}

/* === Estilos para páginas "Sobre Nosotros" (texto justificado, ancho amplio) === */
.page-text {
  max-width: 900px;
  margin: 0 auto;
  padding: 0 1.5rem;
  text-align: left;
}
@media (min-width: 1024px) {
  .page-text {
    padding: 0 2.5rem;
  }
}
.page-text p,
.page-text ul,
.clausula {
  text-align: justify;
  text-justify: inter-word;
  line-height: 1.6;
  margin-bottom: 1rem;
}
.page-text ul {
  padding-left: 1.5rem;
}
.clausula {
  background: #fff8e1;
  padding: 1.2rem;
  border-left: 4px solid var(--color-oshun);
  margin: 1.5rem 0;
  font-style: italic;
}

/* === Tarjetas de CTA (página principal) — ✅ ACTUALIZADO === */
.cta-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1.2rem;
  margin: 2rem auto;
  max-width: 1000px;
  padding: 0 1rem;
}

.cta-card {
  background: white;
  padding: 1.5rem;
  border-radius: 12px;
  text-align: center;
  box-shadow: 0 4px 10px rgba(0,0,0,0.08);
  transition: transform 0.3s;
  border: 2px solid var(--color-oshun); /* ✅ Borde dorado */
  min-height: 200px; /* ✅ Altura fija para uniformidad */
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 0.75rem;
}

.cta-card h3 {
  margin: 0 0 0.5rem 0;
  font-size: 1.1rem;
  line-height: 1.2;
  color: var(--color-eleggua);
  font-weight: bold;
  text-align: center;
  word-break: break-word;
}

.cta-card p {
  margin: 0;
  font-size: 0.95rem;
  line-height: 1.4;
  color: #444;
  text-align: center;
  hyphens: auto;
  word-break: break-word;
}

.cta-card a {
  display: block;
  width: 100%; /* ✅ Botón de ancho completo */
  background: var(--color-eleggua);
  color: white;
  padding: 0.75rem 1rem;
  text-decoration: none;
  border-radius: 8px;
  font-weight: bold;
  transition: background 0.3s;
  font-size: 0.95rem;
  text-align: center;
  white-space: nowrap;
}

.cta-card:hover {
  transform: translateY(-5px);
}

.cta-card a:hover {
  background: #a00000;
}

/* === Fila final: Últimas Noticias + Contacto === */
.final-row {
  display: flex;
  justify-content: center;
  gap: 1.5rem;
  margin: 2rem auto;
  max-width: 1000px;
  padding: 0 1rem;
  flex-wrap: wrap;
}

@media (max-width: 600px) {
  .final-row .cta-card {
    width: 100%;
    max-width: 300px;
  }
}

/* === Tarjetas de maestros (galería de fotos) === */
.teacher-card {
  background: white;
  border-radius: 12px;
  padding: 1.5rem;
  width: 100%;
  max-width: 400px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
  transition: transform 0.3s;
  /* ✅ ALTURA UNIFORME EN TODOS LOS DISPOSITIVOS */
  min-height: 300px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  align-items: center;
  text-align: center;
}

.teacher-card:hover {
  transform: translateY(-4px);
}

.teacher-header {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  cursor: pointer;
  width: 100%;
}

.teacher-info h3 {
  margin: 0;
  color: var(--color-eleggua);
  font-size: 1.25rem;
  text-align: center;
}

/* === Ajuste para móviles: galería de fotos === */
@media (max-width: 768px) {
  .vice-teachers {
    flex-direction: column;
    align-items: center;
    gap: 2.5rem;
  }
  .teacher-card {
    max-width: 320px;
    min-height: 280px;
  }
}

/* === Botones de retroceso === */
.back-button {
  display: inline-block;
  background: var(--color-eleggua);
  color: white;
  padding: 0.75rem 1.5rem;
  border: none;
  border-radius: 8px;
  font-weight: bold;
  margin-top: 2rem;
  text-decoration: none;
  cursor: pointer;
}