/* Hito Signal — controles de tema e idioma (todas las páginas). Heredan el color del texto de la cabecera. */
.prefs{display:flex;align-items:center;gap:10px}
.lang-sw{display:flex;position:relative;border:1px solid color-mix(in srgb,currentColor 28%,transparent);border-radius:999px;padding:3px;isolation:isolate}
.lang-sw button{position:relative;z-index:1;font:650 12.5px/1 var(--f,system-ui);font-stretch:110%;letter-spacing:.02em;color:inherit;opacity:.72;background:none;border:0;border-radius:999px;padding:7px 10px;cursor:pointer;transition:opacity .2s,color .35s}
.lang-sw button:hover{opacity:1}
.lang-sw button[aria-pressed="true"]{opacity:1;color:var(--pill-ink,#14171C)}
/* la píldora verde se desliza bajo el idioma elegido */
.lang-sw::before{content:"";position:absolute;z-index:0;top:3px;bottom:3px;left:3px;width:calc(50% - 3px);border-radius:999px;background:var(--pill,#5BE49B);transition:transform .45s cubic-bezier(.34,1.56,.64,1)}
html[data-lang="es"] .lang-sw::before{transform:translateX(100%)}

.theme-sw{position:relative;width:38px;height:38px;border-radius:50%;display:grid;place-items:center;color:inherit;background:none;cursor:pointer;
  border:1px solid color-mix(in srgb,currentColor 28%,transparent);transition:border-color .2s,background-color .2s,transform .3s cubic-bezier(.34,1.56,.64,1)}
.theme-sw:hover{border-color:currentColor;background:color-mix(in srgb,currentColor 8%,transparent)}
.theme-sw:active{transform:scale(.9)}
.theme-sw svg{width:20px;height:20px;overflow:visible}
/* sol que se convierte en luna: el disco crece, la máscara lo muerde y los rayos se recogen */
.theme-sw .disc{transform-origin:12px 12px;transition:transform .6s cubic-bezier(.34,1.56,.64,1)}
.theme-sw .bite{transition:transform .6s cubic-bezier(.16,1,.3,1)}
.theme-sw .rays{transform-origin:12px 12px;transition:transform .6s cubic-bezier(.16,1,.3,1),opacity .35s}
.theme-sw .rays line{stroke:currentColor;stroke-width:2;stroke-linecap:round}
html[data-theme="dark"] .theme-sw .disc{transform:scale(1.55)}
html[data-theme="dark"] .theme-sw .bite{transform:translate(-8px,6px)}
html[data-theme="dark"] .theme-sw .rays{transform:rotate(-90deg) scale(.4);opacity:0}
html:not([data-theme="dark"]) .theme-sw .bite{transform:translate(0,0)}
.lang-sw button:focus-visible,.theme-sw:focus-visible{outline:2px solid var(--pill,#5BE49B);outline-offset:2px}

/* transición de tema: el nuevo se abre en círculo (View Transitions); sin animación por defecto del navegador */
::view-transition-old(root),::view-transition-new(root){animation:none;mix-blend-mode:normal}
html.vt *{transition:none!important}
@media (prefers-reduced-motion:reduce){.lang-sw::before,.theme-sw *{transition:none!important}}

/* ============ Logo animado: el hito emite la señal ============
   Al cargar: se dibuja el hito, se enciende el punto y salen las dos ondas.
   Después, cada 5 s: el punto late, un anillo se abre desde él, un destello recorre cada onda
   y una tercera onda se aleja y se desvanece. Al pasar el ratón, el ciclo va al triple de rápido. */
.hlogo{--lg:#5BE49B;--lg-hi:#EAFFF3;overflow:visible;flex:none}
html[data-theme="light"] .hlogo{--lg:#0F9D58;--lg-hi:#7DF0B4}
.hlogo .lg-arch,.hlogo .lg-arc,.hlogo .lg-run,.hlogo .lg-wave{fill:none;stroke-linecap:round}
.hlogo .lg-arch{stroke:var(--lg);stroke-width:2.4;stroke-dasharray:100;animation:lgDraw 1.1s cubic-bezier(.65,0,.35,1) both}
.hlogo .lg-dot{fill:var(--lg);transform-box:fill-box;transform-origin:center;
  animation:lgPop .7s cubic-bezier(.34,1.8,.5,1) .7s both,lgBeat 5s ease-in-out 2.2s infinite}
.hlogo .lg-ring{fill:none;stroke:var(--lg);stroke-width:1.1;transform-box:fill-box;transform-origin:center;opacity:0;
  animation:lgRing 5s cubic-bezier(.16,1,.3,1) 2.2s infinite}
.hlogo .lg-arc{stroke:var(--lg);stroke-width:2.2;stroke-dasharray:100;opacity:.6}
.hlogo .lg-a1{animation:lgDraw .7s cubic-bezier(.16,1,.3,1) 1s both,lgGlow 5s ease-in-out 2.35s infinite}
.hlogo .lg-a2{animation:lgDraw .7s cubic-bezier(.16,1,.3,1) 1.2s both,lgGlow 5s ease-in-out 2.55s infinite}
.hlogo .lg-run{stroke:var(--lg-hi);stroke-width:2.4;stroke-dasharray:22 140;stroke-dashoffset:22;opacity:0;filter:drop-shadow(0 0 2px var(--lg))}
.hlogo .lg-r1{animation:lgRun 5s cubic-bezier(.4,0,.2,1) 2.35s infinite}
.hlogo .lg-r2{animation:lgRun 5s cubic-bezier(.4,0,.2,1) 2.55s infinite}
.hlogo .lg-wave{stroke:var(--lg);stroke-width:1.6;opacity:0;transform-box:view-box;transform-origin:7px 9.2px;
  animation:lgWave 5s cubic-bezier(.16,1,.3,1) 2.75s infinite}
@keyframes lgDraw{from{stroke-dashoffset:100}to{stroke-dashoffset:0}}
@keyframes lgPop{0%{transform:scale(0)}100%{transform:scale(1)}}
@keyframes lgBeat{0%,14%,100%{transform:scale(1)}5%{transform:scale(1.55)}}
@keyframes lgRing{0%{opacity:.9;transform:scale(1)}22%{opacity:0;transform:scale(4.2)}100%{opacity:0;transform:scale(4.2)}}
@keyframes lgGlow{0%,30%,100%{opacity:.6}7%{opacity:1}}
@keyframes lgRun{0%{stroke-dashoffset:22;opacity:1}16%{stroke-dashoffset:-100;opacity:1}17%,100%{stroke-dashoffset:-100;opacity:0}}
@keyframes lgWave{0%{opacity:.75;transform:scale(1)}26%{opacity:0;transform:scale(1.55)}100%{opacity:0;transform:scale(1.55)}}
/* al pasar el ratón: una ráfaga corta (la pone js/prefs.js) */
.hlogo.burst .lg-dot{animation:lgBeatB 1.2s ease-in-out both}
.hlogo.burst .lg-ring{animation:lgRingB 1.2s cubic-bezier(.16,1,.3,1) both}
.hlogo.burst .lg-a1{animation:lgGlowB 1.2s ease-in-out .08s both}
.hlogo.burst .lg-a2{animation:lgGlowB 1.2s ease-in-out .2s both}
.hlogo.burst .lg-r1{animation:lgRunB 1.2s cubic-bezier(.4,0,.2,1) .08s both}
.hlogo.burst .lg-r2{animation:lgRunB 1.2s cubic-bezier(.4,0,.2,1) .2s both}
.hlogo.burst .lg-wave{animation:lgWaveB 1.2s cubic-bezier(.16,1,.3,1) .3s both}
.hlogo.burst .lg-arch{animation:lgArchB 1.2s ease-in-out both}
@keyframes lgBeatB{0%,100%{transform:scale(1)}12%{transform:scale(1.7)}30%{transform:scale(.9)}45%{transform:scale(1.35)}65%{transform:scale(1)}}
@keyframes lgRingB{0%{opacity:.95;transform:scale(1)}45%{opacity:0;transform:scale(5)}46%{opacity:.8;transform:scale(1)}100%{opacity:0;transform:scale(5)}}
@keyframes lgGlowB{0%,100%{opacity:.6}20%,55%{opacity:1}}
@keyframes lgRunB{0%{stroke-dashoffset:22;opacity:1}45%{stroke-dashoffset:-100;opacity:1}46%{stroke-dashoffset:22;opacity:1}90%{stroke-dashoffset:-100;opacity:1}100%{stroke-dashoffset:-100;opacity:0}}
@keyframes lgWaveB{0%{opacity:.85;transform:scale(1)}60%{opacity:0;transform:scale(1.8)}100%{opacity:0;transform:scale(1.8)}}
@keyframes lgArchB{0%,100%{filter:none}35%{filter:drop-shadow(0 0 3px var(--lg))}}
a.brand:has(>.hlogo){display:inline-flex;align-items:center;gap:11px}
@media (prefers-reduced-motion:reduce){.hlogo *{animation:none!important;opacity:revert}.hlogo .lg-arc{opacity:.75}.hlogo .lg-ring,.hlogo .lg-run,.hlogo .lg-wave{display:none}}
