:root {
  --nav:#263744;
  --nav-muted:#9eafb9;
  --accent:#2378ba;
  --text:#293b49;
  --muted:#7c8a95;
  --border:#e1e7eb;
  --background:#f2f5f7;
  --sidebar:224px;
  --topbar:56px;
  --topbar-background:#020e27;
  --surface:#fff;
  --surface-subtle:#f8fafb;
  --panel-padding:20px;
  --panel-gap:20px;
}
* {
  box-sizing:border-box;
}
body {
  margin:0;
  background:var(--background);
  color:var(--text);
  font-family:"Segoe UI",-apple-system,BlinkMacSystemFont,Arial,sans-serif;
  font-size:13px;
  line-height:1.5;
}
a {
  color:var(--accent);
  text-decoration:none;
}
a:hover {
  text-decoration:underline;
}
button,input,select,textarea {
  font:inherit;
}
button,a,input,select {
  touch-action:manipulation;
}
button {
  cursor:pointer;
}
button:focus-visible,a:focus-visible,input:focus-visible,select:focus-visible,textarea:focus-visible {
  outline:3px solid #8bbff0;
  outline-offset:3px;
}
h1,h2,p {
  margin-top:0;
}
h1 {
  font-size:25px;
  font-weight:600;
  margin-bottom:6px;
  letter-spacing:-.4px;
}
h2 {
  font-size:15px;
  font-weight:600;
  margin:0;
}
svg.icon {
  width:20px;
  height:20px;
  fill:none;
  stroke:currentColor;
  stroke-width:1.7;
  stroke-linecap:round;
  stroke-linejoin:round;
  flex-shrink:0;
}
.icon-definitions {
  position:absolute;
  width:0;
  height:0;
  overflow:hidden;
}
.muted {
  color:var(--muted);
}
.small {
  font-size:12px;
}
.sr-only {
  position:absolute;
  width:1px;
  height:1px;
  padding:0;
  margin:-1px;
  overflow:hidden;
  clip:rect(0,0,0,0);
  white-space:nowrap;
  border:0;
}
.skip-link {
  position:fixed;
  top:-100px;
  z-index:10;
  background:var(--surface);
  padding:12px;
}
.skip-link:focus {
  top:4px;
}
.topbar {
  height:var(--topbar);
  position:fixed;
  inset:0 0 auto 0;
  display:flex;
  align-items:center;
  background:var(--surface);
  border-bottom:1px solid var(--border);
  z-index:5;
}
.brand {
  display:flex;
  align-items:center;
  gap:9px;
  width:var(--sidebar);
  height:100%;
  background:var(--nav);
  padding:0 24px;
  font-size:25px;
  font-weight:600;
  color:#fff;
  letter-spacing:-1px;
}
.brand:hover {
  text-decoration:none;
}
.brand-mark {
  background:#3989be;
  color:#fff;
  display:grid;
  place-items:center;
  width:30px;
  height:32px;
  border-radius:7px;
  font-size:21px;
  letter-spacing:0;
}
.brand-id {
  font-weight:400;
  color:#70b5df;
}
.icon-button {
  display:inline-flex;
  justify-content:center;
  align-items:center;
  border:0;
  background:transparent;
  color:#607784;
  width:36px;
  height:36px;
  border-radius:4px;
}
.icon-button:hover {
  background:#eef3f6;
}
.screen-help {
  width:44px;
  height:44px;
  flex:none;
}
.menu-toggle {
  margin:0 16px;
}
.topbar-caption {
  color:#76848e;
  font-size:12px;
}
.topbar-tools {
  margin-left:auto;
  display:flex;
  align-items:center;
  gap:24px;
  padding:0 22px;
}
.company-switch {
  display:flex;
  align-items:center;
  gap:8px;
  color:#7d8c96;
}
.company-switch select {
  border:0;
  background:transparent;
  color:var(--text);
  max-width:195px;
  padding:6px 3px;
}
.company-submit {
  background:#edf3f7;
  color:var(--text);
  border:0;
  border-radius:4px;
  font-size:11px;
  padding:5px 8px;
}
.user-summary {
  display:flex;
  align-items:center;
  gap:9px;
}
.user-summary strong {
  display:block;
  font-size:12px;
  font-weight:600;
}
.user-summary small {
  display:block;
  font-size:10px;
  color:var(--muted);
}
.user-avatar {
  background:#e7eff5;
  border-radius:50%;
  display:grid;
  place-items:center;
  width:33px;
  height:33px;
  color:#53748c;
  font-weight:600;
}
.sidebar {
  position:fixed;
  left:0;
  top:var(--topbar);
  bottom:0;
  width:var(--sidebar);
  background:var(--nav);
  color:#fff;
  display:flex;
  flex-direction:column;
  z-index:4;
}
.nav-section {
  padding:25px 23px 10px;
  font-size:9px;
  font-weight:600;
  color:#8498a5;
  letter-spacing:1.1px;
}
.sidebar nav {
  padding:0 10px;
}
.nav-link {
  display:flex;
  align-items:center;
  gap:12px;
  color:#c1cfd7;
  padding:13px 13px;
  margin:3px 0;
  border-radius:5px;
  font-size:12px;
}
.nav-link .icon {
  width:18px;
  height:18px;
  color:#91a7b5;
}
.nav-link:hover {
  background:#ffffff08;
  text-decoration:none;
}
.nav-link.active {
  background:#377dab;
  color:#fff;
}
.nav-link.active .icon {
  color:#fff;
}
.sidebar-note {
  margin-top:auto;
  padding:18px 24px;
  color:#9aadb8;
  font-size:11px;
  border-top:1px solid #ffffff0c;
}
.status-dot {
  display:inline-block;
  width:6px;
  height:6px;
  background:#74b99a;
  border-radius:50%;
  margin-right:6px;
}
.main-content {
  margin-left:var(--sidebar);
  padding:calc(var(--topbar) + var(--panel-gap)) 27px var(--panel-gap);
  min-height:100vh;
}
.page-heading {
  display:flex;
  justify-content:space-between;
  align-items:center;
  gap:20px;
  margin:0 0 14px;
}
.page-heading p {
  color:var(--muted);
  font-size:12px;
  margin:0;
}
.button {
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:7px;
  min-height:36px;
  border-radius:4px;
  border:1px solid transparent;
  padding:8px 13px;
  font-size:12px;
  font-weight:500;
  white-space:nowrap;
}
.button .icon {
  width:16px;
  height:16px;
}
.button:hover {
  text-decoration:none;
  filter:brightness(.97);
}
.button.primary {
  background:var(--accent);
  border-color:var(--accent);
  color:#fff;
}
.button.secondary {
  background:var(--surface);
  border-color:#d7e0e6;
  color:#526c7e;
}
.summary-grid {
  display:grid;
  grid-template-columns:repeat(4,minmax(0,1fr));
  gap:17px;
  margin-bottom:23px;
}
.summary-card {
  background:var(--surface);
  border:1px solid var(--border);
  border-radius:5px;
  padding:20px 18px;
  display:flex;
  align-items:center;
  gap:14px;
}
.summary-card>div>span {
  font-size:11px;
  color:var(--readable-muted);
  display:block;
}
.summary-card strong {
  display:block;
  font-size:27px;
  font-weight:600;
  line-height:1.5;
  letter-spacing:-.6px;
}
.summary-card strong em {
  font-size:11px;
  font-weight:400;
  color:#91a0aa;
  margin-left:5px;
  font-style:normal;
  letter-spacing:0;
}
.summary-card small {
  font-size:10px;
  color:#9ba8b0;
  display:block;
}
.summary-icon {
  width:45px;
  height:45px;
  display:grid;
  place-items:center;
  border-radius:50%;
  flex-shrink:0;
}
.summary-icon.blue {
  background:#e9f2fa;
  color:#4882b7;
}
.summary-icon.green {
  background:#eaf6ef;
  color:#4d9674;
}
.summary-icon.purple {
  background:#f0edf8;
  color:#8c7aaf;
}
.summary-icon.orange {
  background:#fcf2e6;
  color:#c3985b;
}
.panel {
  background:var(--surface);
  border:1px solid var(--border);
  border-radius:8px;
  box-shadow:0 1px 2px #26374403;
  overflow:hidden;
}
.panel-heading {
  padding:14px var(--panel-padding);
  display:flex;
  align-items:center;
  justify-content:space-between;
  border-bottom:1px solid var(--border);
}
.panel-heading>div {
  display:flex;
  align-items:center;
  gap:15px;
}
.panel-heading .muted {
  font-size:11px;
}
.record-count {
  padding:3px 9px;
  background:#eef3f6;
  border-radius:12px;
  color:#79909e;
  font-size:10px;
}
.filter-bar {
  padding:18px 21px;
  display:flex;
  align-items:flex-end;
  gap:12px;
  background:var(--surface-subtle);
  border-bottom:1px solid var(--border);
  flex-wrap:wrap;
}
.field {
  display:flex;
  flex-direction:column;
  gap:6px;
  min-width:130px;
}
.field label {
  font-size:13px;
  font-weight:600;
  color:var(--text);
}
.field input,.field select {
  min-height:35px;
  height:35px;
  border:1px solid var(--border);
  border-radius:4px;
  background:var(--surface);
  color:var(--text);
  padding:6px 9px;
  max-width:100%;
}
.field input[type=date] {
  width:144px;
}
.field-personnel {
  min-width:170px;
}
.field-search {
  flex:1;
  min-width:155px;
  max-width:240px;
}
.field input::placeholder,.field textarea::placeholder,.dt-container input::placeholder {
  color:var(--readable-muted);
  opacity:1;
}
.reset-link {
  padding:8px 0;
  color:var(--readable-muted);
  font-size:11px;
}
.form-error {
  background:#fff1f2;
  color:#9d2235;
  padding:14px 21px;
  border-bottom:1px solid #f1b9bf;
}
.form-error ul { list-style:none; margin:0; padding:0; }
.form-error li + li { margin-top:4px; }
.field-validation-error { color:#9d2235; font-size:12px; }
.field > .field-validation-error { display:block; margin-top:4px; }
[data-theme=dark] .form-error { background:#43252f; color:#ffc0ca; border-color:#854955; }
[data-theme=dark] .field-validation-error { color:#ffc0ca; }
.table-scroll {
  overflow-x:auto;
}
.data-table {
  width:100%;
  border-collapse:collapse;
  white-space:nowrap;
  font-size:12px;
}
.data-table th {
  text-align:left;
  font-size:10px;
  font-weight:600;
  color:#8093a0;
  letter-spacing:.1px;
  background:var(--surface-subtle);
  border-bottom:1px solid var(--border);
  padding:10px var(--panel-padding);
}
.data-table th a {
  color:inherit;
}
.data-table td {
  padding:10px var(--panel-padding);
  border-bottom:1px solid var(--border);
  vertical-align:middle;
}
.data-table tbody tr:hover {
  background:var(--surface-subtle);
}
.data-table tbody tr:last-child td {
  border-bottom:0;
}
.data-table tfoot th,.data-table tfoot td {
  background:var(--surface-subtle);
  border-top:1px solid var(--border);
  padding:17px;
}
.data-table .numeric {
  text-align:right;
  font-variant-numeric:tabular-nums;
}
.duration {
  font-weight:600;
  color:#4b7a62;
  font-variant-numeric:tabular-nums;
}
.date-cell {
  font-size:11px;
  font-variant-numeric:tabular-nums;
}
.date-cell small {
  display:block;
  font-size:9px;
  color:#9daab3;
  margin-top:2px;
}
.person-cell {
  display:flex;
  align-items:center;
  gap:9px;
}
.person-cell strong {
  display:block;
  font-size:12px;
  font-weight:500;
  color:var(--text);
}
.person-cell small {
  display:block;
  font-size:10px;
  color:#94a4ae;
  margin-top:2px;
}
.person-avatar {
  display:grid;
  place-items:center;
  width:29px;
  height:29px;
  border-radius:50%;
  background:#eef2f5;
  color:#7790a1;
  font-size:9px;
  font-weight:600;
  flex-shrink:0;
}
.time-cell {
  font-size:11px;
  color:var(--text);
  font-variant-numeric:tabular-nums;
}
.badge {
  font-size:9px;
  padding:4px 7px;
  border-radius:4px;
  display:inline-block;
  font-weight:500;
}
.badge.completed {
  background:#eaf5ee;
  color:#588c6f;
}
.badge.review, .badge.shortfall {
  background:#fff3df;
  color:#a57a31;
}
.badge.weekend {
  background:#eef2f6;
  color:#7c8c98;
}
.detail-button {
  border:0;
  background:transparent;
  color:#94a9b7;
  display:flex;
  align-items:center;
  padding:3px;
}
.detail-button:hover {
  color:var(--accent);
}
.detail-button .icon {
  width:16px;
  height:16px;
}
.table-footer {
  padding:13px 21px;
  border-top:1px solid var(--border);
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:15px;
  font-size:12px;
  color:var(--readable-muted);
  background:var(--surface-subtle);
}
.pagination {
  display:flex;
  align-items:center;
  gap:12px;
}
.pagination span {
  border:1px solid var(--border);
  background:var(--surface);
  padding:3px 9px;
  border-radius:4px;
}
.page-note {
  display:flex;
  align-items:center;
  gap:7px;
  margin:16px 0;
  color:#8c9ba5;
  font-size:10px;
}
.page-note .icon {
  width:14px;
  height:14px;
}
.empty-state {
  text-align:center!important;
  padding:55px 20px!important;
  white-space:normal;
}
.empty-state>.icon {
  display:block;
  width:30px;
  height:30px;
  margin:0 auto 10px;
  color:#a5b8c5;
}
.empty-state strong {
  display:block;
  font-size:14px;
  font-weight:500;
  color:#788e9b;
}
.empty-state span {
  display:block;
  font-size:11px;
  color:#a0afb8;
  margin-top:6px;
}
.detail-dialog {
  border:0;
  padding:0;
  border-radius:8px;
  width:650px;
  max-width:calc(100vw - 32px);
  max-height:85vh;
  box-shadow:0 20px 80px #152b4140;
  color:var(--text);
}
.detail-dialog::backdrop {
  background:#1b304780;
  backdrop-filter:blur(1px);
}
.dialog-heading {
  display:flex;
  justify-content:space-between;
  align-items:center;
  padding:20px 24px;
  border-bottom:1px solid var(--border);
}
.eyebrow {
  font-size:9px;
  color:#8ba0af;
  letter-spacing:1px;
  font-weight:700;
  display:block;
  margin-bottom:4px;
}
.dialog-heading h2 {
  font-size:19px;
}
.dialog-close.icon-button {
  font-size:25px;
}
.dialog-body {
  padding:20px 24px;
}
.detail-person {
  padding:0 0 20px;
}
.detail-person>strong {
  display:block;
  font-size:18px;
  font-weight:600;
}
.detail-person>span {
  display:block;
  color:var(--muted);
  font-size:11px;
  margin-top:4px;
}
.detail-grid {
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:12px;
  margin:0 0 20px;
}
.detail-grid>div {
  background:var(--surface-subtle);
  border:1px solid var(--border);
  padding:11px 13px;
  border-radius:4px;
}
.detail-grid dt {
  font-size:10px;
  color:#8296a3;
}
.detail-grid dd {
  margin:3px 0 0;
  font-size:16px;
  font-weight:500;
  font-variant-numeric:tabular-nums;
}
.dialog-footer {
  padding:13px 24px;
  text-align:right;
  border-top:1px solid var(--border);
}
.notice {
  padding:13px 15px;
  background:#eef5fa;
  border:1px solid var(--border);
  border-radius:4px;
  font-size:11px;
  color:var(--text);
}
.guest .main-content {
  margin:0;
  padding-top:calc(var(--topbar) + 55px);
  display:flex;
  align-items:center;
  flex-direction:column;
}
.login-card {
  background:var(--surface);
  border:1px solid var(--border);
  border-radius:8px;
  padding:32px;
  width:480px;
  max-width:100%;
  box-shadow:0 6px 24px #26374405;
}
.login-card h1 {
  font-size:24px;
  margin-top:7px;
}
.login-card>p {
  color:#8798a3;
  font-size:12px;
}
.login-card .notice {
  margin:20px 0;
}
.login-card .login-error {
  background:#fff1f2;
  border-color:#f1b9bf;
  color:#9d2235;
  font-size:13px;
}
.login-card .login-error ul {
  list-style:none;
  margin:0;
  padding:0;
}
[data-theme=dark] .login-card .login-error {
  background:#43252f;
  border-color:#854955;
  color:#ffc0ca;
}
.login-card>.button {
  width:100%;
  margin-bottom:16px;
}
.preview-login {
  width:550px;
}
.server-preview-form {
  display: grid;
  gap: 12px;
  margin: 24px 0;
}
.server-preview-form input,.server-preview-form select {
  width: 100%;
  min-height: 42px;
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: 6px;
  background:var(--surface);
  color: inherit;
}
.validation-summary-valid {
  display: none;
}
.preview-choice {
  display:flex;
  justify-content:space-between;
  align-items:center;
  padding:17px 0;
  border-bottom:1px solid var(--border);
  gap:15px;
}
.preview-choice strong {
  display:block;
  font-size:13px;
  font-weight:500;
}
.preview-choice small {
  display:block;
  color:#8a9ca7;
  font-size:11px;
  margin-top:3px;
}
.preview-login>p:last-child {
  margin-top:20px;
  margin-bottom:0;
}
.menu-collapsed .sidebar {
  display:none;
}
.menu-collapsed .main-content {
  margin-left:0;
}
@media(min-width:1500px) {
  .main-content {
    padding-left:35px;
    padding-right:35px;
  }
  .summary-card {
    padding:22px;
  }
}
@media(max-width:1150px) {
  .topbar-caption {
    display:none;
  }
  .topbar-tools {
    gap:15px;
  }
  .summary-grid {
    gap:12px;
  }
  .summary-card {
    padding:16px 13px;
    gap:9px;
  }
  .summary-icon {
    width:35px;
    height:35px;
  }
  .summary-card strong {
    font-size:23px;
  }
  .main-content {
    padding-left:20px;
    padding-right:20px;
  }
  .field-search {
    max-width:none;
  }
  .filter-bar {
    gap:10px;
  }
  .user-summary small {
    display:none;
  }
}
@media(max-width:900px) {
  :root {
    --sidebar:200px;
  }
  .user-summary {
    display:none;
  }
  .topbar-tools {
    gap:10px;
    padding-right:12px;
  }
  .summary-grid {
    grid-template-columns:repeat(2,minmax(0,1fr));
  }
  .page-heading {
    gap:12px;
  }
  .environment-bar {
    flex-wrap:wrap;
  }
  .panel-heading>div {
    flex-wrap:wrap;
    gap:3px;
  }
  .brand {
    padding-left:20px;
  }
  .main-content {
    padding-left:16px;
    padding-right:16px;
  }
}
@media(max-width:650px) {
  :root {
    --sidebar:180px;
    --topbar:58px;
    --panel-padding:14px;
    --panel-gap:14px;
  }
  .brand {
    width:150px;
    font-size:22px;
    padding:0 13px;
  }
  .brand-mark {
    width:26px;
    height:28px;
    font-size:18px;
  }
  .menu-toggle {
    margin:0 5px;
  }
  .company-switch>svg,.company-submit {
    display:none;
  }
  .company-switch select {
    max-width:145px;
    font-size:11px;
  }
  .topbar-tools {
    gap:4px;
    padding-right:5px;
  }
  .sidebar {
    display:none;
    width:220px;
    box-shadow:5px 0 15px #14233120;
  }
  .menu-collapsed .sidebar {
    display:flex;
  }
  .main-content {
    margin-left:0;
    padding-left:12px;
    padding-right:12px;
    padding-top:calc(var(--topbar) + 12px);
  }
  .environment-bar {
    font-size:10px;
    gap:6px;
    margin-bottom:18px;
  }
  .environment-bar a {
    width:100%;
    margin-left:0;
  }
  .page-heading {
    align-items:flex-start;
    margin-bottom:17px;
  }
  .page-heading h1 {
    font-size:23px;
  }
  .page-heading p {
    font-size:11px;
    max-width:210px;
  }
  .page-heading>.button {
    font-size:10px;
    padding:7px 9px;
    min-height:33px;
  }
  .breadcrumb {
    font-size:10px;
    margin-bottom:10px;
  }
  .summary-grid {
    gap:9px;
    margin-bottom:18px;
  }
  .summary-card {
    padding:13px 10px;
    gap:8px;
  }
  .summary-card>div>span {
    font-size:10px;
  }
  .summary-card small {
    font-size:9px;
  }
  .summary-card strong {
    font-size:23px;
  }
  .summary-icon {
    width:31px;
    height:31px;
  }
  .summary-icon .icon {
    width:17px;
    height:17px;
  }
  .filter-bar {
    padding:14px 13px;
    gap:12px;
  }
  .field {
    flex:1;
    min-width:calc(50% - 12px);
  }
  .field input[type=date] {
    width:100%;
  }
  .field-personnel,.field-search {
    min-width:calc(50% - 12px);
  }
  .panel-heading {
    padding:16px 13px;
  }
  .table-footer {
    padding:12px 13px;
    flex-wrap:wrap;
  }
  .page-note {
    align-items:flex-start;
    font-size:10px;
  }
  .page-note>.icon {
    margin-top:2px;
  }
  .login-card {
    padding:25px 20px;
  }
  .detail-grid {
    gap:8px;
  }
  .dialog-body,.dialog-heading {
    padding:18px;
  }
  .page-footer {
    font-size:9px;
  }
  .guest .main-content {
    padding-top:calc(var(--topbar) + 28px);
  }
}
@media print {
  .sidebar,.topbar,.environment-bar,.button,.filter-bar,.pagination,.page-footer,.detail-button {
    display:none!important;
  }
  .main-content {
    margin:0;
    padding:0;
  }
  .summary-grid {
    gap:8px;
  }
  .panel,.summary-card {
    box-shadow:none;
  }
  .table-scroll {
    overflow:visible;
  }
  .data-table {
    font-size:9px;
  }
  .data-table th,.data-table td {
    padding:7px;
  }
  .page-heading {
    margin-bottom:15px;
  }
  .summary-card strong {
    font-size:20px;
  }
}

/* Both themes share the dark navigation bar. */
.topbar { background:var(--nav); color:#edf4f8; border-bottom-color:#ffffff15; }
.topbar .icon-button,.topbar-caption,.topbar .company-switch,.topbar .company-switch select { color:#dce8f0; }
.topbar .icon-button:hover { background:#ffffff12; }
.topbar .user-summary small { color:var(--nav-muted); }
.topbar .company-switch option { background:var(--nav); color:#edf4f8; }
.topbar .user-avatar { background:#ffffff15; color:#edf4f8; }
.sidebar { padding-top:10px; }
.theme-toggle { font-size:23px; flex-shrink:0; }
.guest-theme { margin-left:auto; margin-right:22px; }
:root[data-theme=dark] { color-scheme:dark; --nav:#18232e; --background:#111b25; --surface:#1c2a37; --surface-subtle:#21313f; --text:#e0e9ef; --muted:#a4b6c5; --border:#354756; --accent:#77b9eb; }
:root[data-theme=light] { color-scheme:light; }
[data-theme=dark] .button.secondary,[data-theme=dark] .company-submit { background:#2d4152; color:#dce8f0; border-color:var(--border); }
[data-theme=dark] .icon-button { color:#b8cedf; }
[data-theme=dark] .icon-button:hover,[data-theme=dark] .table-wrap tbody tr:hover { background:#293e50; }
[data-theme=dark] .notice { background:#21394b; color:#c4dfef; }
[data-theme=dark] .badge.completed { background:#244438; color:#a9d9ba; }
[data-theme=dark] .badge.review, [data-theme=dark] .badge.shortfall { background:#4c3d24; color:#e7c684; }
[data-theme=dark] .badge.weekend { background:#304253; color:#becdda; }
[data-theme=dark] .filter-error { background:#4a2d30; color:#f4b8ae; }
[data-theme=dark] .stat-icon { background:#2c4253; }
[data-theme=dark] input,[data-theme=dark] select { color:var(--text); }
[data-theme=dark] .button.primary { color:#142332; }
[data-theme=dark] .summary-card>div>span { color:var(--muted); }
[data-theme=dark] .duration { color:#a9d9ba; }
[data-theme=dark] .record-count,[data-theme=dark] .person-avatar { background:#304657; color:#c5d8e7; }
[data-theme=dark] .summary-icon.blue { background:#294355; color:#93c6ee; }
[data-theme=dark] .summary-icon.green { background:#244438; color:#a9d9ba; }
[data-theme=dark] .summary-icon.purple { background:#3c3451; color:#cbb5ed; }
[data-theme=dark] .summary-icon.orange { background:#4c3d24; color:#e7c684; }
.detail-dialog { background:var(--surface); }
.person-link {color:var(--text);font-weight:650;text-decoration:none;}
.person-link:hover {text-decoration:underline;}
.cell-secondary {display:block;color:var(--muted);font-size:12px;margin-top:4px;}
.personnel-facts {display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:20px;padding:20px;margin:0;border-bottom:1px solid var(--border);}
.personnel-facts dt {font-size:12px;color:var(--muted);margin-bottom:6px;}
.personnel-facts dd {margin:0;overflow-wrap:anywhere;}
.personnel-form {padding:var(--panel-padding);}
.personnel-fields {display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:18px;}
.personnel-fields .field {min-width:0;}
.personnel-fields input,.personnel-fields select {width:100%;}
.personnel-actions {display:flex;align-items:center;gap:8px 12px;flex-wrap:wrap;margin-top:18px;}
.personnel-pagination {display:flex;gap:8px;}
.button:disabled {opacity:.55;cursor:not-allowed;}
@media(max-width:650px){.personnel-fields,.personnel-facts{grid-template-columns:1fr;}.personnel-actions{align-items:flex-start;}}
.date-picker{position:relative;display:flex;align-items:center;min-width:170px;}
.date-picker input[data-date-picker]{width:100%;padding-right:36px;}
.calendar-trigger{position:absolute;right:4px;border:0;background:transparent;color:var(--text);padding:6px 8px;font-size:18px;}
.calendar-popup{position:absolute;top:calc(100% + 6px);left:0;z-index:20;width:300px;background:var(--surface);border:1px solid var(--border);border-radius:6px;padding:12px;box-shadow:0 8px 24px #0003;}
.calendar-popup[hidden]{display:none;}
.calendar-head{display:flex;gap:5px;align-items:center;margin-bottom:10px;}
.calendar-head select{min-width:100px;}.calendar-head input{width:76px!important;padding:6px!important;}
.calendar-head button,.calendar-grid button,.calendar-today{background:var(--surface-subtle);color:var(--text);border:1px solid var(--border);border-radius:4px;padding:6px;}
.calendar-grid{display:grid;grid-template-columns:repeat(7,1fr);gap:4px;text-align:center;}.calendar-grid span{font-size:11px;color:var(--muted);}.calendar-grid button.selected{background:var(--accent);color:#fff;}.calendar-today{width:100%;margin-top:10px;}
.management-fieldset{padding:0;margin:0;border:0;min-width:0;}.working-days{display:flex;flex-wrap:wrap;gap:18px;margin-top:22px;}.working-days label{display:flex;align-items:center;gap:6px;}
.permission-row{display:flex;align-items:end;flex-wrap:wrap;gap:16px;padding:20px;border-bottom:1px solid var(--border);}.permission-user{flex:1;min-width:160px;align-self:center;}.permission-row .field{flex:1;min-width:150px;}
.overtime-item{display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap;gap:18px;padding:20px;border-bottom:1px solid var(--border);}.overtime-decision{display:flex;align-items:end;flex-wrap:wrap;gap:12px;}
.sidebar{overflow-y:auto;}.sidebar-note{flex-shrink:0;}

.calendar-popup[popover]{position:fixed;inset:auto;margin:0;}.calendar-popup::backdrop{background:transparent;}

/* Shared header conventions with Akademia and SPM. */
:root[data-theme=light] { --nav:#0877b5; --nav-muted:#b0d8ed; }
.brand { flex-shrink:0; }
.menu-toggle { margin:0; width:50px; height:100%; border-radius:0; border-inline:1px solid #ffffff1a; background:var(--surface); }
.topbar .menu-toggle { color:var(--text); }
.topbar .menu-toggle:hover { background:var(--surface-subtle); }
.menu-toggle .icon { width:19px; height:19px; fill:currentColor; stroke-width:0; }
.connection-status { margin-left:20px; padding:3px 8px; border-radius:3px; background:#26723f; color:#fff; font-size:12px; font-weight:600; white-space:nowrap; }
.topbar-tools { gap:0; padding:0 10px 0 0; height:100%; min-width:0; }
.header-dropdown { position:relative; height:100%; min-width:0; }
.header-dropdown summary { list-style:none; display:flex; align-items:center; gap:8px; height:100%; padding:0 16px; cursor:pointer; color:#fff; }
.header-dropdown summary::-webkit-details-marker { display:none; }
.header-dropdown summary:hover,.header-dropdown[open] summary { background:#ffffff14; }
.header-dropdown summary:focus-visible { outline:3px solid #8bbff0; outline-offset:-3px; }
.header-dropdown .icon { width:17px; height:17px; }
.header-label { overflow:hidden; text-overflow:ellipsis; white-space:nowrap; max-width:240px; }
.caret { border-top:4px solid currentColor; border-left:4px solid transparent; border-right:4px solid transparent; flex-shrink:0; }
.header-dropdown-menu { position:absolute; top:100%; right:0; min-width:240px; max-width:min(360px,calc(100vw - 24px)); max-height:calc(100dvh - var(--topbar) - 16px); overflow-y:auto; padding:5px 0; background:var(--surface); color:var(--text); border:1px solid var(--border); border-radius:0 0 3px 3px; box-shadow:0 4px 12px #0002; }
.header-dropdown-menu form { margin:0; }
.dropdown-item { display:flex; align-items:center; gap:10px; width:100%; text-align:left; border:0; padding:10px 16px; background:transparent; color:var(--text); }
.dropdown-item:hover { background:var(--surface-subtle); }
.dropdown-item.selected { color:var(--accent); background:var(--surface-subtle); font-weight:600; }
.selection-check { margin-left:auto; }
.dropdown-user-info { padding:8px 16px 12px; margin-bottom:5px; border-bottom:1px solid var(--border); }
.dropdown-user-info strong,.dropdown-user-info small { display:block; }
.dropdown-user-info small { color:var(--muted); }
.topbar-tools .theme-toggle { width:44px; height:100%; border-radius:0; margin-left:4px; }
.topbar-tools .help-shortcut {
  flex:none;
  width:auto;
  min-width:44px;
  height:100%;
  padding-inline:12px;
  gap:7px;
  border-radius:0;
  text-decoration:none;
  white-space:nowrap;
}
.topbar-tools .help-shortcut[aria-current=page] { box-shadow:inset 0 -3px currentColor; }
@media(max-width:850px) {
  .topbar-tools .help-shortcut { padding-inline:0; }
  .help-shortcut span { display:none; }
}
.server-preview-form .login-pattern { width:100%; height:68px; text-align:center; font-size:clamp(23px,5vw,30px); font-weight:600; font-variant-numeric:tabular-nums; }
.login-pattern::placeholder { color:var(--muted); opacity:.75; }
.server-preview-form .login-code { font-size:36px; letter-spacing:.35em; padding-left:calc(12px + .35em); }
.login-reference { display:grid; justify-items:center; gap:4px; margin:16px 0; padding:14px; border:1px solid var(--border); border-radius:6px; }
.login-reference strong { font-size:2.25rem; letter-spacing:.3em; padding-inline-start:.3em; line-height:1.25; }
.login-reference time { font-variant-numeric:tabular-nums; }
.login-actions { display:flex; flex-wrap:wrap; gap:8px; margin-top:16px; }
.header-company-label { display:flex; align-items:center; gap:8px; padding-inline:12px; color:#fff; }
@media(min-width:651px) {
  .menu-collapsed .sidebar { display:flex; width:56px; overflow:visible; }
  .menu-collapsed .sidebar nav { overflow-y:auto; }
  .menu-collapsed .sidebar .nav-section,.menu-collapsed .sidebar .nav-link span { display:none; }
  .menu-collapsed .sidebar .nav-link { padding:14px 0; justify-content:center; margin:0; border-radius:0; }
  .menu-collapsed .main-content { margin-left:56px; }
  .menu-collapsed .brand { width:56px; padding:0; justify-content:center; }
  .menu-collapsed .brand>span:last-child { display:none; }
  .menu-collapsed .menu-toggle .icon { transform:rotate(180deg); }
}
@media(max-width:1000px) {
  .connection-status { margin-left:12px; }
  .header-dropdown summary { padding:0 10px; }
  .header-label { max-width:160px; }
}
@media(max-width:650px) {
  .brand { width:110px; padding:0 10px; font-size:20px; gap:5px; }
  .brand-mark { display:none; }
  .menu-toggle { width:40px; flex-shrink:0; }
  .connection-status { margin-left:8px; font-size:10px; padding:2px 5px; }
  .topbar-tools { padding-right:0; }
  .header-dropdown summary { padding:0 8px; gap:4px; }
  .header-dropdown .header-label { display:none; }
  .company-dropdown .header-label { display:block; max-width:clamp(48px,20vw,120px); }
  .company-dropdown summary .icon { display:none; }
  .header-dropdown-menu { position:fixed; right:8px; top:var(--topbar); }
  .topbar-tools .theme-toggle { width:36px; margin:0; }
  .menu-collapsed .menu-toggle .icon { transform:rotate(180deg); }
}

.sidebar .nav-section { color:var(--nav-muted); }
.sidebar .nav-link { color:#e8f3f9; }
.sidebar .nav-link .icon { color:#b5d4e6; }
.sidebar .nav-link.active .icon { color:#fff; }
.menu-collapsed .sidebar nav { padding:0; }

/* Navigation groups share the existing permission-scoped pages. */
.nav-group summary { list-style:none; cursor:pointer; }
.nav-group summary::-webkit-details-marker { display:none; }
.nav-group summary:focus-visible { outline:3px solid #8bbff0; outline-offset:-3px; }
.nav-group .nav-caret { margin-left:auto; font-size:20px; line-height:1; }
.nav-group[open] .nav-caret { transform:rotate(90deg); }
.nav-group .group-active { background:#ffffff0c; }
.nav-submenu { padding:0 0 4px; }
.nav-submenu .nav-link { padding:9px 12px 9px 43px; margin:2px 0; font-size:12px; }
.home-links { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:14px; padding:20px; }
.home-link { display:flex; align-items:center; gap:14px; border:1px solid var(--border); background:var(--surface); color:var(--text); padding:20px; border-radius:5px; }
.home-link:hover { text-decoration:none; background:var(--surface-subtle); border-color:var(--accent); }
.home-link>span { flex:1; }
.home-link strong,.home-link small { display:block; }
.home-link strong { font-size:15px; }
.home-link small { color:var(--muted); margin-top:4px; }
.home-link>.icon { color:var(--accent); }
@media(min-width:651px) { .menu-collapsed .nav-submenu { display:none; } }
@media(max-width:650px) { .home-links { grid-template-columns:1fr; padding:14px; } }

.operation-form {padding:var(--panel-padding);}.operation-form .personnel-fields{margin-bottom:18px;}.editor-panel summary{cursor:pointer;}.inline-decision{display:flex;gap:6px;flex-wrap:wrap;}.inline-decision input{border:1px solid var(--border);background:var(--surface);color:var(--text);padding:6px;max-width:200px;}.dashboard-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:14px;margin-bottom:20px;}.dashboard-stat{display:flex;flex-direction:column;padding:20px;background:var(--surface);border:1px solid var(--border);border-radius:5px;color:var(--text);}.dashboard-stat:hover{text-decoration:none;border-color:var(--accent);}.dashboard-stat strong{font-size:32px;}.dashboard-stat small{color:var(--muted);}.checkbox-field{display:flex;align-items:center;gap:8px;}[hidden]{display:none!important;}@media(max-width:650px){.dashboard-grid{grid-template-columns:repeat(2,minmax(0,1fr));}.operation-form{padding:14px;}}

.personnel-photo{width:120px;height:120px;object-fit:cover;border-radius:6px;margin:20px;}[data-national-id]{font-variant-numeric:tabular-nums;letter-spacing:.12em;}

.operation-form .working-days{grid-column:1/-1;min-width:0;border:0;padding:0;margin:0;display:flex;flex-wrap:wrap;gap:12px 20px;}
.operation-form .working-days legend{width:100%;margin-bottom:10px;}
.operation-form .working-days label{display:inline-flex;align-items:center;gap:7px;white-space:nowrap;width:auto;}
.operation-form .working-days input[type=checkbox],.operation-form .checkbox-field input[type=checkbox]{width:18px;height:18px;flex:0 0 18px;margin:0;}
.record-summary{display:grid;grid-template-columns:minmax(110px,160px) 1fr;gap:12px 18px;margin:0 0 24px;}.record-summary dt{color:var(--muted);}.record-summary dd{margin:0;overflow-wrap:anywhere;}

.list-actions,.list-exports{display:flex;align-items:center;flex-wrap:wrap;gap:8px;}.list-actions{padding:10px var(--panel-padding);border-bottom:1px solid var(--border);}.list-actions .button:disabled{opacity:.45;cursor:default;}.dt-container{color:var(--text);}.dt-container .dt-layout-row{padding:8px var(--panel-padding);margin:0!important;gap:12px;}.dt-container .dt-layout-table{padding:0;}.dt-container .dt-input{background:var(--surface);color:var(--text);border:1px solid var(--border);border-radius:4px;padding:8px;}.dt-container .dt-buttons .dt-button,.dt-container .dt-paging-button{background:var(--surface)!important;color:var(--text)!important;border:1px solid var(--border)!important;border-radius:4px!important;padding:8px 12px!important;margin:0!important;}.dt-container .dt-buttons{gap:8px;display:flex;flex-wrap:wrap;}.dt-container .dt-paging{display:flex;gap:4px;}.dt-container .dt-paging-button.current{background:var(--accent)!important;color:white!important;}.dt-container .dt-info{color:var(--muted);font-size:13px;}.data-table tbody tr.selected-row>*{background:var(--accent-soft)!important;}.dt-button-collection{background:var(--surface)!important;color:var(--text)!important;border:1px solid var(--border)!important;}.dt-container table.dataTable{border-collapse:collapse;margin:0!important;width:100%!important;}.table-scroll:has(.dt-container){overflow:visible;}.dt-container .dt-layout-full{width:100%;}.dt-container table.dataTable thead th{padding-right:26px;}.permission-row{flex-wrap:wrap;}@media(max-width:650px){.list-actions{padding:12px;}.dt-container .dt-layout-row{padding:8px 12px;flex-wrap:wrap;}.dt-container .dt-layout-cell{max-width:100%;}.dt-container .dt-search input{max-width:180px;}}

.dt-container .list-actions{padding:0;border:0;}.dt-container .dt-layout-row:first-child{padding-top:16px;padding-bottom:16px;}.dt-container .dt-layout-row:last-child{border-top:1px solid var(--border);padding-top:12px;padding-bottom:12px;}.dt-container .dt-length{white-space:nowrap;font-size:13px;}
/* Compact identity fields and shared personnel editor. */
.personnel-fields input[type="tel"],.field input[data-phone-mask]{width:23ch;max-width:100%;}
.personnel-fields input[data-national-id],.field input[data-national-id]{width:17ch;max-width:100%;}
.field .date-picker{width:185px;max-width:100%;min-width:0;}
.employee-editor{display:grid;grid-template-columns:minmax(0,700px) 180px;gap:32px;align-items:start;}
.employee-fields{column-gap:28px;row-gap:16px;}
.employee-fields input,.employee-fields select{max-width:320px;}
.employee-fields input[type="number"],.employee-fields .compact-code{width:180px;max-width:100%;}
.employee-status{max-width:700px;margin-top:20px;}
.form-switch{display:flex;align-items:center;gap:10px;min-height:40px;}
.field .switch-label{margin:0;cursor:pointer;}
.photo-editor{display:flex;flex-direction:column;gap:9px;}
.photo-editor>label{font-weight:600;}
.photo-drop{position:relative;width:180px;aspect-ratio:3 / 4;overflow:hidden;border:2px dashed var(--border);border-radius:6px;background:var(--surface);}
.photo-drop:focus-within,.photo-drop.drag-over{border-color:var(--accent);outline:2px solid var(--accent);outline-offset:2px;}
.photo-drop .photo-file{position:absolute;inset:0;width:100%;height:100%;opacity:0;cursor:pointer;z-index:2;}
.photo-drop img{width:100%;height:100%;object-fit:cover;display:block;}
.photo-placeholder{height:100%;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:10px;text-align:center;padding:12px;color:var(--muted);}
.photo-placeholder>span{font-size:58px;line-height:1;}
.photo-placeholder strong{font-size:14px;color:var(--text);}
.photo-placeholder small,.photo-editor>small{font-size:12px;}
.photo-error{font-size:12px;color:#d33;}
.photo-editor .reset-link{align-self:flex-start;background:none;border:0;padding:0;cursor:pointer;}
.personnel-photo{width:120px;height:160px;}
@media(max-width:900px){.employee-editor{grid-template-columns:minmax(0,1fr) 150px;gap:20px;}.photo-drop{width:150px;}}
@media(max-width:650px){.employee-editor{grid-template-columns:1fr;}.photo-editor{grid-row:1;}.photo-drop{width:135px;}.employee-fields input,.employee-fields select{max-width:100%;}.employee-fields{grid-template-columns:1fr;}}

/* Shared panel heading and list controls, Akademia/SPM conventions. */
:root{--list-selected:#dcecff;--readable-muted:#526574;}
:root[data-theme=dark]{--list-selected:#254f73;--readable-muted:#bccbd7;}
.panel-heading{gap:14px;flex-wrap:wrap;align-items:center;}
.panel-heading .panel-title{flex:0 1 auto;flex-wrap:wrap;min-width:0;gap:12px;}
.panel-title h1,.panel-heading>h1{font-size:20px;line-height:1.3;margin:0;font-weight:650;}
.panel-heading .panel-title>div{display:flex;align-items:center;flex-wrap:wrap;gap:12px;}
.panel-heading .panel-heading-actions{margin-left:auto;flex-wrap:wrap;}
.panel-heading-actions:empty{display:none;}
.panel-heading .panel-filters{display:flex;flex:0 1 auto;justify-content:flex-end;align-items:flex-end;flex-wrap:wrap;gap:10px;margin:0 0 0 auto;padding:0;border:0;background:transparent;}
.panel-filters .field{flex:0 1 auto;min-width:0;width:auto;}
.panel-filters .field-search{flex:0 1 175px;}
.panel-filters .field-personnel{flex:0 1 190px;}
.panel-filters .field input,.panel-filters .field select{width:165px;max-width:100%;}
.panel-filters .field input[type=number]{width:92px;}
.panel-filters .field-personnel select{width:190px;}
.panel-filters .field-search input{width:175px;}
.panel-filters .field .date-picker{width:150px;}
.panel-filters .field .date-picker input{width:100%;}
.panel-filters .field label{font-size:12px;margin-bottom:4px;color:var(--text);}
.panel-filters .button{padding:8px 12px;white-space:nowrap;}
.panel-filters .reset-link{align-self:center;flex:0 0 auto;white-space:nowrap;}
.dashboard-panel{margin-bottom:20px;}
.dashboard-panel>.dashboard-grid{padding:18px;margin:0;}
.dashboard-panel>.panel{margin:18px;}
.dashboard-panel>.panel-heading{border-bottom:1px solid var(--border);}
.sidebar .nav-link,.sidebar .nav-link .icon,.sidebar .nav-section{color:#fff;}
.sidebar .nav-link{font-size:14px;}
.sidebar .nav-submenu .nav-link{font-size:13px;}
.sidebar .nav-section{font-size:12px;}
.topbar .menu-toggle,.topbar-tools>.icon-button,.topbar-tools .header-dropdown>summary{background:transparent;color:#fff;}
.topbar .menu-toggle:hover,.topbar .menu-toggle:focus-visible,.topbar-tools>.icon-button:hover,.topbar-tools>.icon-button:focus-visible,.topbar-tools .header-dropdown>summary:hover,.topbar-tools .header-dropdown>summary:focus-visible,.topbar-tools .header-dropdown[open]>summary{background:#fff;color:#000;}
.topbar-tools .header-dropdown-menu .dropdown-item:hover,.topbar-tools .header-dropdown-menu .dropdown-item:focus-visible{background:#fff;color:#000;}
.data-table th,.dt-container table.dataTable thead th{font-size:13px;font-weight:650;color:var(--text);}
.data-table th a{color:inherit;}
.dashboard-stat small,.home-link small,.summary-card small,.text-muted{color:var(--readable-muted);}
.dt-container .dt-paging nav{display:flex;align-items:center;flex-wrap:wrap;gap:6px;}
.dt-container .dt-paging-button{margin:0!important;}
.data-table tbody tr:is([data-open-url],[data-detail-url],[data-edit-url],[data-role-url]){cursor:pointer;}
.data-table tbody tr.selected-row>*,.dt-container table.dataTable tbody tr.selected-row>*{background:var(--list-selected)!important;box-shadow:none!important;color:var(--text);}
.data-table tbody tr.selected-row>:first-child{box-shadow:inset 3px 0 var(--accent)!important;}
.data-table tbody tr:focus-visible{outline:2px solid var(--accent);outline-offset:-2px;}
@media(max-width:900px){.panel-heading .panel-filters{flex-basis:100%;}.panel-heading .panel-heading-actions{margin-left:auto;}}
@media(max-width:650px){.panel-heading{padding:14px;}.panel-heading .panel-filters{justify-content:flex-start;}.panel-filters .field-search,.panel-filters .field-personnel{flex:0 1 165px;}.panel-heading .panel-title h1{font-size:18px;}}
strong.person-link:hover{text-decoration:none;}
.dt-container .dt-paging .dt-paging-button{color:var(--text)!important;}
.dt-container .dt-paging .dt-paging-button.disabled{color:var(--readable-muted)!important;opacity:.65;}
div.dt-container .dt-paging .dt-paging-button.current{color:#fff!important;}
[data-theme=dark] div.dt-container .dt-paging .dt-paging-button.current{color:#14202a!important;}
div.dt-container .dt-paging nav .dt-paging-button.disabled{color:var(--readable-muted)!important;opacity:.65;}
/* Dedicated ShiftId logos, rendered at half their source resolution. */
.topbar,.topbar .brand{background:var(--topbar-background);}
.brand-logo{flex:none;object-fit:contain;}
.brand-logo-wide{display:block;width:176px;height:32px;max-width:100%;}
.brand-logo-compact{display:none;width:32px;height:32px;}
@media(min-width:651px){.menu-collapsed .brand-logo-wide{display:none;}.menu-collapsed .brand-logo-compact{display:block;}}
@media(max-width:650px){.brand-logo-wide{width:124px;height:32px;}.menu-collapsed .brand-logo-wide{display:none;}.menu-collapsed .brand-logo-compact{display:block;}}
@media(max-width:440px) {
  .topbar:has(.help-shortcut) .brand { width:52px; padding:0; justify-content:center; }
  .topbar:has(.help-shortcut) .brand-logo-wide,.topbar:has(.help-shortcut) .connection-status { display:none; }
  .topbar:has(.help-shortcut) .brand-logo-compact { display:block; }
  .topbar:has(.help-shortcut) .header-company-label { min-width:0; }
}

/* Keep filter labels beside their controls only when the panel has room. */
.panel:has(> .panel-heading .panel-filters){container:filter-panel / inline-size;}
@media(min-width:651px){
  @container filter-panel (min-width:320px){
    .panel-filters>.field:only-of-type{flex-direction:row;align-items:center;gap:8px;}
    .panel-filters>.field:only-of-type>label{margin:0;white-space:nowrap;}
  }
  @container filter-panel (min-width:960px){
    .panel-heading .panel-filters{align-items:center;}
    .panel-filters>.field{flex:0 1 auto;flex-direction:row;align-items:center;gap:8px;}
    .panel-filters>.field>label{margin:0;white-space:nowrap;flex:none;}
    .panel-filters .field input,.panel-filters .field select{width:135px;}
    .panel-filters .field input[type=number]{width:92px;}
    .panel-filters .field-search input{width:145px;}
    .panel-filters .field-personnel select{width:155px;}
    .panel-filters .field .date-picker{width:130px;flex:none;}
    .panel-filters .field .date-picker input{width:100%;}
  }
}
.initial-leave-fields{max-width:720px;border:1px solid var(--border);border-radius:5px;padding:16px;margin:20px 0;}.initial-leave-fields legend{font-weight:600;padding:0 6px;}
.monthly-legend{margin:0;padding:12px var(--panel-padding);color:var(--text);}
.month-day{min-width:58px;text-align:center;}.monthly-table .month-summary{min-width:90px;}.period-details{padding:20px;}.period-checks{display:flex;flex-wrap:wrap;gap:12px;margin-bottom:18px;}.period-checks>span{padding:8px 12px;background:var(--surface-subtle);border:1px solid var(--border);border-radius:4px;}
@media(min-width:651px){.sidebar{transition:width .24s ease;}.main-content{transition:margin-left .24s ease;}.brand{transition:width .24s ease,padding .24s ease;}.sidebar .nav-link .icon{flex-shrink:0;}.sidebar .nav-link span{white-space:nowrap;overflow:hidden;}}
@media(max-width:650px){.sidebar{display:flex;visibility:hidden;transition:transform .24s ease,visibility 0s .24s;transform:translateX(-100%);}.menu-collapsed .sidebar{display:flex;visibility:visible;transition-delay:0s;transform:translateX(0);}}
@media(prefers-reduced-motion:reduce){.sidebar,.main-content,.brand{transition:none!important;}}

/* Keep the shared column chooser outside clipped panels and within the viewport. */
body>div.dt-button-collection.fixed{box-sizing:border-box;top:50%!important;left:50%!important;transform:translate(-50%,-50%);margin:0!important;width:280px;max-width:calc(100vw - 32px);max-height:calc(100dvh - 32px);overflow:hidden;padding:10px;box-shadow:0 8px 32px #0004;}
body>div.dt-button-collection.fixed>:last-child{max-height:calc(100dvh - 110px);overflow-y:auto;overscroll-behavior:contain;}
body>div.dt-button-collection .dt-button{box-sizing:border-box;width:100%;color:var(--text)!important;background:var(--surface)!important;border:1px solid var(--border)!important;border-radius:4px;margin:4px 0;padding:10px 36px 10px 12px;text-align:left;white-space:normal;}
body>div.dt-button-collection .dt-button:hover,body>div.dt-button-collection .dt-button:focus-visible{background:var(--accent-soft)!important;}
body>div.dt-button-collection .dt-button-collection-title{color:var(--text);font-weight:600;white-space:normal;}

.audit-change-table{width:100%;border-collapse:collapse;font-size:13px;}.audit-change-table th,.audit-change-table td{padding:12px 20px;text-align:left;border-top:1px solid var(--border);vertical-align:top;overflow-wrap:anywhere;}.audit-change-table thead{background:var(--surface-subtle);}.audit-change-table thead th{font-size:13px;color:var(--text);}.audit-change-table tbody th{font-weight:600;width:30%;}.audit-change-table td{width:35%;white-space:pre-wrap;}.audit-notice{margin:12px 20px;padding:12px;background:var(--accent-soft);border-radius:4px;}
/* Mobile management screens share the panel's normal list and form conventions. */
.device-facts{display:grid;grid-template-columns:max-content minmax(0,1fr);gap:10px 24px;margin:0 0 24px}.device-facts dt{font-weight:600}.device-facts dd{margin:0;overflow-wrap:anywhere}
.device-zones{margin:0 0 20px;padding:16px;display:flex;flex-wrap:wrap;gap:12px 24px}.rotation-editor{padding:16px;margin:16px 0}.rotation-step{display:flex;align-items:end;gap:12px;margin:12px 0}.rotation-step[hidden]{display:none}.rotation-step .field:first-of-type{width:min(360px,65%)}.rotation-step input[type=number]{width:90px}.announcement-body{white-space:pre-wrap;overflow-wrap:anywhere}.compact-field{max-width:360px}.panel-body{padding:var(--panel-padding)}.panel-note{padding:12px var(--panel-padding);margin:0;color:var(--readable-muted)}
.topbar-tools .alert-shortcut{display:flex;align-items:center;gap:6px;text-decoration:none;padding:0 14px;color:#fff;height:100%}.alert-count{font-size:12px;font-weight:700;min-width:20px;padding:2px 5px;border-radius:10px;background:#c93d3d;color:#fff}.topbar-tools .alert-shortcut:hover{background:#fff;color:#000}
@media(max-width:600px){.device-facts{grid-template-columns:1fr;gap:5px}.device-facts dd{margin-bottom:10px}.rotation-step{gap:8px}.topbar-tools .alert-shortcut{padding:0 8px}}
.editor-form{padding:var(--panel-padding)}.editor-form>.field{max-width:720px;margin-bottom:16px}.editor-form .checkbox-field{margin:16px 0}.form-grid{display:grid;grid-template-columns:repeat(2,minmax(0,360px));gap:16px;margin-bottom:18px}.form-grid .field{min-width:0}.editor-form textarea{display:block;width:100%;font:inherit;padding:10px;border:1px solid var(--border);border-radius:4px;background:var(--surface);color:var(--text);resize:vertical}.editor-form input[data-date-picker]{max-width:190px}.rotation-step .field{margin:0}.rotation-step>span{padding-bottom:9px}.panel-heading-actions{display:flex;align-items:center;gap:10px}
@media(max-width:650px){.form-grid{grid-template-columns:minmax(0,1fr)}}
.announcement-editor>.field{max-width:100%}.rich-toolbar{display:flex;gap:6px;flex-wrap:wrap;padding:10px;background:var(--surface-subtle);border:1px solid var(--border);border-bottom:0;border-radius:4px 4px 0 0}.rich-toolbar .button{padding:7px 10px}.rich-link-tools{display:flex;align-items:center;gap:8px;flex-wrap:wrap;padding:10px;border:1px solid var(--border);border-bottom:0}.rich-link-tools input{flex:1;min-width:160px;max-width:460px;padding:8px;border:1px solid var(--border);background:var(--surface);color:var(--text);border-radius:4px}.rich-editable{min-height:250px;padding:16px;border:1px solid var(--border);background:var(--surface);border-radius:0 0 4px 4px;overflow-wrap:anywhere}.rich-editable:focus{outline:2px solid var(--accent);outline-offset:0}.announcement-rich{overflow-wrap:anywhere;line-height:1.65}.announcement-rich p{margin:.6em 0}.announcement-rich img{max-width:100%;height:auto;display:block;margin:12px 0}.announcement-rich table{border-collapse:collapse;width:100%;margin:12px 0}.announcement-rich th,.announcement-rich td{border:1px solid var(--border);padding:8px}.announcement-rich pre{overflow:auto;background:var(--surface-subtle);padding:12px}.announcement-rich blockquote{border-left:3px solid var(--accent);padding-left:14px;margin-left:0}.announcement-align-center{text-align:center}.announcement-align-left{text-align:left}.announcement-align-right{text-align:right}.announcement-rich h2{font-size:22px}.announcement-rich h3{font-size:18px}.announcement-editor small{display:block;margin-top:8px;color:var(--readable-muted)}.announcement-file-editor,.schedule-fields{padding:16px;border:1px solid var(--border);margin:20px 0}.announcement-drop{padding:20px;border:2px dashed var(--border);border-radius:5px;display:flex;flex-direction:column;gap:10px}.announcement-drop.dragging{border-color:var(--accent);background:var(--surface-subtle)}.attachment-edit-row{display:flex;align-items:center;gap:12px;flex-wrap:wrap;padding:12px 0;border-bottom:1px solid var(--border)}.attachment-edit-row label{display:inline-flex;align-items:center;gap:6px}.announcement-attachments{border-top:1px solid var(--border);margin-top:24px;padding-top:12px}.announcement-attachments>a{display:block;padding:8px 0}.announcement-status{font-size:22px!important}.schedule-fields .personnel-fields{max-width:520px;grid-template-columns:1fr 1fr;margin-bottom:15px}.schedule-fields input{max-width:190px}.schedule-fields input[name=ScheduleTime]{max-width:110px}@media(max-width:650px){.rich-toolbar .button{padding:6px 8px}.schedule-fields .personnel-fields{grid-template-columns:1fr}}

/* Daily roster shares the list toolbar and exports; selection is per day cell. */
.roster-grid td {min-width:155px;vertical-align:top;}
.roster-grid td:first-child {min-width:210px;}
.roster-grid small {display:block;white-space:normal;}
.roster-cell {display:flex;gap:8px;align-items:flex-start;cursor:pointer;min-height:74px;padding:4px;}
.roster-cell input {width:17px;min-width:17px;height:17px;margin:3px 0 0;}
.roster-cell:has(input:disabled) {cursor:default;}
.roster-rest {background:var(--surface-subtle);}
.roster-grid td.roster-selected {background:color-mix(in srgb,var(--accent) 18%,var(--surface));box-shadow:inset 0 0 0 2px var(--accent);}
[data-roster-actions] {display:flex;flex-wrap:wrap;align-items:center;gap:8px;}
[data-roster-editor] select {max-width:390px;}
.roster-copy-people {border:1px solid var(--border);padding:16px;margin:18px 0;max-width:760px;}
.roster-copy-person-list {display:grid;grid-template-columns:repeat(auto-fit,minmax(240px,1fr));gap:8px;max-height:320px;overflow:auto;margin:12px 0;}
.roster-copy-person-list label {display:flex;gap:8px;align-items:flex-start;padding:8px;background:var(--surface-subtle);border-radius:6px;}
.roster-copy-person-list label[hidden] {display:none;}
.roster-copy-person-list small,[data-copy-preview] td small {display:block;}
[data-copy-source][hidden] {display:none;}

.exit-line { padding: 1rem 0; border-bottom: 1px solid var(--border); margin-bottom: 1rem; }

.organization-outline { margin-top: .75rem; }
.organization-outline summary { cursor: pointer; font-weight: 600; }
.organization-outline ul { list-style: none; margin: .6rem 0; padding-left: 1.2rem; border-left: 1px solid var(--border); }
.organization-outline li { padding: .25rem 0 .25rem .5rem; }
.organization-outline small { color: var(--muted); }

.panel-filters.comparison-filters .field input { width: 128px; }
.panel-filters.comparison-filters .field label { white-space: nowrap; }
.panel-filters.comparison-filters .field-personnel select { width: 170px; }

/* Shared form and list readability, including newer administrative screens. */
.field textarea{display:block;width:100%;min-height:110px;padding:10px;border:1px solid var(--border);border-radius:4px;background:var(--surface);color:var(--text);resize:vertical;line-height:1.5;}
.field{min-width:0;}
.field small,.personnel-fields small,.panel-note,.cell-secondary,.muted{color:var(--readable-muted);}
.field small,.personnel-fields small{font-size:12px;line-height:1.5;}
.personnel-fields>.field,.operation-form>.field{margin-bottom:8px;}
.personnel-fields>label:has(input[type=checkbox]){display:flex;align-items:center;gap:10px;padding:12px;border:1px solid var(--border);border-radius:4px;}
.personnel-fields>label>input[type=checkbox]{width:18px;height:18px;min-height:18px;flex:none;margin:0;accent-color:var(--accent);}
.status-badge{display:inline-flex;align-items:center;max-width:100%;padding:3px 9px;border-radius:4px;font-size:12px;font-weight:600;line-height:1.5;white-space:normal;overflow-wrap:anywhere;background:#edf1f5;color:#405365;}
.status-badge.positive{background:#e5f3e9;color:#205e39;}.status-badge.waiting{background:#fff1d4;color:#795214;}.status-badge.negative{background:#fce7e7;color:#9b2e32;}
[data-theme=dark] .status-badge{background:#304253;color:#d3dfe9;}[data-theme=dark] .status-badge.positive{background:#244438;color:#b7e6c8;}[data-theme=dark] .status-badge.waiting{background:#4c3d24;color:#f1d398;}[data-theme=dark] .status-badge.negative{background:#532e36;color:#ffc6cc;}
.monthly-table th.monthly-person,.monthly-table td.monthly-person{position:sticky;left:0;z-index:2;background:var(--surface)!important;box-shadow:2px 0 0 var(--border);}
.monthly-table th.monthly-person{z-index:3;}.monthly-table td.monthly-person>strong{display:block;min-width:145px;max-width:200px;white-space:normal;overflow-wrap:anywhere;}
.monthly-table tr.selected-row>td.monthly-person{background:var(--list-selected)!important;}
@media(min-width:651px) and (max-width:1050px){.employee-editor{grid-template-columns:minmax(0,1fr);}.employee-editor>.photo-editor{grid-row:1;}.employee-fields{column-gap:20px;}}
@media(max-width:650px){.record-summary{grid-template-columns:minmax(0,1fr);gap:4px;}.record-summary dd{margin-bottom:12px;}.rotation-step{flex-wrap:wrap;}.monthly-table td.monthly-person>strong{min-width:115px;max-width:145px;}}

/* Scoped mobile feature settings */

/* Bootstrap Switch: shared light/dark skin for every checkbox, including list selections. */
.bootstrap-switch{flex:none;vertical-align:middle;border-color:var(--border);background:var(--surface);font-family:inherit;}
.bootstrap-switch .bootstrap-switch-handle-on,.bootstrap-switch .bootstrap-switch-handle-off,.bootstrap-switch .bootstrap-switch-label{font:inherit;font-size:12px;line-height:18px;padding:5px 8px;}
.bootstrap-switch .bootstrap-switch-handle-on.bootstrap-switch-primary{background:var(--accent);color:#fff;}
[data-theme=dark] .bootstrap-switch .bootstrap-switch-handle-on.bootstrap-switch-primary{color:#142332;}
.bootstrap-switch .bootstrap-switch-handle-off.bootstrap-switch-default{background:var(--surface-subtle);color:var(--text);}
.bootstrap-switch .bootstrap-switch-label{background:var(--surface);color:var(--text);}
.bootstrap-switch.bootstrap-switch-focused{outline:2px solid var(--accent);outline-offset:2px;box-shadow:none;}
.bootstrap-switch.panel-switch-locked{opacity:.55;cursor:not-allowed;}
.bootstrap-switch.panel-switch-locked .bootstrap-switch-container{cursor:not-allowed;}
.bootstrap-switch input[type=checkbox]{visibility:visible;opacity:0;position:absolute;left:50%;pointer-events:none;width:1px!important;height:1px!important;min-width:0;min-height:0;margin:0;padding:0;}
@media(prefers-reduced-motion:reduce){.bootstrap-switch .bootstrap-switch-container{transition:none!important;}}

/* The ShiftId administration workspace uses the right side of the panel. */
.platform-workspace .sidebar {
  left:auto;
  right:0;
}
@media(min-width:651px) {
  .platform-workspace .main-content {
    margin-left:0;
    margin-right:var(--sidebar);
    transition:margin-right .24s ease;
  }
  .platform-workspace.menu-collapsed .main-content {
    margin-right:56px;
  }
}
@media(max-width:650px) {
  .platform-workspace .sidebar {
    box-shadow:-5px 0 15px #14233120;
    transform:translateX(100%);
  }
  .platform-workspace.menu-collapsed .sidebar {
    transform:translateX(0);
  }
}

.device-brightness-form {
  margin-bottom:24px;
}
.device-brightness-form > label {
  font-weight:600;
}
.device-brightness-control {
  display:flex;
  flex-wrap:wrap;
  align-items:center;
  gap:8px 12px;
  margin:6px 0;
}
.device-brightness-control input[type=range] {
  width:min(250px, 75%);
  margin:0;
  accent-color:var(--accent);
}
.device-brightness-control output {
  min-width:3ch;
  font-variant-numeric:tabular-nums;
}
.device-brightness-control :is(input[type=number],select) {
  min-height:35px;
  max-width:100%;
  padding:6px 8px;
  border:1px solid var(--border);
  border-radius:4px;
  background:var(--surface);
  color:var(--text);
  font:inherit;
}
.device-brightness-control > label { font-weight:600; }
.form-actions { display:flex; flex-wrap:wrap; align-items:center; gap:8px; }

.heartbeat-interval-input {
  width:9ch;
}
.device-detail-columns {
  display:grid;
  grid-template-columns:repeat(auto-fit,minmax(min(100%,330px),1fr));
  gap:20px 32px;
}
.device-detail h2 { margin:0 0 14px; }
.device-detail .device-facts { margin-bottom:12px; }
.device-detail-settings { margin-top:20px; padding-top:20px; border-top:1px solid var(--border); }
.device-detail-settings + .button { margin-top:16px; }
.device-detail [data-heartbeat-conversion] { display:block; }

@media(max-width:650px) {
  .personnel-form { padding:14px; }
  .date-picker { min-width:0; max-width:100%; }
  .date-picker input { min-width:0; }
  .working-days label { min-width:0; max-width:100%; }
  .personnel-fields > .field > :is(input,select,textarea) { min-width:0; max-width:100%; }
  .management-fieldset .personnel-fields { grid-template-columns:minmax(0,1fr); }
  .management-fieldset .personnel-actions > * { min-width:0; max-width:100%; }
  .management-fieldset .working-days { gap:10px 14px; }
}

@media(max-width:360px) {
  .topbar .connection-status { display:none; }
}

.server-list-toolbar {
  display:flex;
  flex-wrap:wrap;
  align-items:end;
  gap:8px 12px;
  padding:10px var(--panel-padding);
}
.server-list-toolbar label {
  display:grid;
  gap:4px;
  min-width:0;
}
.server-list-toolbar :is(input,select) {
  max-width:100%;
  min-width:0;
  min-height:34px;
  padding:6px 8px;
  border:1px solid var(--border);
  border-radius:4px;
  background:var(--surface);
  color:var(--text);
}
.server-list-pager {
  display:flex;
  flex-wrap:wrap;
  align-items:center;
  justify-content:space-between;
  gap:10px 16px;
  padding:12px 20px;
}
.server-list-pager nav {
  display:flex;
  flex-wrap:wrap;
  align-items:center;
  gap:6px;
}
.server-list-sort {
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:6px;
  color:inherit;
  text-decoration:none;
}
.server-list-sort:hover { text-decoration:underline; }
.server-list-sort [aria-hidden] { color:var(--muted); }
.row-open-link {
  position:absolute;
  inline-size:1px;
  block-size:1px;
  overflow:hidden;
  clip-path:inset(50%);
  white-space:nowrap;
}
.row-open-link:focus-visible {
  position:static;
  inline-size:auto;
  block-size:auto;
  overflow:visible;
  clip-path:none;
  margin-inline-start:8px;
}
@media (max-width:650px), (pointer:coarse) {
  .row-open-link {
    position:static;
    display:inline-flex;
    align-items:center;
    min-height:24px;
    inline-size:auto;
    block-size:auto;
    overflow:visible;
    clip-path:none;
    margin-inline-start:8px;
  }
}
@media(max-width:650px) {
  .server-list-toolbar,.server-list-pager { padding-inline:12px; }
}

/* Shared accents for statuses, links and keyboard focus. */
:root {
  --tone-teal:#116e64;
  --tone-teal-soft:#e3f4ee;
  --tone-violet:#5e469c;
  --tone-violet-soft:#eee8fa;
  --tone-amber:#82500a;
  --tone-amber-soft:#fbefd9;
  --tone-rose:#a03850;
  --tone-rose-soft:#fbe8ed;
  --focus-ring:#6c59b0;
  --list-selected:#eee8fa;
}
:root[data-theme=dark] {
  --tone-teal:#89e0c9;
  --tone-teal-soft:#233e3a;
  --tone-violet:#cfbdf6;
  --tone-violet-soft:#39304d;
  --tone-amber:#efca8b;
  --tone-amber-soft:#493b29;
  --tone-rose:#ffb5c5;
  --tone-rose-soft:#482d38;
  --focus-ring:#c8aefa;
  --list-selected:#3d3454;
}
:focus-visible:is(button,a,input,select,textarea,summary) { outline-color:var(--focus-ring); }
.sidebar :is(.nav-link.active,.nav-link.group-active) { box-shadow:inset 3px 0 #8ee7d1; }
.data-table tbody tr.selected-row>:first-child { box-shadow:inset 3px 0 var(--tone-violet)!important; }
.status-badge.positive,[data-theme=dark] .status-badge.positive { background:var(--tone-teal-soft); color:var(--tone-teal); }
.status-badge.waiting,[data-theme=dark] .status-badge.waiting { background:var(--tone-amber-soft); color:var(--tone-amber); }
.status-badge.negative,[data-theme=dark] .status-badge.negative { background:var(--tone-rose-soft); color:var(--tone-rose); }

[data-tone=teal] { --card-ink:var(--tone-teal); --card-tint:var(--tone-teal-soft); }
[data-tone=violet] { --card-ink:var(--tone-violet); --card-tint:var(--tone-violet-soft); }
[data-tone=amber] { --card-ink:var(--tone-amber); --card-tint:var(--tone-amber-soft); }
[data-tone=rose] { --card-ink:var(--tone-rose); --card-tint:var(--tone-rose-soft); }
.dashboard-stat {
  gap:3px;
  border-radius:10px;
  border-top:3px solid var(--card-ink,var(--border));
  background:linear-gradient(145deg,var(--card-tint,var(--surface-subtle)),var(--surface) 70%);
}
.home-kpis>.dashboard-stat { border-top:0; }
.dashboard-stat>span { font-weight:600; }
.dashboard-stat>strong { color:var(--card-ink,var(--text)); font-variant-numeric:tabular-nums; }
a.dashboard-stat:hover { border-color:var(--card-ink,var(--accent)); }
.home-link { border-radius:8px; }
.home-link:hover { border-color:var(--card-ink,var(--accent)); }
.home-link>.icon:first-child {
  width:40px;
  height:40px;
  padding:9px;
  border-radius:11px;
  background:var(--card-tint,var(--surface-subtle));
  color:var(--card-ink,var(--accent));
}
.home-link>.icon:last-child { color:var(--readable-muted); }

/* Use the same insets and separation in list, form and record views. */
.main-content > :is(.panel,.summary-grid,.dashboard-grid) {
  margin-block-end:0;
  scroll-margin-top:calc(var(--topbar) + var(--panel-gap));
}
.main-content > :is(.panel,.summary-grid,.dashboard-grid) ~ :is(.panel,.summary-grid,.dashboard-grid) {
  margin-block-start:var(--panel-gap);
}
.main-content > :is(.panel,.summary-grid,.dashboard-grid) + :is(.notice,.form-error):not([hidden]) {
  margin-block-start:var(--panel-gap);
}
.panel-heading h2 { font-size:16px; line-height:1.35; }
.panel-heading :is(h1,h2) { min-width:0; overflow-wrap:anywhere; }
.panel-heading .panel-heading-actions,.panel-heading .button-group { gap:8px; }
.panel-heading .button-group,.button-group {
  display:flex;
  align-items:center;
  flex-wrap:wrap;
  gap:8px;
  min-width:0;
}
.panel-heading .panel-title > span:not(.badge,.status-badge) { color:var(--readable-muted); }
.panel > :is(.form-error,.notice,.form-success,.validation-summary-errors) { margin:12px var(--panel-padding); }
.panel-heading + .panel-note { border-bottom:1px solid var(--border); }
.table-scroll + .panel-note,.dt-container + .panel-note { border-top:1px solid var(--border); }
:is(.panel-body,.operation-form) > :is(p,ul,dl):last-child { margin-block-end:0; }
:is(.panel-body,.operation-form) > h2 + :is(p,ul,dl,form) { margin-block-start:8px; }
.panel-body + .panel-body { border-top:1px solid var(--border); }
.panel-body > :is(.editor-form,.operation-form) { padding:0; }
.operation-form > .panel-note,.panel-body > .panel-note { padding-inline:0; }
.record-summary { grid-template-columns:minmax(135px,210px) minmax(0,1fr); gap:10px 18px; }
.record-summary dt,.personnel-facts dt { color:var(--readable-muted); }
.record-summary dd { min-width:0; }
.main-content .data-table thead th { line-height:1.35; vertical-align:middle; }
.main-content .data-table td { line-height:1.4; }
.data-table .cell-secondary { margin-top:2px; }
.dashboard-grid,.summary-grid { gap:clamp(10px,1.3vw,16px); }
.dashboard-stat { min-width:0; padding:clamp(12px,1.5vw,20px); overflow-wrap:anywhere; }
.dashboard-stat > strong { line-height:1.18; }
.home-links { padding:var(--panel-padding); gap:12px; }

.settings-group { padding:var(--panel-padding); }
.settings-group + .settings-group { border-top:1px solid var(--border); }
.settings-group h2 { margin-block-end:12px; }
.settings-group .home-links { padding:0; }
.record-list { list-style:none; padding:0; margin:0; }
.record-list > li {
  display:flex;
  align-items:center;
  flex-wrap:wrap;
  gap:8px 12px;
  padding:8px 0;
}
.record-list > li + li { border-top:1px solid var(--border); }
.record-list > li > :first-child { margin-inline-end:auto; }
.inline-fields { display:flex; flex-wrap:wrap; align-items:flex-end; gap:10px 12px; }
.inline-fields > .field { flex:0 1 220px; }
.inline-fields select,.inline-fields input:not([type=hidden]) { width:100%; }
.panel-body .inline-fields + :is(p,form) { margin-block-start:12px; }
.panel-body details { margin-block-start:12px; }
.panel-body details > summary { cursor:pointer; }

.mobile-features-intro { max-width:75ch; color:var(--readable-muted); }
.mobile-features-intro p { margin:0 0 6px; }
.mobile-feature-group { margin-top:18px; }
.mobile-feature-group h2 { margin:0 0 8px; }
.mobile-feature-option {
  display:grid;
  grid-template-columns:minmax(0,1fr) auto;
  align-items:center;
  column-gap:12px;
  margin:0;
  padding:10px 0;
  border-bottom:1px solid var(--border);
}
.mobile-feature-option > label { display:block; }
.mobile-feature-option > small { grid-column:1; margin:0; }
.mobile-feature-option > .mobile-feature-switch { grid-row:1 / span 2; grid-column:2; }

@media(max-width:650px) {
  .panel-heading { align-items:flex-start; }
  .panel-heading .panel-heading-actions,.panel-heading .button-group { margin-inline-start:0; }
  .panel-heading > :is(h1,.panel-title) { flex-basis:100%; }
  .panel-heading .panel-filters { margin-inline-start:0; }
  .record-summary { grid-template-columns:minmax(0,1fr); gap:4px; }
  .record-summary dd { margin-bottom:8px; }
}
.team-row-actions { align-items:center; }
.team-row-actions .team-company-select {
  width:fit-content;
  max-width:240px;
  min-height:36px;
  padding:6px 9px;
  border:1px solid var(--border);
  border-radius:4px;
  background:var(--surface);
  color:var(--text);
}

.profile-context {
  display:flex;
  flex-wrap:wrap;
  align-items:center;
  justify-content:space-between;
  gap:6px 16px;
  margin:0 0 12px;
  padding:8px var(--panel-padding);
  border:1px solid var(--border);
  border-radius:6px;
  background:var(--surface);
  color:var(--readable-muted);
  overflow-wrap:anywhere;
}
.profile-context a { font-weight:650; }
.personnel-profile .profile-identity {
  display:flex;
  flex-wrap:nowrap;
  align-items:center;
  gap:13px;
  min-width:0;
}
.profile-avatar {
  display:grid;
  place-items:center;
  flex:none;
  width:56px;
  height:56px;
  border-radius:10px;
  background:var(--tone-violet-soft);
  color:var(--tone-violet);
  font-size:20px;
  font-weight:700;
  object-fit:cover;
}
.profile-name { display:flex; flex-wrap:wrap; align-items:center; gap:5px 10px; }
.profile-name h1 { margin:0; font-size:22px; }
.profile-identity p { margin:3px 0 0; color:var(--readable-muted); }
.profile-facts {
  display:grid;
  grid-template-columns:repeat(auto-fit,minmax(min(100%,155px),1fr));
  gap:12px 20px;
  margin:0;
  padding:var(--panel-padding);
}
.profile-facts dt { color:var(--readable-muted); font-size:12px; }
.profile-facts dd { margin:3px 0 0; font-weight:600; overflow-wrap:anywhere; }
.profile-overview {
  display:grid;
  grid-template-columns:repeat(auto-fit,minmax(min(100%,195px),1fr));
  gap:12px;
  margin:var(--panel-gap) 0 0;
}
.profile-overview>div {
  min-width:0;
  padding:11px 14px;
  border:1px solid var(--border);
  border-radius:7px;
  background:var(--card-tint,var(--surface));
}
.profile-overview dt { color:var(--card-ink,var(--text)); font-size:13px; font-weight:600; }
.profile-overview dd { margin:4px 0 0; font-size:17px; font-weight:700; }
.profile-overview small { display:block; margin-top:3px; color:var(--readable-muted); font-size:12px; font-weight:400; }
.profile-record-tabs {
  display:flex;
  gap:18px;
  overflow-x:auto;
  padding-inline:var(--panel-padding);
  border-bottom:1px solid var(--border);
}
.profile-record-tabs a {
  display:flex;
  align-items:center;
  min-height:44px;
  border-bottom:2px solid transparent;
  color:var(--readable-muted);
  font-weight:600;
  white-space:nowrap;
}
.profile-record-tabs a:is(:hover,[aria-current]) { color:var(--accent); text-decoration:none; }
.profile-record-tabs a[aria-current] { border-bottom-color:var(--accent); }
.profile-record-tabs a:focus-visible { outline-offset:-3px; }
.profile-record-body { padding:var(--panel-padding); }
.profile-leave-totals {
  display:flex;
  flex-wrap:wrap;
  gap:8px 22px;
  margin:0 0 12px;
  padding:10px 12px;
  border:1px solid var(--border);
  border-radius:7px;
}
.profile-leave-totals dt { color:var(--readable-muted); font-size:13px; }
.profile-leave-totals dd { margin:2px 0 0; font-weight:600; }
.profile-preview-lists {
  display:grid;
  grid-template-columns:repeat(auto-fit,minmax(min(100%,310px),1fr));
  gap:12px;
}
.profile-preview-list {
  min-width:0;
  border:1px solid var(--border);
  border-radius:7px;
}
.profile-preview-list h3 {
  margin:0;
  padding:9px 12px;
  border-bottom:1px solid var(--border);
  border-radius:6px 6px 0 0;
  background:var(--surface-subtle);
  font-size:14px;
}
.profile-preview-list ul,
.profile-full-links ul { list-style:none; margin:0; padding:0; }
.profile-preview-list li {
  display:flex;
  align-items:center;
  flex-wrap:wrap;
  justify-content:space-between;
  gap:8px 12px;
  padding:8px 12px;
}
.profile-preview-list li + li { border-top:1px solid var(--border); }
.profile-preview-copy { display:grid; gap:2px; min-width:0; overflow-wrap:anywhere; }
.profile-preview-copy span { color:var(--readable-muted); font-size:13px; }
.profile-preview-actions { display:flex; align-items:center; flex-wrap:wrap; gap:8px; }
.profile-preview-actions .button { min-height:34px; padding:5px 10px; }
.profile-empty { margin:0; padding:11px 12px; }
.profile-preview-lists + .profile-full-links { margin-top:16px; }
.profile-full-links h3 { margin:0 0 8px; font-size:14px; }
.profile-full-links ul { display:flex; flex-wrap:wrap; gap:7px; }
.profile-full-links .button { min-height:36px; padding:6px 10px; }
.profile-dialog .detail-grid dt { color:var(--readable-muted); font-size:12px; }
.profile-dialog .detail-grid dd { white-space:pre-wrap; overflow-wrap:anywhere; }
.profile-edit .notice:not(.validation-summary-valid) { margin:12px var(--panel-padding) 0; }
@media (max-width:650px) {
  .personnel-profile .profile-identity { flex-basis:100%; }
  .profile-record-tabs { gap:14px; }
}

/* DataTables list controls */
div.dt-container div.dt-layout-row.list-toolbar-row,
div.dt-container div.dt-layout-row.list-footer-row {
  display:flex;
  column-gap:16px;
}
div.dt-container div.dt-layout-row.list-toolbar-row {
  align-items:flex-end;
  flex-wrap:wrap;
}
@media (min-width:651px) {
  div.dt-container .list-toolbar-row .dt-layout-cell.dt-layout-start {
    flex:1 1 0;
    min-width:0;
  }
  .list-toolbar-row .list-actions { max-width:100%; align-items:flex-end; }
}
div.dt-container .list-toolbar-row .dt-layout-cell.dt-layout-end,
div.dt-container .list-footer-row .dt-layout-cell.dt-layout-end {
  display:flex;
  flex-wrap:wrap;
  align-items:flex-end;
  justify-content:flex-end;
  gap:8px 12px;
  margin-inline-start:auto;
}
div.dt-container .list-toolbar-row .dt-layout-cell > *,
div.dt-container .list-footer-row .dt-layout-cell > * { margin:0; }
.dt-container .server-list-toolbar { padding:0; justify-content:flex-end; }
.list-toolbar-row .list-filter-field {
  display:grid;
  gap:4px;
  text-align:start;
  min-width:0;
  margin:0;
}
.list-toolbar-row .list-filter-field label { margin:0; font-size:12px; font-weight:600; }
.list-toolbar-row .list-filter-field input { width:165px; max-width:100%; height:34px; }
.list-toolbar-row .filter-bar { margin:0; padding:0; border:0; }
.server-list-toolbar [data-list-search-submit][hidden] { display:none; }
.list-page-size, .dt-container .dt-search {
  display:grid;
  gap:4px;
  text-align:start;
}
.dt-container .dt-search input.dt-input { margin:0; background:var(--surface); color:var(--text); }
.server-list-toolbar label, .list-page-size > span, .dt-container .dt-search label {
  font-size:12px;
  font-weight:600;
}
.server-list-toolbar input[type="search"], .dt-container .dt-search input { height:34px; }
.list-size-buttons { display:inline-flex; gap:3px; }
.list-size-buttons button {
  box-sizing:border-box;
  height:34px;
  min-width:34px;
  padding:0 7px;
  border:1px solid var(--border);
  border-radius:4px;
  background:var(--surface);
  color:var(--text);
  font:inherit;
  font-size:12px;
  cursor:pointer;
}
.list-size-buttons button[aria-pressed="true"] {
  border-color:var(--accent);
  background:var(--accent-soft);
  color:var(--text);
  font-weight:700;
}
.dt-container table.dataTable.data-table tbody > tr > td { padding-block:12px; }
div.dt-container div.dt-layout-row.list-footer-row { align-items:center; flex-wrap:nowrap; }
div.dt-container .list-footer-row .dt-layout-cell.dt-layout-start,
.list-footer-row nav {
  display:flex;
  align-items:center;
  justify-content:flex-start;
  flex-wrap:wrap;
  gap:6px 12px;
  text-align:start;
}
.list-footer-row .dt-layout-cell { min-width:0; }
.list-footer-row .list-exports { justify-content:flex-end; }
.list-exports [role="status"]:empty { display:none; }
@media (max-width:650px) {
  div.dt-container div.list-toolbar-row > div.dt-layout-cell.dt-layout-end {
    display:flex;
    flex:1 1 100%;
    justify-content:flex-end;
    min-width:0;
    text-align:start;
  }
  .list-toolbar-row .dt-search { flex:0 1 145px; min-width:0; }
  .list-toolbar-row .dt-search input { box-sizing:border-box; width:100%; }
  .list-toolbar-row .server-list-toolbar { width:100%; text-align:start; }
}

.personnel-card {
  display:grid;
  grid-template-columns:minmax(0,1fr);
  gap:var(--panel-gap);
}
.personnel-card > * { min-width:0; margin-block:0; }
.personnel-card .profile-back {
  justify-self:start;
  gap:5px;
  min-height:32px;
  padding:0 4px 0 0;
  border:0;
  background:transparent;
  color:var(--readable-muted);
}
.profile-back .icon { width:15px; transform:rotate(180deg); }
.personnel-card .profile-header {
  display:flex;
  align-items:center;
  justify-content:space-between;
  flex-wrap:wrap;
  gap:16px;
  padding:22px var(--panel-padding);
  border-bottom:1px solid var(--border);
  background:linear-gradient(115deg,var(--tone-teal-soft),var(--surface) 65%);
}
.personnel-card .profile-avatar { width:60px; height:60px; border-radius:50%; background:var(--tone-teal); color:var(--surface); }
.personnel-card .profile-name h1 { font-size:clamp(22px,2.3vw,30px); line-height:1.18; overflow-wrap:anywhere; }
.personnel-card .profile-identity p:empty { display:none; }
.profile-actions { display:flex; flex-wrap:wrap; align-items:center; gap:8px; }
.personnel-card .profile-overview { margin:0; }
.personnel-card .profile-overview > div {
  display:grid;
  align-content:start;
  padding:15px var(--panel-padding);
  border-top:3px solid var(--card-ink);
  background:var(--surface);
}
.personnel-card .profile-overview dt { display:flex; align-items:center; gap:8px; }
.personnel-card .profile-overview dt .icon { width:17px; height:17px; }
.personnel-card .profile-overview dd { margin-top:8px; font-size:clamp(18px,1.5vw,23px); font-variant-numeric:tabular-nums; }
.profile-record-layout:has(.profile-record-tabs) { display:grid; grid-template-columns:minmax(165px,205px) minmax(0,1fr); }
.profile-record-layout .profile-record-tabs {
  align-content:start;
  display:grid;
  gap:3px;
  padding:12px;
  background:var(--surface-subtle);
  border:0;
  border-inline-end:1px solid var(--border);
}
.profile-record-layout .profile-record-tabs a {
  min-height:40px;
  gap:9px;
  padding:6px 10px;
  border:1px solid transparent;
  border-radius:6px;
  white-space:normal;
}
.profile-record-layout .profile-record-tabs a[aria-current] { background:var(--accent-soft); border-color:var(--accent); }
.profile-record-layout .profile-record-tabs a:hover { background:var(--surface); }
.profile-record-layout .profile-record-tabs .icon { width:16px; height:16px; flex:none; }
.personnel-card .profile-full-links ul { display:grid; grid-template-columns:repeat(auto-fit,minmax(min(100%,175px),1fr)); }
.personnel-card .profile-full-links .button { display:flex; height:100%; justify-content:space-between; text-align:start; }
.personnel-card .profile-full-links .icon { width:13px; flex:none; }
.personnel-card .profile-full-links h4 { margin:14px 0 6px; }
.personnel-card .profile-onboarding summary {
  display:flex; align-items:center; justify-content:space-between; gap:12px;
  cursor:pointer; list-style:none; padding:14px var(--panel-padding);
}
.personnel-card summary::-webkit-details-marker { display:none; }
.personnel-card summary h2 { margin:0; font-size:16px; }
.personnel-card summary .icon { width:16px; }
.personnel-card details[open] > summary .icon { transform:rotate(90deg); }
.personnel-card .profile-onboarding[open] > summary { border-bottom:1px solid var(--border); }
.personnel-card .profile-onboarding dd a { display:block; margin-top:6px; }
.personnel-card :is(#profile-edit,#profile-records) { scroll-margin-top:calc(var(--topbar) + var(--panel-gap)); }
@media (max-width:760px) {
  .profile-record-layout:has(.profile-record-tabs) { grid-template-columns:minmax(0,1fr); }
  .profile-record-layout .profile-record-tabs { display:flex; flex-wrap:wrap; gap:4px; padding:8px; border:0; border-bottom:1px solid var(--border); }
  .profile-record-layout .profile-record-tabs a { min-height:38px; }
  .profile-actions { width:100%; }
}

@media (min-width: 651px) {
    .menu-collapsed .nav-group > summary[data-group-label]:is(:hover,:focus-visible)::after {
        content: attr(data-group-label);
        position: fixed;
        inset-inline-start: 60px;
        z-index: 20;
        background: var(--surface);
        color: var(--text);
        border: 1px solid var(--border);
        border-radius: 4px;
        padding: 5px 9px;
        white-space: nowrap;
    }
}

.weekly-empty { padding: 28px var(--panel-padding); text-align: center; color: var(--readable-muted); }
.month-date { display: inline-block; line-height: 1.2; }
.month-date small { display: block; }
.month-date.clipped-date { opacity: 0; }
.monthly-table .week-start { border-inline-start: 2px solid var(--border); }
@media (min-width: 1000px) {
    .home-kpis:has(> :nth-child(4):last-child) { grid-template-columns: repeat(4, minmax(0, 1fr)); }
    .home-links:has(> :nth-child(3):last-child) { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    #roster-selection .list-actions { padding: 8px var(--panel-padding); gap: 6px 12px; align-items: center; }
    #roster-selection label { display: inline-flex; align-items: center; gap: 4px; }
    #roster-selection :is(input[type=number], select) { min-height: 34px; padding: 3px 6px; border: 1px solid var(--border); border-radius: 4px; background: var(--surface); color: var(--text); }
    #roster-range-people { width: 52px; }
    .roster-grid td { min-width: 104px; }
    .roster-grid td:first-child { min-width: 154px; }
    .roster-grid .roster-cell { gap: 5px; padding: 0; min-height: 44px; }
    .roster-grid .roster-cell span { white-space: normal; }
}
@media (min-width: 1000px) and (max-width: 1350px) {
    .profile-facts { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

.document-preview {
  width:min(1060px, 92vw);
  max-height:92vh;
  padding:0;
  color:var(--text);
  background:var(--surface);
  border:1px solid var(--border);
  border-radius:8px;
}
.document-preview::backdrop { background:#08121ac9; }
.document-preview .panel-heading { align-items:center; justify-content:space-between; }
.document-preview-content { padding:16px; max-height:70vh; overflow:auto; text-align:center; }
.document-preview-content :is(canvas,img) { display:block; margin-inline:auto; max-width:100%; height:auto; background:#fff; }
.document-preview [hidden] { display:none; }
.document-preview-pages { padding:0 16px 16px; align-items:center; justify-content:center; }
.document-preview [data-document-status]:empty { display:none; }

.profile-workspace {
  display:grid;
  grid-template-columns:minmax(215px, 260px) minmax(0, 1fr);
  gap:var(--panel-gap);
  align-items:start;
}
.profile-sidebar {
  display:grid;
  gap:var(--panel-gap);
  position:sticky;
  top:calc(var(--topbar) + var(--panel-gap));
  max-height:calc(100dvh - var(--topbar) - 2 * var(--panel-gap));
  overflow:auto;
}
.profile-sidebar .profile-header { align-items:stretch; flex-direction:column; padding:16px; }
.profile-sidebar .profile-identity { align-items:flex-start; flex-direction:column; gap:10px; }
.profile-key-facts { display:grid; gap:5px; margin:10px 0 0; font-size:13px; }
.profile-key-facts div { display:flex; flex-wrap:wrap; gap:2px 7px; }
.profile-key-facts dt { color:var(--readable-muted); }
.profile-key-facts dd { margin:0; font-weight:600; overflow-wrap:anywhere; }
.profile-sidebar .profile-actions { display:grid; }
.profile-sidebar .profile-record-tabs { display:grid; gap:4px; padding:8px; border:1px solid var(--border); border-radius:8px; background:var(--surface); }
.profile-sidebar .profile-record-tabs a { min-height:38px; gap:8px; padding:6px 9px; border:1px solid transparent; border-radius:5px; white-space:normal; }
.profile-sidebar .profile-record-tabs a[aria-current] { background:var(--accent-soft); border-color:var(--accent); }
.profile-main-content { display:grid; min-width:0; gap:var(--panel-gap); }
.profile-edit [data-within-limit][hidden] { display:none; }
@media (max-width: 850px) {
  .profile-workspace { grid-template-columns:minmax(0, 1fr); }
  .profile-sidebar { position:static; max-height:none; overflow:visible; }
  .profile-sidebar .profile-header { flex-direction:row; }
  .profile-sidebar .profile-identity { flex-direction:row; }
  .profile-sidebar .profile-actions { display:flex; }
  .profile-sidebar .profile-record-tabs { display:flex; flex-wrap:wrap; }
}
.badge.open { background: var(--accent-soft); color: var(--accent); }

.list-table-viewport {
  max-height:var(--list-table-height, 60vh);
  overflow:auto;
  border-bottom:1px solid var(--border);
}
.list-table-viewport:focus-visible {
  outline:2px solid var(--accent);
  outline-offset:-2px;
}
.dt-container .list-table-viewport table.dataTable {
  border-collapse:separate;
  border-spacing:0;
}
.list-table-viewport .data-table thead th {
  position:sticky;
  top:0;
  z-index:3;
  background:var(--surface-subtle);
}
.list-scroll-controls {
  display:flex;
  align-items:center;
  justify-content:flex-end;
  gap:8px;
  padding:4px var(--panel-padding);
  color:var(--readable-muted);
  background:var(--surface-subtle);
}
.list-scroll-controls[hidden] { display:none; }
.list-scroll-controls .button { min-width:36px; min-height:30px; padding:3px 8px; }
.list-scroll-controls [aria-disabled=true] { opacity:.55; cursor:default; }
@media (min-width:651px) {
  .list-table-viewport .pay-sicil,.list-table-viewport .pay-person {
    position:sticky;
    z-index:2;
    background:var(--surface);
  }
  .list-table-viewport .pay-sicil { left:0; }
  .list-table-viewport .pay-person { left:var(--pay-sicil-width, 0px); border-right:1px solid var(--border); }
  .list-table-viewport .data-table thead :is(.pay-sicil,.pay-person) { z-index:4; }
}
.list-table-viewport .data-table thead :is(.monthly-person,.roster-person) { z-index:4; }

:is(.hire-form,.employee-fields) .field:has(
  > :is(input,select)[required]:not([disabled]),
  > .date-picker > input[required]:not([disabled])
) > label:first-child::after {
  content:" *" / "";
  color:var(--readable-muted);
}
.required-field-note { color:var(--readable-muted); font-size:12px; }
[data-custom-week-field][hidden] { display:none; }
