.head-actions .absence-admin-open {
  background: #ffffff24;
  border-color: #ffffff8c;
}

.head-actions .absence-admin-open:hover,
.head-actions .absence-admin-open:focus-visible {
  background: #ffffff38;
}

.analyst-card.analyst-on-vacation,
.analyst-card.analyst-on-leave {
  border-color: #76acd3;
  box-shadow: 0 0 0 3px #0a6cb217, 0 8px 20px #12375a17;
}

.analyst-card.analyst-on-vacation .avatar:after,
.analyst-card.analyst-on-leave .avatar:after {
  content: "";
  z-index: 2;
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(180deg, transparent 48%, #003b6fb8 100%);
}

.analyst-card.analyst-on-leave .avatar:after {
  background: linear-gradient(180deg, #dceef03d 34%, #19506cbd 100%);
}

.absence-photo-badge {
  z-index: 3;
  position: absolute;
  right: 5px;
  bottom: 5px;
  display: inline-flex;
  align-items: center;
  min-height: 31px;
  padding: 3px 6px;
  border: 1px solid #ffffffb8;
  border-radius: 10px;
  background: #ffffffeb;
  box-shadow: 0 3px 10px #001e3c42;
  font-size: 18px;
  line-height: 1;
}

.absence-card-status {
  display: block;
  width: fit-content;
  margin-top: 6px;
  padding: 4px 7px;
  border-radius: 999px;
  color: #07567f;
  background: #e3f5fb;
  font-size: 8px;
  font-weight: 850;
  line-height: 1.25;
}

.analyst-on-leave .absence-card-status {
  color: #8a3c45;
  background: #fdebed;
}

body.absence-admin-open-body {
  overflow: hidden;
}

.absence-admin-overlay[hidden],
.absence-manager-view[hidden],
.absence-login-view[hidden],
.absence-tab-panel[hidden] {
  display: none !important;
}

.absence-admin-overlay {
  position: fixed;
  inset: 0;
  z-index: 11000;
  display: grid;
  place-items: center;
  padding: 24px;
  background: #031b34b5;
  backdrop-filter: blur(4px);
}

.absence-admin-dialog {
  width: min(1180px, 97vw);
  max-height: 94vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  color: #173b5e;
  background: #f7fafc;
  border: 1px solid #bad0e1;
  border-radius: 18px;
  box-shadow: 0 30px 80px #00172f70;
}

.absence-admin-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
  padding: 19px 22px 17px;
  color: #fff;
  background: linear-gradient(110deg, #00386d, #0065ad);
}

.absence-admin-header small {
  display: block;
  color: #cce5f8;
  font-size: 10px;
  font-weight: 850;
  letter-spacing: .13em;
}

.absence-admin-header h2 {
  margin: 5px 0 0;
  color: #fff;
  font-size: clamp(21px, 2vw, 28px);
}

.absence-admin-header p {
  margin: 5px 0 0;
  color: #deecf7;
  font-size: 11px;
}

.absence-admin-close {
  flex: 0 0 auto;
  width: 39px;
  height: 39px;
  border: 1px solid #ffffff82;
  border-radius: 10px;
  color: #fff;
  background: #ffffff17;
  cursor: pointer;
  font-size: 27px;
  line-height: 1;
}

.absence-admin-close:hover,
.absence-admin-close:focus-visible {
  background: #ffffff30;
  outline: 2px solid #fff;
  outline-offset: 2px;
}

.absence-admin-status {
  min-height: 0;
  overflow: hidden;
  padding: 0 22px;
  color: #31536f;
  background: #eef5fa;
  border-bottom: 0 solid #d9e6ef;
  font-size: 11px;
  font-weight: 750;
  transition: all .18s;
}

.absence-admin-status:not(:empty) {
  min-height: 38px;
  padding-top: 11px;
  padding-bottom: 11px;
  border-bottom-width: 1px;
}

.absence-admin-status.error { color: #a42638; background: #fff0f2; }
.absence-admin-status.success { color: #0d6c52; background: #eaf8f2; }
.absence-admin-status.loading { color: #225e8d; background: #edf6fd; }

.absence-login-view,
.absence-manager-view {
  min-height: 0;
  overflow: auto;
}

.absence-login-view {
  display: grid;
  place-items: center;
  min-height: 420px;
  padding: 35px 22px;
}

.absence-login-card {
  width: min(480px, 100%);
  padding: 28px;
  text-align: center;
  background: #fff;
  border: 1px solid #d6e2eb;
  border-radius: 16px;
  box-shadow: 0 10px 30px #113b5c12;
}

.absence-lock { font-size: 33px; }
.absence-login-card h3 { margin: 11px 0 0; font-size: 18px; }
.absence-login-card p { margin: 8px 0 19px; color: #657b8e; font-size: 11px; line-height: 1.5; }

.absence-login-card label,
.absence-form label {
  display: grid;
  gap: 6px;
  color: #35536e;
  text-align: left;
  font-size: 10px;
  font-weight: 800;
}

.absence-login-card input,
.absence-form input,
.absence-form select,
.absence-form textarea,
.absence-replacement {
  width: 100%;
  min-height: 40px;
  padding: 8px 10px;
  color: #173b5e;
  background: #fff;
  border: 1px solid #cddce7;
  border-radius: 9px;
  font: inherit;
  font-size: 11px;
}

.absence-form textarea { resize: vertical; }

.absence-login-button,
.absence-form-actions button {
  min-height: 40px;
  margin-top: 14px;
  padding: 9px 16px;
  color: #fff;
  background: #0064ad;
  border: 1px solid #0064ad;
  border-radius: 9px;
  cursor: pointer;
  font-size: 11px;
  font-weight: 850;
}

.absence-login-button:hover,
.absence-form-actions button:hover { background: #004f8b; }
.absence-form-actions button:disabled { cursor: wait; opacity: .6; }

.absence-tabs {
  position: sticky;
  top: 0;
  z-index: 3;
  display: flex;
  gap: 5px;
  padding: 11px 20px;
  background: #f7fafcf2;
  border-bottom: 1px solid #dce6ee;
  backdrop-filter: blur(5px);
}

.absence-tabs button {
  padding: 8px 12px;
  color: #49677f;
  background: #fff;
  border: 1px solid #cfdde8;
  border-radius: 9px;
  cursor: pointer;
  font-size: 10px;
  font-weight: 800;
}

.absence-tabs button.active {
  color: #fff;
  background: #00599e;
  border-color: #00599e;
}

.absence-tab-panel { padding: 18px 20px 22px; }
.absence-form-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 11px; }
.absence-notes { margin-top: 12px; }

.absence-portfolio {
  margin-top: 16px;
  overflow: hidden;
  background: #fff;
  border: 1px solid #d8e4ed;
  border-radius: 13px;
}

.absence-portfolio > header,
.absence-registered-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 15px;
  background: #f1f7fb;
  border-bottom: 1px solid #dbe6ee;
}

.absence-portfolio h3,
.absence-registered-header h3 { margin: 0; color: #173f65; font-size: 14px; }
.absence-portfolio p,
.absence-registered-header p { margin: 4px 0 0; color: #697d8f; font-size: 9px; line-height: 1.4; }
.absence-selected-count { color: #155f97; white-space: nowrap; font-size: 11px; }
.absence-process-list { max-height: 390px; overflow: auto; }
.absence-process-table-wrap { overflow: auto; }

.absence-process-table {
  width: 100%;
  min-width: 930px;
  border-collapse: collapse;
  font-size: 10px;
}

.absence-process-table th,
.absence-process-table td {
  padding: 10px 9px;
  border-bottom: 1px solid #e5edf3;
  text-align: left;
  vertical-align: middle;
}

.absence-process-table th {
  position: sticky;
  top: 0;
  z-index: 1;
  color: #61788d;
  background: #f8fafc;
  font-size: 9px;
}

.absence-process-table th:nth-child(1) { width: 11%; }
.absence-process-table th:nth-child(2) { width: 29%; }
.absence-process-table th:nth-child(3) { width: 26%; }
.absence-process-table th:nth-child(4) { width: 9%; }
.absence-process-table th:nth-child(5) { width: 25%; }
.absence-process-table tr.selected { background: #eef9f5; }
.absence-sgp { color: #075f9f; font-weight: 900; }
.absence-points { color: #174f7a; white-space: nowrap; font-weight: 850; }
.absence-replacement { min-width: 190px; min-height: 35px; padding: 6px 8px; }

.absence-form-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-top: 14px;
}

.absence-form-actions p { margin: 0; color: #60778a; font-size: 10px; }
.absence-form-actions button { margin: 0; }
.absence-empty { padding: 28px 18px; color: #75899b; text-align: center; font-size: 11px; }

.absence-registered-header { margin-bottom: 12px; border: 1px solid #d8e4ed; border-radius: 11px; }
.absence-record-card { margin-top: 11px; overflow: hidden; background: #fff; border: 1px solid #d7e3ec; border-radius: 12px; }
.absence-record-card > header { display: flex; align-items: center; justify-content: space-between; gap: 18px; padding: 13px 15px; background: #f7fafc; border-bottom: 1px solid #e0e9ef; }
.absence-record-card header small { color: #0c6a9e; font-size: 9px; font-weight: 900; letter-spacing: .07em; }
.absence-record-card h4 { margin: 4px 0 0; color: #173f65; font-size: 14px; }
.absence-record-card header p { margin: 4px 0 0; color: #708396; font-size: 9px; }
.absence-cancel { padding: 7px 10px; color: #a52c3c; white-space: nowrap; background: #fff3f4; border: 1px solid #efc3c8; border-radius: 8px; cursor: pointer; font-size: 9px; font-weight: 850; }
.absence-record-card ul { list-style: none; margin: 0; padding: 3px 15px 8px; }
.absence-record-card li { display: grid; grid-template-columns: 105px 1fr 70px; gap: 10px; padding: 9px 0; border-bottom: 1px solid #e8eef3; font-size: 10px; }
.absence-record-card li:last-child { border: 0; }
.absence-record-card li strong { color: #075f9f; }
.absence-record-card li span { color: #38556e; }
.absence-record-card li em { color: #165b8f; text-align: right; white-space: nowrap; font-style: normal; font-weight: 850; }

@media (max-width: 900px) {
  .absence-form-grid { grid-template-columns: 1fr 1fr; }
  .absence-admin-overlay { padding: 10px; }
  .absence-admin-dialog { width: 100%; max-height: 97vh; }
}

@media (max-width: 700px) {
  .head-actions .absence-admin-open { order: 3; width: 100%; }
  .head-actions { flex-wrap: wrap; }
  .absence-admin-header { padding: 15px; }
  .absence-tab-panel { padding: 13px; }
  .absence-form-grid { grid-template-columns: 1fr; }
  .absence-form-actions { align-items: stretch; flex-direction: column; }
  .absence-form-actions button { width: 100%; }
  .absence-record-card > header { align-items: flex-start; flex-direction: column; }
  .absence-record-card li { grid-template-columns: 1fr; gap: 4px; }
  .absence-record-card li em { text-align: left; }
}
