/* Pomodoro: "the quiet study desk".
   Paper and blue-black ink. Tomato red appears in one place at a time (the running timer, something urgent),
   sage green means break or done. No cards by default: whitespace and hairline rules do the grouping. */

/* ---------- fonts (self-hosted, SIL OFL) ---------- */
@font-face { font-family: "Newsreader"; font-style: normal; font-weight: 200 800; font-display: swap;
  src: url(fonts/newsreader-latin-opsz-normal.woff2) format("woff2-variations");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Newsreader"; font-style: normal; font-weight: 200 800; font-display: swap;
  src: url(fonts/newsreader-latin-ext-opsz-normal.woff2) format("woff2-variations");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+1E00-1E9F, U+20A0-20AB, U+20AD-20C0, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Newsreader"; font-style: italic; font-weight: 200 800; font-display: swap;
  src: url(fonts/newsreader-latin-opsz-italic.woff2) format("woff2-variations");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+20AC, U+2122, U+2212; }
@font-face { font-family: "Newsreader"; font-style: italic; font-weight: 200 800; font-display: swap;
  src: url(fonts/newsreader-latin-ext-opsz-italic.woff2) format("woff2-variations");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+1E00-1E9F, U+A720-A7FF; }
@font-face { font-family: "IBM Plex Sans"; font-weight: 400; font-display: swap; src: url(fonts/ibm-plex-sans-latin-400-normal.woff2) format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+20AC, U+2122, U+2212; }
@font-face { font-family: "IBM Plex Sans"; font-weight: 400; font-display: swap; src: url(fonts/ibm-plex-sans-latin-ext-400-normal.woff2) format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+1E00-1E9F, U+A720-A7FF; }
@font-face { font-family: "IBM Plex Sans"; font-style: italic; font-weight: 400; font-display: swap; src: url(fonts/ibm-plex-sans-latin-400-italic.woff2) format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+2000-206F; }
@font-face { font-family: "IBM Plex Sans"; font-style: italic; font-weight: 400; font-display: swap; src: url(fonts/ibm-plex-sans-latin-ext-400-italic.woff2) format("woff2");
  unicode-range: U+0100-02BA, U+1E00-1E9F; }
@font-face { font-family: "IBM Plex Sans"; font-weight: 500; font-display: swap; src: url(fonts/ibm-plex-sans-latin-500-normal.woff2) format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+20AC, U+2122, U+2212; }
@font-face { font-family: "IBM Plex Sans"; font-weight: 500; font-display: swap; src: url(fonts/ibm-plex-sans-latin-ext-500-normal.woff2) format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+1E00-1E9F, U+A720-A7FF; }
@font-face { font-family: "IBM Plex Sans"; font-weight: 600; font-display: swap; src: url(fonts/ibm-plex-sans-latin-600-normal.woff2) format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+20AC, U+2122, U+2212; }
@font-face { font-family: "IBM Plex Sans"; font-weight: 600; font-display: swap; src: url(fonts/ibm-plex-sans-latin-ext-600-normal.woff2) format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+1E00-1E9F, U+A720-A7FF; }

/* ---------- tokens ---------- */
:root {
  color-scheme: light;
  --paper: #f3f4f0; --sheet: #fbfbf9; --ink: #1a2130; --graphite: #5a6371; --rule: #d8dcd3; --rule-2: #e6e9e2;
  --tomato: #cf3a28; --sage: #3e6b57; --sage-wash: #e3ece6; --tomato-wash: #f7e6e2;
  /* supporting inks: used for meaning (mastery, status, course colours), never as decoration */
  --blue: #3b5b9a; --blue-wash: #e4e9f3; --ochre: #a8741f; --ochre-wash: #f4ead8; --plum: #6e5a8a;
  --serif: "Newsreader", "Iowan Old Style", Georgia, serif;
  --sans: "IBM Plex Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --r: 10px; --r-s: 6px;
  --page: 1120px; --gutter: clamp(20px, 4vw, 48px);
}
@media (prefers-color-scheme: dark) {
  :root {
    color-scheme: dark;
    --paper: #12161c; --sheet: #191e26; --ink: #e4e6e1; --graphite: #98a0ac; --rule: #2b323c; --rule-2: #222830;
    --tomato: #e4573f; --sage: #7db095; --sage-wash: #17241e; --tomato-wash: #2a1a18;
    --blue: #8aa6d8; --blue-wash: #18202e; --ochre: #d9a54e; --ochre-wash: #2a2216; --plum: #b39ad0;
  }
}

/* ---------- base ---------- */
*, *::before, *::after { box-sizing: border-box; min-width: 0; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--paper); color: var(--ink); font: 400 16px/1.55 var(--sans);
  font-feature-settings: "kern"; -webkit-font-smoothing: antialiased; }
a { color: var(--ink); text-decoration: underline; text-decoration-color: var(--rule); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { text-decoration-color: currentColor; }
:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; border-radius: 2px; }
::selection { background: color-mix(in srgb, var(--tomato) 22%, transparent); }
h1, h2, h3 { margin: 0; font-weight: 600; }
h1 { font-family: var(--serif); font-weight: 500; font-size: clamp(32px, 4.4vw, 46px); line-height: 1.08; letter-spacing: -.01em; text-wrap: balance; }
h2 { font-size: 17px; line-height: 1.3; }
h3 { font-size: 15px; line-height: 1.35; }
p { margin: 0 0 12px; }
strong, b { font-weight: 600; }
.num { font-variant-numeric: tabular-nums; }

/* ---------- frame ---------- */
.top { max-width: var(--page); margin: 0 auto; padding: 18px var(--gutter); display: flex; align-items: center; gap: 28px; }
.brand { display: flex; align-items: center; gap: 9px; text-decoration: none; font-family: var(--serif); font-size: 21px; font-weight: 500; }
.brand img { width: 20px; height: 20px; }
.tabs { display: flex; gap: 4px; margin-right: auto; }
.tabs a { padding: 6px 10px; color: var(--graphite); text-decoration: none; font-weight: 500; font-size: 15px; border-radius: var(--r-s); }
.tabs a:hover { color: var(--ink); }
.tabs a[aria-current=page] { color: var(--ink); box-shadow: inset 0 -2px 0 var(--tomato); border-radius: 0; }
.nav { display: flex; align-items: center; gap: 18px; font-size: 14px; }
.nav a, .nav .link { color: var(--graphite); text-decoration: none; }
.nav a:hover, .nav .link:hover { color: var(--ink); }
.nav form { margin: 0; }
.link { background: none; border: 0; padding: 0; font: inherit; color: var(--graphite); cursor: pointer; }
.topbar { border-bottom: 1px solid var(--rule); }
.tabs a { flex: none; white-space: nowrap; }
/* below ~1040px the section tabs get their own row, so nothing is squeezed */
@media (max-width: 1040px) {
  .top { flex-wrap: wrap; gap: 10px 16px; padding-top: 14px; padding-bottom: 6px; }
  .nav { margin-left: auto; }
  .tabs { order: 3; width: 100%; margin: 0 -10px; overflow-x: auto; }
}

.wrap { max-width: var(--page); margin: 0 auto; padding: clamp(28px, 4vw, 48px) var(--gutter) 80px; }
.narrow { max-width: 520px; }

/* page head: title, then a plain sentence about where things stand */
.page-head { margin-bottom: clamp(28px, 4vw, 44px); max-width: 860px; }
.crumb { font-size: 14px; color: var(--graphite); margin: 0 0 10px; }
.crumb a { color: var(--graphite); }
.sub { color: var(--graphite); margin: 10px 0 0; font-size: 15px; }
.summary { font-family: var(--serif); font-size: clamp(19px, 2vw, 22px); line-height: 1.45; margin: 18px 0 0; max-width: 62ch; }
.summary b { font-weight: 600; font-variant-numeric: tabular-nums lining-nums; }
.summary .urgent { color: var(--tomato); }

/* columns */
.grid2 { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 40px clamp(32px, 5vw, 72px); align-items: start; }
@media (max-width: 900px) { .grid2 { grid-template-columns: minmax(0, 1fr); } }
.stack-lg { display: grid; gap: 40px; align-content: start; }

/* a section is a heading on a hairline, not a box */
.card { border-top: 1px solid var(--rule); padding-top: 14px; }
.card > h2, .section-h { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; margin-bottom: 10px; }
.card > h2 .meta, .section-h .meta { font-weight: 400; }
.card + .card, section.card + section.card { margin-top: 40px; }
.stack-lg > .card + .card { margin-top: 0; }

/* the one raised surface: work areas and forms */
.panel { background: var(--sheet); border: 1px solid var(--rule); border-radius: var(--r); padding: clamp(20px, 3vw, 32px); }

/* ---------- text bits ---------- */
.lead { font-size: 18px; color: var(--graphite); max-width: 56ch; }
.meta { color: var(--graphite); font-size: 14px; }
.muted { color: var(--graphite); }
.fine { font-size: 14px; color: var(--graphite); margin-top: 18px; }
.error { color: var(--tomato); font-weight: 500; }
.saved { color: var(--sage); font-weight: 500; }
.tight { margin: 4px 0 0; }
.empty { color: var(--graphite); padding: 10px 0; }
.hint { color: var(--graphite); padding: 10px 0; max-width: 58ch; }
.prompt { font-family: var(--serif); font-style: italic; color: var(--ink); font-size: 1.06em; }
.tag { display: inline-block; font-size: 12px; line-height: 1; font-weight: 500; padding: 4px 7px; border: 1px solid var(--rule); border-radius: 99px; color: var(--graphite); white-space: nowrap; vertical-align: 1px; }
.tag.urgent { color: var(--tomato); border-color: color-mix(in srgb, var(--tomato) 45%, transparent); }
.tag.good { color: var(--sage); border-color: color-mix(in srgb, var(--sage) 45%, transparent); }
.when { font-size: 14px; color: var(--graphite); white-space: nowrap; font-variant-numeric: tabular-nums; }
.when.urgent { color: var(--tomato); font-weight: 500; }

/* ---------- buttons + inputs ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 0 20px; border: 1px solid var(--ink);
  border-radius: var(--r-s); background: var(--ink); color: var(--paper); font: 500 15px/1 var(--sans); text-decoration: none; cursor: pointer; }
.btn:hover { background: color-mix(in srgb, var(--ink) 88%, var(--paper)); }
.btn-quiet, .btn-google { background: transparent; color: var(--ink); border-color: var(--rule); }
.btn-quiet:hover, .btn-google:hover { background: transparent; border-color: var(--ink); }
.btn:disabled { opacity: .4; cursor: default; }
.actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 22px; }
label { font-weight: 500; font-size: 14px; }
.input { min-height: 44px; width: 100%; padding: 9px 12px; border: 1px solid var(--rule); border-radius: var(--r-s); background: var(--sheet);
  color: var(--ink); font: 400 16px/1.4 var(--sans); }
.input:hover { border-color: color-mix(in srgb, var(--graphite) 50%, var(--rule)); }
.input:focus { outline: none; border-color: var(--ink); box-shadow: 0 0 0 1px var(--ink); }
.input::placeholder { color: color-mix(in srgb, var(--graphite) 75%, transparent); }
select.input { appearance: auto; }
textarea.input { min-height: 150px; resize: vertical; line-height: 1.5; }
textarea.input.small { min-height: 84px; }
.code { font-variant-numeric: tabular-nums; letter-spacing: .08em; text-transform: uppercase; }
.form { display: grid; gap: 16px; max-width: 640px; }
.form label { display: grid; gap: 6px; }
.form .two { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.form .three { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.form.compact { gap: 12px; margin-top: 12px; }
.form .help { font-weight: 400; color: var(--graphite); }
@media (max-width: 560px) { .form .two { grid-template-columns: 1fr; } }
.stack { display: grid; gap: 10px; margin-top: 8px; }
.row { display: flex; flex-wrap: wrap; gap: 12px; align-items: flex-end; margin: 18px 0 28px; }
.row label { display: grid; gap: 6px; }
.grow { flex: 1 1 220px; }

/* ---------- lists: rows on hairlines ---------- */
.list { list-style: none; margin: 0; padding: 0; }
.list li { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; padding: 11px 0; border-bottom: 1px solid var(--rule-2); }
.list li:last-child { border-bottom: 0; }
.list .grow { flex: 1; }
.list .title { font-weight: 500; }
.list .line { display: block; color: var(--graphite); font-size: 14px; margin-top: 2px; }
.list .body { display: block; margin-top: 4px; max-width: 70ch; }
.list form { margin: 0; }
.list li.empty { display: block; }

/* table-like rows for courses and projects */
.rows { list-style: none; margin: 0; padding: 0; }
.rows > li > a { display: grid; grid-template-columns: minmax(0, 1fr) 132px 112px; gap: 4px 24px; align-items: center; padding: 15px 0;
  border-bottom: 1px solid var(--rule-2); text-decoration: none; }
.rows > li > a:hover .rname { text-decoration: underline; text-decoration-color: var(--rule); text-underline-offset: 3px; }
.rname { grid-column: 1; grid-row: 1; font-weight: 500; font-size: 16px; }
.rows .line { grid-column: 1; grid-row: 2; color: var(--graphite); font-size: 14px; }
.rows .cell { grid-row: 1 / span 2; }
.rows .cell.mid { grid-column: 2; }
.rows .cell.end { grid-column: 3; text-align: right; }
.rows li:last-child > a { border-bottom: 0; }
@media (max-width: 600px) {
  .rows > li > a { grid-template-columns: minmax(0, 1fr) auto; }
  .rows .cell.mid { grid-column: 1; grid-row: 3; }
  .rows .cell.end { grid-column: 2; grid-row: 1; }
}

/* ---------- measures ---------- */
.bar { height: 6px; background: var(--rule-2); border-radius: 99px; overflow: hidden; display: flex; }
.bar span { display: block; height: 100%; }
.bar .done { background: var(--sage); }
.bar .now { background: color-mix(in srgb, var(--blue) 45%, transparent); }
.legend { display: flex; gap: 18px; font-size: 13px; color: var(--graphite); flex-wrap: wrap; margin-top: 14px; }
.legend i { display: inline-block; width: 10px; height: 10px; border-radius: 2px; margin-right: 6px; vertical-align: -1px; }
.k-done, .k-m3 { background: var(--sage); }
.k-now { background: color-mix(in srgb, var(--blue) 45%, transparent); }
.k-m2 { background: var(--blue); }
.k-m1 { background: var(--ochre); }
.k-left, .k-m0 { background: var(--rule-2); box-shadow: inset 0 0 0 1px var(--rule); }

/* three-step mastery meter: ▮▮▯ */
.meter { display: inline-flex; gap: 3px; vertical-align: middle; }
.meter i { width: 16px; height: 6px; border-radius: 2px; background: var(--rule-2); box-shadow: inset 0 0 0 1px var(--rule); }
.meter i.on { background: var(--ink); box-shadow: none; }
.meter.lv1 i.on { background: var(--ochre); } .meter.lv2 i.on { background: var(--blue); } .meter.lv3 i.on { background: var(--sage); }
.meter-label { font-size: 13px; color: var(--graphite); margin-left: 8px; font-variant-numeric: tabular-nums; }

/* curriculum */
.req { display: grid; grid-template-columns: minmax(0, 1fr) 84px; gap: 6px 18px; padding: 14px 0; border-bottom: 1px solid var(--rule-2); }
.req:last-of-type { border-bottom: 0; }
.req-name { font-weight: 500; }
.req-num { text-align: right; font-size: 14px; color: var(--graphite); font-variant-numeric: tabular-nums; }
.req .bar { grid-column: 1 / -1; }
.req-courses { grid-column: 1 / -1; font-size: 14px; color: var(--graphite); margin: 2px 0 0; }
.req-courses a { color: var(--ink); }

/* mastery map */
.mastery { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(150px, 45%), 1fr)); gap: 0 24px; }
.topic { padding: 12px 0; border-bottom: 1px solid var(--rule-2); font-size: 15px; }
.topic .meter { margin-top: 8px; }
.topic small { display: block; color: var(--graphite); font-size: 13px; margin-top: 4px; }
.topic .due { color: var(--tomato); font-weight: 500; }

/* roadmap: milestones on a line */
.roadmap { list-style: none; margin: 4px 0 0; padding: 0 0 0 22px; border-left: 1px solid var(--rule); }
.roadmap li { position: relative; padding: 0 0 22px 4px; }
.roadmap li:last-child { padding-bottom: 4px; }
.roadmap li::before { content: ""; position: absolute; left: -28px; top: 6px; width: 11px; height: 11px; border-radius: 50%; background: var(--paper); border: 1.5px solid var(--graphite); }
.roadmap li.done::before { background: var(--sage); border-color: var(--sage); }
.roadmap li.in_progress::before { border: 3px solid var(--blue); }
.roadmap li.dropped { color: var(--graphite); text-decoration: line-through; }
.roadmap .line { display: block; color: var(--graphite); font-size: 14px; }

/* focus-time chart */
.chart { display: grid; grid-template-columns: repeat(14, minmax(0, 1fr)); gap: 6px; align-items: end; height: 132px; margin-top: 8px; }
.chart .col { display: flex; flex-direction: column; justify-content: flex-end; align-items: center; height: 100%; text-align: center; }
.chart .col span { display: block; width: min(100%, 22px); background: var(--ink); border-radius: 2px 2px 0 0; min-height: 1px; }
.chart .col.today span { background: var(--tomato); }
.chart .col small { font-size: 11px; color: var(--graphite); margin-top: 6px; font-variant-numeric: tabular-nums; }

/* ---------- reading ---------- */
.prose { font-family: var(--serif); font-size: 19px; line-height: 1.6; max-width: 66ch; }
.prose > :first-child { margin-top: 0; }
.prose h1, .prose h2, .prose h3 { font-family: var(--serif); font-weight: 600; line-height: 1.25; margin: 1.5em 0 .45em; }
.prose h1 { font-size: 1.5em; } .prose h2 { font-size: 1.28em; } .prose h3 { font-size: 1.08em; }
.prose p, .prose ul, .prose ol { margin: 0 0 .85em; }
.prose code { font-family: ui-monospace, "SF Mono", Menlo, monospace; font-size: .82em; background: var(--rule-2); padding: 1px 5px; border-radius: 4px; }
.prose pre { background: var(--sheet); border: 1px solid var(--rule); padding: 14px; border-radius: var(--r-s); overflow-x: auto; }
.prose pre code { background: none; padding: 0; }
.prose table { border-collapse: collapse; font-family: var(--sans); font-size: 15px; }
.prose td, .prose th { border-bottom: 1px solid var(--rule); padding: 6px 12px 6px 0; text-align: left; }
.prose blockquote { border-left: 2px solid var(--rule); margin: 0 0 .85em; padding-left: 16px; color: var(--graphite); }
.small-prose { font-size: 17px; }

/* ---------- account pages ---------- */
.hero { display: grid; gap: 22px; max-width: 620px; padding-top: clamp(24px, 8vh, 96px); }
.hero-mark { width: 44px; height: 44px; }
.hero h1 { font-size: clamp(40px, 6vw, 64px); line-height: 1.02; }
.table { width: 100%; border-collapse: collapse; font-size: 15px; margin-top: 8px; }
.table th, .table td { text-align: left; padding: 11px 12px 11px 0; border-bottom: 1px solid var(--rule-2); }
.table th { font-size: 13px; color: var(--graphite); font-weight: 500; border-bottom-color: var(--rule); }
.newcode { border: 1px solid var(--ink); border-radius: var(--r); padding: 16px 18px; margin: 14px 0 22px; }
.newcode p { margin: 0 0 6px; }
.big { font-size: 24px; font-weight: 600; user-select: all; overflow-wrap: anywhere; }
code.copy { display: block; padding: 11px 14px; border: 1px solid var(--rule); background: var(--sheet); border-radius: var(--r-s); overflow-wrap: anywhere;
  user-select: all; font: 400 14px/1.4 ui-monospace, "SF Mono", Menlo, monospace; margin: 6px 0 22px; }
.consent .warn { border-left: 2px solid var(--tomato); padding-left: 12px; color: var(--ink); }

@media (prefers-reduced-motion: reduce) { * { transition: none !important; animation: none !important; } }
.urgent-text { color: var(--tomato); }
.filter { margin: 0 0 18px -10px; }
.papers .title a { text-decoration-color: var(--rule); }
.panel h1, .narrow h1 { font-size: clamp(28px, 3.4vw, 36px); margin-bottom: 14px; }
.panel .lead { font-size: 17px; }
.consent .meta { margin-bottom: 10px; }
.wrap > .narrow { margin-top: clamp(8px, 4vh, 40px); }
#claude h3 { margin: 8px 0 0; font-size: 15px; }
.inline-form { display: flex; gap: 8px; align-items: center; margin: 0; }
.inline-form .input { width: auto; min-width: 120px; }
.storage-h { margin-top: 28px !important; }
.bar.storage { margin-top: 8px; }

/* ---------- notes: list, editor, rendering ---------- */
.head-row { display: flex; justify-content: space-between; align-items: flex-end; gap: 20px; flex-wrap: wrap; max-width: none; }
.filters { margin-top: 0; }
.list a.title { text-decoration: none; }
.list a.title:hover { text-decoration: underline; text-decoration-color: var(--rule); }
.editor { display: grid; gap: 18px; max-width: 900px; }
.editor label { display: grid; gap: 6px; }
.title-field .input { font: 500 22px/1.3 var(--serif); min-height: 52px; }
.meta-fields { display: grid; grid-template-columns: 2fr 1.4fr 1fr 1.2fr 1fr; gap: 12px; }
.meta-fields .wide { grid-column: 1 / -1; }
@media (max-width: 760px) { .meta-fields { grid-template-columns: 1fr 1fr; } }
.editor-tabs { margin: 6px 0 -10px; gap: 2px; }
.editor-tabs button { background: none; border: 0; padding: 8px 12px; font: 500 15px var(--sans); color: var(--graphite); cursor: pointer; }
.editor-tabs button[aria-selected=true] { color: var(--ink); box-shadow: inset 0 -2px 0 var(--ink); }
textarea.body-field { min-height: 62vh; font: 400 15px/1.6 ui-monospace, "SF Mono", Menlo, Consolas, monospace; tab-size: 4; }
.preview { min-height: 62vh; border: 1px solid var(--rule); border-radius: var(--r-s); padding: 22px 26px; background: var(--sheet); max-width: none; }
.syntax { font-size: 14px; color: var(--graphite); }
.syntax summary { min-height: 36px; font-size: 14px; color: var(--graphite); }
.syntax ul { margin: 6px 0 0; padding-left: 18px; display: grid; gap: 6px; }
.syntax code { font: 13px ui-monospace, "SF Mono", Menlo, monospace; color: var(--ink); background: var(--rule-2); padding: 1px 5px; border-radius: 4px; }
.delete-link { color: var(--tomato); font-size: 14px; margin-left: auto; align-self: center; }
.kbd-hint { align-self: center; }
@media (max-width: 600px) { .kbd-hint { display: none; } }
.conflict { border-left: 2px solid var(--tomato); padding: 4px 0 4px 14px; margin-bottom: 20px; max-width: 70ch; }
.btn-danger { background: var(--tomato); border-color: var(--tomato); color: #fff; }
.btn-danger:hover { background: color-mix(in srgb, var(--tomato) 88%, #000); }
.note-actions { display: flex; gap: 16px; align-items: center; margin-top: 12px; font-size: 14px; }

/* maths (MathML from the server) */
math { font-family: "STIX Two Math", "Cambria Math", "Latin Modern Math", math; font-size: 1.05em; }
.math.block { overflow-x: auto; overflow-y: hidden; margin: 1em 0; padding: 4px 0; }
.math.block math { display: block; }
.math-error { color: var(--tomato); }

/* callouts: folded solutions and hints, labelled boxes */
.callout { margin: 1.1em 0; border-left: 2px solid var(--rule); padding: 2px 0 2px 18px; }
.callout > :last-child { margin-bottom: 0; }
.callout-label, .callout summary { display: block; font: 600 14px/1.4 var(--sans); color: var(--graphite); margin-bottom: 6px; }
.callout.theorem, .callout.definition { border-left-color: var(--ink); }
.callout.warning { border-left-color: var(--tomato); }
details.callout { border-left-color: var(--sage); }
details.callout summary { cursor: pointer; list-style: none; margin: 0; min-height: 32px; display: flex; align-items: center; gap: 8px; color: var(--sage); }
details.callout summary::-webkit-details-marker { display: none; }
details.callout summary::before { content: "+"; display: inline-grid; place-items: center; width: 18px; height: 18px; border: 1px solid currentColor; border-radius: 50%; font-size: 13px; line-height: 1; }
details.callout[open] summary::before { content: "–"; }
details.callout[open] summary { margin-bottom: 8px; }
.prose .contains-task-list { list-style: none; padding-left: 4px; }
.prose .task-list-item-checkbox { margin: 0 8px 0 0; accent-color: var(--ink); }

/* code colours: calm, ink-based */
.prose pre code { color: var(--ink); }
.prose .k, .prose .kd, .prose .kn, .prose .kr, .prose .kt, .prose .kc, .prose .ow { font-weight: 600; }
.prose .s, .prose .s1, .prose .s2, .prose .sb, .prose .sd, .prose .sh, .prose .si, .prose .sx, .prose .sc, .prose .se { color: var(--sage); }
.prose .c, .prose .c1, .prose .cm, .prose .cs, .prose .ch, .prose .cp, .prose .cpf { color: var(--graphite); font-style: italic; }
.prose .m, .prose .mi, .prose .mf, .prose .mh, .prose .mo, .prose .il { color: var(--tomato); }
.prose .nf, .prose .fm, .prose .nc, .prose .nd { color: color-mix(in srgb, var(--ink) 70%, #3b5b9a); }
.prose .nb, .prose .bp { color: color-mix(in srgb, var(--ink) 75%, var(--sage)); }
.prose .err { color: var(--tomato); }

/* ---------- plan ---------- */
.days { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 36px 48px; }
.days .card + .card { margin-top: 0; }
.day.weekend h2 { color: var(--graphite); }
.day .empty { padding: 6px 0; }
section.card.day + .days { margin-top: 40px; }
.plan-list { list-style: none; margin: 0; padding: 0; }
.plan-row { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--rule-2);
  text-decoration: none; color: inherit; }
.plan-list li:last-child .plan-row { border-bottom: 0; }
.dnd-hint { margin: -8px 0 20px; }
.plan-row.movable { cursor: grab; }
li[draggable="true"].dragging { opacity: .45; }
li[draggable="true"].dragging .plan-row { cursor: grabbing; }
.day.drop { outline: 2px dashed var(--sage); outline-offset: 4px; border-radius: var(--r); }
.quote-btn { position: fixed; z-index: 50; font: 500 13px/1 var(--sans); color: var(--sheet); background: var(--ink);
  border: 0; border-radius: var(--r-s); padding: 8px 12px; cursor: pointer; box-shadow: 0 2px 10px rgba(0,0,0,.22); }
.quote-btn:hover { background: var(--tomato); }
.quote-toast { position: fixed; z-index: 50; left: 50%; bottom: 28px; transform: translateX(-50%);
  font: 500 13px/1 var(--sans); color: var(--sheet); background: var(--ink); border-radius: var(--r-s); padding: 10px 14px;
  box-shadow: 0 2px 10px rgba(0,0,0,.22); }

/* Save a note as PDF = the browser's print-to-PDF. Drop the app chrome, keep the note. */
@media print {
  @page { margin: 18mm; }
  .topbar, .nav, .tabs, .mini, .mini-sound, #toast, footer,
  .note-actions, .pdf-btn, .quote-btn, .quote-toast { display: none !important; }
  html, body { background: #fff !important; color: #111 !important; }
  .wrap { max-width: none !important; margin: 0 !important; padding: 0 !important; }
  .page-head { margin-bottom: 14px; }
  .prose a { color: #111; text-decoration: underline; }
  .prose h1, .prose h2, .prose h3, .prose h4 { break-after: avoid; }
  .prose pre, .prose table, .prose img, .prose figure, .callout, details.callout { break-inside: avoid; }
  /* keep code highlighting and callout tints in the PDF */
  .prose pre, .prose code, .callout { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  details.callout > summary { list-style: none; font-weight: 600; }
}
.plan-row .title { font-weight: 500; }
.plan-row .line { display: block; color: var(--graphite); font-size: 14px; margin-top: 2px; }
.plan-row:hover .title { text-decoration: underline; text-decoration-color: var(--rule); text-underline-offset: 3px; }
.plan-row.is-done .title { color: var(--graphite); }
.plan-row.is-done:has(.tag:not(.good)) .title { text-decoration: line-through; }
.edit-hint { font-size: 13px; color: var(--graphite); opacity: 0; }
.plan-row:hover .edit-hint, .plan-row:focus-visible .edit-hint { opacity: 1; }
.session-form { max-width: 640px; }
.goals-edit { border: 0; padding: 0; margin: 4px 0 0; display: grid; gap: 10px; }
.goals-edit legend { font-weight: 500; font-size: 14px; margin-bottom: 8px; padding: 0; }
.goal-edit { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; gap: 10px; align-items: center; }
.goal-edit .remove { display: flex; gap: 6px; align-items: center; font-weight: 400; color: var(--graphite); }
.check { display: flex !important; gap: 10px; align-items: center; font-weight: 400; }
.check input, .goal-edit input[type=checkbox] { width: 18px; height: 18px; accent-color: var(--ink); }
.now-edit { font-size: 14px; color: var(--graphite); margin-left: 12px; }
.plan-more { margin: 8px 0 0; }
.day:not(:has(.plan-list)) { padding-bottom: 0; }
.day:not(:has(.plan-list)) > h2 { margin-bottom: 0; }
.day:not(:has(.plan-list)) .empty { padding: 2px 0 0; font-size: 14px; }
@media (max-width: 600px) { .days { gap: 22px; } }

/* ---------- long lists: tabs, "show more", pages ---------- */
.subtabs { display: flex; gap: 2px; flex-wrap: wrap; border-bottom: 1px solid var(--rule); margin: 0 0 18px; }
.subtabs a { display: inline-flex; align-items: center; gap: 7px; padding: 9px 12px 10px; color: var(--graphite); text-decoration: none;
  font-weight: 500; font-size: 15px; margin-bottom: -1px; border-bottom: 2px solid transparent; }
.subtabs a:hover { color: var(--ink); }
.subtabs a[aria-current=page] { color: var(--ink); border-bottom-color: var(--ink); }
.subtabs .count { font-size: 12px; font-weight: 500; color: var(--graphite); background: var(--rule-2); border-radius: 99px; padding: 1px 7px; font-variant-numeric: tabular-nums; }
.subtabs.small a { padding: 6px 10px 8px; font-size: 14px; }
details.more { margin-top: 2px; }
details.more > summary { font-size: 14px; color: var(--graphite); min-height: 40px; cursor: pointer; list-style: none; display: flex; align-items: center; gap: 8px; }
details.more > summary::-webkit-details-marker { display: none; }
details.more > summary::before { content: "+"; display: inline-grid; place-items: center; width: 18px; height: 18px; border: 1px solid var(--rule); border-radius: 50%; font-size: 13px; line-height: 1; }
details.more[open] > summary { display: none; }
details.more > summary:hover { color: var(--ink); }
.more-link { font-size: 14px; margin: 10px 0 0; }
.more-link a { color: var(--graphite); }
.pager { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 12px; margin-top: 24px; }
.pager > :last-child { justify-self: end; }
.clamp-2, .clamp-3, .list .clamp-2, .list .clamp-3 { display: -webkit-box; -webkit-box-orient: vertical; overflow: hidden; }
.clamp-2 { -webkit-line-clamp: 2; line-clamp: 2; }
.clamp-3 { -webkit-line-clamp: 3; line-clamp: 3; }
.tab-actions { margin: 0 0 6px; }
.clear-link { align-self: center; }
/* filter pills inside a tab (e.g. which topics) */
.subtabs.pills { border-bottom: 0; gap: 6px; margin: -4px 0 14px; }
.subtabs.pills a { border: 1px solid var(--rule); border-bottom-width: 1px; border-radius: 99px; padding: 4px 12px; font-size: 14px; margin: 0; }
.subtabs.pills a[aria-current=page] { border-color: var(--ink); background: var(--ink); color: var(--paper); }
.subtabs.pills a[aria-current=page] .count { background: transparent; color: var(--paper); }
.done-fold { margin-bottom: 14px; }
.done-fold .roadmap { margin-bottom: 8px; }

/* ---------- chains ---------- */
.chain-row { padding: 18px 0 20px; border-bottom: 1px solid var(--rule-2); }
.chain-row:last-of-type { border-bottom: 0; }
.chain-head { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 4px 24px; align-items: center; margin-bottom: 12px; }
.chain-count { margin: 0; display: flex; align-items: baseline; gap: 8px; min-width: 120px; }
.chain-num { font-family: var(--serif); font-size: 52px; line-height: .9; font-weight: 500; font-variant-numeric: lining-nums tabular-nums; }
.chain-num.zero { color: var(--graphite); }
.chain-unit { color: var(--graphite); font-size: 14px; max-width: 7em; line-height: 1.25; }
.chain-what h3 { font-size: 16px; font-weight: 600; margin: 0 0 2px; }
.chain-what .meta { margin: 0; }
.chain-edit { align-self: start; }
.chain { display: block; max-width: 100%; height: auto; overflow: visible; }
.chain .link rect { fill: none; stroke-width: 2.6; }
.chain .link.kept rect { stroke: var(--sage); }
.chain .link.side rect { stroke-width: 2.2; }
.chain .link.broken rect { stroke: var(--rule); stroke-dasharray: 34 10; stroke-dashoffset: -6; }
.chain .link.current rect { stroke: var(--graphite); stroke-dasharray: 3 4; }
@media (max-width: 600px) {
  .chain-head { grid-template-columns: auto minmax(0, 1fr); }
  .chain-edit { grid-column: 2; justify-self: start; }
  .chain-num { font-size: 42px; }
}

/* ---------- the timer on every page ---------- */
.topbar { position: relative; }
.hprogress { position: absolute; left: 0; right: 0; bottom: -1px; height: 2px; overflow: hidden; pointer-events: none; }
.hprogress span { display: block; height: 100%; background: var(--tomato); transform-origin: left center; transform: scaleX(0);
  transition: transform 1s linear, background-color .6s ease; }
.hprogress[data-phase=break] span, .hprogress[data-phase=long_break] span { background: var(--sage); }
.mini { display: inline-flex; align-items: center; gap: 8px; padding: 5px 12px; border: 1px solid var(--rule); border-radius: 99px;
  text-decoration: none; color: var(--ink); font-size: 14px; white-space: nowrap; max-width: 340px; }
.mini:hover { border-color: var(--ink); }
.mini[hidden] { display: none; }
.mini-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--tomato); flex: none; }
.mini[data-phase=break] .mini-dot, .mini[data-phase=long_break] .mini-dot { background: var(--sage); }
.mini[data-state=paused] .mini-dot { background: var(--graphite); }
.mini[data-state=running] .mini-dot { animation: breathe 4s ease-in-out infinite; }
.mini[data-state=done] { border-color: var(--ink); }
.mini-phase { color: var(--graphite); }
.mini-clock { font-weight: 600; font-variant-numeric: tabular-nums; }
.mini-what { color: var(--graphite); overflow: hidden; text-overflow: ellipsis; max-width: 16ch; }
.mini-sound { font-size: 13px; }
@keyframes breathe { 0%, 100% { opacity: .35; transform: scale(.85); } 50% { opacity: 1; transform: scale(1); } }
@media (max-width: 720px) {
  .mini { order: 4; width: 100%; justify-content: center; max-width: none; border-radius: var(--r-s); margin-bottom: 6px; }
  .mini-sound { order: 5; width: 100%; text-align: center; }
}
.brand, .brand img, .nav, .mini-sound { flex: none; }
.nav, .mini-sound { white-space: nowrap; }
@media (max-width: 1180px) and (min-width: 721px) { .mini-what { display: none; } }

/* ---------- getting started + guide ---------- */
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.start { border: 1px solid var(--rule); border-radius: var(--r); background: var(--sheet); padding: 18px 22px 8px; margin-bottom: 40px; }
.start.is-welcome { border-color: var(--ink); }
.start[hidden] { display: none; }
.start-head { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; flex-wrap: wrap; margin-bottom: 6px; }
.start-links { display: flex; gap: 16px; font-size: 14px; }
.start-links a, .start-links .link { color: var(--graphite); font-size: 14px; }
.start-steps { list-style: none; margin: 0; padding: 0; }
.start-steps li { display: flex; gap: 14px; align-items: baseline; padding: 11px 0; border-top: 1px solid var(--rule-2); }
.start-steps li > a { white-space: nowrap; }
.start-mark { flex: none; width: 24px; height: 24px; border-radius: 50%; border: 1.5px solid var(--graphite); display: grid; place-items: center;
  font-size: 13px; font-weight: 600; color: var(--graphite); align-self: flex-start; }
.start-steps li.done .start-mark { background: var(--ink); border-color: var(--ink); color: var(--paper); }
.start-steps li.done .start-mark svg { width: 14px; height: 14px; }
.start-steps li.done .title { color: var(--graphite); text-decoration: line-through; text-decoration-color: var(--rule); }
.start-steps .line { display: block; color: var(--graphite); font-size: 14px; margin-top: 2px; max-width: 72ch; }
.inline-copy { font: 13px ui-monospace, "SF Mono", Menlo, monospace; background: var(--rule-2); padding: 1px 5px; border-radius: 4px; overflow-wrap: anywhere; user-select: all; }
@media (max-width: 600px) { .start-steps li { flex-wrap: wrap; } .start-steps li > a { margin-left: 38px; } }

.guide { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: 56px; align-items: start; }
.guide-toc { position: sticky; top: 24px; font-size: 15px; }
.guide-toc ol { list-style: none; margin: 0; padding: 0; display: grid; gap: 2px; counter-reset: toc; }
.guide-toc a { display: block; padding: 5px 0; color: var(--graphite); text-decoration: none; }
.guide-toc a:hover { color: var(--ink); }
.guide-body { max-width: 68ch; }
.guide-body section { padding: 4px 0 36px; border-top: 1px solid var(--rule); scroll-margin-top: 20px; }
.guide-body section:first-child { border-top: 0; }
.guide-body h2 { font-family: var(--serif); font-weight: 500; font-size: 28px; margin: 22px 0 12px; }
.guide-body p, .guide-body li { line-height: 1.6; }
.guide-body .steps { padding-left: 22px; display: grid; gap: 8px; margin: 0 0 14px; }
.guide-body code.copy { display: inline-block; margin: 6px 10px 0 0; }
.ask { display: flex; align-items: baseline; gap: 14px; padding: 10px 14px; margin: 10px 0; background: var(--sheet); border: 1px solid var(--rule); border-radius: var(--r-s); }
.ask .prompt { margin: 0; flex: 1; }
.ask .link { font-size: 13px; flex: none; }
@media (max-width: 860px) { .guide { grid-template-columns: 1fr; gap: 8px; } .guide-toc { position: static; } .guide-toc ol { grid-template-columns: 1fr 1fr; } }
.invite-msg { display: grid; gap: 6px; margin: 14px 0 8px; font-weight: 500; font-size: 14px; }
.invite-msg textarea { min-height: 130px; font-size: 14px; }

/* ---------- colour marks ---------- */
.dot { display: inline-block; width: 9px; height: 9px; border-radius: 50%; background: var(--c, var(--graphite)); margin-right: 9px;
  vertical-align: 1px; flex: none; }
.dot.sq { border-radius: 2px; }
.dot.big { width: 14px; height: 14px; margin-right: 14px; vertical-align: .12em; }
@media (prefers-color-scheme: dark) { .dot { background: color-mix(in oklab, var(--c, var(--graphite)) 70%, white); } }
.chip { display: inline-block; font-size: 12px; line-height: 1; font-weight: 500; padding: 4px 8px; border-radius: 99px; white-space: nowrap;
  color: var(--graphite); background: var(--rule-2); vertical-align: 1px; }
.chip.ok, .chip.st-read, .chip.st-done { color: var(--sage); background: var(--sage-wash); }
.chip.now, .chip.st-reading, .chip.st-running { color: var(--blue); background: var(--blue-wash); }
.chip.bad, .chip.st-failed { color: var(--tomato); background: var(--tomato-wash); }
.chip.off, .chip.st-skipped, .chip.st-abandoned { color: var(--graphite); background: transparent; box-shadow: inset 0 0 0 1px var(--rule); }

/* ---------- small actions: add, edit, one-click changes ---------- */
.head-tools { display: flex; flex-wrap: wrap; gap: 6px 18px; align-items: center; margin: 16px 0 0; font-size: 14px; }
.head-tools a { color: var(--graphite); }
.head-tools a:hover { color: var(--ink); }
.add-row { display: flex; flex-wrap: wrap; gap: 6px 20px; margin: 14px 0 0; }
.add { display: inline-flex; align-items: center; gap: 6px; font-size: 14px; color: var(--graphite); text-decoration: none; min-height: 32px; }
.add span { display: inline-grid; place-items: center; width: 18px; height: 18px; border: 1px solid var(--rule); border-radius: 50%; line-height: 1; font-size: 13px; }
.add:hover { color: var(--ink); }
.add:hover span { border-color: var(--ink); }
h2 .add { font-weight: 400; min-height: 0; }
.h-tools { display: inline-flex; gap: 14px; align-items: baseline; }
.elink { font-size: 13px; color: var(--graphite); text-decoration-color: var(--rule); }
.elink:hover { color: var(--ink); }
form.quick { display: inline; margin: 0; }
.qbtn { background: none; border: 1px solid var(--rule); border-radius: 99px; padding: 3px 10px; min-height: 28px; font: 500 13px/1 var(--sans);
  color: var(--graphite); cursor: pointer; }
.qbtn:hover { color: var(--ink); border-color: var(--ink); }
.qbtn.strong { color: var(--sage); border-color: color-mix(in srgb, var(--sage) 50%, transparent); }
.qbtn.strong:hover { background: var(--sage-wash); }
.qicon { background: none; border: 0; padding: 2px 5px; min-height: 28px; font: 500 14px/1 var(--sans); color: var(--graphite); cursor: pointer; border-radius: 4px; }
.qicon:hover { color: var(--ink); background: var(--rule-2); }
.is-sending { opacity: .5; pointer-events: none; }
.row-tools { display: flex; flex-wrap: wrap; gap: 6px 10px; align-items: center; margin-top: 8px; }
/* tools are always there, quieter until you point at the row (milestones you can still change stay fully visible) */
@media (hover: hover) {
  .list li .row-tools, .ms.done .ms-tools, .ms.dropped .ms-tools, .req .req-tools { opacity: .35; transition: opacity .15s ease; }
  .ms .ms-tools .qicon, .ms .ms-tools .elink { opacity: .5; transition: opacity .15s ease; }
  .list li:hover .row-tools, .list li:focus-within .row-tools, .ms:hover .ms-tools, .ms:focus-within .ms-tools,
  .ms:hover .ms-tools .qicon, .ms:hover .ms-tools .elink, .ms:focus-within .qicon, .ms:focus-within .elink,
  .req:hover .req-tools, .req:focus-within .req-tools { opacity: 1; }
}
/* a round tick for "done" on deadlines */
.list li.dl { align-items: flex-start; justify-content: flex-start; }
.list li.dl .grow { flex: 1; }
.list li.dl a.title { text-decoration: none; }
.list li.dl a.title:hover { text-decoration: underline; text-decoration-color: var(--rule); }
.qcheck { flex: none; width: 20px; height: 20px; margin-top: 2px; border-radius: 50%; border: 1.5px solid var(--rule); background: none; cursor: pointer; padding: 0;
  display: grid; place-items: center; position: relative; }
.qcheck:hover { border-color: var(--sage); }
.qcheck:hover::after, .qcheck.on::after { content: ""; width: 8px; height: 4px; border: solid var(--sage); border-width: 0 0 2px 2px; transform: translateY(-1px) rotate(-45deg); }
.qcheck.on { background: var(--sage); border-color: var(--sage); }
.qcheck.on::after { border-color: var(--paper); }
.dl.is-done .title { color: var(--graphite); text-decoration: line-through; text-decoration-color: var(--rule); }
.list.compact li { padding: 9px 0; }
.log-side { display: flex; flex-direction: column; align-items: flex-end; gap: 6px; flex: none; }

/* ---------- study: view switch, tree, terms ---------- */
.views-h { flex-wrap: wrap; }
.subtabs.seg { border: 1px solid var(--rule); border-radius: 99px; padding: 2px; gap: 0; margin: 0; flex-wrap: nowrap; }
.subtabs.seg a { padding: 4px 12px; font-size: 13px; border: 0; margin: 0; border-radius: 99px; }
.subtabs.seg a[aria-current=page] { background: var(--ink); color: var(--paper); }
.group-h { font-size: 14px; color: var(--graphite); font-weight: 500; margin: 26px 0 2px; }
.req { grid-template-columns: minmax(0, 1fr) auto 84px; }
.req .req-num { grid-column: 3; grid-row: 1; }
.req-tools { grid-column: 2; grid-row: 1; display: flex; align-items: center; gap: 2px; }
.req-courses .dot { margin-right: 5px; width: 7px; height: 7px; }

.tree { list-style: none; margin: 4px 0 0; padding: 0; }
.tree ul { list-style: none; margin: 0; padding: 0 0 0 22px; }
.tree li { position: relative; }
.tree ul > li::before { content: ""; position: absolute; left: -14px; top: 0; bottom: 0; border-left: 1px solid var(--rule); }
.tree ul > li:last-child::before { bottom: auto; height: 21px; }
.tree ul > li::after { content: ""; position: absolute; left: -14px; top: 21px; width: 10px; border-top: 1px solid var(--rule); }
.t-row { display: flex; align-items: center; gap: 10px; min-height: 42px; padding: 4px 0; }
.t-row a { text-decoration: none; font-weight: 500; }
.t-row a:hover { text-decoration: underline; text-decoration-color: var(--rule); }
.t-row .dot { margin-right: 0; }
.t-meta { margin-left: auto; display: flex; align-items: center; gap: 10px; flex: none; }
.t-cr { font-size: 13px; color: var(--graphite); font-variant-numeric: tabular-nums; white-space: nowrap; }
.t-root > .t-row { font-family: var(--serif); font-size: 19px; border-bottom: 1px solid var(--rule-2); }
.t-branch > details > summary.t-row { font-size: 15px; font-weight: 600; min-height: 44px; }
.t-branch > details > summary::before { content: ""; width: 7px; height: 7px; border: solid var(--graphite); border-width: 0 1.5px 1.5px 0;
  transform: rotate(-45deg); transition: transform .15s ease; margin-right: 2px; flex: none; }
.t-branch > details[open] > summary::before { transform: rotate(45deg); }
.t-name { overflow-wrap: anywhere; }
.bar.thin { width: 72px; height: 4px; flex: none; }

.t-leaf .t-row { font-size: 15px; min-height: 38px; }
.t-leaf.is-dropped a, .t-leaf.is-failed a { color: var(--graphite); }
.t-leaf.is-dropped a { text-decoration: line-through; }
.t-project .t-row { font-size: 14px; }
.t-empty { color: var(--graphite); font-size: 14px; padding: 8px 0; }
@media (max-width: 600px) { .bar.thin { display: none; } .tree ul { padding-left: 16px; } }

.steps { display: inline-flex; gap: 3px; flex-wrap: wrap; }
.steps i { width: 10px; height: 6px; border-radius: 2px; background: var(--rule-2); box-shadow: inset 0 0 0 1px var(--rule); }
.steps i.on { background: var(--sage); box-shadow: none; }

.term { padding: 16px 0 6px; border-bottom: 1px solid var(--rule-2); }
.term:last-of-type { border-bottom: 0; }
.term-head { display: flex; align-items: baseline; gap: 14px; flex-wrap: wrap; }
.term-head h3 { font-family: var(--serif); font-size: 21px; font-weight: 500; }
.term-head .elink { margin-left: auto; }
.term-sum { margin: 2px 0 4px; }
.term.is-now { border-left: 2px solid var(--blue); padding-left: 16px; margin-left: -18px; }
.term .list li { align-items: center; }
.term .cr { min-width: 48px; text-align: right; }

/* ---------- course: topics you can open to record practice ---------- */
.mastery { align-items: start; }
details.topic { padding: 0; border-bottom: 1px solid var(--rule-2); }
details.topic > summary { display: block; padding: 12px 0; min-height: 0; font-weight: 400; font-size: 15px; }
details.topic > summary:hover .topic-name { text-decoration: underline; text-decoration-color: var(--rule); text-underline-offset: 3px; }
details.topic[open] { background: var(--sheet); box-shadow: 0 0 0 1px var(--rule); border-radius: var(--r-s); border-bottom-color: transparent;
  padding: 0 12px 12px; margin: 6px -12px; grid-column: 1 / -1; }
.topic-name { display: block; }
.topic-meter { display: block; margin-top: 8px; }
.topic-act { display: grid; gap: 10px; }
.topic-act .meta { margin: 0; }
.mpick { display: flex; flex-wrap: wrap; gap: 6px; }
.mbtn { border: 1px solid var(--rule); background: var(--paper); border-radius: 99px; padding: 6px 12px; min-height: 36px; font: 500 14px/1 var(--sans);
  color: var(--ink); cursor: pointer; }
.mbtn:hover { border-color: var(--ink); }
.mbtn[aria-pressed=true] { color: var(--paper); border-color: transparent; background: var(--graphite); }
.mbtn.m1[aria-pressed=true] { background: var(--ochre); } .mbtn.m2[aria-pressed=true] { background: var(--blue); } .mbtn.m3[aria-pressed=true] { background: var(--sage); }
@media (prefers-color-scheme: dark) { .mbtn[aria-pressed=true] { color: #12161c; } }
.input.slim { min-height: 38px; padding: 7px 10px; font-size: 14px; }
.weak .prose { margin-top: 4px; }
.topic-links { display: flex; gap: 16px; font-size: 13px; margin: 0; }
.topic-links a { color: var(--graphite); }
.legend-tip { margin-left: auto; }
.with-dot { display: flex; }

/* ---------- project roadmap and lists ---------- */
.roadmap li.ms { display: flex; justify-content: space-between; gap: 16px; align-items: flex-start; }
.ms-main { flex: 1; }
.ms-main .title { font-weight: 500; }
.ms-tools { margin-top: 0; flex: none; justify-content: flex-end; max-width: 50%; }
.roadmap li.done .title { color: var(--graphite); }
.roadmap li.in_progress .line { color: var(--blue); }
.roadmap li.ms.dropped { text-decoration: none; }
.roadmap li.ms.dropped .ms-main { text-decoration: line-through; color: var(--graphite); }
@media (max-width: 600px) { .roadmap li.ms { flex-direction: column; gap: 4px; } .ms-tools { max-width: none; opacity: 1 !important; } }
.list li.paper, .list li.exp { align-items: flex-start; }
.list li.paper .chip, .list li.exp .chip { margin-top: 3px; }

/* ---------- the record form ---------- */
.record-form { max-width: 760px; }
.fields { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 16px 14px; }
.fields > * { grid-column: span 6; }
.fields > .s2 { grid-column: span 2; } .fields > .s3 { grid-column: span 3; } .fields > .s4 { grid-column: span 4; }
.fields > .check { align-self: end; min-height: 44px; }
.fields .help { font-size: 13px; font-weight: 400; color: var(--graphite); }
@media (max-width: 640px) { .fields > .s2 { grid-column: span 3; } .fields > .s3, .fields > .s4 { grid-column: span 6; } }
.swatches { border: 0; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.swatches legend { font-weight: 500; font-size: 14px; margin-bottom: 8px; padding: 0; }
.swatch { position: relative; display: inline-flex; align-items: center; gap: 8px; cursor: pointer; font-weight: 400; }
.swatch input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.sw { width: 28px; height: 28px; border-radius: 50%; background: var(--c, var(--rule-2)); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--ink) 12%, transparent); }
.sw.auto { background: conic-gradient(from 90deg, var(--c, var(--graphite)) 0 50%, transparent 0) , var(--rule-2); }
.swatch input:checked + .sw { box-shadow: 0 0 0 2px var(--paper), 0 0 0 4px var(--ink); }
.swatch input:focus-visible + .sw { outline: 2px solid var(--ink); outline-offset: 4px; }
.sw-name { font-size: 14px; color: var(--graphite); }

/* ---------- header: start a focus session from anywhere ---------- */
.qpill { display: inline-flex; align-items: center; gap: 8px; padding: 5px 12px; border: 1px solid var(--rule); border-radius: 99px;
  font-size: 14px; color: var(--graphite); text-decoration: none; white-space: nowrap; flex: none; }
.qpill:hover { color: var(--ink); border-color: var(--tomato); }
.qpill-dot { width: 0; height: 0; border-style: solid; border-width: 5px 0 5px 8px; border-color: transparent transparent transparent var(--tomato); }
.qpill[hidden] { display: none; }
@media (max-width: 720px) { .qpill { order: 4; } }

/* ---------- toasts and live updates ---------- */
.toast { position: fixed; left: 50%; bottom: 24px; transform: translate(-50%, 12px); opacity: 0; z-index: 50; max-width: min(460px, 92vw);
  background: var(--ink); color: var(--paper); padding: 10px 16px; border-radius: var(--r-s); font-size: 14px;
  transition: opacity .2s ease, transform .2s ease; pointer-events: none; display: flex; gap: 16px; align-items: center; }
.toast.show.has-action { pointer-events: auto; }
.toast button { background: none; border: 0; color: inherit; font: 600 14px/1 var(--sans); padding: 4px 0; cursor: pointer;
  text-decoration: underline; text-underline-offset: 3px; }
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.toast[data-kind=error] { background: var(--tomato); color: #fff; }
.live-flash { animation: liveflash 1.6s ease-out; }
@keyframes liveflash { 0% { background-color: color-mix(in srgb, var(--blue) 16%, transparent); } 100% { background-color: transparent; } }
.head-tools .elink { font-size: 14px; }
.fields > label { align-content: start; }
.form .swatch { display: inline-flex; grid-template-columns: none; gap: 8px; }
.with-dot { align-items: center; }
.line .dot, .ctx-line .dot { width: 7px; height: 7px; margin-right: 6px; vertical-align: 1px; }
.plan-row .title .dot { width: 8px; height: 8px; margin-right: 8px; }
.start-steps li.done .start-mark { background: var(--sage); border-color: var(--sage); }

/* ---------- search ---------- */
.search-form { max-width: 720px; margin-bottom: 6px; }
kbd { font: 500 12px/1 ui-monospace, "SF Mono", Menlo, monospace; border: 1px solid var(--rule); border-bottom-width: 2px; border-radius: 4px; padding: 2px 5px; }
.search-results { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 32px 48px; margin-top: 28px; }
.search-results .card + .card { margin-top: 0; }
.search-results .list li { align-items: baseline; }
@media (max-width: 480px) { .tabs a { padding: 6px 7px; font-size: 14.5px; } .nav { gap: 14px; } }

/* ======================= landing page ======================= */
.page-landing .wrap { max-width: 1080px; }
.signin-link, .nav [href] { white-space: nowrap; }
.btn-big { padding: 11px 22px; font-size: 16px; }
.lp-hero { text-align: center; padding: 3rem 0 1rem; }
.lp-hero h1 { font-family: var(--serif); font-weight: 500; font-size: clamp(2.4rem, 6vw, 4rem); line-height: 1.04;
  letter-spacing: -0.015em; margin: 0 0 1.2rem; }
.lp-lead { max-width: 40rem; margin: 0 auto 1.8rem; font-size: clamp(1.05rem, 2.2vw, 1.3rem); line-height: 1.5; color: var(--graphite); }
.lp-cta { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }
.lp-note { margin: 1.1rem auto 0; max-width: 34rem; font-size: 14px; color: var(--graphite); }
.lp-fine { margin-top: 1rem; font-size: 13px; color: var(--graphite); }

.shot { border: 1px solid var(--rule); border-radius: var(--r); overflow: hidden; background: var(--sheet);
  box-shadow: 0 1px 2px rgba(20,25,35,.04), 0 18px 50px -24px rgba(20,25,35,.28); }
.shot img { display: block; width: 100%; height: auto; }
.shot-hero { max-width: 940px; margin: 3rem auto 0; }

.lp-row { display: grid; grid-template-columns: 1fr 1.25fr; gap: 3rem; align-items: center; margin: 6rem 0; }
.lp-row.reverse .lp-text { order: 2; }
.lp-text h2 { font-family: var(--serif); font-weight: 500; font-size: clamp(1.6rem, 3.4vw, 2.2rem); line-height: 1.12; margin: 0 0 .8rem; }
.lp-text p { font-size: 1.08rem; line-height: 1.6; color: var(--graphite); margin: 0; max-width: 32rem; }

.lp-steps { margin: 6rem 0; text-align: center; }
.lp-steps h2 { font-family: var(--serif); font-weight: 500; font-size: clamp(1.6rem, 3.4vw, 2.2rem); margin: 0 0 2.4rem; }
.lp-steps ol { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 2rem; text-align: left; }
.lp-steps li { display: grid; gap: .5rem; }
.lp-n { display: inline-grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; border: 1px solid var(--rule);
  font-family: var(--serif); font-size: 1.1rem; color: var(--tomato); }
.lp-steps b { font-size: 1.1rem; }
.lp-steps li span:last-child { color: var(--graphite); line-height: 1.55; }

.lp-end { text-align: center; margin: 6rem 0 4rem; padding: 3.5rem 1rem; background: var(--sheet); border: 1px solid var(--rule-2); border-radius: var(--r); }
.lp-end h2 { font-family: var(--serif); font-weight: 500; font-size: clamp(1.7rem, 3.6vw, 2.4rem); margin: 0 0 1.6rem; }

@media (max-width: 760px) {
  .lp-row { grid-template-columns: 1fr; gap: 1.4rem; margin: 4rem 0; }
  .lp-row.reverse .lp-text { order: 0; }
  .lp-steps ol { grid-template-columns: 1fr; gap: 1.6rem; }
  .shot-hero { margin-top: 2rem; }
}

/* ---------- guide: plugin + skills ---------- */
.guide-body h3 { font-size: 1.05rem; font-weight: 600; margin: 1.6rem 0 .4rem; }
.pill { display: inline-block; vertical-align: 2px; margin-left: 8px; font-size: 11px; font-weight: 600; letter-spacing: .02em;
  text-transform: uppercase; color: var(--sage); background: var(--sage-wash); padding: 3px 8px; border-radius: 99px; }
.skills { display: grid; gap: 1.4rem; margin-top: 1rem; }
.skill { padding-left: 1rem; border-left: 2px solid var(--rule); }
.skill h3 { margin: 0 0 .2rem; }
.skill > p { margin: 0 0 .5rem; color: var(--graphite); }
.skill .ask { margin: 0; }

/* landing: what Claude can do */
.lp-skills { margin: 6rem 0; text-align: center; }
.lp-skills h2 { font-family: var(--serif); font-weight: 500; font-size: clamp(1.6rem, 3.4vw, 2.2rem); margin: 0 0 .5rem; }
.lp-skills-sub { color: var(--graphite); margin: 0 auto 2.4rem; max-width: 34rem; }
.lp-skill-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 1.6rem 2rem; text-align: left; }
.lp-skill { padding-left: 1rem; border-left: 2px solid var(--rule); }
.lp-skill h3 { font-size: 1.05rem; margin: 0 0 .3rem; }
.lp-skill p { margin: 0; color: var(--graphite); line-height: 1.55; font-size: .98rem; }
.lp-skills-link { margin: 2.6rem 0 0; text-align: center; }
.lp-skills-hint { display: block; margin-top: .9rem; color: var(--graphite); font-size: .88rem; }
.lp-skills-hint code { background: var(--paper); border: 1px solid var(--rule); border-radius: var(--r-s); padding: .1rem .4rem; }
