/* --- Estilos Base y Botones --- */
.primary-btn {
  padding: 0.75rem 2rem;
  background-color: #007CF0; /* primary */
  color: #FFFFFF;
  font-weight: 700;
  border-radius: 0.5rem;
  box-shadow: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
  transition: all 0.3s ease;
}
.primary-btn:hover {
  background-color: #0056b3; /* Un poco más oscuro */
  transform: translateY(-2px);
  box-shadow: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -2px rgb(0 0 0 / 0.05);
}

.secondary-btn {
  padding: 0.75rem 2rem;
  background-color: transparent;
  border: 2px solid #007CF0; /* primary */
  color: #007CF0; /* primary */
  font-weight: 700;
  border-radius: 0.5rem;
  transition: all 0.3s ease;
}
.secondary-btn:hover {
  background-color: #007CF0; /* primary */
  color: #FFFFFF;
  transform: translateY(-2px);
}


/* --- Animaciones y Efectos Generales --- */
.scroll-reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: all 1s cubic-bezier(0.165, 0.84, 0.44, 1);
}
.scroll-reveal.active {
  opacity: 1;
  transform: translateY(0);
}

#main-header.scrolled {
  box-shadow: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
  background-color: rgba(245, 247, 250, 0.8); /* light-bg/80 */
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}
.dark #main-header.scrolled {
    background-color: rgba(11, 17, 32, 0.8); /* dark-bg/80 */
}


/* --- Menú Hamburguesa y Overlay --- */
#mobile-menu {
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
  z-index: 40;
}
#mobile-menu.open {
  opacity: 1;
  pointer-events: all;
}

.nav-link-mobile {
  color: #d1d5db; /* neutral-300 */
  opacity: 0;
  transform: translateY(10px);
  transition: opacity 0.3s ease, transform 0.3s ease;
}
.nav-link-mobile:hover {
    color: #00DFD8; /* secondary */
}

#mobile-menu.open .nav-link-mobile {
  opacity: 1;
  transform: translateY(0);
}
#mobile-menu.open .nav-link-mobile:nth-child(1) { transition-delay: 0.1s; }
#mobile-menu.open .nav-link-mobile:nth-child(2) { transition-delay: 0.15s; }
#mobile-menu.open .nav-link-mobile:nth-child(3) { transition-delay: 0.2s; }
#mobile-menu.open .nav-link-mobile:nth-child(4) { transition-delay: 0.25s; }
#mobile-menu.open .nav-link-mobile:nth-child(5) { transition-delay: 0.3s; }

.hamburger {
  cursor: pointer;
  width: 24px;
  height: 24px;
  transition: all 0.25s;
  position: relative;
  background-color: transparent;
  border: none;
}
.hamburger .line {
  position: absolute;
  width: 24px;
  height: 3px;
  background-color: #FFF;
  border-radius: 3px;
  transition: all 0.25s ease-in-out;
}
.hamburger .line:nth-child(1) { top: 0; }
.hamburger .line:nth-child(2) { top: 10px; }
.hamburger .line:nth-child(3) { top: 20px; }

.hamburger.open .line:nth-child(1) { transform: rotate(45deg) translate(7px, 7px); }
.hamburger.open .line:nth-child(2) { opacity: 0; }
.hamburger.open .line:nth-child(3) { transform: rotate(-45deg) translate(7px, -7px); }


/* --- Estilos de Páginas Específicas --- */

/* Página de Proyectos */
.project-card {
  display: block;
  background-color: #FFFFFF; /* light-card */
  border-radius: 0.75rem;
  box-shadow: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
  overflow: hidden;
  transition: all 0.3s ease;
}
.dark .project-card { background-color: #1A202C; /* dark-card */ }
.project-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -2px rgb(0 0 0 / 0.05);
}
.project-card .tag {
  font-size: 0.75rem;
  font-weight: 600;
  background-color: rgba(0, 124, 240, 0.1); /* primary/10 */
  color: #007CF0; /* primary */
  padding: 0.25rem 0.75rem;
  border-radius: 9999px;
}
.dark .project-card .tag {
    background-color: rgba(0, 223, 216, 0.1); /* secondary/10 */
    color: #00DFD8; /* secondary */
}

/* Página de Contacto */
.contact-input {
  width: 100%;
  padding: 0.9rem 1rem;
  color: inherit;
  background-color: #f5f7fa;
  border: 1px solid #e5e7eb;
  border-radius: 0.5rem;
  transition: all 0.3s;
}
.dark .contact-input {
  background-color: #0B1120;
  border-color: #262626;
}
.contact-input:focus {
  outline: none;
  border-color: #007CF0;
  box-shadow: 0 0 0 2px rgba(0, 124, 240, 0.2);
}

.contact-link {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem;
  background-color: #FFFFFF;
  border-radius: 0.75rem;
  transition: all 0.3s ease;
  box-shadow: 0 1px 3px 0 rgb(0 0 0 / 0.05);
}
.dark .contact-link { background-color: #1A202C; }
.contact-link:hover {
  transform: translateY(-4px);
  box-shadow: 0 4px 10px 0 rgb(0 0 0 / 0.07);
}


/* --- ESTILOS DEFINITIVOS PARA EL TIMELINE --- */

.timeline-container {
  position: relative;
  max-width: 48rem; /* max-w-3xl */
  margin: 0 auto;
}

/* La línea vertical, ahora creada con CSS para no interferir */
.timeline-container::before {
  content: '';
  position: absolute;
  top: 0;
  left: 1.5rem;
  width: 2px;
  height: 100%;
  background-color: rgba(0, 124, 240, 0.2); /* primary/20 */
}

.timeline-item-redesigned {
  position: relative;
  padding-left: 3.5rem;
  padding-bottom: 3rem;
}

.timeline-dot-redesigned {
  position: absolute;
  left: 1.5rem;
  top: 0.5rem;
  width: 1rem;
  height: 1rem;
  background-color: #007CF0; /* primary */
  border-radius: 50%;
  border: 3px solid #F5F7FA; /* light-bg */
  transform: translateX(-50%);
}
.dark .timeline-dot-redesigned {
  border-color: #0B1120; /* dark-bg */
}

/* --- Estilos del Timeline para Escritorio (más de 768px) --- */
@media (min-width: 768px) {
  .timeline-container::before {
    left: 50%;
  }

  .timeline-item-redesigned {
    width: 50%;
    padding-left: 0; /* Reseteo de padding móvil */
  }
  
  /* Items IMPARES (1, 3...) a la IZQUIERDA */
  .timeline-item-redesigned:nth-child(odd) {
    text-align: right;
    padding-right: 2.5rem;
  }

  /* Items PARES (2, 4...) a la DERECHA */
  .timeline-item-redesigned:nth-child(even) {
    left: 50%;
    text-align: left;
    padding-left: 2.5rem;
    padding-right: 0;
  }

  /* El punto siempre va en el centro */
  .timeline-dot-redesigned {
    left: 50%;
    transform: translateX(-50%);
  }
}

.skill-card-container {
  background-color: #FFFFFF;
  border-radius: 0.75rem;
  padding: 1.5rem;
  border: 1px solid #e5e7eb;
  transition: all 0.3s ease;
}
.dark .skill-card-container {
  background-color: #1A202C;
  border-color: #262626;
}
.skill-card-container:hover {
  transform: translateY(-5px);
  border-color: rgba(0, 124, 240, 0.4);
  box-shadow: 0 10px 15px -3px rgb(0 0 0 / 0.05);
}

.skill-card-header {
  margin-bottom: 1rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid #e5e7eb;
}
.dark .skill-card-header {
    border-color: #262626;
}

.skill-list {
  list-style-type: none;
  padding-left: 0;
}
.skill-list li {
  color: #4b5563;
  margin-bottom: 0.5rem;
  padding-left: 1.5rem;
  position: relative;
}
.dark .skill-list li { color: #d1d5db; }

.skill-list li::before {
  content: '✓';
  position: absolute;
  left: 0;
  color: #007CF0;
  font-weight: 600;
}

/* --- NUEVO: Estilo para la fuente del título --- */
.font-serif-italic {
  font-family: 'Playfair Display', serif;
  font-weight: 500; /* Ajusta el grosor si es necesario */
  font-style: italic;
}