/* AvA dashboard theme — dark, accessible. Loaded AFTER Bulma so source order
   wins and we avoid blanket !important. We theme surfaces and base text only,
   and leave Bulma's component colour pairings alone so contrast stays correct
   (this is what fixes the light-on-yellow tags). */

:root {
  --bg: #0d1117;
  --surface: #161b22;
  --surface-2: #21262d;
  --border: #30363d;
  --text: #c9d1d9;
  --text-strong: #f0f6fc;
  --muted: #8b949e;
  --accent: #58a6ff;
}

html,
body {
  background-color: var(--bg);
  color: var(--text);
  min-height: 100vh;
}

/* Base text. Bulma's .has-text-* helpers use !important, so the coloured
   stat numbers (primary/info/success) still win over these. */
.title { color: var(--text-strong); }
.subtitle,
.label,
.content,
.content p,
.content li,
p, dd, dt, li { color: var(--text); }
.heading { color: var(--muted); }

/* Navbar */
.navbar { background-color: var(--surface); border-bottom: 0.0625rem solid var(--border); }
.navbar-item,
.navbar-link { color: var(--text); }
.navbar-item:hover,
.navbar-link:hover { background-color: var(--surface-2); color: var(--accent); }
.navbar-dropdown { background-color: var(--surface); border-color: var(--border); }
.navbar-divider { background-color: var(--border); }

/* Surfaces */
.box,
.card { background-color: var(--surface); color: var(--text); border: 0.0625rem solid var(--border); }
.card-content { color: var(--text); }

/* Tables */
.table { background-color: var(--surface); color: var(--text); }
.table th { color: var(--text-strong); background-color: var(--bg); border-color: var(--border); }
.table td { color: var(--text); border-color: var(--border); }
.table.is-hoverable tbody tr:hover { background-color: var(--surface-2); }

/* Forms */
.input,
.textarea,
.select select {
  background-color: var(--bg);
  border-color: var(--border);
  color: var(--text);
}
.input::placeholder,
.textarea::placeholder { color: var(--muted); opacity: 1; }
.input:focus,
.textarea:focus,
.select select:focus { border-color: var(--accent); }
.select:not(.is-multiple):not(.is-loading)::after { border-color: var(--accent); }
.select select option { background-color: var(--surface); color: var(--text); }

/* Buttons — keep accessible text on solid fills */
.button.is-primary { background-color: #238636; border-color: #238636; color: #fff; }
.button.is-primary:hover { background-color: #2ea043; border-color: #2ea043; color: #fff; }
.button.is-link { background-color: #1f6feb; border-color: #1f6feb; color: #fff; }
.button.is-link:hover { background-color: #388bfd; border-color: #388bfd; color: #fff; }

/* Yellow needs dark text. This is the white-on-yellow fix: restore Bulma's
   accessible pairing explicitly so no stray rule can override it. */
.tag.is-warning,
.button.is-warning,
.notification.is-warning { color: rgba(0, 0, 0, 0.7); }

/* Visible keyboard focus on every interactive element */
a:focus-visible,
button:focus-visible,
.button:focus-visible,
.input:focus-visible,
.textarea:focus-visible,
.select select:focus-visible,
.navbar-item:focus-visible,
.navbar-link:focus-visible {
  outline: 0.125rem solid var(--accent);
  outline-offset: 0.125rem;
}
