body {
    font-family: Arial, sans-serif;
    margin: 0;
    padding: 0;
    padding-top: 60px;
    transition: all 0.3s ease;
}

/* ✅ Pantalla grande (ordenador) */
body.pantalla-grande {
  font-size: 18px;
  zoom: 1;
}

/* ✅ Pantalla mediana (tablets) */
body.pantalla-mediana {
  font-size: 16px;
  zoom: 0.95;
}

/* ✅ Pantalla pequeña (móviles) */
body.pantalla-pequeña {
  font-size: 14px;
  zoom: 0.9;
  padding: 10px;
}

header {
    background-color: white;
    color: black;
    text-align: center;
    padding: 20px;
}

.escudo-nombre {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 10px;
}

.escudo-nombre2 {
    display: inline-block;
    justify-content: space-between;
    align-items: center;
    padding: 10px;
    margin-top: 20px;
}

.escudo {
    width: 650px;
    height: auto;
    transition: transform 0.3s ease-in-out;
}

.escudo2 {
    width: 400px;
    height: auto;
    transition: transform 0.3s ease-in-out;
}

.enlaces {
    width: 70px;
    height: auto;
    transition: transform 0.3s ease-in-out;
}

.enlaces2 {
    width: 95px;
    height: auto;
    transition: transform 0.3s ease-in-out;
}

.nombre-hermandad {
    font-size: 24px;
    font-weight: bold;
    margin: 0;
}

.nombre-hermandad a {
    text-decoration: none;
    color: black;
    transition: color 0.3s ease-in-out;
}

.nombre-hermandad a:hover {
    color: #ADD8E6;
}

/* ==== NAVBAR ==== */
nav { 
    display: flex;
    justify-content: space-around;
    background-color: rgba(110, 195, 226, 0.85); /* azul con transparencia */
    backdrop-filter: blur(6px); /* efecto cristal */
    padding: 10px 0;
    align-items: center;
    position: sticky;
    top: 0;
    z-index: 1000;
    transition: background-color 0.4s ease, backdrop-filter 0.4s ease;
}

nav2 { 
    display: flex;
    justify-content: space-around;
    background-color: white; 
    backdrop-filter: blur(6px); /* efecto cristal */
    padding: 10px 0;
    align-items: center;
    position: sticky;
    top: 0;
    z-index: 1000;
    transition: background-color 0.4s ease, backdrop-filter 0.4s ease;
}

nav2 a { 
    color: rgba(110, 195, 226, 0.85);
    text-decoration: none;
    padding: 10px 20px;
    font-weight: bold;
    background-color: transparent;
    transition: background-color 0.3s, color 0.3s, opacity 0.3s;
}

/* Cuando el usuario hace scroll */
nav.sticky {
    background-color: rgba(110, 195, 226, 0.85);
    backdrop-filter: blur(10px);
}

/* Enlaces del menú */
nav a { 
    color: white;
    text-decoration: none;
    padding: 10px 20px;
    font-weight: bold;
    background-color: transparent;
    transition: background-color 0.3s, color 0.3s, opacity 0.3s;
}

/* Enlaces cuando el nav está anclado (más translúcidos) */
nav.sticky a {
    opacity: 0.9;
}

/* Hover normal */
nav a:hover {
    background-color: white;
    color: #6ec3e2;
    border-radius: 7px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
}

.dropdown {
    position: relative;
    display: inline-block;
}

.dropdown-content {
    display: none;
    position: absolute;
    background-color: #ADD8E6;
    min-width: 200px;
    box-shadow: 0px 8px 16px rgba(0, 0, 0, 0.2);
    z-index: 1;
}

.dropdown-content a {
    color: white;
    padding: 10px 15px;
    display: block;
    text-align: left;
}

.dropdown-content a:hover {
    background-color: white;
    color: #ADD8E6;
}

.dropdown:hover .dropdown-content {
    display: block;
}

section{
    padding: 20px;
}

.carrusel{
    position: relative;
    width: 100%;
    max-width: 1500px;
    height: 600px; 
    margin: 0, auto;
    overflow: hidden;
    border-radius: 10px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
}

.carrusel-img{
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0;
    transition: opacity 1s ease-in-out;
}

.carrusel-img.activo{
    opacity: 1;
}

.titulo-seccion {
    background-color: #ADD8E6;
    color: white;
    text-align: center;
    padding: 20px 0;
    font-size: 24px;
    font-weight: bold;
    width: 100%;
    height: 190px;
    display: flex;
    justify-content: center;
    align-items: center;
    margin-top: 20px;
    border-bottom: 5px solid white;
}

.seccion-imagen {
    text-align: center;
    padding: 20px 0;
}

.imagen-seccion {
    width: 100%;
    max-width: 700px;
    height: 100%;
    display: block;
    margin: 0 auto 10px;
    border-radius: 10px;
}

.imagen-seccion2 {
    width: 100%;
    max-width: 400px;
    height: 100%;
    display: block;
    margin: 0 auto 10px;
    border-radius: 10px;
}

.congreso {
    border-bottom: 3px solid #ADD8E6; 
    width: 100%;
}

.eventos-cuenta{
    display: flex;
    justify-content: space-between;
    padding: 20px;
    gap: 20px;
}

.noticias-lista {
    /*display: flex;*/
    background-color: #f4f4f4;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    margin: 0 20px; 
}

.noticias-lista h2 {
    font-size: 24px;
    margin-bottom: 20px;
    color: #333;
    text-align: center;
    width: 100%;
}

.noticias-contenedor {
    flex-direction: column; 
    align-items: center;    
    gap: 25px;           
    width: 100%;      
}

.noticia {
    background-color: #ADD8E6;
    color: white;
    padding: 15px;
    border-radius: 10px;
    width: 80%;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    text-align: left;
    transition: transform 0.2s ease;
    margin-bottom: 20px;
}

.noticia h3 {
    font-size: 18px;
    margin-bottom: 10px;
    color: white;
}

.noticia p {
    font-size: 14px;
    margin-bottom: 5px;
}

.eventos, .contador-container {
    width: 48%;
    background-color: #f4f4f4;
    padding: 15px;
    border-radius: 8px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

.eventos {
    text-align: center;
    width: 80%;
}

.eventos h2 {
    font-size: 24px;
    margin-bottom: 20px;
    color: #333;
}

.eventos-lista {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
    justify-items: center;
}

.evento {
    background: #ADD8E6;
    padding: 15px;
    border-radius: 10px;
    width: 280px;
    box-shadow: 0px 4px 6px rgba(0, 0, 0, 0.1);
    text-align: center;
}

.evento h3 {
    margin-bottom: 10px;
    font-size: 18px;
    color: white;
}

.evento p {
    color: white;
    font-size: 14px;
}

@media (max-width: 768px) {
    .eventos-lista {
        grid-template-columns: 1fr;
    }
}

.contador-container {
    text-align: center;
    margin: 20px auto;
    padding: 20px;
    border-radius: 10px;
    width: 80%;
    max-width: 600px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
}

.cronometro {
    display: flex;
    justify-content: center;
    gap: 20px;
    font-size: 24px;
}

.tiempo {
    display: flex;
    flex-direction: column;
    align-items: center;
    background: #ADD8E6;
    color: white;
    padding: 8px 16px; 
    border-radius: 6px; 
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2); 
    font-size: 0.9em; 
}

.tiempo span {
    font-size: 36px;
    font-weight: bold;
}

.tiempo p {
    margin: 0;
    font-size: 14px;
}

.texto-container {
    width: 92%;  
    max-width: 12000px; 
    margin: 30px auto; 
    padding: 30px;
    background: #f8f9fa;
    border-left: 8px solid #ADD8E6; 
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.2); 
    border-radius: 10px; 
    font-size: 18px; 
    line-height: 1.8; 
}

.texto-container h2 {
    color: #ADD8E6;
    text-align: center;
}

.texto-container p {
    font-size: 18px;
    line-height: 1.6;
    color: #333;
    text-align: justify;
    font-family: 'Times New Roman', Times, serif;
}

.texto {
    width: 80%;
    margin: auto;
    text-align: center;
    font-size: 18px;
    line-height: 1.6;
}

.texto h2 {
    font-size: 26px;
    margin-bottom: 15px;
}

.imagen-pequena {
    width: 160px;
    height: auto;
    display: block;
    margin: 20px auto 10px;
    border-radius: 8px;
}

.galeria {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    justify-content: center;
    padding: 20px;
}

.galeria img {
    width: 100%;
    height: 480px;
    object-fit: cover;
    border-radius: 10px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
    transition: transform 0.3s ease;
}

.galeria img:hover {
    transform: scale(1.05);
}

footer{
    background-color: #6ec3e2;
    color: white;
    text-align: center;
    padding: 10px;
}

.footer-contenido{
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 20px;
    max-width: 900px;
    margin: 0 auto;
    text-align: left;
}

.red-social {
    display: inline-block;
    margin: 5px;
}

.icono-red-social {
    width: 40px;
    height: auto;
    transition: transform 0.3s ease;
}

.icono-red-social:hover {
    transform: scale(1.1);
}

.video-container {
  position: relative;
  width: 80%;
  max-width: 600px;
  margin: 20px auto;
  aspect-ratio: 16 / 9; /* Mantiene la proporción del video */
  overflow: hidden;
  border-radius: 10px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
}

.video-container iframe,
.video-container video {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border: none;
  object-fit: cover;
}

.datos-contacto{
    width: 50%;
    justify-content: space-between;
}

.datos-contacto i {
    margin-right: 8px;
    font-size: 16px;
    color: #ADD8E6;
}

.datos-contacto a {
    text-decoration: none;
    color: white;
    font-weight: bold;
}

.copyright {
    text-align: center;
    font-size: 16px;
    margin-top: 20px;
}

.mapa-pequeno{
    width: 50%;
}

h1, h2, h3, a {
    font-family: 'Trebuchet MS', 'Lucida Sans Unicode', 'Lucida Grande', 'Lucida Sans', Arial, sans-serif;
}

.titulo-principal {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-top: 20px;
}

.titulo-principal .logo {
  width: 60px;
  height: 60px;
}

/* === AJUSTE AUTOMÁTICO A CUALQUIER PANTALLA === */

/* Para pantallas muy grandes (monitores grandes o TV) */
@media (min-width: 1600px) {
  body {
    font-size: 20px;
    zoom: 1.05;
  }

  .escudo {
    width: 800px;
  }

  .escudo2 {
    width: 500px;
  }

  .enlaces {
    width: 90px;
  }

  .enlaces2 {
    width: 120px;
  }

  /* 🖥️ Carrusel en pantallas grandes */
  .carrusel {
    height: 70vh;
    border-radius: 10px;
  }
}

/* Para tablets horizontales o portátiles pequeños */
@media (max-width: 1024px) {
  .escudo {
    width: 500px;
  }

  .escudo2 {
    width: 300px;
  }

  .eventos-cuenta {
    flex-direction: column;
    align-items: center;
  }

  .eventos, .contador-container {
    width: 90%;
  }

  .titulo-seccion {
    font-size: 20px;
    height: auto;
    padding: 15px;
  }

  /* 📱 Carrusel para tablets */
  .carrusel {
    height: 50vh;
    border-radius: 8px;
  }
}

/* Para móviles grandes */
@media (max-width: 768px) {
  body {
    font-size: 16px;
    zoom: 0.95;
    padding: 10px;
  }

  nav {
    flex-direction: column;
  }

  nav a {
    padding: 8px 15px;
    font-size: 16px;
  }

  .escudo {
    width: 300px;
  }

  .escudo2 {
    width: 220px;
  }

  .eventos-lista {
    grid-template-columns: 1fr;
  }

  .texto-container {
    padding: 15px;
    font-size: 16px;
  }

  .cronometro {
    flex-direction: column;
    gap: 10px;
  }

  /* 📱 Carrusel para móviles grandes */
  .carrusel {
    height: 40vh;
    border-radius: 6px;
  }
}

/* Para móviles pequeños */
@media (max-width: 480px) {
  body {
    font-size: 14px;
    zoom: 0.9;
  }

  header {
    padding: 10px;
  }

  .nombre-hermandad {
    font-size: 18px;
  }

  .titulo-principal .logo {
    width: 45px;
    height: 45px;
  }

  .escudo {
    width: 250px;
  }

  .imagen-seccion,
  .imagen-seccion2 {
    max-width: 100%;
  }

  .texto-container {
    font-size: 15px;
  }

  .footer-contenido {
    flex-direction: column;
    align-items: center;
  }

  .datos-contacto {
    width: 90%;
  }

  .mapa-pequeno {
    width: 90%;
  }

  /* 📱 Carrusel para móviles pequeños */
  .carrusel {
    height: 35vh;
    border-radius: 5px;
  }
}
