/* =====================================================================
   SORAIN – estilos base
   Compartidos por todas las páginas: variables, tipografía, botones, nav,
   hero, grulla 3D, CTA y footer, más las secciones propias del Home.

   Índice
     1. Variables
     2. Base y tipografía
     3. Botones y enlaces
     4. Íconos (Material Symbols)
     5. Grulla 3D (canvas y anclas)
     6. Navegación
     7. Hero
     8. Home: Who we are
     9. Home: What we do
    10. Home: Our philosophy
    11. Home: Our approach (loop)
    12. Home: Engineering experience
    13. CTA y logo final
    14. Footer
    15. Páginas pendientes
    16. Animación al hacer scroll
    17. Ajustes para español
    18. Responsive
   ===================================================================== */

/* 1. Variables
   --------------------------------------------------------------------- */
:root {
  --bg: #07071a;
  --bg-2: #0d1023;
  --bg-3: #0c0b22;
  --hero: #060822;
  --ink: #f3f1ff;
  --muted: #b4b2d1;
  --mute: #8582a8;
  --violet: #7b42d2;
  --violet-hi: #9145d2;
  --purple: #8b3dd9;
  --lav: #8b3dd9;
  --lilac: #b996f5;
  --blue: #475fd2;
  --line: rgba(185, 150, 245, 0.16);
  --font: Roboto, Inter, system-ui, -apple-system, 'Segoe UI', sans-serif;
  --font-head: Cabin, Roboto, system-ui, sans-serif;
  color-scheme: dark;
}

/* 2. Base y tipografía
   --------------------------------------------------------------------- */
* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  overflow-x: hidden;
  overflow-x: clip; /* clip no crea contenedor de scroll: la barra sticky sigue funcionando */
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.55;
  overflow-wrap: break-word; /* ninguna palabra larga (correos, URLs, palabras en español) se sale de su caja */
  -webkit-font-smoothing: antialiased;
}

/* Textos: párrafos sin palabras sueltas al final y títulos de tarjeta equilibrados */
p,
li {
  text-wrap: pretty;
}
h3 {
  text-wrap: balance;
}

a {
  color: inherit;
  text-decoration: none;
}

h1,
h2,
h3,
p {
  margin: 0;
}

h1,
h2,
h3,
.logo,
.step b {
  font-family: var(--font-head);
}

h1,
h2 {
  line-height: 1.08;
  letter-spacing: -0.05em;
  text-wrap: balance;
}

h2 {
  font-size: clamp(32px, 4.4vw, 52px);
  font-weight: 600;
}

.wrap {
  position: relative;
  z-index: 6;
  width: 100%;
  max-width: 1240px;
  margin-inline: auto;
  padding-left: max(16px, env(safe-area-inset-left, 0px));
  padding-right: max(16px, env(safe-area-inset-right, 0px));
}

.sec {
  position: relative;
  padding-block: 88px;
}

.eyebrow {
  margin-bottom: 18px;
  color: var(--lav);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.lead {
  max-width: 52ch;
  color: var(--muted);
}

/* 3. Botones y enlaces
   --------------------------------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 15px 26px;
  border-radius: 5px;
  background: linear-gradient(90deg, #8b3dd9, #466bdb);
  box-shadow: 0 8px 12px rgba(123, 66, 210, 0.45);
  color: #fff;
  font-size: 15px;
  font-weight: 600;
  white-space: nowrap;
  transition:
    background 0.2s,
    transform 0.2s;
}
.btn:hover {
  filter: brightness(1.12);
}

.btn.white {
  border-radius: 10px;
  background: #fff;
  box-shadow: none;
  color: #452d8b;
}
.btn.white:hover {
  background: #efe9ff;
}

.more {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 26px;
  color: var(--lav);
  font-size: 15px;
  font-weight: 500;
}

a:focus-visible,
button:focus-visible {
  outline: 2px solid var(--lav);
  outline-offset: 3px;
  border-radius: 6px;
}

/* 4. Íconos (Material Symbols)
   --------------------------------------------------------------------- */
.material-symbols-outlined {
  display: inline-block;
  flex: none;
  font-family: 'Material Symbols Outlined';
  font-size: 24px;
  font-style: normal;
  font-weight: normal;
  line-height: 1;
  letter-spacing: normal;
  text-transform: none;
  white-space: nowrap;
  direction: ltr;
  user-select: none;
  font-feature-settings: 'liga';
  font-variation-settings:
    'FILL' 0,
    'wght' 400,
    'GRAD' 0,
    'opsz' 24;
  -webkit-font-smoothing: antialiased;
}

.more .material-symbols-outlined,
.btn .material-symbols-outlined {
  font-size: 20px;
  transition: transform 0.2s;
}
.more:hover .material-symbols-outlined,
.btn:hover .material-symbols-outlined {
  transform: translateX(3px);
}

/* 5. Grulla 3D (canvas y anclas)
   La grulla se dibuja en un canvas fijo y vuela entre los elementos .anchor
   (main.js lee su posición, tamaño y data-pose).
   --------------------------------------------------------------------- */
#crane {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 5;
  pointer-events: none;
}

.anchor {
  position: absolute;
  top: calc(var(--cy) - var(--w) / 2);
  left: calc(50% + var(--cx) - var(--w) / 2);
  width: var(--w);
  height: var(--w);
  visibility: hidden;
  pointer-events: none;
}

/* Grulla del hero: grande y recortada por el borde derecho.
   Cada página puede moverla con --hx (centro horizontal), --hy (centro vertical) y --hw (tamaño). */
.anchor.hero {
  --hw: min(62vw, 860px);
  top: var(--hy, 50%);
  left: calc(50% + var(--hx, 41vw) - var(--hw) / 2);
  width: var(--hw);
  height: var(--hw);
  margin-top: calc(var(--hw) / -2);
}

/* 6. Navegación
   Logo a la izquierda · enlaces al centro · idioma y botón a la derecha.
   --------------------------------------------------------------------- */
.nav {
  position: sticky;
  top: env(safe-area-inset-top, 0px);
  z-index: 20;
  border-bottom: 1px solid var(--line);
  background: rgba(6, 8, 34, 0.85);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}

.nav .wrap {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  align-items: center;
  gap: 24px;
  height: 72px;
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 24px;
  font-weight: 700;
  letter-spacing: 0.04em;
}
.logo img {
  width: auto;
  max-width: none;
  height: 46px;
}
.nav .logo {
  justify-self: start;
}

.links {
  display: flex;
  font-size: 15px;
}
.nav .links {
  justify-self: center;
  gap: 44px;
  color: #fff;
}
.links a {
  padding: 6px 0;
  border-bottom: 2px solid transparent;
}
.nav .links a {
  font-weight: 500;
}
.nav .links a:hover {
  color: var(--purple);
}
.nav .links a.on {
  border-color: var(--purple);
  color: var(--purple);
}

.nav-right {
  display: flex;
  justify-self: end;
  align-items: center;
  gap: 24px;
}

.lang {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  font-size: 13px;
}
.lang b {
  color: #fff;
  font-weight: 700;
}
.lang span,
.lang a {
  color: var(--mute);
}
.lang a:hover {
  color: #fff;
}

.nav .btn {
  padding: 11px 20px;
  border: 2px solid var(--purple);
  border-radius: 5px;
  background: var(--hero);
  box-shadow: 0 0 11px rgba(165, 43, 235, 0.66);
}
.nav .btn:hover {
  background: rgba(139, 61, 217, 0.18);
  filter: none;
}

/* 7. Hero
   --------------------------------------------------------------------- */
.hero {
  overflow: hidden;
  padding-block: 72px 96px;
  background:
    radial-gradient(60% 80% at 82% 30%, rgba(69, 45, 139, 0.62), transparent 72%),
    radial-gradient(50% 60% at 0% 100%, rgba(71, 95, 210, 0.16), transparent 70%), var(--hero);
}

.hero .eyebrow {
  margin-bottom: 26px;
}

.hero h1 {
  font-size: clamp(38px, 4.5vw, 64px);
  font-weight: 600;
}

/* Segunda línea del título con degradado */
.hero h1 em {
  display: block;
  padding-bottom: 0.08em; /* alto automático: si el título baja a 2 líneas (móvil, español) no se recorta */
  background: linear-gradient(90deg, #c9a6ff, #7c8cf5);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  font-style: normal;
}

.hero .lead {
  max-width: 52ch;
  margin-top: 28px;
  color: var(--muted);
  font-size: 20px;
}

.cta-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 28px;
  margin-top: 36px;
}

.hero .loc {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 40px;
  color: var(--mute);
  font-size: 15px;
}
.loc .material-symbols-outlined {
  color: var(--lav);
  font-size: 22px;
}

/* 8. Home: Who we are
   --------------------------------------------------------------------- */
.who {
  background: var(--bg-2);
}

.who .wrap {
  display: grid;
  grid-template-columns: 1fr 380px;
  align-items: center;
  gap: 48px;
  min-height: 340px;
}
.who h2 {
  max-width: 12ch;
}
.who .lead {
  margin-top: 22px;
}

.pillars {
  display: grid;
  gap: 28px;
  padding-left: 40px;
  border-left: 1px solid var(--line);
}
.pillar {
  display: grid;
  grid-template-columns: 34px 1fr;
  gap: 16px;
}
.pillar h3 {
  margin-bottom: 4px;
  color: #c6cce3;
  font-size: 14px;
  font-weight: 600;
}
.pillar p {
  max-width: 34ch;
  color: #fff;
  font-size: 13.5px;
}
.pillar .material-symbols-outlined {
  color: var(--lilac);
  font-size: 32px;
  font-variation-settings: 'wght' 300;
}

/* 9. Home: What we do
   (el efecto acordeón de las tarjetas vive en accordion.css)
   --------------------------------------------------------------------- */
.what {
  background: var(--bg);
}
.what h2 {
  max-width: 14ch;
}
.what .lead {
  margin-top: 22px;
}

.cards {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  margin-top: 84px;
}

.card {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  gap: 10px;
  min-height: 232px;
  padding: 36px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 20px;
  transition: transform 0.25s;
}
.card:hover {
  transform: translateY(-4px);
}

/* brillo diagonal */
.card::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(115deg, transparent 55%, rgba(255, 255, 255, 0.1));
  pointer-events: none;
}

.card .ic {
  position: absolute;
  top: 36px;
  left: 36px;
  display: grid;
  place-items: center;
  width: 56px;
  height: 56px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.14);
}
.card .ic .material-symbols-outlined {
  color: #fff;
  font-size: 24px;
}

.card h3 {
  font-size: 21px;
  font-weight: 600;
}

.card span {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: rgba(255, 255, 255, 0.88);
  font-size: 13.5px;
}
.card span .material-symbols-outlined {
  font-size: 18px;
}

.c1 {
  background: linear-gradient(90deg, #8a4be0, #4a2e96);
}
.c2 {
  background: linear-gradient(90deg, #5470e0, #2b3a93);
}
.c3 {
  background: linear-gradient(90deg, #9a4fdc, #452d8b);
}
.c4 {
  background: linear-gradient(90deg, #5e5be0, #352a86);
}

/* 10. Home: Our philosophy
   El fondo de estrellas se funde con var(--bg) arriba y abajo para unirse
   sin cortes con las secciones vecinas.
   --------------------------------------------------------------------- */
.phil {
  padding-block: 96px 80px;
  text-align: center;
  background:
    linear-gradient(180deg, var(--bg) 0%, rgba(7, 7, 26, 0.55) 22%, rgba(7, 7, 26, 0.55) 78%, var(--bg) 100%),
    url('../images/starfield-bg.png') center / cover no-repeat,
    var(--bg);
}
.phil h2 {
  max-width: 24ch;
  margin-inline: auto;
}
.phil .lead {
  margin: 22px auto 0;
}
.phil .btn {
  margin-top: 44px;
}

.values {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  margin-top: 56px;
}
.value {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  padding: 6px 12px;
  color: #fff;
  font-family: var(--font-head);
  font-size: 20px;
  font-weight: 600;
}
.value + .value {
  border-left: 1px solid rgba(255, 255, 255, 0.08);
}
.value .ring {
  display: grid;
  place-items: center;
  width: 64px;
  height: 64px;
  border: 1px solid rgba(185, 150, 245, 0.35);
  border-radius: 50%;
  background: rgba(84, 49, 153, 0.7);
}
.value .material-symbols-outlined {
  color: var(--lilac);
  font-size: 30px;
}

/* 11. Home: Our approach (loop)
   El diagrama del infinito se usa en el Home y en How We Work.
   main.js coloca los .node y .step sobre el trazo según su data-f.
   --------------------------------------------------------------------- */
.appr {
  padding-bottom: 72px;
  background: var(--bg);
}
.appr h2 {
  max-width: 12ch;
}
.appr .lead {
  max-width: 46ch;
  margin-top: 22px;
}

/* padding superior: deja espacio para las etiquetas 01/03 que van arriba del trazo */
.loopwrap {
  margin-top: 90px;
  margin-bottom: -48px;
  padding-top: 60px;
  padding-bottom: 84px;
  overflow-x: auto;
}

.loop {
  position: relative;
  width: 100%;
  min-width: 760px;
  max-width: 980px;
  margin-inline: auto;
  aspect-ratio: 880 / 360;
}
.loop svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  overflow: visible;
}
.loop .path {
  fill: none;
  stroke: url(#lg);
  stroke-width: 2.5;
  filter: drop-shadow(0 0 8px rgba(140, 90, 255, 0.6));
}

/* THINK / BUILD & RUN: centrados bajo los círculos (padding-left compensa el letter-spacing final) */
.loop .tag {
  position: absolute;
  top: 50%;
  transform: translate(-50%, -50%);
  padding-left: 0.3em;
  color: var(--mute);
  font-size: 11px;
  font-weight: 700;
  line-height: 1;
  letter-spacing: 0.3em;
  white-space: nowrap;
}

/* Píldora "Join at any stage" en el cruce del infinito */
.loop .join {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 15px 7px 11px;
  border: 1px solid rgba(185, 150, 245, 0.6);
  border-radius: 999px;
  background: linear-gradient(rgba(123, 66, 210, 0.25), rgba(123, 66, 210, 0.25)), #07071a;
  box-shadow: 0 0 28px rgba(123, 66, 210, 0.5);
  color: #fff;
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
}
.loop .join .material-symbols-outlined {
  font-size: 17px;
}
a.join:hover {
  border-color: var(--lilac);
}

.node {
  position: absolute;
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  margin: -24px 0 0 -24px;
  border: 2px solid #6f4de6;
  border-radius: 50%;
  background: #17123f;
  box-shadow: 0 0 18px rgba(120, 80, 255, 0.5);
}
.node .material-symbols-outlined {
  color: #d7c6ff;
  font-size: 20px;
}

.step {
  position: absolute;
  width: 190px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.4;
}
.step b {
  display: block;
  margin: 2px 0 4px;
  color: #fff;
  font-size: 17px;
  font-weight: 500;
}
.step i {
  color: var(--lilac);
  font-size: 12px;
  font-style: normal;
  font-weight: 700;
  letter-spacing: 0.14em;
}

/* punto de luz que recorre el trazo */
.dot {
  position: absolute;
  width: 10px;
  height: 10px;
  margin: -5px 0 0 -5px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 0 14px 4px rgba(170, 130, 255, 0.9);
}

/* Tarjetas "Enter at 01 / 03 / 05" (el hover vive en accordion.css) */
.entries {
  position: relative;
  z-index: 6;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin-top: 8px;
}
.entry {
  display: flex;
  gap: 18px;
  padding: 22px 24px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 16px;
  background: #121132;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}
.entry .ic {
  display: grid;
  flex: none;
  place-items: center;
  width: 46px;
  height: 46px;
  border: 1px solid rgba(185, 150, 245, 0.25);
  border-radius: 12px;
  background: rgba(123, 66, 210, 0.16);
}
.entry .ic .material-symbols-outlined {
  color: var(--lav);
  font-size: 24px;
}
.entry small {
  display: block;
  color: var(--lav);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.entry h3 {
  margin: 3px 0 4px;
  font-size: 18px;
  font-weight: 600;
}
.entry p {
  color: var(--muted);
  font-size: 14px;
  line-height: 1.5;
}

/* 12. Home: Engineering experience
   --------------------------------------------------------------------- */
.exp {
  background: radial-gradient(45% 70% at 100% 40%, rgba(69, 45, 139, 0.5), transparent 70%), var(--bg-3);
}

.exp .wrap {
  display: grid;
  grid-template-columns: 0.9fr 1.4fr;
  align-items: end;
  gap: 56px;
}
.exp .lead {
  max-width: 30ch;
  margin-top: 22px;
}

.tiles {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin-top: 0;
}
.tile {
  position: relative;
  min-height: 220px;
  padding: 80px 18px 18px;
  border: 1px solid #222345;
  border-radius: 6px;
  background: linear-gradient(180deg, rgba(3, 11, 27, 0.07), #030b1b);
}
.tile h3 {
  color: #f7f5ff;
  font-size: 15px;
  font-weight: 600;
}
.tile p {
  margin-top: 6px;
  color: #c6cce3;
  font-size: 13px;
}
.tile .go {
  display: block;
  margin-top: 12px;
  color: var(--lilac);
}
.tile .go .material-symbols-outlined {
  font-size: 22px;
}
.tile .ic .material-symbols-outlined {
  position: absolute;
  top: 18px;
  left: 18px;
  color: var(--lilac);
  font-size: 30px;
}

/* 13. CTA y logo final
   Las letras SORAIN están fijas; la grulla aterriza encima y se convierte en el ícono.
   --------------------------------------------------------------------- */
.cta {
  overflow: hidden;
  padding-block: 96px 80px;
  background:
    linear-gradient(160deg, rgba(42, 15, 107, 0.7) 0%, rgba(21, 8, 69, 0.2) 32%, rgba(10, 6, 32, 0) 71%),
    linear-gradient(90deg, #9145d2 2%, #7b42d2 35%, #3a2580 100%);
}

.cta .wrap {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 40px;
}
.cta .eyebrow {
  color: rgba(255, 255, 255, 0.75);
}
.cta h2 {
  font-size: clamp(34px, 4.6vw, 54px);
}
.cta .lead {
  max-width: 54ch;
  margin-top: 18px;
  color: rgba(255, 255, 255, 0.85);
}
.cta .lead + .btn {
  margin-top: 36px;
}

.cta-act {
  position: relative;
  width: 300px;
  height: 280px;
  margin-right: 6%;
}

/* El ancla (donde aterriza la grulla) es un cuadrado centrado EXACTAMENTE sobre el ícono del logo.
   Se desplaza (+.066w, -.206w) para que el logo completo (ícono + letras) quede centrado en .cta-act. */
.cta-act .anchor {
  top: 50%;
  bottom: auto;
  left: 50%;
  width: var(--w);
  height: var(--w);
  margin: calc(var(--w) * -0.706) 0 0 calc(var(--w) * -0.434);
}

/* Los dos SVG comparten un lienzo de 3000×2000: el ícono ocupa x 725–2558, y 55–1092
   y las letras x 107–2913, y 1277–1913. El lienzo se escala para que el ícono mida .92 × el ancla,
   que es justo el ancho de la grulla de perfil (main.js: 2.30 * S = .92 * w). */
.anchor .endwrap {
  position: absolute;
  top: 21.21%;
  left: -32.39%;
  width: 150.57%;
  transform: none;
  visibility: visible;
}
.anchor .endwrap .endlogo {
  position: static;
  display: block;
  width: 100%;
  max-width: none;
  height: auto;
  margin: 0;
  object-fit: contain;
  opacity: var(--lg, 0);
  filter: drop-shadow(0 6px 18px rgba(21, 11, 63, 0.45));
}
.anchor .endwrap .endtext {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  max-width: none;
  height: auto;
  margin: 0;
  transform: none;
  opacity: 1;
  filter: drop-shadow(0 6px 18px rgba(21, 11, 63, 0.45));
  pointer-events: none;
}

/* 14. Footer
   --------------------------------------------------------------------- */
.foot {
  padding-block: 64px 28px;
  background: #050512;
}

.foot .top {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1.2fr;
  gap: 40px;
}

.foot .logo img {
  width: auto;
  height: 64px;
}

.foot .tag {
  margin: 18px 0 10px;
  font-weight: 600;
  line-height: 1.3;
}
.foot .small {
  max-width: 34ch;
  color: var(--mute);
  font-size: 13px;
}

.foot h4 {
  margin: 0 0 18px;
  color: var(--purple);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.foot ul {
  display: grid;
  gap: 12px;
  margin: 0;
  padding: 0;
  color: var(--muted);
  font-size: 14px;
  list-style: none;
}
.foot ul a:hover {
  color: #fff;
}

.foot li.row {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--purple);
}
.foot li.row .material-symbols-outlined {
  color: var(--purple);
  font-size: 20px;
}
.foot li.row a:hover {
  color: #fff;
}

.foot .bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 16px 32px;
  margin-top: 64px;
  padding-top: 28px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  color: var(--mute);
  font-size: 12.5px;
}
.foot .bottom nav {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 28px;
}
.foot .bottom a {
  text-decoration: underline;
  text-decoration-color: rgba(184, 149, 255, 0.4);
  text-underline-offset: 3px;
}
.foot .bottom nav a {
  color: var(--muted);
}
.foot .bottom nav.social {
  gap: 10px;
  align-items: center;
}
.foot .bottom nav.social a {
  display: inline-grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 50%;
  color: var(--muted);
  text-decoration: none;
  transition: color 0.2s, border-color 0.2s, background-color 0.2s;
}
.foot .bottom nav.social a:hover,
.foot .bottom nav.social a:focus-visible {
  color: #fff;
  border-color: rgba(184, 149, 255, 0.6);
  background-color: rgba(184, 149, 255, 0.12);
}

/* 15. Páginas simples y legales (Privacy Policy, Terms & Conditions)
   --------------------------------------------------------------------- */
.page {
  display: grid;
  align-items: center;
  min-height: 62vh;
  padding-block: 120px;
  background: radial-gradient(60% 80% at 85% 20%, rgba(69, 45, 139, 0.45), transparent 70%), var(--hero);
}
.page h1 {
  margin: 0 0 20px;
  font-size: clamp(40px, 6vw, 72px);
  font-weight: 600;
  line-height: 1.08;
  letter-spacing: -0.04em;
}
.page .lead {
  margin-bottom: 36px;
}

/* Páginas legales: encabezado compacto + texto largo legible */
.page.page-legal {
  min-height: 0;
  padding-block: 140px 56px;
}
.page.page-legal .lead {
  margin-bottom: 0;
}
.legal {
  padding-block: 56px 120px;
  background: var(--bg);
}
.legal-body {
  max-width: 780px;
  color: var(--muted);
  font-size: 16px;
  line-height: 1.7;
}
.legal-body h2 {
  margin: 48px 0 14px;
  color: var(--ink);
  font-family: var(--font-head);
  font-size: clamp(20px, 2.4vw, 24px);
  font-weight: 600;
  line-height: 1.3;
  letter-spacing: -0.01em;
}
.legal-body p,
.legal-body ul {
  margin: 0 0 16px;
}
.legal-body ul {
  padding-left: 22px;
}
.legal-body li {
  margin-bottom: 8px;
}
.legal-body li ul {
  margin: 8px 0 0;
}
.legal-body li::marker {
  color: var(--lilac);
}
.legal-body strong {
  color: var(--ink);
  font-weight: 500;
}
.legal-body a {
  color: var(--lilac);
  text-decoration: underline;
  text-underline-offset: 3px;
  overflow-wrap: anywhere;
}
.legal-table {
  margin: 8px 0 20px;
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: 8px;
}
.legal-table table {
  width: 100%;
  min-width: 560px;
  border-collapse: collapse;
  font-size: 14.5px;
  line-height: 1.5;
}
.legal-table th,
.legal-table td {
  padding: 12px 16px;
  text-align: left;
  vertical-align: top;
  border-bottom: 1px solid var(--line);
}
.legal-table th {
  color: var(--ink);
  font-weight: 500;
  background: rgba(139, 61, 217, 0.12);
}
.legal-table tr:last-child td {
  border-bottom: 0;
}

/* 16. Animación al hacer scroll
   main.js agrega .reveal a los bloques que empiezan fuera de pantalla y .in cuando aparecen.
   --------------------------------------------------------------------- */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition:
    opacity 0.8s ease,
    transform 0.8s ease;
}
.reveal.in {
  opacity: 1;
  transform: none;
}

/* 17. Ajustes para español (los textos son más largos)
   --------------------------------------------------------------------- */
html[lang='es'] .hero h1 em {
  height: auto;
  padding-bottom: 0.08em;
}
html[lang='es'] .nav .links {
  gap: 30px;
}
html[lang='es'] .who h2 {
  max-width: 15ch;
}
html[lang='es'] .what h2 {
  max-width: 17ch;
}
html[lang='es'] .appr h2 {
  max-width: 15ch;
}
/* En español "CONSTRUIR Y OPERAR" es largo: va en dos líneas y las etiquetas se alejan del centro
   (left 28.6% / 71.4% en el HTML) para dejar aire alrededor de la píldora "Súmenos en cualquier etapa" */
html[lang='es'] .loop .tag {
  padding-left: 0.2em;
  letter-spacing: 0.2em;
  line-height: 1.6;
  text-align: center;
}

/* 18. Responsive
   --------------------------------------------------------------------- */
@media (max-width: 1280px) {
  html[lang='es'] .nav .links {
    gap: 22px;
    font-size: 14px;
  }
}

@media (max-width: 1000px) {
  .links {
    display: none;
  }
  .nav .wrap {
    grid-template-columns: minmax(0, 1fr) auto;
  }

  .who .wrap,
  .exp .wrap,
  .cta .wrap {
    grid-template-columns: 1fr;
  }

  .pillars {
    padding-left: 0;
    border-left: 0;
  }
  .cards {
    grid-template-columns: repeat(2, 1fr);
    margin-top: 48px;
  }
  .tiles {
    grid-template-columns: 1fr;
  }
  .foot .top {
    grid-template-columns: 1fr 1fr;
  }

  /* La grulla se ubica arriba del título de cada sección */
  .sec {
    padding-top: calc(48vw + 24px);
  }
  .hero {
    padding-top: calc(72vw + 8px);
  }

  .anchor,
  .anchor.hero {
    top: 8px;
    right: auto;
    left: 50%;
    width: 48vw;
    height: 48vw;
    margin: 0 0 0 -24vw;
  }
  .anchor.hero {
    top: -2vw;
    left: 28vw;
    width: 78vw;
    height: 78vw;
    margin: 0;
  }

  /* CTA: el logo (ícono + letras) va centrado en el espacio libre arriba del título */
  .cta-act {
    position: static;
    justify-self: start;
    width: 0;
    height: 0;
    margin-right: 0;
  }
  .cta-act .anchor {
    --w: 34vw !important; /* gana al style="--w:183px" del HTML */
    top: calc(-48vw - 12px);
    left: 50%;
    margin: 0 0 0 calc(var(--w) * -0.434);
  }
}

@media (max-width: 900px) {
  .entries {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .lang {
    display: none;
  }
  .nav .btn {
    padding: 10px 14px;
    font-size: 14px;
  }
  .cards {
    grid-template-columns: 1fr;
  }
  .values {
    grid-template-columns: 1fr 1fr;
    row-gap: 24px;
  }
  .value + .value {
    border-left: 0;
  }
  .foot .top {
    grid-template-columns: 1fr;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  .card,
  .btn,
  .more .material-symbols-outlined {
    transition: none;
  }
}
