/* Design language of the new qigongacademy.org (theme qigong-academy-still):
   Outfit light for headings and labels, Lato for text, olive palette, pill buttons,
   wide-tracked eyebrows. Loaded after each page's own styles, so these tokens win.
   Fonts are served from this server: no request leaves for a font host. */
@font-face { font-family: "Lato"; font-weight: 400; font-style: normal; font-display: swap; src: url("/fonts/lato-400-latin.woff2") format("woff2"); }
@font-face { font-family: "Lato"; font-weight: 700; font-style: normal; font-display: swap; src: url("/fonts/lato-700-latin.woff2") format("woff2"); }
@font-face { font-family: "Outfit"; font-weight: 100 900; font-style: normal; font-display: swap; src: url("/fonts/outfit-var-latin.woff2") format("woff2"); }

:root {
  color-scheme: light;
  --sage: #5c6b3d;          /* primary-alt-accent: buttons, links, accents */
  --sage-soft: #dce1d3;     /* primary-alt */
  --ink: #1a202c;           /* main: headings */
  --text: #2d3748;          /* body */
  --muted: #5b6552;         /* secondary */
  --surface: #f1f3ee;       /* primary-accent: quiet panels */
  --card: #ffffff;          /* base */
  --page: #fbfaf7;          /* tertiary: page */
  --rule: #e4e6de;          /* border-light */
  --good: #4a5730; --good-bg: #e6ebdc;
  --warn: #7a5c12; --warn-bg: #f4ecd6;
  --bad: #9a3f2b;  --bad-bg: #f5e3dd;
  --weak: #9a3f2b; --weak-bg: #f5e3dd;
  --font-display: "Outfit", "Century Gothic", "Avenir Next", sans-serif;
  --font-body: "Lato", "Helvetica Neue", Helvetica, Arial, sans-serif;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    color-scheme: dark;
    --sage: #b4c290; --sage-soft: #2f3826; --ink: #f1f3ee; --text: #d9ddd2; --muted: #a9b29c;
    --surface: #222a1c; --card: #1c2318; --page: #151a12; --rule: #343d2c;
    --good: #b4c290; --good-bg: #2b3622; --warn: #e0c47a; --warn-bg: #3a321b; --bad: #eea592; --bad-bg: #3d2621;
    --weak: #eea592; --weak-bg: #3d2621;
  }
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --sage: #b4c290; --sage-soft: #2f3826; --ink: #f1f3ee; --text: #d9ddd2; --muted: #a9b29c;
  --surface: #222a1c; --card: #1c2318; --page: #151a12; --rule: #343d2c;
  --good: #b4c290; --good-bg: #2b3622; --warn: #e0c47a; --warn-bg: #3a321b; --bad: #eea592; --bad-bg: #3d2621;
  --weak: #eea592; --weak-bg: #3d2621;
}

body { background: var(--page); color: var(--text); font-family: var(--font-body); line-height: 1.62; }
h1, h2, h3, .part__title { font-family: var(--font-display); font-weight: 300; letter-spacing: -0.02em; line-height: 1.25; color: var(--ink); }
h3 { font-weight: 400; letter-spacing: -0.01em; }
h1 { font-size: clamp(2.125rem, 1.16rem + 4.05vw, 3.25rem); }
h2 { font-size: clamp(1.375rem, 1.16rem + 0.9vw, 1.75rem); }
.big { font-family: var(--font-display); font-weight: 300; letter-spacing: -0.02em; }
.eyebrow, .part__no, .prio__rank, th, .label, .mini {
  font-family: var(--font-display) !important; /* the pages set these with a shorthand font; the brand face must win */
  font-weight: 500; letter-spacing: 0.2em; text-transform: uppercase; font-size: 0.75rem;
}
.eyebrow, .part__no { color: var(--sage); }
a { color: var(--sage); }
a:hover { color: var(--ink); }

/* Buttons: pills, as on the website */
.btn, button.chip, .todo__who, .owner, .pill, .tag {
  border-radius: 999px;
}
.btn { font-family: var(--font-display); font-weight: 400; min-height: 40px; padding: 8px 18px; border: 1px solid var(--rule); background: var(--card); color: var(--ink); transition: background-color .18s ease, color .18s ease, border-color .18s ease; }
.btn:hover { border-color: var(--sage); }
.btn--primary, #signin { background: var(--sage); border-color: var(--sage); color: #fff; font-family: var(--font-display); font-weight: 400; border-radius: 999px; min-height: 48px; padding: 10px 24px; }
.btn--primary:hover, #signin:hover { background: var(--ink); border-color: var(--ink); color: #fff; }
.btn--icon { min-height: 0; width: 36px; height: 36px; padding: 0; }
.pill { font-family: var(--font-display); font-weight: 500; letter-spacing: 0.02em; }

/* Surfaces: white cards on the warm page, hairline borders, 15px radius */
.tile, .panel, .box, .summary, .toc, .prio__item, .col, .task, .channel, .month-form {
  border-radius: 15px;
}
.tile, .panel, .box { background: var(--card); border: 1px solid var(--rule); box-shadow: none; }
.summary, .toc, .prio__item, .col { background: var(--surface); }
.bar { background: var(--sage-soft); }
.bar__fill { background: var(--sage); }
input, select { border-radius: 8px; border-color: var(--rule); }
:focus-visible { outline: 2px solid var(--sage); outline-offset: 2px; }

/* Command centre bar */
.cc-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 22px; padding: 14px 20px; background: var(--card); border-bottom: 1px solid var(--rule); position: relative; z-index: 20; font-family: var(--font-display); }
.cc-brand { display: flex; align-items: center; gap: 10px; margin-right: auto; color: var(--ink); text-decoration: none; }
.cc-brand img { width: 22px; height: 25px; }
.cc-brand span { font-weight: 400; font-size: 1.05rem; letter-spacing: -0.01em; }
.cc-brand small { display: block; font-size: 0.68rem; letter-spacing: 0.2em; text-transform: uppercase; color: var(--muted); }
.cc-link { color: var(--ink); text-decoration: none; font-size: 0.95rem; padding: 4px 0; border-bottom: 2px solid transparent; }
.cc-link[aria-current="page"] { border-bottom-color: var(--sage); }
.cc-link:hover { color: var(--sage); }
.cc-out { color: var(--muted); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .cc-brand img { filter: invert(1); } }
:root[data-theme="dark"] .cc-brand img { filter: invert(1); }
