/* ======= ESTILOS GENERALES ======= */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: "Helvetica Neue", Arial, sans-serif;
  line-height: 1.6;
  background-color: #ffffff;
  color: #222;
}

/* ======= ENCABEZADO ======= */
header {
  background-color: #0c2d57;
  color: #fff;
  padding: 10px 0;
  position: relative;
  z-index: 1000;
}

header .container {
  width: 90%;
  margin: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

header .logo img {
  height: 45px;
}

nav ul {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
}

nav a {
  color: #fff;
  text-decoration: none;
  font-weight: 500;
  transition: color 0.3s ease;
}

nav a:hover {
  color: #f8f8f8;
  text-decoration: underline;
}

/* ======= HERO DINÁMICO ======= */
.hero-dynamic,
#hero,
#hero-sobre,
#hero-publicaciones {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  padding: clamp(18px, 4vw, 64px);
  min-height: 70vh;
  height: clamp(72vh, 84vh, 92vh);
  color: #fff;
  overflow: hidden;
}

#hero {
  background: url("images/hero/hero-bg.jpg") center center / cover no-repeat;
  text-align: left;
}

#hero::before,
#hero::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
}

/* Capa principal equilibrada */
#hero::before {
  background: linear-gradient(
    to right,
    rgba(0, 0, 0, 0.7) 18%,
    rgba(0, 0, 0, 0.28) 72%
  );
  z-index: 1;
}

/* Capa secundaria: sombra localizada del contorno izquierdo */
#hero::after {
  width: 32%;
  background: radial-gradient(
    circle at 10% 50%,
    rgba(0, 0, 0, 0.7) 0%,
    rgba(0, 0, 0, 0.25) 62%,
    rgba(0, 0, 0, 0) 100%
  );
  z-index: 2;
}

.hero-container,
.hero-content {
  position: relative;
  z-index: 3;
  margin: 0;
  max-width: min(640px, 75vw);
}

.hero-text,
.hero-panel,
.hero-content {
  background: rgba(0, 0, 0, 0.55);
  padding: clamp(16px, 2.8vw, 32px);
  border-radius: 12px;
  display: inline-block;
  box-shadow: 0 6px 22px rgba(0, 0, 0, 0.32);
  backdrop-filter: blur(2px);
}

.hero-text h1,
.hero-content h1 {
  color: #ffffff;
  font-size: clamp(1.8rem, 3.6vw, 2.8rem);
  font-weight: 750;
  letter-spacing: 0.6px;
  margin-bottom: 8px;
}

.hero-text h2,
.hero-content h2,
.hero-content p {
  color: #e8e8e8;
  font-weight: 450;
  font-size: clamp(1rem, 2.1vw, 1.25rem);
  line-height: 1.35;
}

@media (max-width: 768px) and (orientation: portrait) {
  .hero-dynamic,
  #hero,
  #hero-sobre,
  #hero-publicaciones {
    align-items: flex-end;
    justify-content: center;
    padding: clamp(18px, 5vw, 34px);
    background-position: center top;
  }

  .hero-container,
  .hero-content {
    max-width: 94%;
    text-align: left;
    margin-bottom: clamp(16px, 5vh, 36px);
  }
}

@media (max-width: 1024px) and (orientation: landscape) {
  .hero-dynamic,
  #hero,
  #hero-sobre,
  #hero-publicaciones {
    align-items: center;
    justify-content: flex-end;
    padding-inline: clamp(20px, 6vw, 90px);
  }

  .hero-container,
  .hero-content {
    margin-right: clamp(16px, 6vw, 100px);
  }
}

@media (min-width: 1025px) {
  .hero-dynamic,
  #hero,
  #hero-sobre,
  #hero-publicaciones {
    align-items: center;
    justify-content: flex-start;
    padding-inline-start: clamp(42px, 7vw, 168px);
  }
}

/* ======= SECCIÓN CONTACTO ======= */
#contacto {
  padding: 60px 0;
  text-align: center;
}

#contacto h3 {
  color: #0c2d57;
  font-size: 1.8em;
  margin-bottom: 15px;
}

#contacto p {
  color: #333;
  font-size: 1em;
  margin-bottom: 20px;
}

#contacto a {
  color: #0c2d57;
  text-decoration: none;
  font-weight: bold;
}

#contacto a:hover {
  text-decoration: underline;
}

.social-links {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 26px;
  flex-wrap: wrap;
}

.social-links a {
  width: 56px;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  transition: transform 0.25s ease, background-color 0.3s ease;
  background: #ffffff;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.08);
}

.social-links svg {
  width: 30px;
  height: 30px;
  fill: #0c2d57;
  transition: fill 0.3s ease, transform 0.3s ease;
}

.social-links a:hover {
  background: #0c2d57;
  transform: scale(1.08);
}
.social-links a:hover svg {
  fill: #fff;
}

/* ======= FOOTER ======= */
footer {
  background-color: #0c2d57;
  color: #fff;
  text-align: center;
  padding: 30px 10px;
  margin-top: 40px;
}

footer .footer-logo {
  height: 50px;
  margin-bottom: 10px;
}

footer p {
  margin: 5px 0;
  font-size: 0.95em;
}

/* ======= HERO SOBRE MÍ ======= */
/* Usa la foto específica de la carpeta hero: hero-sobre.jpeg */
#hero-sobre {
  position: relative;
  background: url("images/hero/hero-sobre.jpeg") center center / cover no-repeat;
  height: 70vh;
  display: flex;
  align-items: flex-end;
  justify-content: flex-start;
  text-align: left;
  color: #fff;
  overflow: hidden;
}

#hero-sobre::before,
#hero-sobre::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
}

#hero-sobre::before {
  background: linear-gradient(
    to right,
    rgba(0, 0, 0, 0.6) 20%,
    rgba(0, 0, 0, 0.25) 70%
  );
  z-index: 1;
}

#hero-sobre::after {
  width: 28%;
  background: radial-gradient(
    circle at 8% 50%,
    rgba(0, 0, 0, 0.7) 0%,
    rgba(0, 0, 0, 0.25) 60%,
    rgba(0, 0, 0, 0) 100%
  );
  z-index: 2;
  pointer-events: none;
}

/* ======= SECCIÓN BIO ======= */
#bio {
  padding: 60px 0;
}

.bio-inner {
  width: 90%;
  max-width: 900px;
  margin: 0 auto;
}

#bio h3 {
  color: #0c2d57;
  font-size: 1.8em;
  margin-bottom: 15px;
}

.bio-inner p {
  margin-bottom: 15px;
}

.bio-lista {
  margin: 20px 0 25px 20px;
}

.bio-lista li {
  margin-bottom: 10px;
}

.cv-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 10px;
}

.btn {
  display: inline-block;
  padding: 8px 14px;
  border-radius: 4px;
  background-color: #0c2d57;
  color: #fff;
  text-decoration: none;
  font-size: 0.95em;
}

.btn-alt {
  background-color: #e5332a;
}

.btn:hover {
  opacity: 0.9;
}

/* ======= HERO PUBLICACIONES ======= */
/* Usa la imagen de headers: publicaciones-header.jpeg */
#hero-publicaciones {
  position: relative;
  background: url("images/headers/publicaciones-header.jpeg") center center / cover no-repeat;
  height: 70vh;
  display: flex;
  align-items: flex-end;
  justify-content: flex-start;
  text-align: left;
  color: #fff;
  overflow: hidden;
}

#hero-publicaciones::before,
#hero-publicaciones::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
}

#hero-publicaciones::before {
  background: linear-gradient(
    to right,
    rgba(0, 0, 0, 0.6) 20%,
    rgba(0, 0, 0, 0.25) 70%
  );
  z-index: 1;
}

#hero-publicaciones::after {
  width: 28%;
  background: radial-gradient(
    circle at 8% 50%,
    rgba(0, 0, 0, 0.7) 0%,
    rgba(0, 0, 0, 0.25) 60%,
    rgba(0, 0, 0, 0) 100%
  );
  z-index: 2;
  pointer-events: none;
}

/* ======= CONTENIDO PUBLICACIONES ======= */
#publicaciones {
  padding: 60px 0;
}

#publicaciones .container {
  width: 90%;
  max-width: 900px;
  margin: 0 auto;
}

.pub-list {
  list-style: none;
  margin-top: 10px;
}

.pub-item {
  padding: 12px 16px;
  margin-bottom: 10px;
  background: #f7f7f7;
  border-radius: 4px;
  border-left: 4px solid #e5332a;
}

.pub-label {
  font-weight: bold;
  color: #0c2d57;
}

.pub-link {
  color: #0c2d57;
  text-decoration: none;
  font-weight: 500;
}

.pub-link:hover {
  text-decoration: underline;
}

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

  #hero,
  #hero-sobre,
  #hero-publicaciones {
    justify-content: flex-start;
    text-align: left;
    align-items: flex-start;
    height: 70vh;
  }

  .hero-container {
    padding: 18px 20px;
    max-width: 90%;
  }

  .hero-text {
    padding: 14px 18px;
  }

  .hero-text h1 {
    font-size: 1.9em;
  }

  .hero-text h2 {
    font-size: 0.95em;
  }

  .cv-links {
    flex-direction: column;
    align-items: flex-start;
  }
}

/* ======= BOTÓN IDIOMA (NO TOCA EL LAYOUT DEL HEADER) ======= */
.lang-toggle {
  position: absolute;
  left: 16px;
  top: 14px;
}

.lang-toggle a {
  display: inline-block;
  padding: 6px 10px;
  border-radius: 4px;
  background-color: #ffffff;
  color: #0c2d57;
  font-weight: 700;
  font-size: 0.9rem;
  text-decoration: none;
}

.lang-toggle a:hover {
  background-color: #f2f2f2;
}
