.gideon-loading-splash {
  position: fixed;
  z-index: 1300;
  inset: 0;
  display: grid;
  place-items: center;
  padding: max(12px, env(safe-area-inset-top)) max(12px, env(safe-area-inset-right))
    max(12px, env(safe-area-inset-bottom)) max(12px, env(safe-area-inset-left));
  background: rgb(10 5 16 / .72);
  pointer-events: none;
}

.gideon-loading-card {
  box-sizing: border-box;
  width: min(100%, 640px, max(160px, calc((100svh - 96px) * 1.7778)));
  overflow: hidden;
  border: 1px solid #695676;
  border-radius: 15px;
  background: #17101f;
  box-shadow: 0 18px 68px #050309b3;
  pointer-events: auto;
}

.gideon-loading-scene {
  margin: 0;
  background: #1d1726;
}

.gideon-loading-scene[hidden] { display: none; }

.gideon-loading-scene canvas {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 9;
}

.gideon-loading-caption {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px clamp(12px, 3vw, 23px);
  color: #fff8ff;
}

.gideon-loading-caption strong {
  font-size: clamp(.94rem, 3vw, 1.3rem);
  line-height: 1.22;
}

.gideon-loading-caption button {
  display: grid;
  flex: none;
  width: 40px;
  height: 40px;
  place-items: center;
  padding: 0;
  border: 1px solid #685675;
  border-radius: 7px;
  background: #22172c;
  color: #fff8ff;
  font-size: 1.25rem;
  line-height: 1;
  cursor: pointer;
}

.gideon-loading-caption button:hover { background: #39284a; }
.gideon-loading-caption button:focus-visible { outline: 2px solid #91e4d5; outline-offset: 2px; }

.gideon-loading-track {
  height: 3px;
  overflow: hidden;
  background: #3d304b;
}

.gideon-loading-track i {
  display: block;
  width: 45%;
  height: 100%;
  background: linear-gradient(90deg, #b574bc, #84dac9);
  animation: gideon-loading-sweep 1.5s ease-in-out infinite;
}

@keyframes gideon-loading-sweep {
  from { transform: translateX(-100%); }
  to { transform: translateX(225%); }
}

@media (prefers-reduced-motion: reduce) {
  .gideon-loading-track i { width: 100%; animation: none; }
}
