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

a{
  text-decoration: none;
}

body{
  font-family: Helvetica;
  background-color: rgb(255, 255, 255);
  min-height: 100vh;
  margin: 0 auto;
  display: grid;
  grid-template: 
  
    "header" 
    "hero" 500px
    "card-eventos"
    "miscelanea"
    "semana"
    "footer"  
}


  header{
    grid-area: header;
  }
  .hero{
    grid-area: hero;
    background-image: url('../images/hero_eventos.webp');
    background-size: cover;      /* Ajusta la imagen para cubrir todo el fondo */
  background-repeat: no-repeat; /* Evita que la imagen se repita */
  background-position: center;  
  }
  
  .card-eventos{
    grid-area: card-eventos;
    max-width: 1500px;
    margin: 0 auto;
    font-family: Helvetica;
       font-size: 25px;
     padding: 0 1.5rem; /* aire lateral */
     margin-bottom: 1.5rem;
  }

  .miscelanea{
    max-width: 1500px;
    grid-area: miscelanea;
    font-family: Helvetica;
   font-size: 25px;
     padding: 0 1.5rem; /* aire lateral */
     margin-bottom: 1.5rem;
  }

  .semana {
  grid-area: semana;
  max-width: 1500px;
  width: 100%;
  margin: 50px auto;
  font-family: Helvetica;
  font-size: 25px;
    padding: 0 1.5rem; /* aire lateral */
}
  
  footer{
    grid-area: footer;
  }

.card-eventos p{
    font-size: 40px;
    padding: 10px;
    font-weight: bold;
    max-width: 1500px;
}

.all-cards {
  display: grid;
  grid-template-columns: 1fr 1fr;;
  gap: 50px;
  max-width: 1500px;
  width: 100%;
  margin: 0 auto;
  margin-bottom: 50px;
}

.card{
  
    display: flex;
    flex-direction: column;

    width: auto;
     margin: 0 auto;
     gap: 20px;

}

.card img{
    width: 100%;
    height: auto;
    border-radius: 15px;
}

.title {
  width: 100%;
  height: 70px;
  font-size: 30px;
  font-weight: bold;
  border-radius: 15px;
  padding: 5px;
  color: #FBCF2E;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
}


.mesas .title, .nombramiento .title, .semana .title{
    background-color: #0072CE;
}

.conferencias .title, .conversatorios .title, .miscelanea .title{
    background-color: #57A519;

}

.text{
    font-size: 1.2rem;
    text-align: justify;
    margin-bottom: 3rem;
}




/* --------Miscelanea-------- */

.miscelanea{
    display: flex;
    flex-direction: column;
    max-width: 1500px;
    margin: 0 auto;
    gap: 15px;
    margin-bottom: 50px;
}

.img-misce img{
    width: 100%;
    height: auto;
    border-radius: 15px;
}

/* ------Semana------ */

.semana{
    display: flex;
    flex-direction: column;
    max-width: 1500px;
    margin: 0 auto;
    gap: 15px;
    margin-bottom: 50px;
}

.img-semana img{
    width: 100%;
    height: auto;
    border-radius: 15px;
}


/* -------------Responsivo------------ */
/* ===== Tablets (≤ 992px) ===== */
@media (max-width: 992px) {
  /* Ajusta el alto del hero y mantiene el grid en una columna */
  body {
    grid-template:
      "header"
      "hero" 360px
      "card-eventos"
      "miscelanea"
      "semana"
      "footer";
  }

  /* Quitar anchos fijos y dar respiración lateral */
  body .card-eventos,
  body .miscelanea,
  body .semana {
    width: 100%;
    max-width: 100%;
    margin: 0 auto;
    padding: 0 20px;
    font-size: 22px; /* bajar un poco tipografía */
  }

  /* Título grande dentro de card-eventos */
  .card-eventos p {
    font-size: 28px;
    text-align: center;
    max-width: 100%;
  }

  /* Tarjetas en una columna y alturas fluidas */
  .all-cards {
    grid-template-columns: 1fr;
    gap: 30px;
    max-width: 100%;
    padding: 0 0 10px;
  }

  .card {
    height: auto;
  }

  .card img {
    height: 240px;          /* menos alta en tablet */
    object-fit: cover;
  }

  .title {
    min-height: 56px;
    font-size: 24px;
    padding: 8px 12px;
  }

  .text {
    font-size: 20px;
  }
}

.btn-nuevo-evento {
    display: inline-block; /* o block si quieres que ocupe toda la fila */
    width: 30%; /* ahora sí funciona */
    margin: 20px 0 20px 35%; /* centrado horizontal con margen inferior */
    padding: 12px 20px;
    background-color: #007bff;
    color: white;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 600;
    transition: background 0.3s ease, transform 0.2s ease;
    text-align: center;
}

.btn-nuevo-evento:hover {
    background-color: #0056b3;
    transform: translateY(-2px);
}

/* ===== Móviles (≤ 600px) ===== */
@media (max-width: 600px) {
  /* Hero más corto para no comerse la pantalla */
  body {
    grid-template:
      "header"
      "hero" 120px
      "card-eventos"
      "miscelanea"
      "semana"
      "footer";
  }

  body .card-eventos,
  body .miscelanea,
  body .semana {
    padding: 0 12px;
    font-size: 18px;
  }

  .card-eventos p {
    font-size: 22px;
    padding: 8px 0;
  }

  .all-cards {
    gap: 20px;
  }

  .card {
    gap: 12px;
  }

  .card img {
    height: 200px;         /* aún más compacta en móvil */
    border-radius: 12px;
  }

  .title {
    min-height: 48px;
    font-size: 18px;
    border-radius: 12px;
    padding: 8px;
  }

  .text {
    font-size: 16px;
  }

  .img-misce img,
  .img-semana img {
    border-radius: 12px;
  }
}
