/* Minimal stylesheet. No framework, no webfonts — first paint is the goal. */
:root {
  --bg: #ffffff;
  --fg: #14161a;
  --muted: #6b7280;
  --line: #d9dde3;
  --accent: #1f6feb;
  --ok: #128a37;
  --warn: #b7791f;
  --bad: #c62828;
  --soft: #f5f6f8;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font: 16px/1.5 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  color: var(--fg);
  background: var(--bg);
}
.wrap { max-width: 900px; margin: 0 auto; padding: 16px; }
.wrap.narrow { max-width: 680px; }
h1 { font-size: 1.4rem; margin: 0 0 12px; }
h2 { font-size: 1.15rem; margin: 24px 0 8px; }
h3 { font-size: 1rem; margin: 16px 0 6px; }
a { color: var(--accent); }
hr { border: 0; border-top: 1px solid var(--line); margin: 20px 0; }
.muted { color: var(--muted); }
.small { font-size: .85rem; }
.mono { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; }

header.bar {
  display: flex; align-items: center; gap: 12px;
  border-bottom: 1px solid var(--line); padding: 10px 16px;
}
header.bar .grow { flex: 1; }

input, textarea, select, button {
  font: inherit; color: inherit;
  border: 1px solid var(--line); border-radius: 6px;
  padding: 8px 10px; background: #fff;
}
textarea { width: 100%; min-height: 90px; resize: vertical; }
input[type=text], input[type=password], input[type=number], input[type=datetime-local] { width: 100%; }
button, .btn {
  cursor: pointer; background: var(--soft); border: 1px solid var(--line);
  border-radius: 6px; padding: 8px 14px; text-decoration: none; display: inline-block;
}
button:hover, .btn:hover { background: #ebedf1; }
button.primary { background: var(--accent); border-color: var(--accent); color: #fff; }
button.danger { color: var(--bad); }
.row { display: flex; gap: 8px; flex-wrap: wrap; align-items: flex-end; }
.row > * { flex: 1 1 160px; }
.row > .fixed { flex: 0 0 auto; }
label { display: block; font-size: .85rem; color: var(--muted); margin-bottom: 3px; }
form.inline { display: inline; }

.card { border: 1px solid var(--line); border-radius: 8px; padding: 14px; margin: 10px 0; }
table { width: 100%; border-collapse: collapse; font-size: .92rem; }
th, td { text-align: left; padding: 7px 8px; border-bottom: 1px solid var(--line); }
th { color: var(--muted); font-weight: 600; }

.tag {
  display: inline-block; font-size: .75rem; padding: 2px 7px; border-radius: 99px;
  background: var(--soft); border: 1px solid var(--line);
}
.tag.creation { background: #f2f3f5; }
.tag.planned  { background: #e7f0ff; border-color: #b9d1ff; }
.tag.prepared { background: #fff4d9; border-color: #f0dda6; }
.tag.started  { background: #e2f7e8; border-color: #a9dfb9; }
.tag.finished { background: #eceff3; color: var(--muted); }

/* --- player cabinet --- */
.play { max-width: 720px; margin: 0 auto; padding: 18px 16px 60px; }
.play h1 { font-size: 1.25rem; }
.play .body { white-space: pre-wrap; margin: 12px 0; }
.play img, .play video { max-width: 100%; height: auto; border-radius: 6px; margin: 8px 0; display: block; }
.answer {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 1.05rem; letter-spacing: .04em;
  background: var(--soft); border: 1px solid var(--line); border-radius: 6px;
  padding: 8px 10px; margin: 10px 0; min-height: 38px; word-break: break-word;
}
.answer:empty { display: none; }
#feedback { font-weight: 600; min-height: 24px; margin: 8px 0; }
#feedback.yep { color: var(--ok); }
#feedback.duplicated { color: var(--warn); }
#feedback.nope { color: var(--bad); }
.entry { display: flex; gap: 8px; margin: 12px 0; }
.entry input { flex: 1; font-size: 1.05rem; }
.timer {
  position: sticky; bottom: 0; background: var(--bg);
  border-top: 1px solid var(--line); padding: 10px 0; margin-top: 20px;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 1.5rem; text-align: center;
}
.timer.low { color: var(--bad); }
.hint { border-left: 3px solid var(--warn); padding: 4px 0 4px 12px; margin: 12px 0; }
.center { text-align: center; padding-top: 12vh; }
.center .big {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 3rem; margin-top: 12px;
}
.files a { display: block; margin: 4px 0; }
