:root {
  --bg: #111213;
  --panel: #1b1c1e;
  --line: #2a2b2e;
  --text: #f4f4f4;
  --muted: #aaaaab;
  --blue: #1c4da1;
  --yellow: #f6bb30;
  --pink: #cf2c91;
  --radius: 12px;
}
* { box-sizing: border-box; }
html, body { margin: 0; background: var(--bg); color: var(--text); }
body { font: 15px/1.45 Montserrat, "Helvetica Neue", Arial, sans-serif; -webkit-font-smoothing: antialiased; }
button { font: inherit; cursor: pointer; }
.wrap { max-width: 760px; margin: 0 auto; padding: 20px 16px 64px; }

header { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 20px; }
header .brand { display: flex; align-items: center; gap: 10px; font-weight: 600; text-transform: lowercase; letter-spacing: .02em; }
header .brand img { width: 30px; height: 30px; }
header .who { color: var(--muted); font-size: 13px; display: flex; align-items: center; gap: 10px; }
header .who form { margin: 0; }
.link-btn { background: none; border: 0; color: var(--muted); text-decoration: underline; padding: 0; font-size: 13px; }

.running { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; display: flex; align-items: center; gap: 16px; margin-bottom: 18px; }
.running.on { border-color: var(--yellow); }
.running .info { flex: 1; min-width: 0; }
.running .label { font-size: 12px; color: var(--muted); text-transform: lowercase; letter-spacing: .04em; }
.running .task { font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.clock { font-variant-numeric: tabular-nums; font-size: 34px; font-weight: 600; color: var(--yellow); letter-spacing: .02em; }
.running:not(.on) .clock { color: var(--muted); }

.btn { border: 0; border-radius: 999px; padding: 9px 18px; font-weight: 600; color: #fff; min-width: 84px; }
.btn.start { background: var(--blue); }
.btn.stop { background: var(--pink); }
.btn:disabled { opacity: .5; cursor: progress; }

.notice { background: rgba(246, 187, 48, .1); border: 1px solid rgba(246, 187, 48, .45); border-radius: var(--radius); padding: 12px 14px; margin-bottom: 18px; font-size: 14px; }
.notice a { color: var(--yellow); }
.logged { background: rgba(28, 77, 161, .18); border-color: rgba(28, 77, 161, .7); }
.logged b { color: var(--yellow); font-variant-numeric: tabular-nums; }
.error { background: rgba(207, 44, 145, .12); border-color: rgba(207, 44, 145, .5); }

.search { width: 100%; padding: 11px 14px; border-radius: var(--radius); border: 1px solid var(--line); background: var(--panel); color: var(--text); font: inherit; margin-bottom: 14px; }
.search:focus { outline: 2px solid var(--blue); outline-offset: 1px; }

h2 { font-size: 12px; font-weight: 600; color: var(--muted); text-transform: lowercase; letter-spacing: .06em; margin: 22px 0 8px; }
h2::before { content: ""; display: inline-block; width: 14px; height: 2px; background: var(--pink); vertical-align: middle; margin-right: 8px; }
h2:nth-of-type(3n+2)::before { background: var(--yellow); }
h2:nth-of-type(3n)::before { background: var(--blue); }

.task-row { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 10px; }
.task-row:hover { background: var(--panel); }
.task-row.active { background: var(--panel); outline: 1px solid var(--yellow); }
.task-row .name { flex: 1; min-width: 0; }
.task-row .name a { color: var(--text); text-decoration: none; }
.task-row .name a:hover { text-decoration: underline; }
.task-row .meta { font-size: 12px; color: var(--muted); }
.task-row .total { font-variant-numeric: tabular-nums; color: var(--muted); font-size: 13px; min-width: 52px; text-align: right; }
.empty { color: var(--muted); padding: 24px 0; text-align: center; }

@media (max-width: 520px) {
  .clock { font-size: 26px; }
  .running { flex-wrap: wrap; }
  .task-row .total { display: none; }
}
