/* ============================================================
   MetriFi Design System — tokens + auth-page styles
   (from Claude Design). Dark-only. Linked by the IdP Blade views.
   ============================================================ */
@import url("https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600&family=Space+Grotesk:wght@500;600;700&display=swap");

:root {
  --canvas:   #0F0A1A;
  --surface:  #1A1230;
  --elevated: #241845;

  --violet:        #A074FF;
  --violet-hover:  #B088FF;
  --green:         #7DD4AA;
  --green-hover:   #93E0BB;
  --red:           #E85D56;

  --text:   #E8E4F0;
  --muted:  #A89FC0;

  --line:        rgba(255, 255, 255, 0.08);
  --line-strong: rgba(255, 255, 255, 0.14);
  --violet-20:   rgba(160, 116, 255, 0.20);
  --green-20:    rgba(125, 212, 170, 0.20);

  --font-display: "Space Grotesk", "Segoe UI", system-ui, sans-serif;
  --font-body: "Inter", "Segoe UI", system-ui, sans-serif;
  --font-mono: ui-monospace, "SF Mono", "Menlo", "Consolas", monospace;

  --radius-button: 2px;
  --radius-sm: 6px;
  --radius-md: 12px;

  --ease-standard: cubic-bezier(0.4, 0, 0.2, 1);
  --inset-hi: inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

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

body {
  margin: 0;
  min-height: 100vh;
  background: var(--canvas);
  color: var(--text);
  font-family: var(--font-body);
  font-weight: 300;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}

::selection { background: var(--violet-20); color: var(--text); }

.wrap { width: 100%; max-width: 400px; }

.logo { display: block; height: 26px; margin: 0 auto 26px; }

.title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.5rem;
  letter-spacing: -0.015em;
  text-align: center;
  margin: 0 0 6px;
  color: var(--text);
}
/* Emphasis on the canvas (titles sit above the card) = violet */
.title em { color: var(--violet); font-style: normal; }
.sub { color: var(--muted); text-align: center; margin: 0 0 24px; font-size: 14px; }

.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  padding: 28px;
  box-shadow: var(--inset-hi);
}

/* Monospace field labels — the Instrument voice */
label {
  display: block;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
  margin: 16px 0 7px;
}
label:first-of-type { margin-top: 0; }

input[type="text"], input[type="email"], input[type="password"] {
  width: 100%;
  padding: 11px 13px;
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-family: var(--font-body);
  background: var(--canvas);
  border: 1px solid var(--line-strong);
  color: var(--text);
}
input::placeholder { color: var(--muted); opacity: 0.7; }
input:focus { outline: none; border-color: var(--violet); }

/* Primary CTA — green fill, canvas text, hover violet (per the system) */
.btn {
  width: 100%;
  margin-top: 24px;
  padding: 12px;
  border: 0;
  border-radius: var(--radius-button);
  font-family: var(--font-body);
  font-weight: 500;
  font-size: 15px;
  cursor: pointer;
  background: var(--green);
  color: var(--canvas);
  transition: background 140ms var(--ease-standard);
}
.btn:hover { background: var(--violet); }
.btn:active { transform: translateY(1px); }

/* Secondary / ghost — violet text + border */
.btn-ghost {
  background: transparent;
  color: var(--violet);
  border: 1.5px solid var(--violet);
}
.btn-ghost:hover { background: transparent; color: var(--violet-hover); border-color: var(--violet-hover); }

.row { display: flex; gap: 10px; }
.row .btn, .row .btn-ghost { margin-top: 0; }

.err {
  background: rgba(232, 93, 86, 0.10);
  border: 1px solid rgba(232, 93, 86, 0.35);
  color: #F2A6A1;
  border-radius: var(--radius-sm);
  padding: 10px 12px;
  font-size: 13px;
  margin-bottom: 4px;
  line-height: 1.5;
}

/* On-card accent = green (violet is canvas-only) */
.foot { color: var(--muted); text-align: center; font-size: 13px; margin-top: 20px; line-height: 1.5; }
.foot a, .link { color: var(--green); font-weight: 500; }

/* Consent screen */
.scopes { list-style: none; padding: 0; margin: 0 0 20px; }
.scopes li {
  padding: 11px 0;
  border-bottom: 1px solid var(--line);
  font-size: 14px;
  color: var(--text);
  display: flex;
  align-items: center;
  gap: 10px;
}
.scopes li:last-child { border-bottom: 0; }
.scopes li::before {
  content: "";
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--green); flex-shrink: 0;
}
.who { color: var(--muted); text-align: center; font-size: 12px; margin-top: 18px; font-family: var(--font-mono); }
