/* Learning commons: one stylesheet, no framework. Colours: ink, paper, one accent (teal), one warning. */
:root {
  --ink: #1c2430; --ink-2: #4a5566; --ink-3: #7a8494; --line: #e3e6eb; --paper: #ffffff; --bg: #f6f7f9;
  --accent: #0f766e; --accent-2: #115e59; --accent-bg: #e6f4f2; --warn: #b45309; --warn-bg: #fdf3e6;
  --bad: #b42318; --bad-bg: #fdecea; --good: #157f3b; --good-bg: #e8f5ec;
  --v0: #0f766e; --v1: #6d4fc2; --v2: #c2410c; --v3: #2563eb; --v4: #a21caf; --v5: #4d7c0f;
  --radius: 10px; --shadow: 0 1px 2px rgba(16, 24, 40, .05);
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 15px/1.55 -apple-system, BlinkMacSystemFont, "Segoe UI",
  Roboto, "Helvetica Neue", Arial, sans-serif; }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
code, pre, textarea.mono { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 13px; }
code { background: #eef0f3; padding: .05rem .3rem; border-radius: 4px; }
pre { background: #0f172a; color: #e2e8f0; padding: .9rem 1rem; border-radius: 8px; overflow-x: auto; margin: .5rem 0; }
pre code { background: none; padding: 0; color: inherit; }
h1 { font-size: 1.75rem; line-height: 1.25; margin: 0 0 .4rem; letter-spacing: -.01em; }
h2 { font-size: 1.2rem; margin: 2rem 0 .75rem; }
h3 { font-size: 1rem; margin: 1.2rem 0 .4rem; }
p { margin: .4rem 0 .8rem; }
.muted { color: var(--ink-2); }
.small { font-size: 13px; }
.wrap { max-width: 72rem; margin: 0 auto; padding: 0 1.25rem; }

/* header */
.top { background: var(--paper); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 5; }
.top .wrap { display: flex; align-items: center; gap: 1.5rem; height: 58px; }
.brand { display: flex; align-items: center; gap: .55rem; font-weight: 650; color: var(--ink); font-size: 16px; }
.brand:hover { text-decoration: none; }
.brand svg { flex: none; }
.nav { display: flex; gap: 1.1rem; flex: 1; }
.nav a { color: var(--ink-2); font-weight: 500; }
.nav a.on, .nav a:hover { color: var(--ink); text-decoration: none; }
.who { display: flex; align-items: center; gap: .75rem; }
.avatar { width: 26px; height: 26px; border-radius: 50%; background: var(--accent-bg); display: inline-grid;
  place-items: center; font-size: 12px; font-weight: 650; color: var(--accent-2); overflow: hidden; }
.avatar img { width: 100%; height: 100%; }
.pill-count { background: var(--warn); color: #fff; border-radius: 999px; font-size: 11px; padding: 0 .4rem; margin-left: .2rem; }

main { padding: 2rem 0 4rem; min-height: 70vh; }
footer { border-top: 1px solid var(--line); color: var(--ink-3); font-size: 13px; padding: 1.5rem 0 2.5rem; }
footer a { color: var(--ink-2); margin-right: 1rem; }

/* blocks */
.card { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.1rem 1.25rem;
  box-shadow: var(--shadow); }
.card + .card { margin-top: .9rem; }
.grid { display: grid; gap: .9rem; grid-template-columns: repeat(auto-fill, minmax(17rem, 1fr)); }
.grid .card + .card { margin-top: 0; }
.cols { display: grid; gap: 1.5rem; grid-template-columns: minmax(0, 1fr) 20rem; align-items: start; }
@media (max-width: 860px) { .cols { grid-template-columns: 1fr; } .nav { display: none; } }
.row { display: flex; gap: .6rem; align-items: center; flex-wrap: wrap; }
.spread { display: flex; justify-content: space-between; align-items: baseline; gap: 1rem; flex-wrap: wrap; }
.stack > * + * { margin-top: .5rem; }
hr { border: 0; border-top: 1px solid var(--line); margin: 1.5rem 0; }
.page-head { margin-bottom: 1.5rem; }
.page-head p { margin: .2rem 0 0; max-width: 46rem; }
.crumbs { font-size: 13px; color: var(--ink-3); margin-bottom: .4rem; }
.crumbs a { color: var(--ink-2); }

.badge { display: inline-block; font-size: 12px; font-weight: 550; padding: .05rem .5rem; border-radius: 999px;
  background: #eef0f3; color: var(--ink-2); white-space: nowrap; }
.badge.teal { background: var(--accent-bg); color: var(--accent-2); }
.badge.warn { background: var(--warn-bg); color: var(--warn); }
.badge.bad { background: var(--bad-bg); color: var(--bad); }
.badge.good { background: var(--good-bg); color: var(--good); }
.skill-card h3 { margin: 0 0 .25rem; font-size: 1.02rem; }
.skill-card p { color: var(--ink-2); margin: 0 0 .6rem; font-size: 14px; }
.stats { display: flex; gap: 1rem; color: var(--ink-3); font-size: 13px; }

/* hero */
.hero { padding: 1.5rem 0 1rem; }
.hero h1 { font-size: 2.3rem; max-width: 40rem; }
.hero p.lead { font-size: 1.1rem; color: var(--ink-2); max-width: 42rem; }
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: .9rem; margin: 1.75rem 0 1rem; }
@media (max-width: 760px) { .steps { grid-template-columns: 1fr; } .hero h1 { font-size: 1.8rem; } }
.step { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.1rem; }
.step .n { display: inline-grid; place-items: center; width: 26px; height: 26px; border-radius: 50%;
  background: var(--accent); color: #fff; font-weight: 650; font-size: 13px; margin-bottom: .5rem; }
.step h3 { margin: .1rem 0 .3rem; }
.step p { color: var(--ink-2); font-size: 14px; margin: 0; }

/* buttons and forms */
.btn { display: inline-flex; align-items: center; gap: .4rem; border: 1px solid var(--line); background: var(--paper);
  color: var(--ink); font: inherit; font-weight: 550; font-size: 14px; padding: .45rem .9rem; border-radius: 8px;
  cursor: pointer; text-decoration: none; }
.btn:hover { background: #f3f4f6; text-decoration: none; }
.btn.primary { background: var(--accent); border-color: var(--accent); color: #fff; }
.btn.primary:hover { background: var(--accent-2); }
.btn.danger { color: var(--bad); border-color: #f1c9c5; }
.btn.small { font-size: 13px; padding: .25rem .6rem; }
.btn.github { background: #1f2328; color: #fff; border-color: #1f2328; padding: .6rem 1.1rem; }
form.inline { display: inline; }
label { display: block; font-weight: 550; margin: 1rem 0 .3rem; font-size: 14px; }
label .hint, .hint { font-weight: 400; color: var(--ink-3); font-size: 13px; }
input[type=text], input[type=search], input[type=url], select, textarea {
  width: 100%; font: inherit; font-size: 14px; padding: .5rem .65rem; border: 1px solid #d0d5dd; border-radius: 8px;
  background: #fff; color: var(--ink); }
textarea { min-height: 7rem; resize: vertical; }
textarea.tall { min-height: 22rem; }
input:focus, select:focus, textarea:focus { outline: 2px solid var(--accent-bg); border-color: var(--accent); }
.check { display: flex; gap: .5rem; align-items: flex-start; font-weight: 400; }
.check input { margin-top: .25rem; }
.actions { margin-top: 1.25rem; display: flex; gap: .6rem; flex-wrap: wrap; }
.notice { border-radius: 8px; padding: .7rem .9rem; margin: 0 0 1rem; font-size: 14px; }
.notice.ok { background: var(--good-bg); color: var(--good); }
.notice.err { background: var(--bad-bg); color: var(--bad); }
.notice.info { background: var(--accent-bg); color: var(--accent-2); }
.notice.warn { background: var(--warn-bg); color: var(--warn); }
.searchbar { display: flex; gap: .5rem; margin-bottom: 1rem; }
.searchbar input { flex: 1; }
.searchbar select { width: auto; }

/* tables */
table { width: 100%; border-collapse: collapse; font-size: 14px; }
th { text-align: left; font-weight: 600; color: var(--ink-2); font-size: 13px; }
th, td { padding: .5rem .6rem; border-bottom: 1px solid var(--line); vertical-align: top; }
tr:last-child td { border-bottom: 0; }
td.num, th.num { text-align: right; font-variant-numeric: tabular-nums; }

/* tabs (CSS only) */
.tabs { margin-top: .5rem; }
.tabs > input { position: absolute; opacity: 0; pointer-events: none; }
.tabs > label { display: inline-block; margin: 0 .2rem 0 0; padding: .3rem .7rem; border-radius: 7px; cursor: pointer;
  font-size: 13px; color: var(--ink-2); font-weight: 550; }
.tabs > input:checked + label { background: var(--accent-bg); color: var(--accent-2); }
.tabs > .panel { display: none; margin-top: .5rem; }
.tabs > input:nth-of-type(1):checked ~ .panel:nth-of-type(1),
.tabs > input:nth-of-type(2):checked ~ .panel:nth-of-type(2),
.tabs > input:nth-of-type(3):checked ~ .panel:nth-of-type(3),
.tabs > input:nth-of-type(4):checked ~ .panel:nth-of-type(4),
.tabs > input:nth-of-type(5):checked ~ .panel:nth-of-type(5) { display: block; }

/* results */
.verdict { font-size: 1.02rem; margin: .2rem 0 .8rem; }
.progress { height: 8px; border-radius: 999px; background: #eceef2; overflow: hidden; margin: .4rem 0 .3rem; }
.progress > span { display: block; height: 100%; background: var(--accent); }
.chart { width: 100%; height: auto; display: block; }
.chart text { font: 12px -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif; fill: var(--ink-2); }
.chart .axis { stroke: #cfd4dc; }
.chart .zero { stroke: #9aa3af; stroke-dasharray: 3 3; }
.legend { display: flex; gap: 1rem; flex-wrap: wrap; font-size: 13px; color: var(--ink-2); margin: .4rem 0; }
.legend i { display: inline-block; width: 10px; height: 10px; border-radius: 50%; margin-right: .35rem; vertical-align: -1px; }
.bar { display: flex; align-items: center; gap: .6rem; font-size: 13px; margin: .25rem 0; }
.bar .track { flex: 1; height: 8px; background: #eceef2; border-radius: 999px; overflow: hidden; }
.bar .track span { display: block; height: 100%; background: var(--v1); }
.bar .lbl { width: 45%; color: var(--ink-2); }

/* versions and diffs */
details { margin: .5rem 0; }
details > summary { cursor: pointer; color: var(--accent); font-weight: 550; font-size: 14px; }
.skilltext { white-space: pre-wrap; background: #fbfbfc; border: 1px solid var(--line); border-radius: 8px;
  padding: .8rem 1rem; font-size: 13.5px; max-height: 30rem; overflow: auto; }
.diff { font-family: ui-monospace, Menlo, monospace; font-size: 12.5px; border: 1px solid var(--line);
  border-radius: 8px; overflow: auto; max-height: 30rem; background: #fff; }
.diff div { white-space: pre-wrap; padding: 0 .7rem; }
.diff .add { background: #e8f5ec; }
.diff .del { background: #fdecea; text-decoration: line-through; color: #8a2a20; }
.diff .hunk { background: #f3f4f6; color: var(--ink-3); }
.vdot { display: inline-block; width: 10px; height: 10px; border-radius: 50%; margin-right: .4rem; }

/* task designer */
.metric { border: 1px solid var(--line); border-radius: 8px; padding: .3rem .9rem .9rem; margin: .7rem 0; background: #fcfcfd; }
.metric .fields { display: grid; grid-template-columns: repeat(auto-fill, minmax(13rem, 1fr)); gap: 0 .9rem; }
.metric[data-kind=""] .opt, .metric .opt { display: none; }
.metric[data-kind="user_messages"] .opt.phrases, .metric[data-kind="assistant_messages"] .opt.phrases,
.metric[data-kind="last_user_message"] .opt.phrases, .metric[data-kind="shell_commands"] .opt.phrases,
.metric[data-kind="shell_commands"] .opt.outcome, .metric[data-kind="tool_calls"] .opt.tools,
.metric[data-kind="files_edited"] .opt.files, .metric[data-kind="corrections"] .opt.only { display: block; }
.nojs .metric .opt { display: block; }
.sentence { color: var(--accent-2); font-size: 13.5px; margin-top: .3rem; }
.kv { display: grid; grid-template-columns: 10rem 1fr; gap: .3rem 1rem; font-size: 14px; }
.kv dt { color: var(--ink-3); }
.kv dd { margin: 0; }
.empty { text-align: center; color: var(--ink-3); padding: 2rem 1rem; }
.prose { max-width: 46rem; }
.prose h2 { margin-top: 1.6rem; }
.prose li { margin: .25rem 0; }
pre .copy { position: absolute; top: .4rem; right: .4rem; font: inherit; font-size: .75rem; padding: .1rem .5rem;
  border: 1px solid #334155; border-radius: 6px; background: #1e293b; color: #cbd5e1; cursor: pointer; }
pre .copy:hover { color: #fff; }
.card pre { white-space: pre-wrap; word-break: break-word; padding-right: 3.5rem; }
.metric.spare { display: none; }
.nojs .metric.spare { display: block; }
.nojs .add-metric { display: none; }
.signin .actions { flex-direction: column; align-items: stretch; max-width: 22rem; }
.signin .actions .btn { justify-content: center; text-align: center; }
.signin .actions form { flex-direction: column; align-items: stretch; }
.signin .actions form input { max-width: none !important; }
.tags { display: flex; flex-wrap: wrap; gap: .3rem; margin: .2rem 0 .6rem; }
.tag { font-size: .8rem; padding: .1rem .5rem; border-radius: 999px; background: var(--accent-bg); color: var(--accent-2); }
.tag:hover { text-decoration: none; background: #d3ede9; }
.tag.on { background: var(--accent); color: #fff; }
.tag span { color: var(--ink-3); margin-left: .15rem; }
.tag.on span { color: #d3ede9; }
.tags.cloud { margin: .2rem 0 1rem; }
.picklist { max-height: 26rem; overflow-y: auto; border: 1px solid var(--line); border-radius: 8px; padding: .3rem .7rem; }
.check.pick { display: block; padding: .45rem 0; border-bottom: 1px solid var(--line); margin: 0; }
.check.pick .tags { margin: .2rem 0 0 1.6rem; }

/* newcomer path: setup checklist, numbered steps, closed sections */
.btn.big { font-size: 15px; padding: .6rem 1.15rem; }
.me-link span { color: var(--ink-2); font-weight: 500; font-size: 14px; }
.setup { border-color: #b7dcd7; background: linear-gradient(180deg, #f3faf9, #fff); margin-bottom: 1.5rem; }
.checklist { list-style: none; padding: 0; margin: .4rem 0 0; }
.checklist li { display: flex; align-items: center; gap: .6rem; padding: .35rem 0; font-size: 15px; }
.checklist li.done { color: var(--ink-3); text-decoration: line-through; text-decoration-color: #c5cbd3; }
.tick { display: inline-grid; place-items: center; width: 24px; height: 24px; border-radius: 50%; flex: none;
  border: 1.5px solid var(--accent); color: var(--accent); font-size: 12px; font-weight: 650; }
.tick.done { background: var(--accent); color: #fff; border-color: var(--accent); }
.stepper section { position: relative; padding: 0 0 1.4rem 2.75rem; border-left: 2px solid var(--line);
  margin-left: 13px; }
.stepper section:last-child { border-left-color: transparent; }
.stepper .n { position: absolute; left: -14px; top: 0; width: 26px; height: 26px; border-radius: 50%;
  background: var(--accent); color: #fff; display: grid; place-items: center; font-weight: 650; font-size: 13px; }
.stepper h2 { margin: 0 0 .4rem; font-size: 1.15rem; }
.stepper p.sub { font-weight: 600; font-size: 13px; color: var(--ink-2); margin: .8rem 0 .2rem; }
.prose details { border-top: 1px solid var(--line); padding: .6rem 0; margin: 0; }
.prose details:last-child { border-bottom: 1px solid var(--line); }
details.filters { margin: -.4rem 0 1rem; }
details.filters > summary { font-size: 13px; color: var(--ink-2); }
details.filters .searchbar { margin: .5rem 0 0; }
details.more { border: 1px dashed var(--line); border-radius: 8px; padding: .6rem .9rem; margin: 1.2rem 0 .4rem; }
details.more > summary { font-size: 14px; }
form.narrow { max-width: 52rem; }
.two { display: grid; grid-template-columns: 1fr 1fr; gap: 0 1rem; }
@media (max-width: 700px) { .two { grid-template-columns: 1fr; } }
.install { border-color: #b7dcd7; }
.install pre { white-space: pre-wrap; word-break: normal; padding-right: 4.2rem; }
.card.version .row .muted { font-size: 14px; }
details.account { margin-top: 1.5rem; padding: .9rem 1.1rem; }
details.account > summary { color: var(--ink); font-size: 15px; }
details.account .card { box-shadow: none; margin-top: .9rem; }
.card h4 { font-size: 14px; margin: 1rem 0 .4rem; }
a.pick-row { display: grid; grid-template-columns: minmax(9rem, 14rem) minmax(0, 1fr) auto; gap: 1rem; align-items: baseline;
  padding: .7rem .9rem; color: var(--ink); border-bottom: 1px solid var(--line); }
a.pick-row:last-child { border-bottom: 0; }
a.pick-row:hover { background: var(--accent-bg); text-decoration: none; }
a.pick-row .go { color: var(--accent); font-weight: 550; font-size: 14px; white-space: nowrap; }
@media (max-width: 700px) { a.pick-row { grid-template-columns: 1fr; gap: .2rem; } }
.my-task + .my-task { margin-top: .9rem; }

/* tooltips (app.js places them) and words that have one */
.tooltip { position: fixed; z-index: 50; max-width: 300px; background: var(--ink); color: #fff; font-size: 13px;
  line-height: 1.45; font-weight: 400; padding: .5rem .7rem; border-radius: 8px; box-shadow: 0 6px 18px rgba(16, 24, 40, .18);
  pointer-events: none; text-align: left; }
.tooltip[hidden] { display: none; }
.term { border-bottom: 1px dotted currentColor; cursor: help; }
.term:focus { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 2px; }
[data-tip]:not(.term) { cursor: help; }
a[data-tip], button[data-tip] { cursor: pointer; }

/* the member's own tasks, wherever tasks are listed */
.card.mine { border-color: var(--accent); background: #f3faf8; box-shadow: inset 4px 0 0 var(--accent); }
.swatch { display: inline-block; width: .8rem; height: .8rem; border-radius: 3px; background: #f3faf8;
  border: 1px solid var(--accent); box-shadow: inset 3px 0 0 var(--accent); vertical-align: -1px; }
