/* 2.2: SHABAB Arabic font = Noto Kufi Arabic (only for Arabic letters; Latin keeps Segoe UI) */
@font-face {
  font-family: "Noto Kufi Arabic";
  src: url("/w/fonts/NotoKufiArabic-Regular.woff2") format("woff2");
  font-weight: 100 500;
  font-display: swap;
  unicode-range: U+0600-06FF, U+0750-077F, U+08A0-08FF, U+FB50-FDFF, U+FE70-FEFF, U+200C-200F;
}
@font-face {
  font-family: "Noto Kufi Arabic";
  src: url("/w/fonts/NotoKufiArabic-Bold.woff2") format("woff2");
  font-weight: 600 900;
  font-display: swap;
  unicode-range: U+0600-06FF, U+0750-077F, U+08A0-08FF, U+FB50-FDFF, U+FE70-FEFF, U+200C-200F;
}
/* SHABAB TIME ATTENDANCE — shared look. Themes = CSS variables (same idea as SHABAB POS themes). */
:root,
[data-theme="shabab"] {
  --bg: #eef3fb;
  --bg2: #e3ebf8;
  --card: #ffffff;
  --text: #0b1630;
  --muted: #5b6880;
  --line: #dfe6f2;
  --primary: #1a5be6;
  --primary2: #4ea8ff;
  --primaryText: #ffffff;
  --accent: #d4af37;
  --silver: #c9d3e3;
  --side: #041a4d;
  --side2: #06276f;
  --sideText: #dce7ff;
  --sideMute: #8fa6d6;
  --hero1: #1a5be6;
  --hero2: #06276f; /* 2.1.5 SHABAB brand: blue #1A5BE6 · navy #06276F · gold hairline */
  --ok: #16a34a;
  --okBg: #e7f7ec;
  --warn: #d97706;
  --warnBg: #fef3e2;
  --bad: #dc2626;
  --badBg: #fdecec;
  --info: #0ea5e9;
  --infoBg: #e3f4fc;
  --shadow: 0 1px 2px rgba(11, 22, 48, 0.05), 0 8px 24px rgba(11, 22, 48, 0.07);
  --radius: 18px;
}
[data-theme="babil"] {
  --bg: #edf5ef;
  --bg2: #e0eee4;
  --primary: #0b7a3e;
  --primary2: #3dbe6e;
  --accent: #7ed957;
  --side: #06381d;
  --side2: #0a4a27;
  --sideText: #ddf3e4;
  --sideMute: #8cc4a2;
  --hero1: #11934d;
  --hero2: #06381d;
  --silver: #c6dccd;
  --line: #d6e6db;
}
[data-theme="midnight"] {
  --bg: #0a1020;
  --bg2: #0f172a;
  --card: #121b30;
  --text: #e6edfa;
  --muted: #93a3bf;
  --line: #22304d;
  --primary: #4e7cff;
  --primary2: #7fb3ff;
  --accent: #e2be52;
  --side: #060b17;
  --side2: #0e1629;
  --sideText: #d8e2f7;
  --sideMute: #7e8daa;
  --hero1: #1e3a8a;
  --hero2: #060b17;
  --okBg: #0f2d1c;
  --warnBg: #33240c;
  --badBg: #3a1414;
  --infoBg: #0c2a3a;
  --silver: #33415e;
  --shadow: 0 1px 2px rgba(0, 0, 0, 0.3), 0 10px 30px rgba(0, 0, 0, 0.35);
}
/* 2.4.1 LAVENDER NIGHT (same family as SHABAB AZAN Lavender Night): deep night violet / indigo, lavender accents, a soft pink + teal glow,
   white text. Buttons = lavender with dark ink (WCAG AA both ways: lavender on the dark cards and dark ink on lavender). */
[data-theme="lavender"] {
  --bg: #14112a;
  --bg2: #1c1838;
  --card: #221d42;
  --text: #f5f2ff;
  --muted: #c2b9e6;
  --line: #3a3366;
  --primary: #b9a2ff;
  --primary2: #d7c8ff;
  --primaryText: #160f33;
  --accent: #ff8fb8;
  --silver: #3d3670;
  --side: #0f0c22;
  --side2: #1d1840;
  --sideText: #efe9ff;
  --sideMute: #b3a9dc;
  --hero1: #3b2a7a;
  --hero2: #120e28;
  --ok: #6ee7a8;
  --okBg: #12352a;
  --warn: #ffc26b;
  --warnBg: #3a2a12;
  --bad: #ff8fa3;
  --badBg: #401a2a;
  --info: #8fd8ff;
  --infoBg: #15304d;
  --shadow: 0 1px 2px rgba(5, 4, 20, 0.4), 0 10px 30px rgba(8, 5, 30, 0.55), 0 0 0 1px rgba(201, 167, 245, 0.07);
  color-scheme: dark;
}
[data-theme="lavender"] body {
  background:
    radial-gradient(ellipse 60vw 50vh at 100% -10%, rgba(232, 64, 127, 0.1), transparent 70%),
    radial-gradient(ellipse 55vw 45vh at -10% 110%, rgba(43, 179, 168, 0.08), transparent 70%),
    var(--bg);
  background-attachment: fixed;
}
[data-theme="lavender"] .card {
  box-shadow: var(--shadow), 0 0 26px rgba(185, 162, 255, 0.06);
}
/* 2.4.1 NEXUS NAVY GOLD (same look as SHABAB NEXUS): deep navy + gold accents, ivory text. Buttons = gold with navy ink. */
[data-theme="nexus"] {
  --bg: #06122b;
  --bg2: #0a1d44;
  --card: #0f1c38;
  --text: #eef2fb;
  --muted: #a7b6d3;
  --line: #22345c;
  --primary: #d9ae4e;
  --primary2: #e8c56b;
  --primaryText: #1c1300;
  --accent: #d9ae4e;
  --silver: #284a63;
  --side: #040d22;
  --side2: #06122b;
  --sideText: #e3e8ee;
  --sideMute: #aab8c5;
  --hero1: #0b2a6f;
  --hero2: #071a45;
  --ok: #34d399;
  --okBg: #0f2e1c;
  --warn: #fbbf24;
  --warnBg: #3a2a10;
  --bad: #f87171;
  --badBg: #3b171a;
  --info: #7cc4f5;
  --infoBg: #0f2c44;
  --shadow: 0 1px 2px rgba(0, 0, 0, 0.45), 0 10px 28px rgba(0, 0, 0, 0.4);
  color-scheme: dark;
}
[data-theme="nexus"] .card {
  border-top: 1px solid rgba(217, 174, 78, 0.18);
}
/* 2.4.1: the open menu item is gold (NEXUS) / lavender (Lavender Night) -> dark ink on it, not white (white on gold was 3.3:1, below WCAG AA) */
[data-theme="nexus"] .side a.on,
[data-theme="lavender"] .side a.on {
  color: var(--primaryText);
}
/* 2.4.1 NEXUS LIGHT (same family as NEXUS Night): ivory background, white cards, navy buttons + side menu, gold hairlines. */
[data-theme="nexuslight"] {
  --bg: #f4f1ea;
  --bg2: #ece6d8;
  --card: #ffffff;
  --text: #0b1f4a;
  --muted: #5a6785;
  --line: #e3dccb;
  --primary: #0b1f4a;
  --primary2: #16306b;
  --primaryText: #ffffff;
  --accent: #8a6a1f;
  --silver: #cfc7b6;
  --side: #0b1f4a;
  --side2: #071637;
  --sideText: #e3e8ee;
  --sideMute: #aab8c5;
  --hero1: #0b2a6f;
  --hero2: #0a1d44;
  --ok: #047857;
  --okBg: #e6f3ea;
  --warn: #a14a07;
  --warnBg: #fff3df;
  --bad: #c81e1e;
  --badBg: #fbecea;
  --info: #0b5f8a;
  --infoBg: #e3f1fa;
  --shadow: 0 1px 2px rgba(11, 38, 58, 0.05), 0 8px 24px rgba(11, 38, 58, 0.07);
}
[data-theme="nexuslight"] .card {
  border-top: 2px solid rgba(180, 138, 44, 0.35);
}
[data-theme="royal"] {
  --bg: #f3f0fb;
  --bg2: #e9e3f7;
  --primary: #6d28d9;
  --primary2: #a78bfa;
  --accent: #f59e0b;
  --side: #1e0b47;
  --side2: #2b1263;
  --sideText: #ede7ff;
  --sideMute: #a898d6;
  --hero1: #7c3aed;
  --hero2: #1e0b47;
  --line: #e3dcf3;
}
[data-theme="ocean"] {
  --bg: #eaf6f7;
  --bg2: #ddeff1;
  --primary: #0e7490;
  --primary2: #22d3ee;
  --accent: #f2b33d;
  --side: #062a33;
  --side2: #0a3a46;
  --sideText: #ddf5f9;
  --sideMute: #86bfcb;
  --hero1: #0891b2;
  --hero2: #062a33;
  --line: #d3e8eb;
}
[data-theme="sunset"] {
  --bg: #fbf2ec;
  --bg2: #f5e5da;
  --primary: #c2410c;
  --primary2: #fb923c;
  --accent: #1e4fd8;
  --side: #2a1006;
  --side2: #3d170a;
  --sideText: #fce9dd;
  --sideMute: #cfa08a;
  --hero1: #ea580c;
  --hero2: #2a1006;
  --line: #f0ddd0;
}
[data-theme="classic"] {
  --bg: #f5f7fa;
  --bg2: #ebeff5;
  --primary: #1e4fd8;
  --primary2: #4ea8ff;
  --accent: #d4af37;
  --side: #ffffff;
  --side2: #f1f5fb;
  --sideText: #1b2a4a;
  --sideMute: #6b7a96;
  --hero1: #1e4fd8;
  --hero2: #0b2a7a;
  --line: #e2e8f0;
}

* {
  box-sizing: border-box;
  -webkit-tap-highlight-color: transparent;
}
html,
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family:
    "Noto Kufi Arabic",
    "Segoe UI",
    -apple-system,
    BlinkMacSystemFont,
    Roboto,
    "Noto Sans",
    "Noto Sans Arabic",
    "Noto Sans Malayalam",
    system-ui,
    sans-serif;
  font-size: 15px;
  line-height: 1.45;
}
[dir="rtl"] body {
  font-family: "Noto Kufi Arabic", "Segoe UI", Tahoma, "Noto Sans Arabic", system-ui, sans-serif;
}
a {
  color: var(--primary);
}
button,
input,
select,
textarea {
  font: inherit;
  color: inherit;
}
.hidden {
  display: none !important;
}
.muted {
  color: var(--muted);
}
.small {
  font-size: 12.5px;
}
.tiny {
  font-size: 11px;
}
.b {
  font-weight: 700;
}
.bb {
  font-weight: 800;
}
.row {
  display: flex;
  gap: 10px;
  align-items: center;
}
.col {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.grow {
  flex: 1;
  min-width: 0;
}
.wrap {
  flex-wrap: wrap;
}
.card {
  background: var(--card);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 18px;
  border: 1px solid color-mix(in srgb, var(--line) 60%, transparent);
}
.card h3 {
  margin: 0 0 12px;
  font-size: 15.5px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.btn {
  border: 0;
  border-radius: 12px;
  padding: 10px 16px;
  font-weight: 700;
  cursor: pointer;
  background: var(--primary);
  color: var(--primaryText);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  transition:
    transform 0.08s,
    filter 0.15s;
  white-space: nowrap;
}
.btn:hover {
  filter: brightness(1.07);
}
.btn:active {
  transform: scale(0.98);
}
.btn[disabled] {
  opacity: 0.5;
  pointer-events: none;
}
.btn.ghost {
  background: transparent;
  color: var(--primary);
  box-shadow: inset 0 0 0 1.5px color-mix(in srgb, var(--primary) 45%, transparent);
}
.btn.soft {
  background: color-mix(in srgb, var(--primary) 12%, var(--card));
  color: var(--primary);
}
.btn.ok {
  background: var(--ok);
  color: #fff;
}
.btn.bad {
  background: var(--bad);
  color: #fff;
}
.btn.gold {
  background: var(--accent);
  color: #1a1406;
}
.btn svg {
  width: 17px;
  height: 17px;
  flex: none;
}
.btn.sm {
  padding: 6px 11px;
  font-size: 13px;
  border-radius: 10px;
}
.btn.lg {
  padding: 14px 22px;
  font-size: 16.5px;
  border-radius: 16px;
}
.input,
select.input,
textarea.input {
  width: 100%;
  padding: 11px 13px;
  border-radius: 12px;
  border: 1.5px solid var(--line);
  background: var(--card);
  outline: none;
  transition:
    border 0.15s,
    box-shadow 0.15s;
}
.input:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--primary) 15%, transparent);
}
label.f {
  display: block;
  font-size: 12.5px;
  font-weight: 700;
  color: var(--muted);
  margin: 0 0 5px;
}
.field {
  margin-bottom: 12px;
}
.pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 10px;
  border-radius: 99px;
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
}
/* 2.3.1: position pill (staff list) in the position colour; on the dark theme the text is lighter (a dark-grey position was not readable) */
.pill.pospill {
  background: color-mix(in srgb, var(--pc) 14%, transparent);
  color: var(--pc);
}
[data-theme="midnight"] .pill.pospill,
[data-theme="lavender"] .pill.pospill,
[data-theme="nexus"] .pill.pospill {
  background: color-mix(in srgb, var(--pc) 30%, transparent);
  color: color-mix(in srgb, var(--pc) 45%, #ffffff);
}
.s-WORKING {
  background: var(--infoBg);
  color: var(--info);
}
.s-PRESENT {
  background: var(--okBg);
  color: var(--ok);
}
.s-HALF,
.s-SHORT {
  background: var(--warnBg);
  color: var(--warn);
}
.s-ABSENT {
  background: var(--badBg);
  color: var(--bad);
}
.s-LEAVE {
  background: #ede9fe;
  color: #6d28d9;
}
.s-OFF,
.s-HOLIDAY {
  background: var(--bg2);
  color: var(--muted);
}
.s-NOT_YET,
.s-FUTURE {
  background: var(--bg2);
  color: var(--muted);
}
[data-theme="midnight"] .s-LEAVE,
[data-theme="lavender"] .s-LEAVE,
[data-theme="nexus"] .s-LEAVE {
  background: #2a1e4a;
  color: #c4b5fd;
}
.flag {
  background: var(--badBg);
  color: var(--bad);
}
.chip {
  background: var(--bg2);
  color: var(--muted);
}
.dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  display: inline-block;
  flex: none;
}
.avatar {
  width: 38px;
  height: 38px;
  border-radius: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  color: #fff;
  flex: none;
  font-size: 14px;
  background: linear-gradient(135deg, var(--primary), var(--primary2));
  overflow: hidden;
}
.avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.toast {
  position: fixed;
  left: 50%;
  bottom: 26px;
  transform: translateX(-50%);
  background: #0b1630;
  color: #fff;
  padding: 12px 18px;
  border-radius: 14px;
  font-weight: 600;
  z-index: 9999;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25);
  max-width: 92vw;
  animation: up 0.25s ease;
}
.toast.bad {
  background: var(--bad);
}
.toast.ok {
  background: var(--ok);
}
@keyframes up {
  from {
    transform: translate(-50%, 20px);
    opacity: 0;
  }
  to {
    transform: translate(-50%, 0);
    opacity: 1;
  }
}
@keyframes pop {
  0% {
    transform: scale(0.6);
    opacity: 0;
  }
  70% {
    transform: scale(1.06);
  }
  100% {
    transform: scale(1);
    opacity: 1;
  }
}
@keyframes pulse {
  0% {
    box-shadow: 0 0 0 0 color-mix(in srgb, var(--ring) 55%, transparent);
  }
  100% {
    box-shadow: 0 0 0 26px transparent;
  }
}
@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}
.spinner {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  border: 3px solid color-mix(in srgb, var(--primary) 25%, transparent);
  border-top-color: var(--primary);
  animation: spin 0.8s linear infinite;
  display: inline-block;
}
.modal-back {
  position: fixed;
  inset: 0;
  background: rgba(6, 12, 30, 0.55);
  backdrop-filter: blur(3px);
  z-index: 900;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  animation: fade 0.2s;
}
@keyframes fade {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}
.modal {
  background: var(--card);
  border-radius: 22px;
  width: 560px;
  max-width: 100%;
  max-height: 92vh;
  overflow: auto;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.35);
  animation: pop 0.22s ease;
}
.modal .mh {
  padding: 18px 20px 8px;
  display: flex;
  align-items: center;
  gap: 10px;
}
.modal .mh h3 {
  margin: 0;
  flex: 1;
  font-size: 18px;
}
.modal .mb {
  padding: 8px 20px 18px;
}
.modal .mf {
  padding: 12px 20px 18px;
  display: flex;
  gap: 10px;
  justify-content: flex-end;
  border-top: 1px solid var(--line);
}
.x {
  border: 0;
  background: var(--bg2);
  width: 34px;
  height: 34px;
  border-radius: 10px;
  cursor: pointer;
  font-size: 18px;
  color: var(--muted);
}
table.t {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
}
table.t th {
  text-align: start;
  font-size: 11.5px;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 800;
  padding: 9px 10px;
  border-bottom: 1px solid var(--line);
  background: var(--card);
  position: sticky;
  top: 0;
  z-index: 1;
}
table.t td {
  padding: 10px;
  border-bottom: 1px solid var(--line);
  vertical-align: middle;
}
table.t tr.click {
  cursor: pointer;
}
table.t tr.click:hover td {
  background: color-mix(in srgb, var(--primary) 5%, var(--card));
}
.empty {
  text-align: center;
  padding: 30px 10px;
  color: var(--muted);
}
.seg {
  display: inline-flex;
  flex-wrap: wrap; /* 2.4.0: 6 phone languages fit on a small phone */
  background: var(--bg2);
  border-radius: 12px;
  padding: 3px;
  gap: 2px;
}
.seg button {
  border: 0;
  background: transparent;
  padding: 7px 12px;
  border-radius: 9px;
  font-weight: 700;
  color: var(--muted);
  cursor: pointer;
  font-size: 13px;
}
.seg button.on {
  background: var(--card);
  color: var(--primary);
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.08);
}
.switch {
  position: relative;
  width: 46px;
  height: 26px;
  flex: none;
}
.switch input {
  opacity: 0;
  width: 0;
  height: 0;
}
.switch span {
  position: absolute;
  inset: 0;
  background: var(--silver);
  border-radius: 99px;
  transition: 0.2s;
  cursor: pointer;
}
.switch span:before {
  content: "";
  position: absolute;
  width: 20px;
  height: 20px;
  left: 3px;
  top: 3px;
  background: #fff;
  border-radius: 50%;
  transition: 0.2s;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
}
.switch input:checked + span {
  background: var(--primary);
}
.switch input:checked + span:before {
  transform: translateX(20px);
}
.logo-sq {
  border-radius: 14px;
  object-fit: contain;
  background: #fff;
}

/* 1.3 chat */
.chat {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.chat-note:empty {
  display: none;
}
.chat-note {
  background: color-mix(in srgb, var(--warn) 14%, var(--card));
  color: var(--text);
  border: 1px solid color-mix(in srgb, var(--warn) 40%, transparent);
  border-radius: 12px;
  padding: 8px 12px;
  font-size: 13px;
}
.chat-list {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 12px;
  height: min(56vh, 520px);
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.bub {
  max-width: 82%;
  padding: 8px 12px 6px;
  border-radius: 16px;
  font-size: 14.5px;
  line-height: 1.35;
  overflow-wrap: anywhere;
  white-space: normal;
}
.bub.me {
  align-self: flex-end;
  background: var(--primary);
  color: #fff;
  border-bottom-right-radius: 5px;
}
.bub.them {
  align-self: flex-start;
  background: var(--bg);
  border: 1px solid var(--line);
  border-bottom-left-radius: 5px;
}
.bub .by {
  font-size: 11.5px;
  font-weight: 800;
  color: var(--primary);
  margin-bottom: 2px;
}
.bub .tm {
  font-size: 10.5px;
  opacity: 0.7;
  text-align: end;
  margin-top: 3px;
}
.bub .tm .seen {
  color: #9ef0c0;
  font-weight: 800;
}
.chat-bar {
  display: flex;
  gap: 8px;
  align-items: flex-end;
}
.chat-bar textarea {
  flex: 1;
  resize: none;
  min-height: 46px;
  max-height: 120px;
  font: inherit;
}
.chat-bar .btn {
  min-width: 52px;
  height: 46px;
  font-size: 18px;
}
.thread {
  display: flex;
  gap: 12px;
  align-items: center;
  padding: 10px 4px;
  border-bottom: 1px solid var(--line);
  cursor: pointer;
}
.thread:last-child {
  border-bottom: 0;
}
.thread .un {
  background: var(--bad);
  color: #fff;
  border-radius: 99px;
  font-size: 11px;
  font-weight: 800;
  padding: 1px 7px;
}
.thread .lm {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 60vw;
}
.dnd {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 700;
  font-size: 13px;
}
.dchat {
  display: grid;
  grid-template-columns: minmax(260px, 340px) minmax(0, 1fr);
  gap: 14px;
  align-items: stretch;
}
.dchat > * {
  min-width: 0;
}
.chat,
.chat-list {
  min-width: 0;
}
.dlist {
  padding: 12px;
  max-height: 72vh;
  overflow-y: auto;
}
.dlist .thread {
  border-radius: 12px;
  padding: 9px 8px;
  border-bottom: 0;
}
.dlist .thread.on {
  background: color-mix(in srgb, var(--primary) 12%, var(--card));
}
.dlist .thread:hover {
  background: var(--bg);
}
.dlist .lm {
  max-width: 100%;
}
.dconv {
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-height: 60vh;
  padding: 14px;
}
.dconv .chat-list {
  height: 52vh;
}
.dhead {
  display: flex;
  gap: 12px;
  align-items: center;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--line);
}
.quick {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.quick .chip {
  border: 1px solid var(--line);
  background: var(--bg);
  border-radius: 99px;
  padding: 5px 11px;
  font-size: 12.5px;
  cursor: pointer;
  font-weight: 600;
  color: var(--text);
}
@media (max-width: 860px) {
  .dchat {
    grid-template-columns: 1fr;
  }
}

/* 1.4 licence */
.lic {
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 18px;
  background: linear-gradient(150deg, var(--hero1, #061233), var(--hero2, #1e4fd8));
}
.lic-card {
  background: var(--card);
  color: var(--text);
  border-radius: 22px;
  padding: 26px 24px;
  width: 520px;
  max-width: 100%;
  text-align: center;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.35);
}
.lic-ic {
  width: 72px;
  height: 72px;
  border-radius: 18px;
}
.lic h1 {
  font-size: 15px;
  letter-spacing: 2px;
  margin: 10px 0 2px;
  color: var(--muted);
}
.lic h2 {
  font-size: 22px;
  margin: 4px 0 6px;
}
.lic-note {
  background: color-mix(in srgb, var(--warn) 14%, var(--card));
  border-radius: 12px;
  padding: 9px 12px;
  font-size: 13px;
  margin: 10px 0;
}
.lic-ids {
  display: grid;
  gap: 8px;
  margin: 14px 0;
}
.lic-ids > div {
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 9px 12px;
  text-align: start;
}
.lic-ids span {
  font-size: 12px;
  color: var(--muted);
  width: 100px;
  flex: none;
}
.lic-ids b {
  flex: 1;
  font-family: Consolas, monospace;
  font-size: 14.5px;
  word-break: break-all;
}
.lic-banner {
  background: color-mix(in srgb, var(--warn) 16%, var(--card));
  color: var(--text);
  border-bottom: 1px solid color-mix(in srgb, var(--warn) 40%, transparent);
  padding: 7px 14px;
  font-size: 13px;
  font-weight: 600;
  display: flex;
  gap: 10px;
  align-items: center;
}

/* 1.6 message pop-up */
.msgpop {
  position: fixed;
  right: 18px;
  bottom: 18px;
  width: 360px;
  max-width: calc(100vw - 24px);
  background: var(--card, #fff);
  color: var(--text, #0f172a);
  border-radius: 18px;
  box-shadow: 0 18px 50px rgba(2, 8, 30, 0.35);
  z-index: 9000;
  overflow: hidden;
  animation: mpin 0.22s ease-out;
  border: 1px solid color-mix(in srgb, var(--primary) 25%, transparent);
}
@keyframes mpin {
  from {
    transform: translateY(24px);
    opacity: 0;
  }
  to {
    transform: none;
    opacity: 1;
  }
}
.msgpop .mp-h {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 14px;
  background: var(--primary);
  color: #fff;
}
.msgpop .mp-i {
  font-size: 22px;
}
.msgpop .mp-k {
  font-size: 11.5px;
  opacity: 0.85;
  letter-spacing: 0.5px;
  text-transform: uppercase;
}
.msgpop .mp-f {
  font-size: 15.5px;
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.msgpop .x {
  background: rgba(255, 255, 255, 0.18);
  color: #fff;
  border: 0;
  width: 32px;
  height: 32px;
  border-radius: 10px;
  font-size: 20px;
  cursor: pointer;
}
.msgpop .mp-b {
  padding: 12px 14px 4px;
  max-height: 190px;
  overflow-y: auto;
}
.msgpop .mp-m {
  background: color-mix(in srgb, var(--primary) 9%, transparent);
  border-radius: 14px 14px 14px 4px;
  padding: 9px 12px;
  margin-bottom: 8px;
  font-size: 15px;
  line-height: 1.4;
  word-wrap: break-word;
}
.msgpop .mp-t {
  font-size: 11px;
  opacity: 0.6;
  margin-top: 3px;
  text-align: right;
}
.msgpop .mp-r {
  padding: 4px 14px 14px;
}
.msgpop textarea {
  width: 100%;
  resize: none;
  font-size: 15px;
}
.msgpop .mp-a {
  display: flex;
  gap: 8px;
  justify-content: space-between;
  margin-top: 8px;
}
@media (max-width: 600px) {
  .msgpop {
    left: 8px;
    right: 8px;
    bottom: 74px;
    width: auto;
  }
}

/* 1.7 map / satellite switch (like Google Maps) */
.mapmode {
  display: flex;
  background: #fff;
  border-radius: 10px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.25);
  overflow: hidden;
}
.mapmode button {
  border: 0;
  background: #fff;
  color: #0f172a;
  font:
    600 13px system-ui,
    sans-serif;
  padding: 7px 12px;
  cursor: pointer;
}
.mapmode button + button {
  border-left: 1px solid #e2e8f0;
}
.mapmode button.on {
  background: var(--primary);
  color: #fff;
}
/* 1.7 attendance map tools */
.maptools {
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.22);
  padding: 5px;
  width: 200px;
  max-width: calc(100vw - 90px);
  font:
    13px system-ui,
    sans-serif;
  color: #0f172a;
}
.maptools .mt-search {
  position: relative;
}
.maptools input {
  width: 100%;
  box-sizing: border-box;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  padding: 5px 8px;
  font-size: 12.5px;
}
.maptools .mt-res {
  position: absolute;
  left: 0;
  right: -60px;
  top: 30px;
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 8px 22px rgba(0, 0, 0, 0.2);
  z-index: 1000;
  max-height: 240px;
  overflow-y: auto;
}
.maptools .mt-res div {
  padding: 8px 10px;
  cursor: pointer;
  border-bottom: 1px solid #f1f5f9;
}
.maptools .mt-res div:hover {
  background: #eff6ff;
}
.maptools .mt-res span {
  color: #64748b;
  font-size: 11.5px;
  float: right;
}
.maptools .mt-res .none {
  color: #64748b;
  cursor: default;
}
.maptools .mt-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 3px;
  margin-top: 5px;
}
.maptools .mt-row button {
  border: 1px solid #e2e8f0;
  background: #f8fafc;
  border-radius: 8px;
  padding: 4px 1px;
  font:
    600 10.5px system-ui,
    sans-serif;
  cursor: pointer;
  color: #0f172a;
}
.maptools .mt-row button.on {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
}
.maplegend {
  background: rgba(255, 255, 255, 0.92);
  border-radius: 10px;
  padding: 5px 9px;
  font:
    12px system-ui,
    sans-serif;
  color: #0f172a;
  display: flex;
  gap: 10px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.18);
}
.maplegend i {
  display: inline-block;
  width: 10px;
  height: 10px;
  border-radius: 5px;
  margin-right: 4px;
  vertical-align: -1px;
}
.routebar {
  position: absolute;
  left: 50%;
  bottom: 14px;
  transform: translateX(-50%);
  z-index: 800;
  background: #fff;
  color: #0f172a;
  border-radius: 12px;
  padding: 7px 10px;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.25);
  font:
    13px system-ui,
    sans-serif;
  align-items: center;
  gap: 8px;
  max-width: 92%;
}
.route-dot {
  width: 26px;
  height: 26px;
  border-radius: 13px;
  background: #1e4fd8;
  color: #fff;
  border: 2px solid #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font:
    700 12px system-ui,
    sans-serif;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.35);
}
.route-dot.IN {
  background: #16a34a;
}
.route-dot.OUT {
  background: #dc2626;
}
.route-dot.VISIT {
  background: #7c3aed;
}
.mp-btn {
  border: 1px solid #cbd5e1;
  background: #f8fafc;
  color: #0f172a !important;
  border-radius: 8px;
  padding: 4px 8px;
  font:
    600 12px system-ui,
    sans-serif;
  cursor: pointer;
  text-decoration: none;
  display: inline-block;
}
.map-full {
  position: fixed !important;
  inset: 0 !important;
  z-index: 9500 !important;
  margin: 0 !important;
  border-radius: 0 !important;
  padding: 0 !important;
  background: #000;
}
.map-full > div,
.map-full #map,
.map-full .leaflet-container {
  height: 100vh !important;
  width: 100vw !important;
}
body.map-full-open {
  overflow: hidden;
}

/* ===== 2.0 SHABAB HR PRO — blue & gold, rounded everywhere ===== */
.btn.gold {
  background: linear-gradient(135deg, #f3d46b, #d4af37 55%, #b8901f);
  color: #1a1406;
  box-shadow: 0 6px 16px rgba(212, 175, 55, 0.35);
}
.btn.glass {
  background: rgba(255, 255, 255, 0.14);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.25);
  backdrop-filter: blur(6px);
}
.btn .cnt {
  background: var(--bad);
  color: #fff;
  border-radius: 99px;
  font-size: 11px;
  padding: 1px 7px;
}
.btn svg {
  width: 17px;
  height: 17px;
}
.lic-banner.gold {
  background: linear-gradient(90deg, rgba(212, 175, 55, 0.22), rgba(212, 175, 55, 0.08));
  border-color: rgba(212, 175, 55, 0.5);
  border-radius: 14px;
  margin-bottom: 14px;
}
.ab-top {
  text-align: center;
}
.ab-banner {
  width: 100%;
  max-width: 560px;
  border-radius: 22px;
  box-shadow: 0 14px 40px rgba(6, 18, 51, 0.25);
}
.ab-mods {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-top: 16px;
}
.ab-mods div {
  background: var(--bg);
  border-radius: 16px;
  padding: 12px 14px;
  border: 1px solid var(--line);
}
.ab-mods b {
  display: block;
  color: var(--primary);
}
.ab-mods span {
  font-size: 12.5px;
  color: var(--muted);
}
.ab-ceo {
  margin-top: 14px;
  border-radius: 20px;
  padding: 18px;
  color: #fff;
  display: flex;
  gap: 16px;
  align-items: center;
  background: radial-gradient(120% 140% at 90% -20%, var(--hero1), var(--hero2) 70%);
  border: 1px solid rgba(212, 175, 55, 0.55);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.05);
}
.ab-ceo img {
  width: 76px;
  height: 76px;
  border-radius: 20px;
  flex: none;
}
.ab-ceo .bb {
  color: #f3d46b;
}
.ab-co {
  margin-top: 14px;
  background: var(--bg);
  border-radius: 18px;
  padding: 16px;
}
@media (max-width: 560px) {
  .ab-mods {
    grid-template-columns: 1fr;
  }
}
/* module switch (sidebar) */
.modsw {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  background: rgba(255, 255, 255, 0.06);
  padding: 5px;
  border-radius: 16px;
  margin: 0 2px 6px;
  border: 1px solid rgba(212, 175, 55, 0.3);
}
.modsw button {
  border: 0;
  background: transparent;
  color: var(--sideMute);
  border-radius: 12px;
  padding: 9px 4px;
  font-weight: 800;
  font-size: 10.5px;
  letter-spacing: 0.6px;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
}
.modsw button svg {
  width: 20px;
  height: 20px;
}
.modsw button.on {
  background: linear-gradient(135deg, #f3d46b, #d4af37);
  color: #1a1406;
  box-shadow: 0 6px 16px rgba(212, 175, 55, 0.3);
}
[data-theme="classic"] .modsw {
  background: var(--bg2);
}
.side .brand img {
  border-radius: 14px;
}
.side .brand b i {
  font-style: normal;
  color: #e9c75a;
}
[data-theme="classic"] .side .brand b i {
  color: #b8901f;
}
.side a.on {
  box-shadow:
    inset 3px 0 0 #e9c75a,
    0 6px 18px color-mix(in srgb, var(--primary) 35%, transparent) !important;
}
.login .art img.banner {
  width: 380px;
  max-width: 100%;
  border-radius: 24px;
}
@media (max-width: 860px) {
  .login .art img.banner {
    width: 260px;
  }
}
/* HR pages */
.hr-hero {
  background: radial-gradient(120% 140% at 85% -20%, #2b63f0 0%, #0c1e4f 55%, #061233 100%) !important;
  border: 1px solid rgba(212, 175, 55, 0.45);
}
.hr-hero h1 {
  color: #fff;
}
.hr-hero h1:after {
  content: "";
  display: block;
  width: 64px;
  height: 3px;
  border-radius: 3px;
  background: linear-gradient(90deg, #f3d46b, #d4af37);
  margin-top: 8px;
}
.hr-hero-logo {
  margin-inline-start: auto;
  width: 120px;
  height: 120px;
  border-radius: 28px;
  position: relative;
  z-index: 1;
  filter: drop-shadow(0 12px 30px rgba(0, 0, 0, 0.4));
}
.hr-kpi {
  border-top: 3px solid var(--k);
}
.hr-kpi .n {
  font-size: 24px;
  padding-inline-end: 44px;
  overflow-wrap: anywhere;
}
.hr-kpi .s {
  font-size: 11.5px;
  color: var(--muted);
  margin-top: 4px;
}
.hr-tabs {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  margin: 0 0 14px;
  background: var(--card);
  padding: 6px;
  border-radius: 16px;
  box-shadow: var(--shadow);
}
.hr-tabs button {
  border: 0;
  background: transparent;
  padding: 9px 14px;
  border-radius: 12px;
  font-weight: 700;
  cursor: pointer;
  color: var(--muted);
  font-size: 13.5px;
}
.hr-tabs button.on {
  background: var(--primary);
  color: #fff;
  box-shadow: inset 0 -3px 0 #d4af37;
}
.hr-chart {
  width: 100%;
  height: auto;
  display: block;
}
.hr-leg {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 14px;
  font-size: 12px;
  color: var(--muted);
  margin-top: 6px;
}
.hr-leg i {
  display: inline-block;
  width: 10px;
  height: 10px;
  border-radius: 3px;
  margin-inline-end: 5px;
  vertical-align: -1px;
}
.hr-leg.col {
  flex-direction: column;
  gap: 6px;
}
.hr-leg b {
  color: var(--text);
  margin-inline-start: 4px;
}
.hr-hb .r {
  display: grid;
  grid-template-columns: minmax(80px, 34%) 1fr auto;
  gap: 10px;
  align-items: center;
  padding: 5px 0;
  font-size: 13px;
}
.hr-hb .k {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.hr-hb .b {
  background: var(--bg2);
  border-radius: 99px;
  height: 12px;
  overflow: hidden;
}
.hr-hb .b i {
  display: block;
  height: 100%;
  border-radius: 99px;
}
.hr-hb b {
  font-variant-numeric: tabular-nums;
  font-size: 12.5px;
}
.hr-donut {
  display: flex;
  align-items: center;
  gap: 18px;
  flex-wrap: wrap;
}
.hr-donut svg {
  width: 150px;
  height: 150px;
  flex: none;
}
.hr-rep {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}
.hr-rep .span2 {
  grid-column: 1 / -1;
}
.hr-rep .card h3 {
  font-size: 15px;
}
.hr-total {
  margin-top: 8px;
  padding: 12px 14px;
  border-radius: 14px;
  background: linear-gradient(90deg, rgba(212, 175, 55, 0.18), rgba(212, 175, 55, 0.05));
  display: flex;
  justify-content: space-between;
  font-weight: 700;
}
.hr-total b {
  font-size: 20px;
  color: var(--primary);
}
.hr-bal {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(170px, 1fr));
  gap: 12px;
}
.hr-bal .hb {
  background: var(--bg);
  border-radius: 16px;
  padding: 14px;
  border: 1px solid var(--line);
  border-top: 3px solid var(--primary);
}
.hr-bal .hb .n {
  font-size: 28px;
  font-weight: 800;
  color: var(--primary);
}
.hr-bal .hb.neg .n {
  color: var(--bad);
}
.hr-bal .hb .l {
  font-weight: 700;
}
.hr-bal .hb .s {
  font-size: 12px;
  color: var(--muted);
}
.hr-settle {
  display: grid;
  gap: 2px;
  max-width: 520px;
}
.hr-settle > div {
  display: flex;
  justify-content: space-between;
  padding: 9px 12px;
  border-radius: 10px;
}
.hr-settle > div:nth-child(odd) {
  background: var(--bg);
}
.hr-settle .tot {
  background: linear-gradient(90deg, #0c1e4f, #1e4fd8) !important;
  color: #fff;
  font-size: 16px;
  margin-top: 6px;
}
.hr-settle .tot b {
  color: #f3d46b;
  font-size: 20px;
}
.hr-pay td.neg {
  color: var(--bad);
}
.hr-pay td.net {
  color: var(--primary);
  font-size: 15px;
}
.hr-pay tfoot td {
  font-weight: 800;
  background: var(--bg2);
  position: sticky;
  bottom: 0;
}
.hr-lock {
  max-width: 620px;
  margin: 20px auto;
  text-align: center;
}
.hr-lock img {
  width: 100%;
  max-width: 440px;
  border-radius: 22px;
}
.hr-lock .lic-ids {
  text-align: start;
}
.t td.r,
.t th.r {
  text-align: end;
}
.t td.b {
  font-weight: 700;
  white-space: nowrap;
} /* 2.1.7: "9:25 AM" stays on one line */
@media (max-width: 1000px) {
  .hr-rep {
    grid-template-columns: 1fr;
  }
  .hr-hero-logo {
    width: 80px;
    height: 80px;
  }
}
@media print {
  .hr-tabs,
  .modsw {
    display: none !important;
  }
  .hr-rep {
    grid-template-columns: 1fr 1fr;
  }
  .card {
    break-inside: avoid;
    box-shadow: none;
    border: 1px solid #ddd;
  }
}
.hr-kpi .n small.cur {
  display: block;
  font-size: 11.5px;
  font-weight: 800;
  color: var(--muted);
  letter-spacing: 1px;
  line-height: 1.2;
}
.side .brand span {
  letter-spacing: 0.8px;
}
.hbal {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
  gap: 10px;
}
.hbal div {
  background: var(--bg);
  border-radius: 16px;
  padding: 12px;
  border-top: 3px solid var(--accent);
}
.hbal b {
  display: block;
  font-size: 30px;
  color: var(--primary);
  line-height: 1.1;
}
.hbal span {
  font-weight: 700;
  font-size: 13.5px;
  display: block;
}
.hbal i {
  font-style: normal;
  font-size: 12px;
  color: var(--muted);
}
.cpick {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(118px, 1fr));
  gap: 8px;
}
.cpick button {
  border: 1.5px solid var(--line);
  background: var(--card);
  border-radius: 14px;
  padding: 9px 10px;
  text-align: start;
  cursor: pointer;
  color: var(--text);
  display: flex;
  flex-direction: column;
  gap: 1px;
  font: inherit;
}
.cpick button b {
  font-size: 13.5px;
}
.cpick button span {
  font-size: 11.5px;
  color: var(--muted);
}
.cpick button i {
  font-style: normal;
  font-size: 10.5px;
  color: #b8901f;
  font-weight: 700;
}
.cpick button.on {
  border-color: var(--primary);
  background: color-mix(in srgb, var(--primary) 8%, var(--card));
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 45%, transparent);
}
/* 2.0.1 staff form */
.ferr {
  display: block;
  color: var(--bad);
  font-size: 12.5px;
  font-weight: 600;
  min-height: 0;
  margin-top: 4px;
}
.ferr:empty {
  display: none;
}
.input.bad {
  border-color: var(--bad) !important;
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--bad) 18%, transparent);
}
.daychk.dis label {
  opacity: 0.55;
}
.daychk.dis label:has(input:checked) {
  opacity: 0.8;
}
.mgrid th:not(.n),
.mgrid td:not(.n) {
  width: 34px;
  min-width: 34px;
  max-width: 34px;
} /* 2.0.1 even day columns */
.smsbox {
  display: block;
  background: var(--bg2);
  border-radius: 8px;
  padding: 6px 10px;
  margin: 6px 0;
  font-family: Consolas, monospace;
  font-size: 13.5px;
  white-space: pre-wrap;
  word-break: break-all;
  user-select: all;
}
/* 2.1.2 QA (11 Oct): boxes never crushed, tables scroll inside their card (not the whole page), phone-friendly pop-ups and numbers */
.row.wrap > .field.grow {
  flex: 1 1 180px;
}
.row > .field {
  min-width: 0;
}
.card:has(table.t) {
  overflow-x: auto;
}
.modal .row {
  flex-wrap: wrap;
}
@media (max-width: 640px) {
  .hr-kpi .n {
    white-space: nowrap;
    overflow-wrap: normal;
    font-size: 20px;
    padding-inline-end: 38px;
  }
  .row.wrap > .field {
    flex: 1 1 140px;
  }
  .modal .field[style*="width"] {
    width: auto !important;
    flex: 1 1 140px;
  }
}
/* 2.1.2: card titles with buttons and long setting rows wrap on small screens */
.card > h3 {
  flex-wrap: wrap;
  row-gap: 6px;
}
@media (max-width: 600px) {
  .setrow {
    flex-wrap: wrap;
  }
  .setrow > .row {
    flex-wrap: wrap;
    gap: 6px;
  }
  .setrow > .row > .input[style*="width:84px"] {
    width: 72px !important;
  }
}

/* =================================================================== 2.1.5 — polish + new screens (Year / 10-year reports, extra features, kiosk, machines) */
.kpi {
  border-radius: 20px;
}
.kpi .n {
  letter-spacing: -0.5px;
  font-variant-numeric: tabular-nums;
}
.kpi:before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, color-mix(in srgb, var(--accent) 70%, transparent), transparent);
}
.xkpis .kpi {
  cursor: default;
}
.xkpis .kpi .n {
  font-size: 28px;
  padding-inline-end: 46px;
}
.card {
  transition: box-shadow 0.15s;
}
.toolbar h2 {
  letter-spacing: -0.3px;
}
.xchart {
  width: 100%;
  height: auto;
  display: block;
}
.xcharts .card h3 {
  margin-bottom: 6px;
}
.hbars {
  display: flex;
  flex-direction: column;
  gap: 9px;
}
.hb {
  display: grid;
  grid-template-columns: minmax(90px, 38%) 1fr auto;
  gap: 10px;
  align-items: center;
  font-size: 13.5px;
}
.hb-l {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-weight: 700;
}
.hb-l span {
  display: block;
  font-weight: 500;
  color: var(--muted);
  font-size: 11.5px;
}
.hb-b {
  height: 12px;
  background: var(--bg2);
  border-radius: 99px;
  overflow: hidden;
}
.hb-b i {
  display: block;
  height: 100%;
  border-radius: 99px;
}
.hb b {
  font-variant-numeric: tabular-nums;
  min-width: 34px;
  text-align: end;
}
.xyear td,
.xyear th {
  font-variant-numeric: tabular-nums;
}
.xtot td {
  background: color-mix(in srgb, var(--primary) 7%, var(--card)) !important;
  border-top: 2px solid var(--primary);
}
.hr-tabs .xtab {
  color: var(--primary);
}
.hr-tabs .xtab.on {
  color: #fff;
}
.xempty {
  text-align: center;
  padding: 38px 20px;
  max-width: 640px;
  margin: 10px auto;
}
.xempty .xe-ic {
  font-size: 46px;
  width: 92px;
  height: 92px;
  border-radius: 28px;
  margin: 0 auto 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: color-mix(in srgb, var(--primary) 10%, var(--card));
  box-shadow: inset 0 -3px 0 color-mix(in srgb, var(--accent) 60%, transparent);
}
.xempty h3 {
  justify-content: center;
  font-size: 19px;
}
.xempty p {
  margin: 0 auto;
  max-width: 460px;
}
.xnote {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  padding: 12px 16px;
  border-bottom: 1px solid var(--line);
}
.xnote:last-child {
  border-bottom: 0;
}
.xnote.unread {
  background: color-mix(in srgb, var(--primary) 6%, var(--card));
}
.xn-ic {
  width: 38px;
  height: 38px;
  border-radius: 12px;
  flex: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 19px;
  background: var(--bg2);
}
.btn.wa {
  background: #e8f8ee;
  color: #128c4a;
}
.xbell {
  position: relative;
}
.xbell .cnt {
  position: absolute;
  top: -5px;
  inset-inline-end: -5px;
  background: var(--bad);
  color: #fff;
  border-radius: 99px;
  font-size: 10.5px;
  padding: 1px 6px;
  font-weight: 800;
}
.xdashgrid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 16px;
  margin: 0 0 18px;
}
.xdashgrid > * {
  min-width: 0;
}
.xtodo {
  text-decoration: none;
  color: inherit;
}
.xmoodrow {
  display: flex;
  gap: 10px;
}
.xmoodrow div {
  flex: 1;
  text-align: center;
  background: var(--bg);
  border-radius: 14px;
  padding: 10px;
  font-size: 26px;
}
.xmoodrow b {
  display: block;
  font-size: 20px;
}
.xprayer {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 6px;
}
.xprayer div {
  background: var(--bg);
  border-radius: 12px;
  padding: 8px 4px;
  text-align: center;
}
.xprayer span {
  display: block;
  font-size: 11px;
  color: var(--muted);
  font-weight: 700;
}
.xprayer b {
  font-variant-numeric: tabular-nums;
}
.xfeats {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 330px), 1fr));
  gap: 10px;
}
.xfeat {
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 12px;
  background: var(--card);
  transition:
    border-color 0.15s,
    box-shadow 0.15s;
}
.xfeat.on {
  border-color: color-mix(in srgb, var(--primary) 50%, transparent);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--primary) 10%, transparent);
}
.xf-top {
  display: flex;
  gap: 10px;
  align-items: flex-start;
}
.xf-top b {
  display: block;
  font-size: 14px;
}
.xf-top span {
  font-size: 12.3px;
  color: var(--muted);
  display: block;
  line-height: 1.4;
}
.xf-ic {
  font-size: 22px;
  width: 40px;
  height: 40px;
  border-radius: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--bg);
  flex: none;
}
.xf-sub {
  display: none;
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px dashed var(--line);
  font-size: 13px;
  line-height: 2.1;
}
.xfeat.on .xf-sub {
  display: block;
}
.xf-sub .input {
  display: inline-block;
  padding: 6px 9px;
  vertical-align: middle;
  max-width: 100%;
}
.xstaffbox {
  background: var(--bg);
  border-radius: 14px;
  padding: 12px 12px 4px;
  margin-bottom: 10px;
}
.xswap {
  display: flex;
  flex-direction: column;
  min-width: 90px;
}
.xk {
  text-align: center;
}
.xk-ic {
  font-size: 40px;
}
.xbest {
  display: flex;
  align-items: center;
  gap: 18px;
  flex-wrap: wrap;
  margin-bottom: 16px;
  color: #fff;
  background: radial-gradient(120% 140% at 90% -20%, var(--hero1), var(--hero2) 70%);
  border: 0;
  position: relative;
  overflow: hidden;
}
.xbest:after {
  content: "";
  position: absolute;
  left: 20px;
  right: 20px;
  bottom: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--accent), transparent);
}
.xb-medal {
  font-size: 54px;
}
.xscore {
  display: inline-flex;
  min-width: 46px;
  justify-content: center;
  padding: 3px 8px;
  border-radius: 99px;
  font-weight: 800;
  color: #fff;
  background: hsl(calc(var(--s) * 1.2), 70%, 40%);
}
.xrank {
  display: inline-flex;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  background: var(--bg2);
}
.xrank.r1 {
  background: #d4af37;
  color: #fff;
}
.xrank.r2 {
  background: #a8b3c4;
  color: #fff;
}
.xrank.r3 {
  background: #c47f3b;
  color: #fff;
}
.rsel {
  border: 2px solid var(--line);
  border-radius: 8px;
  padding: 3px 2px;
  font-size: 11.5px;
  background: var(--card);
  max-width: 86px;
}
.rsel.moved {
  background: color-mix(in srgb, var(--warn) 14%, var(--card));
}
.xqrcard {
  max-width: 420px;
  margin: 0 auto 14px;
  text-align: center;
  padding: 24px;
  border-top: 4px solid var(--primary);
}
.xqr-head {
  display: flex;
  gap: 12px;
  align-items: center;
  text-align: start;
  margin-bottom: 14px;
}
.xqr-head img {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  object-fit: contain;
  background: #fff;
  border: 1px solid var(--line);
}
.xqrimg img {
  width: 100%;
  max-width: 300px;
  height: auto;
  image-rendering: pixelated;
  background: #fff;
  padding: 8px;
  border-radius: 12px;
}
.xqr-t {
  font-size: 20px;
  font-weight: 800;
  margin-top: 8px;
}
.mstep {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  padding: 8px 0;
  border-bottom: 1px dashed var(--line);
}
.mstep:last-of-type {
  border-bottom: 0;
}
.mnum {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--primary);
  color: #fff;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  flex: none;
}
.maddr {
  font-size: 16px;
  font-weight: 800;
  background: var(--bg);
  padding: 2px 8px;
  border-radius: 8px;
  word-break: break-all;
}
.mguide {
  display: grid;
  gap: 14px;
  max-width: 980px;
}
.mg-sec ol,
.mg-sec ul {
  line-height: 1.8;
  padding-inline-start: 22px;
}
.mg-h {
  font-size: 17px;
}
.mgdraw {
  width: 100%;
  max-width: 360px;
  height: auto;
  display: block;
  margin: 0 0 10px;
  border-radius: 12px;
}
.xmi {
  font-size: 16px;
  width: 19px;
  text-align: center;
  flex: none;
}
.side a {
  transition: background 0.12s;
}
.side .sec {
  position: relative;
}
.side .brand {
  position: relative;
}
.side .brand:after {
  content: "";
  position: absolute;
  left: 8px;
  right: 8px;
  bottom: 6px;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(212, 175, 55, 0.6), transparent);
}
.top {
  box-shadow: 0 1px 0 rgba(212, 175, 55, 0.25);
}
/* staff phone */
.pbtns {
  display: flex;
  gap: 8px;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 4px;
}
.pbtns .btn {
  flex: 1 1 140px;
  max-width: 220px;
}
.xban {
  border-radius: 16px;
  padding: 12px 14px;
  font-weight: 600;
  font-size: 14px;
  box-shadow: var(--shadow);
}
.xban.warn {
  background: color-mix(in srgb, var(--warn) 16%, var(--card));
  border: 1px solid color-mix(in srgb, var(--warn) 40%, transparent);
}
.xban.ok {
  background: color-mix(in srgb, var(--ok) 14%, var(--card));
  border: 1px solid color-mix(in srgb, var(--ok) 35%, transparent);
  text-align: center;
  font-size: 16px;
}
.xban.info {
  background: var(--card);
  border: 1px solid var(--line);
}
.xmood {
  display: flex;
  gap: 12px;
  justify-content: center;
}
.xmood button {
  font-size: 46px;
  width: 84px;
  height: 84px;
  border-radius: 24px;
  border: 2px solid var(--line);
  background: var(--bg);
  cursor: pointer;
}
.xmood button:active {
  transform: scale(0.94);
}
.cal {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 5px;
}
.cal-h {
  text-align: center;
  font-size: 11.5px;
  font-weight: 800;
  color: var(--muted);
  padding-bottom: 2px;
}
.cal-d {
  aspect-ratio: 1;
  border-radius: 12px;
  background: var(--bg);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  cursor: pointer;
  position: relative;
}
.cal-d i {
  font-style: normal;
  font-size: 9.5px;
  font-weight: 800;
}
.cal-d.pr {
  background: var(--okBg);
  color: var(--ok);
}
.cal-d.lt {
  background: var(--warnBg);
  color: var(--warn);
}
.cal-d.ab {
  background: var(--badBg);
  color: var(--bad);
}
.cal-d.lv {
  background: #ede9fe;
  color: #6d28d9;
}
.cal-d.of {
  background: var(--bg2);
  color: var(--muted);
}
.cal-d.today {
  box-shadow: inset 0 0 0 2px var(--primary);
}
.cal-key {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 10px;
  color: var(--muted);
}
.cal-key i {
  display: inline-block;
  width: 11px;
  height: 11px;
  border-radius: 4px;
  margin-inline-end: 4px;
  vertical-align: -1px;
}
.cal-key i.pr {
  background: var(--ok);
}
.cal-key i.lt {
  background: var(--warn);
}
.cal-key i.ab {
  background: var(--bad);
}
.cal-key i.lv {
  background: #7c3aed;
}
.cal-key i.of {
  background: var(--silver);
}
.qrframe {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 62%;
  aspect-ratio: 1;
  transform: translate(-50%, -50%);
  border: 4px solid #fff;
  border-radius: 24px;
  box-shadow: 0 0 0 999px rgba(0, 0, 0, 0.45);
}
[data-theme="midnight"] .cal-d.lv,
[data-theme="lavender"] .cal-d.lv,
[data-theme="nexus"] .cal-d.lv {
  background: #2a1f4a;
  color: #c4b5fd;
}
[data-theme="midnight"] .btn.wa,
[data-theme="lavender"] .btn.wa,
[data-theme="nexus"] .btn.wa {
  background: #0f2d1c;
  color: #6ee7a0;
}
@media (max-width: 600px) {
  .xprayer {
    grid-template-columns: repeat(3, 1fr);
  }
  .hb {
    grid-template-columns: minmax(70px, 34%) 1fr auto;
  }
  .xkpis .kpi .n {
    font-size: 22px;
  }
  .xmood button {
    width: 72px;
    height: 72px;
    font-size: 38px;
  }
}
@media print {
  .xbell,
  #xlang,
  .langsw {
    display: none !important;
  }
  .xcharts .card {
    break-inside: avoid;
  }
}

/* 2.1.6: app name always visible inside the login card (the big title scrolls away on small phones / short windows) */
.login .box .appname {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin: -4px 0 12px;
  font-size: 14px;
  letter-spacing: 0.06em;
  color: var(--ink, #0b1b3f);
}
.login .box .appname img {
  width: 26px;
  height: 26px;
  border-radius: 7px;
}
[data-theme="midnight"] .login .box .appname,
[data-theme="lavender"] .login .box .appname,
[data-theme="nexus"] .login .box .appname {
  color: #e6edff;
} /* 2.3.1: the dark theme is called "midnight" ("dark" never matched: dark-blue name on the dark box) */

/* 2.1.8 bell: small window on the right */
.xbellpop {
  position: fixed;
  top: 100px;
  inset-inline-end: 16px;
  width: min(380px, calc(100vw - 24px));
  max-height: min(70vh, 560px);
  display: flex;
  flex-direction: column;
  background: var(--card, #fff);
  color: var(--text, #0f172a);
  border: 1px solid var(--line);
  border-radius: 16px;
  box-shadow: 0 18px 50px rgba(15, 23, 42, 0.22);
  z-index: 900;
  overflow: hidden;
}
.xbellpop .xbp-h {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 12px 10px 16px;
  border-bottom: 1px solid var(--line);
}
.xbellpop .xbp-list {
  overflow-y: auto;
  flex: 1;
}
.xbellpop .xnote {
  padding: 10px 14px;
  gap: 10px;
}
.xbellpop .xbp-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  text-align: center;
  padding: 22px 18px;
  font-size: 26px;
}
.xbellpop .xbp-empty b {
  font-size: 15px;
}
.xbellpop .xbp-f {
  padding: 8px;
  border-top: 1px solid var(--line);
  text-align: center;
}

/* 2.1.9 simple About */
.ab2 {
  font-weight: 400;
  line-height: 1.5;
}
.ab2 b {
  font-weight: 400;
}
.ab2-head {
  display: flex;
  gap: 14px;
  align-items: center;
}
.ab2-head img {
  width: 56px;
  height: 56px;
  border-radius: 14px;
  flex: none;
}
.ab2-name {
  font-size: 20px;
  font-weight: 500;
  letter-spacing: 0.5px;
}
.ab2-sub,
.ab2-pr {
  font-size: 13px;
  color: var(--muted);
}
.ab2-p {
  font-size: 14px;
  margin: 14px 0;
}
.ab2-lbl {
  font-size: 11px;
  letter-spacing: 2px;
  color: var(--muted);
  margin: 18px 0 8px;
}
.ab2-ppl {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
@media (max-width: 520px) {
  .ab2-ppl {
    grid-template-columns: 1fr;
  }
}
.ab2-pn {
  font-size: 17px;
  font-weight: 500;
}
.ab2-co {
  display: flex;
  gap: 12px;
  align-items: center;
  margin-top: 18px;
  padding-top: 16px;
  border-top: 1px solid var(--line, rgba(0, 0, 0, 0.1));
}
.ab2-co img {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  flex: none;
}
.ab2-ct {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 16px;
  font-size: 13px;
  margin-top: 12px;
}
.ab2-ft {
  font-size: 11px;
  color: var(--muted);
  text-align: center;
  margin-top: 16px;
}

/* 2.2.2 quick language switch EN | عربي (top bar of every screen, login, phones) — 44 px touch target */
.langsw {
  display: inline-flex;
  border: 1.5px solid var(--line, #cbd5e1);
  border-radius: 12px;
  overflow: hidden;
  background: var(--card, #fff);
  flex: 0 0 auto;
  direction: ltr;
}
.langsw button {
  min-width: 48px;
  min-height: 44px;
  padding: 0 12px;
  border: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  font-weight: 700;
  font-size: 15px;
  cursor: pointer;
  touch-action: manipulation;
}
.langsw button[lang="ar"] {
  font-family: "Noto Kufi Arabic", "Segoe UI", Tahoma, sans-serif;
}
.langsw button.on {
  background: var(--primary, #1e4fd8);
  color: #fff;
}
.langsw button:focus-visible {
  outline: 3px solid var(--gold, #d4af37);
  outline-offset: -3px;
}
.login .langsw,
.langsw.float {
  position: fixed;
  top: 12px;
  inset-inline-end: 12px;
  z-index: 60;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.12);
}
.hero .langsw {
  background: rgba(255, 255, 255, 0.14);
  border-color: rgba(255, 255, 255, 0.45);
  color: #fff;
}
.hero .langsw button.on {
  background: #fff;
  color: var(--primary, #1e4fd8);
}
@media (max-width: 600px) {
  main > .top {
    flex-wrap: wrap;
    padding: 10px 12px;
    gap: 8px;
  }
  main > .top .grow {
    min-width: 0;
    flex: 1 1 120px;
  }
  main > .top .grow h1 {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: 16px;
  }
  main > .top .grow .sub {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }
}
@media (max-width: 860px) {
  .login .langsw {
    position: absolute;
  }
  .login .art {
    padding-top: 70px !important;
  }
}

/* 2.3.5 Bank Muscat WPS window */
.wps-head td {
  padding: 5px 8px;
}
.wps-head td:first-child {
  width: 45%;
}
.wps-box {
  border-radius: 10px;
  padding: 10px 12px;
  margin: 10px 0;
  font-size: 14px;
  border: 1px solid var(--line);
}
.wps-box.bad {
  border-color: var(--bad, #dc2626);
  background: rgba(220, 38, 38, 0.06);
}
.wps-box.warn {
  border-color: var(--warn, #d97706);
  background: rgba(217, 119, 6, 0.07);
}
.wps-box.ok {
  border-color: var(--ok, #16a34a);
  background: rgba(22, 163, 74, 0.07);
}
.wps-box ul {
  margin: 4px 0 6px;
  padding-inline-start: 20px;
}
.wps-emp {
  margin-top: 6px;
}
.wps-emp a {
  text-decoration: none;
  color: inherit;
}

/* 2.3.5 HINTS (web/js/core/hints.js): small ⓘ, never changes the size of a button, never covers a field box */
.sbh-i {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 14px;
  height: 14px;
  margin-inline-start: 5px;
  border-radius: 50%;
  border: 1px solid currentColor;
  font: italic 700 9.5px/1 Georgia, "Times New Roman", serif;
  opacity: 0.45;
  cursor: help;
  vertical-align: middle;
  flex: 0 0 auto;
  position: relative;
  text-transform: none;
  letter-spacing: 0;
}
.sbh-i::before {
  content: "i";
}
.sbh-i::after {
  content: "";
  position: absolute;
  inset: -7px;
}
.sbh-i:hover,
.sbh-i:focus {
  opacity: 1;
}
.sbh-off .sbh-i {
  display: none !important;
}
.btn.sbh-has,
.seg > .sbh-has,
.hr-tabs > .sbh-has,
.cs-tabs > .sbh-has {
  position: relative;
}
.btn > .sbh-i {
  position: absolute;
  top: -5px;
  inset-inline-end: -5px;
  margin: 0;
  width: 13px;
  height: 13px;
  font-size: 9px;
  background: var(--card, #fff);
  color: var(--muted, #5b6880);
  opacity: 0.8;
  z-index: 2;
}
.side a > .sbh-i {
  margin-inline-start: auto;
  opacity: 0.35;
}
.side a > .sbh-i + .cnt,
.side a > .cnt + .sbh-i {
  margin-inline-start: 6px;
}
th > .sbh-i {
  width: 12px;
  height: 12px;
  font-size: 8.5px;
  margin-inline-start: 3px;
}
.sbh-pop {
  position: absolute;
  z-index: 2147483000;
  background: #0b1630;
  color: #fff;
  border-radius: 10px;
  padding: 9px 12px 8px;
  font: 500 13px/1.45 "Segoe UI", system-ui, "Noto Kufi Arabic", sans-serif;
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.28);
  pointer-events: auto;
  text-align: start;
  white-space: normal;
}
.sbh-pop .sbh-more {
  display: inline-block;
  margin-top: 5px;
  color: #ffd76a;
  font-weight: 700;
  text-decoration: none;
}
.sbh-pop .sbh-more:hover {
  text-decoration: underline;
}
@media print {
  .sbh-i,
  .sbh-pop {
    display: none !important;
  }
}

/* 2.3.5 HELP CENTER (training manual) */
.hc-top {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  margin-bottom: 10px;
}
.hc-top h2 {
  margin: 0;
  flex: 1 1 100%;
}
.hc-top .input {
  flex: 1 1 260px;
  min-width: 0;
}
.hc-sw {
  display: inline-flex;
  gap: 6px;
  align-items: center;
  font-weight: 600;
  font-size: 14px;
}
.hc-res a {
  display: block;
  padding: 7px 10px;
  border-radius: 8px;
  text-decoration: none;
  color: inherit;
  background: var(--card);
  margin-bottom: 4px;
  border: 1px solid var(--line);
}
.hc-wrap {
  display: grid;
  grid-template-columns: 250px minmax(0, 1fr);
  gap: 16px;
  align-items: start;
}
.hc-toc {
  position: sticky;
  top: 10px;
  background: var(--card);
  border-radius: 14px;
  padding: 10px 6px;
  border: 1px solid var(--line);
  max-height: calc(100vh - 40px);
  overflow: auto;
}
.hc-toc ol {
  list-style: none;
  margin: 0;
  padding: 0;
}
.hc-toc a {
  display: block;
  padding: 6px 10px;
  border-radius: 8px;
  color: inherit;
  text-decoration: none;
  font-size: 14px;
}
.hc-toc a:hover {
  background: var(--bg2);
}
.hc-main {
  min-width: 0;
}
.hc-ch {
  background: var(--card);
  border-radius: 16px;
  padding: 6px 18px 14px;
  margin-bottom: 14px;
  border: 1px solid var(--line);
}
.hc-ch > h2 {
  font-size: 20px;
  margin: 12px 0 4px;
}
.hc-sec {
  padding: 8px 10px;
  margin: 0 -10px;
  border-radius: 12px;
  transition: background 0.4s;
  scroll-margin-top: 16px;
}
.hc-sec.hl {
  background: rgba(212, 175, 55, 0.18);
}
.hc-sec h3 {
  margin: 10px 0 6px;
  font-size: 16.5px;
}
.hc-body {
  line-height: 1.7;
  font-size: 14.5px;
  overflow-wrap: anywhere; /* 2.6.4: long file names / codes (SIF_<CR>_<BANK>_…) wrap — no side scroll on a phone (Arabic too) */
}
.hc-body pre,
.hc-body code {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
.hc-body .note {
  background: var(--infoBg);
  border-inline-start: 4px solid var(--info);
  padding: 8px 12px;
  border-radius: 8px;
}
.hc-body table.t {
  width: 100%;
  border-collapse: collapse;
  margin: 8px 0;
  font-size: 13.5px;
}
.hc-body table.t td,
.hc-body table.t th {
  border: 1px solid var(--line);
  padding: 5px 8px;
  text-align: start;
}
.hc-body dt {
  font-weight: 700;
  margin-top: 8px;
}
.hc-body dd {
  margin-inline-start: 16px;
}
.hc-fig {
  margin: 10px 0 4px;
}
.hc-fig img {
  max-width: 100%;
  height: auto;
  border-radius: 10px;
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
}
@media (max-width: 760px) {
  .hc-wrap {
    grid-template-columns: minmax(0, 1fr);
  }
  .hc-toc {
    position: static;
    max-height: none;
  }
  .hc-ch {
    padding: 4px 12px 10px;
  }
}
.hc-print .hc-wrap {
  display: block;
}
.hc-cover {
  text-align: center;
  padding: 120px 0 60px;
  page-break-after: always;
}
.hc-cover img {
  width: 110px;
}
.hc-cover h1 {
  font-size: 34px;
  margin: 18px 0 6px;
}
.hc-print .hc-ch {
  page-break-before: always;
  border: 0;
  box-shadow: none;
  padding: 0;
}
.hc-print .hc-sec {
  page-break-inside: avoid;
}
.hc-print .hc-fig img {
  max-height: 420px;
  object-fit: contain;
  box-shadow: none;
}
.hc-printbody {
  background: #fff !important;
}
[dir="rtl"] .hc,
.hc[dir="rtl"] {
  font-family: "Noto Kufi Arabic", "Segoe UI", system-ui, sans-serif;
}
.sbh-pop.sbh-inline {
  position: static;
  display: block;
  margin: 2px 0 6px;
  max-width: 100% !important;
  box-shadow: none;
  font-size: 12.5px;
  padding: 7px 10px;
}

/* 2.4.1 HR PRO + BIO CLOUD: the "BIO CLOUD" menu line only while linked; source tag BIO */
html:not([data-bio="1"]) #sidenav a[data-p="hrbio"],
html:not([data-bioallowed="1"]) #sidenav a[data-p="hrbiolink"] {
  display: none;
}
.pill.bio-src {
  background: color-mix(in srgb, var(--primary) 16%, transparent);
  color: var(--primary);
  font-weight: 800;
  letter-spacing: 0.04em;
}

/* 2.4.1 READABLE TEXT ON COLOURED BUTTONS / BADGES in the NEXUS + Lavender themes (WCAG AA, checked by tests/v241/ui_x241.py):
   dark themes have LIGHT buttons (gold / lavender / light green / light red) → dark ink on them; coloured initials circles a bit darker. */
:is([data-theme="nexus"], [data-theme="lavender"]) :is(.avatar:not([style*="background"]), .langsw button.on, .bub.me, .msgpop .mp-h, .mapmode button.on, .maptools .mt-row button.on, .hr-tabs button.on, .mnum, .daychk label:has(input:checked), .lang button.on) {
  color: var(--primaryText);
}
:is([data-theme="nexus"], [data-theme="lavender"], [data-theme="nexuslight"]) .avatar[style*="background"] {
  color: #fff;
}
/* staff phone: the big PUNCH button (green IN / red OUT) keeps white text on a deeper colour */
:is([data-theme="nexus"], [data-theme="lavender"]) .big {
  --ring: #166534;
}
:is([data-theme="nexus"], [data-theme="lavender"]) .big.out {
  --ring: #991b1b;
}
[data-theme="nexuslight"] .btn.wa {
  color: #0d6235;
}
:is([data-theme="nexus"], [data-theme="lavender"]) :is(.btn.ok, .btn.bad, .btn.warn, .btn.danger) {
  color: #10141c;
}
:is([data-theme="nexus"], [data-theme="lavender"]) :is(.cnt, b.cnt) {
  color: #10141c;
}
:is([data-theme="nexus"], [data-theme="lavender"]) .lic-banner.gold {
  color: var(--text);
  background: linear-gradient(90deg, rgba(212, 175, 55, 0.18), rgba(212, 175, 55, 0.06)), var(--card);
}
:is([data-theme="nexus"], [data-theme="lavender"]) .lic-banner.gold a {
  color: var(--primary2);
}
:is([data-theme="nexus"], [data-theme="lavender"], [data-theme="nexuslight"]) .avatar[style*="background"] {
  background-image: linear-gradient(rgba(0, 0, 0, 0.32), rgba(0, 0, 0, 0.32)) !important; /* darker circle under the white initials */
}
:is([data-theme="nexus"], [data-theme="lavender"]) .langsw button:not(.on) {
  color: var(--text);
}

/* 2.4.1 THEME STUDIO: text size (company-wide) + dashboard layouts (Classic cards = as before, Compact list, Today focus with a big clock) */
html[data-fs="2"] body {
  zoom: 1.1;
}
html[data-fs="3"] body {
  zoom: 1.22;
}
html[data-layout="compact"] .kpis {
  gap: 8px;
}
html[data-layout="compact"] .kpis .kpi {
  padding: 10px 12px;
  min-height: 0;
}
html[data-layout="compact"] .kpis .kpi .n {
  font-size: 20px;
}
html[data-layout="compact"] .card {
  padding: 12px 14px;
}
.lk-focus {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 18px;
  align-items: center;
  margin: 0 0 14px;
  padding: 18px 22px;
  border-radius: var(--radius);
  background: linear-gradient(135deg, var(--hero1), var(--hero2));
  color: #fff;
  box-shadow: var(--shadow);
}
.lk-focus .lk-t {
  font-size: 56px;
  font-weight: 800;
  line-height: 1;
  letter-spacing: 0.02em;
  font-variant-numeric: tabular-nums;
  direction: ltr;
}
.lk-focus .lk-d {
  font-size: 18px;
  font-weight: 700;
  opacity: 0.95;
}
.lk-focus .lk-s {
  font-size: 14px;
  opacity: 0.9;
  margin-top: 4px;
}
@media (max-width: 600px) {
  .lk-focus {
    grid-template-columns: 1fr;
    text-align: center;
  }
  .lk-focus .lk-t {
    font-size: 44px;
  }
}
.lk-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 12px;
}
.lk-card {
  border: 2px solid var(--line);
  border-radius: 16px;
  overflow: hidden;
  cursor: pointer;
  background: var(--card);
  text-align: start;
  padding: 0;
  color: var(--text);
  font: inherit;
}
.lk-card.on {
  border-color: var(--accent);
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--accent) 22%, transparent);
}
.lk-card .pv {
  height: 86px;
  display: flex;
}
.lk-card .pv i {
  width: 30%;
}
.lk-card .pv b {
  flex: 1;
  padding: 10px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.lk-card .pv b span {
  height: 8px;
  border-radius: 4px;
  display: block;
}
.lk-card .n {
  padding: 8px 10px;
  font-weight: 800;
  font-size: 14px;
}
.lk-card .d {
  padding: 0 10px 10px;
  font-size: 12px;
  color: var(--muted);
}
.lk-seg {
  display: inline-flex;
  border: 1.5px solid var(--line);
  border-radius: 12px;
  overflow: hidden;
}
.lk-seg button {
  min-height: 44px;
  padding: 0 18px;
  border: 0;
  background: transparent;
  color: var(--text);
  font: inherit;
  font-weight: 700;
  cursor: pointer;
}
.lk-seg button.on {
  background: var(--primary);
  color: var(--primaryText);
}

/* 2.4.1: the hint (i) a bit stronger in the NEXUS / Lavender themes (WCAG 3:1 for a small control) */
:is([data-theme="nexus"], [data-theme="nexuslight"], [data-theme="lavender"]) .sbh-i {
  opacity: 0.72;
}
/* 2.4.1 PRINT in the dark themes: paper is white → dark text, white cards (payroll, reports, lists printed from the screen) */
@media print {
  :is([data-theme="nexus"], [data-theme="lavender"]) {
    --bg: #ffffff;
    --bg2: #f3f4f6;
    --card: #ffffff;
    --text: #111827;
    --muted: #4b5563;
    --line: #d1d5db;
    --primary: #0b263a;
    --primary2: #173d55;
    --primaryText: #ffffff;
    --ok: #166534;
    --okBg: #e6f3ea;
    --warn: #8a5200;
    --warnBg: #fff3df;
    --bad: #b3261e;
    --badBg: #fbecea;
    --info: #0b5f8a;
    --infoBg: #e3f1fa;
    color-scheme: light;
  }
  :is([data-theme="nexus"], [data-theme="lavender"]) body {
    background: #ffffff !important;
    color: #111827;
  }
}

/* 2.6.2 date boxes day first (dd/mm/yyyy) on a month-first browser — see web/js/core/ui.js (html.sbdmy). The real value is unchanged. */
html.sbdmy input[type="date"]:not(:focus) {
  position: relative;
}
html.sbdmy input[type="date"]:not(:focus)::-webkit-datetime-edit {
  color: transparent;
}
html.sbdmy input[type="date"]:not(:focus)::before {
  content: attr(data-dmy);
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  padding: inherit;
  padding-inline-end: 0;
  direction: ltr;
  unicode-bidi: isolate;
  pointer-events: none;
  white-space: nowrap;
}
html.sbdmy[dir="rtl"] input[type="date"]:not(:focus)::before {
  justify-content: flex-end;
}
html.sbdmy input[type="date"].sbdmy-empty:not(:focus)::before {
  opacity: 0.55;
}

/* 2.7.3: "Close without saving?" box (core modal) */
.sb-ask-back { position: fixed; inset: 0; z-index: 2000; background: rgba(6, 12, 30, 0.45); display: flex; align-items: center; justify-content: center; padding: 16px; }
.sb-ask { background: var(--card, #fff); color: var(--text, #0B263A); border-radius: 18px; padding: 18px 18px 14px; width: 360px; max-width: 100%; box-shadow: 0 24px 60px rgba(0, 0, 0, 0.35); }
.sb-ask b { font-size: 17px; display: block; } .sb-ask p { margin: 6px 0 14px; color: var(--muted, #5F6E7C); font-size: 14px; }
.sb-ask-bar { display: flex; gap: 8px; justify-content: flex-end; flex-wrap: wrap; }
/* 2.7.3: "Changes not saved yet — Save" bar (web/js/hr/x273-save.js) + "Saved automatically" note */
.sb-savebar { position: fixed; left: 50%; transform: translateX(-50%); bottom: calc(16px + env(safe-area-inset-bottom)); z-index: 850; display: flex; align-items: center; gap: 12px; background: var(--card, #fff); color: var(--text, #0B263A); border: 1px solid var(--line, #e2e6ef); border-inline-start: 4px solid var(--warn, #C99A35); border-radius: 14px; padding: 8px 10px 8px 14px; box-shadow: 0 12px 34px rgba(0, 0, 0, 0.18); font-weight: 700; font-size: 14px; max-width: calc(100vw - 32px); }
.sb-savebar.hidden { display: none; }
.sb-autosave { margin: 2px 0 8px; color: var(--ok, #0B7A3E); font-weight: 600; }
/* 2.9.6 item 10: hint = one short line + small example + More ▸ */
.sbh-pop .sbh-ex{margin-top:6px;padding:6px 8px;border-radius:8px;background:rgba(255,215,106,.14);color:#ffe9a8;font-size:12.5px;line-height:1.45}
.sbh-pop .sbh-rest{margin-top:6px;font-size:12.5px;opacity:.9;line-height:1.45}
.sbh-pop .sbh-links{display:flex;gap:14px;flex-wrap:wrap;margin-top:6px}
.sbh-pop .sbh-more2{font-weight:700;color:#9cc2ff;text-decoration:none}
.sbh-pop .sbh-links .sbh-more{margin-top:0}
/* 2.9.6 item 11: big enough buttons on a phone (thumb size) on every page */
@media (max-width: 640px) {
  #pg .btn:not(.sm) { min-height: 42px; }
  #pg .btn.sm { min-height: 34px; }
}
