/* Raíz y Pulso — estilos del sitio (V1)
   Tokens de color y tipografía al principio; el resto usa solo variables. */

@font-face {
  font-family: "Poppins";
  src: url("/assets/fonts/poppins-400-v1.woff") format("woff");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Poppins";
  src: url("/assets/fonts/poppins-500-v1.woff") format("woff");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Poppins";
  src: url("/assets/fonts/poppins-700-v1.woff") format("woff");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

:root {
  /* Paleta de marca */
  --verde-raiz: #0F5132;
  --verde-teal: #2CA58D;
  --azul-pulso: #1E6FA8;
  --amarillo-sol: #F2C14E;
  --azul-claro: #DDEAF2;
  --verde-colina: #3A8F66;

  /* Neutros */
  --base: #FBFBF8;
  --tinta: #17261F;
  --tinta-suave: #4B5B53;
  --linea: #D9DFDB;
  --azul-claro-suave: #ECF3F7;
  --verde-raiz-hondo: #0B3F27;

  /* Tipografía */
  --font: "Poppins", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --step--1: 0.875rem;
  --step-0: 1.0625rem;
  --step-1: 1.25rem;
  --step-2: clamp(1.5rem, 1.2rem + 1.2vw, 1.875rem);
  --step-3: clamp(1.875rem, 1.4rem + 2vw, 2.75rem);
  --step-4: clamp(2.375rem, 1.5rem + 3.6vw, 4.25rem);
  --step-5: clamp(3.5rem, 2rem + 7vw, 7.5rem);

  /* Espacio */
  --gutter: clamp(1rem, 0.6rem + 2vw, 2.5rem);
  --section: clamp(4.5rem, 3rem + 6vw, 8.5rem);
  --wrap: 75rem;
  --radius: 999px;
}

*,
*::before,
*::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: 5.5rem;
}

body {
  margin: 0;
  background: var(--base);
  color: var(--tinta);
  font-family: var(--font);
  font-size: var(--step-0);
  line-height: 1.65;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img, svg { display: block; max-width: 100%; }

h1, h2, h3 {
  margin: 0;
  font-weight: 500;
  line-height: 1.15;
  letter-spacing: -0.02em;
  color: var(--verde-raiz);
  text-wrap: balance;
}
h2 { font-size: var(--step-3); }
h3 { font-size: var(--step-1); letter-spacing: -0.01em; }
p { margin: 0; text-wrap: pretty; }
ul, ol { margin: 0; padding: 0; list-style: none; }

a { color: var(--azul-pulso); text-decoration-thickness: 1px; text-underline-offset: 0.18em; }
a:hover { color: var(--verde-raiz); }

:focus-visible {
  outline: 3px solid var(--azul-pulso);
  outline-offset: 3px;
  border-radius: 4px;
}

.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  margin: -1px; padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: absolute;
  left: 1rem; top: -4rem;
  z-index: 100;
  padding: 0.6rem 1rem;
  background: var(--verde-raiz);
  color: #fff;
  border-radius: 6px;
  text-decoration: none;
}
.skip-link:focus { top: 1rem; color: #fff; }

/* ---------- Botones ---------- */

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 3rem;
  padding: 0.7rem 1.6rem;
  border: 2px solid var(--verde-raiz);
  border-radius: var(--radius);
  background: var(--verde-raiz);
  color: #fff;
  font: 500 1rem/1.2 var(--font);
  text-decoration: none;
  cursor: pointer;
  transition: background-color 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}
.button:hover { background: var(--verde-raiz-hondo); border-color: var(--verde-raiz-hondo); color: #fff; }
.button--ghost { background: transparent; color: var(--verde-raiz); }
.button--ghost:hover { background: var(--verde-raiz); color: #fff; }

/* ---------- Cabecera ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgb(251 251 248 / 0.92);
  backdrop-filter: saturate(1.4) blur(10px);
  -webkit-backdrop-filter: saturate(1.4) blur(10px);
  border-bottom: 1px solid var(--linea);
}
.site-header__inner {
  display: flex;
  align-items: center;
  gap: 2rem;
  min-height: 4.5rem;
}
.brand img { height: 2.75rem; width: auto; }
.site-nav { margin-left: auto; }
.site-nav ul { display: flex; gap: 2rem; }
.site-nav a,
.header-cta {
  color: var(--tinta);
  font-size: 0.9375rem;
  font-weight: 500;
  text-decoration: none;
}
.site-nav a:hover { color: var(--verde-raiz); text-decoration: underline; }
.header-cta {
  padding: 0.5rem 1.15rem;
  border: 1.5px solid var(--verde-raiz);
  border-radius: var(--radius);
  color: var(--verde-raiz);
}
.header-cta:hover { background: var(--verde-raiz); color: #fff; }

@media (max-width: 52rem) {
  .site-nav { display: none; }
  .header-cta { margin-left: auto; }
  .brand img { height: 2.25rem; }
  .site-header__inner { min-height: 4rem; }
}

/* ---------- Hero ---------- */

.hero {
  position: relative;
  overflow: hidden;
  padding-top: clamp(3.5rem, 2rem + 6vw, 7rem);
  padding-bottom: calc(clamp(16rem, 8rem + 22vw, 32rem) * 0.62);
}
.hero__inner {
  position: relative;
  z-index: 1;
}
.hero__title {
  max-width: 15ch;
  font-size: var(--step-4);
  line-height: 1.06;
  letter-spacing: -0.03em;
}
.hero__lead {
  max-width: 34rem;
  margin-top: clamp(1.25rem, 1rem + 1vw, 2rem);
  font-size: var(--step-1);
  line-height: 1.6;
  color: var(--tinta-suave);
}
.hero__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem 1.5rem;
  margin-top: 2.25rem;
}
.hero__mail {
  color: var(--tinta-suave);
  font-size: 0.9375rem;
  text-decoration: none;
}
.hero__mail:hover { color: var(--verde-raiz); text-decoration: underline; }

/* Paisaje: Teide, valle y camino */
.horizon {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  width: 100%;
  height: clamp(16rem, 8rem + 22vw, 32rem);
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.horizon__mass { fill: #EAF1EC; stroke: none; }
.horizon__ridge { stroke: var(--verde-raiz); stroke-width: 2; vector-effect: non-scaling-stroke; }
.horizon__hill { stroke: var(--verde-colina); stroke-width: 1.5; opacity: 0.6; vector-effect: non-scaling-stroke; }
.horizon__path { fill: url(#camino-fade); }

/* Un único momento animado: el perfil se dibuja y aparece el camino */
.horizon__ridge { stroke-dasharray: 1; animation: draw 1.6s cubic-bezier(.45,.05,.25,1) 0.2s both; }
.horizon__mass { animation: appear 1.2s ease 0.9s both; }
.horizon__path { animation: appear 0.9s ease 1.5s both; }
@keyframes draw { from { stroke-dashoffset: 1; } to { stroke-dashoffset: 0; } }
@keyframes appear { from { opacity: 0; } to { opacity: 1; } }

@media (max-width: 60rem) {
  .hero { padding-bottom: 0; }
  .horizon { position: static; height: 15rem; margin-top: 2.5rem; }
}

/* ---------- Secciones ---------- */

.section { padding-block: var(--section); }
.section__head {
  display: grid;
  gap: 1rem;
  max-width: 46rem;
  margin-bottom: clamp(2.5rem, 2rem + 2vw, 4rem);
}
.section__intro { font-size: var(--step-1); line-height: 1.6; color: var(--tinta-suave); }

/* Raíz / Pulso */
.about { padding-top: clamp(3rem, 2rem + 4vw, 5.5rem); }
.pair {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(2rem, 1rem + 4vw, 5rem);
}
.pair__word {
  font-size: var(--step-5);
  font-weight: 500;
  line-height: 0.95;
  letter-spacing: -0.045em;
}
.pair__item--raiz .pair__word { color: var(--verde-raiz); }
.pair__item--pulso .pair__word { color: var(--azul-pulso); }
.pair__text {
  max-width: 26rem;
  margin-top: 1.25rem;
  font-size: var(--step-1);
  line-height: 1.55;
}
.about__note {
  max-width: 44rem;
  margin-top: clamp(3rem, 2rem + 3vw, 4.5rem);
  padding-top: 1.75rem;
  border-top: 1px solid var(--linea);
  color: var(--tinta-suave);
}

@media (max-width: 40rem) {
  .pair { grid-template-columns: 1fr; }
}

/* Qué hacemos */
.areas { padding-top: 0; }
.areas__list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(2rem, 1.5rem + 2vw, 3.5rem) clamp(2rem, 1rem + 4vw, 5rem);
}
.area {
  padding-top: 1.5rem;
  border-top: 2px solid var(--verde-raiz);
}
.area__title { margin-bottom: 0.75rem; }
.area p { max-width: 32rem; color: var(--tinta-suave); }

.partners {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.75rem 2.5rem;
  margin-top: clamp(3.5rem, 2.5rem + 3vw, 5.5rem);
  padding: 1.5rem clamp(1.25rem, 1rem + 1.5vw, 2rem);
  background: var(--azul-claro-suave);
  border-radius: 1rem;
}
.partners__title {
  font-size: var(--step-0);
  font-weight: 500;
  letter-spacing: 0;
  color: var(--tinta);
}
.partners__list { display: flex; flex-wrap: wrap; gap: 0.5rem 1.75rem; }
.partners__list li { color: var(--verde-raiz); font-weight: 500; }

@media (max-width: 48rem) {
  .areas__list { grid-template-columns: 1fr; }
  .partners { flex-direction: column; align-items: flex-start; }
  .partners__list { flex-direction: column; gap: 0.35rem; }
}

/* Cómo trabajamos */
.method {
  background: var(--verde-raiz);
  color: #E9F1EC;
}
.method h2,
.method h3 { color: #fff; }
.method .section__intro { color: #CFE0D6; }
.steps {
  position: relative;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: clamp(1.5rem, 1rem + 2vw, 3rem);
  counter-reset: step;
}
/* el camino que une los pasos */
.steps::before {
  content: "";
  position: absolute;
  top: 1.5rem;
  left: 1.5rem;
  right: 0;
  height: 2px;
  background: var(--verde-teal);
}
.step { position: relative; }
.step__num {
  position: relative;
  display: grid;
  place-items: center;
  width: 3rem;
  height: 3rem;
  margin-bottom: 1.5rem;
  border-radius: 50%;
  background: var(--amarillo-sol);
  color: var(--verde-raiz);
  font-weight: 700;
  font-size: 1.125rem;
}
.step__title { margin-bottom: 0.6rem; }
.step p { color: #CFE0D6; }
.method__note {
  max-width: 46rem;
  margin-top: clamp(3rem, 2rem + 3vw, 4.5rem);
  padding-top: 1.75rem;
  border-top: 1px solid rgb(255 255 255 / 0.2);
  color: #fff;
  font-size: var(--step-1);
  line-height: 1.55;
}

@media (max-width: 60rem) {
  .steps { grid-template-columns: 1fr 1fr; }
  .steps::before { display: none; }
}
@media (max-width: 40rem) {
  .steps { grid-template-columns: 1fr; gap: 2.25rem; }
  .steps::before {
    display: block;
    top: 1.5rem; bottom: 1.5rem;
    left: calc(1.5rem - 1px); right: auto;
    width: 2px; height: auto;
  }
  .step { padding-left: 4.5rem; }
  .step__num { position: absolute; left: 0; top: 0; margin: 0; }
  .step__title { padding-top: 0.6rem; }
}

/* Equipo */
.team__list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(2rem, 1rem + 3vw, 3.5rem);
}
.member {
  padding-top: 1.5rem;
  border-top: 2px solid var(--verde-raiz);
}
.member picture { display: block; }
.member__photo {
  width: 100%;
  height: auto;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  margin-bottom: 1.5rem;
  border-radius: 1rem;
  background: var(--azul-claro-suave);
}
.member:has(.member__photo) { border-top: 0; padding-top: 0; }
.member__name { font-size: var(--step-2); line-height: 1.2; }
.member__role {
  margin-top: 0.6rem;
  color: var(--azul-pulso);
  font-weight: 500;
}
.member__area {
  margin-top: 0.15rem;
  color: var(--tinta-suave);
  font-size: 0.9375rem;
  font-weight: 500;
}
.member__bio { margin-top: 1rem; color: var(--tinta-suave); }

/* Tablet: foto a la izquierda, texto a la derecha */
@media (max-width: 56rem) {
  .team__list { grid-template-columns: 1fr; gap: 3rem; }
  .member:has(.member__photo) {
    display: grid;
    grid-template-columns: minmax(0, 15rem) minmax(0, 1fr);
    gap: 2rem;
    align-items: start;
  }
  .member .member__photo { margin-bottom: 0; }
  .member__bio { max-width: 34rem; }
}
/* Móvil: una columna */
@media (max-width: 34rem) {
  .member:has(.member__photo) { display: block; }
  .member .member__photo { margin-bottom: 1.25rem; }
}

/* Contacto */
.contact {
  padding-block: var(--section);
  background: var(--azul-claro);
}
.contact__inner {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr);
  gap: 2.5rem clamp(2rem, 1rem + 4vw, 5rem);
  align-items: end;
}
.contact__title { max-width: 14ch; font-size: var(--step-4); line-height: 1.08; letter-spacing: -0.03em; }
.contact__text { font-size: var(--step-1); line-height: 1.55; color: var(--tinta); }
@media (max-width: 56rem) {
  .contact__inner { grid-template-columns: 1fr; }
}
.contact__mail {
  display: inline-block;
  margin-top: 0.75rem;
  color: var(--azul-pulso);
  font-size: var(--step-3);
  font-weight: 500;
  letter-spacing: -0.02em;
  text-decoration: none;
  overflow-wrap: anywhere;
}
.contact__mail:hover { color: var(--verde-raiz); text-decoration: underline; text-decoration-thickness: 2px; }
.contact__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem 1rem;
  margin-top: 2rem;
}
.copy-status { min-height: 1.5em; margin-top: 0.75rem; font-size: 0.9375rem; color: var(--verde-raiz); font-weight: 500; }

@media (max-width: 30rem) {
  .contact__actions .button { width: 100%; }
}

/* ---------- Pie ---------- */

.site-footer {
  padding-block: clamp(3rem, 2rem + 3vw, 4.5rem);
  background: var(--verde-raiz-hondo);
  color: #CFE0D6;
  font-size: 0.9375rem;
}
.site-footer__inner {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 2rem 4rem;
  align-items: start;
}
.site-footer__logo { width: 16.25rem; height: auto; }
.site-footer__tagline {
  margin-top: 1rem;
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: #CFE0D6;
}
.site-footer__info { display: grid; gap: 1rem; justify-items: start; max-width: 32rem; margin-left: auto; }
.site-footer a { color: #fff; }
.site-footer a:hover { color: var(--amarillo-sol); }
.site-footer__legal {
  grid-column: 1 / -1;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.75rem;
  padding-top: 1.5rem;
  border-top: 1px solid rgb(255 255 255 / 0.15);
}
.site-footer__legal span { margin-left: auto; }

@media (max-width: 48rem) {
  .site-footer__inner { grid-template-columns: 1fr; }
  .site-footer__info { margin-left: 0; }
  .site-footer__logo { width: 13.75rem; }
  .site-footer__legal span { margin-left: 0; width: 100%; }
}

/* ---------- Páginas legales ---------- */

.legal { padding-block: clamp(3rem, 2rem + 4vw, 6rem); }
.legal__body { max-width: 44rem; }
.legal h1 { font-size: var(--step-4); line-height: 1.08; letter-spacing: -0.03em; }
.legal__updated { margin-top: 1rem; color: var(--tinta-suave); font-size: var(--step--1); }
.legal h2 { margin-top: 3rem; margin-bottom: 1rem; font-size: var(--step-2); }
.legal p + p,
.legal p + ul,
.legal ul + p { margin-top: 1rem; }
.legal ul { display: grid; gap: 0.5rem; }
.legal li { padding-left: 1.25rem; position: relative; }
.legal li::before {
  content: "";
  position: absolute;
  left: 0; top: 0.75em;
  width: 0.4rem; height: 0.4rem;
  border-radius: 50%;
  background: var(--verde-teal);
}
.legal dl { display: grid; grid-template-columns: max-content 1fr; gap: 0.6rem 1.5rem; margin: 0; }
.legal dt { font-weight: 500; color: var(--verde-raiz); }
.legal dl + p { margin-top: 1.5rem; }
.legal dd { margin: 0; }
@media (max-width: 36rem) {
  .legal dl { grid-template-columns: 1fr; gap: 0.15rem; }
  .legal dd { margin-bottom: 0.75rem; }
}

/* 404 */
.not-found { padding-block: clamp(5rem, 3rem + 8vw, 10rem); }
.not-found h1 { font-size: var(--step-4); max-width: 16ch; }
.not-found p { margin-top: 1.25rem; font-size: var(--step-1); color: var(--tinta-suave); }
.not-found .button { margin-top: 2rem; }

/* ---------- Movimiento reducido ---------- */

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
