/* Variables de diseño */
:root {
  /* Tipografías */
  --font-title: 'Clash Display', sans-serif;
  --font-paragraph: 'General Sans', sans-serif;

  /* COLORES */

  /* Primary */
  --color-primary-900: #23211F;
  --color-primary-800: #55504C;
  --color-primary-700: #857F79;
  --color-primary-600: #B5AEA7;
  --color-primary-500: #E4DDD6;
  --color-primary-400: #EFE9E2;
  --color-primary-300: #F4EEE9;
  --color-primary-200: #F8F4F0;
  --color-primary-100: #FEFDFB;

  /* Secondary */
  --color-secondary-900: #000026;
  --color-secondary-800: #00005C;
  --color-secondary-700: #010093;
  --color-secondary-600: #1100C9;
  --color-secondary-500: #2A00F6;
  --color-secondary-400: #5D57FF;
  --color-secondary-300: #8282FF;
  --color-secondary-200: #ADADFF;
  --color-secondary-100: #D9D9FF;

  /* Tertiary */
  --color-tertiary-900: #260019;
  --color-tertiary-800: #5C003C;
  --color-tertiary-700: #93035E;
  --color-tertiary-600: #C91780;
  --color-tertiary-500: #FB36A0;
  --color-tertiary-400: #FF60C2;
  --color-tertiary-300: #FF82D3;
  --color-tertiary-200: #FFADE3;
  --color-tertiary-100: #FFD9F2;

  /* Tamaños de texto */
  --title-48: 3rem;
  --title-40: 2.5rem;
  --title-32: 2rem;
  --title-24: 1.5rem;
  --title-16: 1rem;

  --paragraph-20: 1.25rem;
  --paragraph-16: 1rem;
  --paragraph-14: 0.875rem;
  --paragraph-12: 0.75rem;
  --paragraph-10: 0.625rem;
}


/* Reset básico */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: "General Sans", sans-serif;
  background-color: var(--color-primary-100);
  color: var(--color-primary-900);
  padding: 2rem;
}

/* ======== HEADER ======== */
body {
    margin: 0;
    font-family: var(--font-paragraph);
    background-color: var(--color-primary-100);
    color: var(--color-primary-900);
    padding: 2rem;
}

/* === HEADER === */
header {
  display: flex;
  justify-content: space-between; /* logo izquierda, menú derecha */
  align-items: center;
  padding: 32px 64px; /* margen top/bottom = 32px, laterales = 64px */
  width: 100%;
  box-sizing: border-box; /* evita que el padding rompa el layout */
}

/* === LOGO === */
.logo {
  font-family: var(--font-paragraph);
  font-size: var(--paragraph-20);
  color: var(--color-tertiary-400);
}

/* === NAVIGATION === */
nav ul {
  list-style: none;
  display: flex;
  gap: 32px; /* espaciado horizontal */
  margin: 0;
  padding: 0;
}

nav a {
  font-family: var(--font-title);
  font-size: var(--title-16);
  color: var(--color-primary-600);
  text-decoration: none;
  transition: all 0.2s ease-in-out;
}

nav a:hover {
  color: var(--color-primary-800);
}

nav a.active {
  color: var(--color-primary-800);
  text-decoration: underline;
  text-underline-offset: 6px;
}

/* === RESPONSIVE (<550px) === */
@media (max-width: 550px) {
  header {
    flex-direction: column; /* apila logo arriba y menú abajo */
    align-items: center;
    padding: 40px 20px;
  }

  .logo {
    text-align: center;
    margin-bottom: 20px;
  }

  nav ul {
    flex-direction: row;
    overflow-x: auto; /* 🔹 scroll horizontal */
    gap: 24px;
    padding-bottom: 8px;
    scrollbar-width: none; /* oculta barra en Firefox */
  }

  nav ul::-webkit-scrollbar {
    display: none; /* oculta barra en Chrome/Safari */
  }
}

/* Intro general */
.intro {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start; /* texto alineado a la izquierda */
  padding: 120px 0;
  max-width: 1200px;
  margin: 0 auto;
  position: relative;
}


/* Línea con iconos + texto */
/* H1 normal, sin flex */
.intro__title {
  font-family: var(--font-title);
  font-size: 36px;
  font-weight: 400;
  color: var(--color-secondary-900);
  line-height: 1.6;
  margin-bottom: 24px;
}

/* Iconos integrados en el texto */
.inline-icon {
  width: 56px;
  height: auto;
  display: inline-block;
  vertical-align: middle; /* ALINEACIÓN perfecta con el texto */
  margin: 0 8px;
}

/* Contenedor general */
.intro__container {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  margin-left: 80px;
  max-width: 700px;
}

/* Texto principal */
.intro__text h1 {
  font-family: var(--font-title);
  font-size: 36px;
  font-weight: 400;
  color: var(--color-secondary-900);
  margin-bottom: 24px;
  line-height: 1.3;
}

/* Color destacado */
.highlight {
  color: var(--color-secondary-500);
  font-weight: 500;
}


/* Botón centrado */
.intro__button {
  position: absolute;
  left: 50%;
  bottom: -40px;
  transform: translateX(-50%);
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

/* Botón circular con borde */
.scroll-btn {
  width: 64px;
  height: 64px;
  border: 2px solid var(--color-primary-900);
  border-radius: 50%;
  background: transparent;
  color: var(--color-primary-900);
  display: flex;
  justify-content: center;
  align-items: center;
  cursor: pointer;
  transition: all 0.3s ease;
}

.scroll-btn:hover {
    background: var(--color-tertiary-100);
    transform: translateY(-2px);
}

.intro__button span {
  font-family: var(--font-paragraph);
  font-size: 16px;
  color: var(--color-secondary-900);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* ======== PROYECTOS ======== */
.projects {
  display: flex;
  flex-direction: column;
  gap: 88px; /* separación entre cards */
  max-width: 1600px;
  margin: 0 auto 200px auto;
  padding: 0 24px;
  margin-top: 120px;
  width: 95%;
}

.project {
  display: flex;
  flex-direction: row;
  align-items: left;
  gap: 48px;
}

.img-container img {
  width: 720px;
  height: 520px;
  object-fit: cover;
  border-radius: 8px;
  box-shadow: 0 8px 16px rgba(0,0,0,0.05);
  margin-bottom: 32px;
}

/* ======== INFO DE CADA PROYECTO ======== */
.project-card {
  max-width: 600px;
  margin: 2rem auto;
  color: #111;
  font-family: 'General Sans', sans-serif;
  background: transparent;
}

.project-tag {
  display: inline-block;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  font-weight: 500;
  color: #111;
  background-color: #f3f3f3;
  padding: 0.4rem 0.8rem;
  border-radius: 2rem;
  margin-bottom: 1rem;
}

.project-title {
   font-family: var(--font-title);
  font-size: 1.75rem;
  font-weight: 500;
  color: var(--color-primary-900);
    line-height: 1.4;
    margin: 0.5rem 0 1rem;
}

.project-description {
  color: var(--color-primary-900);
  font-size: 1rem;
  line-height: 1.6;
  margin-bottom: 1.5rem;
  max-width: 90%;
}

.project-link {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-weight: 600;
  color: #000;
  text-decoration: none;
  transition: all 0.2s ease-in-out;
}

.project-link .arrow {
  transition: transform 0.2s ease;
}

.project-link:hover {
  color: var(--color-tertiary-500);
  transform: scale(0.97); /* se reduce un poco al hover */
}

.project-link:hover .arrow {
  transform: translateX(4px);
}

/* Invertir proyecto en desktop */
.project.reverse {
  flex-direction: row-reverse; /* imagen a la derecha, texto a la izquierda */
  text-align: right;
}

/* En móvil se mantiene columna, para que todo se vea bien */
@media (max-width: 768px) {
  .project.reverse {
    flex-direction: column;
    text-align: center; /* centrar texto en móvil */
  }
}


/* ======== RESPONSIVE ======== */
@media (max-width: 768px) {
  .intro {
    margin: 80px auto;
    text-align: center;
    align-items: center;
  }

  .projects {
    gap: 64px;
  }

  .img-container img {
    width: 100%;
    height: auto;
  }

  .project__info {
    max-width: 100%;
  }
}

/* ---------- FOOTER ---------- */
footer {
  text-align: center;
  background-color: var(--color-tertiary-100);
  padding: 2rem;
  border-radius: 0.5rem;
}

.footer-links {
  display: flex;
  justify-content: center;
  gap: 4rem;
  margin-bottom: 0.5rem;
}

.footer-links a {
  text-decoration: none;
  color:var(--color-primary-800);
  font-family: var(--font-title);
  font-size: var(--title-24);
  text-transform: uppercase;
}

footer p {
  color:var(--color-primary-800);
  font-family: var(--font-paragraph);
  font-size: var(--paragraph-14);
}

/* ===== Proyecto individual ===== */
.project-detail {
  max-width: 1200px;
  margin: 120px auto;
  padding: 0 24px;
}

.project-detail h1 {
  font-family: var(--font-title);
  font-size: var(--title-40);
  margin-bottom: 16px;
  color: var(--color-secondary-900);
}

.project-detail .project-meta {
  font-family: var(--font-paragraph);
  font-size: var(--paragraph-16);
  color: var(--color-primary-700);
  margin-bottom: 48px;
}

.project-detail .project-images img {
  width: 100%;
  height: auto;
  border-radius: 8px;
  margin-bottom: 32px;
}

.project-detail .project-description h2 {
  font-family: var(--font-title);
  font-size: var(--title-32);
  margin-bottom: 16px;
}

.project-detail .project-description p {
  font-family: var(--font-paragraph);
  font-size: var(--paragraph-16);
  line-height: 1.8;
  color: var(--color-primary-800);
  margin-bottom: 24px;
}
