/* The moderation console's page (console.js) — the circles design system, plus layout. */
/* The base the design system expects (as the circles web app's app.css sets it): without
   border-box, a full-width input is wider than its card by its own padding. */
* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { background: var(--surface-100); color: var(--ink); font-family: var(--font-sans); margin: 0; min-height: 100vh; -webkit-font-smoothing: antialiased; }
::selection { background: var(--brand); color: var(--brand-on); }
.console-header { display: flex; align-items: center; justify-content: space-between; gap: var(--space-3); padding: var(--space-3) var(--space-4); border-bottom: 1px solid var(--border); }
.console-brand { display: flex; align-items: center; gap: var(--space-2); }
.console-who { display: flex; align-items: center; gap: var(--space-2); }
.console-main { max-width: 760px; margin: 0 auto; padding: var(--space-4); display: flex; flex-direction: column; gap: var(--space-3); }
.console-narrow { max-width: 420px; margin: var(--space-6) auto 0; width: 100%; gap: var(--space-3); }
/* A button across a form's whole width: its label centred (as the app's welcome screens) */
.console-narrow > .circles-btn { width: 100%; justify-content: center; margin-top: var(--space-1); }
.console-narrow p { margin: 0; }
.console-muted { color: var(--ink-muted); }
.console-error { color: var(--danger); margin: 0; min-height: 1em; }
/* The tab pills — the same as the circles app's profile tabs (ui-demo/app.css .profile-tab) */
.profile-tabs { display: flex; gap: var(--space-2); }
.profile-tab {
  appearance: none; -webkit-appearance: none;
  border: none; cursor: pointer;
  font-family: var(--font-sans);
  background: var(--surface-200);
  color: var(--ink);
  border-radius: var(--radius-pill);
  padding: var(--space-2) var(--space-4);
  transition: background var(--duration-fast) ease, color var(--duration-fast) ease, transform var(--duration-pop) var(--easing-spring);
}
.profile-tab:hover { background: var(--brand-muted); }
.profile-tab:active { transform: scale(0.93); }
.profile-tab:focus-visible { outline: 2px solid var(--focus-ring); outline-offset: 2px; }
.profile-tab--active { background: var(--brand); color: var(--brand-on); }
.profile-tab--active:hover { background: var(--brand); }
.console-tabs { flex-wrap: wrap; }
.console-case { gap: var(--space-1); }
.console-case p { margin: 0; }
.console-quote { font-style: italic; border-left: 2px solid var(--border); padding-left: var(--space-2); }
.console-actions { display: flex; flex-wrap: wrap; gap: var(--space-2); margin-top: var(--space-2); }
.console-actions--end { justify-content: flex-end; }
.console-list { gap: 0; padding-block: var(--space-1); }
.console-row { padding: var(--space-2) 0; border-bottom: 1px solid var(--border); }
.console-row:last-child { border-bottom: 0; }
.console-row p { margin: 0; }
.console-row--split { display: flex; align-items: center; justify-content: space-between; gap: var(--space-3); }
.console-qr { background: #fff; border-radius: var(--radius-md); padding: var(--space-3); width: 200px; height: 200px; align-self: center; }
.console-qr svg { width: 100%; height: 100%; display: block; }
.console-code { font-family: ui-monospace, monospace; letter-spacing: 0.05em; }
.console-offer { width: 100%; font-family: ui-monospace, monospace; font-size: 12px; resize: vertical; }
.console-dialog:not([open]) { display: none; } /* .circles-card sets display: flex, which would show it closed */
.console-dialog { max-width: 480px; width: calc(100% - 32px); border: 1px solid var(--border); color: var(--ink); }
.console-dialog::backdrop { background: rgba(0, 0, 0, 0.6); }
.console-dialog form { display: flex; flex-direction: column; gap: var(--space-3); }
.console-dialog p { margin: 0; }
.console-toast { position: fixed; left: 50%; bottom: var(--space-5); transform: translateX(-50%); background: var(--surface-300); color: var(--ink); padding: var(--space-2) var(--space-4); border-radius: var(--radius-pill); box-shadow: var(--shadow-lg); }
.console-toast--bad { background: var(--danger); color: var(--danger-on); }
/* The Bugs tab */
.bug-details summary { cursor: pointer; color: var(--ink-muted); }
.bug-dl { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: var(--space-2) var(--space-3); margin: var(--space-2) 0 0; }
.bug-dl dd { margin: 0; overflow-wrap: anywhere; }
.bug-status { height: var(--btn-height-sm); padding-block: 0; }
/* The Network tab (network.js) */
.net { display: flex; flex-direction: column; gap: var(--space-3); }
.net-mock { flex-direction: row; align-items: flex-start; gap: var(--space-2); background: var(--brand-muted); box-shadow: none; }
.net-mock p { margin: 0; }
.net-mock .circles-icon { margin-top: 2px; color: var(--brand); }
.net-tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: var(--space-3); }
.net-tile { gap: var(--space-1); }
.net-tile p { margin: 0; }
.net-tile__value { font-family: var(--font-display); font-weight: 600; font-size: 28px; line-height: 34px; color: var(--ink); font-variant-numeric: tabular-nums; }
.net-card { gap: var(--space-3); }
.net-card > p { margin: 0; }
.net-map { width: 100%; height: auto; display: block; }
.net-map path { stroke: var(--surface-200); stroke-width: 0.6; }
.net-map path.net-country--on:hover { stroke: var(--ink); stroke-width: 1.2; }
.net-legend { display: flex; flex-wrap: wrap; gap: var(--space-1) var(--space-3); color: var(--ink-muted); }
.net-legend__item { display: inline-flex; align-items: center; gap: var(--space-1); }
.net-table summary { cursor: pointer; color: var(--ink-muted); }
.net-table table { width: 100%; border-collapse: collapse; margin-top: var(--space-2); }
.net-table th, .net-table td { text-align: left; padding: var(--space-1) 0; border-bottom: 1px solid var(--border); }
.net-table th { color: var(--ink-muted); font-weight: 500; }
.net-num { text-align: right !important; font-variant-numeric: tabular-nums; }
.net-chart { width: 100%; height: auto; display: block; overflow: visible; }
.net-grid { stroke: var(--border); stroke-width: 1; }
.net-axis { fill: var(--ink-muted); font: 500 11px var(--font-sans); }
.net-line { fill: none; stroke: var(--brand); stroke-width: 2; stroke-linejoin: round; stroke-linecap: round; }
.net-dot, .net-cross-dot { fill: var(--brand); stroke: var(--surface-200); stroke-width: 2; }
.net-direct { fill: var(--ink); font: 600 12px var(--font-sans); }
.net-cross { stroke: var(--ink-muted); stroke-width: 1; stroke-dasharray: 3 3; }
.net-hit { fill: transparent; cursor: crosshair; }
.net-bar { fill: var(--brand); }
.net-bar:hover { fill: #cdb8ff; }
.net-tip { position: fixed; z-index: 50; pointer-events: none; background: var(--surface-300); color: var(--ink); border: 1px solid var(--border); padding: var(--space-1) var(--space-2); border-radius: var(--radius-sm); box-shadow: var(--shadow-md); white-space: nowrap; }
.net-health__row { display: flex; align-items: center; justify-content: space-between; gap: var(--space-3); padding: var(--space-2) 0; border-bottom: 1px solid var(--border); }
.net-health__row p { margin: 0; }
.net-health__value { display: flex; align-items: center; gap: var(--space-3); flex: none; }
.net-health__num { font: 600 18px var(--font-sans); font-variant-numeric: tabular-nums; min-width: 3.5ch; text-align: right; }
.net-state { display: inline-flex; align-items: center; gap: 4px; min-width: 64px; }
.net-state--good { color: var(--success); }
.net-state--warning { color: var(--warning); }
.net-state--bad { color: var(--danger); }
.net-health__versions { margin: var(--space-2) 0 0 !important; }
.net-version { display: grid; grid-template-columns: 56px 1fr 40px; align-items: center; gap: var(--space-2); }
.net-version__bar { width: 100%; height: 8px; display: block; }
@media (max-width: 520px) {
  .net-health__row { flex-direction: column; align-items: flex-start; }
  .console-main { padding: var(--space-3) var(--space-4); }
  .console-row--split { flex-direction: column; align-items: flex-start; }
}
