body:not(.is-unlocked) .app,
body:not(.is-unlocked) .toast-region {
  visibility: hidden;
}

.gate {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: grid;
  place-items: center;
  padding: 24px;
  font-family: var(--font-shell);
  background:
    radial-gradient(circle at 20% 10%, rgb(225 203 145 / 25%), transparent 45%),
    radial-gradient(circle at 85% 90%, rgb(176 137 70 / 18%), transparent 40%), var(--nav-bg);
}

.gate__card {
  display: grid;
  gap: 10px;
  justify-items: center;
  width: min(380px, 100%);
  padding: 36px 32px 28px;
  border-radius: var(--radius-xl);
  text-align: center;
  background: var(--surface);
  box-shadow: var(--shadow-lg);
  animation: pop-in 220ms var(--ease);
}

.gate.is-shaking .gate__card {
  animation: gate-shake 320ms var(--ease);
}

.gate__logo {
  width: 64px;
  height: 64px;
  object-fit: contain;
}

.gate__brand {
  font-family: var(--font-brand);
  font-size: var(--fs-lg);
  font-weight: 800;
  color: var(--text);
}

.gate__brand span {
  display: block;
  margin-top: 2px;
  font-family: var(--font-shell);
  font-size: var(--fs-2xs);
  font-weight: 700;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  color: var(--gold-700);
}

.gate__title {
  margin-top: 14px;
  font-size: var(--fs-xl);
  font-weight: 700;
}

.gate__hint {
  font-size: var(--fs-sm);
  color: var(--text-muted);
}

.gate__input {
  width: 100%;
  height: 56px;
  margin-top: 8px;
  padding: 0 16px;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  font-size: 28px;
  letter-spacing: 0.5em;
  text-align: center;
  text-indent: 0.5em;
  background: var(--surface-soft);
  transition:
    border-color var(--duration) var(--ease),
    box-shadow var(--duration) var(--ease);
}

.gate__input::placeholder {
  color: var(--text-faint);
}

.gate__input:focus {
  outline: none;
  border-color: var(--gold-500);
  box-shadow: var(--focus-ring);
  background: var(--surface);
}

.gate__input:disabled {
  opacity: 0.6;
}

.gate__error {
  min-height: 18px;
  font-size: var(--fs-sm);
  font-weight: 600;
  color: var(--red-500);
}

.gate__submit {
  height: 44px;
}

@keyframes gate-shake {
  0%,
  100% {
    transform: translateX(0);
  }

  20%,
  60% {
    transform: translateX(-8px);
  }

  40%,
  80% {
    transform: translateX(8px);
  }
}
