/* Shared Matrix theme. Pages link this at /_assets/theme.css */
:root {
  color-scheme: dark;
  --bg: #020403;
  --card: #06120a;
  --ink: #5cff8f;
  --muted: #3fb06b;
  --line: #0e3b1e;
  --accent: #00ff41;
  --accent-ink: #001a07;
  --danger: #ff5d73;
  --mono: ui-monospace, "Cascadia Mono", "SFMono-Regular", Consolas, "Liberation Mono", monospace;
}
html { background: var(--bg); }
body {
  margin: 0;
  background: transparent; /* lets the rain canvas show through */
  color: var(--ink);
  font: 16px/1.55 var(--mono);
}
/* faint scanlines */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background: repeating-linear-gradient(0deg, rgba(0, 0, 0, 0.18) 0 1px, transparent 1px 3px);
  opacity: 0.35;
  z-index: 50;
}
::selection { background: var(--accent); color: var(--accent-ink); }
a { color: var(--accent); }
h1, h2, h3 { color: var(--accent); text-shadow: 0 0 10px rgba(0, 255, 65, 0.45); font-weight: 700; }
input, button, select {
  font: inherit;
  color: var(--ink);
  background: #030a05;
  border: 1px solid var(--line);
  border-radius: 0.35rem;
  padding: 0.4rem 0.65rem;
}
input::placeholder { color: #2a7a48; }
input:focus-visible, button:focus-visible, a:focus-visible, select:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}
input[type="checkbox"] { accent-color: var(--accent); }
input[type="color"] { padding: 0.1rem; height: 2.2rem; width: 3rem; cursor: pointer; }
button { cursor: pointer; font-weight: 600; }
button:hover { border-color: var(--accent); box-shadow: 0 0 10px -3px var(--accent); }
button.primary { background: var(--accent); color: var(--accent-ink); border-color: transparent; }
button.primary:hover { box-shadow: 0 0 14px 0 var(--accent); }
/* User avatars (see avatar.js): round, fixed size, cropped to fill rather than stretched. */
.avatar {
  --s: 2rem;
  display: inline-grid;
  place-items: center;
  flex: none;
  box-sizing: border-box;
  width: var(--s);
  height: var(--s);
  border-radius: 50%;
  border: 1px solid var(--line);
  background: var(--card);
  object-fit: cover;
  overflow: hidden;
  vertical-align: middle;
  font-size: calc(var(--s) * 0.45);
  font-weight: 700;
  line-height: 1;
  user-select: none;
}
img.avatar { display: inline-block; }
table { border-collapse: collapse; }
th { color: var(--muted); font-size: 0.78rem; text-transform: uppercase; letter-spacing: 0.06em; }
@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; }
}
