:root {
  --bg: #0b110d;
  --bg2: #0f1812;
  --card: #111c15;
  --card2: #16241b;
  --line: #1f3327;
  --ink: #e7f0ea;
  --muted: #88a596;
  --brand: #046a38;
  --accent: #1c9150;
  --accent-dark: #046a38;
  --ok: #2fae66;
  --warn: #d3a24a;
  --bad: #e06a5e;
  --radius: 12px;
}
* { box-sizing: border-box; }
body {
  margin: 0;
  min-height: 100vh;
  font-family: Verdana, Geneva, Tahoma, sans-serif;
  background-color: var(--bg);
  background-image:
    radial-gradient(900px 440px at 50% -8%, rgba(28, 145, 80, .22), transparent 70%),
    repeating-linear-gradient(135deg, rgba(255, 255, 255, .022) 0, rgba(255, 255, 255, .022) 1px, transparent 1px, transparent 26px);
  background-attachment: fixed;
  color: var(--ink);
}
header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 13px 20px;
  background: linear-gradient(180deg, #06814b 0%, var(--brand) 100%);
  color: #fff;
  border-bottom: 1px solid rgba(0, 0, 0, .25);
  box-shadow: 0 2px 10px rgba(0, 0, 0, .3);
}
.brand { display: flex; align-items: center; gap: 12px; }
.brand .logo { display: block; height: 22px; }
.brand span { padding-left: 12px; border-left: 1px solid rgba(255, 255, 255, .35); font-weight: 600; }
main { max-width: 760px; margin: 0 auto; padding: 18px; }

.card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 16px;
  margin-bottom: 14px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, .25);
  transition: border-color .15s, box-shadow .15s;
}
.card:hover { border-color: #294535; box-shadow: 0 4px 16px rgba(0, 0, 0, .28); }
.card h3 { margin: 0 0 10px; font-size: 16px; }
.row { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.spread { justify-content: space-between; }
.muted { color: var(--muted); font-size: 13px; }

.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: 10px; }
.stat { background: var(--bg2); border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; }
.stat b { display: block; font-size: 22px; color: var(--accent); }
.stat span { font-size: 12px; color: var(--muted); }

button {
  font: inherit;
  border: 0;
  border-radius: 9px;
  padding: 9px 14px;
  background: var(--accent);
  color: #07140d;
  font-weight: 600;
  cursor: pointer;
  transition: background .15s, opacity .15s;
}
button:hover { background: var(--accent-dark); }
button.ghost { background: transparent; border: 1px solid currentColor; color: inherit; font-weight: 500; opacity: .9; }
button.ghost:hover { background: rgba(255, 255, 255, .12); opacity: 1; }
button.lite { background: var(--card2); color: var(--ink); border: 1px solid var(--line); font-weight: 500; }
button.lite:hover { border-color: var(--accent); background: var(--card2); }
button:disabled { opacity: .4; cursor: default; }

input, select, textarea {
  font: inherit;
  padding: 9px 11px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: var(--card2);
  color: var(--ink);
}
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--accent); }
input[type=number]::-webkit-inner-spin-button,
input[type=number]::-webkit-outer-spin-button { -webkit-appearance: none; margin: 0; }
input[type=number] { -moz-appearance: textfield; appearance: textfield; }
input, select { width: auto; }
textarea { width: 100%; resize: vertical; min-height: 56px; }
label { font-size: 13px; color: var(--muted); }

.tag { font-size: 12px; padding: 3px 9px; border-radius: 20px; font-weight: 600; }
.s-none { background: #18261d; color: var(--muted); }
.s-prog { background: rgba(211, 162, 74, .16); color: var(--warn); }
.s-ok { background: rgba(53, 192, 122, .16); color: var(--ok); }
.s-bad { background: rgba(224, 106, 94, .16); color: var(--bad); }

.bar { height: 8px; background: #18261d; border-radius: 6px; overflow: hidden; }
.bar > i { display: block; height: 100%; background: var(--accent); }

.auth { max-width: 440px; margin: 7vh auto; }
.auth-title { text-align: center; font-size: 24px; margin: 0 0 6px; }
.auth-sub { text-align: center; color: var(--muted); font-size: 14px; margin: 0 0 20px; }
.auth .tabs button { flex: 1; padding: 11px 18px; font-size: 15px; }
.auth .card { padding: 22px; box-shadow: 0 12px 32px rgba(0, 0, 0, .35); }
.auth .card > * + * { margin-top: 12px; }
.auth input { width: 100%; padding: 13px 14px; font-size: 15px; }
.auth .card > button { width: 100%; padding: 13px; font-size: 16px; }
.hint { color: var(--muted); font-size: 14px; line-height: 1.5; margin: 0; }
.err { color: var(--bad); font-size: 13px; }
.ok-msg { color: var(--ok); font-size: 14px; }
.toast {
  position: fixed; left: 50%; bottom: 24px; transform: translate(-50%, 16px);
  background: var(--brand); color: #fff; padding: 11px 18px; border-radius: 10px;
  box-shadow: 0 10px 28px rgba(0, 0, 0, .45); font-size: 14px; max-width: 90vw;
  opacity: 0; transition: opacity .25s, transform .25s; z-index: 100;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.tabs { display: flex; gap: 8px; margin-bottom: 14px; }

.tablewrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
table { width: 100%; border-collapse: collapse; font-size: 14px; }
th, td { text-align: left; padding: 8px 10px; border-bottom: 1px solid var(--line); }
th { color: var(--muted); font-weight: 600; }
.score { display: flex; gap: 5px; }
.score button { padding: 6px 11px; }
.score button.on { background: var(--accent-dark); color: var(--ink); }
