/* Auth / login-adjacent shared classes
 * TASK-150: extracted out of app.css (which is now gated behind !IsLightweightRoute() in
 * App.razor) because these specific classes ARE still used on lightweight routes and on the two
 * raw-HTML (non-Blazor) pages Task.Web/Startup/AuthEndpointExtensions.cs renders directly
 * (/oauth/create-workspace and /oauth/pick-workspace) -- both of those link this file explicitly
 * since they render outside App.razor's own gating entirely. Keep this file scoped to classes an
 * unauthenticated/lightweight surface actually renders; anything app-shell-only (the rest of the
 * former login-page/button/form sections) stays behind in the gated app.css.
 */

/* ── Login page ────────────────────────────────────────────────────────── */

.login-page {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #15131f 0%, #1e1e2e 60%, #2a1f4e 100%);
  padding: 24px;
}

.login-card {
  background: #ffffff;
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 36px;
  width: 100%;
  max-width: 380px;
  box-shadow: 0 8px 32px rgba(0,0,0,0.35);
}

.login-card .app-name {
  font-size: 22px;
  font-weight: 700;
  color: var(--accent);
  margin-bottom: 4px;
}

.login-card .company-name {
  font-size: 13px;
  color: var(--text-muted);
  margin-bottom: 24px;
}

/* Shared LoginCard (DotNetShared.AspNet): match IterDone's marketing teal wordmark (the login
   page renders inside the marketing shell, not the app shell). The extra .dns-login class raises
   specificity above the component's scoped default so this wins regardless of stylesheet order. */
.dns-login.task-login .dns-login__title {
  color: var(--mk-accent, #1ec8a5);
}

/* Legacy workspace-picker markup (Task.Web/Startup/AuthEndpointExtensions.cs' /oauth/pick-workspace
   raw-HTML page -- no Blazor component renders these anymore, but that endpoint still does). */
.btn-workspace {
  display: block;
  width: 100%;
  padding: 12px 16px;
  margin-bottom: 8px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface-1);
  color: var(--text-primary);
  font-size: 14px;
  font-weight: 500;
  text-align: left;
  text-decoration: none;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s;
}
.btn-workspace:hover {
  background: var(--surface-2);
  border-color: var(--accent);
  color: var(--text-primary);
  text-decoration: none;
}

.btn-workspace-slug {
  display: block;
  font-size: 11px;
  font-weight: 400;
  color: var(--text-muted);
  margin-top: 2px;
}

/* ── Buttons (subset used outside the app shell, e.g. InviteAccept.razor) ───────────────── */

.btn {
  padding: 5px 12px;
  border-radius: 5px;
  border: none;
  cursor: pointer;
  font-size: 12px;
  font-weight: 500;
  font-family: inherit;
  transition: background 0.1s, opacity 0.1s;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover { background: var(--accent-hover); }

/* ── Login Pages: admin dark-theme overrides (SuperAdmin/Login.razor -- path contains "/login"
   so it is a lightweight route too) ─────────────────────────────────────────────────────────── */

.login-page-admin {
  background: #0f0f17;
}

.login-page-admin .login-card {
  background: #1a1a2a;
  border-color: #313244;
}

.login-page-admin .login-card .app-name {
  color: #f59e0b;
}

.login-page-admin .admin-label {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: #f59e0b;
  margin-bottom: 16px;
}

.login-page-admin input {
  background: #252535;
  border-color: #313244;
  color: #cdd6f4;
}

/* ── Form Elements (subset used outside the app shell, e.g. InviteAccept.razor) ─────────── */

.form-group { margin-bottom: 16px; }
.form-label { display: block; font-size: 12px; font-weight: 500; color: var(--text-secondary); margin-bottom: 4px; }
.form-control {
  width: 100%;
  padding: 8px 10px;
  border: 1px solid var(--border);
  border-radius: 5px;
  font-size: 13px;
  font-family: inherit;
  color: var(--text-primary);
  background: var(--surface-1);
  outline: none;
  transition: border-color 0.1s;
}
.form-control:focus { border-color: var(--accent); box-shadow: 0 0 0 2px var(--accent-light); }

/* ── Live-demo wizard (/demo, Pages/Demo/DemoWizard.razor) ───────────────────────────────── */

.demo-wizard {
  max-width: 480px;
  margin: 48px auto;
  padding: 0 20px 48px;
  color: var(--text-primary, #0c1220);
}
.demo-wizard h1 {
  font-size: 1.6rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  margin: 0 0 8px;
}
.demo-wizard__step-label {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #0fa888;
  margin: 0 0 12px;
}
.demo-wizard__lead, .demo-wizard__muted, .demo-wizard__intro p {
  color: var(--text-muted, #5c6b80);
  margin: 0 0 20px;
  line-height: 1.5;
}
.demo-wizard__field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 14px;
  font-size: 13px;
  font-weight: 600;
}
.demo-wizard__input {
  padding: 10px 12px;
  border: 1px solid var(--border, #d5dde8);
  border-radius: 8px;
  font-size: 15px;
  font-weight: 500;
}
.demo-wizard__input:focus { outline: 2px solid #1ec8a5; border-color: #1ec8a5; }
.demo-wizard__cta, .demo-wizard__cta--link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #1ec8a5;
  color: #fff !important;
  border: none;
  border-radius: 10px;
  padding: 12px 22px;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  text-decoration: none;
}
.demo-wizard__cta:disabled { opacity: 0.6; cursor: default; }
.demo-wizard__ghost, .demo-wizard__ghost.demo-wizard__cta--link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  color: #0fa888 !important;
  border: 1px solid #0fa888;
  border-radius: 10px;
  padding: 12px 22px;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  text-decoration: none;
}
.demo-wizard__actions, .demo-wizard__finish {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 8px;
}
.demo-wizard__finish { margin-top: 24px; }
.demo-wizard__error { color: #dc2626; font-size: 13px; }
.demo-wizard__ok { color: #15803d; font-size: 14px; margin-bottom: 16px; }
