:root {
  --separator: #d1d5db; /* gray-300 */
}
.dark {
  --separator: #4b5563; /* gray-600 */
}

/* ── Layout ───────────────────────────────────────────────────── */
html,
body {
  height: 100%;
}
body {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 100%;
  padding: 1.5rem;
}

/* ── Card ─────────────────────────────────────────────────────── */
.card {
  padding: 2.5rem 2rem;
  width: 100%;
  max-width: 380px;
  text-align: center;
}

/* ── Branding overrides ───────────────────────────────────────── */
.logo-wrap {
  justify-content: center;
}
.logo-title {
  text-align: left;
}

/* ── Body text ────────────────────────────────────────────────── */
.prompt {
  font-size: 0.9375rem;
  color: var(--text-subtle);
  margin-bottom: 1.5rem;
  line-height: 1.5;
}

/* ── Microsoft sign-in button ─────────────────────────────────── */
.btn-ms {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.625rem;
  width: 100%;
  padding: 0.6875rem 1.25rem;
  background-color: var(--ms-blue);
  color: #fff;
  font-family: inherit;
  font-size: 0.9375rem;
  font-weight: 500;
  border: none;
  border-radius: 0.375rem;
  cursor: pointer;
  transition: background-color 0.15s ease;
  user-select: none;
}
.btn-ms:hover {
  background-color: var(--ms-blue-hover);
}
.btn-ms:active {
  background-color: #005a9e;
}
.btn-ms:focus-visible {
  outline: 2px solid var(--ms-blue);
  outline-offset: 2px;
}
.btn-ms:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

/* Microsoft logo SVG — white version */
.ms-logo {
  flex-shrink: 0;
  width: 1.125rem;
  height: 1.125rem;
}

/* ── Status messages ──────────────────────────────────────────── */
.status {
  margin-top: 1rem;
  font-size: 0.875rem;
  min-height: 1.25rem;
}
.status.error {
  color: #dc2626;
}
.status.info {
  color: var(--text-subtle);
}

/* ── Alternate account sign-in (switch_account=1 only) ────────── */
.switch-account-link {
  display: block;
  margin-top: 0.75rem;
  padding: 0;
  width: 100%;
  font-size: 0.875rem;
  color: var(--text-subtle);
  text-align: center;
  text-decoration: underline;
  text-underline-offset: 2px;
  background: none;
  border: none;
  cursor: pointer;
  font-family: inherit;
}
.switch-account-link:hover {
  color: var(--text-primary);
}
.switch-account-link:focus-visible {
  outline: 2px solid var(--ms-blue);
  outline-offset: 2px;
}
.switch-account-link:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}
.switch-account-link[hidden] {
  display: none;
}

/* ── Request access link ──────────────────────────────────────── */
.request-link {
  display: block;
  margin-top: 1.25rem;
  font-size: 0.875rem;
  color: var(--text-subtle);
  text-align: center;
  text-decoration: none;
}
.request-link:hover {
  color: var(--text-primary);
}

/* ── Local dev sign-in (DEV_AUTH_ENABLED) ─────────────────────── */
.dev-auth-panel {
  margin-bottom: 1rem;
}
.dev-auth-panel[hidden] {
  display: none;
}
.dev-auth-label {
  margin: 0 0 0.75rem;
  font-size: 0.875rem;
  color: var(--text-subtle);
  text-align: center;
}
.dev-auth-actions {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}
.btn-dev {
  display: block;
  width: 100%;
  padding: 0.625rem 1rem;
  font-size: 0.9375rem;
  font-weight: 500;
  font-family: inherit;
  color: var(--text-primary);
  background: var(--surface-elevated, #f3f4f6);
  border: 1px solid var(--border-subtle, #d1d5db);
  border-radius: 0.375rem;
  cursor: pointer;
  transition:
    background 0.15s,
    border-color 0.15s;
}
.btn-dev:hover {
  background: var(--surface-hover, #e5e7eb);
  border-color: var(--border-strong, #9ca3af);
}
.btn-dev:focus-visible {
  outline: 2px solid var(--ms-blue);
  outline-offset: 2px;
}
.btn-dev:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}
.login-ms-hidden {
  display: none !important;
}
