/* Estilos mínimos optimizados para móviles con mejoras visuales */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;600&display=swap');

* {
  box-sizing: border-box;
}

body {
  font-family: 'Inter', system-ui, sans-serif;
  background: #f0f0f0;
  color: #333;
  font-size: 16px;
  line-height: 1.5;
  margin: 0;
  padding: 0;
}

h2 {
  font-size: 1.2rem;
  font-weight: 400;
  /*margin: 0.2rem 0 0.4rem 0;
  color: #004080;*/
  text-align: center;
}

h3 {
  font-size: 1rem;
  font-weight: 400;
  /*margin: 0.2rem 0 0.4rem 0;
  color: #004080;*/
  text-align: center;
  line-height: 1.2;
}

.header {
  background: #004080;
  color: white;
  text-align: center;
  padding: 2rem 1rem 1.5rem;
}

.header-content h1 {
  font-size: 1.6rem;
  margin-bottom: 0.5rem;
  font-weight: 600;
}

.header-content p {
  font-size: 1rem;
  font-weight: 400;
  opacity: 0.95;
  margin: 0;
}

.container {
  padding: 1.5rem 1rem;
}

.card-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2.5rem;
}

/*
@media (min-width: 640px) and (orientation: landscape) {
  .card-grid {
    grid-template-columns: 1fr 1fr;
  }
}
*/

@media (min-width: 640px) and (orientation: landscape) {
  .card-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    /* Esta línea centra los elementos si hay uno solo */
    gap: 2.5rem;
  }

  .project-card {
    flex: 0 0 calc(50% - 1.25rem);
    /* dos tarjetas por fila */
    max-width: 100%;
  }

  /* Si hay solo UNA tarjeta */
  .card-grid:has(.project-card:nth-child(1):last-child) .project-card {
    flex: 0 0 80%;
    /* ocupa el 70% del ancho de la fila */
  }
}


.project-card {
  background: white;
  border-radius: 8px;
  padding: 1.25rem;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.08);
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}




.project-card img {
  width: 100%;
  height: auto;
  border-radius: 6px;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.1);
}

.project-card h2 {
  font-size: 1.4rem;
  font-weight: 600;
  margin: 0.2rem 0 0.4rem 0;
  color: #004080;
  text-align: center;
}

.project-card p {
  margin: 0.2rem 0 0.8rem 0;
  line-height: 1.35;
}

.btn {
  display: block;
  width: 100%;
  padding: 0.75rem 1.5rem;
  margin: 0 auto;
  text-align: center;
  background: #004080;
  color: white;
  border-radius: 6px;
  font-weight: bold;
  font-size: 1rem;
  text-decoration: none;
}

@media (hover: hover) {
  .btn:hover {
    background: #002d5e;
  }
}

.mobile-only.aviso {
  display: none;
  font-size: 0.8rem;
  line-height: 1.2;
  color: #004080;
  background-color: #eaf1fb;
  padding: 0.4rem 0.6rem;
  border-radius: 6px;
  margin-top: 0.6rem;
  margin-bottom: 0.4rem;
  text-align: center;
}

.footer {
  text-align: center;
  padding: 1rem 1rem;
  background: #eee;
  font-size: 0.9rem;
  color: #333;
  line-height: 1.4;
  margin-top: 2rem;
  border-top: 1px solid #ccc;
}

.footer a {
  color: #004080;
  text-decoration: none;
}

.footer .section {
  margin-bottom: 1rem;
}

.footer .section strong {
  display: block;
  margin-bottom: 0.3rem;
  color: #004080;
}

.footer-logo {
  width: 120px;
  height: auto;
  margin-bottom: 0rem;
}

.footer-logo2 {
  width: 80px;
  height: auto;
}


.footer .copyright {
  font-size: 0.75rem;
  color: #666;
  text-align: center;
  margin-top: 2rem;
  border-top: 1px solid #ccc;
  padding-top: 0.8rem;
}


.footer .legal-links {
  font-size: 0.75rem;
  color: #666;
  text-align: center;
  margin-top: 0.3rem;
}




.footer .legal-links a {
  color: #666;
  text-decoration: underline;
  margin: 0 0.4rem;
}

.interleaved-fullwidth {
  width: 100%;
  /*margin: 2rem 0;*/
  margin: 0rem 0;
}

.interleaved-fullwidth img {
  width: 100%;
  max-width: 100vw;
  height: auto;
  display: block;
  border-radius: 0;
  margin: 0;
}

.desktop-only {
  display: none !important;
}

@media (max-width: 800px) {
  .mobile-only {
    display: block !important;
  }
}

@media (min-width: 801px) {
  .desktop-only {
    display: block !important;
  }
}