/*
 * LabsNinja customer-portal shared stylesheet (cycle 7).
 *
 * Consolidates the per-template inline <style> blocks that grew across
 * cycles 2-6. Every customer-facing surface (signup, portal_login,
 * verify_otp, onboarding, checklist, portal_dashboard, connector,
 * activity, provisioned) now links this file instead of carrying its own
 * ~80-100 line <style> block.
 *
 * The cycle-2 design tokens (`/static/css/tokens.css` + tokens-accent.css)
 * provide `--ln-*` custom properties; this stylesheet consumes them. The
 * existing CSP allows external stylesheets via `style-src 'self'` and the
 * Google Fonts host — no inline styles required.
 *
 * Naming convention: all classes are prefixed `.ln-` to avoid collisions
 * with the operator portal's hand-rolled `app.css` classes.
 */

/* ---------- Reset + base ---------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

body.ln-customer {
  background: var(--ln-bg);
  color: var(--ln-fg-hi);
  font-family: var(--ln-font-ui);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 2rem 1rem;
  line-height: 1.55;
}

a { color: var(--ln-indigo); text-decoration: none; }
a:hover { text-decoration: underline; }

/* ---------- Top nav ---------- */
.ln-nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: 56px;
  background: rgba(10, 14, 21, 0.85);
  backdrop-filter: blur(12px) saturate(160%);
  -webkit-backdrop-filter: blur(12px) saturate(160%);
  border-bottom: 1px solid var(--ln-border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 2rem;
  z-index: 100;
}
.ln-logo {
  font-size: .9rem;
  font-weight: 800;
  letter-spacing: -.02em;
  color: var(--ln-fg-hi);
  text-decoration: none;
}
.ln-logo span { color: var(--ln-indigo); }
.ln-nav-r {
  display: flex;
  align-items: center;
  gap: 1rem;
  font-size: .82rem;
  color: var(--ln-fg-mute);
}
.ln-nav-r a { color: var(--ln-fg-mute); }
.ln-nav-r a:hover { color: var(--ln-fg); text-decoration: none; }

/* ---------- Layout shells ---------- */
.ln-shell {
  width: 100%;
  margin-top: 72px;
}
.ln-shell-narrow { max-width: 480px; }
.ln-shell-wide   { max-width: 720px; }
.ln-shell-portal { max-width: 1080px; }

/* ---------- Headers / hero ---------- */
.ln-eyebrow {
  font-size: .7rem;
  font-weight: 600;
  color: var(--ln-fg-mute);
  font-family: var(--ln-font-mono);
  text-transform: uppercase;
  letter-spacing: .08em;
  margin-bottom: .5rem;
}
.ln-h1 {
  font-size: clamp(1.5rem, 3vw, 1.95rem);
  font-weight: 500;
  letter-spacing: -.025em;
  line-height: 1.15;
  margin-bottom: .6rem;
}
.ln-h2 {
  font-size: 1.05rem;
  font-weight: 600;
  letter-spacing: -.01em;
  margin-bottom: .8rem;
}
.ln-lede {
  font-size: .92rem;
  color: var(--ln-fg);
  line-height: 1.55;
  margin-bottom: 1.5rem;
}
.ln-lede b { color: var(--ln-fg-hi); font-weight: 600; }

/* ---------- Cards ---------- */
.ln-card {
  background: var(--ln-surface);
  border: 1px solid var(--ln-border);
  border-radius: var(--ln-radius-lg);
  padding: 1.5rem 1.75rem;
  margin-bottom: 1.25rem;
}
.ln-card-tight  { padding: 1.1rem 1.4rem; }
.ln-card-flush  { padding: 0; overflow: hidden; }
.ln-card-row {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding-bottom: 1.25rem;
  border-bottom: 1px solid var(--ln-rule);
  margin-bottom: 1.25rem;
}
.ln-card-row:last-child { border-bottom: none; margin-bottom: 0; padding-bottom: 0; }

.ln-grid-2 {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1rem 1.5rem;
}

/* ---------- KV grid ---------- */
.ln-kv-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: .85rem 1.5rem;
}
@media (max-width: 540px) { .ln-kv-grid { grid-template-columns: 1fr; } }
.ln-kv-row { display: flex; flex-direction: column; gap: .25rem; }
.ln-k {
  font-size: .68rem;
  font-weight: 600;
  color: var(--ln-fg-mute);
  font-family: var(--ln-font-mono);
  text-transform: uppercase;
  letter-spacing: .08em;
}
.ln-v { font-size: .88rem; color: var(--ln-fg-hi); word-break: break-all; }
.ln-v-mono {
  font-family: var(--ln-font-mono);
  font-size: .82rem;
  color: var(--ln-ink-soft);
}

/* ---------- Buttons ---------- */
.ln-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: .7rem 1.1rem;
  border-radius: var(--ln-radius);
  font-size: .9rem;
  font-weight: 600;
  text-decoration: none !important;
  cursor: pointer;
  border: 1px solid transparent;
  transition: filter .15s, border-color .15s, background .15s;
  font-family: inherit;
  white-space: nowrap;
}
.ln-btn:hover { text-decoration: none; }
.ln-btn-primary {
  background: var(--ln-indigo);
  color: var(--ln-indigo-in) !important;
  border-color: var(--ln-indigo);
}
.ln-btn-primary:hover { filter: brightness(1.1); }
.ln-btn-ghost {
  background: transparent;
  color: var(--ln-fg-hi) !important;
  border-color: var(--ln-border-hi);
}
.ln-btn-ghost:hover { border-color: var(--ln-fg-mute); }
.ln-btn-block { display: flex; width: 100%; }
.ln-btn-sm { padding: .5rem .85rem; font-size: .82rem; }
.ln-btn[disabled],
.ln-btn-disabled {
  opacity: .55;
  cursor: not-allowed;
  pointer-events: none;
}

/* ---------- Forms ---------- */
.ln-field {
  display: flex;
  flex-direction: column;
  gap: .35rem;
  margin-bottom: 1rem;
}
.ln-label {
  font-size: .72rem;
  font-weight: 600;
  color: var(--ln-fg-mute);
  text-transform: uppercase;
  letter-spacing: .06em;
}
.ln-input {
  width: 100%;
  background: var(--ln-surface-2);
  border: 1px solid var(--ln-border);
  border-radius: var(--ln-radius);
  color: var(--ln-fg-hi);
  font-family: inherit;
  font-size: .9rem;
  padding: .65rem .85rem;
  outline: none;
  transition: border-color .15s, box-shadow .15s;
}
.ln-input::placeholder { color: var(--ln-fg-dim); }
.ln-input:focus {
  border-color: var(--ln-indigo);
  box-shadow: 0 0 0 3px var(--ln-indigo-soft);
}
.ln-hint {
  font-size: .76rem;
  color: var(--ln-fg-mute);
  margin-top: .2rem;
  line-height: 1.45;
}
.ln-checkbox-row {
  display: flex;
  align-items: flex-start;
  gap: .55rem;
  font-size: .85rem;
  color: var(--ln-fg);
  line-height: 1.55;
  margin-bottom: 1rem;
}
.ln-checkbox-row input[type=checkbox] {
  margin-top: 3px;
  accent-color: var(--ln-indigo);
}

/* ---------- Banners ---------- */
.ln-banner {
  padding: .7rem .95rem;
  border-radius: var(--ln-radius-md);
  font-size: .83rem;
  margin-bottom: 1.25rem;
  display: flex;
  align-items: start;
  gap: .6rem;
}
.ln-banner-error  { background: var(--ln-ruby-soft);  border: 1px solid var(--ln-ruby);         color: var(--ln-ruby);  }
.ln-banner-info   { background: var(--ln-blade-soft); border: 1px solid var(--ln-blade-border); color: var(--ln-blade); }
.ln-banner-warn   { background: var(--ln-amber-soft); border: 1px solid var(--ln-amber);        color: var(--ln-amber); }

/* ---------- Pills / status badges ---------- */
.ln-pill {
  display: inline-flex;
  align-items: center;
  gap: .35rem;
  padding: .18rem .55rem;
  border-radius: var(--ln-radius-pill);
  font-size: .7rem;
  font-weight: 600;
  font-family: var(--ln-font-mono);
  text-transform: uppercase;
  letter-spacing: .08em;
  border: 1px solid transparent;
}
.ln-pill::before {
  content: '';
  width: 6px; height: 6px;
  border-radius: 50%;
  background: currentColor;
}
.ln-pill-ok      { background: var(--ln-blade-soft); color: var(--ln-blade);  border-color: var(--ln-blade-border); }
.ln-pill-warn    { background: var(--ln-amber-soft); color: var(--ln-amber);  border-color: var(--ln-amber); }
.ln-pill-error   { background: var(--ln-ruby-soft);  color: var(--ln-ruby);   border-color: var(--ln-ruby); }
.ln-pill-info    { background: var(--ln-sky-soft);   color: var(--ln-sky);    border-color: var(--ln-sky); }
.ln-pill-mute    { background: var(--ln-surface-2);  color: var(--ln-fg-mute); border-color: var(--ln-border); }
.ln-pill-no-dot::before { display: none; }

/* ---------- Dividers ---------- */
.ln-divider {
  margin: 1.25rem 0;
  border: none;
  border-top: 1px solid var(--ln-rule);
}
.ln-or-divider {
  display: flex;
  align-items: center;
  gap: .75rem;
  margin: 1rem 0;
  color: var(--ln-fg-mute);
  font-size: .75rem;
  font-family: var(--ln-font-mono);
  text-transform: uppercase;
  letter-spacing: .08em;
}
.ln-or-divider::before,
.ln-or-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--ln-rule);
}

/* ---------- OTP cells (cycle 6) ---------- */
.ln-otp-row {
  display: flex;
  gap: .6rem;
  justify-content: center;
  margin-bottom: 1.5rem;
}
.ln-otp-cell {
  position: relative;
  width: 48px;
  height: 60px;
}
.ln-otp-cell input {
  width: 100%; height: 100%;
  background: var(--ln-surface);
  border: 1.5px solid var(--ln-border);
  border-radius: var(--ln-radius);
  color: var(--ln-fg-hi);
  font-family: var(--ln-font-mono);
  font-size: 1.55rem;
  text-align: center;
  font-weight: 600;
  outline: none;
  transition: border-color .15s, box-shadow .15s;
  -moz-appearance: textfield;
}
.ln-otp-cell input::-webkit-outer-spin-button,
.ln-otp-cell input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.ln-otp-cell input:focus {
  border-color: var(--ln-indigo);
  box-shadow: 0 0 0 3px var(--ln-indigo-soft);
}
.ln-otp-fallback {
  background: var(--ln-surface-2);
  border: 1.5px solid var(--ln-border);
  border-radius: var(--ln-radius);
  color: var(--ln-fg-hi);
  font-family: var(--ln-font-mono);
  font-size: 1.2rem;
  letter-spacing: .4em;
  text-align: center;
  padding: .75rem 1rem;
  outline: none;
  width: 100%;
  margin-bottom: 1.5rem;
}
.ln-otp-fallback:focus {
  border-color: var(--ln-indigo);
  box-shadow: 0 0 0 3px var(--ln-indigo-soft);
}
/* By default the no-JS fallback input is hidden; <noscript> below toggles it. */
.ln-otp-no-js-only { display: none; }

/* ---------- Onboarding "Workspace ready" mark ---------- */
.ln-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 72px; height: 72px;
  border-radius: var(--ln-radius-xl);
  background: var(--ln-blade-soft);
  border: 1px solid var(--ln-blade-border);
  color: var(--ln-blade);
  font-size: 32px;
  font-weight: 700;
  margin-bottom: 1.25rem;
  box-shadow: var(--ln-glow-blade);
}
.ln-envelope {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 56px; height: 56px;
  border-radius: var(--ln-radius-xl);
  background: var(--ln-indigo-soft);
  border: 1px solid var(--ln-indigo-border);
  color: var(--ln-indigo);
  font-size: 24px;
  margin-bottom: 1.25rem;
}
.ln-workspace-avatar {
  width: 48px; height: 48px;
  border-radius: var(--ln-radius-md);
  background: var(--ln-indigo-soft);
  border: 1px solid var(--ln-indigo-border);
  color: var(--ln-indigo);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  letter-spacing: .05em;
}
.ln-workspace-meta { flex: 1; }
.ln-workspace-name { font-size: 1rem; font-weight: 600; color: var(--ln-fg-hi); }
.ln-workspace-sub {
  font-size: .8rem;
  color: var(--ln-fg-mute);
  margin-top: .2rem;
  font-family: var(--ln-font-mono);
  text-transform: uppercase;
  letter-spacing: .06em;
}

/* ---------- Provisioned list (onboarding "We just provisioned") ---------- */
.ln-provisioned-title {
  font-size: .72rem;
  font-weight: 600;
  color: var(--ln-fg-mute);
  font-family: var(--ln-font-mono);
  text-transform: uppercase;
  letter-spacing: .08em;
  margin-bottom: .75rem;
}
.ln-provisioned-list { list-style: none; padding: 0; margin: 0; }
.ln-provisioned-list li {
  display: flex;
  align-items: center;
  gap: .6rem;
  padding: .5rem 0;
  border-bottom: 1px solid var(--ln-rule);
  font-size: .88rem;
  color: var(--ln-fg);
}
.ln-provisioned-list li:last-child { border-bottom: none; }
.ln-provisioned-list li::before {
  content: '✓';
  color: var(--ln-blade);
  font-weight: 700;
}

/* ---------- Checklist (cycle 6) ---------- */
.ln-progress {
  display: flex;
  align-items: center;
  gap: .5rem;
  margin-top: 1rem;
  font-size: .78rem;
  color: var(--ln-fg-mute);
  font-family: var(--ln-font-mono);
  text-transform: uppercase;
  letter-spacing: .08em;
}
.ln-progress-bar {
  flex: 1;
  height: 6px;
  background: var(--ln-surface-2);
  border-radius: var(--ln-radius-pill);
  overflow: hidden;
  max-width: 280px;
}
.ln-progress-fill {
  height: 100%;
  background: var(--ln-blade);
  border-radius: var(--ln-radius-pill);
  transition: width .3s;
}
.ln-items {
  display: flex;
  flex-direction: column;
  gap: .75rem;
}
.ln-item {
  background: var(--ln-surface);
  border: 1px solid var(--ln-border);
  border-radius: var(--ln-radius-lg);
  padding: 1.1rem 1.4rem;
  display: grid;
  grid-template-columns: 36px 1fr auto;
  gap: 1rem;
  align-items: start;
}
.ln-item.is-done { border-color: var(--ln-blade-border); }
.ln-item-n {
  width: 32px; height: 32px;
  border-radius: var(--ln-radius-md);
  background: var(--ln-surface-2);
  border: 1px solid var(--ln-border);
  color: var(--ln-fg);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  font-size: .88rem;
  font-family: var(--ln-font-mono);
}
.ln-item.is-done .ln-item-n {
  background: var(--ln-blade-soft);
  color: var(--ln-blade);
  border-color: var(--ln-blade-border);
}
.ln-item-body { min-width: 0; }
.ln-item-label { font-size: .94rem; font-weight: 600; color: var(--ln-fg-hi); margin-bottom: .3rem; }
.ln-item-state {
  font-size: .74rem;
  font-weight: 600;
  color: var(--ln-fg-mute);
  font-family: var(--ln-font-mono);
  text-transform: uppercase;
  letter-spacing: .06em;
  display: inline-flex;
  align-items: center;
  gap: .4rem;
  padding: .18rem .55rem;
  border-radius: var(--ln-radius-pill);
  background: var(--ln-surface-2);
  border: 1px solid var(--ln-border);
  margin-bottom: .45rem;
}
.ln-item-state::before {
  content: '';
  width: 5px; height: 5px;
  border-radius: 50%;
  background: currentColor;
}
.ln-item-state.is-done    { background: var(--ln-blade-soft); border-color: var(--ln-blade-border); color: var(--ln-blade); }
.ln-item-state.is-pending { background: var(--ln-amber-soft);                                       color: var(--ln-amber); }
.ln-item-state.is-coming  { background: var(--ln-surface-2);                                        color: var(--ln-fg-dim); }
.ln-item-detail { font-size: .82rem; color: var(--ln-fg); line-height: 1.5; }
.ln-item-cta { align-self: center; }

/* ---------- Empty states ---------- */
.ln-empty {
  text-align: center;
  padding: 2.5rem 1.5rem;
  color: var(--ln-fg-mute);
}
.ln-empty-title { font-size: 1rem; font-weight: 600; color: var(--ln-fg-hi); margin-bottom: .4rem; }
.ln-empty-body  { font-size: .85rem; line-height: 1.55; max-width: 440px; margin: 0 auto 1.25rem; }

/* ---------- Footer copy line ---------- */
.ln-footer-line {
  margin-top: 1.75rem;
  font-size: .7rem;
  color: var(--ln-fg-mute);
  font-family: var(--ln-font-mono);
  text-transform: uppercase;
  letter-spacing: .06em;
  text-align: center;
}

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  .ln-progress-fill, .ln-btn, .ln-input, .ln-otp-cell input { transition: none !important; }
}

/* ---------- No-JS OTP fallback reveal ---------- */
.no-js .ln-otp-row { display: none; }
.no-js .ln-otp-no-js-only { display: block; }

/* ---------- Cycle 8 — connector page primitives ---------- */
/* Display-once token panel: bordered card with warning iconography. */
.ln-token-panel {
  background: var(--ln-surface);
  border: 1px solid var(--ln-amber);
  border-radius: var(--ln-radius-lg);
  padding: 1.25rem 1.5rem;
  margin-bottom: 1.25rem;
  position: relative;
  overflow: hidden;
}
.ln-token-panel::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: var(--ln-amber);
}
.ln-token-panel-title {
  display: flex;
  align-items: center;
  gap: .55rem;
  font-size: .95rem;
  font-weight: 700;
  color: var(--ln-amber);
  margin-bottom: .35rem;
}
.ln-token-panel-warning {
  font-size: .82rem;
  color: var(--ln-fg);
  line-height: 1.55;
  margin-bottom: 1rem;
}
.ln-token-panel-warning strong { color: var(--ln-fg-hi); font-weight: 600; }

/* Inline copy-field: read-only input + copy button glued together. */
.ln-copyfield {
  display: flex;
  align-items: stretch;
  gap: .4rem;
  margin: .4rem 0 .85rem;
}
.ln-copyfield-label {
  display: block;
  font-size: .68rem;
  font-weight: 600;
  color: var(--ln-fg-mute);
  font-family: var(--ln-font-mono);
  text-transform: uppercase;
  letter-spacing: .08em;
  margin-bottom: .35rem;
}
.ln-copyfield input {
  flex: 1;
  background: var(--ln-surface-2);
  border: 1px solid var(--ln-border);
  border-radius: var(--ln-radius);
  color: var(--ln-fg-hi);
  font-family: var(--ln-font-mono);
  font-size: .82rem;
  padding: .58rem .75rem;
  outline: none;
  min-width: 0;
}
.ln-copyfield input:focus { border-color: var(--ln-indigo); box-shadow: 0 0 0 3px var(--ln-indigo-soft); }
.ln-copy-btn {
  flex: 0 0 auto;
  background: var(--ln-surface-3);
  border: 1px solid var(--ln-border-hi);
  border-radius: var(--ln-radius);
  color: var(--ln-fg-hi);
  font-size: .78rem;
  font-weight: 600;
  font-family: inherit;
  padding: 0 .9rem;
  cursor: pointer;
  transition: background .15s, border-color .15s, color .15s;
  white-space: nowrap;
}
.ln-copy-btn:hover { border-color: var(--ln-indigo); color: var(--ln-indigo); }
.ln-copy-btn.is-copied { background: var(--ln-blade-soft); border-color: var(--ln-blade-border); color: var(--ln-blade); }
.ln-copy-btn.is-error  { background: var(--ln-ruby-soft); border-color: var(--ln-ruby); color: var(--ln-ruby); }

/* Connector base-URL pill — a key piece of customer-facing information. */
.ln-base-url {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  padding: .35rem .65rem;
  background: var(--ln-surface-2);
  border: 1px solid var(--ln-border);
  border-radius: var(--ln-radius);
  font-family: var(--ln-font-mono);
  font-size: .82rem;
  color: var(--ln-fg-hi);
  word-break: break-all;
}

/* Credential row card — one card per active SCIM credential. */
.ln-cred-card {
  background: var(--ln-surface-2);
  border: 1px solid var(--ln-border);
  border-radius: var(--ln-radius);
  padding: .9rem 1.1rem;
  margin-bottom: .65rem;
}
.ln-cred-card-row {
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
}
.ln-cred-card-meta { flex: 1; min-width: 200px; }
.ln-cred-card-hint {
  font-family: var(--ln-font-mono);
  font-size: .82rem;
  color: var(--ln-fg-hi);
  letter-spacing: .04em;
}
.ln-cred-card-sub {
  font-size: .72rem;
  color: var(--ln-fg-mute);
  margin-top: .25rem;
  font-family: var(--ln-font-mono);
  text-transform: uppercase;
  letter-spacing: .06em;
}
.ln-cred-card-actions {
  display: flex;
  gap: .4rem;
  flex-wrap: wrap;
}

/* Next-step setup-guidance bullets (under the one-time token panel). */
.ln-next-steps {
  list-style: none;
  padding: 0;
  margin: 0;
  counter-reset: ln-next-step;
}
.ln-next-steps li {
  display: grid;
  grid-template-columns: 28px 1fr;
  gap: .65rem;
  padding: .55rem 0;
  border-bottom: 1px solid var(--ln-rule);
  font-size: .88rem;
  color: var(--ln-fg);
  line-height: 1.55;
  counter-increment: ln-next-step;
}
.ln-next-steps li:last-child { border-bottom: none; }
.ln-next-steps li::before {
  content: counter(ln-next-step);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px; height: 24px;
  border-radius: var(--ln-radius-pill);
  background: var(--ln-indigo-soft);
  color: var(--ln-indigo);
  border: 1px solid var(--ln-indigo-border);
  font-family: var(--ln-font-mono);
  font-size: .72rem;
  font-weight: 700;
}

/* Activity / provisioned table polish (cycle 8 light pass). */
.ln-table {
  width: 100%;
  border-collapse: collapse;
  font-size: .85rem;
}
.ln-table thead th {
  text-align: left;
  padding: .55rem .75rem;
  border-bottom: 1px solid var(--ln-rule);
  font-size: .68rem;
  font-weight: 600;
  color: var(--ln-fg-mute);
  font-family: var(--ln-font-mono);
  text-transform: uppercase;
  letter-spacing: .08em;
}
.ln-table tbody td {
  padding: .7rem .75rem;
  border-bottom: 1px solid var(--ln-rule);
  color: var(--ln-fg);
  vertical-align: top;
}
.ln-table tbody tr:last-child td { border-bottom: none; }
.ln-table .ln-mono { font-family: var(--ln-font-mono); font-size: .8rem; color: var(--ln-ink-soft); }

/* ── Cycle 9 — workspace users / role cards / error card ─────────────── */
.ln-card-error { border-color: var(--ln-error); }
.ln-role-cards { display: grid; grid-template-columns: 1fr; gap: .5rem; }
@media (min-width: 768px) { .ln-role-cards { grid-template-columns: repeat(2, 1fr); } }
.ln-role-card {
  display: block;
  border: 1px solid var(--ln-rule);
  border-radius: .5rem;
  padding: .75rem .9rem;
  background: var(--ln-card-bg);
  cursor: pointer;
  transition: border-color .12s ease, background .12s ease;
}
.ln-role-card:hover { border-color: var(--ln-accent); }
.ln-role-card input[type="radio"] { margin-right: .5rem; }
.ln-role-card-body { display: inline-block; vertical-align: top; }
.ln-role-card-title { font-weight: 600; margin-bottom: .25rem; }
.ln-role-card-blurb { font-size: .85rem; color: var(--ln-ink-soft); }

/* Cycle 66 — skip-to-main link: visually hidden until keyboard-focused. */
.skip-link { position: absolute; left: -9999px; top: 0; z-index: 1000; background: var(--ln-accent, #4f8ef7); color: #fff; padding: .6rem 1rem; border-radius: 8px; font-weight: 600; text-decoration: none; }
.skip-link:focus { left: .5rem; top: .5rem; outline: 2px solid #fff; }

/* Cycle 70 — centralized keyboard focus-visible affordance for portal pages.
   Outline-based (no layout shift), uses the existing LabsNinja indigo accent
   so it stays consistent with the redesign direction. Keyboard-only via
   :focus-visible, so mouse clicks do not show the ring. */
.ln-customer a:focus-visible,
.ln-customer button:focus-visible,
.ln-customer input:focus-visible,
.ln-customer select:focus-visible,
.ln-customer textarea:focus-visible,
.ln-customer summary:focus-visible,
.ln-customer [tabindex]:focus-visible {
  outline: 2px solid var(--ln-indigo, #7c5af7);
  outline-offset: 2px;
  border-radius: var(--ln-radius, 8px);
}
/* The skip link keeps its own high-contrast white ring (defined above). */
.ln-customer .skip-link:focus-visible { outline: 2px solid #fff; outline-offset: 0; }

/* ---------- Cycle 81 — visual-only card spacing & hierarchy alignment ----------
   Normalizes portal card internal rhythm so a card's last child no longer adds
   uneven trailing whitespace, keeps card titles (`.ln-h2`) visually consistent,
   and tidies trailing checklist-item detail spacing. Consumes the existing
   `--ln-*` tokens and existing classes only — no markup, behavior, data, route,
   JS, token, or accessibility-marker changes. */
.ln-customer .ln-card > :last-child { margin-bottom: 0; }
.ln-customer .ln-card .ln-h2 { line-height: 1.25; }
.ln-customer .ln-item-body > :last-child { margin-bottom: 0; }

/* ---------- Cycle 82 — visual-only button/control sizing alignment ----------
   Gives portal buttons and text controls a shared minimum height and a steady
   line-height so a button sitting next to an input/select lines up cleanly.
   Consumes the existing `--ln-*` tokens / `.ln-*` classes only — no button
   text, action, href, field name/id/placeholder, form, route, JS, or behavior
   change; only sizing rhythm. Focus-visible affordances (Cycle 70) are
   unchanged and remain visible/unclipped (min-height does not clip outlines). */
.ln-customer .ln-btn { min-height: 2.5rem; line-height: 1.2; }
.ln-customer .ln-btn-sm { min-height: 2.1rem; }
.ln-customer .ln-input,
.ln-customer .ln-copyfield input { min-height: 2.5rem; }

/* ---------- Cycle 85 — visual-only typography consistency ----------
   Aligns portal heading line-height, helper/muted text line-height, and the
   uppercase mono-label letter-spacing so card titles and metadata read
   consistently across portal surfaces. Consumes the existing `--ln-*` tokens /
   `.ln-*` classes only — no visible text, heading level, aria, action, route,
   JS, or behavior change; only typographic rhythm. */
.ln-customer .ln-h1 { line-height: 1.15; }
.ln-customer .ln-h2 { line-height: 1.25; }
.ln-customer .ln-hint,
.ln-customer .ln-item-detail,
.ln-customer .ln-empty-body { line-height: 1.55; }
.ln-customer .ln-k,
.ln-customer .ln-cred-card-sub,
.ln-customer .ln-workspace-sub { letter-spacing: .06em; }

/* ---------- Cycle 98 — visual-only responsive spacing alignment ----------
   At narrow (mobile/tablet) widths, tightens portal card padding, card spacing,
   and grid gaps so stacked cards keep a consistent rhythm without crowding or
   horizontal overflow. Consumes the existing `--ln-*` tokens / `.ln-*` classes
   only — no markup, visible text, label, heading level, aria, action, href,
   route, JS, data, or behavior change. Focus-visible affordances (Cycle 70)
   remain visible and unclipped (padding/gap changes do not clip outlines). */
@media (max-width: 600px) {
  .ln-customer .ln-card { padding: 1.15rem 1.2rem; margin-bottom: 1rem; }
  .ln-customer .ln-card-tight { padding: 0.95rem 1.05rem; }
  .ln-customer .ln-grid-2 { gap: 0.85rem 1rem; }
  .ln-customer .ln-card-row { gap: 0.75rem; padding-bottom: 1rem; margin-bottom: 1rem; }
}
