/* Lo que comparten /links y /recursos: la marca de la landing (negro estrellado, menta, Lexend y Geist Mono). */
@font-face { font-family: Lexend; src: url(/fuentes/lexend-latin.woff2) format("woff2"); font-weight: 100 900; font-display: swap; }
@font-face { font-family: Lexend; src: url(/fuentes/lexend-latin-ext.woff2) format("woff2"); font-weight: 100 900; font-display: swap; unicode-range: U+0100-024F; }
@font-face { font-family: "Geist Mono"; src: url(/fuentes/geist-mono-latin.woff2) format("woff2"); font-display: swap; }
@font-face { font-family: "Geist Mono"; src: url(/fuentes/geist-mono-latin-ext.woff2) format("woff2"); font-display: swap; unicode-range: U+0100-024F; }

:root {
  --fondo: #090A0B; --fondo-rgb: 9 10 11;
  --tarjeta: #111214;
  --isla: #0D1F16; --isla-2: #12281C;
  --petroleo: #123030; --petroleo-hondo: #0A1E1E;
  --acento: #81D297; --acento-rgb: 129 210 151;
  --acento-claro: #C4F2D1;
  --crema: #F3F4F2; --crema-rgb: 243 244 242;
  --texto-2: #A9B2AD;
  --apagado: #6B7570;
  --linea: rgba(255, 255, 255, .08);
  --linea-2: rgba(255, 255, 255, .14);
  --mono: "Geist Mono", ui-monospace, Menlo, monospace;
  --radio: 22px;
  color-scheme: dark;
}
*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body { margin: 0; min-height: 100vh; background: var(--fondo); color: var(--crema); font: 400 16px/1.55 Lexend, -apple-system, BlinkMacSystemFont, "Helvetica Neue", Arial, sans-serif; -webkit-font-smoothing: antialiased; overflow-x: hidden; }
img, video, svg { display: block; max-width: 100%; }
a { color: inherit; }
button { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--acento); outline-offset: 3px; border-radius: 8px; }

#cielo { position: fixed; inset: 0; width: 100%; height: 100%; z-index: -1; pointer-events: none; }

/* La palabra resaltada como "texto seleccionado", igual que en la landing */
.sel { position: relative; display: inline-block; padding: 0 .14em .04em; background: rgb(var(--acento-rgb) / .2); box-shadow: inset 0 0 0 1px rgb(var(--acento-rgb) / .75); border-radius: 2px; }
.sel::before, .sel::after { content: ""; position: absolute; width: 7px; height: 7px; border-radius: 50%; background: var(--acento); }
.sel::before { left: 0; top: 0; transform: translate(-55%, -55%); }
.sel::after { right: 0; bottom: 0; transform: translate(55%, 55%); }

.etiqueta { font: 500 11px/1 var(--mono); letter-spacing: .16em; text-transform: uppercase; color: var(--acento); }

/* El logo de la landing: cuadro menta con dos puntos */
.logo { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; font-weight: 700; letter-spacing: -.03em; font-size: 17px; }
.logo i { width: 22px; height: 22px; border: 2px solid var(--acento); border-radius: 3px; position: relative; flex: none; }
.logo i::before, .logo i::after { content: ""; position: absolute; width: 6px; height: 6px; border-radius: 50%; background: var(--acento); }
.logo i::before { left: -4px; top: -4px; } .logo i::after { right: -4px; bottom: -4px; }
.logo small { font: 400 10px/1 var(--mono); letter-spacing: .14em; text-transform: uppercase; color: var(--texto-2); border-left: 1px solid var(--linea-2); padding-left: 10px; margin-left: 2px; }

.boton { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 46px; padding: 0 20px; border-radius: 999px; border: 0; background: var(--acento); color: #0B1A10; font-weight: 600; font-size: 15px; text-decoration: none; cursor: pointer; transition: transform .2s ease, background .2s ease; }
.boton:hover { background: var(--acento-claro); }
.boton:active { transform: scale(.97); }
.boton--hueco { background: transparent; color: var(--crema); box-shadow: inset 0 0 0 1px var(--linea-2); }
.boton--hueco:hover { background: rgba(255, 255, 255, .06); }
.flecha { transition: transform .2s ease; }
a:hover .flecha, .boton:hover .flecha { transform: translateX(3px); }

/* Entrada suave al cargar */
@keyframes subir { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
[data-entra] { animation: subir .7s cubic-bezier(.2, .7, .2, 1) both; animation-delay: calc(var(--i, 0) * 70ms); }
@media (prefers-reduced-motion: reduce) { [data-entra] { animation: none; } html { scroll-behavior: auto; } }

/* ───────── Animaciones compartidas (12 nov) ───────── */

/* Brillo que sigue al mouse o al dedo dentro de una tarjeta (JS pone --mx y --my) */
.brilla { position: relative; isolation: isolate; }
.brilla::after { content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none; z-index: 3; opacity: 0; transition: opacity .35s ease;
  background: radial-gradient(260px circle at var(--mx, 50%) var(--my, 50%), rgba(255, 255, 255, .09), transparent 60%); }
.brilla:hover::after, .brilla.tocando::after { opacity: 1; }

/* Estrellitas dentro de una tarjeta */
.chispas { position: absolute; inset: 0; z-index: -1; pointer-events: none; overflow: hidden; border-radius: inherit;
  background-image: radial-gradient(1px 1px at 12% 18%, rgba(255,255,255,.75), transparent), radial-gradient(1px 1px at 34% 62%, rgba(255,255,255,.45), transparent), radial-gradient(1.4px 1.4px at 58% 12%, rgba(205,239,216,.9), transparent), radial-gradient(1px 1px at 76% 40%, rgba(255,255,255,.55), transparent), radial-gradient(1px 1px at 90% 14%, rgba(255,255,255,.5), transparent), radial-gradient(1.2px 1.2px at 22% 84%, rgba(255,255,255,.4), transparent), radial-gradient(1px 1px at 66% 78%, rgba(205,239,216,.6), transparent);
  animation: titilar 4s ease-in-out infinite alternate; }
@keyframes titilar { from { opacity: .55; } to { opacity: 1; } }

/* El planeta: un arco que brilla en la orilla y una luz que lo recorre */
.planeta { position: absolute; left: -30%; right: -30%; bottom: -150%; aspect-ratio: 1; border-radius: 50%; pointer-events: none;
  background: radial-gradient(closest-side, #0B2418 70%, #103322 88%, #1B5236 97%, rgb(var(--acento-rgb) / .9) 99.4%, transparent 100%);
  box-shadow: 0 -8px 60px rgb(var(--acento-rgb) / .28), 0 -2px 14px rgb(var(--acento-rgb) / .35); }
.planeta::before { content: ""; position: absolute; inset: 0; border-radius: 50%;
  background: conic-gradient(from 0deg, transparent 0 80%, rgb(var(--acento-rgb) / .0) 82%, rgba(220, 255, 232, .85) 86%, transparent 90%);
  -webkit-mask: radial-gradient(closest-side, transparent 98.4%, #000 99.2%, transparent 100%); mask: radial-gradient(closest-side, transparent 98.4%, #000 99.2%, transparent 100%);
  animation: girar 9s linear infinite; }
@keyframes girar { to { transform: rotate(360deg); } }

/* Los robots: flotan un poco, cada uno a su tiempo; al pasar el mouse saludan */
.robot { display: block; height: auto; transform-origin: 50% 100%; animation: flotar 3.2s ease-in-out infinite; animation-delay: calc(var(--n, 0) * -0.45s); filter: drop-shadow(0 8px 10px rgba(0, 0, 0, .35)); }
@keyframes flotar { 0%, 100% { transform: translateY(0) rotate(0deg); } 50% { transform: translateY(-7%) rotate(-2deg); } }
.robot:hover { animation: saludar .6s ease-in-out 2; }
@keyframes saludar { 0%, 100% { transform: rotate(0); } 25% { transform: rotate(-9deg) translateY(-6%); } 75% { transform: rotate(9deg) translateY(-6%); } }

/* Escenas grandes (automatiza, auditoría…): flotan con un halo que respira */
.escena { position: relative; }
.escena::before { content: ""; position: absolute; inset: 12% 10%; border-radius: 50%; background: radial-gradient(closest-side, rgb(var(--acento-rgb) / .35), transparent); filter: blur(18px); animation: respirar 4.5s ease-in-out infinite; z-index: -1; }
.escena img { animation: flotar-suave 6s ease-in-out infinite; }
@keyframes flotar-suave { 0%, 100% { transform: translateY(0) rotate(-.6deg); } 50% { transform: translateY(-4%) rotate(.6deg); } }
@keyframes respirar { 0%, 100% { opacity: .55; transform: scale(.94); } 50% { opacity: 1; transform: scale(1.05); } }

/* Entrada al bajar: JS pone .visible */
[data-aparece] { opacity: 0; transform: translateY(26px); transition: opacity .8s cubic-bezier(.2, .7, .2, 1), transform .8s cubic-bezier(.2, .7, .2, 1); transition-delay: calc(var(--i, 0) * 80ms); }
[data-aparece].visible { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  .robot, .escena img, .escena::before, .chispas, .planeta::before { animation: none !important; }
  [data-aparece] { opacity: 1; transform: none; transition: none; }
}

/* Robots parados en un planeta: .tripulacion junto a .planeta dentro del mismo contenedor; vida.js los acomoda */
.tripulacion { position: absolute; inset: 0; z-index: 1; pointer-events: none; }
.tripulacion .robot { position: absolute; pointer-events: auto; }
