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

body {
  font-family: 'Segoe UI', sans-serif;
  background-color: #f8f9fa;
  color: #212529;
  line-height: 1.6;
  font-size: 18px; /* tamaño base cómodo para desktop */
}

/* Navegación */
.navbar {
  background-color: #1a237e;
  color: white;
  padding: 1rem 2rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
}

.navbar h1 {
  font-size: 1.2rem;
}

.navbar ul {
  list-style: none;
  display: flex;
  gap: 1rem;
}

.navbar a {
  color: white;
  text-decoration: none;
}

/* Foto de perfil */
.foto-perfil {
  display: flex;
  justify-content: center;
  margin-top: 1rem;
}

.foto-perfil img {
  width: 150px;
  height: 150px;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid #1a237e;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

/* Secciones */
.section {
  background: white;
  margin: 1.5rem 2rem;
  padding: 1.5rem;
  border-radius: 8px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
}

.section h2 {
  color: #1a237e;
  margin-bottom: 1rem;
}

.section ul {
  margin-left: 1.5rem;
}

/* Portafolio */
.portafolio-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1.5rem;
  margin-top: 1rem;
}

.proyecto {
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  overflow: hidden;
  transition: transform 0.3s ease;
}

.proyecto:hover {
  transform: translateY(-5px);
}

.proyecto img {
  width: 100%;
  height: 180px;
  object-fit: cover;
}

.proyecto h3 {
  margin: 0.5rem;
  font-size: 1.1rem;
  color: #1a237e;
}

.proyecto p {
  margin: 0 0.5rem 1rem;
  font-size: 0.9rem;
}

/* Footer */
footer {
  background-color: #1a237e;
  color: white;
  text-align: center;
  padding: 1rem;
  margin-top: 2rem;
}

/* Animaciones */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.fade-in {
  animation: fadeIn 1s ease-in-out forwards;
  opacity: 0;
}

/* Responsive */
@media (max-width: 768px) {
  body {
    font-size: 16px; /* tamaño cómodo para móvil */
  }

  .navbar {
    flex-direction: column;
    align-items: flex-start;
    padding: 1rem;
  }

  .navbar h1 {
    font-size: 1rem;
  }

  .navbar ul {
    flex-direction: column;
    gap: 0.5rem;
    margin-top: 0.5rem;
    width: 100%;
    justify-content: flex-start;
  }

  .navbar ul li {
    padding: 0.5rem 0;
  }

  .section {
    margin: 1rem;
    padding: 1rem;
  }

  .section h2 {
    font-size: 1.3rem;
  }

  .proyecto h3 {
    font-size: 1rem;
  }

  .proyecto img {
    height: 150px;
  }
}

.btn-descarga {
  display: inline-block;
  background-color: #1a237e;
  color: white;
  padding: 10px 20px;
  border-radius: 6px;
  text-decoration: none;
  transition: all 0.3s ease;
  font-weight: bold;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.2);
}

.btn-descarga:hover {
  background-color: #303f9f;
  transform: translateY(-2px);
  box-shadow: 0 8px 12px rgba(0, 0, 0, 0.3);
}
