/* ============ Fondo animado (ahora en escala de grises) ============ */
body {
  font-family: 'Inter', sans-serif;
  background: linear-gradient(270deg, #ffffff, #f0f0f0);
  background-size: 600% 600%;
  animation: gradientAnimation 10s ease infinite;
  color: #000000;
}
@keyframes gradientAnimation {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

/* ============ HERO ============ */
.hero {
  padding: 4rem 1rem;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;

  background: #ede8e1; /* un gris claro distinto al fondo */
  position: relative;  /* necesario para degradados o sombras */
}

.hero-inner {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;  /* dos columnas: texto + foto */
  gap: 2.5rem;
  width: 68rem;
  max-width: 92vw;
  margin: 0 auto;
  align-items: center;
}

.hero-image {
  display: flex;
  align-items: center;
  justify-content: center;
}



.profile-hero {
  position: relative;      /* ya no absolute */
  top: -3rem;              /* sobresale por arriba */
  width: auto;
  max-height: 130%;        /* más grande que la card */
}

/* Textos */
.hero-title {
  font-size: 3rem;
  font-weight: 700;
  color: #000000;
}
.hero-subtitle {
  margin-top: 0.5rem;
  font-size: 1.25rem;
  color: #4a4a4a;
}
.hero-description {
  margin-top: 1.25rem;
  max-width: 40rem;
  color: #4a4a4a;
}

/* Botones */
.hero-buttons {
  margin-top: 2.5rem;
  display: flex;
  justify-content: space-around;

}
.btn-primary,
.btn-secondary {
  padding: 0.5rem 1.25rem;
  border-radius: 0.375rem;
  box-shadow: 0 4px 6px rgba(0,0,0,0.1);
  text-decoration: none;
  transition: opacity 0.3s, background-color 0.3s;
  width: 40%;
  height: 4rem;
  text-align: center;
  font-size: large;
  line-height: 3rem;
}
.btn-primary {
  background-color: #000000;
  color: #ede8e1;
}
.btn-primary:hover { background-color: #222222; }
.btn-secondary {
  background-color: #000000;
  color: #ede8e1;
}
.btn-secondary:hover { background-color: #d1d1d1; }

/* ============ Secciones ============ */
.section-title { font-size: 2rem; font-weight: 700; margin-bottom: 1.5rem; }
.section-text { color: #4a4a4a; line-height: 1.75; }

.projects { background-color: #f7f7f7; padding: 5rem 1.5rem; }
.project-grid { display: grid; grid-template-columns: 1fr; gap: 2rem; }
.project-card {
  background-color: #ffffff;
  border-radius: 0.75rem;
  padding: 1.5rem;
  box-shadow: 0 4px 6px rgba(0,0,0,0.1);
  transition: box-shadow 0.3s;
}
.project-card:hover { box-shadow: 0 6px 10px rgba(0,0,0,0.15); }
.project-title { font-size: 1.25rem; font-weight: 600; }
.project-description { margin-top: 0.5rem; font-size: 0.875rem; color: #4a4a4a; }
.project-link { margin-top: 1rem; display: inline-block; font-size: 0.875rem; text-decoration: underline; color: #000000; }

/* ============ SOBRE MÍ ============ */
#sobre-mi {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  max-width: 1100px;
  margin: 0 auto;
  padding: 4rem 1.5rem;
  text-align: left;
}
#sobre-mi h2 {
  font-size: 2rem;
  font-weight: 700;
  margin-bottom: 1.5rem;
  color: #000000;
}
#sobre-mi p {
  font-size: 1.1rem;
  color: #4a4a4a;
  line-height: 1.75;
  font-weight: 300;
}

/* ============ Sticky Header ============ */
#sticky-header {
  position: fixed; top: 0; left: 0; right: 0;
  background: #ede8e1;
  display: none;
  align-items: center;
  justify-content: flex-start;
  padding: 0.5rem 1rem;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
  z-index: 1000;
}
#sticky-header.visible { display: flex; }
#sticky-header a {
  margin-right: 1rem;
  color: #000000;
  text-decoration: none;
  font-weight: 700;
}
#sticky-header nav { margin-left: 1rem; }

#proyectos { text-align: left;
background-color: #ede8e1;
}

/* Helpers */
.max-w-4xl { max-width: 1200px !important; }
.max-w-5xl { max-width: 1400px !important; }

/* ============ Responsive ============ */
@media (min-width: 768px) {
  .project-grid { grid-template-columns: repeat(2, 1fr); }
  .profile-img { width: 25rem; height: 25rem; }
}
@media (max-width: 768px) {
  .hero-inner {
    grid-template-columns: 1fr;
    text-align: center;
    gap: 1.25rem;
  }

  /* Orden: primero título, luego imagen, luego descripción */
  .hero-content { order: 1; }
  .hero-card   { order: 2; }
  .hero-buttons{ order: 3; }

  .hero-card {
    margin: 0 auto;
    max-width: 22rem;
  }
}
@media (min-width: 1200px) {
  .hero-inner { gap: 1.75rem; }
}


/* Tarjeta / marco oscuro para la foto (estilo Euge) */
.hero-card {
  background: #f2f2f2;            /* gris claro, puedes ajustarlo */
  border-radius: 1rem;
  padding-top: 6rem;              /* espacio superior para que sobresalga la cabeza */
  box-shadow: 0 8px 20px rgba(0,0,0,0.15);
  position: relative;
  overflow: hidden;               /* recorta la parte de abajo de la imagen */
  max-width: 18rem;               /* más estrecha */
  height: 24rem;                  /* define la altura fija */
  margin-left: auto;
  display: flex;
  align-items: flex-end;          /* la imagen se alinea abajo y se recorta */
  justify-content: center;
}



/* Halo sutil detrás (spotlight) */
.hero-card::before {
  content: "";
  position: absolute;
  inset: -10% -10% auto -10%;
  height: 70%;
  background: radial-gradient(60% 60% at 60% 30%, rgba(255,255,255,0.06), transparent 60%);
  pointer-events: none;
}



/* Responsive: pila en una columna y centra la tarjeta */
@media (max-width: 768px) {
  .hero-inner {
    grid-template-columns: 1fr;
    text-align: center;
    gap: 1.25rem;
  }
  .hero-card {
    margin: 0 auto;
    max-width: 22rem;
  }
}
.hero::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -2rem;          /* cuánto se extiende el degradado */
  height: 4rem;
  background: linear-gradient(to bottom, #ede8e1,#ede8e100);
  pointer-events: none;
}