/* ============================
   ESTILOS PRINCIPALES - CLARA MONTAÑO
============================ */

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: 'Inter', sans-serif;
  background: #0f172a;
  color: #e2e8f0;
  line-height: 1.6;
}

/* ======== HEADER ======== */
header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(15, 23, 42, 0.9);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

nav {
  max-width: 1100px;
  margin: auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem;
}

nav a {
  color: #cbd5e1;
  text-decoration: none;
  margin-left: 1rem;
  transition: color 0.3s;
}

nav a:hover {
  color: #2dd4bf;
}

/* ======== HERO ======== */
.hero {
  max-width: 1100px;
  margin: auto;
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: 2rem;
  padding: 5rem 1rem;
}

.hero-text h1 {
  font-size: 2.5rem;
  font-weight: 700;
  color: #f8fafc;
}

.hero-text h1 span {
  color: #2dd4bf;
}

.hero-text p {
  margin-top: 1rem;
  color: #94a3b8;
}

.btns a {
  display: inline-block;
  margin-top: 1.5rem;
  margin-right: 1rem;
  padding: 0.75rem 1.5rem;
  border: 1px solid #2dd4bf;
  border-radius: 0.75rem;
  color: #2dd4bf;
  text-decoration: none;
  transition: background 0.3s;
}

.btns a:hover {
  background: #2dd4bf20;
}

.portrait img {
  width: 100%;
  border-radius: 1.5rem;
  filter: grayscale(20%);
}

/* ======== SECCIONES ======== */
section {
  max-width: 1100px;
  margin: auto;
  padding: 4rem 1rem;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
}

h2 {
  font-size: 1.8rem;
  font-weight: 600;
  margin-bottom: 1.5rem;
}

.about p {
  color: #94a3b8;
  margin-bottom: 1rem;
}

/* ======== HABILIDADES ======== */
.skills-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 1rem;
}

.skill {
  background: #1e293b;
  border-radius: 1rem;
  text-align: center;
  border: 1px solid rgba(255, 255, 255, 0.1);
  transition: all 0.3s ease;
  height: 70px;
  display: flex;
  justify-content: center;
  align-items: center;
}

.skill button {
  background: transparent;
  border: none;
  color: #e2e8f0;
  font-size: 16px;
  font-weight: 600;
  font-family: 'Inter', sans-serif;
  cursor: pointer;
  width: 100%;
  height: 100%;
  border-radius: 1rem;
  transition: all 0.3s ease;
}

.skill:hover {
  background-color: #2dd4bf;
  box-shadow: 0 0 25px #2dd4bf80, 0 0 40px #2dd4bf40;
  transform: translateY(-3px);
}

.skill:hover button {
  color: #0f172a;
}

/* ======== PROYECTOS & BLOG ======== */
.projects,
.blog {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.5rem;
}

/* Tarjeta de proyecto */
.card {
  display: block; /* 💡 importante: permite usar <a> como bloque */
  background: #1e293b;
  border-radius: 1rem;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.1);
  transition: transform 0.3s, box-shadow 0.3s;
  text-decoration: none;
  color: inherit;
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: 0 0 20px rgba(45, 212, 191, 0.25);
}

.card img {
  width: 100%;
  height: 180px;
  object-fit: cover;
  display: block;
}

.card-content {
  padding: 1rem;
}

.card-content h3 {
  color: #f8fafc;
  margin-bottom: 0.5rem;
}

.card-content p {
  color: #94a3b8;
  font-size: 0.9rem;
}

/* ======== FORMULARIO ======== */
form {
  display: grid;
  gap: 1rem;
}

input,
textarea {
  background: #1e293b;
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #f1f5f9;
  padding: 0.75rem;
  border-radius: 0.75rem;
}

button {
  background: #2dd4bf;
  color: #0f172a;
  font-weight: 600;
  border: none;
  padding: 0.75rem;
  border-radius: 0.75rem;
  cursor: pointer;
  transition: background 0.3s;
}

button:hover {
  background: #14b8a6;
}

/* ======== FOOTER ======== */
footer {
  text-align: center;
  color: #ffffff;
  padding: 2rem;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  margin-top: 3rem;
}
/* ======== LÍNEA DEL TIEMPO ======== */
.timeline {
  position: relative;
  padding: 2rem 0;
}

.timeline h2 {
  text-align: left;
  color: #f8fafc;
  margin-bottom: 2rem;
}

.timeline-line {
  position: relative;
  margin-left: 2rem;
  border-left: 2px solid rgba(255, 255, 255, 0.1);
  padding-left: 2rem;
}

.timeline-item {
  position: relative;
  margin-bottom: 2rem;
}

.timeline-item::before {
  content: "";
  position: absolute;
  left: -1.1rem;
  top: 0.3rem;
  width: 14px;
  height: 14px;
  background-color: #2dd4bf;
  border-radius: 50%;
  box-shadow: 0 0 10px #2dd4bf80;
}

.timeline-date {
  font-weight: 600;
  color: #2dd4bf;
  font-size: 0.9rem;
}

.timeline-content {
  margin-top: 0.3rem;
  background: #1e293b;
  padding: 1rem;
  border-radius: 1rem;
  border: 1px solid rgba(255, 255, 255, 0.05);
  transition: transform 0.3s ease;
}

.timeline-content:hover {
  transform: translateY(-3px);
  box-shadow: 0 0 15px rgba(45, 212, 191, 0.25);
}

.timeline-content h3 {
  color: #f1f5f9;
  font-size: 1.1rem;
  margin-bottom: 0.5rem;
}

.timeline-content span {
  color: #2dd4bf;
}

.timeline-content p {
  color: #94a3b8;
  font-size: 0.9rem;
}

.skills-list {
  margin-top: 0.75rem;
  list-style: none;
  opacity: 0;
  max-height: 0;
  overflow: hidden;
  transition: all 0.4s ease;
  padding-left: 1rem;
  border-left: 2px solid rgba(45, 212, 191, 0.3);
}

.skills-list li {
  color: #a5b4fc;
  font-size: 0.85rem;
  margin-bottom: 0.4rem;
  position: relative;
}

.skills-list li::before {
  content: "•";
  color: #2dd4bf;
  margin-right: 0.4rem;
}

/* Mostrar habilidades al hacer hover */
.timeline-content:hover .skills-list {
  opacity: 1;
  max-height: 200px; /* límite para transición suave */
}
/* ======== ANIMACIÓN HERO SIMPLE ======== */

/* Animaciones */
@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

@keyframes fadeInRight {
  from {
    opacity: 0;
    transform: translateX(60px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

/* Aplica el fade-in al texto */
.hero-text {
  opacity: 0;
  animation: fadeIn 1.5s ease forwards;
  animation-delay: 0.3s;
}

/* Aplica fade-in desde la derecha a la imagen */
.portrait img {
  opacity: 0;
  animation: fadeInRight 1.8s ease forwards;
  animation-delay: 0.8s;
}

/* =========================
   CONTACTO 
========================= */
#contact {
  max-width: 800px;
  margin: 5rem auto;
  text-align: left;
}

#contact h2 {
  text-align: center;
  margin-bottom: 2rem;
  color: #2dd4bf;
}

/* ✅ Dos columnas, 3 filas */
.contact-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  grid-template-columns: repeat(2, 1fr); /* dos columnas */
  gap: 1.2rem 3rem; /* separación entre filas y columnas */
  font-size: 1rem;
  color: #f8fafc;
}

.contact-list li {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.contact-list i {
  width: 22px;
  height: 22px;
  color: #2dd4bf;
  flex-shrink: 0;
  stroke-width: 2.2;
}

.contact-list a {
  color: #e2e8f0;
  text-decoration: underline;
  transition: color 0.3s ease;
}

.contact-list a:hover {
  color: #2dd4bf;
}

.web-note {
  color: #facc15;
  font-weight: 600;
  margin-left: 0.4rem;
}

/* Responsive: en pantallas pequeñas, vuelve a una sola columna */
@media (max-width: 650px) {
  .contact-list {
    grid-template-columns: 1fr;
  }
}