:root {
  --blue: #2177bd;
  --blue-strong: #184f8f;
  --blue-soft: #eaf6ff;
  --teal: #00a99d;
  --ink: #172033;
  --muted: #667085;
  --line: #d8dee9;
  --surface: #ffffff;
  --page: #f6f8fb;
  --fuchsia: #d9368b;
  --orange: #f58220;
  --yellow: #f5c542;
  --violet: #a24ccf;
  --green: #4aa847;
  --amber: #c86513;
  --red: #b42318;
  --shadow: 0 14px 38px rgba(21, 35, 64, 0.12);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--page);
  color: var(--ink);
  font-family: Inter, "Segoe UI", Arial, sans-serif;
}

button,
input,
select,
textarea {
  font: inherit;
}

button {
  cursor: pointer;
}

.login-shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: minmax(320px, 480px) 1fr;
  background: #fff;
}

.login-panel {
  padding: 40px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  border-right: 1px solid var(--line);
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 800;
  color: #151515;
  letter-spacing: 0;
}

.brand-logo {
  width: 92px;
  height: 42px;
  object-fit: contain;
  flex: 0 0 auto;
}

.brand-mark {
  position: relative;
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: #fff;
  color: #151515;
  font-weight: 900;
  overflow: hidden;
  box-shadow: inset 0 0 0 1px var(--line);
}

.brand-mark::before {
  content: "";
  position: absolute;
  width: 16px;
  height: 16px;
  left: 4px;
  top: 5px;
  border-radius: 50%;
  background: var(--blue);
  box-shadow:
    15px 0 0 var(--fuchsia),
    7px 14px 0 var(--orange),
    21px 16px 0 var(--green),
    1px 24px 0 var(--yellow);
}

.brand-mark span {
  position: relative;
  z-index: 1;
  font-size: 12px;
  transform: translateY(1px);
}

.login-panel h1 {
  margin: 34px 0 10px;
  font-size: 32px;
  line-height: 1.1;
}

.login-panel p {
  margin: 0 0 28px;
  color: var(--muted);
}

.field {
  display: grid;
  gap: 7px;
  margin-bottom: 16px;
}

.field label {
  font-size: 13px;
  color: #344054;
  font-weight: 700;
}

.field input,
.field select,
.field textarea {
  min-height: 42px;
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  padding: 9px 12px;
}

.field textarea {
  min-height: 84px;
  resize: vertical;
}

.check-field {
  min-height: 42px;
  display: flex;
  align-items: center;
  gap: 10px;
  color: #344054;
  font-size: 13px;
  font-weight: 750;
}

.check-field input {
  width: 18px;
  height: 18px;
}

.primary,
.secondary,
.ghost,
.danger {
  min-height: 38px;
  border-radius: 8px;
  border: 1px solid transparent;
  padding: 8px 13px;
  font-weight: 750;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.primary {
  background: var(--fuchsia);
  color: #fff;
}

.secondary {
  background: var(--blue-soft);
  color: var(--blue-strong);
  border-color: #cfe0ff;
}

.ghost {
  background: #fff;
  color: var(--ink);
  border-color: var(--line);
}

.danger {
  background: #fff1f0;
  color: var(--red);
  border-color: #ffccc7;
}

.login-demo {
  margin-top: 24px;
  display: grid;
  gap: 8px;
  color: var(--muted);
  font-size: 13px;
}

.login-demo button {
  width: 100%;
}

.login-art {
  position: relative;
  overflow: hidden;
  min-height: 100vh;
  background:
    linear-gradient(135deg, rgba(217, 54, 139, 0.86), rgba(33, 119, 189, 0.74) 54%, rgba(0, 169, 157, 0.78)),
    url("data:image/svg+xml,%3Csvg width='1200' height='900' viewBox='0 0 1200 900' xmlns='http://www.w3.org/2000/svg'%3E%3Crect width='1200' height='900' fill='%23e8eef8'/%3E%3Cg fill='none' stroke='%23ffffff' stroke-opacity='.65' stroke-width='3'%3E%3Cpath d='M130 220h360v230H130zM570 180h420v310H570zM210 560h780v160H210z'/%3E%3Cpath d='M178 282h230M178 340h260M620 252h300M620 325h250M260 620h600M260 673h520'/%3E%3C/g%3E%3Cg fill='%23ffffff' fill-opacity='.82'%3E%3Ccircle cx='1040' cy='130' r='60'/%3E%3Ccircle cx='130' cy='720' r='42'/%3E%3Ccircle cx='1040' cy='735' r='26'/%3E%3C/g%3E%3C/svg%3E");
  background-size: cover;
  background-position: center;
}

.login-art-content {
  position: absolute;
  left: 56px;
  right: 56px;
  bottom: 56px;
  color: #fff;
  max-width: 680px;
}

.login-art-content h2 {
  margin: 0 0 10px;
  font-size: 46px;
  line-height: 1;
}

.login-art-content p {
  margin: 0;
  font-size: 18px;
  opacity: .92;
}

.portal {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 286px 1fr;
}

.sidebar {
  background: #fff;
  border-right: 1px solid var(--line);
  padding: 18px 16px;
  display: flex;
  flex-direction: column;
  gap: 22px;
}

.nav {
  display: grid;
  gap: 6px;
}

.nav button {
  min-height: 42px;
  width: 100%;
  border: 0;
  border-radius: 8px;
  padding: 10px 12px;
  background: transparent;
  color: #344054;
  text-align: left;
  font-weight: 750;
  display: flex;
  gap: 10px;
  align-items: center;
}

.nav button.active {
  background: #fff2f8;
  color: #9e1f63;
}

.nav-icon {
  width: 22px;
  height: 22px;
  display: grid;
  place-items: center;
  color: currentColor;
}

.sidebar-note {
  margin-top: auto;
  background: #f1f6ff;
  border: 1px solid #dce9ff;
  border-radius: 8px;
  padding: 14px;
  color: #344054;
  font-size: 13px;
}

.main {
  min-width: 0;
}

.topbar {
  height: 62px;
  background: #fff;
  border-bottom: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 24px;
  gap: 18px;
}

.company-select {
  display: flex;
  align-items: center;
  gap: 12px;
}

.company-select select {
  width: min(360px, 50vw);
}

.user-menu {
  display: flex;
  align-items: center;
  gap: 12px;
  text-align: right;
}

.avatar {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--fuchsia);
  color: #fff;
  font-weight: 900;
}

.content {
  padding: 28px clamp(18px, 4vw, 64px);
}

.eyebrow {
  color: var(--muted);
  font-size: 14px;
  margin-bottom: 8px;
}

.page-title {
  margin: 0 0 4px;
  font-size: 28px;
  line-height: 1.12;
}

.page-subtitle {
  margin: 0;
  color: var(--muted);
}

.section {
  margin-top: 30px;
}

.section-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 14px;
}

.section-head h2 {
  margin: 0;
  font-size: 20px;
}

.quick-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(160px, 1fr));
  gap: 14px;
}

.quick {
  min-height: 122px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  padding: 16px;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  font-weight: 800;
  text-align: left;
}

.quick span:first-child {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 16px;
}

.quick-badge,
.metric-icon {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  background: #fff2f8;
  color: var(--fuchsia);
  display: grid;
  place-items: center;
}

.quick:nth-child(2n) .quick-badge,
.metric:nth-child(2n) .metric-icon {
  background: #e5f8f5;
  color: #08766d;
}

.quick:nth-child(3n) .quick-badge,
.metric:nth-child(3n) .metric-icon {
  background: #fff2e4;
  color: var(--orange);
}

.quick:nth-child(4n) .quick-badge,
.metric:nth-child(4n) .metric-icon {
  background: #fff8cf;
  color: #8c6b00;
}

.metric-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(160px, 1fr));
  gap: 14px;
}

.metric {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  padding: 16px;
  display: grid;
  gap: 12px;
}

.metric strong {
  display: block;
  font-size: 28px;
}

.metric small {
  color: var(--muted);
}

.panel {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 18px;
}

.split {
  display: grid;
  grid-template-columns: 1.05fr .95fr;
  gap: 16px;
}

.table-wrap {
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

table {
  width: 100%;
  border-collapse: collapse;
  min-width: 680px;
}

th,
td {
  padding: 12px 14px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}

th {
  background: #f8fafc;
  color: #344054;
  font-size: 13px;
}

tr:last-child td {
  border-bottom: 0;
}

.pill {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  border-radius: 999px;
  padding: 2px 9px;
  font-size: 12px;
  font-weight: 800;
}

.pill.green {
  background: #e8f7ef;
  color: var(--green);
}

.pill.blue {
  background: #eaf6ff;
  color: var(--blue-strong);
}

.pill.amber {
  background: #fff4e5;
  color: var(--amber);
}

.pill.violet {
  background: #f2e9ff;
  color: #6d35a8;
}

.pill.red {
  background: #fff1f0;
  color: var(--red);
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(180px, 1fr));
  gap: 14px;
}

.full {
  grid-column: 1 / -1;
}

.telework-grid {
  display: grid;
  grid-template-columns: 1.2fr repeat(5, minmax(112px, 1fr));
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: auto;
  background: #fff;
}

.telework-cell {
  min-height: 48px;
  padding: 9px 10px;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  display: flex;
  align-items: center;
  font-size: 13px;
}

.telework-cell:nth-child(6n) {
  border-right: 0;
}

.telework-cell.header {
  background: #101828;
  color: #fff;
  font-weight: 800;
}

.telework-cell.presencial {
  background: #ffd7ea;
  color: #74164a;
  font-weight: 800;
}

.telework-cell.remoto {
  background: #fff;
  color: #111827;
}

.telework-cell.mixto {
  background: #e5f8f5;
  color: #075a63;
  font-weight: 800;
}

.empty {
  color: var(--muted);
  padding: 24px;
  border: 1px dashed var(--line);
  border-radius: 8px;
  background: #fff;
}

.toast {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 10;
  max-width: min(420px, calc(100vw - 36px));
  padding: 13px 16px;
  border-radius: 8px;
  background: #101828;
  color: #fff;
  box-shadow: var(--shadow);
}

.hidden {
  display: none !important;
}

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

  .login-art {
    min-height: 320px;
  }

  .sidebar {
    position: sticky;
    top: 0;
    z-index: 4;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .nav {
    grid-template-columns: repeat(2, minmax(140px, 1fr));
  }

  .sidebar-note {
    display: none;
  }

  .quick-grid,
  .metric-grid {
    grid-template-columns: repeat(2, minmax(180px, 1fr));
  }
}

@media (max-width: 640px) {
  .login-panel {
    padding: 26px 18px;
  }

  .login-art-content {
    left: 20px;
    right: 20px;
    bottom: 28px;
  }

  .login-art-content h2 {
    font-size: 34px;
  }

  .topbar {
    height: auto;
    padding: 12px;
    align-items: flex-start;
  }

  .company-select select {
    width: 100%;
  }

  .user-menu {
    align-items: flex-end;
  }

  .quick-grid,
  .metric-grid,
  .form-grid,
  .nav {
    grid-template-columns: 1fr;
  }

  .content {
    padding: 22px 14px;
  }
}
