*{
  margin: 0%;
  padding: 0%;
  box-sizing: border-box;
  font-family: "Open Sans", sans-serif;
}

body{
  background-color: #F9F5E2;
}

header{
  padding: 10px 50px;
  font-size: 1.2rem;
}

#banner{
  width: 100%;
}

#img-banner{
  width: 100%;
}

@media (max-width: 767.98px) {
  #img-banner{
    width: 100%;
    margin-top: 2rem;
  }
}

.lapagina {
    display: none;  /* Ocultar por defecto */
}

@media (max-width: 768px) {
    .lapagina {
        display: block;  /* Mostrar solo en pantallas pequeñas */
    }
}

#footer {
  width: 100%;
  text-align: left;
  background-color: #000000;
  padding-bottom: 20px;
  padding-top: 20px;
  font-size: 14px;
}

#footer a, #footer a:link {
  color: #FFF;
  text-decoration: none;
}

b.titulo-footer {
  font-size: 18px;
  color: #ffffff;
}

p.footer-inbal {
  color: #FFF;
  font-size: 12px;
}

#loading {
    display: none;
    text-align: center;
    padding: 20px;
}

#loading:before {
    content: '';
    border: 4px solid #f3f3f3;
    border-top: 4px solid #3498db;
    border-radius: 50%;
    width: 30px;
    height: 30px;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}



/*================== MAIN PAGINAS ===================*/
.main{
  width: 85%;
  margin: 20px auto;
}

.main-materiales{
  width: 80%;
  margin: 50px auto;
}

.main-actividades{
  width: 80%;
  margin: 30px auto;
}

.main-proyectos{
  width: 80%;
  margin: 30px auto 60px;
}

.main-proyecto-color{
  width: 80%;
  margin: 30px auto;
  gap: 30px;
  display: flex;
  flex-direction: column;
}

#Fin{
  margin-bottom: 50px;
}



/*===================== MENÚ DE NAVEHACIÓN ===========================*/
.navbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* Logo */
.logo {
  font-size: 22px;
  font-weight: bold;
  color: #F9F5E2;
  font-family: "Nunito", sans-serif;
}

/* Links del menú */
.nav-links {
  list-style: none;
  display: flex;
  gap: 30px;
}

.nav-links li a {
  text-decoration: none;
  color: #F9F5E2;
  font-family: "Nunito", sans-serif;
  font-weight: 400;
  transition: color 0.3s;
}

.nav-links li a:hover {
  color: #F4BA2F;
}

/* Botón hamburguesa */
.hamburger {
  display: none; /* por defecto oculto */
  font-size: 28px;
  background: none;
  border: none;
  color: white;
  cursor: pointer;
}

#select{
  font-weight: 800;
}




/*======================= INICIO ======================*/
#presentacion{
  margin-bottom: 30px;
  text-align: left;
}


#pdf{
  display: flex;
  align-items: center;
  flex-direction: column;
  gap: 25px;
  margin: 50px auto;
}

#convocatoria{
  background-color: #F4BA2F;
  color: #F9F5E2;
  font-family: "Nunito", sans-serif;
  font-weight: 800;
  font-size: 22px;
  padding: 15px 20px;
  margin: 0 50px;
  border-radius: 15px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  text-align: center;
  width: 220px;
}

#convocatoria button{
  background-color: #F9F5E2;
  color: #F4BA2F;
  border: none;
  font-family: "Nunito", sans-serif;
  font-weight: 800;
  font-size: 20px;
  text-align: center;
  width: 150px;
  margin: auto;
  border-radius: 15px;
}

#guia{
  background-color: #28BECD;
  color: #F9F5E2;
  font-family: "Nunito", sans-serif;
  font-weight: 800;
  font-size: 22px;
  padding: 15px 20px;
  margin: 0 50px;
  border-radius: 15px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  text-align: center;
  width: 220px;
}

#guia button{
  background-color: #F9F5E2;
  color: #28BECD;
  border: none;
  font-family: "Nunito", sans-serif;
  font-weight: 800;
  font-size: 20px;
  text-align: center;
  width: 150px;
  margin: auto;
  border-radius: 15px;
}



/*========================== CARRUSEL ==========================*/

.carousel-item img {
  width: 100%;
  height: 700px;
  object-fit: cover;
}

.carousel-caption {
  background-color: rgba(0, 0, 0, 0.5);
  color: white;
}

.carousel-control-prev .material-icons,
.carousel-control-next .material-icons {
    font-size: 65px;       /* tamaño del ícono */
    color: white;          /* color del ícono */
    text-shadow: 0 0 8px black; /* mejora visibilidad */
}

/* Opcional: aumentar el área clickeable */
.carousel-control-prev,
.carousel-control-next {
    width: 8%;    /* aumenta área a los costados */
}

.carousel-control-prev:hover .material-icons,
.carousel-control-next:hover .material-icons {
    color: #28BECD;   /* color al pasar el mouse */
}


#flecha-roja{
  color: #EE2A23;
}

#flecha-azul{
  color: #28BECD;
}

#flecha-amarillo{
  color: #F4BA2F;
}

/* Barra decorativa */
.indicator-rojo {
  width: 90%;
  max-width: 900px;
  height: 18px;
  background: #EE2A23;
  border-radius: 20px;
}

/* Barra decorativa */
.indicator-azul {
  width: 90%;
  max-width: 900px;
  height: 18px;
  background: #28BECD;
  border-radius: 20px;
}


/* Barra decorativa */
.indicator-amarillo {
  width: 90%;
  max-width: 900px;
  height: 18px;
  background: #F4BA2F;
  border-radius: 20px;
}



/*======================= EXTRAS =========================*/

a{
  text-decoration: none;
}




@media (max-width: 768px) {
  .hamburger {
    display: block; /* se muestra el botón */
  }

  .nav-links {
    position: absolute;
    top: 50px; /* debajo del header */
    left: 0;
    right: 0;
    background: #EE2A23;
    flex-direction: column;
    align-items: center;
    gap: 15px;
    padding: 10px 0;
    display: none; /* oculto por defecto */
    z-index: 9999;
  }

  .nav-links.active {
    display: flex; /* se muestra al dar click */
  }

  .actividades{
    grid-template-columns: repeat(1, 1fr);
    gap: 30px;
  }

  #title-rojo{
    font-size: 26px;
  }

  #title-azul{
    font-size: 26px;
  }

  #title-amarillo{
    font-size: 26px;
  }
}


@media only screen and (min-width: 1200px){

  h1{
    font-size: 50px;
  }

  p{
    font-size: 22px;
  }

  .main{
    width: 80%;
    margin: 30px auto;
  }

  .arrow{
    font-size: 80px;
  }

  .carousel-images{
    width: 70%;
  }

  .indicator{
    height: 30px;
  }

  #convocatoria, #guia{
    font-size: 35px;
    padding: 25px;
    height: 200px;
    display: flex;
    justify-content: center;
    align-items: center;
  }

  #pdf{
    flex-direction: row;
    margin: 100px 50px;
  }


  #presentacion{
    margin: 60px auto 90px auto;
  }

  #pdf-materiales{
    display: flex;
    flex-direction: row;
    gap: 10px;
  }

  .escuela{
    display: flex;
    flex-direction: row;
    gap: 30px;
    margin-bottom: 50px;
  }

  #alumnos{
    margin: 0%;
  }

  .main-actividades{
    margin: 80px auto 100px;
  }

  .main-proyectos{
    margin: 80px auto 100px;
  }

  /*PROYECTO ROJO*/
  .contenedor-rojo{
    flex-direction: row;
    gap: 15px;
    border: 15px solid #EE2A23;
  }

  .contenedor-azul{
    flex-direction: row;
    gap: 15px;
    border: 15px solid #28BECD;
  }

  .contenedor-amarillo{
    flex-direction: row;
    gap: 15px;
    border: 15px solid #F4BA2F;
  }

  .contenedor-generico{
    flex-direction: row;
    gap: 15px;
  }

  #info-titulo-rojo{
    font-size: 50px;
  }

  #info-titulo-azul{
    font-size: 50px;
  }

  #info-titulo-amarillo{
    font-size: 50px;
  }

  h4{
    font-size: 25px;
  }

  .info{
    padding: 20px 30px;
  }

  h5{
    font-size: 25px;
    padding: 12px 25px;
  }

  .modalidad-rojo{
    background-color: #EE2A23;
    width: 70%;
    margin-left: auto;
    margin-top: 50px;
    margin-bottom: 50px;
  }

  .modalidad-azul{
    background-color: #28BECD;
    width: 70%;
    margin-left: auto;
    margin-top: 50px;
    margin-bottom: 50px;
  }

  .modalidad-amarillo{
    background-color: #F4BA2F;
    width: 70%;
    margin-left: auto;
    margin-top: 50px;
    margin-bottom: 50px;
  }


  h6{
    font-size: 50px;
  }

  .raya-roja {
    height: 25px;
    margin-bottom: 30px;
  }

  .raya-azul {
    height: 25px;
    margin-bottom: 30px;
  }

  .raya-amarillo {
    height: 25px;
    margin-bottom: 30px;
  }

  .indicator-rojo {
    height: 30px;
  }

  .indicator-azul {
    height: 30px;
  }

  .indicator-amarillo {
    height: 30px;
  }

  #Fin{
    margin-bottom: 100px;
  }

}

/* Contenedor de los boxes, aseguramos que se distribuyan bien */
.misbotones {
  font-family: 'Nunito', sans-serif;
  display: flex;
  justify-content: center;  /* Centra horizontalmente */
  align-items: center;  /* Centra verticalmente */
  flex-wrap: wrap;
  gap: 25px;
}

/* Estilo para cada box */
.box {
  color: #000;
  font-weight: 800;
  text-align: center;
  padding: 20px;
  width: 100%;
  max-width: 300px; /* Ajuste máximo para el tamaño de los contenedores */
  height: 175px; /* Establece una altura fija */
  border-radius: 10px;
  transition: background-color 0.3s ease;
  border: black;
  background-color: #FFF;
  display: flex;  /* Cambiado a flex para permitir alineación vertical */
  flex-direction: column; /* Asegura que los elementos (texto y botón) se apilen */
  justify-content: space-between;  /* Asegura que el texto y el botón se distribuyan con espacio entre ellos */
  border-style: solid;
  border-color: #e62b2a;
}

/* Estilo para el botón */
.elboton {
  background-color: #F4BA2F;
  color: #FFF;
  border: none;
  font-family: "Nunito", sans-serif;
  font-weight: 800;
  font-size: 20px;
  text-align: center;
  width: 150px;
  margin: 10px auto 0 auto; /* Espaciado y centrado */
  border-radius: 15px;
  display: block;
}

/* Responsividad */
@media (min-width: 768px) {
  .box {
    width: 45%;
  }
}

@media (min-width: 1024px) {
  .box {
    width: 18%;
  }
}

.filter {
  padding: 20px;
  background-color: #f8f9fa;
  border-radius: 8px;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
  margin: auto;
}

.filter label {
  font-weight: bold;
  margin-bottom: 8px;
  display: block;
}

.filter select {
  width: 100%;
  padding: 10px;
  font-size: 1rem;
  border-radius: 5px;
  border: 1px solid #ced4da;
  background-color: #ffffff;
  transition: border-color 0.3s ease;
}

.filter select:focus {
  border-color: #0056b3;
  box-shadow: 0 0 5px rgba(0, 86, 179, 0.5);
}

.filter .form-group {
  margin-bottom: 15px;
}

/* Hacemos que el layout se ajuste */
@media (min-width: 768px) {
  .filter .form-group {
    display: inline-block;
    width: 48%; /* Cada select ocupa el 48% del contenedor */
    margin-right: 4%; /* Espacio entre los dos selectores */
  }

  .filter .form-group:last-child {
    margin-right: 0; /* El último selector no tiene margen derecho */
  }
}

/* Estado de loading mejorado */
.loading {
    display: none;
    text-align: center;
    padding: 20px;
    color: #666;
}

.loading::after {
    content: '';
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 2px solid #f3f3f3;
    border-top: 2px solid #007bff;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-left: 10px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Mensaje de no resultados */
.no-results {
    text-align: center;
    padding: 40px;
    color: #666;
    font-style: italic;
}

/* Styling the container to arrange the thebuttons */
.thebutton-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-around;
    gap: 30px;
    padding: 30px;
}

/* Styling each thebutton */
.thebutton {
    width: 150px;
    text-align: center;
    position: relative;
    cursor: pointer;
    transition: transform 0.3s, box-shadow 0.3s ease-in-out;
}

/* Image inside each thebutton */
.thebutton img {
    width: 100%;
    height: auto;
    border-radius: 8px;
    transition: opacity 0.3s ease;
}

/* Description text under the image */
.thebutton p {
    margin-top: 10px;
    font-size: 14px;
    color: #333;
    font-weight: bold;
    transition: color 0.3s;
}

/* Effect when hovering over the thebutton */
.thebutton:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

/* Optional: Fade effect for images */
.thebutton:hover img {
    opacity: 0.9;
}

/* Responsiveness: Adjust thebuttons on smaller screens */
@media (max-width: 768px) {
    .thebutton-container {
        flex-direction: column;
        align-items: right;
    }

    .thebutton {
        width: 80%;
        max-width: 300px;
    }
}

.funcion-card,
.proyecto-card,
.teatro-card {
    height: 100%;
    overflow: hidden;
    background: var(--color-blanco);
    border: 1px solid var(--color-borde);
    border-radius: var(--radio);
    transition:
        transform 0.25s ease,
        box-shadow 0.25s ease;
}

.funcion-card:hover,
.proyecto-card:hover,
.teatro-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--sombra);
}

.funcion-card-imagen,
.proyecto-card-imagen,
.teatro-card-imagen {
    position: relative;
    overflow: hidden;
    background: #ddd;
}

.funcion-card-imagen,
.proyecto-card-imagen {
    aspect-ratio: 4 / 3;
}

.teatro-card-imagen {
    aspect-ratio: 4 / 3;
}

.funcion-card-imagen img,
.proyecto-card-imagen img,
.teatro-card-imagen img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.funcion-card:hover img,
.proyecto-card:hover img,
.teatro-card:hover img {
    transform: scale(1.035);
}

.funcion-card-contenido,
.proyecto-card-contenido,
.teatro-card-contenido {
    padding: 1.5rem;
}

.funcion-card h3,
.proyecto-card h3,
.teatro-card h3 {
    margin-bottom: 0.65rem;
    font-size: 1.3rem;
    line-height: 1.25;
}

.funcion-card h3 a,
.proyecto-card h3 a,
.teatro-card h3 a {
    color: var(--color-texto);
    text-decoration: none;
}

.funcion-card-fecha {
    margin-bottom: 0.55rem;
    color: var(--color-principal);
    font-weight: 700;
}

.funcion-card-compania,
.proyecto-card-contenido p,
.teatro-card-contenido p {
    color: var(--color-texto-suave);
}

.funcion-card-recinto {
    display: flex;
    gap: 0.75rem;
    margin: 1.25rem 0;
}

.funcion-card-recinto .material-symbols-outlined {
    color: var(--color-principal);
}

.funcion-card-recinto span:not(.material-symbols-outlined) {
    display: block;
    color: var(--color-texto-suave);
    font-size: 0.9rem;
}
