/* One continuous Excel-style ledger. No responsive splitting or hidden columns. */
main:has(.week-workspace) .report-tabs {
  flex-wrap: wrap;
  overflow: visible;
  width: fit-content;
}
.week-workspace {
  --week-ink: #17354d;
  --week-muted: #526a7d;
  --week-line: #dbe5ee;
  display: grid;
  gap: 16px;
  min-width: 0;
  color: var(--week-ink);
  container-type: inline-size;
}
.week-heading {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
}
.week-heading h2 {
  margin: 0;
  font-size: 25px;
  line-height: 1.3;
  letter-spacing: -0.5px;
}
.week-heading p {
  margin: 5px 0 0;
  color: var(--week-muted);
  font-size: 12px;
}
.week-workspace .week-export {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 40px;
  padding: 9px 14px;
  font-size: 13px;
}
.week-export svg {
  width: 16px;
  height: 16px;
}
.week-overview {
  background: white;
  padding: 17px 20px;
  border: 1px solid var(--week-line);
  border-radius: 10px;
  min-width: 0;
}
.week-overview h3 {
  font-size: 12px;
  margin: 0 0 14px;
  font-weight: 600;
}
.week-summary {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 14px;
  margin: 0;
}
.week-summary > div + div {
  border-left: 1px solid #e8eef3;
  padding-left: 14px;
}
.week-summary dt {
  color: var(--week-muted);
  font-size: 11px;
  line-height: 1.5;
  margin-bottom: 5px;
  overflow-wrap: anywhere;
}
.week-summary dd {
  margin: 0;
  font-size: clamp(15px, 1.05vw, 19px);
  font-weight: 650;
  line-height: 1.5;
  font-variant-numeric: tabular-nums;
  overflow-wrap: anywhere;
}
.week-table-frame {
  min-width: 0;
  width: 100%;
  border: 1px solid #cbdbe7;
  border-radius: 10px;
  background: white;
  box-shadow: 0 3px 12px #17354d08;
}
.week-sheet {
  width: var(--week-sheet-width);
  zoom: var(--week-sheet-scale);
}
/* Size synchronously with the window, before any resize callback or paint. */
@supports (zoom: calc(100cqw / 1px)) {
  .week-sheet {
    width: max(var(--week-sheet-minimum), calc(100cqw - 2px));
    zoom: min(1, calc((100cqw - 2px) / var(--week-sheet-minimum)));
  }
}
.week-workspace table.week-ledger {
  display: table;
  width: 100%;
  min-width: 0;
  table-layout: fixed;
  border-collapse: separate;
  border-spacing: 0;
  margin: 0;
}
.week-workspace .week-ledger thead {
  display: table-header-group;
}
.week-workspace .week-ledger tbody {
  display: table-row-group;
}
.week-workspace .week-ledger tfoot {
  display: table-footer-group;
}
.week-workspace .week-ledger tr {
  display: table-row;
  width: auto;
  padding: 0;
  border: 0;
  margin: 0;
}
.week-workspace .week-ledger :is(th, td) {
  display: table-cell;
  width: auto;
  min-width: 0;
  max-width: none;
  padding: 13px 6px;
  vertical-align: middle;
  border: 0;
  border-bottom: 1px solid #e5edf3;
  line-height: 1.5;
  font-size: 11px;
  overflow-wrap: normal;
  word-break: normal;
  background: white;
}
.week-workspace .week-ledger td:before {
  display: none;
}
.week-workspace .week-ledger thead th {
  position: static;
  color: #39566c;
  font-size: 10.5px;
  font-weight: 650;
  white-space: normal;
}
.week-workspace .week-ledger .week-group-headings th {
  background: #173e5a;
  color: #fff;
  text-align: left;
  height: 36px;
  padding: 8px 10px;
  font-size: 11px;
  border-bottom: 2px solid #2293c9;
}
.week-workspace .week-ledger .week-group-headings th + th {
  border-left: 1px solid #416580;
}
.week-workspace .week-ledger .week-group-headings th:first-child {
  border-top-left-radius: 9px;
}
.week-workspace .week-ledger .week-group-headings th:last-child {
  border-top-right-radius: 9px;
}
.week-workspace .week-ledger .week-column-headings th {
  background: #edf4f9;
  height: 55px;
  border-bottom: 1px solid #c6d9e8;
}
.week-workspace .week-ledger :is(th, td) + :is(th, td) {
  border-left: 1px solid #edf2f6;
}
.week-workspace .week-ledger :is(th, td).week-group-start {
  border-left: 1.5px solid #bfd3e2;
}
.week-workspace .week-ledger .week-text {
  text-align: left;
  white-space: normal;
  hyphens: none;
}
.week-workspace .week-ledger td.week-text {
  overflow-wrap: anywhere;
  color: #3e566b;
}
.week-workspace .week-ledger td[data-field="title"] {
  color: #17354d;
  font-weight: 600;
}
.week-workspace .week-ledger .week-numeric {
  text-align: right;
  font-variant-numeric: tabular-nums;
  font-weight: 500;
  white-space: nowrap;
}
.week-workspace .week-ledger thead .week-numeric {
  white-space: normal;
}
.week-workspace .week-ledger td[data-field="number"] {
  white-space: nowrap;
}
.week-workspace .week-ledger tbody tr:nth-child(even) td {
  background: #f8fbfd;
}
.week-workspace .week-ledger tbody tr:is(:hover, :focus-within) td {
  background: #eaf5fc;
}
.week-workspace .week-ledger tbody td {
  transition: background-color 140ms ease;
}
.week-workspace .week-ledger tbody tr:last-child td {
  border-bottom: 0;
}
.week-workspace .week-ledger tfoot :is(th, td) {
  background: #eaf3f9;
  border-top: 2px solid #b6cedf;
  border-bottom: 0;
  padding-top: 15px;
  padding-bottom: 15px;
  font-weight: 700;
}
.week-workspace .week-ledger tfoot th {
  text-align: left;
  padding-left: 10px;
  font-size: 11px;
}
.week-workspace
  .week-ledger
  :is(tfoot, tbody:last-child)
  tr:last-child
  > :first-child {
  border-bottom-left-radius: 9px;
}
.week-workspace
  .week-ledger
  :is(tfoot, tbody:last-child)
  tr:last-child
  > :last-child {
  border-bottom-right-radius: 9px;
}
.week-workspace :is(.report-value, .week-project-link) {
  display: inline;
  min-height: 0;
  min-width: 0;
  max-width: none;
  margin: 0;
  padding: 0;
  border: 0;
  box-shadow: none;
  background: transparent;
  color: #096ca3;
  font: inherit;
  text-align: inherit;
  white-space: inherit;
}
.week-workspace .week-project-link {
  font-weight: 650;
}
.week-workspace :is(.report-value, .week-project-link):hover {
  color: #064972;
  text-decoration: underline;
  text-underline-offset: 3px;
}
.week-workspace :is(.report-value, .week-project-link):focus-visible {
  outline: 2px solid #1884c3;
  outline-offset: 2px;
  border-radius: 2px;
}
.week-workspace .week-ledger .is-gain,
.week-workspace .is-gain {
  color: #20704e;
}
.week-workspace .week-ledger .is-loss,
.week-workspace .is-loss {
  color: #b13c43;
}
.week-workspace .week-ledger .week-empty {
  padding: 32px 16px;
  text-align: center;
  color: var(--week-muted);
}
@container (max-width: 850px) {
  .week-summary {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
  .week-summary > div:nth-child(5) {
    border-left: 0;
    padding-left: 0;
  }
}
@container (max-width: 460px) {
  .week-summary {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .week-summary > div:nth-child(odd) {
    border-left: 0;
    padding-left: 0;
  }
}
@media (prefers-reduced-motion: reduce) {
  .week-workspace .week-ledger tbody td {
    transition: none;
  }
}
@media print {
  .week-export {
    display: none !important;
  }
  .week-table-frame {
    box-shadow: none;
  }
}
