@charset "utf=8";

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

body {
  font-family: Arial, sans-serif;
  line-height: 1.6;
  background-color: #c6d2e7;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

header {
  background-color: #003865;
  color: white;
  padding: 2rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.nav-list {
  display: flex;
  list-style-type: none;
  gap: 1rem;
}

.nav-list li a {
  text-decoration: none;
  color: white;
}

header .nuestrologo img {
  max-width: 120px;
}

nav ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
}

nav ul li {
  margin-left: 15px;
}

nav ul li a {
  color: white;
  text-decoration: none;
  font-weight: bold;
}

nav ul li a:hover {
  text-decoration: underline;
}

.abrir-menu,
.cerrar-menu {
  display: none;
}

main {
  padding: 2rem;
  max-width: 1200px;
  margin: auto;
  flex: 1;
  display: flex;
  flex-direction: column;
  width: 100%;
}

footer {
  background: #93aedb;
  color: #000000;
  text-align: center;
  padding: 10px 0;
  margin-top: auto;
  width: 100%;
}

.quienes-somos {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: flex-start;
  gap: 2rem;
}

.contenido {
  flex: 1 1 600px;
  padding: 1rem;
}

.contenido h2 {
  margin-bottom: 1rem;
}

.contenido p {
  margin-bottom: 1rem;
}

.estadisticas {
  display: flex;
  justify-content: space-between;
  margin: 2rem 0;
}

.estadisticas div {
  text-align: center;
  font-size: 1.2rem;
}

button {
  background-color: #f36f21;
  color: #fff;
  padding: 0.5rem 1rem;
  border: none;
  cursor: pointer;
  font-size: 1rem;
}

.imagenes {
  flex: 1 1 400px;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.imagenes img {
  width: 100%;
  height: auto;
  border-radius: 0.5rem;
}

.contenedor {
  width: 90%;
  max-width: 1200px;
  margin: auto;
  padding: 20px 0;
}

.titulo {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 0;
}

.titulo h2 {
  margin: 0;
  color: #00003e;
}

.titulo select {
  padding: 5px;
  font-size: 16px;
  color: #00003e;
}

.eventos-list {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.evento {
  display: flex;
  flex-direction: row;
  background: #ededf0;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  padding: 10px;
}

.evento img {
  width: 200px;
  height: auto;
  object-fit: cover;
  border-radius: 10px;
}

.detalle {
  flex: 1;
  padding: 20px;
}

.detalle h3 {
  color: #00003e;
  margin: 0 0 10px 0;
  border-bottom: 1px solid #00003e;
  padding-bottom: 5px;
}

.detalle p {
  margin: 5px 0;
}

.ultimasnoticias {
  margin: 30px;
}

.ordenar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 0;
}

.ordenar h1 {
  margin: 0;
  color: #00003e;
}

.ordenar select {
  padding: 5px;
  font-size: 16px;
  color: #00003e;
}

.noticias {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}

.noticias article {
  background: #ededf0;
  border-radius: 5px;
  flex: 1 1 calc(33.333% - 1rem);
  display: flex;
  flex-direction: column;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  margin-bottom: 1rem;
}

.noticias img {
  width: 100%;
  height: auto;
  border-bottom: 1px solid #ddd;
  border-radius: 5px 5px 0 0;
}

.noticias h3 {
  margin: 1rem;
  color: #00003e;
  border-bottom: 1px solid #00003e;
}

.noticias p {
  flex: 1;
  margin: 0.5rem 1rem;
}

.button {
  display: inline-block;
  padding: 10px 20px;
  font-size: 16px;
  font-weight: bold;
  color: white;
  background-color: #002b80;
  text-align: center;
  text-decoration: none;
  border-radius: 5px;
  margin: 10px 10px 20px 15px;
}

.button:hover {
  background-color: #2f95f6;
}

@media (max-width: 768px) {
  header {
    flex-direction: column;
    text-align: center;
  }

  .nav-list {
    flex-direction: column;
    gap: 0.5rem;
  }

  .abrir-menu,
  .cerrar-menu {
    display: block;
    border: 0;
    font-size: 1.5rem;
    background-color: transparent;
    cursor: pointer;
    color: white;
  }

  .nav {
    display: flex;
    flex-direction: column;
    align-items: end;
    position: absolute;
    top: 0;
    gap: 1rem;
    right: 0;
    background-color: rgb(9, 9, 36);
    padding: 2rem;
    box-shadow: 0 0 0 100vmax rgba(0, 0, 0, 0.5);
    opacity: 0;
    visibility: hidden;
    bottom: 0;
    transition: opacity 0.3s ease, visibility 0.3s ease;
  }

  .nav.visible {
    display: flex;
    opacity: 1;
    visibility: visible;
  }

  .quienes-somos {
    flex-direction: column;
  }

  .estadisticas {
    flex-direction: column;
    gap: 1rem;
  }

  .estadisticas div {
    font-size: 1rem;
  }

  button {
    width: 100%;
    padding: 1rem;
  }

  footer {
    padding: 10px 5px;
  }

  .titulo {
    flex-direction: column;
    align-items: flex-start;
  }

  .evento {
    flex-direction: column;
  }

  .evento img {
    width: 100%;
  }

  .titulo {
    width: 100%;
  }
}

@media (max-width: 480px) {
  footer {
    padding: 10px 5px;
  }

  .ordenar {
    width: 100%;
  }

  .noticias article {
    flex: 1 1 100%;
  }

}