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

html, body {
  height: 100%;
}

/* ===================== CONTAINERS ===================== */

.contenido {
  margin-top: 5px;
  padding: 20px;
}

.container {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}

/* ===================== PORTADAS ===================== */

.portada_servicio {
  background-image: url('../img/F7-página%20SS.jpg');
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  width: 900px;
  height: 450px;
  margin: 0 auto;
}

.Subportada_servicio {
  background-image: url('../img/F5-páginaSS.jpg');
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  width: 900px;
  height: 450px;
  margin: 0 auto;
}

/* ===================== TEXTOS ===================== */

.titulo_servicio {
  color: #003752;
  font-size: 40px;
  text-transform: uppercase;
  margin: 40px 0;
  text-align: center;
  font-weight: 200;
}

.subtitulo_servicio {
  font-size: 30px;
  text-align: center;
  margin-bottom: 20px;
  font-weight: 200;
  color: #003752;
}

.descripcion_servicio {
  text-align: justify;
  color: #858585;
  width: 900px;
  font-size: 16px;
  line-height: 1.8rem;
}

/* ===================== LISTAS ===================== */

.lista {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 10px 30px;
  list-style: none;
  text-align:left;
  margin-bottom: 30px;
}

.lista li {
  font-size: 1.1em;
  display: flex;
  align-items: center;
  color: #858585;
}

.lista li i {
  color: #2d9cdb;
  margin-right: 10px;
}

/* ===================== UNIVERSIDADES ===================== */

.contenedor_universidades {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 3rem;
  padding: 20px;
  justify-items: center;
}

.contenedor_universidades > div {
  display: flex;
  justify-content: center;
  width: 100%;
}

.logos_uni {
  width: 100%;
  max-width: 120px;
  height: auto;
  background-color: white;
  border-radius: 8px;
  transition: 0.3s ease;
}

.logos_uni:hover {
  transform: scale(1.05);
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
  cursor: pointer;
}

/* ===================== ICONOS ===================== */

.scroll-icon {
  font-size: 40px;
  cursor: pointer;
  display: block;
  margin: 50px auto;
  text-align: center;
  color: #e67700;
}

/* ===================== THUMBNAILS ===================== */

.container_premios {
  max-width: 950px;
  margin: auto;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  margin-bottom: 40px;
}

.thumb {
  flex: 1 1 calc(33.33% - 20px);
  max-width: calc(33.33% - 20px);
  aspect-ratio: 4 / 3;
  object-fit: cover;
  cursor: pointer;
  border: 2px solid transparent;
  border-radius: 4px;
  transition: 0.3s;
}

.thumb:hover {
  border-color: #007BFF;
}

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

.lightbox {
  position: fixed;
  inset: 0;
  display: none;
  justify-content: center;
  align-items: center;
  background-color: #333;
  z-index: 99999;
}

.lightbox.active {
  display: flex;
}

.lightbox img {
  max-width: 70%;
  max-height: 80vh;
}

.lightbox .close,
.lightbox .prev,
.lightbox .next {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  font-size: 2.5rem;
  color: white;
  background: none;
  border: none;
  cursor: pointer;
  user-select: none;
  transition: color 0.3s;
}

.lightbox .close {
  top: 20px;
  right: 20px;
  font-size: 2rem;
  transform: none;
}

.lightbox .prev {
  left: 5%;
}

.lightbox .next {
  right: 5%;
}

.lightbox .close:hover,
.lightbox .prev:hover,
.lightbox .next:hover {
  color: #ECB409;
}

/* ===================== RESPONSIVE ===================== */

@media (max-width: 991px) {
  .portada_servicio,
  .Subportada_servicio {
    width: 100%;
    height: auto;
    aspect-ratio: 2 / 1;
  }

  .descripcion_servicio {
    width: 100%;
    padding: 15px;
  }

  .contenedor_universidades {
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
  }

  .logos_uni {
    max-width: 90px;
  }

  .thumb {
    flex: 1 1 calc(50% - 10px);
    max-width: calc(50% - 10px);
  }
}

@media (max-width: 480px) {
  .thumb {
    flex: 1 1 calc(50% - 10px);
    max-width: calc(50% - 10px);
  }

  .lightbox .close,
  .lightbox .prev,
  .lightbox .next {
    font-size: 2rem;
  }
}

@media (max-width: 320px) {
  .thumb {
    flex: 1 1 100%;
    max-width: 100%;
  }

  .lightbox img {
    max-width: 100%;
    max-height: 70vh;
  }
}
@media (max-width: 991px) {
  .lightbox.active {
    display: flex !important;
  }
}