.capacity-day{display:block;margin:5px auto 0;padding:4px 7px;border-radius:8px;border:1px solid currentColor;font:inherit;font-size:11px;line-height:1.4;cursor:pointer;max-width:100%;white-space:normal}.capacity-day small{display:block;font-size:10px}.capacity-ok{color:#166534;background:#effaf2}.capacity-overlap{color:#854d0e;background:#fff5d6}.capacity-exceeded{color:#b91c1c;background:#fee2e2}.capacity-summary{margin:8px 0;padding:8px 12px;border-radius:8px;font-size:13px}.capacity-overlay{position:fixed;inset:0;background:#0008;z-index:20000;display:flex;align-items:center;justify-content:center;padding:16px}.capacity-dialog{background:var(--card-bg,#fff);color:var(--text,#172033);width:min(620px,100%);max-height:90vh;overflow:auto;padding:22px;border-radius:16px;box-shadow:0 18px 70px #0005}.capacity-dialog h3{margin:0 0 12px}.capacity-dialog p{font-size:14px;line-height:1.5}.capacity-dialog label{display:block;font-size:13px;margin:8px 0}.capacity-dialog input:not([type=checkbox]),.capacity-dialog select,.capacity-dialog textarea{display:block;box-sizing:border-box;width:100%;padding:9px;margin-top:5px;font:inherit;border:1px solid #94a3b8;border-radius:7px;background:var(--input-bg,#fff);color:inherit}.capacity-fields{display:flex;gap:12px;flex-wrap:wrap}.capacity-fields>label{flex:1;min-width:110px}.capacity-actions{display:flex;flex-wrap:wrap;gap:8px;justify-content:flex-end;margin-top:18px}.capacity-weekdays{display:flex;flex-wrap:wrap;gap:12px}.capacity-status{font-size:13px;color:#b91c1c}.capacity-range[hidden]{display:none}html[data-theme=dark] .capacity-dialog,body.dark-mode .capacity-dialog{background:#172033;color:#edf2f7}html[data-theme=dark] .capacity-dialog input,html[data-theme=dark] .capacity-dialog select,html[data-theme=dark] .capacity-dialog textarea{background:#253247;color:#edf2f7}

.day-heatbar .capacity-heat-overlap{background:#f59e0b!important;opacity:1!important}.day-heatbar .capacity-heat-exceeded{background:#dc2626!important;opacity:1!important}

html.zr-soft-dark .capacity-dialog{background:#172033;color:#edf2f7}html.zr-soft-dark .capacity-dialog input:not([type=checkbox]),html.zr-soft-dark .capacity-dialog select,html.zr-soft-dark .capacity-dialog textarea{background:#253247;color:#edf2f7}

/* Keep the limit below the day score instead of sharing its bottom position. */
.week-day-head:has(.capacity-day) .week-day-icons{
  position:relative;
  bottom:auto;
  min-height:22px;
  margin:0 auto 8px;
}
.week-day-head .capacity-day{
  position:relative;
  z-index:3;
  margin:6px auto 10px;
}
