* {
  box-sizing: border-box;
}

:root {
  --blanco: #f9f9f9;
  --oscuro: #0c0c0c;
  --resalto: #00a6ff;
  --gris: #2b2b2b;
  --grisclaro: #868686;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  margin: 0;
  padding: 0;
}

body {
  background-color: var(--blanco);
  color: var(--oscuro);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

h1 {
  font-size: 3rem;
  font-weight: 470;
  letter-spacing: -0.1rem;
  margin: 0;
  padding: 0;
  text-align: center;
}

h1 span {
  color: var(--resalto);
  font-weight: 600;
}

.h2 {
  margin: 0;
  padding: 0 0 2rem 0;
  font-size: 2rem;
  font-weight: 600;
  color: var(--oscuro);
  text-align: center;
}

p {
  margin: 0;
  padding: 0;
  font-size: 1.2rem;
  text-align: center;
  color: rgb(52, 52, 83);
}
a {
  text-decoration: none;
  color: var(--oscuro);
}

/* =========================
   NAVBAR
========================= */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1002;
  background: transparent;
  transition: background 0.3s, box-shadow 0.3s;
  box-shadow: none;
}

.navbar.scrolled {
  background: #fff;
  box-shadow: 0 2px 16px rgba(0,0,0,0.06);
}

.container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 1200px;
  margin: 0 auto;
  height: 70px;
  padding: 0 24px;
}

.logo {
  color: #0074ff;
  font-weight: 700;
  font-size: 1.3rem;
  margin: 0;
}

.logo span {
  color: #1a1a1a;
  font-weight: 400;
}

/* =========================
   NAV LINKS
========================= */
.nav-links {
  list-style: none;
  display: flex;
  gap: 40px;
  margin: 0;
  padding: 0;
  align-items: center;
}

.nav-links li a {
  text-decoration: none;
  color: #222;
  font-weight: 500;
  font-size: 1.1rem;
  transition: color 0.2s;
}

.nav-links li a:hover {
  color: #0074ff;
}


/* =========================
   BUTTONS
========================= */
.btn {
  background: #0074ff;
  color: #fff;
  border: none;
  border-radius: 16px;
  padding: 12px 32px;
  font-size: 1.1rem;
  font-weight: 600;
  text-decoration: none;
  margin-left: 30px;
  box-shadow: 0 4px 16px rgba(0, 116, 255, 0.08);
  transition: background 0.2s;
  cursor: pointer;
}

.btn-small {
  padding: 10px 28px;
  font-size: 1rem;
}

.login-btn {
  background: #0074ff;
  color: #fff;
  border-radius: 16px;
  padding: 8px 20px;
  font-size: 1.1rem;
  font-weight: 600;
  text-decoration: none;
  box-shadow: 0 4px 16px rgba(0, 116, 255, 0.08);
  margin-left: 0;
}

/* =========================
   MENU HAMBURGUESA
========================= */
.menu-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  width: 40px;
  height: 40px;
  cursor: pointer;
  z-index: 1003;
}

.menu-toggle span {
  height: 4px;
  width: 100%;
  background: #0074ff;
  margin: 6px 0;
  border-radius: 2px;
  transition: 0.3s;
  display: block;
}

/* Animación hamburguesa activa */
.menu-toggle.active span:nth-child(1) {
  transform: rotate(45deg) translate(7px, 7px);
}
.menu-toggle.active span:nth-child(2) {
  opacity: 0;
}
.menu-toggle.active span:nth-child(3) {
  transform: rotate(-45deg) translate(7px, -7px);
}

@media (max-width: 900px) {
  .container {
    flex-direction: row;
    align-items: center;
    gap: 0;
    max-width: 100vw;
    padding: 0 16px;
    height: 60px;
  }

  .logo {
    font-size: 1.1rem;
  }

  .nav-links {
    position: fixed;
    top: 0;
    right: -100vw;
    width: 70vw;
    max-width: 100vw;
    height: 100vh;
    background: #fff;
    flex-direction: column;
    gap: 32px;
    justify-content: center;
    align-items: center;
    box-shadow: -2px 0 16px rgba(0,0,0,0.08);
    transition: right 0.3s;
    z-index: 1001;
    overflow-y: auto; /* Permite scroll si el contenido es mayor */
    box-sizing: border-box; /* Incluye padding en el ancho */
  }

  .nav-links.open {
    right: 0;
  }

  .nav-links li a {
    font-size: 1.3rem;
    color: #0074ff;
  }

  .btn,
  .btn-small,
  .login-btn {
    font-size: 1rem;
    padding: 10px 24px;
    margin-left: 0;
    margin-top: 12px;
    position: static;
    box-shadow: none;
  }

  .login-btn {
    margin-top: 0;
    margin-left: 0;
  }

  .menu-toggle {
    display: flex;
    margin-left: auto;
  }

  .navbar {
    padding: 18px 0 0 0;
    position: fixed;
  }
}

.hero {
    margin: 4rem 0;
  padding: 8rem 0 5rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  align-items: center;
  justify-content: center;
  height: fit-content;
  width: 47%;
}
.contenedor-p {
  width: 80%;
}

#contacto {
  text-decoration: none;
  background-color: var(--oscuro);
  color: var(--blanco);
  height: 3rem;
  width: fit-content;
  border: none;
  border-radius: 0.6rem;
  font-size: 1.2rem;
  padding: 1rem;
  display: flex;
  justify-content: center;
  align-items: center;
  transition: ease-in-out 0.3s;
}
#contacto:hover {
  cursor: pointer;
  background-color: var(--resalto);
}

.grid-bio {
  border: 2px solid #00a6ff;
  background-color: rgb(255, 255, 255);
  display: grid;
  grid-template-columns: 1fr 2fr;
  height: fit-content;
  padding: 3rem;
  gap: 3rem;
  margin: 2rem auto;
  width: 60%;
  border-radius: 0.8rem;
  box-shadow: 0px 7px 10px rgba(0, 0, 0, 0.386);
  overflow: hidden; /* Previene que cualquier contenido se salga del contenedor */
}

@media (max-width: 1237px) {
  .grid-bio {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 90%;
  }
}

.texto-bio {
  width: 100%;
  max-width: 80%;
  line-height: 1.4;
  text-align: justify;
  color: var(--oscuro);
  margin: 0.5rem 0 1rem;
}


.despedida{
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
}
.despedida p{
    width: fit-content;
}

video{
    width: 8rem;
}

.grid-texto{
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: fit-content;
}

.bold{
    color: var(--resalto);
    font-size: 1.4rem;
    font-weight: 700;
}


.grid-imagenes {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
}

#g1 {
  height: 100%;
  width: fit-content;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

#g1 img{
  width: 15rem;
  border-radius: 5%;
  box-shadow: 0 0 15px rgba(0, 0, 0, 0.3); /* Difuminado suave */
  transition: box-shadow 0.3s ease;
}

#g1 img:hover{
  box-shadow: 0 0 25px rgba(0, 0, 0, 0.5);
}



@media (max-width: 697px) {

  #g1 img{

    width: 80%;

  }

}

.contacto {
  width: 100%;
  padding: 0 3rem;
  display: grid;
  grid-template-columns: auto 1fr;
  grid-gap:0;
  align-items: center;
  border-radius: 10px;
}
.contacto p{
  text-align: left;
}

.contacto_icono i{
  width: 3rem;
  height: 3rem;
  display: flex;
  justify-content: center;
  align-items: center;
}

.contacto_info {
  font-size: 16px;
}


.tecnologias {
  width: 90%;
  height: fit-content;
  border-radius: 0.8rem;
  height: fit-content;
  padding: 3rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;

} 

.titulo {
  width: 100%;
  height: fit-content;
}

.tecnologias-logo {
  padding: 1rem 0;
  width: 70%;
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
}


.tecnologias-logo svg {
  height: 3rem;
  width: 3rem;
  transition: ease-in-out 0.3s;
}

.tecnologias-logo img {
  height: 3rem;
  width: 3rem;
  transition: ease-in-out 0.3s;
}

.tecnologias-logo svg:hover {
  scale: 1.2;
}

.tecnologias-logo img:hover {
  scale: 1.2;
}



@media (max-width: 1237px) {

  .tecnologias-logo{
display: grid;
grid-template-columns: auto auto auto;
gap: 1.5rem;
  }
}


.seccion-proyectos{
  margin: 3rem 0;
}

.Proyectos {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 2rem;
  justify-items: center;
  align-items: stretch;
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
}

/* Si hay un solo proyecto en la última fila, céntralo */
.Proyectos > *:nth-last-child(1):nth-child(odd) {
  grid-column: 1 / -1;
  justify-self: center;
}

.pill-proyecto {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: fit-content;
  height: fit-content;
  gap: 2rem;
  text-align: center; /* Asegura el centrado del texto */
}

.pill-proyecto h3 {
  margin-top: 1rem;
  text-align: center;
  width: 100%;
  align-self: center;
  justify-self: center;
}


.pill-proyecto img{
  width: 30rem;
  border-radius: 0.5rem;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  box-shadow: 0px 7px 10px rgba(0, 0, 0, 0.386); 
}

.pill-proyecto img:hover{
  transform: scale(1.05);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}



@media (max-width: 1237px) {

  .Proyectos {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .pill-proyecto img{
    width: 60%;
  }
}
.contenido {
  padding: 3rem;
  width: 65%;
  display: grid;
  grid-template-columns: 2fr 1fr;
  align-items: first baseline;
  justify-content: center;
  column-gap: 4rem;
}

@media (max-width: 1237px) {
    .contenido {
      padding: 2rem;
      width: 100%;
      display: flex;
      flex-direction: column;
      align-items: center;
      justify-content: center;
      gap: 2rem;
      padding-left: 3rem;
      padding-right: 0rem;
    }
    .pill{
      padding-left: 1rem;
    }
    
  }
  


.titulo-exp {
  color: var(--oscuro);
  text-align: left;
  justify-content: first baseline;
}

.exp .edu {
  padding-top: 2rem;
  display: grid;
  grid-template-columns: 1fr;
  align-items: first baseline;
}

.fecha {
  color: var(--grisclaro);
  font-weight: lighter;
  font-size: 1rem;
  margin: 1rem;
}

.pill{
  margin-bottom: 4rem;
}

.empresa {
  font-size: 1.323rem;
  font-weight: 500;
  transition: ease-in-out 0.3s;
}

.empresa:hover {
  font-weight: bolder;
  color: var(--resalto);
}

.pill p {
  width: 80%;
  line-height: 1.4;
  text-align: justify;
  color: var(--oscuro);
  margin: 0.5rem 0 1rem;
}

.pill a {
  color: #4a1401;
  transition: ease-in-out 0.3s;
}
.pill a:hover{
color: var(--resalto);
}

.centro {
  width: 100%;
  line-height: 1.4;
  text-align: left;
  color: var(--oscuro);
  margin: 0.5rem 0 1rem;
  width: 100%;
  text-align: left;
}

.fecha-estudio {
  margin-top: 0;
  text-align: left;
  width: fit-content;
}

.pill-edu {
  display: flex;
  flex-direction: column;
  align-items: left;
}

/* Contenedor de secciones */
.contenedor-info,
.contenedor-info2 {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 20px;
  max-width: 1000px;
  margin: 0 auto 60px auto;
  padding: 20px;
  justify-content: center; /* Centra las tarjetas en filas incompletas */
}

/* Tarjetas (Glassmorphism Apple style) */
.infor, 
.infor2 {
  background: rgba(255, 255, 255, 0.65);
  backdrop-filter: blur(15px);
  -webkit-backdrop-filter: blur(15px);
  border-radius: 20px;
  padding: 25px;
  text-align: center;
  box-shadow: 0 8px 20px rgba(0,0,0,0.08);
  transition: all 0.3s ease;
  cursor: default;
  border: 1px solid rgba(255, 255, 255, 0.5);
  display: flex; /* Añadido para centrar contenido */
  flex-direction: column; /* Vertical */
  align-items: center;    /* Horizontal */
  justify-content: center;/* Vertical */
}

/* Efecto hover elegante */
.infor:hover, 
.infor2:hover {
  transform: translateY(-6px);
  box-shadow: 0 12px 30px rgba(0,0,0,0.12);
  background: rgba(255, 255, 255, 0.8);
}

/* Textos dentro de las tarjetas */
.infor h3, 
.infor2 h3 {
  font-size: 1.1rem;
  font-weight: 500;
  color: #1d1d1f;
  margin: 0;
}

/* Responsive para móviles */
@media (max-width: 600px) {
  .h2 {
    font-size: 1.6rem;
    margin: 40px 0 20px;
  }

  .infor h3, 
  .infor2 h3 {
    font-size: 1rem;
  }
}

/* Sección Información Relevante */
.contenedor-info, .contenedor-info2 {
  display: flex;
  flex-wrap: wrap;
  justify-content: center; /* Centra las tarjetas en filas incompletas */
  gap: 20px;
  max-width: 1000px;
  margin: 0 auto 60px auto;
  padding: 20px;
}

/* Tarjetas */
.infor, .infor2 {
  flex: 1 1 240px; /* Todas ocupan el mismo ancho mínimo */
  max-width: 280px; /* Ancho máximo para mantener equilibrio */
  background: rgba(255, 255, 255, 0.65);
  backdrop-filter: blur(15px);
  -webkit-backdrop-filter: blur(15px);
  border-radius: 20px;
  padding: 25px;
  text-align: center;
  box-shadow: 0 8px 20px rgba(0,0,0,0.08);
  transition: all 0.3s ease;
  cursor: default;
  border: 1px solid rgba(255, 255, 255, 0.5);
}

/* Hover */
.infor2:hover {
  transform: translateY(-6px);
  box-shadow: 0 12px 30px rgba(0,0,0,0.12);
  background: rgba(255, 255, 255, 0.8);
}

/* Responsive móvil: todas en columna */
@media (max-width: 768px) {
  .contenedor-info, .contenedor-info2 {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
    align-items: center;
    justify-items: center;
    padding: 10px;
  }

  .infor, 
  .infor2 {
    width: 100%;
    max-width: 350px;
    min-width: 220px;
    box-sizing: border-box;
    margin: 0 auto;
    height: auto; /* Evita que crezca demasiado */
    display: flex;
    flex-direction: column;
    justify-content: center;
  }
}


button {
  width: 40%;
  padding: 0.625rem;
  background-color: var(--resalto);
  color: #fff;
  border: none;
  border-radius: 0.3rem;
  cursor: pointer;
}

button:hover {
  background-color: var(--resalto);
  scale: 1.03;
}

footer{
  height: 10vh;
  width: 100%;
  background-color: var(--oscuro);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  padding: 3.4rem 0;
}

footer p{
  color: var(--blanco);
  font-weight: lighter;
}


.rrss{
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  gap: 1rem;
}
footer svg{
  filter: brightness(100);
  width: 1.3rem;
  height: 1.3rem;
}



/*CURSOR*/

.location {
  width: fit-content;
  height: fit-content;
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: left;
}

.material-symbols-outlined {
  font-variation-settings: "FILL" 0, "wght" 200, "GRAD" -25, "opsz" 24;
}


/* Solución para desbordamiento en contenedores */
.contenedor-info, .grid-bio {
  max-width: 90%;
  overflow: hidden; 
}

@keyframes wave {
  0% { transform: rotate(0deg); }
  10% { transform: rotate(14deg); }
  20% { transform: rotate(-8deg); }
  30% { transform: rotate(14deg); }
  40% { transform: rotate(-4deg); }
  50% { transform: rotate(10deg); }
  60% { transform: rotate(0deg); }
  100% { transform: rotate(0deg); }
}

.wave-hand {
  display: inline-block;
  animation: wave 2s infinite;
  transform-origin: 70% 70%;
  animation-delay: 2s; /* Ajusta el delay según sea necesario */
}