/* Full-screen gate — wiki-style dark shell + INO branding */
/* Spacing/sizes tuned to match internal wiki login (logo → title → button rhythm). */

:root {
  --launcher-auth-bg: #121214;
  --launcher-auth-wiki-blue: #2b66e8;
  --launcher-auth-logo-size: 5rem;
  --launcher-auth-gap-logo-title: 1rem;
  --launcher-auth-gap-title-button: 1.5rem;
  --launcher-auth-title-min: 1.375rem;
  --launcher-auth-title-max: 1.875rem;
  --launcher-auth-btn-text: 1rem;
  --launcher-auth-btn-radius: 10px;
}

/* Covers the whole viewport before JS runs (module defer / session fetch). */
html.launcher-auth-gate-pending::before {
  content: '';
  position: fixed;
  inset: 0;
  z-index: 99998;
  background: var(--launcher-auth-bg);
  pointer-events: none;
}

.launcher-auth-overlay {
  position: fixed;
  inset: 0;
  z-index: 100000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  background: var(--launcher-auth-bg);
  color: #f4f4f5;
}

.launcher-auth-panel {
  width: min(20rem, 100%);
  text-align: center;
}

.launcher-auth-wiki {
  display: flex;
  flex-direction: column;
  align-items: center;
}

/* Frosted panel only when we need readable error / setup copy */
.launcher-auth-panel--boxed {
  padding: 1.5rem 1.25rem;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  text-align: left;
}

.launcher-auth-panel--boxed h2 {
  text-align: center;
}

.launcher-auth-logo {
  display: block;
  width: var(--launcher-auth-logo-size);
  height: auto;
  margin: 0 auto var(--launcher-auth-gap-logo-title);
  object-fit: contain;
  flex-shrink: 0;
}

.launcher-auth-panel h2 {
  font-size: 1.125rem;
  font-weight: 600;
  margin: 0 0 0.5rem;
  letter-spacing: -0.02em;
}

.launcher-auth-panel h2.launcher-auth-login-title {
  font-size: clamp(var(--launcher-auth-title-min), 3.5vw, var(--launcher-auth-title-max));
  font-weight: 600;
  line-height: 1.28;
  margin: 0 0 var(--launcher-auth-gap-title-button);
  letter-spacing: -0.02em;
  max-width: 24ch;
}

.launcher-auth-error {
  font-size: 0.8125rem;
  color: #fecaca;
  margin: 0 0 0.875rem;
  line-height: 1.4;
  text-align: center;
  max-width: 26rem;
}

.launcher-auth-actions {
  display: flex;
  flex-direction: column;
  gap: 0;
  align-items: center;
  width: 100%;
}

.launcher-auth-google-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.6875rem 1.375rem;
  min-height: 2.75rem;
  border: none;
  border-radius: var(--launcher-auth-btn-radius);
  font-size: var(--launcher-auth-btn-text);
  font-weight: 600;
  cursor: pointer;
  width: auto;
  max-width: 100%;
  box-sizing: border-box;
  transition: filter 0.15s ease, transform 0.1s ease;
}

.launcher-auth-google-btn--wiki {
  background: var(--launcher-auth-wiki-blue);
  color: #fff;
  box-shadow: 0 2px 14px rgba(43, 102, 232, 0.38);
}

.launcher-auth-google-btn--wiki:hover {
  filter: brightness(1.06);
}

.launcher-auth-google-btn--wiki:active {
  transform: scale(0.99);
}

.launcher-auth-google-btn--wiki:disabled {
  opacity: 0.75;
  cursor: not-allowed;
}

.launcher-auth-google-btn--wiki .launcher-auth-spinner {
  border-color: rgba(255, 255, 255, 0.25);
  border-top-color: #fff;
}

.launcher-auth-help-local {
  margin-top: 1.25rem;
  font-size: 0.75rem;
  opacity: 0.72;
  line-height: 1.4;
}

.launcher-auth-help-local code {
  font-size: 0.7rem;
  padding: 0.1rem 0.25rem;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.08);
}

.launcher-auth-spinner {
  width: 1.25rem;
  height: 1.25rem;
  border: 2px solid rgba(255, 255, 255, 0.35);
  border-top-color: #fff;
  border-radius: 50%;
  animation: launcher-auth-spin 0.7s linear infinite;
}

@keyframes launcher-auth-spin {
  to {
    transform: rotate(360deg);
  }
}

