/* Standalone styles for /login. Doesn't extend shell.html or shell.css
   because the user is not yet authenticated and we want a minimal, fast
   first paint with no dependence on the rest of the app. */

:root {
  --brand: #5b21b6;
  --brand-hover: #4c1d95;
  --bg-app: #fafaf9;
  --bg-card: #ffffff;
  --text-primary: #18181b;
  --text-secondary: #52525b;
  --border-subtle: rgba(0, 0, 0, 0.08);
  --border-focus: #5b21b6;
  --error-bg: #fee2e2;
  --error-text: #991b1b;
  --error-border: #fecaca;
  --radius-md: 8px;
  --radius-lg: 12px;
}

*, *::before, *::after { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  height: 100%;
  background: var(--bg-app);
  color: var(--text-primary);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Inter",
               Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 14px;
  line-height: 1.5;
}

body {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}

.login-card {
  width: 100%;
  max-width: 380px;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 32px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04),
              0 8px 24px rgba(0, 0, 0, 0.06);
}

.login-title {
  margin: 0 0 4px;
  font-size: 20px;
  font-weight: 600;
  letter-spacing: -0.01em;
}

.login-sub {
  margin: 0 0 20px;
  color: var(--text-secondary);
  font-size: 13px;
}

.login-sub code {
  font-family: ui-monospace, SFMono-Regular, "SF Mono", Menlo, monospace;
  font-size: 12px;
  background: rgba(0, 0, 0, 0.05);
  padding: 1px 5px;
  border-radius: 4px;
}

.login-error {
  background: var(--error-bg);
  color: var(--error-text);
  border: 1px solid var(--error-border);
  border-radius: var(--radius-md);
  padding: 10px 12px;
  font-size: 13px;
  margin-bottom: 16px;
}

.login-form {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.login-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.login-label {
  font-size: 12px;
  font-weight: 500;
  color: var(--text-secondary);
}

.login-form input {
  width: 100%;
  padding: 10px 12px;
  font-size: 14px;
  font-family: inherit;
  color: var(--text-primary);
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  transition: border-color 0.15s, box-shadow 0.15s;
}

.login-form input:focus {
  outline: none;
  border-color: var(--border-focus);
  box-shadow: 0 0 0 3px rgba(91, 33, 182, 0.15);
}

.login-form input[readonly] {
  background: rgba(0, 0, 0, 0.03);
  color: var(--text-secondary);
  cursor: default;
}

.login-hint {
  display: block;
  font-size: 11px;
  color: var(--text-secondary);
  margin-top: 4px;
}

.login-submit {
  margin-top: 4px;
  padding: 10px 16px;
  font-size: 14px;
  font-weight: 500;
  font-family: inherit;
  color: #ffffff;
  background: var(--brand);
  border: none;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: background-color 0.15s;
}

.login-submit:hover { background: var(--brand-hover); }
.login-submit:focus { outline: none; box-shadow: 0 0 0 3px rgba(91, 33, 182, 0.30); }
.login-submit:active { transform: translateY(1px); }
