:root {
  --bg: #eef3ff;
  --line: #c5d5fa;
  --muted: #40516d;
  font-family: Arial, "Helvetica Neue", sans-serif;
}
h1,
h2,
h3,
.steps-wordmark {
  font-family: "Segoe UI", Arial, sans-serif;
}
.portal-page {
  --footer-height: 66px;
  padding-bottom: var(--footer-height);
  background: var(--bg);
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
}
.portal-layout {
  display: grid;
  grid-template-columns: 248px minmax(0, 1fr);
  gap: 28px;
  max-width: 1920px;
  width: 100%;
  margin: 0 auto;
  padding: 18px 32px 24px;
  flex: 1;
}
.portal-sidebar {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 24px;
  box-shadow: 0 3px 6px #10224805;
  padding: 30px 18px 22px;
  display: flex;
  flex-direction: column;
  align-self: start;
  position: sticky;
  top: 18px;
  min-height: calc(100dvh - 126px);
}
.portal-sidebar .steps-wordmark {
  justify-content: center;
  font-size: 38px;
  margin: 0 0 12px;
}
.portal-version {
  text-align: center;
  font-size: 8px;
  letter-spacing: 0.15em;
  color: var(--muted);
  padding-bottom: 27px;
  border-bottom: 1px solid var(--line);
  display: block;
}
.portal-sidebar nav {
  margin-top: 20px;
}
.nav-section {
  font-size: 10px;
  font-weight: 750;
  letter-spacing: 0.12em;
  padding: 12px 14px;
  color: var(--primary);
}
.portal-sidebar nav a {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 46px;
  text-decoration: none;
  color: var(--ink);
  padding: 11px 14px;
  border-radius: 12px;
  font-size: 13px;
  margin-bottom: 5px;
}
.portal-sidebar nav a[aria-current] {
  background: var(--accent);
  font-weight: 650;
}
.portal-sidebar nav a:hover {
  box-shadow: inset 0 0 0 1px var(--primary);
}
.portal-sidebar svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.6;
  flex-shrink: 0;
}
.sidebar-note {
  margin-top: auto;
  padding: 42px 12px 0;
  font-size: 11px;
  font-weight: 600;
  color: var(--muted);
}
.sidebar-note p {
  font-size: 11px;
  font-weight: 400;
  margin-top: 10px;
}
.status-dot {
  display: inline-block;
  width: 7px;
  height: 7px;
  background: var(--primary);
  border-radius: 50%;
  margin-right: 5px;
}
.portal-workspace {
  min-width: 0;
}
.portal-topbar {
  min-height: 96px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--line);
  padding: 0 0 22px;
  gap: 24px;
}
.portal-topbar .eyebrow {
  font-size: 9px;
  margin-bottom: 5px;
}
.portal-topbar h1 {
  font-size: 26px;
  font-weight: 650;
  letter-spacing: -0.04em;
}
.portal-topbar p:not(.eyebrow) {
  font-size: 13px;
  margin-top: 5px;
}
.portal-account {
  display: flex;
  align-items: center;
  gap: 10px;
  background: #fff;
  border: 1px solid var(--line);
  padding: 6px 8px;
  border-radius: 18px;
  flex-shrink: 0;
}
.profile-avatar {
  display: grid;
  place-items: center;
  width: 33px;
  height: 33px;
  background: var(--primary-soft);
  color: var(--primary);
  border-radius: 50%;
  font-weight: 700;
}
.portal-account strong {
  font-size: 12px;
  display: block;
  max-width: 175px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.portal-account small {
  display: block;
  color: var(--primary);
  font-size: 9px;
  letter-spacing: 0.06em;
}
.portal-account button {
  border: 0;
  font-size: 12px;
}
.portal-main {
  padding: 24px 0 0;
  max-width: none;
  margin: 0;
  width: 100%;
}
.directory-metrics {
  display: grid;
  grid-template-columns: repeat(3, 1fr) 1.6fr;
  gap: 14px;
  margin-bottom: 18px;
}
.directory-metrics > div {
  padding: 15px 18px;
  border: 1px solid var(--line);
  background: #fff;
  border-radius: 16px;
  min-width: 0;
}
.directory-metrics span,
.directory-metrics small {
  display: block;
  font-size: 11px;
  color: var(--muted);
}
.directory-metrics strong {
  display: block;
  font-size: 23px;
  font-weight: 600;
  line-height: 1.4;
  margin-top: 3px;
}
.directory-metrics > div:last-child strong {
  font-size: 16px;
  margin-top: 8px;
}
.directory-metrics small {
  font-size: 10px;
  margin-top: 3px;
}
.directory-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 23px 24px;
  margin-bottom: 20px;
  box-shadow: 0 4px 8px #10224804;
  min-width: 0;
}
.card-heading {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 18px;
  margin-bottom: 20px;
}
.card-heading h2 {
  font-size: 16px;
  font-weight: 650;
}
.card-heading p {
  font-size: 12px;
  color: var(--muted);
  margin-top: 5px;
}
.subtle-tag {
  font-size: 10px;
  background: var(--primary-soft);
  color: var(--primary);
  padding: 5px 10px;
  border-radius: 20px;
  white-space: nowrap;
}
.directory-form {
  padding: 0;
}
.filter-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px 16px;
}
.filter-grid label {
  display: block;
  font-size: 14px;
  font-weight: 700;
  color: #172b4d;
  margin: 0 0 7px;
}
.filter-grid input,
.filter-grid select {
  width: 100%;
  min-width: 0;
  min-height: 44px;
  padding: 10px 12px;
  border: 1px solid #aac0ed;
  border-radius: 12px;
  color: var(--ink);
  background: #fff;
  font-size: 15px;
}
.filter-grid input:focus,
.filter-grid select:focus {
  border-color: var(--primary);
}
.filter-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-top: 22px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
}
.filter-bottom > p {
  font-size: 11px;
  color: var(--muted);
  max-width: 410px;
}
.filter-bottom > div {
  display: flex;
  gap: 10px;
  flex-shrink: 0;
}
.portal-page .login-submit {
  font-size: 12px;
  min-height: 44px;
  border-radius: 12px;
}
.portal-page .secondary-button {
  font-size: 12px;
  border-radius: 11px;
  white-space: nowrap;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
}
.directory-table-wrap {
  overflow: auto;
  max-height: 420px;
  width: 100%;
}
.directory-table {
  border-collapse: collapse;
  width: 100%;
  text-align: left;
  font-size: 12px;
}
.directory-table th {
  position: sticky;
  top: 0;
  font-weight: 500;
  color: var(--muted);
  font-size: 11px;
  padding: 12px 10px;
  background: #f7f9ff;
  border-bottom: 1px solid var(--line);
  white-space: nowrap;
}
.directory-table td {
  padding: 15px 10px;
  border-bottom: 1px solid #e6ecf8;
  vertical-align: middle;
  max-width: 230px;
  overflow-wrap: anywhere;
}
.directory-table td:last-child {
  text-align: right;
}
.table-person {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 190px;
}
.table-avatar {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  flex-shrink: 0;
  background: var(--primary-soft);
  color: var(--primary);
  border-radius: 10px;
  font-weight: 650;
}
.table-person strong {
  font-size: 12px;
  display: block;
  font-weight: 600;
}
.table-person small {
  font-size: 10px;
  color: var(--muted);
  display: block;
  margin-top: 3px;
  overflow-wrap: anywhere;
}
.employee-status {
  display: inline-block;
  padding: 4px 8px;
  border-radius: 20px;
  background: #edf0f6;
  color: var(--ink);
  font-size: 10px;
  white-space: nowrap;
}
.employee-status.is-active {
  background: var(--accent);
}
.directory-pagination {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding-top: 18px;
  font-size: 12px;
  color: var(--muted);
}
.directory-pagination > div {
  display: flex;
  gap: 10px;
}
.directory-empty {
  padding: 45px 20px;
  text-align: center;
  color: var(--muted);
}
.directory-empty h3 {
  font-size: 16px;
  color: var(--ink);
  margin-bottom: 8px;
}
.directory-empty p {
  font-size: 12px;
}
.corporate-footer {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  background: #fff;
  border-top: 1px solid var(--line);
  padding: 15px 48px;
  margin: 0;
  min-height: 66px;
  color: var(--ink);
  font-size: 10px;
  width: 100%;
}
.corporate-footer > img {
  display: block;
  width: 150px;
  height: auto;
  object-fit: contain;
}
.portal-page .corporate-footer {
  position: fixed;
  bottom: 0;
  left: 0;
  z-index: 20;
  height: var(--footer-height);
}
.corporate-footer > span {
  display: flex;
  align-items: center;
  gap: 4px;
}
.corporate-footer strong {
  font-weight: 600;
  color: #005ba6;
}
.footer-icon {
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: #f2f8ff;
  margin-right: 5px;
}
.footer-icon svg {
  width: 15px;
  height: 15px;
  fill: none;
  stroke: #005ba6;
  stroke-width: 1.5;
}
.employee-dialog {
  width: min(900px, calc(100% - 32px));
  padding: 28px;
}
.employee-tabs {
  display: flex;
  gap: 8px;
  border-bottom: 1px solid var(--line);
  margin: 25px 0 18px;
  padding-bottom: 12px;
  overflow: auto;
}
.employee-tabs button {
  padding: 10px 14px;
  background: #fff;
  color: var(--ink);
  font-size: 12px;
  white-space: nowrap;
  border-radius: 10px;
}
.employee-tabs button[aria-current] {
  background: var(--accent);
  font-weight: 600;
}
.detail-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
  margin: 24px 0;
}
.detail-grid > div {
  min-width: 0;
}
.detail-grid dt {
  color: var(--muted);
  font-size: 11px;
  margin-bottom: 5px;
}
.detail-grid dd {
  margin: 0;
  font-size: 13px;
  overflow-wrap: anywhere;
}
.hierarchy-person {
  border: 1px solid var(--line);
  border-radius: 15px;
  padding: 18px;
  margin-top: 14px;
}
.hierarchy-person h3 {
  font-size: 17px;
  margin-bottom: 5px;
}
.hierarchy-person p {
  font-size: 12px;
}
.hierarchy-person .eyebrow {
  font-size: 9px;
}
.hierarchy-person .employee-status {
  margin-top: 10px;
}
.panel-note,
#detail-status,
#sync-message {
  font-size: 12px;
  color: var(--muted);
}
.technical-details {
  border-top: 1px solid var(--line);
  margin-top: 22px;
  padding-top: 17px;
  font-size: 12px;
}
.technical-details pre,
.portal-page pre {
  overflow: auto;
  max-height: 350px;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  font-size: 11px;
  padding: 18px;
  border-radius: 12px;
  margin: 14px 0;
  background: #eef3ff;
  color: var(--ink);
}
.integration-endpoints {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin: 24px 0;
}
.integration-endpoints p {
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 18px;
  font-size: 12px;
  min-width: 0;
}
.integration-endpoints code {
  display: block;
  font-size: 11px;
  margin-top: 10px;
  overflow-wrap: anywhere;
}
.portal-users .users-main {
  max-width: none;
  margin: 0;
  padding: 26px 0;
}
.portal-users .users-card {
  border-radius: 20px;
}
.portal-users .users-heading h1 {
  font-size: 25px;
}
.login-page .corporate-footer {
  margin-top: auto;
}
.portal-page button:disabled {
  cursor: default;
}
@media (min-width: 1700px) {
  .portal-layout {
    padding-left: 60px;
    padding-right: 60px;
    grid-template-columns: 270px minmax(0, 1fr);
  }
  .directory-card {
    padding: 26px 28px;
  }
  .portal-topbar {
    min-height: 105px;
  }
}
@media (max-width: 1150px) {
  .portal-layout {
    grid-template-columns: 205px minmax(0, 1fr);
    padding: 16px;
    gap: 20px;
  }
  .portal-sidebar {
    padding: 25px 12px;
  }
  .portal-account strong {
    max-width: 115px;
  }
  .filter-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .filter-bottom {
    align-items: flex-start;
    flex-direction: column;
  }
  .directory-metrics {
    grid-template-columns: 1fr 1fr;
  }
  .portal-topbar {
    gap: 12px;
  }
  .portal-topbar h1 {
    font-size: 23px;
  }
  .portal-topbar p:not(.eyebrow) {
    max-width: 350px;
    font-size: 12px;
  }
  .corporate-footer {
    padding: 15px 24px;
  }
}
@media (max-width: 800px) {
  .portal-layout {
    display: flex;
    flex-direction: column;
    padding: 12px;
    gap: 15px;
  }
  .portal-sidebar {
    position: static;
    min-height: 0;
    width: 100%;
    padding: 15px;
    border-radius: 18px;
  }
  .portal-sidebar .steps-wordmark {
    font-size: 28px;
    justify-content: flex-start;
    margin: 0;
  }
  .portal-version,
  .sidebar-note,
  .nav-section {
    display: none;
  }
  .portal-sidebar nav {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
    margin-top: 14px;
  }
  .portal-sidebar nav a {
    white-space: nowrap;
    margin: 0;
    padding: 9px 12px;
    font-size: 12px;
  }
  .portal-sidebar nav a svg {
    width: 16px;
    height: 16px;
  }
  .portal-topbar {
    padding: 3px 4px 18px;
    align-items: flex-start;
  }
  .portal-account {
    padding: 3px 5px;
    gap: 5px;
  }
  .portal-account strong,
  .portal-account small,
  .profile-avatar {
    display: none;
  }
  .portal-main {
    padding-top: 18px;
  }
  .directory-card {
    padding: 19px 16px;
    border-radius: 17px;
  }
  .filter-grid {
    grid-template-columns: 1fr 1fr;
    gap: 16px;
  }
  .directory-metrics {
    gap: 10px;
  }
  .directory-metrics > div {
    padding: 12px;
  }
  .directory-metrics strong {
    font-size: 21px;
  }
  .card-heading {
    gap: 10px;
  }
  .subtle-tag {
    display: none;
  }
  .filter-bottom > div {
    width: 100%;
  }
  .filter-bottom .login-submit {
    flex: 1;
  }
  .directory-table {
    min-width: 0;
    display: block;
  }
  .directory-table thead {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip-path: inset(50%);
  }
  .directory-table tbody {
    display: block;
  }
  .directory-table tr {
    display: grid;
    grid-template-columns: 1fr 1fr;
    border: 1px solid var(--line);
    border-radius: 14px;
    padding: 12px;
    margin-bottom: 12px;
    gap: 10px;
  }
  .directory-table td {
    display: block;
    max-width: none;
    min-width: 0;
    border: 0;
    padding: 0;
  }
  .directory-table td:first-child,
  .directory-table td:last-child {
    grid-column: 1 / -1;
  }
  .directory-table td:last-child button {
    width: 100%;
  }
  .directory-table td:nth-child(2)::before {
    content: "Matrícula";
  }
  .directory-table td:nth-child(3)::before {
    content: "Cargo";
  }
  .directory-table td:nth-child(4)::before {
    content: "Empresa";
  }
  .directory-table td:nth-child(5)::before {
    content: "Status";
  }
  .directory-table td::before {
    display: block;
    color: var(--muted);
    font-size: 10px;
    margin-bottom: 3px;
  }
  .directory-table-wrap {
    max-height: 580px;
  }
  .corporate-footer > span {
    justify-content: center;
  }
  .detail-grid {
    grid-template-columns: 1fr 1fr;
  }
  .corporate-footer {
    padding: 14px 20px;
    flex-wrap: wrap;
  }
  .corporate-footer > img {
    width: 130px;
  }
  .integration-endpoints {
    grid-template-columns: 1fr;
  }
}
@media (max-width: 440px) {
  .portal-page {
    --footer-height: 96px;
  }
  .filter-grid {
    grid-template-columns: 1fr;
  }
  .portal-topbar .eyebrow {
    font-size: 8px;
  }
  .portal-topbar p:not(.eyebrow) {
    max-width: 235px;
  }
  .directory-metrics > div:last-child strong {
    font-size: 13px;
  }
  .filter-bottom > div {
    flex-wrap: wrap;
  }
  .filter-bottom button {
    width: 100%;
  }
  .corporate-footer {
    gap: 12px;
    justify-content: center;
  }
  .corporate-footer > span {
    font-size: 9px;
  }
  .employee-dialog {
    padding: 20px;
  }
  .detail-grid {
    grid-template-columns: 1fr;
  }
  .employee-dialog .dialog-heading h2 {
    font-size: 20px;
  }
  .employee-tabs {
    margin-top: 20px;
  }
}

/* Readable type scale shared by the directory, login and user management. */
.login-card label,
dialog label,
.users-search label {
  font-size: 14px;
  font-weight: 700;
  color: #172b4d;
}
.portal-topbar h1 {
  font-weight: 750;
}
.portal-sidebar nav a,
.portal-topbar p:not(.eyebrow),
.card-heading p,
.directory-table,
.table-person strong,
.portal-page .login-submit,
.portal-page .secondary-button,
.employee-tabs button,
.hierarchy-person p,
.detail-grid dd {
  font-size: 14px;
}
.portal-sidebar nav a {
  font-weight: 600;
  white-space: normal;
}
.directory-metrics span,
.directory-table th,
.detail-grid dt {
  font-size: 13px;
  font-weight: 700;
  color: #263d5d;
}
.table-person small,
.employee-status,
.filter-bottom > p,
.directory-pagination,
.directory-metrics small,
.panel-note,
.portal-account small,
.portal-account strong,
.directory-empty p {
  font-size: 12px;
}
.portal-topbar .eyebrow,
.nav-section {
  font-size: 11px;
}
.directory-table th {
  background: #eef3ff;
}
.filter-grid input::placeholder,
.login-card input::placeholder,
.users-search input::placeholder {
  color: #56647b;
  opacity: 1;
}
.card-heading h2 {
  font-size: 18px;
  font-weight: 700;
}
@media (max-width: 800px) {
  .portal-sidebar nav a {
    font-size: 13px;
    padding: 9px 8px;
    gap: 8px;
  }
  .directory-table td::before {
    font-size: 12px;
    font-weight: 700;
    color: #263d5d;
  }
  .filter-grid input,
  .filter-grid select {
    font-size: 16px;
  }
}
