/* KSL Ryczałt 0.24.2 - lżejszy panel webowy, bez zmiany logiki aplikacji */
:root {
  --bg: #f5f9fc;
  --panel: #ffffff;
  --text: #0b1b33;
  --muted: #63738a;
  --line: #dde8f2;
  --blue: #00a7b5;
  --blue-soft: #e8fbfd;
  --blue-ink: #007784;
  --green: #10b981;
  --green-soft: #dcfce7;
  --amber: #b77900;
  --amber-soft: #fff1c2;
  --red: #dc2626;
  --red-soft: #fee2e2;
  --shadow: 0 14px 34px rgba(30, 57, 89, .08);
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: "Segoe UI Variable Text", "Segoe UI", Arial, sans-serif;
  font-size: 14px;
  font-weight: 400;
  line-height: 1.38;
  letter-spacing: 0;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

a,
button,
input,
select,
textarea {
  letter-spacing: 0;
}

.shell {
  grid-template-columns: 260px minmax(0, 1fr);
}

.sidebar {
  padding: 18px 16px;
  border-right: 1px solid var(--line);
  background: #ffffff;
  box-shadow: 10px 0 30px rgba(21, 45, 74, .04);
  backdrop-filter: none;
}

.content {
  padding: 24px 30px 38px;
}

.brand {
  gap: 12px;
}

.product-brand {
  padding: 6px 4px 14px;
  border-bottom: 1px solid #edf3f8;
}

.product-brand .product-logo {
  width: 178px;
  max-height: 48px;
  object-fit: contain;
}

.brand-logo {
  width: 54px;
  height: 38px;
  padding: 4px 7px;
  border-radius: 12px;
  box-shadow: 0 12px 22px rgba(7, 11, 19, .14);
}

.brand strong {
  font-size: 14px;
  font-weight: 700;
  line-height: 1.12;
}

.brand small {
  color: var(--muted);
  font-size: 12px;
  font-weight: 500;
}

.nav {
  gap: 16px;
  margin-top: 18px;
}

.nav-group {
  gap: 4px;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
}

.nav-group > span {
  padding: 0 10px 6px;
  color: #71839a;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .06em;
}

.nav a {
  min-height: 38px;
  padding: 8px 10px;
  border: 1px solid transparent;
  border-radius: 12px;
  color: #23324a;
  font-size: 14px;
  font-weight: 600;
  transition: background .16s ease, color .16s ease, border-color .16s ease, box-shadow .16s ease;
}

.nav a:hover {
  border-color: #e1ebf4;
  background: #f2f8fc;
  color: #071b35;
}

.nav a.active {
  border-color: #b7eef2;
  background: var(--blue-soft);
  color: var(--blue-ink);
  box-shadow: inset 3px 0 0 var(--blue);
}

.nav-icon {
  display: inline-grid;
  place-items: center;
  flex: 0 0 28px;
  width: 28px;
  height: 28px;
  border-radius: 9px;
  background: #f2f7fb;
  color: #50657d;
}

.nav a:hover .nav-icon,
.nav a.active .nav-icon {
  background: #dff8fa;
  color: var(--blue-ink);
}

.nav-icon svg {
  width: 17px;
  height: 17px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.9;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.footer-note {
  margin-top: 20px;
  padding: 13px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #f8fbfe;
  color: var(--muted);
  font-size: 12px;
  font-weight: 400;
}

.sidebar > div:last-child .button {
  width: 100%;
  min-height: 36px;
}

.topbar {
  align-items: center;
  gap: 16px;
  margin-bottom: 18px;
  padding: 0;
}

.topbar h1 {
  margin-bottom: 6px;
  color: var(--text);
  font-size: 31px;
  font-weight: 700;
  line-height: 1.08;
}

.topbar p {
  color: var(--muted);
  font-size: 14px;
  font-weight: 400;
}

.actions {
  gap: 8px;
}

button,
.button {
  min-height: 38px;
  padding: 8px 13px;
  border-radius: 11px;
  background: var(--blue);
  color: #ffffff;
  font-size: 14px;
  font-weight: 600;
  box-shadow: 0 10px 22px rgba(0, 167, 181, .18);
}

button:hover,
.button:hover {
  background: #008996;
  transform: translateY(-1px);
}

.button.mini,
button.mini {
  min-height: 31px;
  padding: 6px 10px;
  border-radius: 9px;
  font-size: 12px;
}

.button.secondary,
button.secondary {
  border: 1px solid var(--line);
  background: #f3f8fd;
  color: #10233d;
  box-shadow: none;
}

.button.secondary:hover,
button.secondary:hover {
  background: #e8f3fb;
  border-color: #c7d8e8;
}

input,
select,
textarea {
  border-color: #cfe0ef;
  border-radius: 11px;
  background: #fbfdff;
  padding: 9px 11px;
  font-size: 14px;
  font-weight: 500;
}

input:focus,
select:focus,
textarea:focus {
  outline: 3px solid rgba(0, 167, 181, .16);
  border-color: var(--blue);
  background: #ffffff;
}

label {
  color: #33445c;
  font-size: 12px;
  font-weight: 650;
}

.card,
.login-card,
.invoice-preview,
.invoice-print-shell,
.stat-card,
.tile,
.report-tabs-card {
  border-color: var(--line);
  border-radius: 18px;
  background: #ffffff;
  box-shadow: var(--shadow);
}

.card-pad {
  padding: 18px;
}

.grid {
  gap: 14px;
}

.topbar + .license-banner,
.license-banner {
  border-radius: 15px;
}

h1,
h2,
h3,
h4,
.card h2,
.section-title h2,
.login-card h1 {
  font-weight: 700;
  letter-spacing: 0;
}

h1 {
  font-size: 31px;
}

h2 {
  font-size: 21px;
}

h3 {
  font-size: 16px;
}

strong,
b {
  font-weight: 650;
}

.muted,
.card p,
table span,
.footer-note,
.demo-role-desc {
  color: var(--muted);
  font-weight: 400;
}

table {
  border-collapse: collapse;
}

th,
td {
  padding: 9px 12px;
  border-bottom: 1px solid #e7edf5;
  line-height: 1.28;
}

th {
  color: #71839a;
  font-size: 11px;
  font-weight: 650;
  letter-spacing: .04em;
}

td {
  font-size: 13px;
}

tr.clickable:hover,
.action-row:hover,
.report-row:hover,
.task-card:hover,
.expense-card:hover,
.company-row:hover,
.check-card:hover {
  border-color: #b7eef2;
  background: #eaf7fb;
  box-shadow: 0 10px 22px rgba(0, 167, 181, .10);
}

tr.clickable:hover {
  box-shadow: inset 3px 0 0 var(--blue);
}

.pill,
.badge,
.feature-tags span,
.login-version-badge,
.demo-credentials span {
  border-radius: 999px;
  font-weight: 600;
}

.pill {
  min-height: 24px;
  padding: 5px 9px;
  font-size: 11px;
}

.pill.ok,
.pill.active,
.pill.production {
  background: var(--green-soft);
  color: #166534;
}

.pill.warn,
.pill.demo {
  background: var(--amber-soft);
  color: #8a4a00;
}

.pill.bad {
  background: var(--red-soft);
  color: #991b1b;
}

.report-tabs {
  gap: 8px;
}

.report-tab {
  min-height: 58px;
  padding: 10px 12px;
  border-radius: 14px;
}

.report-tab strong {
  font-weight: 650;
}

.login-body {
  background: var(--bg);
}

.login-card {
  padding: 30px;
}

.login-version-badge {
  min-height: 40px;
  padding: 0 17px;
  font-size: 15px;
}

.demo-role-section {
  border-radius: 20px;
  box-shadow: var(--shadow);
}

.demo-role-card,
.login-choice .demo-role-card {
  min-height: 230px;
  padding: 22px;
}

.demo-role-desc {
  min-height: 58px;
  line-height: 1.38;
}

.invoice-brand-logo {
  border-radius: 12px;
}

.invoice-table th,
.invoice-table td,
.invoice-print-shell th,
.invoice-print-shell td {
  padding: 8px 10px;
}

.payment-card,
.report-row,
.task-card,
.expense-card,
.check-card,
.action-note,
.mf-box,
.invoice-advanced {
  border-color: var(--line);
  border-radius: 15px;
}

.payment-card,
.report-row,
.task-card,
.expense-card,
.check-card,
.mf-box,
.invoice-advanced {
  background: #f9fcff;
}

.row-actions,
.status-actions,
.payment-actions {
  gap: 7px;
}

.row-actions .button,
.row-actions button,
.status-actions button,
.payment-actions button,
.table-action {
  min-height: 31px;
  padding: 6px 9px;
  font-size: 12px;
  font-weight: 600;
}

@media (max-width: 980px) {
  .shell {
    grid-template-columns: 1fr;
  }

  .sidebar {
    position: relative;
    height: auto;
  }

  .content {
    padding: 20px 14px 30px;
  }

  .topbar {
    display: block;
  }

  .topbar h1 {
    font-size: 27px;
  }

  .actions {
    margin-top: 12px;
  }
}

@media print {
  .sidebar,
  .topbar,
  .actions,
  .button,
  button {
    display: none !important;
  }
}

/* 0.24.3 - dopracowanie środka panelu: mniej ciężaru, ciaśniejsze karty i czytelniejszy raport */
:root {
  --shadow: 0 10px 26px rgba(28, 48, 76, .055);
  --shadow-hover: 0 14px 30px rgba(0, 167, 181, .11);
}

.content {
  padding-top: 22px;
  background:
    radial-gradient(circle at 12% 0%, rgba(0, 167, 181, .045), transparent 34%),
    linear-gradient(180deg, #f7fbfe 0%, #eef5fb 100%);
}

.content > .topbar {
  margin-bottom: 20px;
}

.content > .topbar h1 {
  font-size: 30px;
  font-weight: 720;
  letter-spacing: 0;
}

.content > .topbar p {
  max-width: 760px;
  font-size: 14px;
  line-height: 1.45;
}

.content .card,
.content .metric,
.content .report-tabs-card,
.content .report-intro,
.content .payment-card,
.content .task-card,
.content .expense-card,
.content .check-card,
.content .status-row,
.content .mf-box,
.content .invoice-advanced {
  border-color: #d9e6f1;
  box-shadow: var(--shadow);
}

.content .card-pad {
  padding: 16px 18px;
}

.content .grid {
  gap: 12px;
}

.license-banner {
  padding: 12px 16px;
  box-shadow: none;
}

.report-tabs-card {
  margin-bottom: 16px;
  padding: 14px 18px !important;
  background: rgba(255, 255, 255, .86);
}

.report-tabs {
  gap: 10px;
}

.report-tab {
  position: relative;
  display: grid;
  grid-template-columns: 31px minmax(0, 1fr);
  grid-template-rows: auto auto;
  align-items: center;
  min-height: 62px;
  padding: 11px 13px;
  column-gap: 10px;
  row-gap: 2px;
  border-color: #d8e5f0;
  border-radius: 15px;
  background: linear-gradient(180deg, #ffffff, #fbfdff);
  box-shadow: 0 8px 18px rgba(28, 48, 76, .035);
}

.report-tab::before {
  content: "";
  grid-row: 1 / 3;
  width: 30px;
  height: 30px;
  border-radius: 11px;
  background:
    linear-gradient(135deg, rgba(0, 167, 181, .18), rgba(14, 165, 233, .08));
  box-shadow: inset 0 0 0 1px rgba(0, 167, 181, .18);
}

.report-tab strong,
.report-tab span {
  grid-column: 2;
  min-width: 0;
}

.report-tab strong {
  font-size: 13px;
  font-weight: 680;
  line-height: 1.18;
}

.report-tab span {
  font-size: 11px;
  font-weight: 600;
  line-height: 1.2;
}

.report-tab:hover,
.report-tab.active {
  border-color: #8ddde6;
  background: #f1fcfd;
  box-shadow: inset 3px 0 0 var(--blue), var(--shadow-hover);
}

.report-tab.active::before {
  background: linear-gradient(135deg, var(--blue), #69d7e1);
}

.report-intro {
  margin-bottom: 16px;
  padding: 16px 18px !important;
}

.report-intro .topbar {
  margin: 0;
}

.report-intro h2,
.content .card h2 {
  margin-bottom: 6px;
  font-size: 20px;
  font-weight: 720;
  letter-spacing: 0;
}

.report-intro p,
.content .card p {
  font-size: 13px;
  line-height: 1.42;
}

.month-picker,
.report-months,
.month-nav,
.report-intro .actions {
  gap: 7px;
}

.month-picker a,
.report-months a,
.month-nav a,
.report-intro .button,
.report-intro button {
  min-height: 34px;
  padding: 7px 11px;
  border-radius: 10px;
  font-size: 13px;
}

.metric {
  position: relative;
  min-height: 78px;
  padding: 14px 18px 14px 58px !important;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  border-radius: 16px;
  background: linear-gradient(180deg, #ffffff, #fbfdff);
}

.metric::before {
  content: "";
  position: absolute;
  left: 18px;
  top: 50%;
  width: 28px;
  height: 28px;
  border-radius: 11px;
  transform: translateY(-50%);
  background:
    linear-gradient(135deg, rgba(0, 167, 181, .18), rgba(14, 165, 233, .08));
  box-shadow: inset 0 0 0 1px rgba(0, 167, 181, .18);
}

.metric span {
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: .045em;
  line-height: 1.15;
}

.metric strong {
  font-size: 25px;
  font-weight: 720;
  line-height: 1.05;
}

.status-list {
  gap: 8px;
}

.status-row,
.task-card,
.payment-card,
.expense-card,
.check-card,
.report-row {
  padding: 10px 13px;
  border-radius: 14px;
  background: #ffffff;
}

.status-row:hover,
.task-card:hover,
.payment-card:hover,
.expense-card:hover,
.check-card:hover,
.report-row:hover {
  border-color: #a9e7ed;
  background: #f1fcfd;
  box-shadow: var(--shadow-hover);
}

.content table {
  background: transparent;
}

.content th,
.content td {
  padding-top: 7px;
  padding-bottom: 7px;
  line-height: 1.22;
}

.content td {
  font-size: 12.8px;
}

.content th {
  font-size: 10.5px;
}

.pill {
  min-height: 22px;
  padding: 4px 8px;
  font-size: 10.5px;
}

.content .notice {
  padding: 10px 13px;
  border-radius: 13px;
  font-size: 13px;
}

.content .topbar .actions .button,
.content .topbar .actions button {
  min-height: 38px;
  padding-inline: 14px;
}

@media (max-width: 1180px) {
  .report-tabs {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

/* 0.25.0 - warstwa pracy: wyszukiwarka, powiadomienia, panel boczny i proces dokumentu */
.topbar-tools {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  flex-wrap: wrap;
  min-width: min(760px, 100%);
}

.global-search {
  display: flex;
  align-items: center;
  gap: 8px;
  width: min(430px, 100%);
  padding: 6px;
  border: 1px solid #d7e5f0;
  border-radius: 14px;
  background: rgba(255, 255, 255, .9);
  box-shadow: 0 8px 20px rgba(28, 48, 76, .04);
}

.global-search input {
  flex: 1;
  min-width: 180px;
  min-height: 32px;
  border: 0;
  background: transparent;
  box-shadow: none;
  padding: 6px 8px;
}

.global-search input:focus {
  outline: none;
  background: transparent;
}

.global-search button {
  min-height: 32px;
  padding: 6px 12px;
}

.global-search.large {
  width: 100%;
  margin-bottom: 16px;
}

.notification-menu {
  position: relative;
}

.notification-toggle {
  gap: 7px;
}

.notification-count {
  display: inline-grid;
  place-items: center;
  min-width: 22px;
  height: 22px;
  padding: 0 6px;
  border-radius: 999px;
  background: var(--blue);
  color: #fff;
  font-size: 11px;
  font-weight: 750;
}

.notification-popover {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  z-index: 50;
  display: none;
  width: min(380px, calc(100vw - 32px));
  padding: 10px;
  border: 1px solid #d9e6f1;
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 24px 55px rgba(20, 40, 70, .16);
}

.notification-popover.open {
  display: grid;
  gap: 8px;
}

.notification-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 8px 8px 6px;
}

.notification-head a {
  color: var(--blue-ink);
  font-size: 12px;
  font-weight: 700;
}

.notification-row {
  display: grid;
  grid-template-columns: 10px minmax(0, 1fr);
  gap: 10px;
  padding: 10px;
  border: 1px solid transparent;
  border-radius: 13px;
  color: var(--text);
}

.notification-row:hover {
  border-color: #b7eef2;
  background: #f1fcfd;
}

.notification-dot {
  width: 8px;
  height: 8px;
  margin-top: 6px;
  border-radius: 999px;
  background: var(--blue);
  box-shadow: 0 0 0 4px rgba(0, 167, 181, .12);
}

.notification-row small {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.35;
}

.notification-empty {
  padding: 12px;
  color: var(--muted);
  font-size: 13px;
}

.quick-panel-backdrop {
  position: fixed;
  inset: 0;
  z-index: 70;
  background: rgba(8, 23, 42, .18);
  backdrop-filter: blur(2px);
}

.quick-panel {
  position: fixed;
  top: 18px;
  right: 18px;
  bottom: 18px;
  z-index: 80;
  width: min(460px, calc(100vw - 36px));
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  border: 1px solid #d9e6f1;
  border-radius: 22px;
  background: #fff;
  box-shadow: 0 30px 80px rgba(15, 35, 65, .2);
  transform: translateX(calc(100% + 40px));
  transition: transform .2s ease;
  overflow: hidden;
}

.quick-panel.open {
  transform: translateX(0);
}

.quick-panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 18px;
  border-bottom: 1px solid #e4eef7;
  background: #f8fcff;
}

.quick-panel-head span {
  display: block;
  margin-top: 2px;
  color: var(--muted);
  font-size: 12px;
}

.quick-panel-content {
  overflow: auto;
  padding: 18px;
}

.quick-preview h2 {
  margin: 4px 0 6px;
  font-size: 23px;
  line-height: 1.16;
}

.eyebrow {
  color: var(--blue-ink);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .06em;
  text-transform: uppercase;
}

.quick-facts {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin: 16px 0;
}

.quick-facts span {
  display: grid;
  gap: 4px;
  padding: 11px;
  border: 1px solid #dce8f3;
  border-radius: 14px;
  background: #f8fcff;
}

.quick-facts small {
  color: var(--muted);
  font-size: 10px;
  font-weight: 750;
  text-transform: uppercase;
}

.quick-facts strong {
  font-size: 14px;
  line-height: 1.2;
}

.quick-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 16px;
}

.process-steps {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 8px;
}

.process-step {
  position: relative;
  display: grid;
  gap: 4px;
  min-height: 68px;
  padding: 12px 11px;
  border: 1px solid #dce8f3;
  border-radius: 14px;
  background: #f9fcff;
}

.process-step::before {
  content: "";
  width: 9px;
  height: 9px;
  border-radius: 999px;
  background: #cbd7e4;
  box-shadow: 0 0 0 4px rgba(203, 215, 228, .25);
}

.process-step.done {
  border-color: #b9efe0;
  background: #f0fdf7;
}

.process-step.done::before {
  background: var(--green);
  box-shadow: 0 0 0 4px rgba(16, 185, 129, .16);
}

.process-step strong {
  font-size: 12px;
  font-weight: 750;
}

.process-step small {
  color: var(--muted);
  font-size: 11px;
  line-height: 1.25;
}

.process-steps.compact {
  grid-template-columns: 1fr;
}

.process-steps.compact .process-step {
  min-height: auto;
  grid-template-columns: 14px minmax(0, 1fr);
  align-items: start;
}

.process-steps.compact .process-step small {
  grid-column: 2;
}

.search-results {
  margin-top: 14px;
}

@media (max-width: 1220px) {
  .topbar-tools {
    justify-content: flex-start;
    min-width: 100%;
  }

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

/* 0.25.1 - spójny format wszystkich zakładek: raporty, listy, filtry i widoki robocze */
main.content {
  --surface-border: #d8e6f1;
  --surface-soft: #f7fbfe;
  --surface-hover: #e8fbfd;
  --surface-shadow: 0 14px 34px rgba(30, 57, 89, .07);
  --surface-shadow-strong: 0 18px 42px rgba(30, 57, 89, .11);
}

main.content > .topbar {
  align-items: flex-start;
  padding-bottom: 16px;
  border-bottom: 1px solid rgba(216, 230, 241, .78);
}

main.content > .topbar h1 {
  font-size: 30px;
  font-weight: 700;
  letter-spacing: 0;
}

main.content > .topbar p {
  color: #60728a;
}

main.content .card,
main.content .report-tabs-card,
main.content .report-intro,
main.content .table-card,
main.content .invoice-filter-card,
main.content .tax-profile-card,
main.content .decision-card,
main.content .ksef-result-card,
main.content .mf-box,
main.content .payment-card,
main.content .task-card,
main.content .expense-card,
main.content .check-card {
  border: 1px solid var(--surface-border);
  border-radius: 16px;
  background: rgba(255, 255, 255, .94);
  box-shadow: var(--surface-shadow);
}

main.content .card-pad {
  padding: 18px 20px;
}

main.content .grid {
  gap: 14px;
}

main.content .grid.cols-4 {
  grid-template-columns: repeat(4, minmax(180px, 1fr));
}

main.content .grid.cols-3 {
  grid-template-columns: repeat(3, minmax(220px, 1fr));
}

main.content .grid.cols-2 {
  grid-template-columns: repeat(2, minmax(280px, 1fr));
}

main.content .report-tabs-card {
  margin: 0 0 16px;
  padding: 14px !important;
}

main.content .report-tabs {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(176px, 1fr));
  gap: 10px;
}

main.content .report-tab,
main.content .report-view-link {
  position: relative;
  min-height: 64px;
  border: 1px solid #d9e7f2;
  border-radius: 15px;
  background: linear-gradient(180deg, #ffffff, #fbfdff);
  color: #0b1b33;
  box-shadow: none;
  transition: border-color .16s ease, background .16s ease, box-shadow .16s ease, transform .16s ease;
}

main.content .report-tab {
  grid-template-columns: 32px minmax(0, 1fr);
  padding: 12px 13px;
}

main.content .report-tab::before {
  width: 31px;
  height: 31px;
  border-radius: 11px;
  background: #eef7fb;
  box-shadow: inset 0 0 0 1px #d5e8f4;
}

main.content .report-tab:hover,
main.content .report-tab.active,
main.content .report-view-link:hover,
main.content .report-view-link.active {
  border-color: #7bd8e3;
  background: #f0fcfd;
  box-shadow: inset 3px 0 0 var(--blue), 0 13px 28px rgba(0, 167, 181, .12);
  transform: translateY(-1px);
}

main.content .report-tab.active::before {
  background: linear-gradient(135deg, #00a7b5, #0ea5e9);
  box-shadow: 0 8px 16px rgba(0, 167, 181, .18);
}

main.content .report-tab strong,
main.content .report-view-link strong {
  font-size: 13px;
  font-weight: 700;
  line-height: 1.18;
}

main.content .report-tab span,
main.content .report-view-link span {
  color: #60728a;
  font-size: 11px;
  font-weight: 650;
  line-height: 1.22;
}

main.content .report-intro {
  margin: 0 0 16px;
  padding: 18px 20px !important;
}

main.content .report-intro .topbar,
main.content .card > .topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin: 0 0 12px;
  padding: 0;
}

main.content .report-intro h2,
main.content .card h2 {
  font-size: 20px;
  font-weight: 700;
  letter-spacing: 0;
}

main.content .report-intro p,
main.content .card p,
main.content .muted {
  line-height: 1.42;
}

main.content .report-view-switch {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 10px;
  margin-top: 14px;
}

main.content .report-view-link {
  display: grid;
  gap: 4px;
  padding: 12px 14px;
}

main.content .month-switch {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  justify-content: flex-end;
}

main.content .month-switch a {
  min-width: 36px;
  min-height: 34px;
  display: inline-grid;
  place-items: center;
  padding: 7px 10px;
  border: 1px solid #d8e6f1;
  border-radius: 10px;
  background: #f8fbfe;
  color: #17304d;
  font-size: 12px;
  font-weight: 700;
}

main.content .month-switch a:hover,
main.content .month-switch a.active {
  border-color: #7bd8e3;
  background: #e8fbfd;
  color: #007784;
  box-shadow: inset 0 -2px 0 var(--blue);
}

main.content .metric {
  min-height: 82px;
  padding: 15px 18px 15px 58px !important;
  border-radius: 16px;
}

main.content .metric::before {
  width: 30px;
  height: 30px;
  border-radius: 11px;
  background: #eef7fb;
  box-shadow: inset 0 0 0 1px #d5e8f4;
}

main.content .metric span {
  color: #60728a;
  font-size: 10.5px;
  font-weight: 750;
  letter-spacing: .035em;
}

main.content .metric strong {
  font-size: 25px;
  font-weight: 700;
}

main.content .table-card {
  overflow-x: auto;
  padding: 0;
  background: #ffffff;
}

main.content .table-card table,
main.content table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
}

main.content th {
  padding: 12px 13px;
  border-bottom: 1px solid #dce8f3;
  background: #f8fbfe;
  color: #60728a;
  font-size: 10.5px;
  font-weight: 750;
  letter-spacing: .045em;
  text-transform: uppercase;
}

main.content td {
  padding: 12px 13px;
  border-bottom: 1px solid #e5eef7;
  color: #13243a;
  font-size: 13px;
  line-height: 1.28;
  vertical-align: middle;
}

main.content tbody tr:last-child td {
  border-bottom: 0;
}

main.content tr.clickable,
main.content .clickable {
  cursor: pointer;
}

main.content tr.clickable:hover td {
  background: #f0fcfd;
}

main.content .status-list {
  display: grid;
  gap: 9px;
}

main.content .status-row,
main.content .report-row {
  min-height: 58px;
  padding: 11px 13px;
  border: 1px solid #dce8f3;
  border-radius: 14px;
  background: #ffffff;
}

main.content .status-row:hover,
main.content .report-row:hover,
main.content .task-card:hover,
main.content .payment-card:hover,
main.content .expense-card:hover,
main.content .check-card:hover {
  border-color: #8fe1e8;
  background: #f0fcfd;
  box-shadow: var(--surface-shadow-strong);
}

main.content .form-grid,
main.content .compact-form-grid,
main.content .invoice-filter-grid {
  gap: 12px;
  align-items: end;
}

main.content form.form-grid,
main.content .invoice-filter-card,
main.content .compact-filter-card {
  padding: 14px;
  border: 1px solid #dce8f3;
  border-radius: 15px;
  background: #f8fbfe;
  box-shadow: none;
}

main.content label {
  color: #314158;
  font-size: 12px;
  font-weight: 700;
}

main.content input,
main.content select,
main.content textarea {
  min-height: 40px;
}

main.content .monthly-detail-list {
  display: grid;
  gap: 14px;
}

main.content .monthly-detail-card {
  overflow: hidden;
}

main.content .monthly-detail-summary {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 10px;
  margin: 12px 0 14px;
}

main.content .monthly-detail-summary div {
  padding: 12px;
  border: 1px solid #dce8f3;
  border-radius: 13px;
  background: #f8fbfe;
}

main.content .monthly-detail-summary span {
  display: block;
  color: #60728a;
  font-size: 10.5px;
  font-weight: 750;
  text-transform: uppercase;
}

main.content .monthly-detail-summary strong {
  display: block;
  margin-top: 4px;
  font-size: 17px;
}

main.content .monthly-event-row {
  border-left: 3px solid #a8e8ee;
}

main.content .ksef-received-summary,
main.content .ksef-result-grid,
main.content .invoice-step-grid,
main.content .workflow-grid,
main.content .tax-profile-grid,
main.content .decision-grid,
main.content .zus-calendar {
  gap: 12px;
}

main.content .ksef-received-summary > *,
main.content .invoice-step-card,
main.content .workflow-card,
main.content .tax-profile-card {
  border-radius: 15px;
}

main.content .pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 23px;
  padding: 4px 9px;
  border-radius: 999px;
  font-size: 10.5px;
  font-weight: 750;
  line-height: 1;
  white-space: nowrap;
}

main.content .notice {
  border-radius: 14px;
  border-color: #dce8f3;
  background: #f8fbfe;
}

main.content .action-guidance {
  margin: 12px 0 14px;
  border-color: #b9edf2;
  background: #f0fcfd;
  color: #17425a;
}

main.content .button,
main.content button {
  border-radius: 11px;
}

@media (max-width: 1320px) {
  main.content .grid.cols-4 {
    grid-template-columns: repeat(2, minmax(220px, 1fr));
  }

  main.content .report-intro .topbar,
  main.content .card > .topbar {
    align-items: flex-start;
    flex-direction: column;
  }

  main.content .month-switch {
    justify-content: flex-start;
  }
}

@media (max-width: 760px) {
  main.content .grid.cols-4,
  main.content .grid.cols-3,
  main.content .grid.cols-2,
  main.content .report-tabs,
  main.content .report-view-switch {
    grid-template-columns: 1fr;
  }

  main.content .card-pad,
  main.content .report-intro {
    padding: 15px !important;
  }
}

@media print {
  body {
    background: #fff !important;
    color: #111827;
    font-size: 9.2px;
    line-height: 1.22;
  }

  main.content {
    padding: 0 !important;
    background: #fff !important;
  }

  .topbar-tools,
  .global-search,
  .notification-menu,
  .quick-panel,
  .quick-panel-backdrop,
  .report-tabs-card,
  .print-hide,
  main.content > .topbar .actions,
  main.content .report-intro .actions,
  main.content form,
  main.content button,
  main.content .button {
    display: none !important;
  }

  main.content > .topbar {
    margin: 0 0 5mm;
    padding: 0 0 3mm;
    border-bottom: 1px solid #d6e2ed;
  }

  main.content > .topbar h1 {
    font-size: 18px;
    line-height: 1.15;
  }

  main.content .card,
  main.content .report-intro,
  main.content .metric,
  main.content .table-card,
  main.content .status-row {
    box-shadow: none !important;
    border-color: #d2deea;
    border-radius: 6px;
    background: #fff !important;
    break-inside: avoid;
    page-break-inside: avoid;
  }

  main.content .card-pad,
  main.content .report-intro,
  main.content .metric {
    padding: 5px 6px !important;
  }

  main.content .grid {
    gap: 5px;
  }

  main.content .grid.cols-4 {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  main.content .grid.cols-3,
  main.content .grid.cols-2 {
    grid-template-columns: 1fr;
  }

  main.content .metric {
    min-height: 0;
    padding-left: 6px !important;
  }

  main.content .metric::before,
  main.content .report-tab::before {
    display: none;
  }

  main.content .metric span {
    font-size: 6.8px;
  }

  main.content .metric strong {
    font-size: 12px;
  }

  main.content h2 {
    font-size: 12.5px;
    margin-bottom: 2px;
  }

  main.content p,
  main.content .muted,
  main.content .notice {
    font-size: 8px;
    line-height: 1.22;
  }

  main.content .table-card {
    overflow: visible;
  }

  main.content th,
  main.content td {
    padding: 4px 5px;
    font-size: 7.8px;
    line-height: 1.18;
  }

  main.content th {
    background: #f6f9fc !important;
  }

  main.content .status-list {
    gap: 4px;
  }

  main.content .status-row {
    min-height: 0;
    padding: 5px 6px;
  }

  main.content .pill {
    min-height: 15px;
    padding: 2px 5px;
    font-size: 7px;
  }

  main.content .action-guidance {
    border-color: #d2deea;
    background: #f8fafc !important;
  }

  .print-footer {
    margin-top: 5mm;
    padding-top: 2mm;
    border-top: 1px solid #d6e2ed;
    color: #475569;
    font-size: 7.5px;
    line-height: 1.2;
  }
}
