:root {
  --bg: #edf2f8;
  --panel: rgba(255, 255, 255, 0.88);
  --panel-solid: #ffffff;
  --panel-soft: #f4f7fb;
  --nav: #10213b;
  --nav-line: rgba(255, 255, 255, 0.08);
  --ink: #14243b;
  --muted: #6c7b92;
  --line: rgba(20, 36, 59, 0.1);
  --line-strong: rgba(20, 36, 59, 0.18);
  --accent: #21bdd0;
  --accent-soft: rgba(33, 189, 208, 0.12);
  --danger: #ef5b4c;
  --danger-soft: rgba(239, 91, 76, 0.12);
  --warning: #f0a02e;
  --warning-soft: rgba(240, 160, 46, 0.16);
  --shadow: 0 22px 60px rgba(17, 28, 46, 0.12);
  --radius-xl: 28px;
  --radius-lg: 22px;
  --radius-md: 16px;
  --radius-sm: 12px;
  --font-sans: "Segoe UI Variable", "Bahnschrift", "Trebuchet MS", sans-serif;
  --font-mono: "Cascadia Code", "JetBrains Mono", monospace;
}

* {
  box-sizing: border-box;
  scrollbar-width: none;
}

*::-webkit-scrollbar {
  width: 0;
  height: 0;
}

html,
body {
  margin: 0;
  min-height: 100%;
}

body {
  font-family: var(--font-sans);
  color: var(--ink);
  background:
    radial-gradient(circle at top center, rgba(33, 189, 208, 0.08), transparent 28rem),
    linear-gradient(180deg, #f4f7fb 0%, #edf2f8 100%);
}

button,
input,
select,
textarea {
  font: inherit;
}

button,
input,
select,
textarea,
summary {
  outline: none;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.app-shell {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr) 332px;
  width: min(1520px, calc(100vw - 28px));
  min-height: calc(100vh - 28px);
  margin: 14px auto;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: var(--radius-xl);
  background: rgba(255, 255, 255, 0.54);
  box-shadow: 0 32px 90px rgba(22, 36, 58, 0.14);
  backdrop-filter: blur(18px);
}

.sidebar {
  display: grid;
  grid-template-rows: auto auto 1fr auto;
  gap: 14px;
  padding: 18px;
  background: linear-gradient(180deg, #10213b 0%, #182846 100%);
}

.sidebar__search input {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--nav-line);
  border-radius: 14px;
  color: #f4f8ff;
  background: rgba(255, 255, 255, 0.06);
}

.sidebar__search input::placeholder {
  color: rgba(244, 248, 255, 0.48);
}

.sidebar__toggle {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 14px;
  color: rgba(244, 248, 255, 0.88);
  background: rgba(255, 255, 255, 0.05);
  cursor: pointer;
}

.sidebar__toggle input {
  accent-color: var(--accent);
}

.group-list,
.imports__list {
  display: grid;
  gap: 8px;
  align-content: start;
  overflow: auto;
}

.group-section {
  display: grid;
  gap: 8px;
}

.group-section__toggle {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  width: 100%;
  padding: 4px 6px 0;
  border: none;
  color: rgba(244, 248, 255, 0.72);
  background: transparent;
  cursor: pointer;
  text-align: left;
}

.group-section__title {
  margin: 0;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(244, 248, 255, 0.5);
}

.group-section__meta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.group-section__badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 24px;
  padding: 3px 7px;
  border-radius: 999px;
  font-size: 0.75rem;
  color: rgba(244, 248, 255, 0.84);
  background: rgba(255, 255, 255, 0.08);
}

.group-section__chevron {
  width: 16px;
  text-align: center;
  font-size: 0.95rem;
  color: rgba(244, 248, 255, 0.6);
}

.group-section__items {
  display: grid;
  gap: 8px;
}

.group-section.is-collapsed .group-section__items,
.group-section__items.is-hidden {
  display: none;
}

.group-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  width: 100%;
  padding: 12px 13px;
  border: 1px solid transparent;
  border-radius: 14px;
  color: rgba(244, 248, 255, 0.92);
  background: transparent;
  cursor: pointer;
  text-align: left;
  transition: transform 140ms ease, background 140ms ease, border-color 140ms ease;
}

.group-link:hover,
.employee-card:hover,
.calendar-cell:hover,
.action-button:hover,
.icon-button:hover,
.tab:hover {
  transform: translateY(-1px);
}

.group-link.is-active {
  border-color: rgba(33, 189, 208, 0.4);
  background: rgba(255, 255, 255, 0.08);
}

.group-link__name {
  min-width: 0;
  line-height: 1.16;
}

.group-link__count {
  flex: 0 0 auto;
  padding: 4px 8px;
  border-radius: 999px;
  font-size: 0.82rem;
  color: rgba(244, 248, 255, 0.88);
  background: rgba(255, 255, 255, 0.08);
}

.imports {
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.04);
}

.imports summary {
  padding: 12px 13px;
  cursor: pointer;
  list-style: none;
  color: rgba(244, 248, 255, 0.76);
}

.imports summary::-webkit-details-marker {
  display: none;
}

.imports__list {
  padding: 0 12px 12px;
}

.imports__item {
  display: grid;
  gap: 4px;
  padding: 10px 11px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.06);
}

.imports__item strong {
  color: #f4f8ff;
}

.imports__item small,
.summary-bar__meta,
.summary-stat small,
.employee-card__metric small,
.employee-card__text small,
.detail-stat small,
.detail-panel p,
.detail-day__head small,
.detail-events li,
.report-print p {
  color: var(--muted);
}

.workspace {
  display: grid;
  grid-template-rows: auto 1fr;
  border-inline: 1px solid rgba(20, 36, 59, 0.06);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.74), rgba(248, 250, 252, 0.88));
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 18px 22px;
  border-bottom: 1px solid var(--line);
}

.topbar__month,
.topbar__actions,
.tabs {
  display: flex;
  align-items: center;
  gap: 10px;
}

.topbar__month h1,
.summary-bar h2,
.detail-panel h3,
.dialog h3,
.report-print h1 {
  margin: 0;
  line-height: 1;
}

.topbar__month h1 {
  font-size: 1.8rem;
  letter-spacing: -0.03em;
}

.tabs {
  padding: 4px;
  border-radius: 14px;
  background: #eef3f8;
}

.tab,
.action-button,
.icon-button,
.calendar-cell {
  border: none;
  cursor: pointer;
  transition: transform 140ms ease, background 140ms ease, color 140ms ease, border-color 140ms ease;
}

.tab {
  padding: 9px 16px;
  border-radius: 12px;
  color: var(--muted);
  background: transparent;
  font-weight: 600;
}

.tab__stack,
.report-tab__stack {
  display: grid;
  justify-items: center;
  line-height: 1.02;
}

.tab__hint,
.report-tab__hint {
  font-size: 0.76em;
  font-weight: 600;
}

.tab.is-active {
  color: var(--ink);
  background: #ffffff;
  box-shadow: 0 8px 22px rgba(19, 35, 63, 0.08);
}

.action-button,
.icon-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
}

.action-button {
  padding: 11px 15px;
  color: var(--ink);
  background: #eff3f8;
}

.action-button--dark {
  color: #ffffff;
  background: #13243f;
}

.action-button--danger {
  color: #ffffff;
  background: var(--danger);
}

.icon-button {
  width: 36px;
  height: 36px;
  color: var(--muted);
  background: transparent;
  font-size: 1.7rem;
}

.icon-button:disabled {
  opacity: 0.34;
  cursor: default;
  transform: none;
}

.workspace__body {
  display: grid;
  grid-template-rows: auto 1fr;
  gap: 18px;
  min-height: 0;
  padding: 18px 22px 22px;
  overflow: auto;
}

.summary-bar {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  grid-template-areas:
    "head head"
    "stats actions";
  gap: 16px;
  align-items: start;
  padding: 16px 18px;
  border-radius: var(--radius-lg);
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 14px 34px rgba(17, 28, 46, 0.06);
}

.summary-bar__head {
  grid-area: head;
  display: grid;
  align-content: start;
}

.summary-bar__title-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 18px;
  min-width: 0;
}

.summary-bar__meta {
  flex: 0 0 auto;
  font-size: 0.92rem;
  font-weight: 600;
  text-align: right;
  white-space: nowrap;
}

.summary-bar h2 {
  flex: 1 1 auto;
  min-width: 0;
  font-size: 1.28rem;
  line-height: 1.05;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.summary-bar__stats {
  grid-area: stats;
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: nowrap;
  min-width: 0;
}

.summary-bar__actions {
  grid-area: actions;
  display: flex;
  align-items: center;
  gap: 10px;
  justify-content: flex-end;
  align-self: end;
}

.summary-stat,
.detail-stat {
  display: grid;
  gap: 4px;
  min-width: 102px;
  padding: 10px 12px;
  border-radius: 14px;
  background: var(--panel-soft);
}

.summary-stat strong,
.detail-stat strong,
.employee-card__metric strong {
  font-family: var(--font-mono);
  font-size: 0.96rem;
}

.detail-stat strong {
  font-family: var(--font-sans);
  font-size: 0.92rem;
  line-height: 1.08;
  letter-spacing: -0.02em;
}

.employee-board {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  align-content: start;
}

.employee-card {
  display: grid;
  gap: 10px;
  padding: 12px;
  border: 1px solid transparent;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 10px 28px rgba(17, 28, 46, 0.06);
}

.employee-card.is-active {
  border-color: rgba(33, 189, 208, 0.42);
  box-shadow: inset 0 0 0 1px rgba(33, 189, 208, 0.12), 0 16px 34px rgba(33, 189, 208, 0.08);
}

.employee-card.is-hidden {
  opacity: 0.68;
}

.employee-card__top {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.employee-card__bottom {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.employee-card__identity {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  min-width: 0;
}

.employee-card__avatar,
.detail-panel__avatar {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  color: #ffffff;
  background: linear-gradient(135deg, #1eb9cb, #124f67);
  font-weight: 700;
  object-fit: cover;
  overflow: hidden;
}

.employee-card__avatar {
  width: 34px;
  height: 34px;
  flex: 0 0 auto;
  font-size: 0.88rem;
}

.detail-panel__avatar {
  width: 48px;
  height: 48px;
  flex: 0 0 auto;
}

.employee-card__text {
  display: grid;
  gap: 2px;
  min-width: 0;
  flex: 1 1 auto;
}

.employee-card__text strong {
  display: -webkit-box;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: normal;
  line-height: 1.08;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.employee-card__metric {
  display: grid;
  gap: 2px;
  justify-items: end;
  text-align: right;
  white-space: nowrap;
  flex: 0 0 auto;
  align-self: flex-start;
}

.mini-calendar,
.detail-calendar__grid,
.detail-calendar__weekdays {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
}

.mini-calendar,
.detail-calendar__grid {
  gap: 6px;
}

.mini-calendar {
  grid-template-columns: repeat(7, 16px);
  gap: 4px;
  justify-content: start;
  margin-top: 0;
  flex: 0 1 auto;
}

.calendar-cell {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 0;
  aspect-ratio: 1 / 1;
  border: 1px solid transparent;
  border-radius: 11px;
  color: #6d7d94;
  background: #f4f7fb;
  padding: 0;
}

.calendar-cell span {
  font-size: 0.82rem;
  line-height: 1;
}

.calendar-cell--compact {
  width: 16px;
  min-width: 16px;
  height: 16px;
  min-height: 16px;
  border-radius: 7px;
  aspect-ratio: auto;
  box-shadow: none;
}

.calendar-cell--compact span {
  font-size: 0.58rem;
}

.calendar-cell--compact.is-late,
.calendar-cell--compact.is-early,
.calendar-cell--compact.is-overtime,
.calendar-cell--compact.is-late-overtime {
  border-radius: 999px;
}

.calendar-cell--placeholder {
  pointer-events: none;
  background: transparent;
  border-color: transparent;
}

.calendar-cell.is-normal {
  color: var(--ink);
  background: #eff4f8;
}

.calendar-cell.is-empty {
  color: #9eabbc;
  background: #f6f8fb;
}

.calendar-cell.is-weekend {
  color: #b0bac8;
  background: #fbfcfd;
}

.calendar-cell.is-late {
  color: #ffffff;
  background: var(--danger);
}

.calendar-cell.is-early {
  color: #ffffff;
  background: var(--danger);
}

.calendar-cell.is-overtime {
  color: #ffffff;
  background: #34b266;
}

.calendar-cell.is-late-overtime {
  color: #ffffff;
  background: linear-gradient(90deg, var(--danger) 0 50%, #34b266 50% 100%);
}

.calendar-cell.is-smoke {
  color: #ffffff;
  background: var(--warning);
}

.calendar-cell.is-absence {
  color: #b43f34;
  background: rgba(239, 91, 76, 0.16);
  border-color: rgba(239, 91, 76, 0.22);
}

.calendar-cell.is-flagged {
  color: #b07213;
  background: var(--warning-soft);
}

.calendar-cell.is-excluded {
  color: var(--muted);
  border-color: rgba(108, 123, 146, 0.24);
  background: transparent;
}

.calendar-cell.is-selected {
  border-color: rgba(33, 189, 208, 0.48);
  box-shadow: 0 0 0 3px rgba(33, 189, 208, 0.16);
}

.detail-panel {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 10px;
  min-height: 0;
  padding: 12px;
  background: rgba(255, 255, 255, 0.92);
  overflow: auto;
}

.detail-empty {
  display: grid;
  align-content: center;
  gap: 8px;
  height: 100%;
}

.detail-panel__header,
.detail-day {
  display: grid;
  gap: 14px;
}

.detail-panel__header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--line);
}

.detail-panel__identity {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  min-width: 0;
  flex: 1 1 auto;
}

.detail-panel__identity div {
  min-width: 0;
}

.detail-panel__identity h3 {
  font-size: 1.02rem;
  line-height: 1.08;
}

.detail-panel__hide-button {
  flex: 0 0 auto;
  align-self: flex-start;
  padding: 6px 10px;
  border-radius: 10px;
  font-size: 0.8rem;
  font-weight: 700;
}

.detail-panel__stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.detail-panel__stats--month {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.detail-panel__stats .detail-stat {
  min-width: 0;
}

.detail-calendar {
  display: grid;
  gap: 8px;
  padding: 10px;
  border-radius: var(--radius-lg);
  background: var(--panel-soft);
}

.detail-calendar__weekdays {
  gap: 4px;
}

.detail-calendar__weekdays span {
  text-align: center;
  font-size: 0.74rem;
  color: var(--muted);
}

.detail-calendar .calendar-cell {
  height: 34px;
  min-height: 34px;
  border-radius: 10px;
  aspect-ratio: auto;
}

.detail-calendar .calendar-cell span {
  font-size: 0.76rem;
}

.detail-day {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  justify-content: flex-start;
  min-height: 0;
  padding: 12px;
  border-radius: var(--radius-lg);
  background: var(--panel-soft);
  overflow: auto;
}

.detail-day-metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.detail-day-metrics .detail-stat {
  min-width: 0;
  padding: 9px 10px;
}

.detail-day__head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 6px 10px;
  border-radius: 999px;
  font-size: 0.78rem;
}

.pill--muted {
  color: var(--muted);
  background: rgba(108, 123, 146, 0.12);
}

.detail-events {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.detail-events li {
  padding: 0;
  border-radius: 0;
  background: transparent;
  font-size: 0.92rem;
  line-height: 1.34;
}

.detail-events li + li {
  padding-top: 6px;
  border-top: 1px solid var(--line);
}

.detail-events li.is-late {
  color: var(--danger);
}

.detail-events li.is-smoke {
  color: #c37d14;
}

.detail-events li.is-overtime {
  color: #2d9a59;
}

.detail-events li.is-flag {
  color: #7f8ca0;
  font-size: 0.86rem;
}

.detail-events li.is-muted {
  color: var(--muted);
}

.detail-log {
  display: grid;
  gap: 10px;
  padding: 12px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.76);
}

.detail-log h4 {
  margin: 0;
  font-size: 0.94rem;
  line-height: 1.1;
}

.detail-stat--late strong {
  color: var(--danger);
}

.detail-stat--smoke strong {
  color: #c37d14;
}

.detail-stat--overtime strong {
  color: #2d9a59;
}

.detail-sections {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.detail-section {
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.76);
  overflow: hidden;
}

.detail-section summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 12px 14px;
  cursor: pointer;
  list-style: none;
  font-weight: 600;
  color: var(--ink);
}

.detail-section summary::-webkit-details-marker {
  display: none;
}

.detail-section summary::after {
  content: "▾";
  color: var(--muted);
  font-size: 0.84rem;
}

.detail-section:not([open]) summary::after {
  content: "▸";
}

.detail-section__body {
  padding: 0 14px 14px;
}

.detail-editor {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 12px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.76);
}

.detail-editor h4 {
  margin: 0;
  font-size: 0.94rem;
  line-height: 1.1;
}

.detail-form {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.detail-field {
  display: grid;
  gap: 8px;
}

.detail-field span {
  font-size: 0.84rem;
  color: var(--muted);
}

.detail-field input,
.detail-field textarea {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--line-strong);
  border-radius: 14px;
  color: var(--ink);
  background: #ffffff;
}

.detail-field textarea {
  min-height: 84px;
  resize: vertical;
}

.detail-check {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-size: 0.88rem;
}

.detail-check input {
  accent-color: var(--accent);
}

.detail-placeholder,
.empty {
  display: grid;
  place-items: center;
  padding: 24px;
  border-radius: var(--radius-lg);
  color: var(--muted);
  background: rgba(255, 255, 255, 0.78);
  text-align: center;
}

.detail-placeholder--compact {
  place-items: start;
  padding: 0;
  min-height: 0;
}

.empty--compact {
  min-height: 88px;
  padding: 16px;
}

.dialog {
  width: min(1120px, calc(100vw - 28px));
  max-height: calc(100vh - 28px);
  padding: 0;
  border: none;
  border-radius: 24px;
  box-shadow: var(--shadow);
}

.dialog::backdrop {
  background: rgba(18, 30, 50, 0.26);
  backdrop-filter: blur(4px);
}

.dialog__header {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 14px;
  padding: 16px 18px;
  border-bottom: 1px solid var(--line);
}

.dialog__header h3:empty {
  display: none;
}

.dialog--confirm {
  width: min(420px, calc(100vw - 28px));
  max-height: none;
}

.dialog__header--confirm {
  justify-content: flex-start;
  padding-bottom: 10px;
  border-bottom: none;
}

.dialog__actions {
  display: flex;
  gap: 10px;
}

.dialog__actions--confirm {
  justify-content: flex-end;
  padding: 0 18px 18px;
}

.dialog__body {
  max-height: calc(100vh - 120px);
  overflow: auto;
  padding: 18px;
}

.confirm-dialog__body {
  padding: 0 18px 16px;
}

.confirm-dialog__body p {
  margin: 0;
  color: var(--muted);
  line-height: 1.5;
}

.report-print {
  color: var(--ink);
}

.report-print__header {
  display: grid;
  gap: 16px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--line);
}

.report-print__headline {
  display: flex;
  align-items: baseline;
  gap: 14px;
  flex-wrap: wrap;
}

.report-print__period {
  margin: 0;
  color: var(--muted);
}

.report-tabs {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.report-tab {
  padding: 9px 15px;
  border: none;
  border-radius: 12px;
  color: var(--muted);
  background: var(--panel-soft);
  font-weight: 700;
  cursor: pointer;
}

.report-tab.is-active {
  color: #ffffff;
  background: #13243f;
}

.report-print__stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.report-print__stat {
  padding: 12px 14px;
  border-radius: 14px;
  background: var(--panel-soft);
}

.report-print__stat span {
  display: block;
  margin-bottom: 6px;
  color: var(--muted);
  font-size: 0.82rem;
}

.report-print__stat strong {
  font-family: var(--font-mono);
  font-size: 1rem;
}

.report-print__panel[hidden] {
  display: none;
}

.report-print__table {
  width: 100%;
  margin-top: 16px;
  border-collapse: collapse;
}

.report-print__table th,
.report-print__table td {
  padding: 12px 10px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}

.report-sort {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 0;
  border: none;
  color: inherit;
  background: transparent;
  font: inherit;
  font-weight: 700;
  cursor: pointer;
}

.report-sort::after {
  content: "";
  font-size: 0.72rem;
  color: var(--muted);
}

.report-sort.is-active[data-sort-direction="asc"]::after {
  content: "↑";
}

.report-sort.is-active[data-sort-direction="desc"]::after {
  content: "↓";
}

.report-comment {
  min-width: 160px;
}

.report-comment summary {
  cursor: pointer;
  color: #13243f;
  font-weight: 600;
}

.report-comment ul {
  display: grid;
  gap: 8px;
  margin: 10px 0 0;
  padding: 0;
  list-style: none;
}

.report-comment li {
  display: grid;
  gap: 4px;
  padding: 10px 12px;
  border-radius: 12px;
  background: var(--panel-soft);
}

@media (max-width: 1440px) {
  .employee-board {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 1280px) {
  .app-shell {
    grid-template-columns: 250px minmax(0, 1fr) 320px;
  }

  .employee-board {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 1080px) {
  .app-shell {
    grid-template-columns: 1fr;
    width: calc(100vw - 20px);
    min-height: auto;
  }

  .workspace {
    border: none;
  }

  .sidebar,
  .detail-panel {
    border-top: 1px solid var(--line);
  }

  .group-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 820px) {
  .app-shell {
    margin: 10px auto;
    border-radius: 22px;
  }

  .topbar,
  .summary-bar,
  .dialog__header,
  .report-print__header {
    display: grid;
    gap: 12px;
  }

  .topbar__actions,
  .summary-bar__stats,
  .summary-bar__actions,
  .dialog__actions {
    flex-wrap: wrap;
  }

  .report-print__stats {
    grid-template-columns: 1fr;
  }

  .report-print__headline {
    gap: 8px;
  }

  .summary-bar {
    grid-template-columns: 1fr;
    grid-template-areas:
      "head"
      "stats"
      "actions";
  }

  .summary-bar__title-row {
    align-items: start;
    flex-direction: column;
    gap: 8px;
  }

  .summary-bar h2,
  .summary-bar__meta {
    white-space: normal;
  }

  .summary-bar__actions {
    justify-content: flex-start;
  }

  .detail-panel__stats {
    grid-template-columns: 1fr;
  }
}
