:root {
  --green: #1e6fd9;         /* azul científico principal */
  --green-dark: #124a99;    /* azul profundo */
  --green-light: #e8f1fd;   /* azul muy claro */
  --yellow: #38bdf0;        /* celeste de acento */
  --yellow-light: #e2f7ff;  /* celeste claro */
  --ink: #16283d;           /* azul tinta para texto */
  --muted: #5b6e83;         /* gris azulado */
  --white: #ffffff;
  --shadow: 0 10px 30px rgba(30, 111, 217, 0.12);
  --radius: 20px;
}

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

html {
  scroll-behavior: smooth;
}

body {
  font-family: "Quicksand", sans-serif;
  color: var(--ink);
  background: linear-gradient(160deg, #ffffff 0%, #f2f7fd 100%);
  line-height: 1.65;
  overflow-x: hidden;
}

h1, h2, h3, .logo {
  font-family: "Poppins", sans-serif;
}

/* Blobs decorativos */
.blob {
  position: fixed;
  border-radius: 50%;
  filter: blur(60px);
  opacity: 0.35;
  z-index: -1;
  pointer-events: none;
}
.blob-1 {
  width: 380px;
  height: 380px;
  background: var(--yellow);
  top: -120px;
  right: -80px;
}
.blob-2 {
  width: 420px;
  height: 420px;
  background: var(--green);
  bottom: -160px;
  left: -120px;
}

/* NAV */
.nav {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px clamp(20px, 5vw, 60px);
  background: rgba(255, 255, 255, 0.7);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(58, 157, 93, 0.08);
}
.logo {
  font-weight: 700;
  font-size: 1.4rem;
  color: var(--green-dark);
  text-decoration: none;
}
.nav nav {
  display: flex;
  gap: clamp(14px, 3vw, 30px);
}
.nav nav a {
  text-decoration: none;
  color: var(--muted);
  font-weight: 500;
  transition: color 0.2s ease;
}
.nav nav a:hover {
  color: var(--green);
}

/* HERO */
.hero {
  text-align: center;
  padding: clamp(60px, 12vh, 120px) 20px clamp(50px, 8vh, 90px);
  max-width: 760px;
  margin: 0 auto;
}
.hero-badge {
  display: inline-block;
  background: var(--yellow-light);
  color: var(--green-dark);
  border: 1px solid var(--yellow);
  padding: 6px 16px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 0.9rem;
  margin-bottom: 22px;
}
.hero h1 {
  font-size: clamp(2.2rem, 6vw, 3.6rem);
  line-height: 1.15;
  margin-bottom: 18px;
}
.highlight {
  color: var(--green);
  position: relative;
}
.highlight::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 4px;
  width: 100%;
  height: 10px;
  background: var(--yellow);
  opacity: 0.5;
  z-index: -1;
  border-radius: 4px;
}
.subtitle {
  font-size: 1.15rem;
  color: var(--muted);
  max-width: 560px;
  margin: 0 auto 30px;
}

/* Botones */
.hero-actions {
  display: flex;
  gap: 14px;
  justify-content: center;
  flex-wrap: wrap;
}
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 26px;
  border-radius: 999px;
  font-weight: 600;
  text-decoration: none;
  font-family: "Poppins", sans-serif;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
  cursor: pointer;
}
.btn-primary {
  background: var(--green);
  color: var(--white);
  box-shadow: var(--shadow);
}
.btn-primary:hover {
  background: var(--green-dark);
  transform: translateY(-2px);
}
.btn-outline {
  background: transparent;
  color: var(--green-dark);
  border: 2px solid var(--green);
}
.btn-outline:hover {
  background: var(--green-light);
  transform: translateY(-2px);
}

/* Secciones */
.section {
  max-width: 900px;
  margin: 0 auto;
  padding: clamp(40px, 8vh, 70px) 20px;
}
.section h2 {
  text-align: center;
  font-size: clamp(1.7rem, 4vw, 2.3rem);
  margin-bottom: 36px;
  color: var(--green-dark);
}
.section h2::after {
  content: "";
  display: block;
  width: 60px;
  height: 4px;
  background: var(--yellow);
  border-radius: 4px;
  margin: 10px auto 0;
}

/* Sobre mí */
.about {
  display: flex;
  align-items: center;
  gap: 30px;
  background: var(--white);
  border-radius: var(--radius);
  padding: 34px;
  box-shadow: var(--shadow);
  flex-wrap: wrap;
}
.avatar {
  flex: 0 0 auto;
  width: 110px;
  height: 110px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--green-light), var(--yellow-light));
  display: grid;
  place-items: center;
  font-size: 3rem;
  margin: 0 auto;
}
.about-text {
  flex: 1;
  min-width: 240px;
}
.about-text p + p {
  margin-top: 14px;
}

/* Cards */
.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 22px;
}
.card {
  background: var(--white);
  border-radius: var(--radius);
  padding: 30px 26px;
  text-align: center;
  box-shadow: var(--shadow);
  border: 1px solid rgba(58, 157, 93, 0.06);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}
.card:hover {
  transform: translateY(-6px);
  box-shadow: 0 16px 36px rgba(58, 157, 93, 0.2);
}
.card-icon {
  font-size: 2.4rem;
  margin-bottom: 12px;
}
.card h3 {
  color: var(--green-dark);
  margin-bottom: 8px;
  font-size: 1.2rem;
}
.card p {
  color: var(--muted);
  font-size: 0.98rem;
}

/* Contacto */
.contact {
  text-align: center;
}
.contact p {
  color: var(--muted);
  margin-bottom: 24px;
  font-size: 1.1rem;
}
.btn-linkedin {
  background: var(--green);
  color: var(--white);
  box-shadow: 0 10px 24px rgba(30, 111, 217, 0.35);
}
.btn-linkedin:hover {
  background: var(--green-dark);
  transform: translateY(-2px);
}

/* Footer */
.footer {
  text-align: center;
  padding: 30px 20px;
  color: var(--muted);
  font-size: 0.95rem;
}

/* Aparición al hacer scroll */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
}
