/* ============================================================================
   POLISH v2 — the ledger layer (appended after board.css; later cascade wins).
   Identity: a 1915 contractor's ledger, modernized. Slab display with real
   drama, ruled section heads, inked stamps for status, elevation + motion.
   ========================================================================== */

:root {
  --fs-6: 34px; --fs-7: 44px;
  --e1: 0 1px 2px rgba(16,24,36,.06), 0 1px 6px rgba(16,24,36,.05);
  --e2: 0 2px 6px rgba(16,24,36,.08), 0 8px 24px rgba(16,24,36,.08);
  --e3: 0 12px 40px rgba(16,24,36,.16);
  --tr: 160ms cubic-bezier(.3,.7,.4,1);
}
:root[data-theme="dark"], :root[data-theme="dark"] * { --e1: 0 1px 3px rgba(0,0,0,.5); --e2: 0 4px 14px rgba(0,0,0,.5); --e3: 0 16px 48px rgba(0,0,0,.6); }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) { --e1: 0 1px 3px rgba(0,0,0,.5); --e2: 0 4px 14px rgba(0,0,0,.5); --e3: 0 16px 48px rgba(0,0,0,.6); }
}

/* ---- surface + depth ---- */
.card {
  box-shadow: var(--e1);
  border-color: var(--line);
  transition: box-shadow var(--tr), transform var(--tr), border-color var(--tr);
}
.card:hover { box-shadow: var(--e2); }
a.vaultcard:hover, .dragcard:hover { transform: translateY(-2px); box-shadow: var(--e2); border-color: var(--gold-ink); }

/* ---- display type with drama ---- */
h1.page {
  font-family: var(--font-display);
  font-size: var(--fs-6);
  letter-spacing: -.01em;
  line-height: 1.08;
  text-wrap: balance;
}
main > .dossier-hd h1.page, .dossier-hd h1.page { font-size: var(--fs-6); }

/* ledger-rule section heads: heavy top rule + slab, like a logbook divider */
h2.sect {
  font-family: var(--font-display);
  font-size: var(--fs-4);
  border-top: 3px double var(--rule);
  border-bottom: 0;
  padding-top: 10px;
  margin-top: var(--gap-4);
  letter-spacing: .01em;
}
.card h3 {
  font-family: var(--font-display);
  letter-spacing: .01em;
}

/* ---- the stamp system: status as ink, readable at arm's length ---- */
.stamp {
  display: inline-block;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 11px;
  letter-spacing: .14em;
  text-transform: uppercase;
  padding: 2px 9px;
  border: 2px solid currentColor;
  border-radius: 3px;
  transform: rotate(-1.6deg);
  opacity: .92;
  line-height: 1.5;
}
.stamp.ok    { color: var(--ok);   background: var(--ok-soft); }
.stamp.warn  { color: var(--warn); background: var(--warn-soft); }
.stamp.bad   { color: var(--bad);  background: var(--bad-soft); }
.stamp.ghost { color: var(--faint); background: transparent; border-style: dashed; }
.stamp.gold  { color: var(--gold-ink); background: var(--gold-soft); }

/* ---- KPI strip: the numbers that run the morning ---- */
.kpis {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: var(--gap-2);
  margin-bottom: var(--gap-3);
}
.kpi {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 14px 16px 10px;
  box-shadow: var(--e1);
  border-top: 3px solid var(--gold);
}
.kpi b {
  display: block;
  font-family: var(--font-display);
  font-size: var(--fs-7);
  line-height: 1;
  font-variant-numeric: tabular-nums;
  letter-spacing: -.02em;
}
.kpi span { color: var(--mut); font-size: var(--fs-0); letter-spacing: .06em; text-transform: uppercase; }
.kpi.hot   { border-top-color: var(--bad); }  .kpi.hot b   { color: var(--bad); }
.kpi.warm  { border-top-color: var(--warn); } .kpi.warm b  { color: var(--warn); }
.kpi.calm  { border-top-color: var(--ok); }   .kpi.calm b  { color: var(--ok); }

/* ---- chase-list heat: age you can see across the room ---- */
ul.chase li { border-left: 3px solid var(--line); padding-left: 10px; transition: background var(--tr); border-radius: 0 var(--radius) var(--radius) 0; }
ul.chase li:hover { background: var(--panel2); }
ul.chase li:has(.age.hot)  { border-left-color: var(--bad); }
ul.chase li:has(.age:not(.hot):not(.cool)) { border-left-color: var(--warn); }
.age { font-family: var(--font-data); font-variant-numeric: tabular-nums; }
.age.hot { color: var(--bad); font-weight: 700; }

/* ---- designed rows instead of spreadsheet walls ---- */
table { border-collapse: collapse; }
th { font-size: var(--fs-0); letter-spacing: .09em; text-transform: uppercase; color: var(--mut); font-weight: 600; border-bottom: 2px solid var(--rule); padding: 6px 12px 6px 0; }
td { border-bottom: 1px solid var(--line); padding: 9px 12px 9px 0; }
tbody tr, table tr { transition: background var(--tr); }
table tr:hover td { background: var(--panel2); }
td .src { font-variant-numeric: tabular-nums; }

/* ---- buttons that feel pressable ---- */
button, .btn {
  font-family: var(--font-display);
  letter-spacing: .04em;
  border-radius: var(--radius);
  border: 1px solid var(--gold);
  background: var(--gold);
  /* wave89: was #fff = 2.24 on gold. board.css already sets #14100a for the same
     selector; this rule loads later and was overriding it with the unreadable one. */
  color: #14100a;
  padding: 7px 16px;
  cursor: pointer;
  transition: transform var(--tr), box-shadow var(--tr), filter var(--tr);
  box-shadow: var(--e1);
}
button:hover, .btn:hover { filter: brightness(1.06); box-shadow: var(--e2); }
button:active, .btn:active { transform: translateY(1px); box-shadow: none; }
.btn.quiet, button.quiet { background: transparent; color: var(--gold-ink); }

/* ---- nav: gold ink-bar for the active tab ---- */
.nav a { position: relative; padding-bottom: 4px; transition: color var(--tr); }
.nav a.on::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: -2px;
  height: 3px; background: var(--gold); border-radius: 2px;
}
.pchip { transition: transform var(--tr), box-shadow var(--tr); }
.pchip:hover { transform: translateY(-1px); }
.pchip.on { box-shadow: var(--e1); }

/* ---- skeleton shimmer for the async deep record ---- */
@keyframes skel { 0% { background-position: -300px 0 } 100% { background-position: 300px 0 } }
.skel {
  border-radius: var(--radius);
  background: linear-gradient(90deg, var(--panel2) 25%, var(--panel) 50%, var(--panel2) 75%);
  background-size: 600px 100%;
  animation: skel 1.3s infinite linear;
  min-height: 14px;
}
.skel-block { height: 90px; margin: 10px 0; }
.skel-line { height: 14px; margin: 8px 0; }
.skel-line.w60 { width: 60%; } .skel-line.w80 { width: 80%; }

/* ---- calendar grid: quieter chrome, louder content ---- */
.calgrid th { border-bottom: 2px solid var(--rule); }
.calgrid td { transition: background var(--tr); }
.calgrid td.dropday:hover { background: var(--panel2); }
.ev { transition: transform var(--tr); }
.ev:hover { transform: translateX(2px); }

/* ---- peeks + omni get pop elevation ---- */
.omni-out, #gcard, .peek-card, [id^="peek"] { box-shadow: var(--e3) !important; border-radius: var(--radius-lg); }

/* ---- page enter: one quiet breath, not a slideshow ---- */
@keyframes rise { from { opacity: 0; transform: translateY(4px) } to { opacity: 1; transform: none } }
main { animation: rise 220ms cubic-bezier(.2,.7,.3,1); }


/* ---- People / Organizations directory (2026-08-12) ---------------------------
   A directory is scanned, not read: fixed-width cards in a dense grid, name first
   at reading weight, affiliation quiet underneath. */
.dirgrid { display: grid; gap: 8px; margin: 10px 0 var(--gap-2);
  grid-template-columns: repeat(auto-fill, minmax(215px, 1fr)); }
.dircard { display: block; padding: 9px 11px; border: 1px solid var(--line);
  border-radius: 7px; background: var(--card); text-decoration: none;
  box-shadow: var(--e1); transition: border-color .12s, transform .12s, box-shadow .12s; }
.dircard:hover { border-color: var(--gold-ink); transform: translateY(-1px); box-shadow: var(--e2); }
.dircard b { display: block; color: var(--ink); font-weight: 600; font-size: 14px;
  line-height: 1.25; overflow-wrap: break-word; }
.dircard .src { display: block; margin-top: 3px; font-size: 11.5px; }
.dircard.warnish { border-style: dashed; }
.dircard.warnish b { color: var(--ink-2, var(--ink)); }


/* ---- Graph v3 layer bar ------------------------------------------------------
   Each layer is a legend entry AND its switch: the swatch tells you what the colour
   means, the count tells you how much of it is on the canvas, clicking removes it. */
.glayers { display: flex; flex-wrap: wrap; gap: 6px; align-items: center;
  margin: 0 0 10px; }
.glayer { display: inline-flex; align-items: center; gap: 6px; cursor: pointer;
  padding: 4px 10px; border: 1px solid var(--line); border-radius: 999px;
  background: var(--card); color: var(--ink); font: inherit; font-size: 12.5px; }
.glayer i { width: 9px; height: 9px; border-radius: 50%; background: var(--faint);
  display: inline-block; }
.glayer b { font-variant-numeric: tabular-nums; opacity: .65; font-weight: 600; }
.glayer:hover { border-color: var(--gold-ink); }
.glayer.off { opacity: .38; text-decoration: line-through; }
.glayer.l-project i { background: var(--gold); }
.glayer.l-person  i { background: var(--chip-parks, #4a7fc8); }
.glayer.l-org     i { background: var(--ok, #3f9e63); }
.glayer.l-place   i { background: var(--warn, #c8873f); }
.glayer.l-doc     i { background: var(--faint, #8a8f98); }
.glayer.l-event   i { background: #a05fc8; }
.glayer.l-claim   i { background: #c85f8a; }
.glayer.l-day     i { background: #5fb0c8; }
.glayer.l-loop    i { background: #c8a24a; }


/* ---- Whole-corpus shell: canvas + inspector sidebar (the graphify pattern) -------
   Sidebar is fixed at 300px so the canvas can be measured exactly (it draws at
   width - 300); the panel is a column that gives its scroll to the legend. */
.corpus-shell { display: grid; grid-template-columns: 1fr 300px; gap: 10px;
  align-items: start; }
.corpus-side { display: flex; flex-direction: column; gap: 0;
  border: 1px solid var(--line); border-radius: var(--rad); background: var(--card);
  height: 662px; overflow: hidden; box-shadow: var(--e1); }
.cs-block { padding: 10px 12px; border-bottom: 1px solid var(--line); }
.cs-grow { flex: 1; display: flex; flex-direction: column; min-height: 0; }
.cs-head { display: flex; align-items: center; gap: 8px; }
.cs-mode { font-size: 11.5px; padding: 2px 6px; margin-left: auto; max-width: 158px; }
.cs-all { display: flex; align-items: center; gap: 6px; margin: 6px 0 4px;
  color: var(--faint); }
.cs-foot { padding: 8px 12px; border-top: 1px solid var(--line);
  font-variant-numeric: tabular-nums; }
.csub { font-size: 11.5px; text-transform: uppercase; letter-spacing: .06em;
  color: var(--faint); margin: 0 0 6px; font-weight: 700; }
.cempty { color: var(--faint); font-style: italic; font-size: 12.5px; }
.cfield { font-size: 12.5px; line-height: 1.55; color: var(--faint); }
.cfield b { color: var(--ink); font-weight: 600; }

#legend { overflow-y: auto; flex: 1; min-height: 0; margin: 0 -4px; padding: 0 4px; }
.citem { display: flex; align-items: center; gap: 8px; padding: 3px 4px;
  border-radius: 4px; cursor: pointer; font-size: 12.5px; }
.citem:hover { background: var(--panel); }
.citem.dimmed { opacity: .35; }
.cdot { width: 11px; height: 11px; border-radius: 50%; flex: 0 0 auto; }
.clabel { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  color: var(--ink); }
.ccount { color: var(--faint); font-size: 11px; font-variant-numeric: tabular-nums; }

#search-results { max-height: 190px; overflow-y: auto; margin-top: 6px; }
.sitem { padding: 3px 7px; margin: 2px 0; border-left: 3px solid var(--line);
  border-radius: 3px; cursor: pointer; font-size: 12.5px; overflow: hidden;
  text-overflow: ellipsis; white-space: nowrap; }
.sitem:hover { background: var(--panel); }

#neighbors { max-height: 190px; overflow-y: auto; margin-top: 4px; }
.nlink { display: block; padding: 2px 7px; margin: 2px 0; border-left: 3px solid var(--line);
  border-radius: 3px; cursor: pointer; font-size: 12px; overflow: hidden;
  text-overflow: ellipsis; white-space: nowrap; color: var(--ink); }
.nlink:hover { background: var(--panel); }

@media (max-width: 900px) {
  .corpus-shell { grid-template-columns: 1fr; }
  .corpus-side { height: auto; max-height: 520px; }
}


/* ---- Whole-corpus shell: canvas + inspector sidebar (the graphify pattern) -------
   Sidebar is fixed at 300px so the canvas can be measured exactly (it draws at
   width - 300); the panel is a column that gives its scroll to the legend. */
.corpus-shell { display: grid; grid-template-columns: 1fr 300px; gap: 10px;
  align-items: start; }
.corpus-side { display: flex; flex-direction: column; gap: 0;
  border: 1px solid var(--line); border-radius: var(--rad); background: var(--card);
  height: 662px; overflow: hidden; box-shadow: var(--e1); }
.cs-block { padding: 10px 12px; border-bottom: 1px solid var(--line); }
.cs-grow { flex: 1; display: flex; flex-direction: column; min-height: 0; }
.cs-head { display: flex; align-items: center; gap: 8px; }
.cs-mode { font-size: 11.5px; padding: 2px 6px; margin-left: auto; max-width: 158px; }
.cs-all { display: flex; align-items: center; gap: 6px; margin: 6px 0 4px;
  color: var(--faint); }
.cs-foot { padding: 8px 12px; border-top: 1px solid var(--line);
  font-variant-numeric: tabular-nums; }
.csub { font-size: 11.5px; text-transform: uppercase; letter-spacing: .06em;
  color: var(--faint); margin: 0 0 6px; font-weight: 700; }
.cempty { color: var(--faint); font-style: italic; font-size: 12.5px; }
.cfield { font-size: 12.5px; line-height: 1.55; color: var(--faint); }
.cfield b { color: var(--ink); font-weight: 600; }

#legend { overflow-y: auto; flex: 1; min-height: 0; margin: 0 -4px; padding: 0 4px; }
.citem { display: flex; align-items: center; gap: 8px; padding: 3px 4px;
  border-radius: 4px; cursor: pointer; font-size: 12.5px; }
.citem:hover { background: var(--panel); }
.citem.dimmed { opacity: .35; }
.cdot { width: 11px; height: 11px; border-radius: 50%; flex: 0 0 auto; }
.clabel { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  color: var(--ink); }
.ccount { color: var(--faint); font-size: 11px; font-variant-numeric: tabular-nums; }

#search-results { max-height: 190px; overflow-y: auto; margin-top: 6px; }
.sitem { padding: 3px 7px; margin: 2px 0; border-left: 3px solid var(--line);
  border-radius: 3px; cursor: pointer; font-size: 12.5px; overflow: hidden;
  text-overflow: ellipsis; white-space: nowrap; }
.sitem:hover { background: var(--panel); }

#neighbors { max-height: 190px; overflow-y: auto; margin-top: 4px; }
.nlink { display: block; padding: 2px 7px; margin: 2px 0; border-left: 3px solid var(--line);
  border-radius: 3px; cursor: pointer; font-size: 12px; overflow: hidden;
  text-overflow: ellipsis; white-space: nowrap; color: var(--ink); }
.nlink:hover { background: var(--panel); }

@media (max-width: 900px) {
  .corpus-shell { grid-template-columns: 1fr; }
  .corpus-side { height: auto; max-height: 520px; }
}


/* ---- corpus-fullbleed: a map is surveyed, not read ---------------------------
   board.css caps main at 1280px for readable prose. That is right for every other
   page and wrong for this one: it left a 29,743-node graph 630px wide on a 1680px
   screen. Escape the measure and take the whole viewport. */
body:has(#corpuswrap) main { max-width: none; padding-left: 14px; padding-right: 14px; }
.corpus-shell { grid-template-columns: 1fr 320px; gap: 12px; }
#corpuswrap { height: calc(100vh - 250px); min-height: 560px; }
#corpuscv { height: 100% !important; }
.corpus-side { height: calc(100vh - 250px); min-height: 560px; }
@media (max-width: 900px) {
  .corpus-shell { grid-template-columns: 1fr; }
  #corpuswrap, .corpus-side { height: auto; min-height: 460px; }
}


/* ---- corpus-ground: the map has its own night sky ---------------------------- */
#corpuswrap { background: #0d0e12; border-color: #23262e; }
.corpus-side { background: #101218; border-color: #23262e; }
.corpus-side .csub { color: #8b93a4; }
.corpus-side .cfield { color: #9aa3b4; }
.corpus-side .cfield b, .corpus-side .clabel { color: #e6eaf2; }
.corpus-side .citem:hover, .corpus-side .sitem:hover, .corpus-side .nlink:hover {
  background: #1a1e28; }
.corpus-side .omni-in { background: #0d0e12; border-color: #2b2f3a; color: #e6eaf2; }
#cstatus { color: #8b93a4; }


/* --- rich daily-truth document (2026-08-22) --- */
.dt-doc{max-width:80ch;line-height:1.55;font-size:.94rem}
.dt-doc .dt-h{margin:1.15em 0 .35em;font-size:1rem;font-weight:700;letter-spacing:.01em}
.dt-doc .dt-p{margin:.5em 0}
.dt-doc ul{margin:.35em 0 .7em 1.2em;padding:0}
.dt-doc li{margin:.22em 0}
.dt-doc code{background:rgba(128,128,128,.16);padding:.06em .32em;border-radius:3px;font-size:.86em}
.dt-doc .dt-hr{border:0;border-top:1px solid rgba(128,128,128,.28);margin:1.1em 0}
/* Obsidian-parity callouts — data-callout + --cc(RGB accent). Icons take currentColor. */
.dt-doc .callout{--cc:68,138,255;margin:.9em 0;border:1px solid rgba(var(--cc),.30);
  border-left:3px solid rgb(var(--cc));border-radius:var(--radius,7px);
  background:rgba(var(--cc),.05);overflow:hidden}
.dt-doc .callout-title{display:flex;align-items:center;gap:.5em;padding:.5em .8em;
  background:rgba(var(--cc),.14);color:rgb(var(--cc));font-weight:700;font-size:.9rem;line-height:1.35}
.dt-doc .callout-title-inner{color:rgb(var(--cc))}
.dt-doc .callout-title a.wl{color:inherit;text-decoration:underline;text-underline-offset:2px}
.dt-doc .callout-icon{display:inline-flex;flex:0 0 auto;align-items:center}
.dt-doc .callout-icon svg{width:1.05em;height:1.05em;display:block}
.dt-doc .callout-content{padding:.5em .85em .15em;color:var(--tx)}
.dt-doc .callout-content>.dt-p:first-child{margin-top:.3em}
.dt-doc .callout-content>*:last-child{margin-bottom:.4em}
.dt-doc .callout-content .dt-p{margin:.4em 0}
.dt-doc .callout-content ul{margin:.3em 0 .5em 1.1em}
/* --- type accent colors: Obsidian defaults + the vault's crm-callouts vocabulary --- */
.dt-doc .callout[data-callout="note"]{--cc:68,138,255}
.dt-doc .callout[data-callout="abstract"],.dt-doc .callout[data-callout="summary"],.dt-doc .callout[data-callout="tldr"]{--cc:0,191,165}
.dt-doc .callout[data-callout="info"]{--cc:2,122,255}
.dt-doc .callout[data-callout="todo"]{--cc:2,122,255}
.dt-doc .callout[data-callout="tip"],.dt-doc .callout[data-callout="hint"],.dt-doc .callout[data-callout="important"]{--cc:0,191,165}
.dt-doc .callout[data-callout="success"],.dt-doc .callout[data-callout="check"],.dt-doc .callout[data-callout="done"]{--cc:8,185,78}
.dt-doc .callout[data-callout="question"],.dt-doc .callout[data-callout="help"],.dt-doc .callout[data-callout="faq"]{--cc:236,117,0}
.dt-doc .callout[data-callout="warning"],.dt-doc .callout[data-callout="caution"],.dt-doc .callout[data-callout="attention"]{--cc:236,117,0}
.dt-doc .callout[data-callout="failure"],.dt-doc .callout[data-callout="fail"],.dt-doc .callout[data-callout="missing"]{--cc:233,49,71}
.dt-doc .callout[data-callout="danger"],.dt-doc .callout[data-callout="error"],.dt-doc .callout[data-callout="bug"]{--cc:233,49,71}
.dt-doc .callout[data-callout="example"]{--cc:120,82,238}
.dt-doc .callout[data-callout="quote"],.dt-doc .callout[data-callout="cite"]{--cc:158,158,158}
.dt-doc .callout[data-callout="document"],.dt-doc .callout[data-callout="doc"]{--cc:71,85,105}
/* DT skeleton v15 (2026-08-30): the safety section ships with 8/28+ truths */
.dt-doc .callout[data-callout="safety"]{--cc:8,185,78}
.dt-doc .callout[data-callout="incident"]{--cc:233,49,71}
.dt-doc .callout[data-callout="attachment"]{--cc:100,116,139}
.dt-doc .callout[data-callout="email"]{--cc:59,130,246}
.dt-doc .callout[data-callout="correspondence"],.dt-doc .callout[data-callout="letter"]{--cc:99,102,241}
.dt-doc .callout[data-callout="spec"]{--cc:13,148,136}
.dt-doc .callout[data-callout="drawing"],.dt-doc .callout[data-callout="sheet"]{--cc:6,182,212}
.dt-doc .callout[data-callout="submittal"]{--cc:168,85,247}
.dt-doc .callout[data-callout="photo"]{--cc:139,92,246}
.dt-doc .callout[data-callout="rfi"]{--cc:245,158,11}
.dt-doc .callout[data-callout="co"],.dt-doc .callout[data-callout="changeorder"]{--cc:249,115,22}
.dt-doc .callout[data-callout="pco"]{--cc:251,146,60}
.dt-doc .callout[data-callout="meeting"]{--cc:37,99,235}
.dt-doc .callout[data-callout="permit"]{--cc:22,163,74}
.dt-doc .callout[data-callout="inspection"]{--cc:16,185,129}
.dt-doc .callout[data-callout="payapp"],.dt-doc .callout[data-callout="invoice"]{--cc:34,197,94}
.dt-doc .callout[data-callout="backcharge"]{--cc:220,38,38}
.dt-doc .callout[data-callout="dispute"]{--cc:234,88,12}
.dt-doc .callout[data-callout="pour"]{--cc:120,113,108}
.dt-doc .callout[data-callout="delivery"]{--cc:180,83,9}
.dt-doc .callout[data-callout="sub"],.dt-doc .callout[data-callout="subcontractor"]{--cc:202,138,4}
.dt-doc .callout[data-callout="geotech"]{--cc:146,64,14}
.dt-doc .callout[data-callout="ust"],.dt-doc .callout[data-callout="environmental"]{--cc:185,28,28}
/* --- title legibility: vivid accent stays on icon+border; title text adapts to the ground --- */
.dt-doc .callout-title,.dt-doc .callout-title-inner{color:color-mix(in srgb, rgb(var(--cc)) 60%, #0f1319)}
@media (prefers-color-scheme: dark){
  :root:not([data-theme="light"]) .dt-doc .callout-title,
  :root:not([data-theme="light"]) .dt-doc .callout-title-inner{color:color-mix(in srgb, rgb(var(--cc)) 80%, #ffffff)}
}
:root[data-theme="dark"] .dt-doc .callout-title,
:root[data-theme="dark"] .dt-doc .callout-title-inner{color:color-mix(in srgb, rgb(var(--cc)) 80%, #ffffff)}
:root[data-theme="light"] .dt-doc .callout-title,
:root[data-theme="light"] .dt-doc .callout-title-inner{color:color-mix(in srgb, rgb(var(--cc)) 60%, #0f1319)}

.dt-doc .dt-bq{border-left:3px solid rgba(128,128,128,.4);margin:.55em 0;padding:.15em .8em;opacity:.85;font-style:italic}

.dt-doc .dt-tablewrap{overflow-x:auto;margin:.75em 0}
.dt-doc .dt-table{border-collapse:collapse;width:100%;font-size:.9rem}
.dt-doc .dt-table th,.dt-doc .dt-table td{border:1px solid rgba(128,128,128,.28);padding:.35em .6em;text-align:left;vertical-align:top}
.dt-doc .dt-table thead th{background:rgba(128,128,128,.14);font-weight:700}
.dt-doc .dt-table tbody tr:nth-child(even){background:rgba(128,128,128,.05)}

/* --- comprehensive calendar (2026-08-23) --- */
.calgrid td{min-width:116px;vertical-align:top}
.calgrid .calday{display:block;margin-bottom:3px;font-weight:600}
.calgrid .caltoday{color:var(--gold-ink);font-weight:800}
.calgrid .daycell{max-height:150px;overflow-y:auto;display:flex;flex-direction:column;gap:2px}
.calgrid .ev{font-size:11px;line-height:1.3;border-left:3px solid var(--faint,#888);padding:1px 5px;border-radius:3px;background:rgba(128,128,128,.07);white-space:nowrap;overflow:hidden;text-overflow:ellipsis;max-width:100%}
.calgrid .ev a{text-decoration:none;color:var(--tx)}
.calgrid .ev.ghost{opacity:.6}
.cal-legend{display:flex;flex-wrap:wrap;gap:8px 15px;margin:.3em 0 .8em;font-size:12px;color:var(--mut)}
.cal-legend span{display:inline-flex;align-items:center;gap:5px}
.cal-dot{display:inline-block;width:9px;height:9px;border-radius:2px;background:var(--faint,#888);flex:0 0 auto}
.calgrid .ev.ev-deadline,.calgrid .ev.ev-due{border-left-color:#e93147}
.cal-dot.ev-deadline,.cal-dot.ev-due{background:#e93147}
.calgrid .ev.ev-permit{border-left-color:#22a35a}
.cal-dot.ev-permit{background:#22a35a}
.calgrid .ev.ev-meeting{border-left-color:#2563eb}
.cal-dot.ev-meeting{background:#2563eb}
.calgrid .ev.ev-inspection{border-left-color:#10b981}
.cal-dot.ev-inspection{background:#10b981}
.calgrid .ev.ev-rfi,.calgrid .ev.ev-co,.calgrid .ev.ev-pco,.calgrid .ev.ev-submittal{border-left-color:#f59e0b}
.cal-dot.ev-rfi,.cal-dot.ev-co,.cal-dot.ev-pco,.cal-dot.ev-submittal{background:#f59e0b}
.calgrid .ev.ev-delivery{border-left-color:#b4530a}
.cal-dot.ev-delivery{background:#b4530a}
.calgrid .ev.ev-document,.calgrid .ev.ev-drawing,.calgrid .ev.ev-spec{border-left-color:#64748b}
.cal-dot.ev-document,.cal-dot.ev-drawing,.cal-dot.ev-spec{background:#64748b}
.calgrid .ev.ev-event,.calgrid .ev.ev-calendar,.calgrid .ev.ev-task,.calgrid .ev.ev-milestone,.calgrid .ev.ev-decision,.calgrid .ev.ev-phase,.calgrid .ev.ev-ratification{border-left-color:#7c8794}
.cal-dot.ev-event{background:#7c8794}
.calgrid .ev.ev-photo{border-left-color:#8b5cf6}
.cal-dot.ev-photo{background:#8b5cf6}
.calgrid .ev.ev-daily-truth{border-left-color:#c78a2e}
.cal-dot.ev-daily-truth{background:#c78a2e}
.calgrid .ev.ev-mention{border-left-color:rgba(140,140,150,.45);opacity:.82}
.cal-dot.ev-mention{background:rgba(140,140,150,.5)}
.calgrid .ev.ev-more{opacity:.6;font-style:italic;border-left-color:transparent;background:none}

.calgrid .ev.ev-mention-sum{opacity:.8;font-style:italic;border-left-color:rgba(140,140,150,.5);background:rgba(128,128,128,.10);color:var(--mut);cursor:default}

/* --- home: where every job stands (2026-08-23) --- */
.jobsboard{display:grid;grid-template-columns:repeat(auto-fill,minmax(224px,1fr));gap:var(--gap-2);margin:.4em 0 var(--gap-3)}
.jobcard{display:block;padding:12px 14px;border:1px solid var(--line);border-top:3px solid var(--rule);border-radius:var(--radius-lg);background:var(--panel);text-decoration:none;color:var(--tx);transition:transform .12s ease,box-shadow .12s ease,border-color .12s ease}
.jobcard:hover{transform:translateY(-2px);box-shadow:var(--shadow-pop);border-top-color:var(--gold-ink)}
.jobcard.hot{border-top-color:var(--bad)}
.jc-hd{display:flex;align-items:center;gap:7px;font-size:1rem;margin-bottom:7px}
.jc-hd b{font-family:var(--font-display,serif)}
.jc-flag{margin-left:auto;font-size:10px;color:var(--bad);border:1px solid var(--bad);border-radius:4px;padding:0 5px;text-transform:uppercase;letter-spacing:.05em;font-weight:700}
.jc-row{font-size:.85rem;color:var(--mut);margin:2px 0}
.jc-n{font-weight:800;color:var(--tx)}
.jc-n.warn{color:var(--warn)}
.jc-ball b,.jc-row b{color:var(--tx)}
.jc-docs{display:flex;flex-wrap:wrap;gap:6px;margin-top:8px}
.jc-docs span{font-size:11px;background:var(--panel2);border:1px solid var(--line);border-radius:4px;padding:1px 7px;color:var(--mut)}
.jc-next{color:var(--gold-ink)!important;border-color:var(--gold-soft)!important}

.jc-last{font-size:.8rem;color:var(--faint)}
.jc-nextd{color:var(--gold-ink)}

/* --- contextual ask box (2026-08-23) --- */
.askfab{position:fixed;right:22px;bottom:22px;z-index:900;display:inline-flex;align-items:center;gap:8px;
  padding:11px 16px;border:none;border-radius:26px;background:var(--gold);color:#1a1400;font-weight:700;
  font-size:.9rem;cursor:pointer;box-shadow:var(--shadow-pop);transition:transform .12s ease}
.askfab:hover{transform:translateY(-2px)}
.askfab svg{width:17px;height:17px}
.askpanel{position:fixed;right:22px;bottom:78px;z-index:901;width:min(400px,calc(100vw - 44px));
  max-height:min(70vh,620px);display:flex;flex-direction:column;background:var(--panel);
  border:1px solid var(--line);border-radius:var(--radius-lg);box-shadow:var(--shadow-pop);overflow:hidden}
.ap-hd{display:flex;align-items:center;gap:8px;padding:11px 14px;border-bottom:1px solid var(--line);background:var(--panel2)}
.ap-title{font-weight:700;font-family:var(--font-display,serif)}
.ap-ctx{font-size:.78rem;color:var(--gold-ink);background:var(--gold-soft);border-radius:4px;padding:1px 7px;max-width:180px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.ap-x{margin-left:auto;background:none;border:none;color:var(--mut);font-size:1.4rem;line-height:1;cursor:pointer;padding:0 2px}
.ap-body{padding:13px 15px;overflow-y:auto;flex:1;font-size:.9rem;line-height:1.5}
.ap-hint{color:var(--mut);font-size:.85rem}
.ap-kbd{margin-top:9px;font-size:.75rem;color:var(--faint)}
.ap-kbd b{background:var(--panel2);border:1px solid var(--line);border-radius:3px;padding:0 5px;color:var(--mut)}
.ap-q{font-weight:700;color:var(--tx);margin-bottom:8px}
.ap-q::before{content:"▸ ";color:var(--gold-ink)}
.ap-ans{color:var(--tx);white-space:normal}
.ap-thinking{color:var(--mut);font-style:italic}
.ap-err{color:var(--warn)}
.ap-cites{margin-top:12px;border-top:1px solid var(--line);padding-top:9px}
.ap-cites-h{font-size:.72rem;text-transform:uppercase;letter-spacing:.05em;color:var(--faint);margin-bottom:5px}
.ap-cite{display:inline-block;font-size:.8rem;margin:0 6px 5px 0;padding:1px 7px;background:var(--panel2);border:1px solid var(--line);border-radius:4px}
.ap-cites[open]{padding-bottom:4px}.ap-cites summary{cursor:pointer}.ap-cite{display:block;margin:7px 0;padding:7px 8px;overflow-wrap:anywhere}.ap-cite small{display:block;margin-top:4px;color:var(--faint);font:500 .66rem/1.35 "JetBrains Mono",monospace}.ap-verify{margin-top:10px;color:var(--green);font:600 .68rem/1.3 "JetBrains Mono",monospace;text-transform:uppercase;letter-spacing:.04em}
.ap-form{display:flex;gap:8px;padding:11px 13px;border-top:1px solid var(--line);background:var(--panel2)}
.ap-in{flex:1;padding:9px 11px;border:1px solid var(--line);border-radius:8px;background:var(--panel);color:var(--tx);font-size:.9rem}
.ap-in:focus{outline:none;border-color:var(--gold-ink)}
.ap-go{padding:0 15px;border:none;border-radius:8px;background:var(--gold);color:#1a1400;font-weight:700;font-size:1.05rem;cursor:pointer}
@media (max-width:760px){.askpanel{right:10px;left:10px;width:auto;bottom:70px}}

/* --- voice: mic + listen (2026-08-23) --- */
.ap-mic{padding:0 11px;border:1px solid var(--line);border-radius:8px;background:var(--panel);color:var(--mut);font-size:1rem;cursor:pointer}
.ap-mic:hover{border-color:var(--gold-ink)}
.ap-mic.listening{background:var(--bad);color:#fff;border-color:var(--bad);animation:micpulse 1s infinite}
@keyframes micpulse{0%,100%{opacity:1}50%{opacity:.55}}
.ap-listen{display:inline-block;margin-top:9px;padding:3px 10px;border:1px solid var(--line);border-radius:14px;background:var(--panel2);color:var(--mut);font-size:.78rem;cursor:pointer}
.ap-listen:hover{border-color:var(--gold-ink);color:var(--tx)}
.js-listen.speaking{background:var(--gold);color:#1a1400;border-color:var(--gold-ink);animation:micpulse 1.1s infinite}
.js-listen{cursor:pointer}

/* --- trace the chain (2026-08-23) --- */
.tracetree,.tracetree ul{list-style:none;margin:0;padding-left:0}
.tracetree ul{margin-left:13px;padding-left:14px;border-left:1px solid var(--line)}
.tracetree li{margin:3px 0;line-height:1.55}
.tr-edge{font-size:.72rem;color:var(--faint);background:var(--panel2);border:1px solid var(--line);border-radius:4px;padding:0 6px;margin-right:6px}
.tr-ref{color:var(--faint);font-size:.82rem}

/* --- trace: chronological chain (2026-08-23) --- */
.tracechain{list-style:none;margin:0;padding:0}
.tracechain li{display:flex;gap:12px;align-items:baseline;padding:5px 0;border-bottom:1px solid var(--line);line-height:1.5}
.tracechain li:last-child{border-bottom:none}
.tracechain .tc-root{background:var(--panel2);margin:0 -6px 5px;padding:7px 8px;border-radius:6px;border-bottom:none}
.tc-date{flex:0 0 90px;font-family:var(--font-data,ui-monospace,monospace);font-size:.8rem;color:var(--mut)}
.tc-via{flex:0 0 158px;font-size:.72rem;color:var(--faint);text-align:right}
.tracechain a,.tracechain b{flex:1;min-width:0}
.tc-back{margin-left:auto}

/* --- read-aloud pills (2026-08-23) --- */
.listen-pill{display:inline-flex;align-items:center;gap:5px;margin-left:9px;padding:3px 11px;border:1px solid var(--line);border-radius:16px;background:var(--panel2);color:var(--mut);font-size:.78rem;cursor:pointer;vertical-align:middle;transition:border-color .12s,color .12s}
.listen-pill:hover{border-color:var(--gold-ink);color:var(--tx)}
.listen-pill.speaking{background:var(--gold);color:#1a1400;border-color:var(--gold-ink);animation:micpulse 1.1s infinite}

/* --- on-this-page navigator (2026-08-23) --- */
.toc-fab{position:fixed;left:20px;bottom:20px;z-index:70;width:44px;height:44px;display:none;align-items:center;justify-content:center;border-radius:50%;border:1px solid var(--line);background:var(--panel);color:var(--mut);cursor:pointer;box-shadow:0 4px 14px -4px rgba(0,0,0,.35)}
.toc-fab.ready{display:inline-flex}
.toc-fab:hover{color:var(--tx);border-color:var(--gold-ink)}
.toc-fab.on{color:#1a1400;background:var(--gold);border-color:var(--gold-ink)}
.toc-panel{position:fixed;left:20px;bottom:74px;z-index:70;width:270px;max-height:min(64vh,560px);overflow-y:auto;background:var(--panel);border:1px solid var(--line);border-radius:14px;box-shadow:0 18px 46px -16px rgba(0,0,0,.5),0 2px 6px rgba(0,0,0,.2);padding:12px 6px 10px}
.toc-hd{display:flex;align-items:center;justify-content:space-between;font-size:.68rem;letter-spacing:.14em;text-transform:uppercase;color:var(--mut);font-weight:600;padding:0 10px 8px;border-bottom:1px solid var(--line);margin-bottom:6px}
.toc-x{background:none;border:none;color:var(--mut);font-size:1.15rem;line-height:1;cursor:pointer;padding:0 2px;box-shadow:none}
.toc-x:hover{color:var(--tx)}
.toc-list{list-style:none;margin:0;padding:0}
.toc-i{margin:1px 0}
.toc-i a{display:block;padding:5px 10px;color:var(--mut);text-decoration:none;border-radius:7px;line-height:1.32;border-left:2px solid transparent;font-size:.86rem;transition:color .12s,background .12s,border-color .12s}
.toc-i a:hover{color:var(--tx);background:var(--panel2)}
.toc-i a.on{color:var(--gold-ink);border-left-color:var(--gold-ink);background:color-mix(in srgb,var(--gold) 9%,transparent);font-weight:600}
.toc-i.lvl2 a{padding-left:22px;font-size:.8rem;opacity:.9}
.toc-panel::-webkit-scrollbar{width:8px}

/* --- minigraph hover affordance (2026-08-23) --- */
.minigraph a{cursor:pointer}
.minigraph text{transition:fill .1s}
.minigraph a:hover text{fill:var(--gold)}
.minigraph a:hover circle{fill:var(--gold);r:6.5}

/* --- peek: +N more row (2026-08-23) --- */
.peek .more{color:var(--mut);font-size:.8rem;margin-top:2px;opacity:.85}
.peek .row b{color:var(--tx)}

/* --- dossier breadcrumb (2026-08-23) --- */
.crumbs{font-size:.8rem;color:var(--mut);margin:0 0 12px;display:flex;flex-wrap:wrap;gap:7px;align-items:center;letter-spacing:.01em}
.crumbs a{color:var(--mut);text-decoration:none;border-bottom:1px solid transparent;transition:color .12s,border-color .12s}
.crumbs a:hover{color:var(--gold-ink);border-bottom-color:var(--gold-ink)}
.crumb-sep{color:var(--faint);opacity:.6}
.crumb-here{color:var(--tx);font-weight:500}

/* --- day view (2026-08-23): every date resolves to a two-way day --- */
.day-hd{display:flex;align-items:center;gap:16px;margin:2px 0 var(--gap-3)}
.day-hd .day-title{flex:1}
.day-nav{display:inline-flex;align-items:center;justify-content:center;width:40px;height:40px;flex:0 0 auto;border:1px solid var(--line);border-radius:10px;color:var(--mut);text-decoration:none;font-size:1.5rem;line-height:1;background:var(--panel)}
.day-nav:hover{border-color:var(--gold-ink);color:var(--tx)}
.day-flag{font-size:.55em;text-transform:uppercase;letter-spacing:.1em;padding:3px 9px;border-radius:11px;vertical-align:middle;font-family:var(--font-body);font-weight:600}
.day-flag.today{background:var(--gold);color:#1a1400}
.day-flag.ahead{border:1px solid var(--line);color:var(--mut)}
.daytruth{display:flex;gap:11px;align-items:center;padding:12px 14px;margin-bottom:14px;border:1px solid var(--line);border-radius:10px;background:var(--panel2);text-decoration:none;color:var(--tx);transition:border-color .12s}
.daytruth:hover{border-color:var(--gold-ink)}
.daytruth .dt-ico{font-size:1.35rem;color:var(--gold-ink);line-height:1}
.day-grp{margin:13px 0}
.day-grp-t{font-size:.72rem;text-transform:uppercase;letter-spacing:.1em;color:var(--mut);font-weight:700;margin-bottom:6px;display:flex;align-items:center;gap:8px}
.day-grp-t.due{color:var(--warn)}
.day-ct{font-size:.68rem;color:var(--faint);background:var(--panel2);border:1px solid var(--line);border-radius:9px;padding:0 7px;font-weight:500}
.day-row{padding:5px 0;border-bottom:1px solid var(--line);font-size:.9rem;line-height:1.4}
.day-row:last-child{border-bottom:none}
.d a{color:inherit;text-decoration:none;border-bottom:1px dotted var(--rule)}
.d a:hover{color:var(--gold-ink);border-bottom-color:var(--gold-ink)}

/* --- calendar day-stream (2026-08-23) --- */
.calstream{display:flex;flex-direction:column;gap:9px}
.calsec{text-transform:uppercase;letter-spacing:.14em;font-size:.72rem;font-weight:700;color:var(--mut);margin:24px 0 9px;display:flex;align-items:baseline;gap:11px}
.calsec:first-child{margin-top:6px}
.calsec-n{font-size:.68rem;letter-spacing:.02em;text-transform:none;color:var(--faint);font-weight:400}
.daycard{display:flex;gap:17px;align-items:stretch;padding:14px 18px;border:1px solid var(--line);border-radius:12px;background:var(--panel);text-decoration:none;color:var(--tx);transition:border-color .12s,transform .1s,box-shadow .12s}
.daycard:hover{border-color:var(--gold-ink);transform:translateY(-1px);box-shadow:0 6px 20px -12px rgba(0,0,0,.4)}
.daycard.today{border-color:var(--gold-ink);box-shadow:0 0 0 1px var(--gold) inset}
.daycard.wknd{opacity:.66}
.daycard.wknd:hover{opacity:1}
.dc-date{flex:0 0 58px;text-align:center;display:flex;flex-direction:column;justify-content:center;gap:1px;border-right:1px solid var(--line);padding-right:16px}
.dc-dow{font-size:.68rem;text-transform:uppercase;letter-spacing:.1em;color:var(--mut)}
.dc-dom{font-family:var(--font-display,serif);font-size:2rem;line-height:1;font-weight:600}
.dc-mon{font-size:.66rem;text-transform:uppercase;letter-spacing:.1em;color:var(--faint)}
.daycard.today .dc-dom{color:var(--gold-ink)}
.dc-body{flex:1;min-width:0;display:flex;flex-direction:column;gap:7px;justify-content:center}
.dc-dt{font-weight:600;font-size:.95rem;color:var(--tx)}
.dc-fwd-row{font-size:.88rem;line-height:1.45;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;color:var(--tx)}
.dc-k{font-size:.6rem;text-transform:uppercase;letter-spacing:.05em;padding:1px 6px;border-radius:5px;margin-right:8px;background:var(--panel2);color:var(--mut);border:1px solid var(--line);vertical-align:1px}
.dc-k.dc-deadline,.dc-k.dc-due{color:var(--warn);border-color:var(--warn)}
.dc-k.dc-inspection,.dc-k.dc-meeting{color:var(--link);border-color:var(--link-under)}
.dc-counts{display:flex;flex-wrap:wrap;gap:6px}
.dc-chip{font-size:.74rem;color:var(--mut);background:var(--panel2);border:1px solid var(--line);border-radius:20px;padding:2px 11px}
.dc-empty{color:var(--faint);font-size:.88rem}
.dc-go{flex:0 0 auto;align-self:center;color:var(--faint);font-size:1.5rem}
.daycard:hover .dc-go{color:var(--gold-ink)}
.bk-row{padding:6px 0;border-bottom:1px solid var(--line);font-size:.9rem}
.bk-row:last-child{border-bottom:none}

/* --- document viewer: click a sheet/photo, see the actual file (2026-08-23) --- */
.docview{margin-bottom:var(--gap-3)}
.docview-hd{display:flex;align-items:center;gap:11px;margin-bottom:11px;font-size:.95rem;flex-wrap:wrap}
.docview-pdf{width:100%;height:80vh;border:1px solid var(--line);border-radius:9px;background:#fff}
.docview-img{max-width:100%;max-height:82vh;border:1px solid var(--line);border-radius:9px;display:block}
.docview-open{display:inline-flex;align-items:center;gap:9px;padding:12px 18px;border:1px solid var(--gold);border-radius:10px;color:var(--gold-ink);text-decoration:none;font-weight:600}
.docview-open:hover{background:var(--gold);color:#1a1400}

/* --- day view: readable narrative + collapsible record groups (2026-08-23) --- */
.daycard-body{margin:2px 0 18px}
.day-sech{font-size:.72rem;letter-spacing:.08em;text-transform:uppercase;color:var(--faint);
  margin:18px 0 8px;padding-top:14px;border-top:1px solid var(--line)}
.day-more{margin:2px 0 4px}
.day-more>summary{cursor:pointer;color:var(--gold-ink);font-size:.82rem;list-style:none;padding:4px 0}
.day-more>summary::-webkit-details-marker{display:none}
.day-more>summary::before{content:"\25B8 ";color:var(--gold-ink)}
.day-more[open]>summary::before{content:"\25BE "}
.day-more>summary:hover{color:var(--tx)}

/* --- build stamp: objective 'am I on the current version' signal (2026-08-23) --- */
.build-tag{font-size:.6rem;letter-spacing:.02em;color:var(--faint);opacity:.6;white-space:nowrap;
  margin-left:8px;font-family:var(--mono,monospace)}
.build-tag:hover{opacity:1;color:var(--gold-ink)}

/* --- home reorg (2026-08-23): intentional top-down hierarchy, not a 3-col auto-grid --- */
.hero-brief{margin-bottom:var(--gap-3)}
.brief-cols{display:grid;grid-template-columns:repeat(auto-fit,minmax(270px,1fr));gap:var(--gap-2) var(--gap-4);margin-top:6px}
.brief-col{min-width:0}
.brief-h{margin:0 0 5px;color:var(--tx);border-bottom:1px solid var(--line);padding-bottom:4px}
.colcap{font-size:.72rem;letter-spacing:.12em;text-transform:uppercase;color:var(--faint);margin:2px 0 10px;font-weight:600}
.home-split{align-items:start}

/* --- home finish (2026-08-23): quiet jobs read as intentional, cards equal height --- */
/* wave82: #5fce9b was 1.95:1 on white; --ok is the token for exactly this. */
.jc-clear{color:var(--ok);font-weight:600;font-size:.85rem}
.jobsboard{align-items:stretch}
.jobcard{display:flex;flex-direction:column}
.jobcard .jc-docs{margin-top:auto;padding-top:8px}
.hero-brief h3{margin-bottom:2px}
.colcap{border-bottom:1px solid var(--line);padding-bottom:6px}

/* --- STATE DASHBOARD (2026-08-23): the status board is the point of The Board --- */
.statusboard{display:grid;grid-template-columns:repeat(auto-fit,minmax(212px,1fr));gap:var(--gap-2);margin:.3em 0 var(--gap-3);align-items:stretch}
.stile{display:flex;flex-direction:column;padding:14px 16px;border:1px solid var(--line);border-left:3px solid var(--line);border-radius:var(--radius-lg,12px);background:var(--panel);text-decoration:none;color:var(--tx);transition:transform .12s ease,box-shadow .12s ease}
.stile:hover{transform:translateY(-2px);box-shadow:var(--shadow-pop,0 6px 20px rgba(0,0,0,.35))}
.stile.bad{border-left-color:var(--bad)}
.stile.warn{border-left-color:var(--gold-ink)}
.stile.ok{border-left-color:#3a7d5c}
.stile-top{display:flex;align-items:baseline;gap:8px}
.stile-big{font-size:2rem;font-weight:800;line-height:1;color:var(--tx)}
.stile.bad .stile-big{color:var(--bad)}
.stile.warn .stile-big{color:var(--gold-ink)}
.stile-sub{font-size:.76rem;color:var(--faint)}
.stile-label{font-size:.92rem;font-weight:600;margin:3px 0 9px}
.stile-rows{display:flex;flex-direction:column;gap:3px;margin-top:9px;border-top:1px solid var(--line);padding-top:8px}
.stile-row{display:flex;justify-content:space-between;font-size:.82rem;color:var(--faint)}
.stile-row b{color:var(--tx)}
.stile-item{font-size:.8rem;line-height:1.3;padding:3px 0;border-bottom:1px solid var(--line)}
.stile-item:last-child{border-bottom:none}
/* wave80: an obligation quote wrapping to four lines made one tile 522px tall next to
   a 155px neighbour. Two lines each, with the rest one click away exactly as the tile
   header already promises. */
.stile-itxt{display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;
  overflow:hidden;color:var(--tx)}
.stile-state{font-size:.7rem;text-transform:uppercase;letter-spacing:.03em;color:var(--gold-ink)}
.stile-state.bad{color:var(--bad)}
.attn{display:flex;flex-wrap:wrap;align-items:baseline;gap:7px;padding:8px 0;border-bottom:1px solid var(--line);font-size:.9rem}
.attn:last-child{border-bottom:none}
.attn-kind{font-size:.66rem;text-transform:uppercase;letter-spacing:.05em;color:var(--faint);border:1px solid var(--line);padding:1px 6px;border-radius:4px}
.attn-state{margin-left:auto;font-size:.72rem;text-transform:uppercase;letter-spacing:.03em;color:var(--gold-ink);font-weight:600}
.attn-state.bad{color:var(--bad)}
.wk-strip{display:grid;grid-template-columns:repeat(7,1fr);gap:4px;margin-top:10px}
.wk-day{display:flex;flex-direction:column;gap:2px;padding:6px 4px;border:1px solid var(--line);border-radius:8px;color:var(--tx);min-height:64px;font-size:.72rem;text-decoration:none;transition:border-color .12s}
a.wk-day:hover{border-color:var(--gold-ink)}
.wk-dot{display:inline-block;width:7px;height:7px;border-radius:50%;margin-right:3px;vertical-align:baseline}
.wk-n{float:right;font-weight:700;color:var(--gold-ink);font-size:.62rem}
.wk-more{color:var(--faint);opacity:.9}
.wk-day.today{border-color:var(--gold-ink)}
.wk-dow{font-weight:700;color:var(--faint);font-size:.64rem;text-transform:uppercase}
.wk-ev{color:var(--tx);line-height:1.15;overflow:hidden;opacity:.85}
.wk-empty{color:var(--line)}

/* --- today's briefing: reason through the day, grounded + cited (2026-08-23) --- */
.briefing-card{border-top:3px solid var(--gold);margin-bottom:var(--gap-3)}
.briefing-body{font-size:.92rem;line-height:1.5}
.briefing-body h1,.briefing-body h2,.briefing-body h3{font-size:.98rem;margin:13px 0 4px;color:var(--tx)}
.briefing-body strong{color:var(--tx)}
.briefing-body p{margin:5px 0}
.briefing-body ul{margin:3px 0 11px;padding-left:2px;list-style:none}
.briefing-body li{padding:3px 0 3px 2px;line-height:1.42}
.burg{font-size:.66rem;vertical-align:1px;margin-right:5px}
.burg.bad{color:var(--bad)}
.burg.warn{color:var(--gold-ink)}
.burg.ok{color:var(--ok)}
.bcite{font-size:.68rem;color:var(--faint);text-decoration:none;border:1px solid var(--line);border-radius:4px;padding:0 5px;margin-left:5px;white-space:nowrap}
.bcite:hover{color:var(--gold-ink);border-color:var(--gold-ink)}
.bcite.syn{border-style:dashed}

/* calendar — the road ahead (rich forward view) 2026-08-24 */
.calsec-ahead{color:var(--gold-ink,#e8b84b);font-weight:700;font-size:1.06rem;letter-spacing:.02em}
.ahead-tl{padding:4px 4px}
.ahead-row{display:flex;align-items:baseline;gap:12px;padding:8px 10px;border-bottom:1px solid rgba(255,255,255,.06)}
.ahead-row:last-child{border-bottom:0}
/* wave82: #9aa3ad was 2.56:1 on white; --mut is the token for secondary text. */
.ahead-when{flex:0 0 172px;color:var(--mut);font-variant-numeric:tabular-nums;font-size:.9rem}
.ahead-in{opacity:.7}
.ahead-in.soon{color:var(--gold-ink,#e8b84b);opacity:1;font-weight:600}
.ahead-ic{flex:0 0 auto;opacity:.9}
.ahead-lbl{flex:1 1 auto;line-height:1.4}
.ahead-owed{margin-top:14px}
.owed-hd{color:var(--mut);font-size:.92rem;margin-bottom:6px}
.owed-grp{border-bottom:1px solid rgba(255,255,255,.06);padding:2px 0}
.owed-grp:last-child{border-bottom:0}
.owed-grp>summary{cursor:pointer;padding:7px 8px;list-style:none;display:flex;align-items:center;gap:10px}
.owed-grp>summary::-webkit-details-marker{display:none}
.owed-grp>summary::before{content:"\25B8";color:#8a93a0;font-size:.8em;transition:transform .12s}
.owed-grp[open]>summary::before{transform:rotate(90deg)}
.owed-who{font-weight:600}
.owed-n{background:rgba(255,255,255,.08);border-radius:10px;padding:1px 9px;font-size:.8rem;color:var(--mut)}
.owed-row{padding:5px 8px 5px 28px;font-size:.92rem;border-top:1px solid rgba(255,255,255,.04);line-height:1.4}

/* ===== full-history month calendar + property tenant rows (2026-08-29) ===== */
.calmonth { padding: 14px 16px 12px; margin-bottom: 18px; }
.cm-hd { display: flex; align-items: baseline; gap: 12px; margin-bottom: 10px; }
.cm-title { font-size: 1.15rem; letter-spacing: .02em; }
.cm-nav { font-size: 1.3rem; line-height: 1; padding: 0 8px; border-radius: 6px;
  color: var(--fg, #ddd); text-decoration: none; background: rgba(255,255,255,.05); }
.cm-nav:hover { background: rgba(255,255,255,.12); }
.cm-today { margin-left: auto; font-size: .78rem; color: #e8b33e; text-decoration: none; }
.cm-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 3px; }
.cm-dow { font-size: .68rem; opacity: .55; text-transform: uppercase; letter-spacing: .08em;
  padding: 2px 4px; }
.cm-day { min-height: 64px; border-radius: 7px; background: rgba(255,255,255,.025);
  padding: 4px 5px; display: flex; flex-direction: column; gap: 2px; text-decoration: none;
  color: inherit; border: 1px solid transparent; overflow: hidden; }
.cm-day.cm-has { background: rgba(255,255,255,.055); }
.cm-day:hover { border-color: rgba(232,179,62,.5); }
.cm-day.cm-now { border-color: #e8b33e; box-shadow: 0 0 0 1px #e8b33e inset; }
.cm-day.cm-void { background: transparent; pointer-events: none; }
.cm-dom { font-size: .72rem; opacity: .6; }
.cm-now .cm-dom { color: #e8b33e; opacity: 1; font-weight: 700; }
.cm-it { font-size: .62rem; line-height: 1.25; opacity: .9; white-space: nowrap;
  overflow: hidden; text-overflow: ellipsis; border-left: 2px solid rgba(255,255,255,.25);
  padding-left: 4px; }
.cm-it.cm-meeting { border-left-color: #6fb3ff; }
.cm-it.cm-inspection { border-left-color: #e8836f; }
.cm-it.cm-deadline { border-left-color: #e85d5d; }
.cm-it.cm-permit { border-left-color: #b07fe8; }
.cm-it.cm-delivery, .cm-it.cm-event { border-left-color: #7fe8a5; }
.cm-it.cm-email { border-left-color: rgba(255,255,255,.35); opacity: .6; }
.cm-more { font-size: .6rem; opacity: .5; }
.cm-idx { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 12px; }
.cm-mchip { font-size: .68rem; padding: 2px 7px; border-radius: 999px;
  background: rgba(255,255,255,.06); color: inherit; text-decoration: none; opacity: .8; }
.cm-mchip b { margin-left: 5px; opacity: .7; font-weight: 600; }
.cm-mchip.on { background: rgba(232,179,62,.2); border: 1px solid rgba(232,179,62,.5);
  opacity: 1; }
.cm-mchip:hover { opacity: 1; }
.jc-ten { font-size: .72rem; opacity: .75; white-space: nowrap; overflow: hidden;
  text-overflow: ellipsis; }
.jobsboard.props .jobcard { border-left: 2px solid rgba(176,127,232,.45); }
@media (max-width: 760px) { .cm-day { min-height: 44px; } .cm-it { display: none; }
  .cm-day.cm-has::after { content: "•"; color: #e8b33e; font-size: .7rem; } }

/* ===== calendar baseline port: legend, filters, job colors, states, spans, badges (2026-08-29) ===== */
.cm-legend { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 8px; }
.cm-leg { display: inline-flex; align-items: center; gap: 5px; font-size: .7rem; opacity: .8;
  color: inherit; text-decoration: none; padding: 2px 7px; border-radius: 999px;
  background: rgba(255,255,255,.05); }
.cm-leg i { width: 9px; height: 9px; border-radius: 3px; display: inline-block; }
.cm-leg.on { outline: 1px solid rgba(232,179,62,.6); opacity: 1; }
.cm-leg:hover { opacity: 1; }
.cm-leg.cm-clear { opacity: .6; }
.cm-filters { display: flex; flex-wrap: wrap; gap: 5px; align-items: center; margin-bottom: 8px; }
.cm-f { font-size: .66rem; padding: 1px 8px; border-radius: 999px; cursor: pointer;
  background: rgba(255,255,255,.05); border: 1px solid transparent; color: inherit; opacity: .5; }
.cm-f.on { opacity: 1; border-color: rgba(255,255,255,.2); }
.cm-star { color: #e8b33e; font-size: .66rem; }
.cm-day.cm-fut { border-style: dashed; border-color: rgba(232,179,62,.35); }
.cm-span { display: block; height: 4px; border-radius: 2px; margin: 1px 0; }
.cm-badges { margin-top: auto; font-size: .62rem; opacity: .8; }
.cm-it.cm-ghost { border-left-color: #e85d5d !important; color: #e88; }
.cm-it.cm-unc { opacity: .6; font-style: italic; }
.cm-it.cm-st-predicted, .cm-it.cm-st-scheduled { border-left-style: dashed; }
.cm-it.cm-st-done, .cm-it.cm-st-ratified { opacity: 1; font-weight: 600; }
.cm-it.cm-st-overdue { border-left-color: #e85d5d !important;
  text-shadow: 0 0 6px rgba(232,93,93,.6); }
.cm-it.cm-st-at-risk, .cm-it.cm-st-armed { text-shadow: 0 0 6px rgba(232,179,62,.6); }
.day-file{font-size:.72rem;opacity:.7;margin-left:8px;white-space:nowrap}.day-file:hover{opacity:1}
/* quiet calendar cells (2026-08-29 readability pass) */
.cm-dom { font-size: .9rem; font-weight: 600; opacity: .85; }
.cm-n { font-size: .68rem; opacity: .75; }
.cm-n::after { content: " items"; opacity: .7; }
.cm-fut-t { font-size: .64rem; line-height: 1.2; color: #e8b33e; white-space: normal; }
.cm-day { min-height: 58px; }
.cm-day.cm-has:hover { filter: brightness(1.25); }

/* ===== SOLID Obsidian-style month cells + phone-first fixes (2026-08-29, Nick) ===== */
.cm-day.cm-solid { border: 1px solid rgba(0,0,0,.3); }
.cm-day.cm-solid .cm-dom { color: inherit; opacity: 1; font-weight: 700; }
.cm-day.cm-solid .cm-badges { color: inherit; opacity: .95; }
.cm-day.cm-solid .cm-n { color: inherit; opacity: .9; }
.cm-day.cm-solid:hover { filter: brightness(1.15); }
.cm-day.cm-fut { border: 1.5px dashed rgba(255,255,255,.75); }
.cm-day.cm-now { outline: 2px solid #e8b33e; outline-offset: 1px; box-shadow: none; }
.cm-fut-t { color: #fff; }
.cm-star { color: #ffd76a; }
/* single-row scrollable legend + month strip — no more wrapped walls */
.cm-legend { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: thin; padding-bottom: 4px; }
.cm-leg { flex: 0 0 auto; }
.cm-idx { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: thin; padding-bottom: 4px; }
.cm-mchip { flex: 0 0 auto; }
/* phone: keep the color and the counts — never blank the cells */
@media (max-width: 760px) {
  .cm-day { min-height: 52px; padding: 3px 4px; }
  .cm-day.cm-has::after { content: none; }
  .cm-n::after { content: ""; }
  .cm-n { font-size: .62rem; }
  .cm-badges { font-size: .56rem; }
  .cm-fut-t { display: none; }
  .cm-dom { font-size: .8rem; }
}

/* PCS emblem (2026-08-31, Nick: logo on the board) */
.hdr .brand{display:flex;align-items:center;gap:10px}
.hdr .brand small{display:block}
.brand-logo{width:36px;height:36px;border-radius:50%;flex:none;box-shadow:0 0 0 1px rgba(201,166,70,.35)}

/* ===== wave6 (2026-09-06): in-place expansions + paper groups — the wiki enriched ===== */
.mention-more summary, .corr-more summary { cursor: pointer; font-size: 11px; color: var(--mut); margin-top: 3px; }
.mention-more summary:hover, .corr-more summary:hover { color: var(--fg); }
.mention-more p { margin: 5px 0 3px; padding: 7px 10px; background: var(--panel2); border-radius: 7px; line-height: 1.5; }
.paper-kind { margin: 8px 0 2px; letter-spacing: .04em; text-transform: uppercase; font-size: 10.5px; color: var(--mut); }
.paper-row { margin: 2px 0; }
.mention-line { line-height: 1.55; }

/* ===== wave8 (2026-09-06): the plan table — sheets were a 300x150 default iframe ===== */
.docview-pdf { width: 100%; height: 80vh; border: 1px solid var(--line, #333); border-radius: 8px; background: #fff; }
.docview-img { max-width: 100%; border-radius: 8px; }
#sv-frame { position: relative; width: 100%; height: 80vh; overflow: hidden; background: #1a1d23;
  border: 1px solid var(--line, #333); border-radius: 8px; touch-action: none; cursor: grab; }
#sv-frame canvas { position: absolute; left: 0; top: 0; transform-origin: 0 0; }
#sv-ink { pointer-events: none; }
.sv-bar { display: flex; gap: 6px; align-items: center; margin: 6px 0; flex-wrap: wrap; }
.sv-bar .badge { cursor: pointer; border: 1px solid transparent; }
.sv-bar .badge.on { border-color: var(--gold-ink,#d7a833); }

/* ===== wave13: photo strip ===== */
.photo-strip { display: flex; gap: 8px; flex-wrap: wrap; }
.photo-thumb { display: flex; flex-direction: column; gap: 2px; width: 118px; text-decoration: none; }
.photo-thumb img { width: 118px; height: 88px; object-fit: cover; border-radius: 7px; border: 1px solid var(--line, #333); }
/* wave81: .src is a block caption (board.css:119), but 105 elements pasted
   style="display:inline" to put it back on the line. One class, not 105 copies.
   Specificity 0,2,0 beats .src at 0,1,0 regardless of load order. */
.src.inl{display:inline}
