:root {
  color-scheme: light;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: #30252c;
  background: #f8f5f1;
  --ink: #30252c;
  --muted: #695c64;
  --line: #e7e0e4;
  --plum: #672855;
  --wine: #5b1026;
  --card: #fffdfb;
}
* { box-sizing: border-box; }
body { margin: 0; min-height: 100vh; }
.rail {
  position: fixed; inset: 0 auto 0 0; width: 224px;
  display: flex; flex-direction: column; padding: 28px 16px 20px;
  background: #eee7e3; border-right: 1px solid #e7dddd;
}
a { color: var(--plum); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--wine); }
.brand {
  display: flex; gap: 10px; align-items: center; padding: 0 6px;
  color: var(--ink); text-decoration: none; font-weight: 720; font-size: 16px;
}
.brand img { width: 36px; height: 36px; object-fit: contain; }
nav { display: grid; gap: 5px; margin-top: 44px; }
nav a {
  padding: 11px 12px; border-radius: 9px; font-size: 14px;
  color: var(--muted); text-decoration: none; font-weight: 620; min-height: 42px;
}
nav a:hover { background: #f6efed; }
nav a[aria-current="page"] { background: var(--plum); color: white; }
.workspace-label {
  margin-top: auto; padding: 10px 6px 0; color: var(--muted);
  border-top: 1px solid #ded2d8; font-size: 12px;
}
main { margin-left: 224px; padding: 42px clamp(22px, 4vw, 64px) 64px; }
.page-header {
  display: flex; align-items: end; justify-content: space-between;
  gap: 14px; margin-bottom: 24px;
}
h1 { font-size: clamp(26px, 4vw, 40px); line-height: 1.13; letter-spacing: -.045em; margin: 4px 0 8px; overflow-wrap: anywhere; }
p { margin: 0; }
.page-copy p, small { color: var(--muted); }
.page-copy p { font-size: 14px; }
.back { display: inline-block; font-size: 13px; margin-bottom: 8px; }
.actions, .filters { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; }
.actions { justify-content: end; }
button, input, select, textarea { font: inherit; }
button { cursor: pointer; }
button:disabled { opacity: .55; cursor: wait; }
:focus-visible { outline: 3px solid #875483; outline-offset: 3px; }
.primary, .quiet {
  min-height: 38px; padding: 8px 13px; border: 1px solid var(--line);
  border-radius: 8px; background: var(--card); color: var(--plum);
  font-size: 13px; font-weight: 660; text-decoration: none;
}
.primary { background: var(--plum); border-color: var(--plum); color: white; }
.primary:hover { background: #512044; color: white; }
.quiet:hover { background: #f4eaf0; }
.metrics { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin-bottom: 22px; }
.metric {
  display: grid; align-content: start; gap: 3px; min-height: 112px; padding: 15px;
  border-radius: 13px; border: 1px solid var(--line); background: var(--card);
}
.metric > span { font-size: 13px; font-weight: 650; }
.metric strong { font-size: 34px; line-height: 1.15; color: var(--plum); font-variant-numeric: tabular-nums; }
.metric small { font-size: 12px; }
.metric-good { background: #e7f3ef; border-color: #d6e7e2; }
.metric-violet { background: #efe9f5; border-color: #e6ddee; }
.metric-peach { background: #f5e8df; border-color: #ecddd1; }
.surface {
  margin-bottom: 15px; border: 1px solid var(--line); border-radius: 14px;
  background: var(--card); overflow: hidden;
}
.section-head {
  padding: 13px 17px; min-height: 56px; display: flex; align-items: center;
  justify-content: space-between; flex-wrap: wrap; gap: 9px;
}
.section-head a { font-size: 13px; }
h2 { margin: 0; font-size: 16px; }
input:not([type="checkbox"]), select, textarea {
  min-height: 36px; max-width: 100%; border: 1px solid #dfd5dc;
  border-radius: 7px; background: #fff; color: var(--ink); padding: 7px 9px; font-size: 13px;
}
input[type="search"] { width: min(190px, 100%); }
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; text-align: left; font-size: 13px; }
th { color: var(--muted); background: #faf7f7; font-size: 12px; font-weight: 650; }
th, td { padding: 11px 14px; border-top: 1px solid var(--line); }
th:first-child, td:first-child { padding-left: 17px; }
.cell-link { font-weight: 670; color: var(--ink); text-decoration: none; overflow-wrap: anywhere; }
.cell-link:hover { text-decoration: underline; }
.cell-stack { display: grid; gap: 3px; justify-items: start; min-width: 100px; }
.cell-stack small { font-size: 11px; }
.site-cell { display: flex; gap: 9px; align-items: center; }
.monogram {
  flex: none; display: grid; place-items: center; width: 35px; height: 35px;
  border-radius: 9px; color: var(--plum); background: #f1e6ee; font-weight: 720;
}
.pill {
  display: inline-block; border-radius: 6px; padding: 3px 7px; font-size: 11px;
  font-weight: 690; background: #f1ecef; color: #594954; white-space: nowrap;
}
.pill.good { background: #d3e9e7; color: #24514c; }
.pill.caution { background: #f6e5d0; color: #704716; }
.pill.violet { background: #ebe3f4; color: #5a4b77; }
.pill.danger { background: #f7dce5; color: #831339; }
.readiness { display: inline-flex; align-items: center; gap: 7px; font-size: 12px; white-space: nowrap; }
progress { width: 72px; height: 7px; border: 0; border-radius: 9px; background: #eee5ea; }
progress::-webkit-progress-bar { background: #eee5ea; border-radius: 9px; }
progress::-webkit-progress-value { background: var(--plum); border-radius: 9px; }
progress::-moz-progress-bar { background: var(--plum); border-radius: 9px; }
.case-count { font-weight: 670; }
.empty { border-top: 1px solid var(--line); padding: 25px 17px; color: var(--muted); font-size: 14px; }
.detail-grid { display: grid; grid-template-columns: 1.3fr 1fr; gap: 14px; }
.checklist { padding: 0; margin: 0; list-style: none; }
.checklist li { display: flex; gap: 9px; align-items: center; padding: 10px 17px; border-top: 1px solid var(--line); font-size: 13px; }
.complete, .incomplete {
  flex: none; display: grid; place-items: center; width: 18px; height: 18px;
  border-radius: 5px; border: 1px solid #ddd3da; font-size: 12px;
}
.complete { background: #d3e9e7; color: #24514c; border-color: #cee2df; }
.info-stack, .guide { border-top: 1px solid var(--line); padding: 13px 17px; }
.info-stack { display: grid; gap: 12px; }
.fact { display: grid; justify-items: start; gap: 3px; font-size: 14px; white-space: pre-wrap; overflow-wrap: anywhere; }
.fact > span:first-child { font-size: 12px; color: var(--muted); }
.event, .activity > p { border-top: 1px solid var(--line); padding: 10px 17px; font-size: 13px; }
.event p { white-space: pre-wrap; overflow-wrap: anywhere; margin-bottom: 3px; }
.guide { line-height: 1.55; font-size: 14px; }
.guide ol { padding-left: 20px; margin: 8px 0; }
.guide li { padding: 3px 0; }
.playbooks { display: grid; gap: 1px; }
dialog { width: min(calc(100% - 24px), 510px); max-height: 90dvh; border: 1px solid var(--line); border-radius: 14px; padding: 0; color: var(--ink); background: var(--card); }
dialog::backdrop { background: #301c2cab; }
dialog form { display: flex; flex-direction: column; max-height: 88dvh; }
.dialog-head, .dialog-fields, .dialog-foot { padding: 14px 17px; }
.dialog-head { border-bottom: 1px solid var(--line); }
.dialog-fields { display: grid; gap: 12px; overflow: auto; }
.form-field { display: grid; gap: 5px; font-size: 13px; font-weight: 650; }
textarea { resize: vertical; }
fieldset { min-width: 0; border: 1px solid var(--line); border-radius: 7px; }
legend, .checkbox { font-size: 13px; }
.checkbox { display: flex; align-items: center; gap: 7px; padding: 4px 0; }
.checkbox input { accent-color: var(--plum); width: 16px; height: 16px; flex: none; }
.dialog-foot { border-top: 1px solid var(--line); display: flex; justify-content: flex-end; gap: 8px; }
.form-error { color: #831339; font-size: 13px; }
.form-error:empty, #notice:empty { display: none; }
#notice {
  position: fixed; bottom: 20px; right: 20px; max-width: calc(100vw - 40px);
  border-radius: 8px; background: var(--plum); color: #fff; padding: 11px 14px; font-size: 13px;
}
@media (max-width: 960px) {
  .rail { width: 175px; padding-inline: 12px; }
  main { margin-left: 175px; }
  .brand { font-size: 14px; gap: 6px; }
  .brand img { width: 29px; height: 29px; }
  .metrics { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .detail-grid { grid-template-columns: 1fr; gap: 0; }
}
@media (max-width: 640px) {
  .rail { position: static; width: 100%; padding: 9px 13px; border-right: 0; border-bottom: 1px solid var(--line); display: grid; gap: 8px; }
  nav { margin: 0; display: flex; flex-wrap: wrap; }
  nav a { padding: 8px 9px; min-height: 36px; font-size: 13px; }
  .workspace-label { border: 0; padding: 0 6px; }
  main { margin: 0; padding: 21px 13px 42px; }
  .page-header { flex-wrap: wrap; align-items: start; }
  .actions { justify-content: flex-start; }
  .metric { min-height: 94px; padding: 11px; }
  .metric strong { font-size: 28px; }
  .section-head { padding-inline: 11px; }
  .site-cell { min-width: 145px; }
}
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }

@font-face { font-family: Manrope; src: url('/manrope.ttf') format('truetype'); font-display: swap; font-weight: 200 800; }
:root {
  font-family: Manrope, system-ui, sans-serif;
  --ink: #392532;
  --muted: #64534f;
  --line: #e2d8df;
  --card: #fffdfa;
  background: #f5f1eb;
  color: var(--ink);
}
.rail {
  inset: 12px auto 12px 12px; width: 210px;
  border: 1px solid #553b58; border-radius: 20px;
  background: linear-gradient(162deg, #672855, #53324f 38%, #3a293f 80%);
  box-shadow: 0 12px 26px #39253221;
}
.brand, .brand:hover { color: #faf3f8; }
.brand img { background: #fffdfa; padding: 4px; border-radius: 8px; }
nav a, .workspace-label { color: #ead8e5; }
.workspace-label { border-color: #ffffff29; }
nav a:hover { color: #faf3f8; background: #ffffff16; }
nav a[aria-current="page"] { color: #263e40; background: #d3e9e7; }
h1 { color: #5b1026; font-weight: 650; }
.surface, .metric { box-shadow: 0 1px 2px #39253208, 0 8px 22px #39253207; }
.environment-status { display: flex; gap: 9px; align-items: center; flex-wrap: wrap; font-size: 13px; padding: 6px 2px; }
@media (max-width: 960px) { .rail { width: 153px; } }
@media (max-width: 640px) { .rail { width: auto; margin: 8px 8px 0; } }
.signing-in :is(.rail, main) { display: none; }
.signing-in #identity { min-height: 100dvh; display: grid; place-items: center; padding: 20px; }
.sign-out { position: fixed; bottom: 48px; left: 28px; z-index: 1; }
@media (max-width: 640px) { .sign-out { position: absolute; bottom: auto; top: 19px; left: auto; right: 18px; } }
