/* Reset general */
html, body {
  margin: 0;
  padding: 0;
  height: 100%;
}

/* Tipografía y colores */
body {
  font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
  color: #333;
  background-color: #FFFFFF;
  overflow-x: hidden;
  scroll-behavior: smooth;
}

.wrapper {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

.content {
  padding-top: 120px;
  max-width: 900px;
  margin: auto;
  animation: slideIn 1.2s ease;
  flex: 1;
}

@keyframes slideIn {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

/* NAVBAR */
nav {
  background-color: #FFC7C7;
  padding: 15px 30px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  position: fixed;
  width: 100%;
  top: 0;
  z-index: 1000;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
}

nav a, .dropbtn {
  margin: 0 20px;
  color: #333;
  text-decoration: none;
  transition: color 0.3s;
  font-weight: bold;
  cursor: pointer;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

nav a:hover, .dropbtn:hover {
  color: #FF6F61;
}

/* Menú desplegable */
.dropdown {
  position: relative;
  display: inline-block;
}

.dropbtn {
  font-weight: bold;
  color: #333;
  padding: 0 20px;
  cursor: pointer;
  display: inline-block;
  transition: color 0.3s;
  text-decoration: none;
}

.dropdown-content {
  display: none;
  position: absolute;
  background-color: #fff;
  min-width: 180px;
  box-shadow: 0 4px 8px rgba(0,0,0,0.1);
  z-index: 2000; /* Asegura que esté por encima de todo */
  border-radius: 5px;
  margin-top: 15px;
}

.dropdown-content a {
  color: #333;
  padding: 10px 15px;
  text-decoration: none;
  display: block;
  font-weight: normal;
}

.dropdown-content a:hover {
  background-color: #f1f1f1;
  color: #FF6F61;
}

/* Mostrar el menú cuando se hace clic */
.show {
  display: block;
}



/* Footer */
footer {
  background-color: #C8E6C9;
  padding: 20px;
  text-align: center;
  color: #333;
}

footer a {
  color: #333;
  margin: 0 10px;
  text-decoration: none;
  font-weight: bold;
  white-space: nowrap;
}

footer a:hover {
  color: #388E3C;
}

footer p {
  margin: 0;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
}


/* Imagen de perfil y tarjeta */
.profile-card {
  display: flex;
  align-items: center;
  gap: 40px;
  padding: 30px;
}

.profile-img {
  width: 250px;
  height: 250px;
  border-radius: 50%;
  object-fit: cover;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

/* ¡HOLA! con hover verde */
h2 {
  color: #333;
  transition: background-color 0.3s, color 0.3s;
  display: inline-block;
  padding-bottom: 5px;
  text-align: right;
}

h2:hover {
  background-color: #81C784;
  color: #FFFFFF;
}

/* Cajitas desplegables como tarjetas */
details {
  margin-bottom: 20px;
  padding: 12px 16px;
  background-color: #f9f9f9;
  border-radius: 12px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s, box-shadow 0.3s;
  width: 100%;
  box-sizing: border-box;
}

details:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* Encabezado con la flechita y alineación perfecta */
summary {
  font-size: 1.1em;
  font-weight: bold;
  color: #333;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 10px;
  list-style: none; /* elimina el estilo del navegador */
}

details[open] summary {
  margin-bottom: 10px;
}

/* Estilo para la flechita ▶️ */
summary::-webkit-details-marker {
  display: none;
}

summary::before {
  content: "▶";
  display: inline-block;
  transition: transform 0.3s ease;
}

/* Rotar la flecha al abrir */
details[open] summary::before {
  transform: rotate(90deg);
}


/* Textos */
p {
  line-height: 1.6;
  animation: fadeInText 1.8s forwards;
  text-align: justify;
}

@keyframes fadeInText {
  from { opacity: 0; transform: translateY(30px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Visualizar GitHub */

.github-card {
  display: flex;
  align-items: center;
  background-color: #f9f9f9;
  padding: 20px;
  border-radius: 12px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
  max-width: 400px;
  margin: auto;
}

.github-avatar {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  margin-right: 20px;
}

.github-info {
  flex: 1;
}

.github-username {
  font-size: 1.2em;
  font-weight: bold;
  color: #333;
  text-decoration: none;
}

.github-username:hover {
  text-decoration: underline;
}

.github-repos {
  list-style: none;
  padding: 0;
  margin-top: 10px;
}

.github-repos li {
  margin-bottom: 5px;
}

.github-repos a {
  color: #FF6F61;
  text-decoration: none;
}

.github-repos a:hover {
  text-decoration: underline;
}

/* Responsive */
@media (max-width: 768px) {
  nav {
    flex-direction: column;
    align-items: center;
  }

  nav a, .dropbtn {
    margin: 5px 0;
  }

  .content {
    padding: 100px 20px;
  }

  .profile-card {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }

  .dropdown-content {
    position: static;
    margin-top: 10px;
    box-shadow: none;
  }

  .dropdown-content a {
    padding: 8px 10px;
  }
}