/* Wspólnota Plus v214 — końcowe ujednolicenie: dokumenty, powiadomienia, FIK/finanse, raporty.
   Warstwa wizualna oparta o wspólny shell v211 i standardy v212/v213. Bez zmian logiki. */
.app-shell-unified-v211{
  --v214-bg:#f4f8fd;
  --v214-panel:#ffffff;
  --v214-panel-soft:#f8fbff;
  --v214-border:#eef2f7;
  --v214-border-soft:#eef2f7;
  --v214-text:#0f172a;
  --v214-muted:#64748b;
  --v214-blue:#1f2937;
  --v214-blue-soft:#eef2f7;
  --v214-green:#16a34a;
  --v214-green-soft:#ecfdf3;
  --v214-orange:#f59e0b;
  --v214-orange-soft:#fff7e6;
  --v214-red:#dc2626;
  --v214-red-soft:#fff1f2;
  --v214-purple:#7c3aed;
  --v214-purple-soft:#f3e8ff;
  --v214-radius:24px;
  --v214-radius-sm:16px;
  --v214-shadow:0 18px 48px rgba(15, 23, 42,.08);
  --v214-shadow-sm:0 10px 26px rgba(15, 23, 42,.055);
}

/* Dokumenty / powiadomienia / raporty: wspólne nagłówki */
.app-shell-unified-v211 .notifications-page,
.app-shell-unified-v211 .documents-page,
.app-shell-unified-v211 .reports-page,
.app-shell-unified-v211 .report-page,
.app-shell-unified-v211 .fik-page,
.app-shell-unified-v211 .finance-page,
.app-shell-unified-v211 .payments-page,
.app-shell-unified-v211 .audit-page,
.app-shell-unified-v211 .message-template-page,
.app-shell-unified-v211 .operational-documents-page,
.app-shell-unified-v211 .owner-documents-page,
.app-shell-unified-v211 .owner-notifications-page,
.app-shell-unified-v211 .owner-payments-page{
  max-width:100%!important;
}
.app-shell-unified-v211 .notifications-page .page-header,
.app-shell-unified-v211 .documents-page .page-header,
.app-shell-unified-v211 .reports-page .page-header,
.app-shell-unified-v211 .report-page .page-header,
.app-shell-unified-v211 .fik-page .page-header,
.app-shell-unified-v211 .finance-page .page-header,
.app-shell-unified-v211 .payments-page .page-header,
.app-shell-unified-v211 .audit-page .page-header,
.app-shell-unified-v211 .message-template-page .page-header,
.app-shell-unified-v211 .operational-documents-page .page-header,
.app-shell-unified-v211 .owner-documents-page .page-header,
.app-shell-unified-v211 .owner-notifications-page .page-header,
.app-shell-unified-v211 .owner-payments-page .page-header,
.app-shell-unified-v211 .fik-header,
.app-shell-unified-v211 .report-header,
.app-shell-unified-v211 .section-header,
.app-shell-unified-v211 .list-header{
  border:1px solid var(--v214-border)!important;
  border-radius:28px!important;
  background:linear-gradient(135deg,#fff 0%,#f6f9ff 100%)!important;
  box-shadow:var(--v214-shadow)!important;
  padding:clamp(20px,2.2vw,32px)!important;
  margin-bottom:20px!important;
  color:var(--v214-text)!important;
}
.app-shell-unified-v211 .page-header h1,
.app-shell-unified-v211 .fik-header h1,
.app-shell-unified-v211 .report-header h1,
.app-shell-unified-v211 .section-header h1,
.app-shell-unified-v211 .section-title,
.app-shell-unified-v211 .card-title{
  color:var(--v214-text)!important;
  letter-spacing:-.035em!important;
}
.app-shell-unified-v211 .page-header p,
.app-shell-unified-v211 .fik-header p,
.app-shell-unified-v211 .report-header p,
.app-shell-unified-v211 .section-header p,
.app-shell-unified-v211 .help-text,
.app-shell-unified-v211 .hint,
.app-shell-unified-v211 .description,
.app-shell-unified-v211 .subtitle{
  color:var(--v214-muted)!important;
}

/* Karty dokumentów, raportów i powiadomień */
.app-shell-unified-v211 .notification-card,
.app-shell-unified-v211 .document-card,
.app-shell-unified-v211 .report-card,
.app-shell-unified-v211 .payment-card,
.app-shell-unified-v211 .finance-card,
.app-shell-unified-v211 .audit-card,
.app-shell-unified-v211 .template-card,
.app-shell-unified-v211 .operational-document-card,
.app-shell-unified-v211 .message-card,
.app-shell-unified-v211 .stat-card,
.app-shell-unified-v211 .summary-card,
.app-shell-unified-v211 .kpi-card,
.app-shell-unified-v211 .metric-card,
.app-shell-unified-v211 .quick-card,
.app-shell-unified-v211 .action-card,
.app-shell-unified-v211 .filter-card,
.app-shell-unified-v211 .panel-card,
.app-shell-unified-v211 .box,
.app-shell-unified-v211 .tile{
  background:rgba(255,255,255,.97)!important;
  border:1px solid var(--v214-border)!important;
  border-radius:var(--v214-radius)!important;
  box-shadow:var(--v214-shadow-sm)!important;
  color:var(--v214-text)!important;
}
.app-shell-unified-v211 .notification-card,
.app-shell-unified-v211 .document-card,
.app-shell-unified-v211 .report-card,
.app-shell-unified-v211 .payment-card,
.app-shell-unified-v211 .finance-card,
.app-shell-unified-v211 .audit-card,
.app-shell-unified-v211 .template-card,
.app-shell-unified-v211 .operational-document-card,
.app-shell-unified-v211 .message-card{
  padding:18px!important;
}
.app-shell-unified-v211 .notification-card:hover,
.app-shell-unified-v211 .document-card:hover,
.app-shell-unified-v211 .report-card:hover,
.app-shell-unified-v211 .payment-card:hover,
.app-shell-unified-v211 .finance-card:hover,
.app-shell-unified-v211 .audit-card:hover,
.app-shell-unified-v211 .template-card:hover,
.app-shell-unified-v211 .operational-document-card:hover,
.app-shell-unified-v211 .message-card:hover{
  border-color:#eef2f7!important;
  box-shadow:0 20px 54px rgba(15, 23, 42,.105)!important;
  transform:translateY(-1px);
}

/* Listy i wiersze */
.app-shell-unified-v211 .notification-item,
.app-shell-unified-v211 .document-item,
.app-shell-unified-v211 .report-item,
.app-shell-unified-v211 .payment-item,
.app-shell-unified-v211 .audit-item,
.app-shell-unified-v211 .activity-item,
.app-shell-unified-v211 .timeline-item,
.app-shell-unified-v211 .message-item,
.app-shell-unified-v211 .list-row{
  background:#fff!important;
  border:1px solid var(--v214-border-soft)!important;
  border-radius:18px!important;
  padding:14px 16px!important;
  margin-bottom:10px!important;
  box-shadow:0 8px 22px rgba(15, 23, 42,.04)!important;
}
.app-shell-unified-v211 .notification-item.unread,
.app-shell-unified-v211 .message-item.unread{
  border-color:#eef2f7!important;
  background:linear-gradient(135deg,#fff 0%,#eef2f7 100%)!important;
}

/* Raporty i finanse — siatki KPI */
.app-shell-unified-v211 .kpi-grid,
.app-shell-unified-v211 .metrics-grid,
.app-shell-unified-v211 .stats-grid,
.app-shell-unified-v211 .reports-grid,
.app-shell-unified-v211 .documents-grid,
.app-shell-unified-v211 .notifications-grid,
.app-shell-unified-v211 .finance-grid,
.app-shell-unified-v211 .payments-grid{
  display:grid!important;
  grid-template-columns:repeat(auto-fit,minmax(220px,1fr))!important;
  gap:18px!important;
  margin-bottom:20px!important;
}
.app-shell-unified-v211 .kpi-card,
.app-shell-unified-v211 .metric-card,
.app-shell-unified-v211 .stat-card{
  padding:18px!important;
  min-height:118px!important;
}
.app-shell-unified-v211 .kpi-card .value,
.app-shell-unified-v211 .metric-card .value,
.app-shell-unified-v211 .stat-card .value,
.app-shell-unified-v211 .stat-value,
.app-shell-unified-v211 .metric-value{
  font-size:clamp(24px,2.4vw,34px)!important;
  font-weight:900!important;
  color:var(--v214-text)!important;
  letter-spacing:-.045em!important;
}
.app-shell-unified-v211 .kpi-card .label,
.app-shell-unified-v211 .metric-card .label,
.app-shell-unified-v211 .stat-card .label,
.app-shell-unified-v211 .stat-label,
.app-shell-unified-v211 .metric-label{
  color:var(--v214-muted)!important;
  font-weight:800!important;
}

/* Tabele raportów/dokumentów/płatności */
.app-shell-unified-v211 .documents-table,
.app-shell-unified-v211 .notifications-table,
.app-shell-unified-v211 .reports-table,
.app-shell-unified-v211 .payments-table,
.app-shell-unified-v211 .finance-table,
.app-shell-unified-v211 .audit-table,
.app-shell-unified-v211 .fik-table{
  width:100%!important;
  overflow-x:auto!important;
  border:1px solid var(--v214-border)!important;
  border-radius:24px!important;
  background:#fff!important;
  box-shadow:var(--v214-shadow-sm)!important;
}
.app-shell-unified-v211 .documents-table table,
.app-shell-unified-v211 .notifications-table table,
.app-shell-unified-v211 .reports-table table,
.app-shell-unified-v211 .payments-table table,
.app-shell-unified-v211 .finance-table table,
.app-shell-unified-v211 .audit-table table,
.app-shell-unified-v211 .fik-table table{
  margin:0!important;
}
.app-shell-unified-v211 .documents-table th,
.app-shell-unified-v211 .notifications-table th,
.app-shell-unified-v211 .reports-table th,
.app-shell-unified-v211 .payments-table th,
.app-shell-unified-v211 .finance-table th,
.app-shell-unified-v211 .audit-table th,
.app-shell-unified-v211 .fik-table th{
  background:#f8fbff!important;
  color:#64748b!important;
  font-size:12px!important;
  letter-spacing:.055em!important;
  text-transform:uppercase!important;
  font-weight:900!important;
}

/* Badge/statusy — wspólna mapa kolorów */
.app-shell-unified-v211 .badge,
.app-shell-unified-v211 .status,
.app-shell-unified-v211 .pill,
.app-shell-unified-v211 .tag,
.app-shell-unified-v211 .label-badge{
  border-radius:999px!important;
  font-weight:900!important;
  border:1px solid transparent!important;
  padding:.38rem .68rem!important;
  line-height:1.1!important;
}
.app-shell-unified-v211 .badge-success,
.app-shell-unified-v211 .status-success,
.app-shell-unified-v211 .status-paid,
.app-shell-unified-v211 .status-sent,
.app-shell-unified-v211 .status-active,
.app-shell-unified-v211 .status-accepted{
  background:var(--v214-green-soft)!important;color:#166534!important;border-color:#bbf7d0!important;
}
.app-shell-unified-v211 .badge-info,
.app-shell-unified-v211 .status-info,
.app-shell-unified-v211 .status-open,
.app-shell-unified-v211 .status-in-progress,
.app-shell-unified-v211 .status-processing{
  background:var(--v214-blue-soft)!important;color:#1f2937!important;border-color:#eef2f7!important;
}
.app-shell-unified-v211 .badge-warning,
.app-shell-unified-v211 .status-warning,
.app-shell-unified-v211 .status-planned,
.app-shell-unified-v211 .status-pending,
.app-shell-unified-v211 .status-draft{
  background:var(--v214-orange-soft)!important;color:#92400e!important;border-color:#fed7aa!important;
}
.app-shell-unified-v211 .badge-danger,
.app-shell-unified-v211 .status-danger,
.app-shell-unified-v211 .status-error,
.app-shell-unified-v211 .status-overdue,
.app-shell-unified-v211 .status-unpaid,
.app-shell-unified-v211 .status-rejected{
  background:var(--v214-red-soft)!important;color:#991b1b!important;border-color:#fecdd3!important;
}
.app-shell-unified-v211 .badge-muted,
.app-shell-unified-v211 .status-muted,
.app-shell-unified-v211 .status-archived,
.app-shell-unified-v211 .status-cancelled{
  background:#f1f5f9!important;color:#475569!important;border-color:#e2e8f0!important;
}

/* Formularze w dokumentach/powiadomieniach/raportach */
.app-shell-unified-v211 .filters,
.app-shell-unified-v211 .filter-bar,
.app-shell-unified-v211 .search-bar,
.app-shell-unified-v211 .actions-bar,
.app-shell-unified-v211 .toolbar{
  background:rgba(255,255,255,.97)!important;
  border:1px solid var(--v214-border)!important;
  border-radius:22px!important;
  box-shadow:var(--v214-shadow-sm)!important;
  padding:14px!important;
  gap:12px!important;
}
.app-shell-unified-v211 input,
.app-shell-unified-v211 select,
.app-shell-unified-v211 textarea{
  border-radius:14px!important;
  border-color:#eef2f7!important;
  background:#fff!important;
}
.app-shell-unified-v211 input:focus,
.app-shell-unified-v211 select:focus,
.app-shell-unified-v211 textarea:focus{
  border-color:#94a3b8!important;
  box-shadow:0 0 0 4px rgba(31, 41, 55,.10)!important;
  outline:none!important;
}

/* Puste stany */
.app-shell-unified-v211 .empty-state,
.app-shell-unified-v211 .no-results,
.app-shell-unified-v211 .blank-state{
  border:1px dashed #eef2f7!important;
  border-radius:26px!important;
  background:linear-gradient(135deg,#fff 0%,#f6f9ff 100%)!important;
  color:var(--v214-muted)!important;
  padding:clamp(22px,3vw,42px)!important;
  text-align:center!important;
  box-shadow:var(--v214-shadow-sm)!important;
}
.app-shell-unified-v211 .empty-state h2,
.app-shell-unified-v211 .empty-state h3,
.app-shell-unified-v211 .no-results h2,
.app-shell-unified-v211 .no-results h3,
.app-shell-unified-v211 .blank-state h2,
.app-shell-unified-v211 .blank-state h3{
  color:var(--v214-text)!important;
}

/* Responsywność końcowa */
@media(max-width:1100px){
  .app-shell-unified-v211 .reports-grid,
  .app-shell-unified-v211 .documents-grid,
  .app-shell-unified-v211 .notifications-grid,
  .app-shell-unified-v211 .finance-grid,
  .app-shell-unified-v211 .payments-grid{grid-template-columns:repeat(auto-fit,minmax(190px,1fr))!important;}
}
@media(max-width:760px){
  .app-shell-unified-v211 .notifications-page .page-header,
  .app-shell-unified-v211 .documents-page .page-header,
  .app-shell-unified-v211 .reports-page .page-header,
  .app-shell-unified-v211 .report-page .page-header,
  .app-shell-unified-v211 .fik-page .page-header,
  .app-shell-unified-v211 .finance-page .page-header,
  .app-shell-unified-v211 .payments-page .page-header,
  .app-shell-unified-v211 .audit-page .page-header,
  .app-shell-unified-v211 .message-template-page .page-header,
  .app-shell-unified-v211 .operational-documents-page .page-header,
  .app-shell-unified-v211 .owner-documents-page .page-header,
  .app-shell-unified-v211 .owner-notifications-page .page-header,
  .app-shell-unified-v211 .owner-payments-page .page-header,
  .app-shell-unified-v211 .fik-header,
  .app-shell-unified-v211 .report-header,
  .app-shell-unified-v211 .section-header,
  .app-shell-unified-v211 .list-header{border-radius:20px!important;padding:18px!important;}
  .app-shell-unified-v211 .notification-card,
  .app-shell-unified-v211 .document-card,
  .app-shell-unified-v211 .report-card,
  .app-shell-unified-v211 .payment-card,
  .app-shell-unified-v211 .finance-card,
  .app-shell-unified-v211 .audit-card,
  .app-shell-unified-v211 .template-card,
  .app-shell-unified-v211 .operational-document-card,
  .app-shell-unified-v211 .message-card{border-radius:18px!important;}
}
