/* Arranque común de ISC Management y sus programas (sacado de la secuencia de inicio de Tesorería) */
/* ───────── Secuencia de inicio ───────── */
@property --sp-a { syntax: '<angle>'; inherits: false; initial-value: 0deg; }
.splash { position: fixed; inset: 0; z-index: 1000; display: grid; place-items: center; overflow: hidden; cursor: pointer; color: #fff;
  background: radial-gradient(120% 90% at 50% 45%, #0B5a38 0%, #064229 55%, #032617 100%);
  clip-path: circle(150% at 50% 45%); }
/* rayas de carrera que cruzan la pantalla */
.sp-stripes { position: absolute; inset: 0; pointer-events: none; }
.sp-stripes i { position: absolute; left: -30%; width: 160%; height: 10px; background: #FFB81D; transform: translateX(-110%) rotate(-12deg); animation: sp-sweep .9s cubic-bezier(.7, 0, .2, 1) forwards; }
.sp-stripes i:nth-child(1) { top: 30%; animation-delay: .05s; }
.sp-stripes i:nth-child(2) { top: calc(30% + 18px); height: 4px; animation-delay: .14s; }
.sp-stripes i:nth-child(3) { top: 68%; height: 3px; opacity: .5; background: #fff; animation-delay: .22s; }
@keyframes sp-sweep { 0% { transform: translateX(-110%) rotate(-12deg); } 100% { transform: translateX(110%) rotate(-12deg); } }

.sp-center { position: relative; display: grid; justify-items: center; text-align: center; }
.sp-emb-wrap { position: relative; width: min(170px, 42vw); aspect-ratio: 1; margin-bottom: 26px; animation: sp-pop .9s cubic-bezier(.2, 1.4, .4, 1) .35s both; }
/* la llave se «dibuja» con un barrido circular y luego le pasa un brillo */
.sp-emb { position: absolute; inset: 0; overflow: hidden; background: #FFB81D;
  -webkit-mask: var(--emblem) center / contain no-repeat; mask: var(--emblem) center / contain no-repeat;
  filter: drop-shadow(0 0 0 rgba(255, 184, 29, 0)); }
.sp-emb::before { content: ''; position: absolute; inset: -20%; background: #064229; -webkit-mask: conic-gradient(from 200deg, transparent var(--sp-a), #000 0); mask: conic-gradient(from 200deg, transparent var(--sp-a), #000 0); animation: sp-draw 1s cubic-bezier(.6, 0, .3, 1) .35s both; }
.sp-shine { position: absolute; inset: 0; background: linear-gradient(105deg, transparent 35%, rgba(255, 255, 255, .85) 50%, transparent 65%); transform: translateX(-120%); animation: sp-shine .8s ease-in-out 1.35s forwards; }
.sp-ring { position: absolute; inset: 0; border: 2px solid #FFB81D; border-radius: 50%; opacity: 0; animation: sp-ring 1.1s ease-out 1.25s; }
.sp-ring.r2 { animation-delay: 1.45s; border-color: rgba(255, 255, 255, .6); }
@keyframes sp-pop { from { opacity: 0; transform: scale(.55) rotate(-25deg); } to { opacity: 1; transform: none; } }
@keyframes sp-draw { from { --sp-a: 0deg; } to { --sp-a: 360deg; } }
@keyframes sp-shine { to { transform: translateX(120%); } }
@keyframes sp-ring { 0% { opacity: .9; transform: scale(.9); } 100% { opacity: 0; transform: scale(1.9); } }

.sp-title { display: flex; font: italic 800 clamp(40px, 7vw, 76px)/.9 var(--display); font-stretch: 75%; text-transform: uppercase; letter-spacing: .01em; }
.sp-title span { display: inline-block; opacity: 0; transform: translateY(40%) skewX(-12deg); animation: sp-letter .5s cubic-bezier(.2, .9, .3, 1.2) forwards; }
.sp-title span { animation-delay: calc(1.05s + var(--i, 0) * 40ms); }
@keyframes sp-letter { to { opacity: 1; transform: none; } }
.sp-sub { margin-top: 10px; font: 600 13px/1 var(--body); letter-spacing: .22em; text-transform: uppercase; color: #FFB81D; opacity: 0; animation: sp-fade .6s ease 1.5s forwards; }
.sp-bar { width: min(260px, 60vw); height: 3px; margin-top: 30px; background: rgba(255, 255, 255, .15); border-radius: 2px; overflow: hidden; opacity: 0; animation: sp-fade .4s ease .6s forwards; }
.sp-bar i { display: block; height: 100%; width: 100%; background: linear-gradient(90deg, #FFB81D, #fff); transform-origin: left; transform: scaleX(0); animation: sp-fill 2.2s cubic-bezier(.4, 0, .2, 1) .6s forwards; }
.sp-status { margin-top: 12px; min-height: 1.4em; font: 500 13px/1.4 var(--body); color: rgba(255, 255, 255, .7); font-variant-numeric: tabular-nums; opacity: 0; animation: sp-fade .4s ease .7s forwards; }
.sp-status b { color: #fff; font-weight: 700; }
@keyframes sp-fade { to { opacity: 1; } }
@keyframes sp-fill { to { transform: scaleX(1); } }

/* salida: la llave gira y se difumina, el texto se va y la pantalla verde se cierra en un círculo */
.splash.out { transition: clip-path .75s cubic-bezier(.7, 0, .3, 1) .35s; clip-path: circle(0% at 50% 45%); }
.splash.out .sp-emb-wrap { animation: sp-spin .8s cubic-bezier(.5, 0, .75, .3) forwards; }
.splash.out .sp-title, .splash.out .sp-sub, .splash.out .sp-bar, .splash.out .sp-status { transition: opacity .3s, transform .4s; opacity: 0; transform: translateY(-10px); }
@keyframes sp-spin { from { opacity: 1; transform: none; } to { opacity: 0; filter: blur(8px); transform: rotateY(540deg) scale(1.6); } }

@media (prefers-reduced-motion: reduce) {
  .splash *, .splash *::before { animation-duration: .01s !important; animation-delay: 0s !important; }
  .splash.out { transition: opacity .3s; clip-path: none; opacity: 0; }
}
@media print { .splash { display: none; } }
.sp-title .sp-hueco { width: .3em; }
.sp-frase { margin-top: 18px; max-width: min(460px, 86vw); font: italic 700 clamp(15px, 2.2vw, 19px)/1.35 var(--display); font-stretch: 85%; color: #fff; opacity: 0; animation: sp-fade .6s ease 1.7s forwards; }
