:root {
  color-scheme: light;
  --ink: #20242c;
  --muted: #667085;
  --line: #d9dee8;
  --panel: #ffffff;
  --soft: #f3f6fa;
  --accent: #1f7a68;
  --accent-strong: #155d50;
  --warning: #b86b00;
  --shadow: 0 16px 40px rgba(29, 38, 53, 0.08);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  display: grid;
  grid-template-columns: 330px 1fr;
  background: var(--soft);
  color: var(--ink);
  font-family: "Segoe UI", Arial, sans-serif;
  transition: grid-template-columns 0.2s ease;
}

body.sidebar-collapsed {
  grid-template-columns: 76px 1fr;
}

body.login-page {
  display: grid;
  grid-template-columns: 1fr;
  place-items: center;
  padding: 24px;
  background:
    linear-gradient(135deg, rgba(31, 122, 104, 0.14), rgba(255, 255, 255, 0) 42%),
    var(--soft);
}

.login-shell {
  display: grid;
  place-items: center;
  width: 100%;
  min-height: calc(100vh - 48px);
}

.login-panel {
  width: min(420px, 100%);
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.login-brand {
  display: flex;
  gap: 12px;
  align-items: center;
  padding: 22px;
  background: #17202b;
  color: #fff;
}

.login-brand small {
  display: block;
  margin-top: 3px;
  color: #b8c2cf;
}

.login-form {
  display: grid;
  gap: 16px;
  padding: 24px;
}

.login-form h1 {
  font-size: 28px;
}

.login-form p {
  margin-top: 6px;
  color: var(--muted);
}

.login-form input,
.login-form button {
  width: 100%;
}

.sidebar {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 10;
  display: flex;
  flex-direction: column;
  width: 330px;
  height: 100vh;
  padding: 14px 18px;
  background: #17202b;
  color: #fff;
  overflow-x: hidden;
  overflow-y: auto;
  transition: width 0.2s ease, padding 0.2s ease;
}

.sidebar-toggle {
  position: absolute;
  top: 18px;
  right: -14px;
  z-index: 2;
  display: grid;
  place-items: center;
  width: 28px;
  min-height: 28px;
  border-color: rgba(255, 255, 255, 0.22);
  border-radius: 999px;
  padding: 0;
  background: #223041;
  color: #fff;
  font-size: 20px;
  line-height: 1;
}

.sidebar-toggle:hover {
  border-color: var(--accent);
}

.brand {
  display: flex;
  gap: 10px;
  align-items: center;
  margin-bottom: 16px;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border-radius: 8px;
  background: var(--accent);
  font-weight: 700;
}

.brand small {
  display: block;
  margin-top: 3px;
  color: #b8c2cf;
}

nav {
  display: grid;
  gap: 3px;
  margin-bottom: 12px;
}

nav a,
.nav-group summary,
.sidebar-action {
  display: flex;
  gap: 10px;
  align-items: center;
  min-height: 34px;
  padding: 7px 12px;
  border-radius: 8px;
  color: #d6dde7;
  text-decoration: none;
}

nav a span,
.nav-group summary span,
.sidebar-action span {
  display: none;
  width: 20px;
  text-align: center;
  font-weight: 700;
}

nav a strong,
.nav-group summary strong,
.sidebar-action strong {
  font: inherit;
  font-weight: 600;
}

nav a.active,
nav a:hover,
.nav-group summary.active,
.nav-group summary:hover,
.sidebar-action:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
}

.nav-group {
  display: grid;
  gap: 3px;
}

.nav-group summary {
  cursor: pointer;
  list-style: none;
}

.nav-group summary::-webkit-details-marker {
  display: none;
}

.nav-group summary::after {
  content: "+";
  margin-left: auto;
  color: #9aa7b8;
  font-weight: 800;
}

.nav-group[open] summary::after {
  content: "-";
}

.nav-submenu {
  display: grid;
  gap: 2px;
  padding-left: 12px;
}

.nav-submenu a {
  min-height: 30px;
  padding-block: 5px;
  font-size: 13px;
}

.sidebar-action {
  min-height: auto;
  border: 0;
  background: transparent;
  cursor: pointer;
  text-align: left;
}

.sidebar-footer {
  margin-top: auto;
  padding-top: 10px;
}

.fullscreen-action {
  width: 100%;
  min-height: 30px;
  padding-block: 5px;
}

.sidebar-logout-form {
  width: 100%;
}

.sidebar-logout-action {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  min-height: 30px;
  padding: 5px 0;
  color: inherit;
}

.sidebar-filter {
  display: grid;
  gap: 6px;
  min-height: 0;
  padding-top: 10px;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
}

.sidebar-filter label {
  color: #d6dde7;
  font-size: 11px;
}

.sidebar-filter input[type="search"],
.sidebar-filter input[type="date"],
.sidebar-filter select {
  width: 100%;
  min-width: 0;
  min-height: 32px;
  border-color: rgba(255, 255, 255, 0.18);
  background: #223041;
  color: #fff;
  font-size: 11px;
}

.sidebar-filter input[type="search"]::placeholder {
  color: #9aa7b8;
}

.sidebar-filter select {
  color-scheme: dark;
}

.sidebar-filter .checkbox-filter {
  min-height: 24px;
  padding-bottom: 0;
  color: #d6dde7;
  font-size: 11px;
}

.sidebar-filter .checkbox-filter input {
  width: 13px;
  height: 13px;
  margin: 0;
}

.sidebar-filter-button {
  width: 100%;
  min-height: 32px;
  margin-top: 2px;
}

.sidebar-collapsed .sidebar {
  width: 76px;
  padding-inline: 16px;
}

.sidebar-collapsed .brand {
  justify-content: center;
}

.sidebar-collapsed .sidebar-text,
.sidebar-collapsed .sidebar-filter,
.sidebar-collapsed nav a strong,
.sidebar-collapsed .nav-group summary strong,
.sidebar-collapsed .nav-submenu,
.sidebar-collapsed .sidebar-action strong {
  display: none;
}

.sidebar-collapsed nav a,
.sidebar-collapsed .nav-group summary,
.sidebar-collapsed .sidebar-action {
  justify-content: center;
  padding-inline: 8px;
}

.sidebar-collapsed nav a span,
.sidebar-collapsed .nav-group summary span,
.sidebar-collapsed .sidebar-action span {
  display: block;
}

.sidebar-collapsed .nav-group summary::after {
  display: none;
}


.app-shell {
  grid-column: 2;
  min-width: 0;
  padding: 28px;
}

.topbar {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  align-items: center;
  margin-bottom: 22px;
}

h1,
h2,
p {
  margin: 0;
}

h1 {
  font-size: 30px;
  line-height: 1.15;
}

.topbar p {
  margin-top: 6px;
  color: var(--muted);
}

.topbar-actions {
  display: flex;
  gap: 10px;
  align-items: center;
}

.save-status {
  min-width: 118px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
  text-align: right;
}

.save-status.dirty {
  color: #a85f00;
}

.save-status.saving {
  color: var(--accent-strong);
}

.save-status.error {
  color: #b42318;
}

.logout-form {
  margin: 0;
}

button {
  min-height: 40px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0 16px;
  background: #fff;
  color: var(--ink);
  font-weight: 600;
  cursor: pointer;
}

button:hover {
  border-color: var(--accent);
}

button:disabled {
  cursor: not-allowed;
  opacity: 0.55;
}

.primary-button {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}

.primary-button:hover {
  background: var(--accent-strong);
}

.settings-panel {
  display: grid;
  gap: 16px;
  width: min(520px, 100%);
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  box-shadow: var(--shadow);
}

.settings-form {
  display: grid;
  gap: 16px;
}

.settings-form label {
  display: grid;
  gap: 7px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.settings-form input {
  width: 100%;
}

.settings-actions {
  display: flex;
  justify-content: flex-end;
}

.form-message {
  border-radius: 8px;
  padding: 12px 14px;
  font-size: 13px;
  font-weight: 700;
}

.form-message-error {
  background: #fef3f2;
  color: #b42318;
}

.form-message-success {
  background: #ecfdf3;
  color: #027a48;
}

.form-message-info {
  background: #eff6ff;
  color: #175cd3;
}

.icon-button {
  display: grid;
  place-items: center;
  width: 34px;
  min-height: 34px;
  padding: 0;
}

.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 20;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(23, 32, 43, 0.28);
}

.modal-backdrop[hidden] {
  display: none;
}

.modal {
  position: fixed;
  top: 50%;
  left: 50%;
  width: min(460px, 100%);
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  box-shadow: 0 24px 70px rgba(23, 32, 43, 0.24);
  padding: 20px;
  transform: translate(-50%, -50%);
  touch-action: none;
}

.modal-wide {
  width: min(980px, calc(100vw - 40px));
}

.modal-heading {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: start;
  margin-bottom: 18px;
  cursor: move;
  user-select: none;
}

.modal-heading h2 {
  font-size: 20px;
}

.modal-heading p,
.modal-hint,
.form-error {
  margin-top: 6px;
  color: var(--muted);
  font-size: 13px;
}

.modal input,
.modal select {
  width: 100%;
}

.schedule-modal {
  width: min(920px, calc(100vw - 40px));
}

.tolerance-modal {
  width: min(1280px, calc(100vw - 24px));
  padding: 16px;
}

.tolerance-modal .schedule-editor-wrap {
  max-height: 64vh;
}

.schedule-form-grid {
  display: grid;
  grid-template-columns: minmax(260px, 1fr) 180px 160px;
  gap: 12px;
  margin-bottom: 14px;
}

.schedule-form-grid label {
  display: grid;
  gap: 7px;
  color: var(--ink);
  font-size: 13px;
  font-weight: 700;
}

.schedule-form-grid label[hidden] {
  display: none;
}

.schedule-form-grid .schedule-checkbox-field {
  align-content: end;
  grid-template-columns: auto 1fr;
  align-items: center;
  min-height: 36px;
}

.schedule-form-grid .schedule-checkbox-field input {
  min-height: auto;
}

.schedule-flexible-lunch-badge {
  display: block;
  width: fit-content;
  margin-top: 4px;
  border-radius: 999px;
  padding: 2px 7px;
  background: #e0f2fe;
  color: #0369a1;
  font-size: 11px;
  font-weight: 700;
}

.schedule-form-grid input,
.schedule-form-grid select,
.schedule-editor-table input {
  min-height: 36px;
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
}

.schedule-form-grid select {
  padding: 0 10px;
}

.schedule-shift-fields {
  margin: 0 0 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 12px;
}

.schedule-shift-fields[hidden] {
  display: none;
}

.schedule-shift-fields legend {
  padding: 0 6px;
  color: var(--ink);
  font-size: 13px;
  font-weight: 800;
}

.schedule-shift-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(145px, 1fr));
  gap: 12px;
}

.schedule-shift-grid label {
  display: grid;
  gap: 6px;
  color: var(--ink);
  font-size: 12px;
  font-weight: 700;
}

.schedule-shift-grid label[hidden] {
  display: none;
}

.schedule-shift-grid input {
  min-width: 0;
  min-height: 36px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.schedule-shift-grid input[readonly] {
  background: var(--soft);
  font-weight: 800;
}

.schedule-number-suffix {
  display: grid;
  grid-template-columns: 1fr 34px;
}

.schedule-number-suffix input {
  border-radius: 8px 0 0 8px;
}

.schedule-number-suffix b {
  display: grid;
  place-items: center;
  border: 1px solid var(--line);
  border-left: 0;
  border-radius: 0 8px 8px 0;
  background: var(--soft);
  color: var(--muted);
}

.schedule-shift-grid .schedule-shift-exempt {
  align-content: end;
  grid-template-columns: auto 1fr;
  align-items: center;
  min-height: 36px;
}

.schedule-shift-grid .schedule-shift-exempt input {
  min-height: auto;
}

.schedule-editor-wrap {
  max-height: 52vh;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.schedule-editor-table {
  min-width: 680px;
}

.schedule-editor-table input {
  width: 112px;
  padding: 0 8px;
}

.table-muted {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 600;
}

.new-approver-modal {
  width: min(620px, calc(100vw - 40px));
}

.new-approver-body {
  display: grid;
  gap: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 16px;
  background: #f8fafc;
}

.new-approver-body label {
  display: grid;
  gap: 7px;
  color: var(--ink);
  font-size: 13px;
  font-weight: 700;
}

.new-approver-body input,
.new-approver-body select {
  width: 100%;
  min-height: 42px;
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
}

.new-approver-body select {
  padding: 0 10px;
}

.new-approver-actions {
  grid-template-columns: 1fr 1fr;
  margin-top: 16px;
}

.modal-table-wrap {
  max-height: 58vh;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.compact-table {
  min-width: 760px;
}

.compact-table th,
.compact-table td {
  padding: 7px 10px;
}

.vacation-summary {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 14px;
}

.vacation-summary article {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 12px;
  background: var(--soft);
}

.vacation-summary span,
.vacation-summary small {
  display: block;
  color: var(--muted);
  font-size: 12px;
}

.vacation-summary strong {
  display: block;
  margin: 4px 0;
  font-size: 22px;
}

.modal-hint {
  min-height: 18px;
}

.form-error {
  min-height: 18px;
  color: #9b1c1c;
  font-weight: 600;
}

.modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 16px;
}

.metrics {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 18px;
}

.metrics article,
.form-panel,
.toolbar,
.table-panel {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.metrics article {
  padding: 18px;
}

.metrics span {
  display: block;
  color: var(--muted);
  font-size: 13px;
  margin-bottom: 8px;
}

.metrics strong {
  font-size: 24px;
}

.analysis-map-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 18px;
}

.analysis-map-grid article {
  min-height: 138px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  box-shadow: var(--shadow);
}

.analysis-map-grid span {
  display: block;
  margin-bottom: 8px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
}

.analysis-map-grid strong {
  display: block;
  font-size: 18px;
}

.analysis-map-grid p {
  margin-top: 8px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.4;
}

.absence-legend {
  display: flex;
  gap: 8px;
  padding: 0 18px 14px;
}

.absence-chip {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 3px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
}

.vacation-chip,
.absence-vacation {
  background: #e6f4ef;
  color: #12624f;
}

.fault-chip,
.absence-fault {
  background: #fff2d8;
  color: #925300;
}

.weekend-chip,
.absence-weekend-column {
  background: #eef2f7;
  color: #475467;
}

.holiday-chip,
.absence-holiday-column {
  background: #fcebea;
  color: #9f1f1f;
}

.absence-map-wrap {
  max-height: calc(100vh - 112px);
  overflow: auto;
  border-top: 1px solid var(--line);
}

.mapas-page {
  font-size: 13px;
}

.mapas-page .app-shell {
  padding: 8px;
}

.mapas-page .sidebar {
  padding: 8px 10px;
}

.mapas-page .brand {
  margin-bottom: 8px;
}

.mapas-page nav {
  margin-bottom: 6px;
}

.mapas-page nav a,
.mapas-page .nav-group summary,
.mapas-page .sidebar-action {
  min-height: 28px;
  padding: 4px 8px;
}

.mapas-page .nav-submenu {
  padding-left: 8px;
}

.mapas-page .nav-submenu a {
  min-height: 26px;
  padding-block: 3px;
}

.mapas-page .sidebar-filter {
  gap: 4px;
  padding-top: 6px;
}

.mapas-page .sidebar-filter input[type="search"],
.mapas-page .sidebar-filter input[type="date"],
.mapas-page .sidebar-filter select {
  min-height: 28px;
}

.mapas-page .sidebar-filter-button {
  min-height: 30px;
}

.mapas-page .employee-tree {
  max-height: clamp(240px, calc(100vh - 390px), 520px);
}

.mapas-page .employee-tree-node summary,
.mapas-page .employee-tree-item {
  min-height: 24px;
  padding: 3px 5px;
}

.mapas-page .employee-tree-item strong {
  font-size: 10px;
}

.mapas-page .panel-heading {
  padding: 8px 10px;
}

.mapas-page .panel-heading h2 {
  font-size: 18px;
}

.mapas-page .panel-heading p,
.mapas-page .panel-heading span,
.mapas-page .absence-legend {
  font-size: 12px;
}

.mapas-page .absence-legend {
  gap: 6px;
  padding: 0 10px 8px;
}

.mapas-page .absence-chip {
  min-height: 20px;
  padding: 2px 7px;
}

.absence-map-table {
  min-width: max-content;
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
}

.absence-map-table th,
.absence-map-table td {
  min-width: 92px;
  max-width: 150px;
  height: 30px;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  padding: 3px 5px;
  text-align: center;
  vertical-align: middle;
}

.absence-map-table thead th {
  position: sticky;
  top: 0;
  z-index: 3;
  background: var(--panel);
  color: var(--muted);
  font-size: 11px;
}

.absence-map-table thead th span,
.absence-map-table thead th small {
  display: block;
}

.absence-map-table thead th small {
  margin-top: 2px;
  font-size: 9px;
  text-transform: lowercase;
}

.absence-map-table .absence-employee-column {
  position: sticky;
  left: 232px;
  z-index: 2;
  min-width: 220px;
  max-width: 220px;
  background: var(--panel);
  text-align: left;
}

.absence-map-table .absence-company-column,
.absence-map-table .absence-department-column {
  position: sticky;
  z-index: 2;
  background: var(--panel);
  text-align: left;
}

.absence-map-table .absence-company-column {
  left: 0;
  min-width: 82px;
  max-width: 82px;
}

.absence-map-table .absence-department-column {
  left: 82px;
  min-width: 150px;
  max-width: 150px;
}

.absence-map-table thead .absence-employee-column {
  z-index: 4;
}

.absence-map-table thead .absence-company-column,
.absence-map-table thead .absence-department-column {
  z-index: 4;
}

.absence-map-table .absence-employee-column strong {
  display: block;
  overflow: hidden;
  font-size: 12px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.absence-empty-cell {
  background: #fbfcfe;
}

.absence-empty-cell.absence-weekend-column {
  background: #eef2f7;
}

.absence-empty-cell.absence-holiday-column {
  background: #fcebea;
}

.absence-empty-cell.absence-weekend-column.absence-holiday-column {
  background: #f8e2e1;
}

.absence-cell {
  overflow: hidden;
  font-size: 10px;
  font-weight: 800;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.mapas-page .absence-planner {
  --absence-map-height: calc(100vh - 16px);
  --absence-map-header-height: 32px;
  --absence-map-row-height: calc((var(--absence-map-height) - var(--absence-map-header-height)) / 12);
  display: grid;
  grid-template-columns: minmax(0, 1fr) clamp(280px, 18vw, 320px);
  height: var(--absence-map-height);
  max-height: var(--absence-map-height);
  overflow: hidden;
  border: 1px solid #aeb7c2;
  background: #fff;
}

.absence-marking-page .app-shell {
  display: grid;
  gap: 18px;
  align-content: start;
}

.absence-marking-page .absence-planner {
  --absence-map-height: calc(100vh - 270px);
  grid-template-columns: minmax(0, 1fr) clamp(280px, 18vw, 320px);
  height: var(--absence-map-height);
  max-height: var(--absence-map-height);
}

.absence-marking-card {
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--panel);
  padding: 22px 24px;
  box-shadow: var(--shadow);
}

.absence-marking-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 18px;
}

.absence-marking-heading h1,
.absence-marking-heading p {
  margin: 0;
}

.absence-marking-heading h1 {
  margin: 3px 0 4px;
}

.absence-marking-heading > div > p:last-child,
.absence-form-help {
  color: var(--muted);
}

.absence-marking-form {
  display: grid;
  grid-template-columns: minmax(140px, .8fr) repeat(2, minmax(145px, .8fr)) minmax(190px, 1.2fr) minmax(120px, .6fr) minmax(210px, 1.4fr) auto;
  gap: 12px;
  align-items: end;
}

.absence-marking-form label:not(.checkbox-filter) {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: .82rem;
  font-weight: 700;
}

.absence-marking-form input,
.absence-marking-form select {
  width: 100%;
  min-height: 40px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
  padding: 8px 10px;
  color: var(--ink);
}

.absence-weekend-option {
  grid-column: 1 / -2;
  align-self: center;
}

.absence-marking-options {
  grid-column: 1 / -2;
  display: flex;
  flex-wrap: wrap;
  gap: 10px 24px;
  align-items: center;
}

.absence-submit-button {
  min-height: 42px;
  white-space: nowrap;
}

.absence-form-help {
  margin: 12px 0 0;
  font-size: .8rem;
}

.marking-status {
  min-height: 22px;
  font-weight: 700;
}

.marking-status.success { color: #16734b; }
.marking-status.error { color: #b42318; }
.marking-status.saving { color: var(--muted); }

.absence-marking-page .app-shell {
  gap: 10px;
  padding: 10px;
}

.absence-marking-page .absence-marking-card {
  border-color: #cbd5df;
  border-radius: 12px;
  padding: 12px 16px 10px;
  background: linear-gradient(135deg, #ffffff 0%, #f8fbfd 100%);
  box-shadow: 0 5px 18px rgba(15, 23, 42, 0.08);
}

.absence-marking-page .absence-marking-heading {
  gap: 14px;
  align-items: center;
  margin-bottom: 9px;
  padding-bottom: 8px;
  border-bottom: 1px solid #e2e8ef;
}

.absence-marking-page .absence-marking-heading .eyebrow {
  display: none;
}

.absence-marking-page .absence-marking-heading h1 {
  margin: 0 0 2px;
  color: #17202b;
  font-size: 20px;
  line-height: 1.15;
}

.absence-marking-page .absence-marking-heading > div > p:last-child {
  max-width: 900px;
  overflow: hidden;
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.absence-marking-page .marking-status:not(:empty) {
  min-height: auto;
  border-radius: 999px;
  padding: 5px 9px;
  background: #eef3f8;
  font-size: 11px;
  white-space: nowrap;
}

.absence-marking-page .absence-marking-form {
  grid-template-columns: minmax(160px, 1.1fr) 145px 145px minmax(180px, 1.2fr) minmax(165px, .85fr) auto;
  gap: 8px;
  border: 1px solid #e2e8ef;
  border-radius: 10px;
  padding: 9px 10px;
  background: #f5f8fb;
}

.absence-marking-page .absence-marking-form.has-hour-field {
  grid-template-columns: minmax(160px, 1.1fr) 145px 145px 110px minmax(180px, 1.2fr) minmax(165px, .85fr) auto;
}

@media (min-width: 1401px) {
  .absence-marking-page .absence-marking-form.has-vacation-year-field {
    grid-template-columns: minmax(145px, 1fr) 130px 130px minmax(180px, 1fr) minmax(120px, 1fr) 165px auto;
  }
  .absence-marking-page .absence-marking-form.has-vacation-year-field.has-hour-field {
    grid-template-columns: minmax(145px, 1fr) 130px 130px 95px minmax(180px, 1fr) minmax(100px, 1fr) 165px auto;
  }
}

.absence-marking-page .absence-marking-form > label,
.absence-marking-page .absence-marking-form input,
.absence-marking-page .absence-marking-form select {
  min-width: 0;
}

.absence-marking-page .absence-marking-form [hidden] {
  display: none;
}

.absence-marking-page .fault-code-combobox {
  position: relative;
  min-width: 0;
  display: grid;
  gap: 4px;
}

.absence-marking-page .fault-code-input-wrap { position: relative; }
.absence-marking-page #faultCodeSearch { padding-right: 30px; }
.absence-marking-page #faultCodeToggle {
  position: absolute;
  right: 1px;
  top: 1px;
  bottom: 1px;
  width: 28px;
  border: 0;
  background: transparent;
  color: var(--ink);
  cursor: pointer;
}
.absence-marking-page #faultCodeOptions {
  position: absolute;
  top: 100%;
  left: 0;
  z-index: 100;
  min-width: 100%;
  width: max-content;
  max-width: min(520px, 80vw);
  max-height: 320px;
  overflow-y: auto;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: #fff;
  box-shadow: 0 6px 18px #172b4d26;
  color: var(--ink);
  font-size: 12px;
}
.absence-marking-page #faultCodeOptions [role="option"],
.absence-marking-page .fault-code-empty { padding: 10px 12px; }
.absence-marking-page #faultCodeOptions [role="option"] { cursor: pointer; }
.absence-marking-page #faultCodeOptions [role="option"]:hover,
.absence-marking-page #faultCodeOptions [aria-selected="true"] { background: #e5f3f0; }

@media (min-width: 901px) and (max-width: 1600px) {
  .absence-marking-page .absence-marking-form.has-vacation-year-field,
  .absence-marking-page .absence-marking-form.has-vacation-year-field.has-hour-field {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

.absence-marking-page .absence-marking-form label:not(.checkbox-filter) {
  gap: 4px;
  color: #526174;
  font-size: 10px;
  letter-spacing: .02em;
  text-transform: uppercase;
}

.absence-marking-page .absence-marking-form input,
.absence-marking-page .absence-marking-form select {
  min-height: 34px;
  border-radius: 7px;
  padding: 6px 8px;
  font-size: 12px;
}

.absence-marking-page .absence-marking-options {
  grid-column: auto;
  display: grid;
  gap: 3px;
  align-self: stretch;
  align-content: center;
  border: 1px solid #d7e0e8;
  border-radius: 7px;
  padding: 4px 8px;
  background: #fff;
}

.absence-marking-page .absence-marking-options .checkbox-filter {
  min-height: 20px;
  padding: 0;
  color: #344054;
  font-size: 10px;
  white-space: nowrap;
}

.absence-marking-page .absence-submit-button {
  min-height: 36px;
  padding-inline: 14px;
  border-radius: 8px;
}

.absence-marking-page .absence-form-help {
  margin: 6px 2px 0;
  font-size: 10px;
}

.absence-marking-page .absence-planner {
  --absence-map-height: calc(100vh - 165px);
}

.absence-marking-page .absence-year-cell {
  padding: 0;
}

.absence-marking-page .absence-year-cell button {
  width: 100%;
  height: 100%;
  min-height: 30px;
  border: 0;
  background: transparent;
  color: inherit;
  cursor: pointer;
  display: grid;
  place-items: center;
  padding: 1px;
}

.absence-marking-page .absence-year-cell button:hover {
  box-shadow: inset 0 0 0 2px #2459a9;
}

.absence-marking-page .absence-year-cell.absence-marking-selected {
  box-shadow: inset 0 0 0 2px #174b91;
  filter: saturate(1.15);
}

.absence-marking-page .absence-year-cell.has-absences button {
  cursor: pointer;
}

.absence-delete-modal {
  width: min(680px, calc(100vw - 40px));
}

.absence-delete-range { /* alt chat 07.09.2026 - intervalo de desmarcação. */
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.absence-delete-range label { /* alt chat 07.09.2026 */
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.absence-delete-range input { /* alt chat 07.09.2026 */
  width: 100%;
  min-height: 42px;
  border: 1px solid var(--line);
  border-radius: 9px;
  padding: 8px 10px;
  background: #fff;
  color: var(--ink);
  font: inherit;
}

.absence-delete-list {
  display: grid;
  gap: 10px;
  max-height: min(55vh, 480px);
  overflow: auto;
}

.absence-delete-item {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 12px;
  background: #f8fafc;
}

.absence-delete-item input {
  width: 18px;
  height: 18px;
}

.absence-delete-item strong,
.absence-delete-item span,
.absence-delete-item small {
  display: block;
}

.absence-delete-item span,
.absence-delete-item small {
  margin-top: 3px;
  color: var(--muted);
  font-size: 12px;
}

.absence-delete-item em {
  border-radius: 999px;
  padding: 4px 8px;
  background: #e8eef6;
  color: #344054;
  font-size: 11px;
  font-style: normal;
  font-weight: 800;
  white-space: nowrap;
}

.absence-delete-item.is-protected {
  opacity: .72;
}

.danger-delete-button {
  border-color: #b42318;
  background: #b42318;
  color: #fff;
}

.danger-delete-button:hover {
  border-color: #8f1c13;
  background: #8f1c13;
}

@media (max-width: 1400px) {
  .absence-marking-page .absence-marking-form {
    grid-template-columns: repeat(3, minmax(160px, 1fr));
  }

  .absence-marking-page .absence-marking-form.has-hour-field {
    grid-template-columns: repeat(3, minmax(160px, 1fr));
  }

  .absence-marking-page .absence-planner {
    --absence-map-height: calc(100vh - 215px);
  }
}

@media (max-width: 900px) {
  .absence-marking-page .absence-marking-form,
  .absence-marking-page .absence-marking-form.has-hour-field {
    grid-template-columns: repeat(2, minmax(140px, 1fr));
  }

  .absence-marking-page .absence-planner {
    --absence-map-height: max(460px, calc(100vh - 300px));
  }
}

@media (max-width: 620px) {
  .absence-marking-page .absence-marking-heading {
    align-items: flex-start;
    flex-direction: column;
  }

  .absence-marking-page .absence-marking-heading > div > p:last-child {
    overflow: visible;
    white-space: normal;
  }

  .absence-marking-page .absence-marking-form,
  .absence-marking-page .absence-marking-form.has-hour-field {
    grid-template-columns: 1fr;
  }

  .absence-marking-page .absence-submit-button {
    width: 100%;
  }

  .absence-marking-page .absence-planner {
    --absence-map-height: 560px;
  }
}

.mapas-page .absence-calendar-panel {
  height: var(--absence-map-height);
  max-height: var(--absence-map-height);
  min-width: 0;
  overflow: auto;
  background: #eef3f8;
}

.mapas-page .banco-horas-planner {
  display: block;
}

.mapas-page .vacation-summary-panel {
  display: grid;
  grid-template-rows: auto 1fr;
  min-width: 0;
  border-left: 1px solid #aeb7c2;
  background: #f8fafc;
}

.mapas-page .vacation-summary-heading {
  display: flex;
  justify-content: space-between;
  gap: 6px;
  align-items: center;
  padding: 7px 9px;
  border-bottom: 1px solid #d8dee6;
  background: #17202b;
  color: #fff;
}

.mapas-page .vacation-summary-heading h2 {
  margin: 0;
  font-size: 14px;
}

.mapas-page .vacation-summary-heading span {
  color: #b8c2cf;
  font-size: 10px;
  font-weight: 700;
}

.mapas-page .vacation-summary-list {
  display: grid;
  align-content: start;
  gap: 4px;
  min-height: 0;
  overflow: auto;
  padding: 5px;
}

.mapas-page .vacation-summary-total,
.mapas-page .vacation-summary-card {
  border: 1px solid #d8dee6;
  border-radius: 8px;
  background: #fff;
}

.mapas-page .vacation-summary-total {
  display: grid;
  gap: 5px;
  padding: 6px;
}

.mapas-page .vacation-summary-total strong {
  color: #1f2937;
  font-size: 11px;
}

.mapas-page .vacation-summary-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 5px;
  padding: 6px;
}

.mapas-page .vacation-summary-person strong,
.mapas-page .vacation-summary-person small {
  display: block;
}

.mapas-page .vacation-summary-person strong {
  overflow: hidden;
  color: #1f2937;
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.mapas-page .vacation-summary-person small {
  margin-top: 2px;
  color: #667085;
  font-size: 9px;
}

.mapas-page .vacation-summary-table {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.mapas-page .vacation-summary-table-legend {
  color: #667085;
  font-size: 8px;
  font-weight: 700;
  text-align: right;
  text-transform: uppercase;
}

.mapas-page .vacation-summary-table-head,
.mapas-page .vacation-summary-table-row {
  display: grid;
  grid-template-columns: 42px minmax(64px, 1.2fr) minmax(64px, 1.2fr) minmax(48px, .8fr) minmax(42px, .7fr);
  gap: 1px;
  align-items: center;
  min-width: 0;
}

.mapas-page .vacation-summary-table-head {
  padding: 3px 4px 2px;
  border-bottom: 1px solid #edf1f5;
  color: #667085;
  font-size: 9px;
  font-weight: 700;
  text-transform: uppercase;
}

.mapas-page .vacation-summary-table-row {
  padding: 3px 2px;
  border: 1px solid transparent;
  border-radius: 6px;
  background: #f8fafc;
  cursor: default;
  outline: none;
  transition: border-color 0.15s ease, background 0.15s ease;
}

.mapas-page .vacation-summary-table-row.is-interactive {
  cursor: help;
}

.mapas-page .vacation-summary-table-row.is-interactive:hover,
.mapas-page .vacation-summary-table-row.is-interactive:focus {
  border-color: #65b8a7;
  background: #eef9f6;
}

.mapas-page .vacation-summary-table-head span:not(:first-child),
.mapas-page .vacation-summary-table-row b {
  text-align: right;
}

.mapas-page .vacation-summary-table-row strong {
  color: #204c34;
  font-size: 10px;
  font-weight: 800;
}

.mapas-page .vacation-summary-table-row strong span {
  color: #1f7a68;
  font-size: 9px;
}

.mapas-page .vacation-summary-ratio {
  display: grid;
  grid-template-columns: auto auto;
  gap: 1px;
  align-items: baseline;
  justify-content: flex-end;
  min-width: 0;
  overflow: hidden;
  white-space: nowrap;
}

.mapas-page .vacation-summary-ratio small {
  color: #667085;
  font-size: 8px;
  font-weight: 700;
}

.mapas-page .vacation-summary-table-row b {
  color: #17202b;
  font-size: 11px;
  font-weight: 800;
}

.mapas-page .vacation-summary-table-row b.negative {
  color: #b42318;
}

.mapas-page .vacation-summary-total .vacation-summary-ratio b {
  font-size: 9px;
}

.mapas-page .vacation-summary-total .vacation-summary-ratio small {
  font-size: 7px;
}

.vacation-summary-tooltip {
  position: fixed;
  z-index: 100;
  width: min(680px, calc(100vw - 16px));
  border: 1px solid #b9c5d2;
  border-radius: 12px;
  padding: 12px;
  background: #fff;
  color: #17202b;
  box-shadow: 0 18px 48px rgba(15, 23, 42, 0.24);
  pointer-events: none;
}

.vacation-summary-tooltip[hidden] {
  display: none;
}

.vacation-tooltip-heading {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  margin: -12px -12px 10px;
  padding: 10px 12px;
  border-radius: 11px 11px 0 0;
  background: #17202b;
  color: #fff;
}

.vacation-tooltip-heading small,
.vacation-tooltip-heading strong {
  display: block;
}

.vacation-tooltip-heading small {
  color: #b8c2cf;
  font-size: 9px;
}

.vacation-tooltip-heading strong {
  margin-top: 2px;
  font-size: 12px;
}

.vacation-tooltip-heading > span {
  flex: 0 0 auto;
  border-radius: 999px;
  padding: 4px 7px;
  background: rgba(255, 255, 255, 0.12);
  color: #d9f3ec;
  font-size: 9px;
  font-weight: 800;
  text-transform: uppercase;
}

.vacation-tooltip-metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 6px;
}

.vacation-tooltip-metrics article {
  display: grid;
  gap: 2px;
  border: 1px solid #dce4ec;
  border-radius: 8px;
  padding: 7px;
  background: #f8fafc;
}

.vacation-tooltip-metrics article.total {
  border-color: #9fd7ca;
  background: #eef9f6;
}

.vacation-tooltip-metrics span,
.vacation-tooltip-metrics small {
  color: #667085;
  font-size: 8px;
  font-weight: 700;
}

.vacation-tooltip-metrics strong {
  color: #17202b;
  font-size: 13px;
}

.vacation-tooltip-calculation,
.vacation-tooltip-extract,
.vacation-tooltip-source {
  display: grid;
  gap: 5px;
  margin-top: 9px;
  padding-top: 8px;
  border-top: 1px solid #e4e9ef;
}

.vacation-tooltip-calculation > strong,
.vacation-tooltip-extract > strong,
.vacation-tooltip-source > strong {
  color: #204c34;
  font-size: 10px;
}

.vacation-tooltip-calculation p {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  margin: 0;
  font-size: 9px;
}

.vacation-tooltip-calculation p span {
  color: #667085;
}

.vacation-tooltip-calculation p b {
  text-align: right;
}

.vacation-tooltip-extract-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 7px;
}

.vacation-tooltip-extract-grid.single-section {
  grid-template-columns: minmax(0, 1fr);
}

.vacation-tooltip-extract-grid section {
  min-width: 0;
  border: 1px solid #dce4ec;
  border-radius: 8px;
  background: #f8fafc;
  overflow: hidden;
}

.vacation-tooltip-extract-grid h4 {
  display: flex;
  justify-content: space-between;
  gap: 6px;
  margin: 0;
  padding: 6px 7px;
  background: #edf2f7;
  color: #344054;
  font-size: 9px;
  text-transform: uppercase;
}

.vacation-tooltip-extract-grid h4 span {
  color: #147d69;
}

.vacation-tooltip-extract-grid ul {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(112px, 1fr));
  gap: 3px;
  margin: 0;
  padding: 5px;
  list-style: none;
}

.vacation-tooltip-extract-grid li {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 7px;
  min-width: 0;
  padding: 4px 5px;
  border: 1px solid #e0e7ee;
  border-radius: 5px;
  background: #fff;
  font-size: 9px;
}

.vacation-tooltip-extract-grid li:first-child {
  border-top: 1px solid #e0e7ee;
}

.vacation-tooltip-extract-grid li > span,
.vacation-tooltip-extract-grid li > span small,
.vacation-tooltip-extract-grid li > span b {
  display: block;
  min-width: 0;
}

.vacation-tooltip-extract-grid li > span small {
  overflow: hidden;
  color: #667085;
  font-size: 8px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.vacation-tooltip-extract-grid li > span b {
  margin-top: 1px;
  color: #17202b;
  font-size: 9px;
}

.vacation-tooltip-extract-grid li > strong {
  flex: 0 0 auto;
  border-radius: 999px;
  padding: 2px 5px;
  background: #d9f3ec;
  color: #176b58;
  font-size: 8px;
}

.vacation-tooltip-extract-grid li.empty {
  display: block;
  grid-column: 1 / -1;
  color: #667085;
  line-height: 1.35;
}

.vacation-tooltip-extract-empty {
  margin: 0;
  border: 1px solid #dce4ec;
  border-radius: 8px;
  padding: 8px;
  background: #f8fafc;
  color: #667085;
  font-size: 9px;
}

.vacation-tooltip-source span {
  color: #667085;
  font-size: 9px;
  line-height: 1.4;
}

.vacation-tooltip-source code {
  border-radius: 3px;
  padding: 1px 3px;
  background: #edf2f7;
  color: #204c34;
  font-size: 8px;
}

.dias-extra-page .app-shell {
  display: grid;
  gap: 18px;
  align-content: start;
}

.extra-day-create-card {
  padding: 18px 20px;
}

.extra-day-create-card .absence-marking-heading {
  margin-bottom: 14px;
}

.extra-day-create-card h2,
.extra-day-create-card p {
  margin: 0;
}

.extra-day-form {
  display: grid;
  /* chat 23.09.2026 - campos podem encolher sem se sobreporem. */
  grid-template-columns: minmax(0, 120px) minmax(0, 120px) minmax(0, 1fr) auto;
  gap: 12px;
  align-items: end;
}

.extra-day-form label {
  display: grid;
  min-width: 0;
  gap: 6px;
  color: var(--muted);
  font-size: .82rem;
  font-weight: 700;
}

.extra-day-form input,
.extra-day-form select,
.extra-days-table-card input,
.extra-days-table-card select {
  width: 100%;
  min-height: 38px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  padding: 7px 9px;
  color: var(--ink);
}

.extra-days-table-card .table-scroll,
.extra-legacy-card .table-scroll {
  max-height: 46vh;
}

.table-actions {
  display: flex;
  gap: 6px;
  align-items: center;
}

.table-actions button {
  white-space: nowrap;
}

.danger-text-button {
  border-color: #f1c2bd;
  color: #b42318;
}

@media (max-width: 1400px) {
  /* chat 23.09.2026 - descrição e ação em linhas próprias quando há menos espaço. */
  .extra-day-form { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .extra-day-form .extra-description-field,
  .extra-day-form > button { grid-column: 1 / -1; }
}

/* chat 23.09.2026 - neutralizar a largura mínima global dos inputs neste formulário. */
.dias-extra-page .extra-day-form input,
.dias-extra-page .extra-day-form select {
  min-width: 0;
  max-width: 100%;
}
.extra-day-create-card,
.dias-extra-page .app-shell > * { min-width: 0; }
.extra-day-create-card .absence-marking-heading {
  flex-wrap: wrap;
  overflow-wrap: anywhere;
}
.extra-day-create-card .absence-marking-heading > * { min-width: 0; }
.extra-day-form > button { white-space: normal; }
@media (max-width: 640px) {
  .extra-day-form { grid-template-columns: minmax(0, 1fr); }
  .extra-day-create-card { padding: 14px; }
}

.mapas-page .absence-calendar-wrap {
  min-width: min(980px, 100%);
  height: var(--absence-map-height);
  max-height: var(--absence-map-height);
}

.mapas-page .absence-month-grid {
  height: var(--absence-map-height);
  max-height: var(--absence-map-height);
  padding: 0;
}

.mapas-page .absence-month-grid > .empty-state {
  margin: 18px;
}

.mapas-page .absence-year-table {
  width: 100%;
  min-width: 900px;
  height: var(--absence-map-height);
  max-height: var(--absence-map-height);
  table-layout: fixed;
  border-collapse: collapse;
  background: #fff;
  font-size: 12px;
}

.mapas-page .absence-year-table th,
.mapas-page .absence-year-table td {
  border: 1px solid #c7ccd3;
  padding: 0;
  text-align: center;
  vertical-align: middle;
}

.mapas-page .absence-year-table tbody tr {
  height: var(--absence-map-row-height);
  max-height: var(--absence-map-row-height);
}

.mapas-page .absence-year-table tbody th,
.mapas-page .absence-year-table tbody td {
  height: var(--absence-map-row-height);
  max-height: var(--absence-map-row-height);
  overflow: hidden;
}

.mapas-page .absence-year-table td {
  width: calc((100% - clamp(76px, 6vw, 104px)) / 37);
}

.mapas-page .absence-year-table thead th {
  position: sticky;
  top: 0;
  z-index: 3;
  height: var(--absence-map-header-height);
  background: #e8f3df;
  color: #204c34;
  font-size: 13px;
  font-weight: 800;
}

.mapas-page .absence-year-table thead .absence-weekend-head {
  background: #d6d8dc;
  color: #374151;
}

.mapas-page .absence-year-table .absence-week-divider {
  border-right-color: #7f8792;
  border-right-width: 2px;
}

.mapas-page .absence-year-corner,
.mapas-page .absence-year-month {
  position: sticky;
  left: 0;
  width: clamp(76px, 6vw, 104px);
  min-width: clamp(76px, 6vw, 104px);
  background: #dbeafe !important;
  color: #1f2937 !important;
  font-size: 13px;
  font-weight: 800;
  text-transform: lowercase;
  z-index: 2;
}

.mapas-page .absence-year-corner {
  z-index: 4;
  background: #fbf8d8 !important;
  color: #11610f !important;
}

.mapas-page .absence-year-cell {
  background: #fbfdff;
  color: #6b7280;
  font-weight: 700;
}

.mapas-page .absence-year-cell span,
.mapas-page .absence-year-cell strong {
  display: block;
  line-height: 1.1;
}

.mapas-page .absence-year-cell strong {
  margin-top: 2px;
  color: inherit;
  font-size: 12px;
}

.mapas-page .absence-year-weekend {
  background: #d9d9d9;
  color: #4b5563;
}

.mapas-page .absence-year-holiday {
  background: #f6b04b;
  color: #4a2500;
  font-weight: 800;
}

.mapas-page .absence-year-fault {
  background: #f8b8b8;
  color: #111827;
  font-weight: 800;
}

.mapas-page .absence-year-vacation {
  background: #4bc6c0;
  color: #082f49;
  font-weight: 800;
}

.mapas-page .absence-year-extra-vacation {
  background: #36a4d9;
  color: #06243a;
  font-weight: 800;
}

:is(.absence-marking-page, .absence-map-page) .absence-category-FN { background: #e2e8f0; color: #334155; }
:is(.absence-marking-page, .absence-map-page) .absence-category-S { background: #fed7aa; color: #7c2d12; }
:is(.absence-marking-page, .absence-map-page) .absence-category-B { background: #fef08a; color: #713f12; }
:is(.absence-marking-page, .absence-map-page) .absence-category-LP { background: #c7d2fe; color: #312e81; }
:is(.absence-marking-page, .absence-map-page) .absence-category-LM { background: #fbcfe8; color: #831843; }
/* chat 16.09.2026 - código histórico 160: identificação visual de Maternidade/Paternidade. */
:is(.absence-marking-page, .absence-map-page) .absence-category-LMP { background: #e9d5ff; color: #581c87; }
:is(.absence-marking-page, .absence-map-page) .absence-category-LC { background: #d9f99d; color: #365314; }
:is(.absence-marking-page, .absence-map-page) .absence-category-F { background: #f8b8b8; color: #111827; }
:is(.absence-marking-page, .absence-map-page) .absence-category-Prov { background: #fee2e2; color: #7f1d1d; }
:is(.absence-marking-page, .absence-map-page) .absence-category-FR { background: #4bc6c0; color: #082f49; }
:is(.absence-marking-page, .absence-map-page) .absence-category-FH { background: #e9d5ff; color: #581c87; }
:is(.absence-marking-page, .absence-map-page) .absence-category-FE { background: #36a4d9; color: #06243a; }
:is(.absence-marking-page, .absence-map-page) .absence-category-FEM { background: #bae6fd; color: #0c4a6e; }
:is(.absence-marking-page, .absence-map-page) .absence-category-mixed { background: #f8fafc; color: #334155; }
:is(.absence-marking-page, .absence-map-page) .absence-year-cell .absence-category-markers {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 2px;
}
:is(.absence-marking-page, .absence-map-page) .absence-category-markers strong {
  border-radius: 3px;
  padding: 1px 2px;
  font-size: 10px;
}
:is(.absence-marking-page, .absence-map-page) .absence-category-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-top: 6px;
  font-size: 10px;
}
:is(.absence-marking-page, .absence-map-page) .absence-category-legend span {
  padding: 3px 6px;
  border-radius: 4px;
}

:is(.absence-marking-page, .absence-map-page) .absence-sidebar-filter .absence-category-legend {
  padding-top: 6px;
  border-top: 1px solid #2f4053;
}

.mapas-page .absence-year-empty {
  background: #f1f5f9;
}

.mapas-page .absence-filter-actions {
  display: grid;
  gap: 4px;
}

.absence-filter-drawer-heading,
.absence-mobile-toolbar,
.absence-filter-backdrop {
  display: none;
}

.mapas-page .absence-filter-actions .link-button {
  justify-self: start;
  margin-top: 0;
}

.mapas-page .absence-sidebar-filter .absence-legend {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2px;
  padding-top: 4px;
  border-top: 1px solid #2f4053;
  background: transparent;
}

.mapas-page .legend-swatch {
  display: inline-block;
  width: 11px;
  height: 11px;
  flex: 0 0 11px;
  border: 1px solid #888;
}

.mapas-page .holiday-swatch {
  background: #f6b04b;
}

.mapas-page .fault-swatch {
  background: #f8b8b8;
}

.mapas-page .vacation-swatch {
  background: #4bc6c0;
}

.mapas-page .absence-map-summary {
  display: grid;
  gap: 6px;
  border-top: 1px solid #2f4053;
  padding-top: 8px;
  color: #9aa7b8;
  font-size: 11px;
}

.mapas-page .absence-map-summary strong {
  color: #b8dfd3;
}

body.sidebar-collapsed.mapas-page .absence-sidebar-filter {
  display: none;
}

.banco-horas-map {
  min-width: 1060px;
  padding: 12px;
}

.banco-horas-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  background: #fff;
  font-size: 12px;
}

.banco-horas-table th,
.banco-horas-table td {
  min-width: 72px;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  padding: 8px 9px;
  text-align: right;
  white-space: nowrap;
}

.banco-horas-table th {
  position: sticky;
  top: 0;
  z-index: 3;
  background: #e8f3df;
  color: #204c34;
  font-weight: 800;
}

/* comentado chat 12.10.2026: fixação anterior das três colunas de identificação.
.banco-horas-table th:first-child,
.banco-horas-table td:first-child {
  position: sticky;
  left: 0;
  z-index: 2;
  min-width: 86px;
  background: #fff;
  text-align: left;
}

.banco-horas-table th:nth-child(2),
.banco-horas-table td:nth-child(2) {
  position: sticky;
  left: 86px;
  z-index: 2;
  min-width: 150px;
  background: #fff;
  text-align: left;
}

.banco-horas-table th:nth-child(3),
.banco-horas-table td:nth-child(3) {
  position: sticky;
  left: 236px;
  z-index: 2;
  min-width: 230px;
  background: #fff;
  text-align: left;
}

.banco-horas-table thead th:first-child,
.banco-horas-table thead th:nth-child(2),
.banco-horas-table thead th:nth-child(3) {
  z-index: 4;
  background: #dbeafe;
  color: #1f2937;
}

*/
/* alterado chat 12.10.2026: uma única coluna de funcionário, libertando espaço para os saldos. */
.banco-horas-table .banco-horas-employee-column {
  position: sticky;
  left: 0;
  z-index: 2;
  min-width: 240px;
  width: 280px;
  max-width: 320px;
  background: #fff;
  text-align: left;
  white-space: normal;
  overflow-wrap: anywhere;
}
.banco-horas-table thead .banco-horas-employee-column {
  z-index: 4;
  background: #dbeafe;
  color: #1f2937;
}

.banco-horas-table td strong,
.banco-horas-table td small {
  display: block;
}

.banco-horas-table td small {
  margin-top: 3px;
  color: var(--muted);
  font-size: 10px;
}

.banco-horas-table .positive-hours {
  background: #ecfdf3;
  color: #027a48;
  font-weight: 800;
}

.banco-horas-table .negative-hours {
  background: #fef3f2;
  color: #b42318;
  font-weight: 800;
}

.banco-horas-table .zero-hours {
  color: #667085;
}

.banco-horas-detail-button {
  min-width: 70px;
}

.banco-horas-detail-modal {
  width: min(900px, calc(100vw - 32px));
  max-height: calc(100dvh - 32px);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  touch-action: auto;
}

.banco-horas-detail-modal .modal-heading {
  flex-shrink: 0;
}

.banco-horas-detail-modal .modal-heading > div {
  min-width: 0;
  overflow-wrap: anywhere;
}

.banco-horas-detail-modal .modal-table-wrap {
  min-height: 0;
  max-height: none;
  overflow: auto;
}

.banco-horas-detail-modal .banco-horas-detail-table {
  width: 100%;
  min-width: 0;
  table-layout: fixed;
}

.banco-horas-detail-modal .banco-horas-detail-table th,
.banco-horas-detail-modal .banco-horas-detail-table td {
  width: 33.333%;
  min-width: 0;
  padding: 10px 12px;
  font-variant-numeric: tabular-nums;
  overflow-wrap: anywhere;
}

.banco-horas-detail-modal .banco-horas-detail-table th {
  position: sticky;
  top: 0;
  background: #f1f5f9;
  z-index: 1;
}

.banco-horas-detail-summary {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 14px;
  flex-shrink: 0;
}

.banco-horas-detail-summary article {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 12px;
  background: #f8fafc;
}

.banco-horas-detail-summary span {
  display: block;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.banco-horas-detail-summary strong {
  display: block;
  margin-top: 5px;
  font-size: 20px;
  font-variant-numeric: tabular-nums;
  overflow-wrap: anywhere;
}

@media (max-width: 680px) {
  .banco-horas-detail-modal { padding: 14px; }
  .banco-horas-detail-summary { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
  .banco-horas-detail-summary article { padding: 9px; }
  .banco-horas-detail-summary strong { font-size: 17px; }
  .banco-horas-detail-modal .banco-horas-detail-table th,
  .banco-horas-detail-modal .banco-horas-detail-table td { padding: 8px 6px; }
}

@media (max-height: 500px) {
  .banco-horas-detail-modal { overflow-y: auto; }
  .banco-horas-detail-modal .modal-table-wrap { flex-shrink: 0; }
}

.banco-horas-detail-table th,
.banco-horas-detail-table td {
  text-align: right;
}

.banco-horas-detail-table th:first-child,
.banco-horas-detail-table td:first-child {
  text-align: left;
}

.banco-horas-detail-summary .positive-hours,
.banco-horas-detail-table .positive-hours {
  color: #027a48;
  font-weight: 800;
}

.banco-horas-detail-summary .negative-hours,
.banco-horas-detail-table .negative-hours {
  color: #b42318;
  font-weight: 800;
}

.banco-horas-detail-summary .zero-hours,
.banco-horas-detail-table .zero-hours {
  color: #667085;
}

.toolbar {
  display: flex;
  gap: 12px;
  align-items: end;
  padding: 14px;
  margin-bottom: 18px;
}

.form-panel {
  margin-bottom: 18px;
  overflow: hidden;
}

.aprovadores-form {
  display: grid;
  grid-template-columns: repeat(3, minmax(170px, 1fr));
  gap: 14px;
  padding: 18px;
}

.aprovadores-form input,
.aprovadores-form select {
  width: 100%;
  min-width: 0;
}

.sidebar-form {
  margin-top: 10px;
}

.sidebar-form-heading {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  align-items: center;
}

.sidebar-form-heading h2 {
  color: #fff;
  font-size: 13px;
}

.sidebar-form-heading span {
  color: #9aa7b8;
  font-size: 10px;
  font-weight: 700;
  white-space: nowrap;
}

.sidebar-form .aprovadores-form {
  grid-template-columns: 1fr;
  gap: 7px;
  padding: 0;
}

.sidebar-form .aprovadores-form label {
  color: #d6dde7;
  font-size: 11px;
}

.sidebar-form .aprovadores-form input {
  min-height: 30px;
  border-color: rgba(255, 255, 255, 0.18);
  background: #223041;
  color: #fff;
  font-size: 11px;
}

.sidebar-form .form-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  align-items: stretch;
}

.sidebar-form .form-actions .form-error {
  grid-column: 1 / -1;
  min-height: 14px;
  margin: 0;
  color: #ffd7d7;
  font-size: 10px;
}

.sidebar-form .form-actions button {
  min-height: 30px;
  padding: 0 10px;
  font-size: 11px;
}

.form-actions {
  display: flex;
  grid-column: 1 / -1;
  justify-content: flex-end;
  gap: 10px;
  align-items: center;
}

.form-actions .form-error {
  margin-right: auto;
}

label {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 600;
}

input,
select {
  min-height: 40px;
  min-width: 170px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0 10px;
  color: var(--ink);
  font: inherit;
  background: #fff;
}

/* alt chat 04.09.2026 - Processamento surge depois de Análises e antes de Configurações. */
.sidebar nav {
  display: flex;
  flex-direction: column;
}

.sidebar nav > .processing-nav-group {
  order: 1;
}

.sidebar nav > .nav-group:has(> summary[title^="Config"]) {
  order: 2;
}

/* alt chat 04.09.2026 - tabela de turno fixo com o design das Análises do portal. */
.processing-table-wrap { max-height: calc(100vh - 175px); overflow: auto; }
.processing-fixed-table { min-width: 2250px; }
.processamento-page[data-processing-type="rotativo"] .processing-fixed-table { min-width: 1050px; width: 100%; }
.processamento-page[data-processing-type="rotativo"] .processing-fixed-table td { padding: 10px; }
.processamento-page[data-processing-type="rotativo"] .processing-fixed-table td:first-child { min-width: 210px; white-space: normal; }
/* comentado chat 08.10.2026
.processamento-page[data-processing-type="rotativo"] .processing-fixed-table td:nth-child(n+3):nth-child(-n+8),
.processamento-page[data-processing-type="rotativo"] .processing-fixed-table td:nth-child(10),
.processamento-page[data-processing-type="rotativo"] .processing-fixed-table td:nth-child(11) { text-align: center; }
*/
/* .processamento-page[data-processing-type="rotativo"] .processing-fixed-table td:nth-child(n+2):nth-child(-n+7), comentado chat 09.10.2026 */
.processamento-page[data-processing-type="rotativo"] .processing-fixed-table td:nth-child(n+3):nth-child(-n+8), /* alterado chat 09.10.2026: alinhar os turnos após a coluna de salário. */
/* .processamento-page[data-processing-type="rotativo"] .processing-fixed-table td:nth-child(n+9):nth-child(-n+12) { text-align: center; } comentado chat 08.10.2026 */
.processamento-page[data-processing-type="rotativo"] .processing-fixed-table td:nth-child(n+9):nth-child(-n+11),
.processamento-page[data-processing-type="rotativo"] .processing-fixed-table td:nth-child(13) { text-align: center; } /* alterado chat 08.10.2026 */
.processing-table-wrap .processing-fixed-table thead { position: sticky; top: 0; z-index: 3; background: #f4f7f6; box-shadow: 0 1px 0 #d5ddeb; }
.processing-fixed-table th { background: #f4f7f6; text-align: center; vertical-align: middle; white-space: nowrap; }
.processing-fixed-table td { white-space: nowrap; }
.processing-shift-heading { background: #e8f3ef !important; color: #176b5b; font-weight: 900; }
.processing-empty-value { color: var(--muted); text-align: center; }
.processing-check-all { align-items: center; display: inline-flex; gap: 6px; }

/* alt chat 04.09.2026 - separação visual dos blocos Manhã, Tarde e Noite. */
/* comentado chat 08.10.2026
.processamento-page[data-processing-type="fixo"] .processing-fixed-table thead tr:nth-child(2) th:nth-child(-n+3),
.processamento-page[data-processing-type="fixo"] .processing-fixed-table tbody td:nth-child(n+4):nth-child(-n+6),
.processamento-page[data-processing-type="rotativo"] .processing-fixed-table thead tr:nth-child(2) th:nth-child(-n+2),
.processamento-page[data-processing-type="rotativo"] .processing-fixed-table tbody td:nth-child(n+3):nth-child(-n+4) { background: #f0faf6; }
.processamento-page[data-processing-type="fixo"] .processing-fixed-table thead tr:nth-child(2) th:nth-child(n+4):nth-child(-n+6),
.processamento-page[data-processing-type="fixo"] .processing-fixed-table tbody td:nth-child(n+7):nth-child(-n+9),
.processamento-page[data-processing-type="rotativo"] .processing-fixed-table thead tr:nth-child(2) th:nth-child(n+3):nth-child(-n+4),
.processamento-page[data-processing-type="rotativo"] .processing-fixed-table tbody td:nth-child(n+5):nth-child(-n+6) { background: #fff8eb; }
.processamento-page[data-processing-type="fixo"] .processing-fixed-table thead tr:nth-child(2) th:nth-child(n+7):nth-child(-n+9),
.processamento-page[data-processing-type="fixo"] .processing-fixed-table tbody td:nth-child(n+10):nth-child(-n+12),
.processamento-page[data-processing-type="rotativo"] .processing-fixed-table thead tr:nth-child(2) th:nth-child(n+5):nth-child(-n+6),
.processamento-page[data-processing-type="rotativo"] .processing-fixed-table tbody td:nth-child(n+7):nth-child(-n+8) { background: #f3f1fb; }
*/
/* alterado chat 08.10.2026: cores alinhadas com as novas colunas dos turnos rotativos. */
.processamento-page[data-processing-type="fixo"] .processing-fixed-table thead tr:nth-child(2) th:nth-child(-n+3),
.processamento-page[data-processing-type="fixo"] .processing-fixed-table tbody td:nth-child(n+4):nth-child(-n+6),
.processamento-page[data-processing-type="rotativo"] .processing-fixed-table thead tr:nth-child(2) th:nth-child(-n+2),
/* .processamento-page[data-processing-type="rotativo"] .processing-fixed-table tbody td:nth-child(n+2):nth-child(-n+3) { background: #f0faf6; } comentado chat 09.10.2026 */
.processamento-page[data-processing-type="rotativo"] .processing-fixed-table tbody td:nth-child(n+3):nth-child(-n+4) { background: #f0faf6; } /* alterado chat 09.10.2026 */
.processamento-page[data-processing-type="fixo"] .processing-fixed-table thead tr:nth-child(2) th:nth-child(n+4):nth-child(-n+6),
.processamento-page[data-processing-type="fixo"] .processing-fixed-table tbody td:nth-child(n+7):nth-child(-n+9),
.processamento-page[data-processing-type="rotativo"] .processing-fixed-table thead tr:nth-child(2) th:nth-child(n+3):nth-child(-n+4),
/* .processamento-page[data-processing-type="rotativo"] .processing-fixed-table tbody td:nth-child(n+4):nth-child(-n+5) { background: #fff8eb; } comentado chat 09.10.2026 */
.processamento-page[data-processing-type="rotativo"] .processing-fixed-table tbody td:nth-child(n+5):nth-child(-n+6) { background: #fff8eb; } /* alterado chat 09.10.2026 */
.processamento-page[data-processing-type="fixo"] .processing-fixed-table thead tr:nth-child(2) th:nth-child(n+7):nth-child(-n+9),
.processamento-page[data-processing-type="fixo"] .processing-fixed-table tbody td:nth-child(n+10):nth-child(-n+12),
.processamento-page[data-processing-type="rotativo"] .processing-fixed-table thead tr:nth-child(2) th:nth-child(n+5):nth-child(-n+6),
/* .processamento-page[data-processing-type="rotativo"] .processing-fixed-table tbody td:nth-child(n+6):nth-child(-n+7) { background: #f3f1fb; } comentado chat 09.10.2026 */
.processamento-page[data-processing-type="rotativo"] .processing-fixed-table tbody td:nth-child(n+7):nth-child(-n+8) { background: #f3f1fb; } /* alterado chat 09.10.2026 */
/* .processing-fixed-table thead tr:first-child .processing-shift-heading:nth-of-type(3) { background: #f6ecd5 !important; color: #9a5a00; } comentado chat 04.09.2026 */
/* .processing-fixed-table thead tr:first-child .processing-shift-heading:nth-of-type(4) { background: #e9e5f6 !important; color: #5b3f91; } comentado chat 04.09.2026 */
.processing-fixed-table thead tr:first-child .processing-shift-heading:nth-of-type(4) { background: #f6ecd5 !important; color: #9a5a00; } /* alt chat 04.09.2026 - Tarde. */
.processing-fixed-table thead tr:first-child .processing-shift-heading:nth-of-type(5) { background: #e9e5f6 !important; color: #5b3f91; } /* alt chat 04.09.2026 - Noite. */
/* Separadores verticais dos blocos comentados chat 04.09.2026 - as cores já distinguem Manhã, Tarde e Noite. */
.processing-fixed-table th:last-child,
.processing-fixed-table td:last-child { min-width: 72px; width: 72px; } /* alt chat 04.09.2026 - coluna de seleção compacta. */
.processing-fixed-table input[type="checkbox"],
.processing-check-all input[type="checkbox"] { height: 15px; min-height: 15px; min-width: 15px; width: 15px; } /* alt chat 04.09.2026 - checkbox discreto como no restante portal. */

.employee-filter {
  align-self: stretch;
}

.employee-filter input {
  min-width: 0;
}

.employee-tree-summary {
  color: #b8dfd3;
  font-size: 10px;
  font-weight: 700;
}

.employee-tree {
  width: 100%;
  max-height: clamp(260px, calc(100vh - 330px), 560px);
  overflow: auto;
  border: 1px solid rgba(255, 255, 255, 0.13);
  border-radius: 8px;
  padding: 4px;
  background: #111a25;
}

.employee-tree-node {
  margin-bottom: 2px;
}

.employee-tree-node summary {
  display: grid;
  grid-template-columns: 12px 12px minmax(0, 1fr) auto;
  align-items: center;
  gap: 5px;
  min-height: 20px;
  border-radius: 6px;
  padding: 1px 4px;
  cursor: pointer;
  list-style: none;
  color: #edf2f7;
  font-size: 10px;
}

.employee-tree-node summary::-webkit-details-marker {
  display: none;
}

.employee-tree-node summary::before {
  content: "+";
  display: inline-grid;
  place-items: center;
  width: 12px;
  height: 12px;
  color: #9aa7b8;
  font-weight: 800;
}

.employee-tree-node[open] > summary::before {
  content: "-";
}

.employee-tree-node summary:hover,
.employee-tree-item:hover {
  background: rgba(255, 255, 255, 0.08);
}

.employee-tree-node summary input,
.employee-tree-item input {
  width: 11px;
  height: 11px;
  min-width: auto;
  min-height: auto;
  margin: 0;
}

.employee-tree-node summary span,
.employee-tree-item span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.employee-tree-item span {
  display: block;
}

.employee-tree-item strong {
  overflow: hidden;
  color: #edf2f7;
  font: inherit;
  font-weight: 700;
  text-overflow: ellipsis;
}

.employee-tree-item small {
  overflow: hidden;
  color: #9aa7b8;
  font-size: 9px;
  font-weight: 600;
  text-overflow: ellipsis;
}

.employee-tree-node summary small {
  color: #9aa7b8;
  font-size: 9px;
  font-weight: 700;
}

.employee-tree-children {
  margin-left: 16px;
}

.employee-tree-company > .employee-tree-children {
  margin-left: 10px;
}

.employee-tree-item {
  display: grid;
  grid-template-columns: 12px minmax(0, 1fr);
  align-items: center;
  gap: 5px;
  min-height: 19px;
  border-radius: 6px;
  padding: 1px 4px;
  color: #edf2f7;
  font-size: 10px;
  font-weight: 500;
}

.employee-tree-empty {
  margin: 0;
  padding: 6px;
  color: #9aa7b8;
  font-size: 10px;
}

.link-button {
  justify-self: start;
  min-height: auto;
  border: 0;
  padding: 0;
  background: transparent;
  color: #b8dfd3;
  font-size: 10px;
}

.approver-list {
  display: grid;
  gap: 5px;
  max-height: clamp(220px, calc(100vh - 260px), 620px);
  overflow: auto;
  border: 1px solid rgba(255, 255, 255, 0.13);
  border-radius: 8px;
  padding: 5px;
  background: #111a25;
}

.approver-list-item {
  display: grid;
  gap: 2px;
  justify-items: start;
  width: 100%;
  min-height: auto;
  border: 1px solid transparent;
  border-radius: 6px;
  padding: 6px 7px;
  background: transparent;
  color: #edf2f7;
  text-align: left;
}

.approver-list-item:hover,
.approver-list-item.active {
  border-color: rgba(184, 223, 211, 0.28);
  background: rgba(255, 255, 255, 0.08);
}

.approver-list-item strong,
.approver-list-item span {
  width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.approver-list-item strong {
  font-size: 11px;
}

.approver-list-item span,
.approver-list-item small {
  color: #9aa7b8;
  font-size: 10px;
  font-weight: 700;
}

.checkbox-filter {
  align-items: center;
  display: flex;
  gap: 8px;
  min-height: 40px;
  padding-bottom: 1px;
}

.checkbox-filter input {
  min-height: auto;
  min-width: auto;
}

/* alt chat 04.09.2026 - filtros apresentados apenas quando há equipas indiretas. */
.indirect-team-filters {
  display: grid;
  gap: 8px;
}

.indirect-team-filters[hidden],
.indirect-team-filters label[hidden] {
  display: none;
}

.table-panel {
  overflow: hidden;
}

.panel-heading {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 18px;
  border-bottom: 1px solid var(--line);
}

.panel-heading-main,
.panel-heading-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.panel-heading-actions {
  flex: 0 0 auto;
  flex-wrap: wrap;
  justify-content: flex-end;
  margin-left: auto;
  white-space: nowrap;
}

.panel-heading-main > .panel-heading-actions {
  margin-left: 0;
}

.panel-heading h2 {
  font-size: 18px;
}

.panel-heading p {
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
}

.panel-heading span {
  color: var(--muted);
  font-size: 13px;
}

.approver-team-panel {
  display: flex;
  flex-direction: column;
  min-height: calc(100vh - 132px);
}

.approver-team-toolbar {
  display: flex;
  gap: 12px;
  align-items: end;
  padding: 12px 18px;
  border-bottom: 1px solid var(--line);
}

.approver-team-toolbar label:first-child {
  flex: 1 1 auto;
}

.approver-team-toolbar input[type="search"] {
  width: 100%;
}

.approver-team-tree {
  flex: 1 1 auto;
  max-height: none;
  min-height: 420px;
  border: 0;
  border-radius: 0;
  padding: 10px 14px 16px;
  background: var(--panel);
  color: var(--ink);
}

.approver-team-tree .employee-tree-node {
  margin-bottom: 6px;
}

.approver-team-tree .employee-tree-node summary {
  grid-template-columns: 18px 16px minmax(0, 1fr) auto;
  gap: 9px;
  min-height: 30px;
  padding: 5px 8px;
  font-size: 12px;
}

.approver-team-tree .employee-tree-node summary::before {
  width: 16px;
  height: 16px;
}

.approver-team-tree .employee-tree-node summary input,
.approver-team-tree .employee-tree-item input {
  width: 14px;
  height: 14px;
}

.approver-team-tree .employee-tree-children {
  margin-top: 4px;
  margin-left: 28px;
}

.approver-team-tree .employee-tree-company > .employee-tree-children {
  margin-left: 22px;
}

.approver-team-tree .employee-tree-node:not(.employee-tree-company) > .employee-tree-children {
  margin-left: 42px;
  padding-left: 10px;
  border-left: 1px solid #d9dee8;
}

.approver-team-tree .employee-tree-item {
  grid-template-columns: 16px minmax(0, 1fr);
  gap: 10px;
  min-height: 28px;
  margin-bottom: 4px;
  padding: 4px 8px 4px 10px;
  font-size: 12px;
}

.approver-team-tree .employee-tree-node summary,
.approver-team-tree .employee-tree-item {
  color: var(--ink);
}

.approver-team-tree .employee-tree-node summary:hover,
.approver-team-tree .employee-tree-item:hover {
  background: #eef5f2;
}

.approver-team-tree .employee-tree-item strong {
  color: var(--ink);
}

.approver-team-tree .employee-tree-item.disabled {
  cursor: not-allowed;
  opacity: 0.58;
}

.approver-team-tree .employee-tree-item.disabled:hover {
  background: transparent;
}

.approver-team-tree .employee-tree-item.disabled input {
  cursor: not-allowed;
}

.approver-team-tree .employee-tree-node summary small,
.approver-team-tree .employee-tree-item small {
  color: var(--muted);
}

.table-wrap {
  overflow-x: auto;
}

table {
  width: 100%;
  border-collapse: collapse;
  min-width: 900px;
}

.aprovadores-table {
  min-width: 1040px;
}

.funcionarios-table {
  min-width: 920px;
}

.horarios-table {
  min-width: 980px;
}

.horarios-table th,
.horarios-table td {
  padding: 5px 8px;
}

/* chat 29.09.2026 - sete dias na listagem de horários. */
.horarios-table th:nth-child(n + 2):nth-child(-n + 8),
.horarios-table td:nth-child(n + 2):nth-child(-n + 8) {
  font-size: 11px;
  line-height: 1.25;
}

.horarios-table th:first-child,
.horarios-table td:first-child {
  width: 165px;
}

.horarios-table th:nth-child(9),
.horarios-table td:nth-child(9) {
  width: 76px;
}

.horarios-table th:last-child,
.horarios-table td:last-child {
  width: 150px;
}

.ty-table {
  min-width: 1160px;
}

/* adicionado chat 12.10.2026 - checkboxes compactas na tabela e no formulário de tipos de faltas. */
.ty-table input[type="checkbox"],
.ty-flags-fieldset input[type="checkbox"] {
  width: 15px;
  height: 15px;
  min-width: 15px;
  min-height: 15px;
  padding: 0;
  margin: 0;
  flex: 0 0 15px;
  vertical-align: middle;
}

.ty-flags-fieldset {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 10px 18px;
  margin-top: 18px;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: 10px;
}

.ty-flags-fieldset legend {
  padding: 0 7px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.ty-flags-fieldset label {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 13px;
  font-weight: 700;
}

.feriados-table {
  min-width: 1220px;
}

.holiday-company-fieldset {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 22px;
  margin: 18px 0 0;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: 10px;
}

.holiday-company-fieldset legend {
  padding: 0 7px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.holiday-company-fieldset label {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 13px;
  font-weight: 700;
}

.holiday-company-fieldset small {
  flex-basis: 100%;
  color: var(--muted);
}

.ferias-table {
  min-width: 1320px;
}

.tolerance-table {
  min-width: 980px;
}

.schedules-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 150px;
  gap: 16px;
  align-items: start;
}

.schedule-graph-panel {
  overflow: hidden;
}

.schedule-graph-panel .panel-heading {
  padding: 12px;
}

.schedule-graph-panel .panel-heading h2 {
  font-size: 16px;
}

.schedule-graph-panel .panel-heading p {
  max-width: 120px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.schedule-day-graph {
  display: grid;
  grid-template-rows: auto minmax(400px, calc(100vh - 390px));
  min-width: 0;
  border-top: 1px solid var(--line);
  padding: 10px;
  background: #f8fafc;
}

.schedule-day-graph-heading {
  display: grid;
  gap: 6px;
  margin-bottom: 8px;
}

.schedule-day-graph-heading strong {
  font-size: 12px;
}

.schedule-day-graph-heading div {
  display: grid;
  gap: 3px;
  color: var(--muted);
  font-size: 10px;
  font-weight: 700;
}

.schedule-day-graph-heading span {
  display: inline-flex;
  gap: 5px;
  align-items: center;
}

.schedule-day-graph-heading i {
  display: inline-block;
  width: 10px;
  height: 10px;
  border: 1px solid rgba(0, 0, 0, 0.12);
  border-radius: 3px;
}

.schedule-day-graph-heading i.free {
  background: #4fd36f;
}

.schedule-day-graph-heading i.work {
  background: #5a9ee8;
}

.schedule-day-graph-heading i.break {
  background: #ff5b5b;
}

.schedule-day-graph-body {
  display: grid;
  grid-template-columns: 34px 1fr;
  min-height: 0;
}

.schedule-day-scale,
.schedule-day-track {
  position: relative;
  min-height: 400px;
}

.schedule-day-scale span {
  position: absolute;
  right: 5px;
  translate: 0 -50%;
  color: #38536f;
  font-size: 10px;
  font-weight: 800;
  line-height: 1;
}

.schedule-day-track {
  overflow: hidden;
  border: 1px solid #2d6241;
  border-radius: 6px;
  background:
    repeating-linear-gradient(
      to bottom,
      rgba(255, 255, 255, 0.34) 0,
      rgba(255, 255, 255, 0.34) 1px,
      transparent 1px,
      transparent calc(100% / 24)
    ),
    linear-gradient(90deg, #24b747, #8af28e 45%, #1fa741);
}

.schedule-day-block {
  position: absolute;
  left: 8px;
  right: 8px;
  min-height: 3px;
  border: 1px solid rgba(0, 0, 0, 0.2);
  box-shadow: inset 0 0 10px rgba(255, 255, 255, 0.42);
}

.schedule-day-block.work {
  background: linear-gradient(90deg, #2d75c4, #8bc2ff 50%, #1e63ae);
}

.schedule-day-block.break {
  left: 10px;
  right: 10px;
  background: linear-gradient(90deg, #dd2f2f, #ff9c9c 50%, #c92424);
}

.tolerance-layout {
  display: grid;
  grid-template-columns: 310px minmax(0, 1fr);
  gap: 16px;
}

.tolerance-schedule-panel,
.tolerance-period-panel {
  min-height: calc(100vh - 248px);
}

.tolerance-schedule-list {
  display: grid;
  gap: 5px;
  max-height: calc(100vh - 318px);
  overflow: auto;
  padding: 10px;
}

.tolerance-table input,
.tolerance-table select {
  width: 100%;
  min-width: 0;
  min-height: 30px;
  border-radius: 6px;
  font-size: 12px;
}

.tolerance-table input[type="number"] {
  width: 82px;
}

.tolerance-table input[type="checkbox"] {
  width: 16px;
  min-width: 16px;
  min-height: 16px;
}

.tolerance-period-panel .form-error {
  padding-inline: 18px;
}

th,
td {
  padding: 6px 10px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: middle;
}

th {
  color: var(--muted);
  font-size: 12px;
  text-transform: uppercase;
}

td {
  font-size: 13px;
}

.action-cell {
  text-align: right;
  white-space: nowrap;
}

.punch-row {
  cursor: grab;
}

.punch-row:active {
  cursor: grabbing;
}

.dragging-punch {
  opacity: 0.45;
}

.day-group td.drop-target {
  outline: 2px solid var(--accent);
  outline-offset: -3px;
  background: #dff1eb;
}

.row-action {
  display: inline-grid;
  place-items: center;
  width: 26px;
  min-height: 24px;
  padding: 0;
  white-space: nowrap;
  margin-left: 6px;
  margin-right: 0;
}

.schedule-actions {
  display: flex;
  gap: 6px;
  align-items: center;
  justify-content: flex-end;
}

.selected-schedule-row td {
  background: #eef5f2;
}

.table-action-button {
  min-height: 26px;
  border-radius: 6px;
  padding: 0 8px;
  font-size: 12px;
}

.group-toggle {
  display: inline-grid;
  place-items: center;
  width: 22px;
  min-height: 22px;
  margin-right: 8px;
  border-color: currentColor;
  border-radius: 6px;
  padding: 0;
  background: transparent;
  color: inherit;
  font-size: 16px;
  line-height: 1;
}

.secondary-action {
  color: var(--accent-strong);
}

.add-punch-action {
  width: auto;
  min-height: 24px;
  border-color: var(--accent);
  color: var(--accent-strong);
  padding: 0 8px;
}

.danger-action {
  color: #9b1c1c;
}

.status-pill {
  display: inline-grid;
  place-items: center;
  min-width: 68px;
  min-height: 26px;
  border-radius: 8px;
  padding: 0 10px;
  font-size: 12px;
  font-weight: 700;
}

.status-active {
  background: #dff1eb;
  color: var(--accent-strong);
}

.status-inactive {
  background: #f4e6e6;
  color: #9b1c1c;
}

.status-warning {
  background: #fff3d6;
  color: var(--warning);
}

.muted-line {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 500;
}

.color-swatch {
  display: inline-block;
  width: 18px;
  height: 18px;
  border: 1px solid var(--line);
  border-radius: 6px;
  margin-right: 8px;
  vertical-align: middle;
}

.pill-list {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.mini-pill {
  display: inline-grid;
  place-items: center;
  min-height: 24px;
  border-radius: 8px;
  padding: 0 8px;
  background: #eef5f2;
  color: var(--accent-strong);
  font-size: 12px;
  font-weight: 700;
}

.ignored-punch {
  color: var(--muted);
  opacity: 0.58;
}

.ignored-punch td:not(:last-child) {
  text-decoration: line-through;
}

.missing-record-row td {
  background: #fffaf0;
  color: var(--warning);
  font-weight: 700;
}

.day-group td {
  background: #eef5f2;
  color: var(--accent-strong);
  font-size: 13px;
  letter-spacing: 0;
  padding: 5px 10px;
}

.day-group-content {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: center;
}

.day-group-main {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  min-width: 0;
}

.day-group strong {
  margin-right: 10px;
}

.day-group span {
  color: var(--muted);
  font-weight: 600;
  margin-right: 10px;
}

.day-group small {
  color: var(--accent-strong);
  font-size: 12px;
  font-weight: 700;
  margin-right: 8px;
}

.day-group-ignored {
  flex: 0 0 auto;
  margin-left: auto;
  color: var(--muted);
  font-weight: 700;
  white-space: nowrap;
}

.visible-totals-row td {
  position: sticky;
  bottom: 0;
  z-index: 2;
  border-top: 1px solid var(--accent);
  background: #f4f8f6;
  color: var(--accent-strong);
  font-size: 12px;
  font-weight: 700;
}

.visible-totals-content {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 12px;
}

.visible-totals-content strong {
  margin-right: 4px;
  color: var(--ink);
}

.visible-totals-content span {
  white-space: nowrap;
}

.employee-group td {
  background: #f8fafc;
  color: var(--ink);
  font-size: 13px;
  padding: 5px 10px 5px 22px;
}

.employee-group-content {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
}

.employee-summary {
  display: flex;
  flex-wrap: wrap;
  gap: 0;
  align-items: center;
}

.employee-group span {
  color: var(--ink);
  font-weight: 600;
  margin-right: 10px;
}

.treated-group td {
  background: #f2f8f5;
}

/* alt chat 04.09.2026 - diferencia claramente registos indiretos apenas para consulta. */
.employee-group.indirect-team-group td {
  background: #f5f3ff;
}

.employee-group .indirect-team-badge {
  color: #6d28d9;
  font-weight: 900;
}

.indirect-team-group button:disabled,
.indirect-team-group input:disabled,
.indirect-team-group input[readonly],
.indirect-team-group select:disabled,
.punch-row[data-readonly-indirect="1"] button:disabled,
.punch-row[data-readonly-indirect="1"] input:disabled {
  cursor: not-allowed;
  opacity: 0.58;
}

.treated-toggle {
  display: inline-grid;
  place-items: center;
  min-height: 22px;
  margin-right: 10px;
  border-color: #c7d2da;
  border-radius: 6px;
  padding: 0 8px;
  background: #fff;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.treated-toggle.treated-active {
  border-color: #b8dfd3;
  background: #dff1eb;
  color: var(--accent-strong);
}

.extra-approval-checks {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-right: 10px;
}

.extra-approval-toggle {
  min-height: 22px;
  border-color: #d8c08c;
  border-radius: 6px;
  padding: 0 7px;
  background: #fffaf0;
  color: #925300;
  font-size: 11px;
  font-weight: 800;
}

.extra-approval-toggle.extra-approval-active {
  border-color: #b8dfd3;
  background: #dff1eb;
  color: var(--accent-strong);
}

.extra-approval-summary {
  color: var(--warning);
  font-weight: 800;
}

.treated-group .extra-approval-summary {
  color: var(--accent-strong);
}

.time-edit {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  white-space: nowrap;
}

.time-edit input {
  width: 58px;
  min-width: 58px;
  min-height: 24px;
  border-radius: 6px;
  padding: 0 6px;
  font-size: 12px;
}

.original-time {
  color: var(--muted);
  font-size: 11px;
  text-decoration: line-through;
}

.punch-period-total {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  min-height: 22px;
  padding: 2px 7px;
  border: 1px solid #b7d8ce;
  border-radius: 999px;
  background: #edf8f4;
  color: #32695c;
  font-size: 11px;
  white-space: nowrap;
}

.punch-period-total strong {
  color: #174f43;
  font-variant-numeric: tabular-nums;
}

.punch-period-total.is-below-expected {
  border-color: #f0a8a8;
  background: #fff0f0;
  color: #b42318;
}

.punch-period-total.is-below-expected strong {
  color: #b42318;
}

.punch-period-total.has-automatic-lunch {
  border-color: #8fc9dc;
  background: #eef9fc;
  color: #23657a;
}

.punch-period-total.has-automatic-lunch strong {
  color: #174f63;
}

.punch-period-total.has-automatic-lunch.is-below-expected {
  border-color: #f0a8a8;
  background: #fff0f0;
  color: #b42318;
}

.punch-period-total.has-automatic-lunch.is-below-expected strong {
  color: #b42318;
}

.time-edit input[disabled] {
  border-width: 0;
  border-color: transparent;
  background: transparent;
  color: var(--muted);
  cursor: default;
  opacity: 1;
  outline: 0;
  box-shadow: none;
}

.employee-group small {
  color: var(--muted);
  font-size: 12px;
  font-weight: 600;
  margin-right: 10px;
}

.normal-hours-edit {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-right: 10px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.normal-hours-edit input {
  width: 74px;
  min-width: 74px;
  min-height: 24px;
  border-radius: 6px;
  padding: 0 7px;
  font-size: 12px;
}

.treated-group .normal-hours-edit input[readonly] {
  border-color: transparent;
  background: transparent;
  color: var(--muted);
  cursor: default;
}

.missing-hours-edit {
  color: var(--warning);
}

.extra-hours-edit {
  color: var(--accent-strong);
}

.banco-hours-edit {
  color: #475467;
}

.absence-type-select {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-right: 10px;
  color: var(--warning);
  font-size: 12px;
  font-weight: 700;
}

.absence-type-select input {
  min-width: 150px;
  max-width: 210px;
  min-height: 24px;
  border-radius: 6px;
  padding: 0 7px;
  font-size: 12px;
}

.treated-group .absence-type-select input[readonly] {
  border-width: 0;
  background: transparent;
  color: var(--muted);
  cursor: default;
  opacity: 1;
}

.extra-breakdown {
  color: var(--accent-strong);
  font-size: 11px;
  font-weight: 800;
}

.employee-group .incoherence-label {
  color: #b42318;
  font-weight: 800;
}


.employee-group .vacation-status-label,
.day-group .vacation-status-label,
.missing-record-row .vacation-status-label { /* alt chat 07.09.2026 - férias marcadas. */
  color: #175cd3;
  font-weight: 800;
}

.employee-group .vacation-punches-label,
.day-group .vacation-punches-label { /* alt chat 07.09.2026 - picagens registadas durante férias. */
  color: #b42318;
  font-weight: 800;
}

.employee-group .automatic-lunch-label {
  display: inline-flex;
  align-items: center;
  min-height: 22px;
  padding: 2px 7px;
  border: 1px solid #8fc9dc;
  border-radius: 999px;
  background: #eef9fc;
  color: #23657a;
  font-weight: 800;
}

.day-group .missing-hours-label,
.employee-group .missing-hours-label {
  color: var(--warning);
  font-weight: 800;
}

/* alt chat 03.09.2026 - destaque próprio para horas trabalhadas acima das normais. */
.day-group .surplus-hours-label {
  /* display: inline-flex; comentado chat 03.09.2026 */
  /* align-items: center; comentado chat 03.09.2026 */
  /* padding: 2px 6px; comentado chat 03.09.2026 */
  /* border: 1px solid #8b5cf6; comentado chat 03.09.2026 */
  /* border-radius: 999px; comentado chat 03.09.2026 */
  /* background: #ede9fe; comentado chat 03.09.2026 */
  color: #5b21b6;
  font-weight: 900; /* alt chat 03.09.2026 - apenas cor e negrito. */
}

.schedule-select {
  align-items: center;
  display: flex;
  gap: 8px;
  margin-left: auto;
  white-space: nowrap;
}

.schedule-select select {
  min-height: 26px;
  max-width: 260px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0 8px;
  color: var(--ink);
  font: inherit;
}

.picagens-page .app-shell {
  padding: 18px 22px 16px;
}

.picagens-page .topbar {
  align-items: flex-start;
  margin-bottom: 12px;
}

.picagens-page h1 {
  font-size: 27px;
}

.picagens-page .topbar p {
  margin-top: 4px;
  font-size: 13px;
}

.picagens-page .topbar-actions {
  gap: 8px;
}

.picagens-page .topbar-actions button {
  min-height: 34px;
  padding-inline: 13px;
}

.picagens-page .save-status {
  min-width: 96px;
  font-size: 12px;
}

.picagens-page .calculation-rules-button {
  min-height: 34px;
  border-color: var(--accent);
  color: var(--accent-strong);
}

.calculation-rules-modal {
  max-height: calc(100vh - 48px);
  overflow: auto;
}

.calculation-rules-modal .modal-heading {
  cursor: default;
}

.calculation-rules-content {
  display: grid;
  gap: 12px;
}

.calculation-rules-content section {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 12px 14px;
  background: #f8fbfa;
}

.calculation-rules-content h3 {
  margin: 0 0 6px;
  font-size: 14px;
  color: var(--accent-strong);
}

.calculation-rules-content p {
  color: var(--ink);
  font-size: 13px;
  line-height: 1.45;
}

.calculation-rules-content p + p {
  margin-top: 5px;
}

.picagens-page .metrics {
  gap: 10px;
  margin-bottom: 14px;
}

.picagens-page .metrics article {
  min-height: 72px;
  padding: 12px 18px;
}

.picagens-page .metrics span {
  margin-bottom: 7px;
  font-size: 12px;
}

.picagens-page .metrics strong {
  font-size: 23px;
}

.picagens-page .positive-hours {
  color: #027a48;
}

.picagens-page .negative-hours {
  color: #b42318;
}

.picagens-page .zero-hours {
  color: #667085;
}

.picagens-page .visible-totals-content .positive-hours,
.picagens-page .visible-totals-content .negative-hours,
.picagens-page .visible-totals-content .zero-hours {
  font-weight: 800;
}

.picagens-page .panel-heading {
  padding: 12px 18px;
}

.picagens-page .panel-heading h2 {
  font-size: 17px;
}

.picagens-page .panel-heading span {
  font-size: 12px;
}

.picagens-page .panel-heading-actions .table-action-button {
  min-height: 28px;
  font-size: 11px;
}

.picagens-page .panel-heading-actions .compact-panel-action {
  display: inline-grid;
  place-items: center;
  width: 28px;
  min-width: 28px;
  padding: 0;
  font-size: 17px;
  font-weight: 800;
  line-height: 1;
}

.picagens-page th,
.picagens-page td {
  padding: 4px 9px;
}

.picagens-page th {
  font-size: 11px;
}

.picagens-page td {
  font-size: 12px;
}

.picagens-page .day-group td {
  padding: 4px 9px;
  font-size: 12px;
}

.picagens-page .day-group small {
  font-size: 11px;
}

.picagens-page .employee-group td {
  padding: 4px 9px 4px 22px;
  font-size: 12px;
}

.picagens-page .employee-group-content {
  gap: 8px;
}

.picagens-page .employee-group span,
.picagens-page .employee-group small,
.picagens-page .normal-hours-edit,
.picagens-page .absence-type-select {
  margin-right: 7px;
  font-size: 11px;
}

.picagens-page .group-toggle {
  width: 20px;
  min-height: 20px;
  margin-right: 7px;
  font-size: 14px;
}

.picagens-page .treated-toggle,
.picagens-page .extra-approval-toggle,
.picagens-page .add-punch-action,
.picagens-page .row-action {
  min-height: 22px;
}

.picagens-page .treated-toggle {
  margin-right: 7px;
  padding-inline: 7px;
  font-size: 11px;
}

.picagens-page .extra-approval-checks {
  gap: 4px;
  margin-right: 7px;
}

.picagens-page .extra-approval-toggle {
  padding-inline: 6px;
  font-size: 10px;
}

.picagens-page .row-action {
  width: 24px;
  margin-left: 5px;
}

.picagens-page .time-edit input,
.picagens-page .normal-hours-edit input,
.picagens-page .absence-type-select input,
.picagens-page .schedule-select select {
  min-height: 23px;
  border-radius: 6px;
  font-size: 12px;
}

.picagens-page .normal-hours-edit input {
  width: 66px;
  min-width: 66px;
}

.picagens-page .time-edit input {
  width: 58px;
  min-width: 58px;
}

.picagens-page .time-edit .punch-observation-input {
  width: 180px;
  min-width: 140px;
}

.picagens-page .schedule-select {
  gap: 6px;
}

.picagens-page .schedule-select select {
  max-width: 220px;
  padding-inline: 7px;
}

.picagens-page .table-wrap {
  position: relative;
  max-height: calc(100vh - 218px);
  overflow: auto;
}

.picagens-page .table-wrap table {
  transition: opacity 0.15s ease;
}

.picagens-page .table-wrap.records-loading {
  cursor: progress;
}

.picagens-page .table-wrap.records-loading table {
  opacity: 0.55;
  pointer-events: none;
}

/* Adicionado chat 14.10.2026 - mostrar os resultados SQL apenas após o AUTO terminar. */
.picagens-page .table-wrap.records-auto-loading table {
  visibility: hidden;
}

.picagens-page thead th {
  position: sticky;
  top: 0;
  z-index: 1;
  background: var(--panel);
}

.empty-state {
  padding: 34px;
  text-align: center;
  color: var(--muted);
}

.auditoria-page .app-shell {
  min-width: 0;
}

.audit-filters select {
  width: 100%;
}

.audit-metrics {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.audit-panel {
  min-height: 0;
}

.audit-tabs {
  justify-content: flex-start;
  gap: 8px;
}

.audit-tab {
  min-height: 34px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: transparent;
  color: var(--muted);
  font-weight: 700;
}

.audit-tab.active {
  border-color: var(--accent);
  background: #e2f2ee;
  color: var(--accent-strong);
}

.audit-table-wrap {
  max-height: calc(100vh - 270px);
  overflow: auto;
}

.audit-table-wrap table {
  min-width: 1120px;
}

.audit-table-wrap thead th {
  position: sticky;
  top: 0;
  z-index: 2;
  background: var(--panel);
}

.audit-table-wrap td {
  vertical-align: top;
}

.audit-table-wrap td small {
  display: block;
  margin-top: 3px;
  color: var(--muted);
}

.audit-date {
  white-space: nowrap;
}

.audit-method,
.audit-result {
  display: inline-block;
  padding: 2px 6px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 800;
  white-space: nowrap;
}

.audit-method {
  margin-right: 5px;
  background: #e2f2ee;
  color: var(--accent-strong);
}

.audit-result-ok {
  background: #dff5ec;
  color: #08735b;
}

.audit-result-error {
  background: #fee8e7;
  color: #b42318;
}

.audit-details {
  position: relative;
}

.audit-details summary {
  cursor: pointer;
  color: var(--accent-strong);
  font-weight: 700;
}

.audit-details div {
  width: min(520px, 65vw);
  margin-top: 8px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  box-shadow: var(--shadow);
  overflow-wrap: anywhere;
}

.audit-details pre {
  max-height: 230px;
  margin: 5px 0 0;
  overflow: auto;
  white-space: pre-wrap;
  font-size: 11px;
}

.audit-value {
  max-width: 260px;
  overflow-wrap: anywhere;
}

.employee-analysis-page .app-shell,
.employee-analysis-panel {
  min-width: 0;
  min-height: 0;
}

.employee-analysis-metrics {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.employee-analysis-table-wrap {
  max-height: calc(100vh - 270px);
  overflow: auto;
}

.employee-analysis-table-wrap table {
  min-width: 1120px;
}

.employee-analysis-table-wrap thead th {
  position: sticky;
  top: 0;
  z-index: 2;
  background: var(--panel);
}

.employee-analysis-table-wrap td {
  vertical-align: middle;
}

.analysis-type-badge {
  display: inline-block;
  padding: 2px 7px;
  border-radius: 999px;
  background: #e2f2ee;
  color: var(--accent-strong);
  font-size: 11px;
  font-weight: 800;
  text-transform: capitalize;
}

/* chat 02.10.2026 - destacar o total de horas extra do período consultado. */
.employee-analysis-metrics .extra-period-total {
  background: #eaf6f2;
  border: 2px solid var(--accent);
}
.employee-analysis-metrics .extra-period-total strong {
  color: var(--accent);
  font-size: clamp(30px, 3vw, 42px);
  line-height: 1.15;
}
.employee-analysis-metrics .extra-period-total small {
  display: block;
  margin-top: 6px;
  color: var(--ink);
  font-weight: 600;
}

.employee-analysis-group td {
  position: sticky;
  left: 0;
  padding-block: 7px;
  background: #eaf3f1;
  color: var(--accent-strong);
}

.employee-analysis-group span {
  margin-left: 12px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 600;
}

@media (max-width: 980px) {
  body {
    grid-template-columns: 1fr;
  }

  body.sidebar-collapsed {
    grid-template-columns: 1fr;
  }

  .sidebar {
    position: relative;
    top: auto;
    left: auto;
    width: 100%;
    height: auto;
    min-height: auto;
    overflow: visible;
  }

  .app-shell {
    grid-column: 1;
  }

  .sidebar-filter {
    margin-top: 12px;
  }

  .employee-tree {
    max-height: 280px;
  }

  .sidebar-toggle {
    display: none;
  }

  .metrics {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .analysis-map-grid {
    grid-template-columns: 1fr;
  }

  .tolerance-layout {
    grid-template-columns: 1fr;
  }

  .schedules-layout {
    grid-template-columns: 1fr;
  }

  .schedule-day-graph {
    grid-template-rows: auto 320px;
  }

  .schedule-day-scale,
  .schedule-day-track {
    min-height: 320px;
  }

  .schedule-shift-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .toolbar,
  .topbar {
    align-items: stretch;
    flex-direction: column;
  }

  .aprovadores-form {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 620px) {
  .app-shell {
    padding: 18px;
  }

  .metrics {
    grid-template-columns: 1fr;
  }

  input {
    min-width: 100%;
  }

  .employee-filter input,
  .employee-tree {
    min-width: 100%;
    width: 100%;
  }

  .aprovadores-form {
    grid-template-columns: 1fr;
  }

  .form-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .form-actions .form-error {
    margin-right: 0;
  }

  .schedule-shift-grid {
    grid-template-columns: 1fr;
  }
}

.absence-map-page .sidebar {
  overflow-x: hidden;
  overflow-y: auto;
}

.absence-map-page .sidebar-toggle {
  right: 6px;
}

.sidebar .brand {
  margin-bottom: 4px;
}

.sidebar nav {
  gap: 1px;
  margin-bottom: 4px;
}

.sidebar nav a,
.sidebar .nav-group summary,
.sidebar .sidebar-action {
  min-height: 24px;
  padding: 2px 7px;
  font-size: 12px;
}

.sidebar .nav-group,
.sidebar .nav-submenu {
  gap: 1px;
}

.sidebar .nav-submenu a {
  min-height: 22px;
  padding-block: 2px;
  font-size: 11px;
}

.absence-map-page .absence-sidebar-filter {
  gap: 3px;
  padding-top: 5px;
}

.absence-map-page .absence-sidebar-filter .employee-tree {
  min-height: 100px;
  max-height: clamp(140px, calc(100vh - 415px), 360px);
}

.absence-map-page .absence-sidebar-filter .absence-legend {
  gap: 0;
  padding-top: 3px;
}

.absence-map-page .absence-sidebar-filter .absence-map-summary {
  gap: 2px;
  padding-top: 4px;
}

.absence-map-page .absence-filter-actions {
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
}

.absence-map-page .absence-filter-actions .link-button {
  grid-column: 2;
  grid-row: 1;
  padding-inline: 6px;
}

.absence-map-page .sidebar-footer {
  margin-top: 4px;
  padding-top: 4px;
}

body.sidebar-collapsed.absence-map-page {
  grid-template-columns: 76px minmax(0, 1fr);
}

.sidebar-collapsed.absence-map-page .sidebar {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 40;
  width: 76px;
  height: 100vh;
  min-height: 100vh;
  padding: 8px 10px;
}

.sidebar-collapsed.absence-map-page .brand {
  justify-content: center;
}

.sidebar-collapsed.absence-map-page .sidebar-text,
.sidebar-collapsed.absence-map-page .sidebar nav a strong,
.sidebar-collapsed.absence-map-page .sidebar .nav-group summary strong,
.sidebar-collapsed.absence-map-page .sidebar .nav-submenu,
.sidebar-collapsed.absence-map-page .sidebar .sidebar-action strong,
.sidebar-collapsed.absence-map-page .sidebar .absence-sidebar-filter {
  display: none;
}

.sidebar-collapsed.absence-map-page .sidebar nav a,
.sidebar-collapsed.absence-map-page .sidebar .nav-group summary,
.sidebar-collapsed.absence-map-page .sidebar .sidebar-action {
  justify-content: center;
  padding-inline: 8px;
}

.sidebar-collapsed.absence-map-page .sidebar nav a span,
.sidebar-collapsed.absence-map-page .sidebar .nav-group summary span,
.sidebar-collapsed.absence-map-page .sidebar .sidebar-action span {
  display: block;
}

.sidebar-collapsed.absence-map-page .sidebar .nav-group summary::after {
  display: none;
}

.sidebar-collapsed.absence-map-page .app-shell {
  grid-column: 2;
  padding: 8px;
}

@media (max-width: 980px) {
  .absence-map-page .sidebar {
    max-height: 100vh;
  }

  .absence-map-page .sidebar-toggle {
    display: grid;
    right: 10px;
  }
}

@media (max-width: 620px) {
  body.sidebar-collapsed.absence-map-page {
    grid-template-columns: 58px minmax(0, 1fr);
  }

  .sidebar-collapsed.absence-map-page .sidebar {
    width: 58px;
    padding-inline: 6px;
  }

  .sidebar-collapsed.absence-map-page .app-shell {
    grid-column: 2;
    padding: 6px;
  }
}
.previous-year-transfer-modal .modal { /* alt chat 07.09.2026 */
  width: min(980px, calc(100vw - 32px));
  max-height: calc(100vh - 48px);
  overflow-y: auto; /* alt chat 07.09.2026 - permite deslocar todo o conteúdo em ecrãs baixos. */
}

.previous-year-transfer-scroll { /* alt chat 07.09.2026 */
  max-height: min(55vh, 560px);
  overflow: auto; /* alt chat 07.09.2026 - scroll vertical e horizontal da lista. */
  overscroll-behavior: contain;
}

.previous-year-transfer-scroll thead { /* alt chat 07.09.2026 */
  position: sticky;
  top: 0;
  z-index: 1;
  background: var(--panel);
}

.previous-year-transfer-modal th:first-child,
.previous-year-transfer-modal td:first-child { /* alt chat 07.09.2026 */
  width: 42px;
  min-width: 42px;
  text-align: center;
}

.previous-year-transfer-modal input[type="checkbox"] { /* alt chat 07.09.2026 */
  width: 16px;
  height: 16px;
}

.previous-year-select-all { /* alt chat 07.09.2026 */
  margin: 12px 0;
}

/* chat 14.09.2026 - filtros/legendas não encolhem sobre Fullscreen/Sair; a sidebar mantém o scroll. */
.mapas-page .sidebar > .brand,
.mapas-page .sidebar > nav,
.mapas-page .sidebar > .sidebar-filter,
.mapas-page .sidebar > .sidebar-footer {
  flex-shrink: 0;
}

/* chat 14.09.2026 - alerta não bloqueante após marcação/desmarcação em mês processado. */
.marking-status.warning { color: #8a5200; }

/* chat 14.09.2026 - o aviso ocupa uma linha própria e quebra texto sem alargar o ecrã. */
.absence-marking-page .absence-marking-heading {
  flex-wrap: wrap;
}

.absence-marking-page .absence-marking-heading > div {
  min-width: 0;
  max-width: 100%;
}

.absence-marking-page .marking-status:not(:empty) {
  min-width: 0;
  max-width: 100%;
  white-space: normal;
  overflow-wrap: anywhere;
}

.absence-marking-page .marking-status.warning:not(:empty) {
  flex-basis: 100%;
  border-radius: 6px;
}

/* chat 14.09.2026 - aviso no ano de saída e no detalhe, sem alterar a largura. */
.vacation-departure-warning { color: #8a5200; white-space: normal; overflow-wrap: anywhere; }

/* chat 15.09.2026 - destacar o botão Por tratar com fundo amarelo. */
.picagens-page .treated-toggle:not(.treated-active) {
  background: #fff1c2;
  border-color: #d6ab38;
  color: #735000;
}

/* chat 16.09.2026 - alertas legíveis e erros centrados sem alargar o ecrã das ausências. */
.absence-marking-page .marking-status:not(:empty),
.absence-marking-page .absence-delete-modal .modal-hint {
  font-size: 10pt;
  line-height: 1.5;
  white-space: normal;
  overflow-wrap: anywhere;
}

.absence-save-error-dialog {
  position: fixed;
  inset: 0;
  margin: auto;
  box-sizing: border-box;
  width: min(520px, calc(100vw - 32px));
  max-height: calc(100dvh - 32px);
  overflow: auto;
  padding: 24px;
  border: 1px solid #e0b4b0;
  border-radius: 12px;
  background: #fff;
  color: #17202b;
  box-shadow: 0 12px 48px rgb(0 0 0 / 25%);
  overflow-wrap: anywhere;
}

.absence-save-error-dialog::backdrop { background: rgb(15 23 42 / 45%); }
.absence-save-error-dialog h2 { margin: 0 0 16px; font-size: 18px; color: #b42318; }
#picagensAlertDialog.picagens-warning-dialog h2 { color: #a66300; }
.absence-save-error-dialog p { font-size: 10pt; line-height: 1.5; white-space: pre-wrap; }
.absence-save-error-dialog form { display: flex; justify-content: flex-end; margin-top: 20px; }

/* chat 16.09.2026 - confirmação legível em ecrãs pequenos, sem scroll horizontal. */
.vacation-next-year-dialog h2 { color: #8a5200; }
.vacation-next-year-dialog ul { padding-left: 20px; font-size: 10pt; line-height: 1.5; }
.vacation-next-year-dialog li + li { margin-top: 12px; }
.vacation-next-year-dialog form { gap: 8px; flex-wrap: wrap; }
.vacation-next-year-dialog button { white-space: normal; max-width: 100%; }

/* chat 16.09.2026 - ao mostrar todos, só desenhar os cartões do resumo próximos da área visível. */
.absence-marking-page .vacation-summary-card {
  content-visibility: auto;
  contain-intrinsic-size: auto 180px;
}
/* chat 15.09.2026 - aprovação em massa com tabela igual às picagens e scroll dentro do modal. */
.bulk-approvals-dialog {
  width: min(1600px, calc(100vw - 32px));
  max-width: calc(100vw - 32px);
  max-height: calc(100dvh - 32px);
  padding: 20px;
  border: 1px solid #d5dfed;
  border-radius: 12px;
  color: #172b45;
  background: #fff;
}
.bulk-approvals-dialog::backdrop { background: rgb(15 23 42 / 45%); }
.bulk-approvals-dialog[open] { display: flex; flex-direction: column; gap: 14px; }
.bulk-approvals-dialog .modal-heading { flex-shrink: 0; align-items: flex-start; }
.bulk-approvals-dialog h2 { margin: 0 0 6px; }
.bulk-approvals-dialog p { margin: 0; font-size: 14px; }
.bulk-approvals-toolbar, .bulk-approvals-footer {
  display: flex; flex-wrap: wrap; gap: 12px; align-items: center; flex-shrink: 0;
}
.bulk-approvals-footer { justify-content: flex-end; }
.bulk-approvals-table { min-height: 0; overflow: auto; }
.bulk-approval-choice { display: flex; align-items: center; gap: 10px; }
/* chat 15.09.2026 - anular os mínimos dos inputs gerais, que ampliavam os vistos. */
.bulk-approvals-dialog input[type="checkbox"] {
  width: 16px;
  min-width: 16px;
  max-width: 16px;
  height: 16px;
  min-height: 16px;
  max-height: 16px;
  flex: 0 0 16px;
  padding: 0;
  margin: 0;
  accent-color: var(--accent);
}
.bulk-approvals-toolbar > label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.bulk-approvals-dialog .employee-group :disabled { opacity: 1; }

/* chat 21.09.2026 - resumo legível em painéis estreitos, sem cortar o disponível. */
.mapas-page .vacation-summary-panel {
  container-type: inline-size;
  container-name: vacation-summary;
}
.mapas-page .vacation-summary-list,
.mapas-page .vacation-summary-total,
.mapas-page .vacation-summary-card {
  min-width: 0;
}
@container vacation-summary (max-width: 360px) {
  .mapas-page .vacation-summary-table-head,
  .mapas-page .vacation-summary-table-row {
    grid-template-columns: minmax(54px, 1fr) repeat(3, minmax(0, 1fr)) minmax(42px, .85fr);
    column-gap: 3px;
  }
  .mapas-page .vacation-summary-ratio {
    grid-template-columns: minmax(0, 1fr);
    justify-content: stretch;
    gap: 2px;
    overflow: visible;
    text-align: right;
  }
  .mapas-page .vacation-summary-table-row b,
  .mapas-page .vacation-summary-total .vacation-summary-ratio b {
    font-size: 11px;
  }
  .mapas-page .vacation-summary-ratio small,
  .mapas-page .vacation-summary-total .vacation-summary-ratio small {
    font-size: 10px;
  }
  .mapas-page .vacation-summary-table-row strong {
    overflow-wrap: anywhere;
  }
  .mapas-page .vacation-summary-person strong {
    white-space: normal;
    overflow-wrap: anywhere;
  }
}
/* chat 21.09.2026 - em ecrãs muito estreitos, o resumo passa para baixo do mapa. */
@media (max-width: 760px) {
  .mapas-page .absence-planner:not(.banco-horas-planner) {
    grid-template-columns: minmax(0, 1fr);
    height: auto;
    max-height: none;
  }
  .mapas-page .vacation-summary-panel {
    border-left: 0;
    border-top: 1px solid #aeb7c2;
  }
  .mapas-page .vacation-summary-list {
    max-height: 480px;
  }
}
/* chat 01.10.2026 - limitar a lista para concentrar o scroll nos funcionários. */
.sidebar .employee-tree {
  max-height: min(36vh, 320px);
  overflow-y: auto;
  overflow-x: hidden;
  flex-shrink: 0;
  overscroll-behavior-y: contain;
}

.sidebar #bancoHorasEmployeeFilterHint {
  margin: 0;
  font-weight: 400;
  line-height: 1.45;
}

.compensation-hover-target {
  position: relative;
}

.compensation-hover-card {
  position: absolute;
  z-index: 30;
  left: 0;
  top: calc(100% + 8px);
  display: none;
  width: 260px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--panel);
  color: var(--ink);
  box-shadow: 0 14px 30px rgba(15, 31, 58, .3);
  text-align: left;
  font-size: .82rem;
}

.compensation-hover-target:hover .compensation-hover-card,
.compensation-hover-target:focus-within .compensation-hover-card {
  display: grid;
  gap: 7px;
}

.compensation-hover-card > strong {
  color: var(--accent);
  font-size: .95rem;
}

.compensation-hover-card > small {
  color: var(--muted);
}

.compensation-hover-card > span {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  border-top: 1px solid var(--line);
  padding-top: 5px;
}

.compensation-hover-card em {
  color: var(--ink);
  font-style: normal;
  font-weight: 700;
}

.compensation-hover-total {
  color: var(--accent);
}

/* chat 01.10.2026 - contraste explícito, evitando cores herdadas da linha. */
.compensation-hover-card b { color: var(--ink); }
.compensation-hover-card .compensation-hover-total b,
.compensation-hover-card .compensation-hover-total em { color: var(--accent); }
.compensation-hover-card [data-compensation-credits] { color: var(--accent); }
.compensation-hover-card [data-compensation-debits] { color: #b42318; }
.compensation-hover-card small:empty { display: none; }
.processing-approved {
  display: inline-block;
  color: #176b5c;
  background: #e1f2ed;
  border: 1px solid #abd9cc;
  border-radius: 6px;
  padding: 3px 8px;
  font-weight: 700;
}
.processing-note { padding: 0 16px 12px; color: #596b82; font-size: 0.85rem; }
.processing-fixed-table details { white-space: normal; min-width: 180px; }
.processing-fixed-table summary { cursor: pointer; color: #176b5c; }
.processamento-page #processingMessage { color: #596b82; }
.processing-detail-target { padding: 3px 8px; border: 0; border-bottom: 1px dotted var(--accent, #1f7a68); border-radius: 0; background: transparent; color: var(--accent, #1f7a68); font: inherit; cursor: pointer; }
.processing-saved-notice:not([hidden]) { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 12px; padding: 12px 16px; margin-bottom: 16px; border: 1px solid #c5ded7; border-radius: 10px; background: #eef8f5; color: #176b5c; }
.processing-saved-dialog { width: min(1500px, calc(100vw - 32px)); max-height: calc(100dvh - 32px); box-sizing: border-box; padding: 24px; border: 1px solid #c5ded7; border-radius: 12px; color: #17202b; background: #fff; }
.processing-saved-dialog[open] { display: flex; flex-direction: column; gap: 16px; overflow: hidden; }
.processing-saved-dialog .panel-heading { flex-shrink: 0; gap: 16px; margin: 0; padding: 0 0 12px; border-bottom: 1px solid #dce7e3; }
.processing-saved-dialog .panel-heading h2 { margin: 0; color: #176b5c; font-size: 18px; }
.processing-saved-dialog .processing-saved-description { margin: 0; line-height: 1.6; color: #617187; flex-shrink: 0; }
.processing-saved-dialog #processingSavedMessage { margin: 0; flex-shrink: 0; }
.processing-saved-dialog #processingSavedMessage:empty { display: none; }
.processing-saved-dialog::backdrop { background: rgba(15, 30, 45, .45); }
.processing-saved-dialog .table-wrap { min-height: 0; overflow: auto; overscroll-behavior: contain; border: 1px solid #dce7e3; border-radius: 8px; }
.processing-saved-dialog table { width: 100%; min-width: 1200px; }
.processing-saved-dialog th, .processing-saved-dialog td { padding: 12px 14px; vertical-align: middle; }
/* .processing-saved-dialog td:first-child { min-width: 210px; max-width: 280px; white-space: normal; } comentado chat 09.10.2026 */
.processing-saved-dialog td[data-label="Funcionário"] { min-width: 210px; max-width: 280px; white-space: normal; } /* alterado chat 09.10.2026 */
/* .processing-saved-dialog td:nth-child(n+3):nth-child(-n+10) { text-align: center; white-space: nowrap; font-variant-numeric: tabular-nums; } comentado chat 09.10.2026 */
.processing-saved-dialog td.processing-saved-numeric { text-align: center; white-space: nowrap; font-variant-numeric: tabular-nums; } /* alterado chat 09.10.2026 */
.processing-saved-dialog td:last-child button { white-space: nowrap; min-height: 36px; }
.processing-saved-dialog thead { position: sticky; top: 0; z-index: 2; background: #f4f7f6; }
.processing-saved-dialog td small { display: block; color: #7a8491; font-size: 10px; }
.processing-saved-dialog td .processing-approved-daily-note { max-width: 190px; margin-top: 6px; color: #946200; line-height: 1.45; white-space: normal; }
.processing-approved-daily-note:empty { display: none !important; }
.processing-rules-dialog { width: min(640px, calc(100vw - 32px)); }
.processing-rules-dialog .calculation-rules-content { overflow: auto; min-height: 0; }
.processing-rules-dialog .modal-heading { margin: 0; flex-shrink: 0; }
.processing-rules-dialog .modal-heading form { margin: 0; }
.processing-saved-audit { min-width: 125px; }
.processing-saved-audit summary { cursor: pointer; color: #176b5c; white-space: nowrap; }
.processing-saved-audit > div { display: grid; gap: 4px; padding-top: 10px; min-width: 160px; }
.processing-saved-audit strong { font-size: 11px; color: #617187; }
.processing-saved-audit strong:not(:first-child) { margin-top: 8px; }
@media (max-width: 640px) {
  .processing-saved-dialog { width: calc(100vw - 16px); max-height: calc(100dvh - 16px); padding: 16px; }
  .processing-saved-dialog[open] { gap: 12px; }
  .processing-saved-dialog .panel-heading h2 { font-size: 16px; }
  .processing-saved-dialog .table-wrap { border: 0; border-radius: 0; }
  .processing-saved-dialog table { min-width: 0; display: block; }
  .processing-saved-dialog thead { display: none; }
  .processing-saved-dialog tbody { display: grid; gap: 12px; }
  .processing-saved-dialog tr { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px 16px; padding: 16px; border: 1px solid #dce7e3; border-radius: 8px; background: #f7faf9; }
  .processing-saved-dialog td { display: block; min-width: 0 !important; max-width: none !important; padding: 0; border: 0; white-space: normal !important; text-align: left !important; overflow-wrap: anywhere; }
  .processing-saved-dialog td[data-label]::before { content: attr(data-label); display: block; margin-bottom: 4px; color: #617187; font-size: 11px; }
/* .processing-saved-dialog td:first-child, .processing-saved-dialog td:nth-child(11), .processing-saved-dialog td:nth-child(12), .processing-saved-dialog td:last-child { grid-column: 1 / -1; } comentado chat 09.10.2026 */
  .processing-saved-dialog td[data-label="Funcionário"], .processing-saved-dialog td[data-label="Aprovado"], .processing-saved-dialog td[data-label="Detalhes"], .processing-saved-dialog td:last-child { grid-column: 1 / -1; } /* alterado chat 09.10.2026 */
/* .processing-saved-dialog td:first-child { font-weight: 600; } comentado chat 09.10.2026 */
  .processing-saved-dialog td[data-label="Funcionário"] { font-weight: 600; } /* alterado chat 09.10.2026 */
  .processing-saved-dialog td:last-child button { width: 100%; min-height: 40px; }
}
.processing-hover-card { position: fixed; z-index: 200; box-sizing: border-box; width: min(470px, calc(100vw - 24px)); max-height: min(340px, calc(100vh - 24px)); display: flex; flex-direction: column; overflow: hidden; border: 1px solid #c7d5df; border-radius: 10px; background: #fff; color: #17202b; box-shadow: 0 12px 32px #17202b30; }
.processing-hover-card[hidden] { display: none; }
.processing-hover-card header { flex-shrink: 0; padding: 10px 12px; background: #eef9f6; border-bottom: 1px solid #d4e7df; }
.processing-hover-card header strong { display: block; color: #176b5c; }
.processing-hover-card header small { display: block; margin-top: 3px; color: #596b82; font-size: 11px; }
.processing-hover-list { min-height: 0; overflow-y: auto; overscroll-behavior: contain; padding: 2px 12px; }
.processing-hover-list > div { display: grid; grid-template-columns: 74px minmax(0, 1fr) auto; align-items: baseline; gap: 8px; padding: 7px 0; border-bottom: 1px solid #e7ecf0; font-size: 11px; line-height: 1.35; }
.processing-hover-list > div:last-child { border-bottom: 0; }
.processing-hover-list small { color: #596b82; text-align: right; font-size: 10px; }
@media (max-width: 480px) {
  .processing-hover-list > div { grid-template-columns: 70px minmax(0, 1fr); }
  .processing-hover-list small { grid-column: 2; text-align: left; }
}
.processamento-page[data-processing-type="fixo"] .processing-fixed-table { min-width: 0; width: 100%; }
.processamento-page[data-processing-type="fixo"] .processing-fixed-table th { white-space: normal; line-height: 1.3; padding: 7px 8px; }
.processamento-page[data-processing-type="fixo"] .processing-fixed-table td { padding: 7px 8px; }
.processamento-page[data-processing-type="fixo"] .processing-fixed-table tbody td:nth-child(n+14):nth-child(-n+16) { text-align: center; vertical-align: middle; font-variant-numeric: tabular-nums; }
.processamento-page[data-processing-type="fixo"] .processing-fixed-table .processing-detail-target { display: inline-block; margin: 0; text-align: center; }
.processamento-page[data-processing-type="fixo"] .processing-fixed-table td:first-child { white-space: normal; min-width: 220px; }
.processing-employee-cell small { display: block; margin-top: 3px; font-size: 10px; color: #7a8491; }
.processing-value-input { width: 96px; min-width: 0; padding: 6px 7px; }
.processamento-page[data-processing-type="fixo"] .processing-fixed-table th.processing-header-nowrap { white-space: nowrap; }

/* adicionado chat 09.10.2026: ocultar apenas visualmente IHT e Sub. IHT no processamento fixo. */
.processamento-page[data-processing-type="fixo"] .processing-iht-column { display: none; }

/* adicionado chat 09.10.2026: células partilhadas sem alterar as decisões nem a edição por movimento. */
.processing-saved-table .processing-saved-repeat { display: none; }
.processing-saved-table tr.processing-saved-group-start:not(:first-child) > td { border-top: 2px solid #c8d9d3; }
.processing-saved-table td[rowspan] { background: #fff; }
.processing-saved-table .processing-saved-shift-manha { background: #effaf7; }
.processing-saved-table .processing-saved-shift-tarde { background: #fff9ee; }
.processing-saved-table .processing-saved-shift-noite { background: #f4f1fc; }
.processing-saved-table th { text-align: center; white-space: nowrap; }
.processing-saved-table th:first-child { text-align: left; }
.processing-saved-table .processing-saved-action { white-space: nowrap; }
@media (max-width: 640px) {
  /* adicionado chat 09.10.2026: manter a identificação e os detalhes completos em cada cartão móvel. */
  .processing-saved-table .processing-saved-repeat { display: block; }
  .processing-saved-table td[rowspan] { background: transparent; }
  .processing-saved-table tr.processing-saved-group-start:not(:first-child) > td { border-top: 0; }
  .processing-saved-table tr.processing-saved-group-continuation { margin-top: -6px; }
}

/* adicionado chat 09.10.2026: reduzir o espaço entre colunas e manter Dias / Valor-dia juntos nos cartões. */
.processing-saved-dialog .processing-saved-table th,
.processing-saved-dialog .processing-saved-table td { padding: 10px 8px; }
@media (max-width: 640px) {
  .processing-saved-dialog .processing-saved-table td { padding: 0; }
  .processing-saved-table td[data-label="Salário base"] { grid-column: 1 / -1; }
}

/* adicionado chat 12.10.2026 - criação de tipos de faltas: grelha própria e deslocamento apenas vertical. */
#tyForm.ty-create-modal {
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  width: min(960px, calc(100vw - 32px));
  max-height: calc(100vh - 32px);
  max-height: calc(100dvh - 32px);
  padding: 0;
  overflow: hidden;
  touch-action: auto;
}
#tyForm > .modal-heading {
  flex-shrink: 0;
  margin: 0;
  padding: 18px 20px;
  border-bottom: 1px solid var(--line);
  cursor: default;
  user-select: text;
}
#tyForm > .modal-heading > div { min-width: 0; }
#tyForm > .modal-heading .icon-button { flex-shrink: 0; }
#tyForm .ty-create-body {
  min-height: 0;
  padding: 18px 20px;
  overflow-y: auto;
  overscroll-behavior: contain;
}
#tyForm .ty-create-grid {
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 14px 12px;
  margin: 0;
}
#tyForm .ty-create-grid label { min-width: 0; }
#tyForm .ty-field-code, #tyForm .ty-field-abbreviation { grid-column: span 1; }
#tyForm .ty-field-description, #tyForm .ty-field-classification { grid-column: span 3; }
#tyForm .ty-field-class-code, #tyForm .ty-field-color,
#tyForm .ty-field-absence-code, #tyForm .ty-field-reason-code,
#tyForm .ty-field-reason-description { grid-column: span 2; }
#tyForm .ty-create-grid input { box-sizing: border-box; min-width: 0; width: 100%; }
#tyForm .ty-create-grid input[type="color"] { padding: 4px 6px; }
#tyForm .ty-flags-fieldset {
  min-width: 0;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px 16px;
  margin: 20px 0 0;
  padding: 12px;
}
#tyForm .ty-flags-fieldset label {
  min-width: 0;
  justify-content: flex-start;
  font-size: 12px;
  font-weight: 600;
  line-height: 1.4;
  overflow-wrap: anywhere;
  cursor: pointer;
}
#tyForm .ty-flags-fieldset input[type="checkbox"] {
  width: 15px;
  min-width: 15px;
  height: 15px;
  min-height: 15px;
  flex: 0 0 15px;
  padding: 0;
  margin: 0;
}
#tyForm .ty-create-actions {
  flex-shrink: 0;
  margin: 0;
  padding: 14px 20px;
  border-top: 1px solid var(--line);
  background: var(--panel);
}
#tyForm .form-error:empty { display: none; }
@media (max-width: 800px) {
  #tyForm .ty-create-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  #tyForm .ty-create-grid label { grid-column: span 1; }
  #tyForm .ty-field-reason-description { grid-column: 1 / -1; }
  #tyForm .ty-flags-fieldset { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 560px) {
  #tyForm .ty-create-grid { grid-template-columns: minmax(0, 1fr); gap: 12px; }
  #tyForm > .modal-heading, #tyForm .ty-create-body { padding: 14px; }
  #tyForm > .modal-heading h2 { font-size: 18px; }
  #tyForm .ty-create-actions { padding: 12px 14px; }
}
@media (max-width: 420px) {
  #tyForm .ty-flags-fieldset { grid-template-columns: minmax(0, 1fr); }
}

/* adicionado chat 12.10.2026 - tempo da falta provisória numa segunda linha, dentro da célula do calendário. */
.absence-marking-page .absence-category-markers .absence-provisional-time {
  display: block;
  font-size: 9px;
  line-height: 1.2;
  white-space: nowrap;
}

/* adicionado chat 12.10.2026 - modal de faltas repartidas, adaptado a ecrãs pequenos. */
.split-absence-dialog { width: min(620px, calc(100vw - 24px)); max-height: calc(100dvh - 24px); padding: 0; border: 1px solid #cbdedb; border-radius: 12px; color: #132735; }
.split-absence-dialog::backdrop { background: rgb(15 30 40 / 35%); }
.split-absence-dialog .modal-heading { padding: 16px 18px; margin: 0; border-bottom: 1px solid #dce6e9; }
.split-absence-dialog h2 { font-size: 18px; margin: 0; }
.split-absence-dialog .modal-heading p { font-size: 12px; color: #657789; margin: 5px 0 0; }
.split-absence-body { padding: 14px 18px; max-height: calc(100dvh - 205px); overflow-y: auto; }
.split-absence-totals { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 8px; padding: 12px; background: #edf7f5; border-radius: 8px; margin: 12px 0; font-size: 12px; }
.split-absence-totals strong { display: block; margin-top: 4px; font-size: 17px; color: #146e63; }
.split-absence-overflow strong { color: #a52020; }
.split-absence-search { display: grid; gap: 5px; font-size: 12px; margin-bottom: 10px; }
.split-absence-search input { width: 100%; min-width: 0; box-sizing: border-box; }
.split-absence-types { border: 1px solid #dde6e9; border-radius: 7px; }
.split-absence-type-row { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 9px 10px; font-size: 12px; margin: 0; border-bottom: 1px solid #e6edf0; }
.split-absence-type-row:last-child { border-bottom: 0; }
.split-absence-type-row[hidden] { display: none; }
.split-absence-type-row > input { width: 78px; min-width: 78px; text-align: center; box-sizing: border-box; }
.split-absence-type-row > span:first-child { min-width: 0; overflow-wrap: anywhere; }
.split-absence-day { display: flex; flex: 0 0 auto; align-items: center; gap: 5px; color: #647488; font-size: 11px; }
.split-absence-day input[type=checkbox] { width: 16px; height: 16px; min-width: 16px; margin: 0; }
.split-absence-existing-row { display: flex; justify-content: space-between; gap: 12px; font-size: 12px; padding: 7px 0; border-bottom: 1px solid #e6edf0; }
.split-absence-existing-row strong { flex-shrink: 0; }
.split-absence-dialog h3 { font-size: 13px; margin: 0 0 5px; }
.split-absence-dialog .muted { font-size: 12px; color: #647488; }
.split-absence-error { color: #b42318; font-size: 12px; white-space: pre-line; }
.split-absence-actions { display: flex; justify-content: flex-end; gap: 8px; padding: 12px 18px; border-top: 1px solid #dce6e9; }
.split-absence-trigger { white-space: nowrap; font-size: 12px; }
@media (max-width: 480px) { .split-absence-body { padding: 10px 12px; } .split-absence-dialog .modal-heading { padding: 12px; } .split-absence-actions { padding: 10px 12px; } }

/* adicionado chat 12.10.2026 - editor de modalidades em ecrãs pequenos. */
#manualPunchForm { width: min(460px, calc(100vw - 24px)); max-height: calc(100dvh - 24px); overflow-y: auto; touch-action: auto; }
#manualPunchForm > label { display: grid; gap: 6px; margin-top: 12px; min-width: 0; }
#manualPunchForm > label[hidden] { display: none; }
#manualPunchForm textarea { width: 100%; min-width: 0; resize: vertical; }
.work-record-description { display: block; max-width: 260px; white-space: normal; overflow-wrap: anywhere; color: var(--muted); font-size: .75rem; }
.work-day-total { white-space: nowrap; font-weight: 600; color: var(--primary); }

/* adicionado chat 12.10.2026 - observação com o estilo dos restantes campos. */
#manualPunchObservation { border: 1px solid var(--line); border-radius: 8px; padding: 8px 10px; font: inherit; color: var(--ink); background: var(--panel); }

/* Adicionado chat 21.10.2026 - tipo de falta por parcela, com bloqueio após processamento. */
#splitAbsenceDialog [hidden] { display: none; }
.split-absence-existing-row { flex-wrap: wrap; align-items: center; }
.hs-existing-description { flex: 1 1 220px; min-width: 0; overflow-wrap: anywhere; }
.hs-existing-action { flex: 0 1 100%; display: flex; align-items: end; justify-content: flex-end; gap: 8px; min-width: 0; }
.hs-existing-action .table-action-button { white-space: normal; font-size: 12px; }
.hs-processed { font-size: 12px; font-weight: 700; color: #657789; }
.hs-type-editor { display: grid; gap: 4px; font-size: 12px; min-width: 0; flex: 1; }
.hs-type-editor select { width: 100%; min-width: 0; box-sizing: border-box; }
.hs-time-editor { display: grid; gap: 4px; flex: 0 1 165px; min-width: 0; font-size: 12px; }
.hs-time-editor input { width: 100%; min-width: 0; padding: 8px; box-sizing: border-box; }
@media (max-width: 480px) {
  .hs-existing-description { flex-basis: calc(100% - 75px); }
  .hs-existing-action { flex-wrap: wrap; }
  .hs-type-editor { flex-basis: 100%; }
  .hs-time-editor { flex-basis: 100%; }
}

/* 22.10.2026 - troca individual de feriado nos mapas anuais. */
.absence-category-TF{background:#d8f1ed;color:#096858}
