/* ============================================================
   G8 Research Output Database — shared stylesheet
   CITS3200 Team 20. Site design: Jamie Taylor.

   This file is the single source of visual truth for the site.
   Do not write page-specific colours, spacing or fonts anywhere
   else — add a token or a component class here instead, so all
   pages stay consistent as different people build them.
   ============================================================ */

/* ---------- 1. Design tokens ------------------------------- */
:root {
  --navy:        #12284d;
  --navy-dark:   #0d1e3a;
  --blue:        #2563eb;
  --blue-dark:   #1d4ed8;
  --blue-light:  #dbeafe;

  --ink:         #16202e;
  --ink-muted:   #5a6779;
  --ink-faint:   #626d7d;

  --bg:          #f4f6f9;
  --surface:     #ffffff;
  --border:      #e1e6ed;
  --border-firm: #c9d2de;

  --ok:          #15803d;
  --warn:        #b45309;
  --warn-bg:     #fef3c7;
  --danger:      #991b1b;
  --danger-bg:   #fee2e2;

  /* ABDC rating colours — used consistently everywhere a rating appears */
  --abdc-astar:  #7c3aed;
  --abdc-a:      #2563eb;
  --abdc-b:      #0891b2;
  --abdc-c:      #64748b;

  --radius:      8px;
  --radius-lg:   12px;
  --shadow:      0 1px 2px rgba(16,32,56,.06), 0 2px 8px rgba(16,32,56,.05);
  /* Veil over a card's photo. Thin at the top so the image reads, thickening
     towards the bottom where the grey stat labels need a clean background. */
  --scrim:       linear-gradient(rgba(255,255,255,.35), rgba(255,255,255,.72) 55%, rgba(255,255,255,.92));
  --shadow-lift: 0 4px 14px rgba(16,32,56,.12);

  --maxw:        1440px;   /* content column */
  --gutter:      28px;
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;
}

/* ---------- 2. Reset / base -------------------------------- */
*, *::before, *::after { box-sizing: border-box; }

/* This is a light-only design. Declaring it stops browsers running in dark
   mode from painting native controls (select, checkbox, scrollbars) dark —
   which would put dark-grey text on our white filter panel. */
:root { color-scheme: light; }

/* Sticky footer: the page is a full-height flex column, main takes up the
   slack, so the footer sits at the bottom of the viewport on short pages and
   below the content on long ones. Without this it floats mid-screen on tall
   monitors. Every page must use the header / main / footer structure. */
body {
  margin: 0;
  font-family: var(--font);
  font-size: 15px;
  line-height: 1.55;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;

  min-height: 100vh;
  min-height: 100dvh;   /* accounts for mobile browser chrome; ignored where unsupported */
  display: flex;
  flex-direction: column;
}
body > main { flex: 1 0 auto; }
body > .site-footer { margin-top: auto; }

h1, h2, h3 { line-height: 1.25; margin: 0 0 .5rem; font-weight: 650; letter-spacing: -.01em; }
h1 { font-size: 1.9rem; }
h2 { font-size: 1.3rem; }
h3 { font-size: 1.05rem; }
p  { margin: 0 0 .85rem; }
a  { color: var(--blue-dark); text-decoration: none; }
a:hover { text-decoration: underline; }

:focus-visible {
  outline: 2px solid var(--blue);
  outline-offset: 2px;
  border-radius: 3px;
}

/* Content column: centred, capped. Used by <main> only. */
.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 var(--gutter); }

/* Header and footer are full-bleed — their contents sit against the screen
   edges instead of being boxed into the content column, which left the brand
   and nav stranded mid-screen on wide monitors. */
.wrap-wide { width: 100%; margin: 0; padding: 0 var(--gutter); }
.muted { color: var(--ink-muted); }
.faint { color: var(--ink-faint); }
.small { font-size: .85rem; }
.nowrap { white-space: nowrap; }
.num { font-variant-numeric: tabular-nums; text-align: right; }

/* ---------- 3. Header / nav -------------------------------- */
.site-header {
  background: var(--navy);
  color: #fff;
  box-shadow: var(--shadow);
}
.site-header .wrap-wide {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  min-height: 62px;
  flex-wrap: wrap;
  padding-top: 10px;
  padding-bottom: 10px;
}
.brand {
  font-size: 1.15rem;
  font-weight: 680;
  color: #fff;
  letter-spacing: -.015em;
}
.brand:hover { text-decoration: none; opacity: .9; }

.nav { display: flex; gap: 8px; flex-wrap: wrap; }
.nav a {
  color: #fff;
  background: rgba(255,255,255,.10);
  padding: 7px 16px;
  border-radius: 999px;
  font-size: .9rem;
  font-weight: 500;
  transition: background .12s ease;
}
.nav a:hover { background: rgba(255,255,255,.20); text-decoration: none; }
.nav a[aria-current="page"] { background: var(--blue); }

/* ---------- 4. Page furniture ------------------------------ */
main { padding: 30px 0 60px; }

.page-head { text-align: center; margin-bottom: 26px; }
.page-head h1 { margin-bottom: .35rem; }
.page-head p  { color: var(--ink-muted); max-width: 640px; margin-inline: auto; }

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
}
.card-pad { padding: 20px 22px; }

/* Dataset totals used on the university comparison page. */
.summary-strip {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  margin-bottom: 18px;
  overflow: hidden;
}
.summary-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  padding: 17px 12px;
  border-left: 1px solid var(--border);
}
.summary-item:first-child { border-left: 0; }
.summary-value {
  color: var(--navy);
  font-size: 1.45rem;
  font-weight: 680;
  line-height: 1.15;
  font-variant-numeric: tabular-nums;
}
.summary-label {
  color: var(--ink-muted);
  font-size: .75rem;
  font-weight: 600;
  letter-spacing: .04em;
  text-transform: uppercase;
}
@media (max-width: 650px) {
  .summary-strip { grid-template-columns: repeat(2, 1fr); }
  .summary-item:nth-child(3) { border-left: 0; border-top: 1px solid var(--border); }
  .summary-item:nth-child(4) { border-top: 1px solid var(--border); }
}

/* Sample-data banner. Delete this element once real data is wired in. */
.banner-sample {
  display: flex; gap: 10px; align-items: flex-start;
  background: var(--warn-bg);
  border: 1px solid #fcd34d;
  color: #78350f;
  border-radius: var(--radius);
  padding: 10px 14px;
  font-size: .875rem;
  margin-bottom: 22px;
}
.banner-sample strong { font-weight: 650; }
/* `display: flex` above is a class selector, so it beats the browser's own
   [hidden] { display: none } on specificity and the hidden attribute silently
   does nothing. Both researcher.html and universities.html hide this banner
   that way, so without this line neither can ever turn it off and the site
   tells the client real data is invented. */
.banner-sample[hidden] { display: none; }

/* ---------- 5. University cards (home) --------------------- */
/* Eight universities. Fixed column counts (4 / 2 / 1) rather than auto-fill,
   so the grid is always evenly filled — auto-fill gives an ugly 3+3+2. */
.uni-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}
@media (max-width: 1040px) { .uni-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px)  { .uni-grid { grid-template-columns: 1fr; } }
.uni-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  padding: 18px 20px 20px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  transition: transform .12s ease, box-shadow .12s ease;
}
.uni-card:hover { transform: translateY(-2px); box-shadow: var(--shadow-lift); text-decoration: none; }
.uni-card .code {
  font-family: var(--mono);
  font-size: .72rem;
  font-weight: 600;
  letter-spacing: .08em;
  color: #fff;
  background: var(--navy);
  padding: 3px 8px;
  border-radius: 4px;
  align-self: flex-start;
  margin-bottom: 8px;
}
.uni-card .name { font-weight: 640; color: var(--ink); font-size: 1.02rem; }
.uni-card .name { margin-bottom: auto; }
/* Stats stack as label-left / number-right rows. At four cards across there
   isn't room for three side-by-side columns without the labels wrapping. */
.uni-card .stats {
  margin-top: 14px; padding-top: 10px;
  border-top: 1px solid var(--border);
  display: flex; flex-direction: column; gap: 3px;
}
.uni-card .stat {
  display: flex; align-items: baseline; justify-content: space-between; gap: 10px;
}
.uni-card .stat .k {
  font-size: .78rem; color: var(--ink-muted); white-space: nowrap;
}
.uni-card .stat .v {
  font-size: .98rem; font-weight: 660; line-height: 1.35;
  font-variant-numeric: tabular-nums; color: var(--ink);
}

/* Optional campus photo behind each card. Drop a file per university into
   assets/unis/ using the lowercased code below; a card with no file just keeps
   the plain --surface background, so this degrades quietly.

   The white gradient is layered ON TOP of the photo, not under it: the card's
   text is dark --ink, and an unscrimmed photo destroys that contrast. Raise the
   two alpha values towards 1 for a fainter photo, lower them for a bolder one.
   Keep them high enough that .stat .k (the muted grey labels) stays readable. */
.uni-card[data-code] {
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}
.uni-card[data-code="UA"]     { background-image: var(--scrim), url("unis/ua.jpg"); }
.uni-card[data-code="ANU"]    { background-image: var(--scrim), url("unis/anu.jpg"); }
.uni-card[data-code="UM"]     { background-image: var(--scrim), url("unis/um.jpg"); }
.uni-card[data-code="MONASH"] { background-image: var(--scrim), url("unis/monash.jpg"); }
.uni-card[data-code="UNSW"]   { background-image: var(--scrim), url("unis/unsw.jpg"); }
.uni-card[data-code="UQ"]     { background-image: var(--scrim), url("unis/uq.jpg"); }
.uni-card[data-code="USYD"]   { background-image: var(--scrim), url("unis/usyd.jpg"); }
.uni-card[data-code="UWA"]    { background-image: var(--scrim), url("unis/uwa.jpg"); }

/* ---------- 6. Filter panel -------------------------------- */
.filters { margin-bottom: 18px; }
.filter-row {
  display: flex; flex-wrap: wrap; gap: 16px 20px; align-items: flex-end;
}
.field { display: flex; flex-direction: column; gap: 5px; }
.field label {
  font-size: .78rem; font-weight: 600; color: var(--ink-muted);
  text-transform: uppercase; letter-spacing: .04em;
}
select, input[type="text"], input[type="search"], input[type="password"] {
  font: inherit;
  font-size: .9rem;
  padding: 7px 10px;
  border: 1px solid var(--border-firm);
  border-radius: 6px;
  background: #fff;
  color: var(--ink);
  min-width: 150px;
}
input[type="search"] { min-width: 210px; }
.rank-field select { min-width: 245px; }
.university-search-field { flex: 1 1 230px; }
.university-search-field input { width: 100%; }

.btn {
  font: inherit; font-size: .9rem; font-weight: 550;
  padding: 8px 18px;
  border: 1px solid transparent;
  border-radius: 6px;
  background: var(--blue);
  color: #fff;
  cursor: pointer;
  transition: background .12s ease;
}
.btn:hover { background: var(--blue-dark); }
.btn-ghost { background: #fff; color: var(--ink); border-color: var(--border-firm); }
.btn-ghost:hover { background: #f1f4f8; }

.toolbar {
  display: flex; align-items: center; justify-content: space-between;
  gap: 14px; flex-wrap: wrap; margin: 0 0 12px;
}
.toolbar .left, .toolbar .right { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }

.check { display: inline-flex; align-items: center; gap: 7px; font-size: .9rem; cursor: pointer; }
.check input { width: 16px; height: 16px; accent-color: var(--blue); cursor: pointer; }

/* ---------- 7. Tables -------------------------------------- */
.table-scroll { overflow-x: auto; border-radius: var(--radius-lg); border: 1px solid var(--border); background: var(--surface); }

table.data { width: 100%; border-collapse: collapse; font-size: .9rem; }

/* Publications table: fixed layout so the colgroup widths are honoured.
   min-width keeps the columns usable on a phone — .table-scroll scrolls it. */
table.table-pubs { table-layout: fixed; min-width: 880px; }
table.table-pubs tbody td { overflow-wrap: anywhere; }
table.data thead th {
  background: var(--navy);
  color: #fff;
  font-weight: 600;
  font-size: .82rem;
  letter-spacing: .02em;
  text-align: left;
  padding: 11px 14px;
  white-space: nowrap;
}
table.data thead th.sortable { cursor: pointer; user-select: none; }
table.data thead th.sortable:hover { background: var(--navy-dark); }
table.data thead th.sortable:focus-visible {
  outline: 2px solid #fff; outline-offset: -3px; background: var(--navy-dark);
}
table.data thead th .arrow { opacity: .45; margin-left: 5px; font-size: .75em; }
table.data thead th[aria-sort] .arrow { opacity: 1; }

table.data tbody td { padding: 10px 14px; border-top: 1px solid var(--border); vertical-align: top; }
table.data tbody tr:nth-child(even) { background: #fafbfd; }
table.data tbody tr:hover { background: var(--blue-light); }
table.data td.rank { font-weight: 640; color: var(--ink-muted); font-variant-numeric: tabular-nums; }

.university-table {
  min-width: 1120px;
  font-size: 1rem;
  table-layout: fixed;
}
.university-table thead th {
  padding: 14px 16px;
  font-size: .88rem;
  text-align: center;
}
.university-table tbody td {
  padding: 15px 16px;
  text-align: center;
  vertical-align: middle;
}
.university-table thead th:nth-child(1) { width: 72px; }
.university-table thead th:nth-child(2) { width: 110px; }
.university-table thead th:nth-child(3),
.university-table thead th:nth-child(4) { width: 185px; }
.university-table thead th:nth-child(5) { width: 130px; }
.university-table thead th:nth-child(6) { width: 135px; }
.university-table thead th:nth-child(7) { width: 105px; }
.university-table thead th:nth-child(8) { width: 135px; }
.university-table thead th:nth-child(9) { width: 155px; }
.university-link {
  display: inline-block;
  min-width: 62px;
  padding: 5px 10px;
  border-radius: 4px;
  background: var(--blue-light);
  color: var(--blue-dark);
  font-family: var(--mono);
  font-size: .9rem;
  font-weight: 700;
  letter-spacing: .05em;
  text-align: center;
  white-space: nowrap;
}
table.data td.metric-primary { font-weight: 680; color: var(--navy); }
.data-note {
  margin-top: 14px;
  color: var(--ink-faint);
  font-size: .8rem;
  text-align: right;
}

/* ---------- University rankings --------------------------- */
.university-rankings-page { padding-top: 42px; }
.university-rankings-wrap { max-width: 1380px; }
.university-rankings-head { margin-bottom: 28px; }
.university-rankings-head h1 {
  font-size: 3rem;
  font-weight: 650;
  letter-spacing: -.035em;
}
.ranking-control {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 22px;
  padding: 26px 32px;
  margin-bottom: 38px;
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 5px 18px rgba(15, 23, 42, .16);
}
.ranking-control label {
  color: var(--ink);
  font-size: 1.15rem;
  font-weight: 700;
  white-space: nowrap;
}
.ranking-control select {
  width: min(540px, 58vw);
  padding: 10px 14px;
  font-size: 1rem;
}
.ranking-update { padding: 11px 28px; font-size: 1rem; }
.university-ranking-shell {
  border: 0;
  border-radius: 0;
  box-shadow: 0 4px 14px rgba(15, 23, 42, .13);
}
table.university-ranking-table {
  min-width: 1060px;
  table-layout: fixed;
  font-size: 1rem;
}
table.university-ranking-table thead th {
  padding: 15px 12px;
  background: #247ed4;
  font-size: .94rem;
  line-height: 1.35;
  text-align: center;
  white-space: normal;
  vertical-align: middle;
}
table.university-ranking-table thead th:first-child { width: 74px; }
table.university-ranking-table thead th:nth-child(2) { width: 130px; }
table.university-ranking-table tbody td {
  padding: 15px 12px;
  text-align: center;
  vertical-align: middle;
}
table.university-ranking-table tbody td:nth-child(2) a {
  color: var(--ink);
  font-weight: 650;
}
.rank-arrow { font-size: .8em; }
@media (max-width: 700px) {
  .university-rankings-head h1 { font-size: 2.15rem; }
  .ranking-control { align-items: stretch; flex-direction: column; gap: 10px; }
  .ranking-control select { width: 100%; }
}

.empty { padding: 44px 20px; text-align: center; color: var(--ink-muted); }

/* ABDC rating pill */
.abdc {
  display: inline-block; min-width: 30px; text-align: center;
  font-size: .78rem; font-weight: 650;
  padding: 2px 8px; border-radius: 4px;
  color: #fff; background: var(--abdc-c);
}
.abdc[data-r="A*"] { background: var(--abdc-astar); }
.abdc[data-r="A"]  { background: var(--abdc-a); }
.abdc[data-r="B"]  { background: var(--abdc-b); }
.abdc[data-r="C"]  { background: var(--abdc-c); }
.abdc[data-r="none"], .abdc[data-r=""] { background: #e2e8f0; color: var(--ink-muted); }

/* A value we do not have yet. Renders as a dash, never as blank or "undefined". */
.na { color: var(--ink-faint); }

/* ---------- 8. Pagination ---------------------------------- */
.pager { display: flex; align-items: center; justify-content: space-between; gap: 14px; margin-top: 14px; flex-wrap: wrap; }
.pager .pages { display: flex; gap: 6px; }
.pager button {
  font: inherit; font-size: .87rem;
  min-width: 34px; padding: 5px 10px;
  border: 1px solid var(--border-firm); background: #fff; color: var(--ink);
  border-radius: 6px; cursor: pointer;
}
.pager button:hover:not(:disabled) { background: #f1f4f8; }
.pager button[aria-current="true"] { background: var(--blue); border-color: var(--blue); color: #fff; }
.pager button:disabled { opacity: .45; cursor: default; }
/* Refresh switched off on this server: looks disabled, still clickable so it
   can say why (see admin.html). */
.btn[aria-disabled="true"],
.btn[aria-disabled="true"]:hover { background: var(--blue); opacity: .45; cursor: not-allowed; }

/* ---------- 9. Researcher detail --------------------------- */
.researcher-head { display: flex; justify-content: space-between; gap: 20px; flex-wrap: wrap; align-items: flex-start; margin-bottom: 4px; }
.researcher-head h1 { margin-bottom: .15rem; }
.researcher-meta { color: var(--ink-muted); font-size: .95rem; }
.researcher-meta .sep { margin: 0 7px; color: var(--border-firm); }

/* ORCID and university profile links under the name. Sits a little tighter
   than the line above it so the two read as one block of identity. */
.researcher-links { margin-top: 4px; font-size: .88rem; }
.researcher-links a { color: var(--blue); text-decoration: none; }
.researcher-links a:hover,
.researcher-links a:focus-visible { text-decoration: underline; }

.tally { display: flex; gap: 10px; flex-wrap: wrap; margin: 18px 0 4px; }
.tally .t {
  border: 1px solid var(--border); border-radius: var(--radius);
  padding: 9px 16px; background: #fff; min-width: 78px;
}
.tally .t .v { font-size: 1.35rem; font-weight: 660; font-variant-numeric: tabular-nums; line-height: 1.15; }
.tally .t .k { font-size: .73rem; color: var(--ink-muted); text-transform: uppercase; letter-spacing: .04em; }
.tally .t[data-r="A*"] { border-color: var(--abdc-astar); }
.tally .t[data-r="A"]  { border-color: var(--abdc-a); }
.tally .t[data-r="B"]  { border-color: var(--abdc-b); }
.tally .t[data-r="C"]  { border-color: var(--abdc-c); }

.back-link { display: inline-block; margin-bottom: 14px; font-size: .9rem; }

/* ---------- 10. Footer ------------------------------------- */
.site-footer {
  border-top: 1px solid var(--border);
  background: var(--surface);
  padding: 20px 0;
  font-size: .84rem;
  color: var(--ink-muted);
}
.site-footer .wrap-wide { display: flex; justify-content: space-between; gap: 14px; flex-wrap: wrap; }

/* ---------- 11. Responsive --------------------------------- */
@media (max-width: 700px) {
  h1 { font-size: 1.5rem; }
  .site-header .wrap-wide { min-height: 0; }
  .filter-row { gap: 12px; }
  select, input[type="text"], input[type="search"] { min-width: 0; width: 100%; }
  .field { flex: 1 1 140px; }
  table.data { font-size: .85rem; }
}

@media print {
  .site-header, .site-footer, .filters, .toolbar, .pager, .banner-sample { display: none !important; }
  body { background: #fff; }
  .table-scroll { border: none; }
}

/* ---------- Admin ----------------------------------------------------- */
/* Sign-in page: one narrow card, centred under the shared header. */
.login-wrap { max-width: 400px; margin: 48px auto 0; padding: 0 var(--gutter); }
.login-card { padding: 28px 28px 26px; }
.login-card h1 { font-size: 1.4rem; margin-bottom: .3rem; }
.login-lead { color: var(--ink-muted); font-size: .92rem; margin-bottom: 1.3rem; }
.login-card input[type="password"],
.login-card input[type="text"] { width: 100%; padding: 9px 11px; font-size: .95rem; }
.login-show { margin: .75rem 0 1.2rem; color: var(--ink-muted); }
.login-card .btn { width: 100%; padding: 10px 18px; font-size: .95rem; }
.login-error {
  background: var(--danger-bg); color: var(--danger);
  border-radius: 6px; padding: 9px 12px; margin-bottom: 1.1rem; font-size: .9rem;
}
.login-back { margin-top: 1rem; text-align: center; }

.admin-wrap { max-width: 880px; margin: 2rem auto; padding: 0 1rem; }
.admin-logout { margin-top: -.5rem; }
.admin-step {
  margin: 1.5rem 0; padding: 1rem 1.25rem;
  border: 1px solid var(--border); border-radius: var(--radius); background: #fff;
}
.admin-step h2 { margin-top: 0; }
.admin-step h3 { margin: 0 0 .75rem; font-size: 1rem; }
.admin-action-block { margin-top: 1.2rem; padding-top: 1.1rem; border-top: 1px solid var(--border); }
.admin-check-row { display: block; margin: .7rem 0; }
.admin-result {
  white-space: pre-wrap; font-family: ui-monospace, monospace; font-size: .85rem;
  background: #f6f6f6; border-radius: 6px; padding: .75rem; margin-top: .75rem;
}
.warn { color: #8a4f00; }
.admin-refresh-toolbar {
  display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin: 1rem 0;
}
.status-badge, .source-state {
  display: inline-block; border-radius: 999px; padding: 3px 9px;
  font-size: .78rem; font-weight: 650; background: #e2e8f0; color: var(--ink-muted);
}
.status-badge[data-state="running"], .status-badge[data-state="queued"] { background: #fff3cd; color: #765400; }
.status-badge[data-state="succeeded"] { background: #dcfce7; color: #166534; }
.status-badge[data-state="failed"] { background: #fee2e2; color: #991b1b; }
.admin-summary {
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px 20px; margin: 1rem 0;
}
.admin-summary div { min-width: 0; }
.admin-summary dt { font-size: .75rem; text-transform: uppercase; letter-spacing: .04em; color: var(--ink-muted); }
.admin-summary dd { margin: 2px 0 0; overflow-wrap: anywhere; }
.admin-message { margin: .8rem 0; }
.admin-source-list { list-style: none; padding: 0; margin: .8rem 0 0; border-top: 1px solid var(--border); }
.admin-source-list li {
  display: grid; grid-template-columns: minmax(130px, 1fr) auto;
  align-items: center; gap: 10px; padding: 8px 0; border-bottom: 1px solid var(--border);
}
.admin-source-list .source-error { grid-column: 1 / -1; color: #991b1b; font-size: .82rem; }
@media (max-width: 700px) {
  .admin-summary { grid-template-columns: 1fr; }
}
