
/* =========================================
   RESET
========================================= */

*{
  margin:0;
  padding:0;
  box-sizing:border-box;
}

html{
  scroll-behavior:smooth;
  -webkit-text-size-adjust:100%;
}

body{
  font-family:'Inter',sans-serif;
  background:#F8FAFC;
  color:#0F172A;
  overflow-x:hidden;
  -webkit-font-smoothing:antialiased;
}

a{
  text-decoration:none;
  color:inherit;
}

img{
  width:100%;
  display:block;
}

.container{
  width:90%;
  max-width:1200px;
  margin:auto;
}

section{
  padding:50px 0;
}

/* =========================================
   MENU
========================================= */

nav{
  position:fixed;
  top:0;
  left:0;
  width:100%;
  z-index:1000;
  background:rgba(255,255,255,.90);
  backdrop-filter:blur(12px);
  border-bottom:1px solid #E2E8F0;
}

.nav-content{
  height:80px;
  display:flex;
  align-items:center;
  justify-content:space-between;
}

.logo{
  font-size:1.2rem;
  font-weight:700;
  color:#2563EB;
  font-family:'Space Grotesk',sans-serif;
}

.menu{
  display:flex;
  gap:30px;
}

.menu a{
  color:#475569;
  font-weight:500;
  transition:.3s;
  -webkit-tap-highlight-color:transparent;
}

.menu a:hover{
  color:#2563EB;
}

/* =========================================
   ENCABEZADO
========================================= */

.hero{
  min-height:100vh;
  display:flex;
  align-items:center;
  overflow:hidden;
  background:
  radial-gradient(circle at top right, rgba(37,99,235,.08), transparent 25%),
  radial-gradient(circle at bottom left, rgba(6,182,212,.08), transparent 25%);
}

.hero-grid{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:10px;
  align-items:center;
}

/* TEXTO */

.hero-badge{
  display:inline-block;
  padding:10px 18px;
  background:#DBEAFE;
  color:#2563EB;
  border-radius:50px;
  font-size:.9rem;
  font-weight:600;
  margin-bottom:25px;
}

.hero-text h1{
  font-size:4rem;
  line-height:1.1;
  margin-bottom:25px;
  font-family:'Space Grotesk',sans-serif;
}

.hero-text h1 span{
  color:#2563EB;
}

.hero-text p{
  color:#64748B;
  line-height:1.8;
  font-size:1.1rem;
  margin-bottom:35px;
}

/* BOTONES */

.buttons{
  display:flex;
  gap:20px;
  flex-wrap:wrap;
}

.btn{
  padding:15px 28px;
  border-radius:14px;
  font-weight:600;
  transition:.3s;
  -webkit-tap-highlight-color:transparent;
}

.btn-primary{
  background:#2563EB;
  color:white;
}

.btn-primary:hover{
  background:#1D4ED8;
  transform:translateY(-3px);
}

.btn-secondary{
  background:white;
  border:1px solid #CBD5E1;
  color:#0F172A;
}

.btn-secondary:hover{
  border-color:#2563EB;
  color:#2563EB;
}

/* ENCABEZADO VISUAL */

.hero-visual{
  position:relative;
  display:flex;
  justify-content:center;
  align-items:center;
}

/* FOTO */

.profile-container{
  position:relative;
  width:340px;
  height:340px;
  display:flex;
  justify-content:center;
  align-items:center;
}

.profile-ring{
  position:absolute;
  width:100%;
  height:100%;
  border-radius:50%;
  background:
  linear-gradient(135deg,#2563EB,#06B6D4);
  opacity:.15;
  animation:pulse 4s infinite;
}

.profile-image{
  position:relative;
  width:280px;
  height:280px;
  object-fit:cover;
  border-radius:50%;
  border:8px solid white;
  box-shadow:
  0 20px 40px rgba(15,23,42,.10);
  z-index:2;
}

/* DASHBOARD MINI */

.dashboard-mini{
  position:absolute;
  right:-70px;
  bottom:20px;
  display:flex;
  flex-direction:column;
  gap:15px;
}

.mini-card{
  background:white;
  border:1px solid #E2E8F0;
  border-radius:18px;
  padding:18px 22px;
  min-width:180px;
  box-shadow:
  0 10px 30px rgba(15,23,42,.06);
}

.mini-card small{
  color:#64748B;
}

.mini-kpi{
  margin-top:8px;
  color:#2563EB;
  font-weight:700;
  font-size:1.1rem;
}

/* =========================================
   TITULOS
========================================= */

.section-title{
  text-align:center;
  margin-bottom:60px;
}

.section-title h2{
  font-size:2.8rem;
  margin-bottom:15px;
  font-family:'Space Grotesk',sans-serif;
}

.section-title p{
  color:#64748B;
}

/* =========================================
   ACERCA DE MI
========================================= */

#about-section{
  scroll-margin-top:120px;
}

.about-section{
  margin-top:0px;
}

.about-grid{
  display:grid;
  grid-template-columns:repeat(4,1fr);
  gap:25px;
  overflow:hidden;
}

.about-card{
  background:white;
  border:1px solid #E2E8F0;
  border-radius:24px;
  padding:30px;
  text-align:center;
  box-shadow:
  0 10px 30px rgba(15,23,42,.04);
}

.about-card h3{
  color:#2563EB;
  margin-bottom:12px;
}

.about-card p{
  color:#64748B;
  line-height:1.7;
}

/* =========================================
   HABILIDADES
========================================= */

#habilidades{
  scroll-margin-top:120px;
}

.skills-grid{
  display:grid;
  grid-template-columns:repeat(3,1fr);
  gap:25px;
  overflow:hidden;
}

.skill-box{
  background:white;
  border:1px solid #E2E8F0;
  border-radius:24px;
  padding:30px;
}

.skill-box h3{
  color:#2563EB;
  margin-bottom:25px;
}

.tags{
  display:flex;
  flex-wrap:wrap;
  gap:12px;
}

.tag{
  background:#EFF6FF;
  color:#1E3A8A;
  padding:10px 15px;
  border-radius:10px;
  font-size:.9rem;
}

/* =========================================
   PROYECTOS
========================================= */

#proyectos{
  scroll-margin-top:120px;
}

.projects-grid{
  display:grid;
  grid-template-columns:repeat(3,1fr);
  gap:30px;
  overflow:hidden;
}

.project{
  background:white;
  border:1px solid #E2E8F0;
  border-radius:24px;
  overflow:hidden;
  transition:.3s;
}

.project:hover{
  transform:translateY(-5px);
}

.project-image{
  height:220px;
  background:
  linear-gradient(135deg,#fbfbfc,#ffffff);
}

.project-image img{
  height:100%;
  object-fit:cover;
}

.project-content{
  padding:25px;
}

.project-content h3{
  margin-bottom:12px;
}

.project-content p{
  color:#64748B;
  line-height:1.7;
  margin-bottom:20px;
}

/* =========================================
   CONTACTO
========================================= */

.contact-box{
  max-width:700px;
  margin:auto;
  background:white;
  border:1px solid #E2E8F0;
  border-radius:30px;
  padding:50px;
  box-shadow:
  0 10px 30px rgba(15,23,42,.05);
}

form{
  display:flex;
  flex-direction:column;
  gap:20px;
}

input,
textarea,
button{
appearance: none;
  -webkit-appearance: none;
}

input,
textarea{
  padding:18px;
  border-radius:14px;
  border:1px solid #CBD5E1;
  background:#F8FAFC;
  font-family:'Inter',sans-serif;
  outline:none;
}

textarea{
  resize:none;
  height:160px;
}

button{
  border:none;
  cursor:pointer;
}

/* =========================================
   PIE
========================================= */

footer{
  padding:40px 0;
  text-align:center;
  color:#64748B;
  border-top:1px solid #E2E8F0;
}

/* =========================================
   VIDEO
========================================= */

.video-container{
  width:50%;
  margin:auto;
}

.video-container h2{
  text-align:center;
}

.video-container video{
  width:100%;
  display:block;
  border-radius:20px;
}

/* =========================================
   ANIMACION
========================================= */

@keyframes pulse{

  0%{
    transform:scale(1);
    opacity:.15;
  }

  50%{
    transform:scale(1.05);
    opacity:.25;
  }

  100%{
    transform:scale(1);
    opacity:.15;
  }

}

/* =========================================
   RESPONSIVE DESIGN
========================================= */

/* ---------- LAPTOPS PEQUEÑAS ---------- */

@media (max-width:1200px){

  .hero-text h1{
    font-size:3.2rem;
  }

  .dashboard-mini{
    right:-60px;
  }

}

/* ---------- TABLETS ---------- */

@media (max-width:992px){

  .hero{
    padding-top:120px;
    min-height:auto;
  }

  .hero-grid{
    grid-template-columns:1fr;
    gap:60px;
    text-align:center;
  }

  .hero-text{
    order:2;
  }

  .hero-visual{
    order:1;
  }

  .buttons{
    justify-content:center;
  }

  .dashboard-mini{
    position:relative;
    right:auto;
    bottom:auto;
    margin-top:30px;
    flex-direction:row;
    justify-content:center;
    flex-wrap:wrap;
  }

  .about-grid{
    grid-template-columns:repeat(2,1fr);
  }

  .skills-grid{
    grid-template-columns:1fr;
  }

  .projects-grid{
    grid-template-columns:repeat(2,1fr);
  }

  .video-container{
    width:90%;
  }

}

/* ---------- MOVILES ---------- */

@media (max-width:768px){

  nav{
    padding:10px 0;
  }

  .nav-content{
    height:auto;
    flex-direction:column;
    gap:15px;
    padding:10px 0;
  }

  .menu{
    flex-wrap:wrap;
    justify-content:center;
    gap:18px;
  }

  .hero{
    padding-top:160px;
  }

  .hero-text h1{
    font-size:2.5rem;
    line-height:1.2;
  }

  .hero-text p{
    font-size:1rem;
  }

  .profile-container{
    width:260px;
    height:260px;
  }

  .profile-image{
    width:220px;
    height:220px;
  }

  .dashboard-mini{
    flex-direction:column;
    align-items:center;
  }

  .mini-card{
    min-width:220px;
  }

  .section-title h2{
    font-size:2rem;
  }

  .about-grid{
    grid-template-columns:1fr;
  }

  .projects-grid{
    grid-template-columns:1fr;
  }

  .contact-box{
    padding:30px 20px;
  }

  .btn{
    width:100%;
    text-align:center;
  }

}

/* ---------- iPHONE SE / MINI ---------- */

@media (max-width:480px){

  .container{
    width:92%;
  }

  section{
    padding:40px 0;
  }

  .hero{
    padding-top:180px;
  }

  .hero-text h1{
    font-size:2rem;
  }

  .hero-badge{
    font-size:.8rem;
  }

  .profile-container{
    width:220px;
    height:220px;
  }

  .profile-image{
    width:190px;
    height:190px;
    border-width:5px;
  }

  .mini-card{
    width:100%;
    min-width:auto;
  }

  .project-content{
    padding:20px;
  }

  .contact-box{
    border-radius:20px;
    padding:25px 15px;
  }

  input,
  textarea{
    padding:15px;
  }

}

/* AREA iPHONE */

@supports (padding:max(0px)){

  body{
    padding-left:env(safe-area-inset-left);
    padding-right:env(safe-area-inset-right);
  }

}

