/* ============================================================
   LeaderBoard EDU — LeaderForce Design System (Light Mode)
   ============================================================ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  /* LeaderForce Web Tokens v1.1 — light-mode adaptation */
  --lf-ground:      #160D2E;              /* header / footer / table heads */
  --lf-panel:       #F7F5FF;              /* card / filter surface */
  --lf-panel-2:     #EDE9FE;              /* raised surface */
  --lf-edge:        rgba(139,92,246,.13); /* 1px borders */
  --lf-violet:      #8B5CF6;             /* primary accent */
  --lf-violet-soft: #7C3AED;             /* links (darker for white bg legibility) */
  --lf-lilac:       #C9B8F0;             /* decorative / dark-surface body */
  --lf-paper:       #160D2E;             /* high-emphasis text on white */
  --lf-dim:         #8F7FC0;             /* captions, labels */
  --lf-signal:      #FF5C9E;             /* ROSE: one signal per view */
  --lf-signal-soft: rgba(255,92,158,.10);

  --f-display: 'Fraunces', serif;
  --f-body:    'Public Sans', sans-serif;
  --f-data:    'Spline Sans Mono', monospace;

  --green:     #166534; --green-lt:  #dcfce7;
  --red:       #b91c1c; --red-lt:    #fee2e2;
  --amber:     #92400e; --amber-lt:  #fef3c7;
  --gold:      #d4a017; --gold-lt:   #fef9e7;

  --radius:    6px;
  --radius-lg: 13px;
  --shadow:    0 1px 3px rgba(22,13,46,.06), 0 1px 2px rgba(22,13,46,.04);
  --shadow-md: 0 4px 12px rgba(139,92,246,.08), 0 2px 4px rgba(22,13,46,.05);
  --transition: 0.18s ease;
}

html { font-size: 16px; }
body {
  font-family: var(--f-body);
  color: var(--lf-paper);
  background: #ffffff;
  line-height: 1.65;
  font-weight: 400;
}

/* 3.5% noise layer */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='280' height='280'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.7' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix type='saturate' values='0'/%3E%3C/filter%3E%3Crect width='280' height='280' filter='url(%23n)' opacity='0.035'/%3E%3C/svg%3E");
}

a { color: var(--lf-violet-soft); text-decoration: none; }
a:hover { text-decoration: underline; color: var(--lf-violet); }

h1, h2, h3, h4 {
  font-family: var(--f-display);
  line-height: 1.15;
  letter-spacing: -.01em;
  color: var(--lf-paper);
}
h1 { font-size: 2rem;     font-weight: 900; }
h2 { font-size: 1.375rem; font-weight: 600; }
h3 { font-size: 1.1rem;   font-weight: 600; }

pre, code { font-family: var(--f-data); }

/* --- Layout --- */
.main-content {
  max-width: 1200px;
  margin: 0 auto;
  padding: 2rem 1.5rem 4rem;
  position: relative;
  z-index: 1;
}

/* --- Site Header --- */
.site-header {
  background: var(--lf-ground);
  border-bottom: 1px solid rgba(167,139,250,.18);
  position: sticky;
  top: 0;
  z-index: 100;
}
.header-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 52px;
}
.site-logo {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  color: #fff;
  font-family: var(--f-data);
  font-size: 11.5px;
  letter-spacing: .28em;
  text-transform: uppercase;
  text-decoration: none;
  font-weight: 500;
}
.site-logo:hover { text-decoration: none; opacity: 0.9; }
.logo-icon { display: none; }
.logo-wordmark { color: var(--lf-lilac); }
.logo-wordmark b { color: var(--lf-violet); font-weight: 500; }

.site-nav { display: flex; gap: 1.5rem; }
.site-nav a {
  color: rgba(201,184,240,.7);
  font-family: var(--f-data);
  font-size: 10px;
  letter-spacing: .2em;
  text-transform: uppercase;
  font-weight: 500;
  text-decoration: none;
  padding: 0.25rem 0;
  border-bottom: 2px solid transparent;
  transition: var(--transition);
}
.site-nav a:hover { color: #fff; border-bottom-color: var(--lf-violet); text-decoration: none; }

/* --- Global Search Bar --- */
.global-search {
  background: var(--lf-violet);
  padding: 0.6rem 1.5rem;
  position: relative;
  z-index: 99;
}
.global-search form {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  gap: 0.5rem;
}
.search-input-global {
  flex: 1;
  padding: 0.45rem 1rem;
  border: 1px solid rgba(255,255,255,0.25);
  border-radius: var(--radius);
  background: rgba(255,255,255,0.18);
  color: #fff;
  font-family: var(--f-body);
  font-size: 0.9rem;
}
.search-input-global::placeholder { color: rgba(255,255,255,0.55); }
.search-input-global:focus {
  outline: 2px solid rgba(255,255,255,0.55);
  background: rgba(255,255,255,0.24);
}

/* --- Buttons --- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.45rem 1rem;
  border-radius: var(--radius);
  font-family: var(--f-data);
  font-size: 10.5px;
  font-weight: 500;
  letter-spacing: .12em;
  text-transform: uppercase;
  cursor: pointer;
  border: 1px solid transparent;
  transition: var(--transition);
  text-decoration: none;
  white-space: nowrap;
}
.btn:hover { text-decoration: none; }
.btn-primary  { background: var(--lf-violet); color: #fff; }
.btn-primary:hover  { background: var(--lf-violet-soft); color: #fff; }
.btn-secondary { background: var(--lf-panel); color: var(--lf-paper); border-color: var(--lf-edge); }
.btn-secondary:hover { background: var(--lf-panel-2); }
.btn-outline  { background: #fff; color: var(--lf-violet-soft); border-color: var(--lf-edge); }
.btn-outline:hover  { background: var(--lf-panel); }
.btn-search   { background: var(--lf-ground); color: rgba(201,184,240,.9); border: 1px solid rgba(167,139,250,.3); }
.btn-search:hover   { background: #211447; color: #fff; }
.btn-filter   { background: var(--lf-violet); color: #fff; }
.btn-filter:hover   { background: var(--lf-violet-soft); }
.btn-clear    { background: #fff; color: var(--red); border-color: var(--red); }
.btn-clear:hover    { background: var(--red-lt); }
.btn-sm  { padding: 0.3rem 0.65rem; font-size: 10px; }
.btn-lg  { padding: 0.65rem 1.4rem; font-size: 11.5px; }

/* --- Statline (home) --- */
.stats-bar {
  display: flex;
  border-top: 1px solid var(--lf-edge);
  border-bottom: 1px solid var(--lf-edge);
  flex-wrap: wrap;
  margin-bottom: 2.5rem;
}
.stat-item {
  flex: 1 1 180px;
  padding: 18px 22px;
  border-right: 1px solid var(--lf-edge);
  display: flex;
  flex-direction: column;
}
.stat-item:last-child { border-right: none; }
.stat-number {
  font-family: var(--f-display);
  font-weight: 600;
  font-size: 2rem;
  line-height: 1;
  color: var(--lf-paper);
}
.stat-number.stat-signal { color: var(--lf-signal); }
.stat-number.stat-small  { font-size: 1.1rem; }
.stat-label {
  font-family: var(--f-data);
  font-size: 10px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--lf-dim);
  margin-top: 5px;
}

/* --- Page hero --- */
.page-hero { padding: 2rem 0 1.5rem; }
.page-hero h1 { font-size: 2.25rem; }
.hero-subtitle { color: var(--lf-dim); margin-top: 0.5rem; font-size: 1.05rem; max-width: 700px; font-weight: 300; }

/* Kicker / eyebrow */
.kicker {
  font-family: var(--f-data);
  font-size: 11px;
  letter-spacing: .3em;
  text-transform: uppercase;
  color: var(--lf-violet);
  margin-bottom: 0.75rem;
}

/* --- List controls --- */
.list-controls {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.25rem;
  flex-wrap: wrap;
  gap: 0.5rem;
}
.role-pills { display: flex; gap: 0.5rem; flex-wrap: wrap; }
.role-pill {
  padding: 0.2rem 0.65rem;
  border-radius: 999px;
  font-family: var(--f-data);
  font-size: 10px;
  font-weight: 500;
  letter-spacing: .1em;
  text-transform: uppercase;
  background: var(--lf-panel-2);
  color: var(--lf-violet-soft);
  border: 1px solid var(--lf-edge);
  text-decoration: none;
}
.role-pill:hover { background: var(--lf-violet); color: #fff; text-decoration: none; }

/* --- Systems grid --- */
.systems-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  gap: 1.25rem;
  margin-bottom: 2.5rem;
}
.system-card {
  background: #fff;
  border: 1px solid var(--lf-edge);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  transition: var(--transition);
}
.system-card:hover { box-shadow: var(--shadow-md); transform: translateY(-1px); }
.system-card-header {
  background: var(--lf-ground);
  color: #fff;
  padding: 1rem 1.25rem;
}
.system-card-header h3 {
  font-family: var(--f-display);
  font-size: 1rem;
  font-weight: 600;
  letter-spacing: 0;
}
.system-card-header h3 a { color: #fff; }
.system-card-header h3 a:hover { text-decoration: underline; }
.domain-badge {
  font-family: var(--f-data);
  font-size: 10px;
  letter-spacing: .12em;
  opacity: 0.55;
  display: block;
  margin-top: 0.3rem;
}
.domain-badge a { color: rgba(201,184,240,.75); }

.system-card-body { padding: 1rem 1.25rem; flex: 1; }
.system-notes { color: var(--lf-dim); font-size: 0.875rem; margin-bottom: 0.75rem; font-weight: 300; }
.system-meta { margin-bottom: 0.75rem; }
.member-count { font-size: 0.9rem; color: var(--lf-dim); }
.member-count strong {
  font-family: var(--f-display);
  color: var(--lf-violet-soft);
  font-size: 1.1rem;
}
.no-data { color: var(--lf-dim); font-style: italic; }
.source-urls { font-size: 0.8rem; }
.source-label { color: var(--lf-dim); }
.source-link { color: var(--lf-violet-soft); margin-left: 0.35rem; }

.system-card-footer { padding: 0.75rem 1.25rem; border-top: 1px solid var(--lf-edge); }

/* --- Search hint (home) --- */
.search-hint {
  background: var(--lf-panel);
  border: 1px solid var(--lf-edge);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  margin-top: 2rem;
}
.search-hint h3 { margin-bottom: 0.5rem; }
.search-hint p  { margin-bottom: 1rem; color: var(--lf-dim); font-weight: 300; }
.inline-search  { display: flex; gap: 0.5rem; }
.search-input {
  flex: 1;
  padding: 0.5rem 1rem;
  border: 1px solid var(--lf-edge);
  border-radius: var(--radius);
  font-family: var(--f-body);
  font-size: 0.95rem;
  background: #fff;
  color: var(--lf-paper);
}
.search-input:focus { outline: 2px solid var(--lf-violet); border-color: var(--lf-violet); }

/* --- Network Visualization --- */
.viz-section { margin-bottom: 2rem; }
.viz-card {
  background: var(--lf-ground);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-md);
  border: 1px solid rgba(167,139,250,.18);
}
.viz-card-header {
  padding: 1.25rem 1.5rem 1rem;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}
.viz-header-left h2 {
  font-family: var(--f-display);
  font-size: 1.1rem;
  font-weight: 600;
  color: #F0ECFA;
  margin: 0;
  letter-spacing: 0;
}
.viz-description {
  font-family: var(--f-body);
  font-size: 0.83rem;
  color: rgba(201,184,240,.55);
  margin-top: 0.2rem;
}
.viz-fullscreen-link {
  font-family: var(--f-data);
  font-size: 10px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--lf-violet);
  white-space: nowrap;
  align-self: center;
}
.viz-fullscreen-link:hover { color: var(--lf-lilac); text-decoration: underline; }
.viz-body { border-top: 1px solid rgba(167,139,250,.18); }
.viz-body iframe { display: block; width: 100%; height: 560px; border: none; }

/* --- Breadcrumb --- */
.breadcrumb {
  font-family: var(--f-data);
  font-size: 10px;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--lf-dim);
  margin-bottom: 1.25rem;
}
.breadcrumb a { color: var(--lf-violet-soft); }
.bc-sep { margin: 0 0.5rem; }

/* --- System hero --- */
.system-hero {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 1.5rem;
  gap: 1rem;
}
.system-subtitle { color: var(--lf-dim); margin-top: 0.25rem; font-weight: 300; }
.domain-link {
  font-family: var(--f-data);
  font-size: 10px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--lf-violet-soft);
  margin-top: 0.35rem;
  display: inline-block;
}
.member-count-badge {
  background: var(--lf-ground);
  color: #fff;
  padding: 0.75rem 1.5rem;
  border-radius: var(--radius-lg);
  text-align: center;
  min-width: 100px;
  border: 1px solid rgba(167,139,250,.18);
}
.count-number {
  display: block;
  font-family: var(--f-display);
  font-size: 2rem;
  font-weight: 600;
  color: var(--lf-signal);
  line-height: 1;
}
.count-label {
  display: block;
  font-family: var(--f-data);
  font-size: 10px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: rgba(201,184,240,.55);
  margin-top: 4px;
}

/* --- Filter bar --- */
.filter-bar {
  background: var(--lf-panel);
  border: 1px solid var(--lf-edge);
  border-radius: var(--radius);
  padding: 1rem 1.25rem;
  margin-bottom: 1.5rem;
}
.filter-form {
  display: flex;
  align-items: flex-end;
  gap: 1rem;
  flex-wrap: wrap;
}
.filter-group { display: flex; flex-direction: column; gap: 0.3rem; }
.filter-group label {
  font-family: var(--f-data);
  font-size: 10px;
  font-weight: 500;
  color: var(--lf-dim);
  text-transform: uppercase;
  letter-spacing: .18em;
}
.select-filter {
  padding: 0.45rem 0.75rem;
  border: 1px solid var(--lf-edge);
  border-radius: var(--radius);
  font-family: var(--f-body);
  font-size: 0.9rem;
  background: #fff;
  color: var(--lf-paper);
}

/* --- Members table --- */
.members-section { margin-bottom: 2.5rem; }
.table-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.75rem 0;
  font-family: var(--f-data);
  font-size: 10px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--lf-dim);
  border-bottom: 2px solid var(--lf-violet);
  margin-bottom: 0;
}
.members-table-wrapper { overflow-x: auto; }
.members-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.875rem;
  background: #fff;
}
.members-table th {
  background: var(--lf-ground);
  color: rgba(201,184,240,.85);
  padding: 0.65rem 0.85rem;
  text-align: left;
  font-family: var(--f-data);
  font-size: 10px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: .18em;
  white-space: nowrap;
}
.members-table td {
  padding: 0.6rem 0.85rem;
  border-bottom: 1px solid var(--lf-edge);
  vertical-align: top;
  color: var(--lf-paper);
}
.members-table tr:hover td { background: var(--lf-panel); }
.member-link { font-weight: 500; color: var(--lf-violet-soft); }
.member-link:hover { text-decoration: underline; color: var(--lf-violet); }
.empty-field { color: var(--lf-dim); }

/* --- Badges & Tags --- */
.role-tag {
  display: inline-block;
  padding: 0.15rem 0.55rem;
  border-radius: 999px;
  font-family: var(--f-data);
  font-size: 10px;
  font-weight: 500;
  letter-spacing: .06em;
  text-transform: capitalize;
}
.role-regent      { background: #dbeafe; color: #1e40af; }
.role-trustee     { background: #dcfce7; color: #166534; }
.role-board_member { background: var(--lf-panel); color: var(--lf-dim); }
.role-visitor     { background: #fef3c7; color: #92400e; }
.role-governor    { background: var(--lf-panel-2); color: var(--lf-violet-soft); }
.role-commissioner { background: #fce7f3; color: #9d174d; }

.title-badge {
  display: inline-block;
  padding: 0.15rem 0.55rem;
  border-radius: var(--radius);
  font-family: var(--f-data);
  font-size: 10px;
  letter-spacing: .06em;
  font-weight: 500;
  background: var(--lf-panel-2);
  color: var(--lf-violet-soft);
  border: 1px solid var(--lf-edge);
}
.title-chair               { background: var(--gold-lt);  color: var(--gold); }
.title-vice-chair          { background: var(--amber-lt); color: var(--amber); }
.title-ex-officio          { background: var(--lf-panel); color: var(--lf-dim); border-color: var(--lf-edge); }
.title-student-representative { background: var(--green-lt); color: var(--green); }

.status-badge {
  display: inline-block;
  padding: 0.15rem 0.55rem;
  border-radius: 999px;
  font-family: var(--f-data);
  font-size: 10px;
  letter-spacing: .06em;
  font-weight: 500;
}
.status-success    { background: var(--green-lt);  color: var(--green); }
.status-failed     { background: var(--red-lt);    color: var(--red); }
.status-skipped    { background: var(--amber-lt);  color: var(--amber); }
.status-pending    { background: var(--lf-panel);  color: var(--lf-dim); }
.status-empty      { background: var(--amber-lt);  color: var(--amber); }
.status-js_fallback { background: #dbeafe; color: #1e40af; }

.method-badge  { font-family: var(--f-data); font-size: 10px; color: var(--lf-dim); }
.notes-text    { font-size: 0.82rem; color: var(--lf-dim); cursor: help; }
.bio-link      { font-size: 0.82rem; color: var(--lf-violet-soft); }
.has-bio       { font-size: 0.82rem; color: var(--green); }
.timestamp-cell { font-family: var(--f-data); font-size: 10.5px; color: var(--lf-dim); white-space: nowrap; }

/* --- Evidence section --- */
.evidence-section {
  margin-top: 2.5rem;
  padding-top: 2rem;
  border-top: 1px solid var(--lf-edge);
}
.evidence-section h2 {
  font-family: var(--f-data);
  font-size: 10.5px;
  letter-spacing: .24em;
  text-transform: uppercase;
  color: var(--lf-dim);
  font-weight: 500;
  margin-bottom: 0.5rem;
}
.evidence-intro { color: var(--lf-dim); font-size: 0.9rem; margin: 0.25rem 0 1rem; font-weight: 300; }
.evidence-table { width: 100%; border-collapse: collapse; font-size: 0.82rem; margin-top: 0.75rem; }
.evidence-table th {
  background: var(--lf-panel);
  padding: 0.5rem 0.75rem;
  text-align: left;
  font-family: var(--f-data);
  font-size: 10px;
  letter-spacing: .16em;
  font-weight: 500;
  color: var(--lf-dim);
  text-transform: uppercase;
}
.evidence-table td { padding: 0.5rem 0.75rem; border-bottom: 1px solid var(--lf-edge); }
.evidence-url      { font-size: 0.82rem; word-break: break-all; color: var(--lf-violet-soft); }
.page-title        { color: var(--lf-dim); }
.last-scrape-note  { margin-top: 0.75rem; font-family: var(--f-data); font-size: 10px; letter-spacing: .1em; color: var(--lf-dim); }
.no-evidence       { color: var(--lf-dim); font-size: 0.9rem; font-weight: 300; }

/* --- Trustee detail --- */
.trustee-layout {
  display: grid;
  grid-template-columns: 1fr 280px;
  gap: 2rem;
  align-items: start;
}
@media (max-width: 768px) {
  .trustee-layout { grid-template-columns: 1fr; }
}
.trustee-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 1.5rem;
  gap: 1rem;
  flex-wrap: wrap;
}
.trustee-identity { display: flex; gap: 1rem; align-items: flex-start; }
.trustee-avatar {
  width: 80px;
  height: 80px;
  background: var(--lf-violet);
  color: #fff;
  font-family: var(--f-display);
  font-size: 2rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  flex-shrink: 0;
  overflow: hidden;
  border: 3px solid var(--lf-panel-2);
}
.avatar-photo    { width: 100%; height: 100%; object-fit: cover; border-radius: 50%; }
.avatar-initials { display: flex; align-items: center; justify-content: center; width: 100%; height: 100%; }
.trustee-name-block h1 { font-size: 1.75rem; }
.trustee-title   { margin-top: 0.35rem; }
.trustee-role    { margin-top: 0.3rem; font-size: 0.9rem; color: var(--lf-dim); }
.trustee-actions { display: flex; gap: 0.5rem; flex-wrap: wrap; }

.info-card {
  background: #fff;
  border: 1px solid var(--lf-edge);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  margin-bottom: 1.25rem;
  box-shadow: var(--shadow);
}
.card-title {
  font-family: var(--f-data);
  font-size: 10px;
  letter-spacing: .24em;
  text-transform: uppercase;
  font-weight: 500;
  color: var(--lf-dim);
  margin-bottom: 1rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid var(--lf-edge);
}
.info-grid { display: grid; grid-template-columns: 150px 1fr; gap: 0.5rem 1rem; }
.info-grid dt {
  font-family: var(--f-data);
  font-size: 10px;
  font-weight: 500;
  color: var(--lf-dim);
  text-transform: uppercase;
  letter-spacing: .16em;
  padding-top: 0.1rem;
}
.info-grid dd { font-size: 0.95rem; }

.bio-content p { font-size: 0.95rem; color: var(--lf-dim); line-height: 1.7; font-weight: 300; }
.bio-link-section { margin-top: 1rem; }

.evidence-list { display: flex; flex-direction: column; gap: 0.75rem; }
.evidence-item { font-size: 0.875rem; }
.evidence-label {
  font-family: var(--f-data);
  font-size: 10px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--lf-dim);
  margin-right: 0.5rem;
}
.evidence-url-row { display: flex; align-items: flex-start; gap: 0.5rem; flex-wrap: wrap; }
.evidence-meta { margin-top: 0.25rem; font-family: var(--f-data); font-size: 10px; color: var(--lf-dim); }

.raw-data-section { margin-top: 1.5rem; }
.raw-data-section summary {
  cursor: pointer;
  font-family: var(--f-data);
  font-size: 10.5px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--lf-violet-soft);
  padding: 0.5rem 0;
}
.json-block {
  font-family: var(--f-data);
  font-size: 0.78rem;
  background: var(--lf-ground);
  color: var(--lf-lilac);
  padding: 1rem;
  border-radius: var(--radius);
  overflow-x: auto;
  margin-top: 0.5rem;
  line-height: 1.6;
}

/* Sidebar */
.trustee-sidebar { display: flex; flex-direction: column; gap: 1rem; }
.sidebar-card {
  background: #fff;
  border: 1px solid var(--lf-edge);
  border-radius: var(--radius-lg);
  padding: 1.25rem;
  box-shadow: var(--shadow);
}
.sidebar-card h3 {
  font-family: var(--f-data);
  font-size: 10px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: .2em;
  color: var(--lf-dim);
  margin-bottom: 0.75rem;
}
.sidebar-system-link { font-weight: 600; color: var(--lf-violet-soft); }
.colleague-list { list-style: none; display: flex; flex-direction: column; gap: 0.4rem; }
.colleague-list li { font-size: 0.875rem; }
.colleague-title { display: block; font-family: var(--f-data); font-size: 10px; color: var(--lf-dim); margin-top: 2px; }
.view-all-link { display: inline-block; margin-top: 0.75rem; font-size: 0.85rem; color: var(--lf-violet-soft); }

/* --- Search page --- */
.search-page-header { margin-bottom: 1.5rem; }
.search-form-section {
  background: #fff;
  border: 1px solid var(--lf-edge);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  margin-bottom: 1.5rem;
  box-shadow: var(--shadow);
}
.search-form-full { display: flex; flex-direction: column; gap: 1rem; }
.search-row  { display: flex; gap: 0.75rem; }
.search-input-lg {
  flex: 1;
  padding: 0.65rem 1rem;
  border: 1px solid var(--lf-edge);
  border-radius: var(--radius);
  font-family: var(--f-body);
  font-size: 1rem;
  background: #fff;
  color: var(--lf-paper);
}
.search-input-lg:focus { outline: none; border-color: var(--lf-violet); box-shadow: 0 0 0 3px rgba(139,92,246,.1); }
.search-filters { display: flex; align-items: flex-end; gap: 1rem; flex-wrap: wrap; }
.results-header {
  font-family: var(--f-data);
  font-size: 10px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--lf-dim);
  margin-bottom: 1rem;
}
.results-table-wrapper { overflow-x: auto; }
.results-table { background: #fff; }
.system-link-sm { font-size: 0.85rem; color: var(--lf-violet-soft); }
.source-link-sm { font-size: 0.82rem; color: var(--lf-violet-soft); }

/* Pagination */
.pagination { display: flex; align-items: center; justify-content: center; gap: 1rem; padding: 1.5rem 0; }
.page-btn {
  padding: 0.45rem 1rem;
  background: #fff;
  border: 1px solid var(--lf-edge);
  border-radius: var(--radius);
  color: var(--lf-violet-soft);
  font-family: var(--f-data);
  font-size: 10px;
  letter-spacing: .12em;
  text-transform: uppercase;
  cursor: pointer;
  text-decoration: none;
}
.page-btn:hover { background: var(--lf-panel); text-decoration: none; }
.page-info { font-family: var(--f-data); font-size: 10.5px; color: var(--lf-dim); }

/* Search default */
.search-default { padding: 1rem 0; }
.search-default h3 { margin-bottom: 0.75rem; }
.search-default ul { list-style: none; color: var(--lf-dim); display: flex; flex-direction: column; gap: 0.35rem; margin-bottom: 1.5rem; }
.system-quick-links a { color: var(--lf-violet-soft); }

/* --- Admin page --- */
.admin-header { margin-bottom: 1.5rem; }
.admin-subtitle { color: var(--lf-dim); margin-top: 0.25rem; font-weight: 300; }
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 1rem;
  margin-bottom: 2rem;
}
.stat-card {
  background: #fff;
  border: 1px solid var(--lf-edge);
  border-radius: var(--radius-lg);
  padding: 1.25rem;
  text-align: center;
  box-shadow: var(--shadow);
}
.stat-card .stat-number {
  font-family: var(--f-display);
  font-size: 2rem;
  font-weight: 600;
  color: var(--lf-violet-soft);
  line-height: 1;
}
.stat-card .stat-number.stat-sm { font-size: 1.1rem; }
.stat-card .stat-label {
  font-family: var(--f-data);
  font-size: 10px;
  color: var(--lf-dim);
  text-transform: uppercase;
  letter-spacing: .14em;
  margin-top: 0.35rem;
}
.stat-good .stat-number { color: var(--green); }
.stat-warn .stat-number { color: var(--amber); }

.admin-section { margin-bottom: 2.5rem; }
.admin-section h2 {
  font-family: var(--f-data);
  font-size: 10.5px;
  letter-spacing: .24em;
  text-transform: uppercase;
  color: var(--lf-dim);
  font-weight: 500;
  margin-bottom: 1rem;
  border-bottom: 1px solid var(--lf-edge);
  padding-bottom: 0.5rem;
}

/* Page status bar */
.page-status-bar { background: #fff; border: 1px solid var(--lf-edge); border-radius: var(--radius-lg); padding: 1.25rem; }
.status-bar-container { height: 20px; border-radius: var(--radius); overflow: hidden; display: flex; margin-bottom: 0.75rem; }
.status-segment.status-success { background: var(--green); }
.status-segment.status-failed  { background: var(--red); }
.status-segment.status-skipped { background: var(--amber); }
.status-legend { display: flex; gap: 1.5rem; font-family: var(--f-data); font-size: 10.5px; color: var(--lf-dim); }
.legend-item   { display: flex; align-items: center; gap: 0.4rem; }
.dot           { width: 10px; height: 10px; border-radius: 50%; display: inline-block; }
.dot-success   { background: var(--green); }
.dot-failed    { background: var(--red); }
.dot-skipped   { background: var(--amber); }

/* Quality table */
.quality-table-wrapper { overflow-x: auto; }
.quality-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.85rem;
  background: #fff;
  box-shadow: var(--shadow);
  border-radius: var(--radius-lg);
  overflow: hidden;
}
.quality-table th {
  background: var(--lf-ground);
  color: rgba(201,184,240,.85);
  padding: 0.65rem 0.85rem;
  text-align: left;
  font-family: var(--f-data);
  font-size: 10px;
  font-weight: 500;
  letter-spacing: .18em;
  text-transform: uppercase;
}
.quality-table td { padding: 0.65rem 0.85rem; border-bottom: 1px solid var(--lf-edge); vertical-align: top; }
.quality-table tr:hover td { background: var(--lf-panel); }
.row-warn td { background: #fff8f8 !important; }
.num-cell    { text-align: right; font-family: var(--f-data); font-variant-numeric: tabular-nums; }
.good-text   { color: var(--green);  font-weight: 600; }
.warn-text   { color: var(--amber);  font-weight: 600; }
.bad-text    { color: var(--red);    font-weight: 600; }
.domain-sm   { font-family: var(--f-data); font-size: 10.5px; color: var(--lf-dim); }
.issue-badge { display: inline-block; background: var(--red-lt);   color: var(--red);   padding: 0.1rem 0.4rem; border-radius: var(--radius); font-family: var(--f-data); font-size: 10px; font-weight: 500; margin-right: 0.25rem; }
.skip-badge  { display: inline-block; background: var(--amber-lt); color: var(--amber); padding: 0.1rem 0.4rem; border-radius: var(--radius); font-family: var(--f-data); font-size: 10px; font-weight: 500; margin-right: 0.25rem; }
.ok-badge    { display: inline-block; background: var(--green-lt); color: var(--green); padding: 0.1rem 0.4rem; border-radius: var(--radius); font-family: var(--f-data); font-size: 10px; font-weight: 500; }
.evidence-url-small { font-size: 0.75rem; margin-bottom: 0.2rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 300px; color: var(--lf-violet-soft); }
.status-dot  { display: inline-block; width: 8px; height: 8px; border-radius: 50%; vertical-align: middle; margin-right: 3px; }

/* Command blocks */
.command-blocks { display: flex; flex-direction: column; gap: 1rem; }
.command-block  { background: #fff; border: 1px solid var(--lf-edge); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
.command-label  {
  background: var(--lf-panel);
  padding: 0.5rem 1rem;
  font-family: var(--f-data);
  font-size: 10px;
  letter-spacing: .14em;
  font-weight: 500;
  color: var(--lf-dim);
  text-transform: uppercase;
  border-bottom: 1px solid var(--lf-edge);
}

/* API table */
.api-table { width: 100%; border-collapse: collapse; font-size: 0.875rem; background: #fff; border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow); }
.api-table th { background: var(--lf-ground); color: rgba(201,184,240,.85); padding: 0.65rem 1rem; text-align: left; font-family: var(--f-data); font-size: 10px; letter-spacing: .18em; text-transform: uppercase; }
.api-table td { padding: 0.65rem 1rem; border-bottom: 1px solid var(--lf-edge); }
.admin-timestamp { font-family: var(--f-data); font-size: 10px; letter-spacing: .12em; color: var(--lf-dim); margin-top: 2rem; }

/* --- Code blocks --- */
.code-block {
  background: var(--lf-ground);
  color: var(--lf-lilac);
  padding: 1rem 1.25rem;
  border-radius: var(--radius);
  font-family: var(--f-data);
  font-size: 0.875rem;
  overflow-x: auto;
  line-height: 1.6;
}

/* --- Empty state --- */
.empty-state { text-align: center; padding: 3rem 1rem; color: var(--lf-dim); }
.empty-state h3 { color: var(--lf-paper); margin-bottom: 0.5rem; }
.empty-state .code-block { display: inline-block; text-align: left; margin-top: 0.75rem; }

/* --- Error page --- */
.error-page { text-align: center; padding: 4rem 1rem; }
.error-page h1 { color: var(--lf-signal); margin-bottom: 1rem; }
.error-page p  { color: var(--lf-dim); margin-bottom: 1.5rem; }

/* --- Footer --- */
.site-footer {
  background: var(--lf-ground);
  border-top: 1px solid rgba(167,139,250,.18);
  color: rgba(201,184,240,.55);
  padding: 1.5rem;
  margin-top: 4rem;
  position: relative;
  z-index: 1;
}
.footer-inner { max-width: 1200px; margin: 0 auto; }
.footer-inner p {
  font-family: var(--f-data);
  font-size: 10px;
  letter-spacing: .14em;
  text-transform: uppercase;
  margin-bottom: 0.5rem;
}
.footer-inner a { color: rgba(167,139,250,.55); }
.footer-inner a:hover { color: var(--lf-lilac); }
.footer-note { font-size: 10px; opacity: 0.55; }

/* --- Login page --- */
.login-page {
  min-height: 75vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
}
.login-card {
  background: #fff;
  border: 1px solid var(--lf-edge);
  border-radius: var(--radius-lg);
  padding: 2.5rem;
  width: 100%;
  max-width: 400px;
  box-shadow: var(--shadow-md);
  text-align: center;
}
.login-eyebrow {
  font-family: var(--f-data);
  font-size: 10.5px;
  letter-spacing: .3em;
  text-transform: uppercase;
  color: var(--lf-violet);
  margin-bottom: 1rem;
}
.login-card h1 { font-size: 1.5rem; font-weight: 900; margin-bottom: 0.5rem; }
.login-card p  { color: var(--lf-dim); font-size: 0.9rem; margin-bottom: 1.75rem; font-weight: 300; }
.login-form    { display: flex; flex-direction: column; gap: 0.75rem; }
.login-input {
  padding: 0.7rem 1rem;
  border: 1px solid var(--lf-edge);
  border-radius: var(--radius);
  font-family: var(--f-body);
  font-size: 0.95rem;
  background: #fff;
  color: var(--lf-paper);
  text-align: center;
  letter-spacing: .1em;
}
.login-input:focus { outline: none; border-color: var(--lf-violet); box-shadow: 0 0 0 3px rgba(139,92,246,.1); }
.login-error {
  color: var(--lf-signal);
  font-family: var(--f-data);
  font-size: 10.5px;
  letter-spacing: .12em;
  text-transform: uppercase;
  margin-top: 0.25rem;
}

/* --- Responsive --- */
@media (max-width: 600px) {
  .system-hero   { flex-direction: column; }
  .systems-grid  { grid-template-columns: 1fr; }
  .stats-bar     { display: block; }
  .stat-item     { border-right: none; border-bottom: 1px solid var(--lf-edge); }
  .filter-form   { flex-direction: column; align-items: stretch; }
  .trustee-header   { flex-direction: column; }
  .trustee-identity { flex-direction: column; }
  .search-row    { flex-direction: column; }
  .info-grid     { grid-template-columns: 1fr; }
  .info-grid dt  { margin-top: 0.5rem; }
}
