@font-face { font-family: "Public Sans"; font-style: normal; font-weight: 400; font-display: swap; src: url("/fonts/public-sans-latin-400-normal.woff2") format("woff2"); }
@font-face { font-family: "Public Sans"; font-style: normal; font-weight: 500; font-display: swap; src: url("/fonts/public-sans-latin-500-normal.woff2") format("woff2"); }
@font-face { font-family: "Public Sans"; font-style: normal; font-weight: 600; font-display: swap; src: url("/fonts/public-sans-latin-600-normal.woff2") format("woff2"); }
@font-face { font-family: "Public Sans"; font-style: normal; font-weight: 700; font-display: swap; src: url("/fonts/public-sans-latin-700-normal.woff2") format("woff2"); }

:root {
  color-scheme: light;
  --bg: #eef1f4; --surface: #ffffff; --surface2: #f6f8fa; --ink: #17202c; --muted: #5a6576; --line: #d6dce3;
  --accent: #23574a; --accent-ink: #ffffff; --accent-soft: #e3efea;
  --orange: #a85300; --orange-bg: #fff0dd; --red: #b3261e; --red-bg: #fce8e6; --ok: #1e6b45; --ok-bg: #e4f3ea;
  --focus: #2f6fdd; --r: 6px;
  box-sizing: border-box; padding-top: env(safe-area-inset-top, 0px); padding-bottom: env(safe-area-inset-bottom, 0px);
}
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) {
  color-scheme: dark;
  --bg: #0f141a; --surface: #161d25; --surface2: #1c242e; --ink: #e5e9ee; --muted: #98a3b1; --line: #2a3440;
  --accent: #79c2a6; --accent-ink: #0f141a; --accent-soft: #1d3a31;
  --orange: #f2a555; --orange-bg: #3a2812; --red: #f2867c; --red-bg: #3d1c1a; --ok: #7fd0a3; --ok-bg: #17352a; --focus: #7aa7ff; } }
:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #0f141a; --surface: #161d25; --surface2: #1c242e; --ink: #e5e9ee; --muted: #98a3b1; --line: #2a3440;
  --accent: #79c2a6; --accent-ink: #0f141a; --accent-soft: #1d3a31;
  --orange: #f2a555; --orange-bg: #3a2812; --red: #f2867c; --red-bg: #3d1c1a; --ok: #7fd0a3; --ok-bg: #17352a; --focus: #7aa7ff; }
*, *::before, *::after { box-sizing: inherit; }
html { scroll-padding-top: env(safe-area-inset-top, 0px); }
body { margin: 0; background: var(--bg); color: var(--ink); font: 15px/1.5 "Public Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; font-variant-numeric: tabular-nums; }
body::before { content: ""; position: fixed; inset: 0 0 auto; height: env(safe-area-inset-top, 0px); z-index: 10; background: var(--surface); }
h1 { font-size: 1.5rem; line-height: 1.2; margin: 0; font-weight: 700; letter-spacing: -0.01em; }
h2 { font-size: 1.15rem; margin: 0; font-weight: 650; }
h3 { font-size: 1rem; margin: 1.5rem 0 .5rem; font-weight: 650; }
h4 { font-size: .9rem; margin: 1.25rem 0 .5rem; font-weight: 650; color: var(--muted); }
p { margin: .5rem 0; max-width: 75ch; }
.muted { color: var(--muted); } .small { font-size: .82rem; } .mono { font-family: ui-monospace, "SF Mono", Menlo, monospace; font-size: .85em; }
.err { color: var(--red); } .warntext { color: var(--orange); }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }

/* controls */
button { font: inherit; font-size: .9rem; font-weight: 550; border: 1px solid var(--line); background: var(--surface); color: var(--ink); border-radius: var(--r); padding: .45rem .85rem; cursor: pointer; white-space: nowrap; }
button:hover:not(:disabled) { border-color: var(--muted); }
button:disabled { opacity: .45; cursor: default; }
button.primary { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
button.primary:hover:not(:disabled) { filter: brightness(1.08); border-color: var(--accent); }
button.ghost { background: transparent; border-color: transparent; }
button.ghost:hover:not(:disabled) { background: var(--surface2); border-color: var(--line); }
button.danger { color: var(--red); }
button.sm { padding: .2rem .55rem; font-size: .82rem; }
button.icon { padding: .25rem .6rem; font-size: 1.1rem; line-height: 1; }
button.block { width: 100%; margin-top: 1rem; }
input, select, textarea { font: inherit; font-size: .9rem; color: var(--ink); background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: .4rem .55rem; min-width: 0; max-width: 100%; }
input[type="checkbox"] { accent-color: var(--accent); width: 1rem; height: 1rem; }
input[type="color"] { padding: 0; height: 2.1rem; width: 4rem; }
input:disabled, select:disabled { background: var(--surface2); color: var(--muted); }
.field { display: flex; flex-direction: column; gap: .25rem; min-width: 0; }
.field.wide { grid-column: 1 / -1; }
.flabel { font-size: .8rem; font-weight: 600; color: var(--muted); }
.hint { font-size: .78rem; color: var(--muted); }
label.inline { display: inline-flex; align-items: center; gap: .4rem; font-size: .88rem; }
.grid2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: .85rem 1rem; }
.grid4 { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: .85rem 1rem; align-items: start; }
.grid4 > button, .grid4 > label.inline, .grid4 > p { align-self: end; }
.grid4 > button { margin-bottom: 1px; }
.row3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: .6rem; }
.weekgrid { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: .5rem; margin-top: .75rem; }
.actions { display: flex; flex-wrap: wrap; gap: .5rem; align-items: center; margin: .85rem 0; }
.narrow { max-width: 760px; }

/* shell */
.shell { min-height: 100%; }
.top { position: sticky; top: env(safe-area-inset-top, 0px); z-index: 5; background: var(--surface); border-bottom: 1px solid var(--line); display: flex; align-items: center; gap: 1.5rem; padding: .6rem 1.25rem; flex-wrap: wrap; }
.brand { display: flex; align-items: center; gap: .65rem; }
.brand small { display: block; font-size: .75rem; color: var(--muted); font-weight: 400; }
.brand strong { display: block; font-size: .95rem; line-height: 1.15; }
.mark { display: inline-grid; place-items: center; width: 2.4rem; height: 2.4rem; border-radius: 4px; background: var(--accent); color: var(--accent-ink); font-weight: 700; font-size: .78rem; letter-spacing: .04em; }
nav { display: flex; gap: .15rem; overflow-x: auto; flex: 1; scrollbar-width: none; }
nav button { border: 0; background: transparent; color: var(--muted); padding: .5rem .75rem; border-radius: var(--r); }
nav button:hover { color: var(--ink); background: var(--surface2); }
nav button.on { color: var(--ink); background: var(--accent-soft); box-shadow: inset 0 -2px 0 var(--accent); border-radius: var(--r) var(--r) 0 0; }
.role { color: var(--muted); font-size: .88rem; }
main { padding: 1.25rem; max-width: 1440px; margin: 0 auto; }
.bar { display: flex; flex-wrap: wrap; gap: .75rem 1rem; align-items: center; justify-content: space-between; margin-bottom: .75rem; }
.bar.sub { margin: .5rem 0; }
.tools { display: flex; flex-wrap: wrap; gap: .5rem; align-items: center; }
.tabs { display: flex; gap: .15rem; flex-wrap: wrap; border-bottom: 1px solid var(--line); }
.tabs button { border: 0; background: transparent; border-radius: 0; color: var(--muted); padding: .45rem .75rem; box-shadow: inset 0 -2px 0 transparent; }
.tabs button.on { color: var(--ink); box-shadow: inset 0 -2px 0 var(--accent); }
.boot { display: grid; place-items: center; gap: .5rem; min-height: 70vh; text-align: center; padding: 2rem; }

/* calendar */
.monthnav { display: flex; align-items: center; gap: .25rem; }
.monthnav h1 { min-width: 11ch; text-align: center; }
.cal { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: var(--r); overflow: hidden; }
.calh { background: var(--surface2); padding: .35rem .6rem; font-size: .78rem; font-weight: 600; color: var(--muted); }
.calpad { background: var(--surface2); }
.calday { all: unset; box-sizing: border-box; background: var(--surface); min-height: 7.2rem; padding: .4rem .45rem; display: flex; flex-direction: column; gap: .3rem; cursor: pointer; position: relative; }
.calday:hover { background: var(--surface2); }
.calday:focus-visible { outline: 2px solid var(--focus); outline-offset: -2px; }
.calday.today .dnum { background: var(--accent); color: var(--accent-ink); }
.dnum { font-weight: 650; font-size: .85rem; width: 1.6rem; height: 1.6rem; display: grid; place-items: center; border-radius: 50%; }
.dcount { position: absolute; top: .5rem; right: .5rem; font-size: .72rem; color: var(--muted); }
.dchips { display: flex; flex-wrap: wrap; gap: 3px; }
.more { font-size: .72rem; color: var(--muted); align-self: center; }
.chip { display: inline-block; font-size: .72rem; font-weight: 650; line-height: 1.3; padding: .05rem .35rem; border-radius: 3px; border-left: 3px solid var(--c);
  background: color-mix(in srgb, var(--c) 16%, var(--surface)); color: var(--ink); white-space: nowrap; }
.chip.draft { background: transparent; border: 1px dashed var(--c); border-left-width: 3px; }
.legend { display: flex; align-items: center; gap: .5rem; }

/* modal */
.scrim { position: fixed; inset: 0; background: rgb(10 14 20 / .5); display: grid; place-items: start center; padding: calc(env(safe-area-inset-top, 0px) + 3vh) 1rem 1rem; z-index: 20; overflow-y: auto; }
.modal { background: var(--surface); border: 1px solid var(--line); border-radius: 10px; width: min(640px, 100%); box-shadow: 0 20px 50px rgb(0 0 0 / .25); }
.modal.wide { width: min(1120px, 100%); }
.modal header { display: flex; justify-content: space-between; align-items: center; padding: .85rem 1.1rem; border-bottom: 1px solid var(--line); position: sticky; top: 0; background: var(--surface); border-radius: 10px 10px 0 0; z-index: 1; }
.mbody { padding: 1rem 1.1rem 1.25rem; }
.split { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); gap: 1.25rem; }
.split h3 { margin-top: 0; }
.panel { background: var(--surface2); border: 1px solid var(--line); border-radius: var(--r); padding: .9rem 1rem; margin: .75rem 0; }
.split .panel { margin: 0; }
.shiftgroup { border-top: 1px solid var(--line); padding: .5rem 0; }
.sghead { display: flex; align-items: center; gap: .5rem; font-size: .88rem; font-weight: 600; margin-bottom: .25rem; }
.arow { display: flex; flex-wrap: wrap; gap: .25rem .75rem; align-items: center; padding: .3rem 0 .3rem .4rem; font-size: .88rem; }
.arow .who { font-weight: 550; min-width: 9rem; }
.arow .acts { margin-left: auto; }
.arow.editing input { width: auto; }
.status { font-size: .74rem; padding: .05rem .4rem; border-radius: 3px; background: var(--surface2); color: var(--muted); border: 1px solid var(--line); }
.status.published, .status.confirmed { background: var(--ok-bg); color: var(--ok); border-color: transparent; }
.status.planned, .status.draft { background: var(--orange-bg); color: var(--orange); border-color: transparent; }
.status.cancelled { text-decoration: line-through; }
.warnmark { font-size: .74rem; color: var(--orange); font-weight: 600; }
.copyrow { display: flex; align-items: end; gap: .5rem; margin-top: 1rem; }

/* checks */
.checks { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: .35rem; max-height: 300px; overflow-y: auto; padding: 2px; }
.check { display: grid; grid-template-columns: auto 1fr; column-gap: .45rem; align-items: center; border: 1px solid var(--line); border-radius: var(--r); padding: .35rem .5rem; cursor: pointer; background: var(--surface); font-size: .86rem; }
.check small { grid-column: 2; color: var(--muted); font-size: .74rem; line-height: 1.25; }
.check.on { border-color: var(--accent); background: var(--accent-soft); }
.check.warn small { color: var(--orange); }

/* tables */
.tablewrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--r); background: var(--surface); }
.tablewrap.tall { max-height: 60vh; overflow-y: auto; }
table { width: 100%; border-collapse: collapse; font-size: .88rem; }
th { text-align: left; font-size: .78rem; font-weight: 600; color: var(--muted); background: var(--surface2); padding: .5rem .65rem; border-bottom: 1px solid var(--line); position: sticky; top: 0; white-space: nowrap; }
td { padding: .5rem .65rem; border-bottom: 1px solid var(--line); vertical-align: top; }
tr:last-child td { border-bottom: 0; }
th.n, td.n { text-align: right; } th.c, td.c { text-align: center; }
tr.click { cursor: pointer; } tr.click:hover td { background: var(--surface2); }
tr.total td { font-weight: 650; background: var(--surface2); }
tr.bench td { background: var(--surface2); font-weight: 600; }
tr.inactive td { color: var(--muted); }
td.acts { white-space: nowrap; }
td.detail { max-width: 46ch; overflow-wrap: anywhere; }
table.att th.c { font-size: .7rem; }
.matrix td.cell.orange { background: var(--orange-bg); color: var(--orange); font-weight: 600; }
.matrix td.cell.red { background: var(--red-bg); color: var(--red); font-weight: 600; }
.matrix td.cell.review { background: repeating-linear-gradient(135deg, transparent 0 6px, var(--orange-bg) 6px 12px); }
tr.imp.error td { color: var(--red); } tr.imp.conflict td, tr.imp.duplicate td { color: var(--orange); } tr.imp.same td { color: var(--muted); }
.flag { font-size: .74rem; font-weight: 650; padding: .08rem .45rem; border-radius: 3px; display: inline-block; }
.flag.normal { background: var(--ok-bg); color: var(--ok); } .flag.orange { background: var(--orange-bg); color: var(--orange); }
.flag.red { background: var(--red-bg); color: var(--red); } .flag.na, .flag.hidden { background: var(--surface2); color: var(--muted); }
.flag.review { border: 1px dashed var(--orange); color: var(--orange); }
.legendrow { display: flex; flex-wrap: wrap; gap: .4rem .6rem; align-items: center; font-size: .82rem; color: var(--muted); }
.vstat { font-size: .78rem; font-weight: 600; } .vstat.valid { color: var(--ok); } .vstat.held, .vstat.partial { color: var(--orange); } .vstat.invalid { color: var(--red); }

/* results entry */
.outgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: .4rem; }
.out { display: flex; justify-content: space-between; align-items: center; gap: .5rem; padding: .4rem .55rem; border: 1px solid var(--line); border-left-width: 4px; border-radius: var(--r); }
.out span { display: flex; flex-direction: column; } .out small { color: var(--muted); font-size: .72rem; }
.out.pass { border-left-color: var(--ok); } .out.fail { border-left-color: var(--red); } .out.pending, .out.absent { border-left-color: var(--orange); }
.quick { display: flex; gap: .5rem; align-items: end; margin-bottom: .75rem; } .quick .field { flex: 1; }

/* misc */
.notice { background: var(--accent-soft); border: 1px solid var(--line); border-radius: var(--r); padding: .7rem .9rem; margin: .75rem 0; font-size: .9rem; max-width: 900px; }
.notice.warn { background: var(--orange-bg); border-color: transparent; }
.empty { border: 1px dashed var(--line); border-radius: var(--r); padding: 2.25rem 1.5rem; text-align: center; color: var(--muted); }
.empty strong { color: var(--ink); display: block; margin-bottom: .25rem; }
.empty p { margin: 0 auto; }
.upload { display: inline-flex; border: 1px dashed var(--muted); border-radius: var(--r); padding: .9rem 1.2rem; cursor: pointer; gap: .5rem; align-items: center; margin: .5rem 0; }
.upload input { max-width: 15rem; }
.pillrow { display: flex; flex-wrap: wrap; gap: .4rem; margin: .5rem 0 .75rem; }
.pill { font-size: .8rem; padding: .2rem .55rem; border-radius: 999px; background: var(--surface); border: 1px solid var(--line); }
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: .75rem; margin: .75rem 0; }
.stat { background: var(--surface); border: 1px solid var(--line); border-top: 3px solid var(--accent); border-radius: var(--r); padding: .8rem .95rem; display: flex; flex-direction: column; gap: .1rem; }
.stat .big { font-size: 1.7rem; font-weight: 700; line-height: 1.1; letter-spacing: -0.02em; }
.stat > span:not(.big) { font-weight: 600; font-size: .88rem; }
.stat small { color: var(--muted); font-size: .78rem; }
.picker { position: relative; max-width: 380px; } .picker input { width: 100%; }
.picker ul { list-style: none; margin: .25rem 0 0; padding: .25rem; border: 1px solid var(--line); border-radius: var(--r); background: var(--surface); }
.picker li button { width: 100%; text-align: left; }
.toast { position: fixed; bottom: calc(env(safe-area-inset-bottom, 0px) + 1rem); left: 50%; transform: translateX(-50%); background: var(--ink); color: var(--surface); padding: .6rem 1rem; border-radius: var(--r); z-index: 40; font-size: .9rem; max-width: min(90vw, 640px); box-shadow: 0 8px 24px rgb(0 0 0 / .25); }
.toast.err { background: var(--red); color: #fff; }

@media (max-width: 860px) {
  main { padding: .85rem; }
  .split { grid-template-columns: 1fr; }
  .calday { min-height: 4.4rem; padding: .25rem; }
  .dchips .chip { font-size: .62rem; padding: 0 .2rem; }
  .calh { padding: .3rem; font-size: .7rem; }
  .weekgrid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .row3 { grid-template-columns: 1fr 1fr; }
  .top { gap: .5rem; padding: .5rem .85rem; }
  nav { flex-basis: 100%; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; animation: none !important; } }

/* sign-in and account */
.auth { min-height: 100vh; display: grid; place-items: center; padding: 1.5rem; }
.authcard { width: min(400px, 100%); background: var(--surface); border: 1px solid var(--line); border-radius: 10px; padding: 1.5rem; display: flex; flex-direction: column; gap: .85rem; }
.authcard h1 { margin-top: .5rem; }
.stack { display: flex; flex-direction: column; gap: .85rem; }
.usermenu { display: flex; align-items: center; gap: .25rem; margin-left: auto; }
.cred { display: flex; flex-wrap: wrap; gap: .5rem 1.5rem; margin: .6rem 0; font-size: 1rem; }
.cred b { background: var(--surface); padding: .1rem .4rem; border-radius: 4px; border: 1px solid var(--line); }
@media (max-width: 860px) { .usermenu { margin-left: 0; } }

/* v1.3 additions */
.seg { display: inline-flex; border: 1px solid var(--line); border-radius: var(--r); overflow: hidden; flex-wrap: wrap; }
.seg button { border: 0; border-radius: 0; background: var(--surface); color: var(--muted); }
.seg button + button { border-left: 1px solid var(--line); }
.seg button.on { background: var(--accent-soft); color: var(--ink); box-shadow: inset 0 -2px 0 var(--accent); }
table.reg td { white-space: nowrap; }
.issue { border: 1px solid var(--line); border-left: 4px solid var(--orange); border-radius: var(--r); padding: .6rem .8rem; margin: .6rem 0; background: var(--surface2); }
.issue.leave { border-left-color: var(--red); }
.issue p { margin: 0 0 .5rem; }
.rooms { display: grid; grid-template-columns: repeat(auto-fill, minmax(400px, 1fr)); gap: .75rem; margin: .75rem 0; }
.room { border: 1px solid var(--line); border-radius: var(--r); padding: .75rem; background: var(--surface); }
.roomhead { display: flex; align-items: center; gap: .6rem; margin: .75rem 0 .25rem; }
.roomhead button { margin-left: auto; }
ol.order { list-style: none; margin: 0 0 .6rem; padding: 0; }
ol.order li { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: .6rem; padding: .4rem .25rem; border-bottom: 1px solid var(--line); font-size: .88rem; }
ol.order li.dupe { background: var(--orange-bg); }
ol.order .pos { display: inline-grid; place-items: center; width: 1.7rem; height: 1.7rem; border-radius: 50%; background: var(--accent-soft); font-weight: 650; font-size: .78rem; }
ol.order .who { display: flex; flex-direction: column; min-width: 0; }
ol.order .nm { font-weight: 550; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
ol.order .who small { font-size: .75rem; }
ol.order .acts { display: flex; gap: .1rem; align-items: center; }
ol.order select { font-size: .78rem; padding: .15rem .3rem; max-width: 7.5rem; }
@media (max-width: 520px) { .rooms { grid-template-columns: 1fr; } }
.assess > * { min-width: 0; }
.assess { display: grid; grid-template-columns: minmax(220px, 280px) minmax(0, 1fr); gap: 1rem; margin-top: 1rem; }
.clist { display: flex; flex-direction: column; gap: .5rem; }
.clist ul { list-style: none; margin: 0; padding: 0; max-height: 65vh; overflow-y: auto; border: 1px solid var(--line); border-radius: var(--r); background: var(--surface); }
.clist li button { width: 100%; text-align: left; border: 0; border-bottom: 1px solid var(--line); border-radius: 0; display: flex; flex-direction: column; align-items: flex-start; gap: .1rem; white-space: normal; }
.clist li button small { color: var(--muted); font-weight: 400; font-size: .75rem; }
.clist li button.on { background: var(--accent-soft); box-shadow: inset 3px 0 0 var(--accent); }
tr.entryrow td { background: var(--surface2); }
.entry { display: flex; flex-wrap: wrap; gap: .6rem; align-items: end; }
.entry .field { min-width: 9rem; } .entry .field.wide { flex: 1; min-width: 14rem; }
.areport td.acell { cursor: pointer; min-width: 3rem; }
.areport td.acell:hover { outline: 2px solid var(--focus); outline-offset: -2px; }
.areport td.acell.exempted { color: var(--muted); font-style: italic; }
.areport td.acell.na { color: var(--muted); }
@media (max-width: 860px) { .assess { grid-template-columns: 1fr; } .clist ul { max-height: 30vh; } }

.nowrap { white-space: nowrap; }

/* v1.3.2 attendance and demand */
td.wrap { white-space: normal; min-width: 14rem; }
.attpanel { border-top: 1px solid var(--line); margin-top: 1rem; padding-top: .25rem; }
.crmnote { margin: .5rem 0; padding: .6rem .8rem; border-left: 4px solid var(--accent); background: var(--surface2); border-radius: 0 var(--r) var(--r) 0; display: flex; flex-direction: column; gap: .2rem; }
.daygrid { display: flex; flex-wrap: wrap; gap: .4rem; margin: .5rem 0; }
.dayc { display: flex; flex-direction: column; align-items: center; gap: .1rem; border: 1px solid var(--line); border-radius: var(--r); padding: .4rem .7rem; cursor: pointer; background: var(--surface); min-width: 5.5rem; }
.dayc input { margin: 0 0 .15rem; }
.dayc small { color: var(--muted); font-size: .74rem; }
.dayc.on { border-color: var(--accent); background: var(--accent-soft); }
details.sub { margin: .75rem 0; }
details.sub summary { cursor: pointer; font-weight: 600; font-size: .9rem; color: var(--accent); }
.extra { border: 1px solid var(--line); border-radius: var(--r); padding: .6rem; margin: .5rem 0; background: var(--surface); }
.dday { margin-bottom: 1.25rem; }
.dday h3 { margin-bottom: .4rem; }
.dday .tablewrap + .tablewrap { margin-top: .5rem; }

/* staffing demand */
.demandcal .calday { min-height: 6.4rem; }
.dem { font-size: .76rem; line-height: 1.25; display: block; }
.dem b { font-size: .95rem; }
.dem.short { color: var(--red); font-weight: 650; }
.dem.ok { color: var(--ok); }
.appr { position: absolute; top: .45rem; right: .55rem; color: var(--ok); font-weight: 700; }
.driftmark { position: absolute; top: .45rem; right: 1.6rem; color: var(--orange); font-weight: 800; }
.numin { width: 4.2rem; text-align: right; }
tr.needs td { background: var(--orange-bg); }

.checks.wd { grid-template-columns: repeat(7, minmax(0, 1fr)); max-height: none; }
.checks.wd .check { padding: .25rem .3rem; font-size: .78rem; }
.bulkbar { display: flex; flex-wrap: wrap; align-items: center; gap: .6rem; margin: .5rem 0; padding: .5rem .7rem; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); }
.okline { color: var(--ok); }
.hidden { display: none !important; }
.viewbar { display: flex; flex-wrap: wrap; gap: .6rem 1rem; align-items: end; margin: .75rem 0 .25rem; padding: .6rem .75rem; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); }
.viewbar .field { min-width: 12rem; }
.hidebox { align-self: center; } .hidebox summary { cursor: pointer; font-size: .9rem; font-weight: 600; color: var(--accent); }
.hidebox .checks { max-width: 640px; margin-top: .4rem; }
tr.warnrow td { background: color-mix(in srgb, var(--orange-bg) 60%, transparent); }
table.alloc select { max-width: 11rem; } .roomin { width: 5rem; } .skillpick { display: flex; align-items: center; gap: .35rem; flex-wrap: wrap; }
.trendwrap { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: .5rem .75rem; margin: .5rem 0 .75rem; }
svg.trend { width: 100%; height: auto; display: block; }
svg.trend .grid { stroke: var(--line); stroke-width: 1; } svg.trend .axis { fill: var(--muted); font-size: 12px; }
svg.trend .series polyline { fill: none; stroke-width: 2.5; } svg.trend .series circle { stroke: var(--surface); stroke-width: 2; }
svg.trend .series.all polyline { stroke: var(--muted); stroke-dasharray: 5 4; } svg.trend .series.all circle { fill: var(--muted); }
svg.trend .series.who polyline { stroke: var(--accent); } svg.trend .series.who circle { fill: var(--accent); }
.key::before { content: ""; display: inline-block; width: 1.4rem; height: 3px; margin-right: .35rem; vertical-align: middle; background: var(--muted); }
.key.who::before { background: var(--accent); } tr.hl td { font-weight: 650; }
.histbar { display: flex; justify-content: flex-end; margin: -.25rem 0 .5rem; }
table.diff td.old { color: var(--red); text-decoration: line-through; text-decoration-thickness: 1px; } table.diff td.new { color: var(--ok); }
table.diff td { overflow-wrap: anywhere; } .detailpre { background: var(--surface2); border: 1px solid var(--line); border-radius: var(--r); padding: .6rem; font-size: .78rem; max-height: 40vh; overflow: auto; white-space: pre-wrap; }
.sharebtns { display: inline-flex; gap: .35rem; flex-wrap: wrap; align-items: center; }
a.btnlink { display: inline-flex; align-items: center; padding: .25rem .6rem; border: 1px solid var(--line); border-radius: var(--r); color: var(--accent); font-weight: 600; font-size: .85rem; text-decoration: none; background: var(--surface); }
a.btnlink:hover { background: var(--surface2); }
