/* ════════════════════════════════════════════════════════════
   splash.css — Splash, bye-screen y animaciones de arranque
   ════════════════════════════════════════════════════════════ */

/* ── Splash ─────────────────────────────────────────────── */

.splash {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(to top,
    var(--color-bg)            0%,
    var(--color-bg)            40%,
    color-mix(in srgb, var(--color-accent) 22%, var(--color-bg)) 100%);
  opacity: 1;
  transition: opacity 0.6s ease;
}

.splash--fade { opacity: 0; pointer-events: none; transition: opacity 0.4s ease; }

.splash__card {
  position: relative;
  width: 360px;
  min-height: 310px;
  border-radius: 10px;
  border: 1px solid rgba(255,255,255,0.45);
  background: var(--color-surface-soft);
  box-shadow: 0 1px 0 rgba(255,255,255,0.9) inset,
              0 -2px 4px rgba(0,0,0,0.12) inset,
              0 0 0 1px rgba(0,0,0,0.10),
              0 4px 6px rgba(0,0,0,0.10),
              0 20px 60px rgba(0,0,0,0.28),
              0 40px 80px rgba(0,0,0,0.12);
  display: flex;
  flex-direction: column;
  padding: 28px 28px 0;
}

.splash__top {
  display: flex;
  flex-direction: column;
  gap: 4px;
  background: var(--lyt-band-bg);
  margin: -28px -28px 0;
  padding: 20px 28px 16px;
  border-radius: 10px 10px 0 0;
}

.splash__title-row {
  display: flex;
  align-items: center;
}

.splash__subtitle {
  font-family: system-ui, sans-serif;
  font-size: 12px;
  font-weight: 300;
  letter-spacing: 0.08em;
  color: rgba(255,255,255,0.75);
}

.splash__title {
  font-family: system-ui, sans-serif;
  font-size: 22px;
  font-weight: 400;
  letter-spacing: 0.06em;
  color: #fff;
}

.splash__version {
  font-family: system-ui, sans-serif;
  font-size: 10px;
  font-weight: 400;
  letter-spacing: 0.04em;
  color: var(--color-text-soft);
  opacity: .65;
  margin-top: 6px;
  text-align: center;
}

.splash__mid {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 0 0 13px;
  position: relative;
}

.splash__tagline {
  font-family: system-ui, sans-serif;
  font-size: 20px;
  font-weight: 600;
  letter-spacing: 0.08em;
  color: var(--color-text-soft);
  position: relative;
  display: inline-block;
  overflow: hidden;
}

.splash__tagline::after {
  content: '';
  position: absolute;
  top: 0; bottom: 0;
  width: 28px;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,.72), transparent);
  animation: tagline-scan 3s ease-in-out infinite;
  animation-delay: .8s;
}

@keyframes tagline-scan {
  0%        { left: -28px; }
  60%, 100% { left: 100%;  }
}

.splash__foot {
  margin: 0 -28px;
}

.splash__divider {
  border: none;
  border-top: 1px solid var(--color-border);
}

.splash__sig {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 7px 16px 10px;
  background: #ffffff;
  border-radius: 0 0 10px 10px;
}

.splash__escuadra {
  width: 20px;
  height: 20px;
  opacity: 0.85;
  flex-shrink: 0;
}

.splash__brand {
  font-family: system-ui, sans-serif;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.14em;
  background: linear-gradient(135deg, #444444 0%, #888888 30%, #cccccc 55%, #999999 80%, #444444 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.splash__enter-btn {
  background: color-mix(in srgb, var(--color-accent) 65%, white);
  color: #fff;
  border: none;
  border-radius: var(--radius-pill);
  padding: 6px 18px;
  font-size: 11px;
  letter-spacing: 0.05em;
  font-family: system-ui, sans-serif;
  cursor: pointer;
  opacity: 1;
  pointer-events: none;
  transition: box-shadow 0.2s, transform 0.15s;
}

.splash__enter-btn--ready  { pointer-events: auto; }
.splash__enter-btn--ready:hover {
  box-shadow: 0 3px 10px rgba(0,0,0,0.22);
  transform: scale(1.03);
}

/* ── Pájaro del título ── */

.spl-title-bird {
  position: absolute;
  top: 38px;
  right: 20px;
  width: 32px;
  height: 16px;
  transform-origin: center;
  opacity: 1;
}

.spl-title-bird__wing-l {
  transform-origin: 50px 32px;
  animation: byeFlapL 0.5s ease-in-out infinite alternate;
}

.spl-title-bird__wing-r {
  transform-origin: 50px 32px;
  animation: byeFlapR 0.5s ease-in-out infinite alternate;
  animation-delay: .08s;
}

@keyframes titleBirdTakeoff {
  0%   { transform: scale(1)   translate(0px,   0px);   opacity: 1; }
  15%  { transform: scale(1.2) translate(4px,  -6px);   opacity: 1; }
  40%  { transform: scale(2.2) translate(20px, -30px);  opacity: 1; }
  70%  { transform: scale(4)   translate(60px, -80px);  opacity: 0.6; }
  100% { transform: scale(6)   translate(120px,-160px); opacity: 0; }
}

/* ── Pájaro grande (desactivado) ── */

.spl-bird { display: none; }

.spl-bird__wing-l {
  transform-origin: 50px 32px;
  animation: byeFlapL 1.1s ease-in-out infinite alternate;
}

.spl-bird__wing-r {
  transform-origin: 50px 32px;
  animation: byeFlapR 1.1s ease-in-out infinite alternate;
  animation-delay: .15s;
}

@keyframes splBirdFly {
  0%   { transform: translateX(-55vw) translateY(10px);  opacity: 0;  }
  4%   {                                                 opacity: .7; }
  18%  { transform: translateX(0px)   translateY(0px);   opacity: .7; }
  28%  { transform: translateX(8px)   translateY(-8px);  }
  38%  { transform: translateX(18px)  translateY(-12px); }
  48%  { transform: translateX(12px)  translateY(-18px); }
  58%  { transform: translateX(26px)  translateY(-22px); }
  68%  { transform: translateX(20px)  translateY(-28px); }
  78%  { transform: translateX(32px)  translateY(-32px); }
  88%  { transform: translateX(28px)  translateY(-38px); }
  100% { transform: translateX(38px)  translateY(-44px); opacity: .6; }
}

/* ── Animaciones generales de arranque ── */

@keyframes splashIn {
  from { opacity: 0; transform: translateY(10px); }
  to   { opacity: 1; transform: translateY(0);    }
}

@keyframes appFadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}

/* ── Bye-screen ──────────────────────────────────────────── */

.bye-screen {
  cursor: none;
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 100vh;
  gap: 16px;
  background: linear-gradient(to top,
    var(--color-surface-strong)  0%,
    var(--color-bg)             55%,
    var(--color-surface-soft)  100%);
  animation: byeScreenOut 1.3s ease forwards 9s;
}

.bye-screen__text {
  font-size: 18px;
  font-weight: 500;
  color: var(--color-text-muted);
  font-family: var(--font-family);
  opacity: 0;
  animation: byeTextIn 1.2s ease forwards 0.5s;
}

@keyframes byeTextIn {
  from { opacity: 0; transform: translateY(6px); }
  to   { opacity: 1; transform: translateY(0);   }
}

@keyframes byeScreenOut {
  from { opacity: 1; }
  to   { opacity: 0; }
}

.bye-bird {
  position: absolute;
  pointer-events: none;
  opacity: .70;
  animation: byeFly 9s cubic-bezier(.3,0,.7,1) forwards;
}

.bye-bird__wing-l {
  transform-origin: 50px 32px;
  animation: byeFlapL 1.1s ease-in-out infinite alternate;
}

.bye-bird__wing-r {
  transform-origin: 50px 32px;
  animation: byeFlapR 1.1s ease-in-out infinite alternate;
  animation-delay: .15s;
}

@keyframes byeFly {
  0%   { transform: translateX(-140px) translateY(0px);               }
  40%  { transform: translateX(38vw)   translateY(-28px);             }
  100% { transform: translateX(calc(100vw + 140px)) translateY(8px);  }
}

@keyframes byeFlapL {
  from { transform: rotate(0deg);   }
  to   { transform: rotate(-16deg); }
}

@keyframes byeFlapR {
  from { transform: rotate(0deg);  }
  to   { transform: rotate(16deg); }
}
