/* Staff Leave (js/staffleave/*.js). Prefix stl- (sl- is the Student leave module, css/att-leave.css, whose shared pieces are reused:
   .sl-back, .sl-icon-btn, .sl-type-tab/.sl-badge, .sl-actions/.sl-act, .sl-sort, .sl-bar, .sl-files, .sl-d-* detail, .sl-week/.sl-day).
   Home 22316:151836 · Pending list 149749 / 150626 / 150871 · Select 148085 / 148308 · sheets 147659 / 147872 · dialogs 148540 / 148776 ·
   snackbar 150040 · detail 152389 / 152134 / 152312 / 152235 · Leave Applications 149012 / 149180 / 149408. */

.stl [hidden] { display: none !important; }
.stl-head { display: flex; align-items: center; gap: 8px; height: 40px; }
.stl-head h1 { flex: 1; min-width: 0; }

/* ---------- Home (151836) ---------- */
.screen.stl-home { background: var(--goku); }
.stl-home-page { display: flex; flex-direction: column; gap: 24px; padding: calc(var(--sb-dash) + 24px) 20px 24px; }
.stl-star { flex: none; width: 40px; height: 40px; display: grid; place-items: center; border-radius: 8px; }
.stl-star:hover { background: var(--heles); }
.stl-card-sec { background: var(--gohan); border-radius: var(--radius-s-sm); overflow: hidden; }
.stl-sec-head { display: flex; align-items: center; gap: 12px; padding: 12px; }
.stl-sec-title { flex: 1; min-width: 0; display: flex; align-items: center; gap: 8px; font: 700 16px/24px var(--font); color: var(--bulma); white-space: nowrap; }
.stl-semi { font-weight: 600; }
.stl-viewall { flex: none; border-radius: 4px; font: 700 16px/24px var(--font); color: var(--piccolo); white-space: nowrap; }
.stl-viewall:hover { text-decoration: underline; }
.stl-count {
  flex: none; display: grid; place-items: center; min-width: 20px; max-width: 34px; height: 20px; padding: 0 4px; border-radius: 100px;
  background: var(--piccolo); font: 500 12px/16px var(--font); color: var(--gohan); text-align: center;
}
.stl-tiles { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; padding: 8px 12px 16px; }
.stl-tile {
  display: flex; align-items: center; justify-content: space-between; gap: 8px; min-height: 72px; padding: 8px 24px;
  border-radius: var(--radius-i-md); background: var(--goku); font: 700 16px/24px var(--font); color: var(--bulma); text-align: left;
}
.stl-tile:hover { background: #EDEDED; }
.stl-avs { display: flex; flex-wrap: wrap; gap: 8px; padding: 8px; }
.stl-av-item { width: 83.5px; display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 8px; border-radius: 8px; text-align: center; }
.stl-av-item:hover { background: var(--heles); }
.stl-av-stack { display: flex; flex-direction: column; align-items: center; }
.stl-av-circle {
  width: 48px; height: 48px; margin-bottom: -4px; display: grid; place-items: center; border: 1.5px solid var(--beerus); border-radius: 50%;
  background: var(--goku); font: 700 18px/24px var(--font); color: var(--bulma);
}
.stl-pill {
  position: relative; width: 64px; padding: 0 2px; border-radius: 8px; background: var(--raditz); overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  font: 700 10px/16px var(--font); letter-spacing: 0.5px; text-transform: uppercase; color: var(--gohan);
}
.stl-pill.perm { background: var(--hit); }
.stl-av-name { width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font: 700 10px/16px var(--font); color: var(--bulma); }
.stl-av-sub { width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font: 400 10px/16px var(--font); color: var(--zeno); }
.stl-none { padding: 4px 8px 8px; font: 400 14px/20px var(--font); color: var(--trunks); }

/* ---------- Request card (149749) ---------- */
.stl-card { display: flex; flex-direction: column; border: 1px solid var(--beerus); border-radius: 8px; background: var(--gohan); overflow: hidden; }
.stl-card.is-on { border-color: var(--piccolo); background: linear-gradient(var(--jiren), var(--jiren)), var(--gohan); }
.stl-card-main { width: 100%; display: flex; flex-direction: column; gap: 12px; padding: 12px 4px; text-align: left; }
.stl-card-main:hover { background: rgba(0, 0, 0, 0.012); }
.stl-card-top { display: flex; align-items: center; gap: 12px; padding: 0 8px; }
.stl-av { flex: none; width: 40px; height: 40px; border-radius: 50%; object-fit: cover; }
.stl-picked { flex: none; width: 40px; height: 40px; display: grid; place-items: center; border-radius: 50%; background: var(--piccolo); }
.stl-who { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.stl-name { font: 700 16px/24px var(--font); color: var(--bulma); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.stl-sub { font: 400 12px/16px var(--font); color: #5D626C; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.stl-sub.wrap { white-space: normal; }
.stl-when { flex: none; align-self: flex-start; font: 400 12px/16px var(--font); color: var(--trunks); white-space: nowrap; }
.stl-box { display: flex; align-items: flex-start; gap: 4px; padding: 12px; border-radius: 8px; background: var(--heles); }
.stl-box-l { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.stl-type { font: 700 12px/16px var(--font); color: var(--bulma); }
.stl-range { font: 400 12px/16px var(--font); color: #5D626C; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.stl-type sup, .stl-app-type sup { font-size: 7.74px; line-height: 0; vertical-align: 4px; }
.stl-box-r { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; align-items: flex-end; text-align: right; font: 400 12px/16px var(--font); color: #5D626C; }
.stl-reason { flex: 1; min-width: 0; padding: 0 8px; font: 400 12px/16px var(--font); color: var(--trunks); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.stl-att { flex: none; align-self: flex-start; display: flex; align-items: center; gap: 4px; font: 400 12px/16px var(--font); color: var(--piccolo); border-radius: 4px; cursor: pointer; white-space: nowrap; }
.stl-att u { text-underline-position: from-font; }

/* ---------- Pending Applications list ---------- */
.screen.stl-list { background: var(--goku); }
.stl-page { display: flex; flex-direction: column; min-height: 100%; padding: calc(var(--sb-dash) + 12px) 20px 20px; }
.stl-search { margin: 12px 0 0; }
.stl-search input { font-weight: 400; }
.stl-types { gap: 8px; margin: 0 -20px; padding: 12px 20px; scroll-snap-type: none; }
.stl-panel { flex: 1; display: flex; flex-direction: column; gap: 16px; padding-bottom: 12px; border-radius: 8px; background: var(--gohan); }
.stl-seg { display: flex; border-radius: 8px 8px 0 0; overflow: hidden; }
.stl-seg-tab {
  flex: 1; min-width: 0; display: flex; align-items: center; justify-content: center; gap: 8px; padding: 12px;
  border-bottom: 2px solid; font: 700 14px/24px var(--font); white-space: nowrap;
}
.stl-seg-tab.pending { color: var(--piccolo); border-color: var(--piccolo); }
.stl-seg-tab.approved { color: var(--roshi); border-color: var(--roshi); }
.stl-seg-tab.rejected { color: var(--dodoria); border-color: var(--dodoria); }
.stl-seg-tab.is-on { color: var(--gohan); }
.stl-seg-tab.pending.is-on { background: var(--piccolo); }
.stl-seg-tab.approved.is-on { background: var(--roshi); }
.stl-seg-tab.rejected.is-on { background: var(--dodoria); }
.stl-seg-tab:not(.is-on):hover { background: var(--heles); }
.stl-seg-badge { min-width: 16px; max-width: 34px; padding: 0 4px; border-radius: 100px; background: var(--piccolo); font: 500 12px/16px var(--font); color: var(--gohan); text-align: center; }
.stl-seg-tab.is-on .stl-seg-badge { background: var(--gohan); color: var(--piccolo); }
.stl-sort-slot:empty { display: none; }
.stl-sortrow { display: flex; align-items: center; justify-content: space-between; gap: 12px; height: 24px; padding: 0 12px; }
.stl-sortrow .sl-sort { align-self: stretch; }
.stl-link { flex: none; border-radius: 4px; font: 400 16px/24px var(--font); color: var(--piccolo); white-space: nowrap; }
.stl-link:hover { text-decoration: underline; }
.stl-cards { display: flex; flex-direction: column; gap: 16px; padding: 0 12px; }

/* ---------- Select multiple (148085 / 148308) ---------- */
.screen.stl-select { display: flex; flex-direction: column; overflow: hidden; background: var(--goku); }
.stl-sel-top { flex: none; background: var(--gohan); }
.stl-sel-head { display: flex; align-items: center; gap: 16px; min-height: 58px; padding: calc(var(--sb-dash) + 8px) 20px 8px; }
.stl-sel-head h1 { flex: 1; min-width: 0; }
.stl-sel-tools { padding: 8px 8px 12px; }
.stl-sel-body { flex: 1; min-height: 0; overflow-y: auto; scrollbar-width: none; padding: 16px 20px 12px; }
.stl-sel-body::-webkit-scrollbar { display: none; }
.stl-sel-list { display: flex; flex-direction: column; gap: 16px; }
.stl-bar { display: flex; flex-direction: column; gap: 12px; }
.stl-bar-comment { display: flex; align-items: center; height: 56px; padding: 0 16px; border-radius: 8px; background: var(--goku); cursor: text; }
.stl-bar-comment input { flex: 1; min-width: 0; border: 0; outline: 0; background: transparent; font: 400 16px/24px var(--font); color: var(--bulma); }
.stl-bar-comment input::placeholder { color: var(--trunks); }
.stl-bar-comment:focus-within { box-shadow: inset 0 0 0 1px var(--piccolo); }
.stl-bar .home-indicator { margin-top: -12px; }

/* ---------- Approve / Reject sheet (147659 / 147872) ---------- */
.stl-sheet-comment { display: flex; flex-direction: column; gap: 10px; margin-top: -8px; }
.stl-comment {
  position: relative; display: block; height: 84px; border: 1px solid var(--beerus); border-radius: var(--radius-s-sm); background: var(--gohan); overflow: hidden; cursor: text;
}
.stl-comment:focus-within { border-color: var(--piccolo); }
.stl-comment-label { position: absolute; left: 15px; top: 11px; font: 400 12px/12px var(--font); color: var(--trunks); opacity: 0; pointer-events: none; }
.stl-comment textarea {
  width: 100%; height: 100%; padding: 15px 15px 8px; border: 0; outline: 0; resize: none; background: transparent;
  font: 400 16px/24px var(--font); color: var(--bulma);
}
.stl-comment textarea::placeholder { color: var(--trunks); }
.stl-comment.is-filled .stl-comment-label { opacity: 1; }
.stl-comment.is-filled textarea { padding-top: 26px; }
.stl-quick { gap: 10px; margin: 0 -20px; padding: 0 20px; scroll-snap-type: none; }
.stl-quick-chip {
  height: 32px; padding: 4px 8px; border: 1px solid var(--beerus); border-radius: var(--radius-full); white-space: nowrap;
  font: 700 14px/24px var(--font); color: var(--trunks);
}
.stl-quick-chip:hover { background: var(--heles); }
.stl-quick-chip.is-on { border-color: var(--piccolo); background: var(--jiren); color: var(--piccolo); }

/* ---------- Confirm dialog (148540 / 148776) ---------- */
.stl-alert-layer { position: absolute; inset: 0; z-index: 60; display: grid; place-items: center; }
.stl-alert-scrim { position: absolute; inset: 0; background: var(--zeno); animation: fade-in .2s ease-out both; }
.stl-alert { position: relative; width: 312px; border-radius: 14px; background: var(--gohan); overflow: hidden; text-align: center; animation: fade-in .15s ease-out both; }
.stl-alert-body { display: flex; flex-direction: column; gap: 8px; padding: 24px 24px 20px; }
.stl-alert-body h2 { font: 400 22px/28px var(--font); color: var(--bulma); }
.stl-alert-body p { font: 400 14px/20px var(--font); color: var(--trunks); }
.stl-alert-btn { display: block; width: 100%; height: 56px; border-top: 1px solid var(--beerus); font: 700 16px/24px var(--font); color: var(--trunks); }
.stl-alert-btn.reject { color: var(--dodoria); }
.stl-alert-btn.approve { color: var(--roshi); }
.stl-alert-btn:hover { background: var(--heles); }

/* ---------- Snackbar with UNDO (150327) ---------- */
.stl-snack {
  position: absolute; left: 16px; right: 16px; bottom: 20px; z-index: 80; display: flex; align-items: center; gap: 16px; padding: 16px 20px;
  border-radius: var(--radius-s-sm); background: #1F1F1F; box-shadow: var(--shadow-snackbar); animation: fade-in .2s ease-out both;
}
.stl-snack.is-leaving { animation: fade-out .2s ease-in both; }
.stl-snack-text { flex: 1; min-width: 0; font: 400 14px/20px var(--font); color: #FFFFFF; }
.stl-snack-undo { flex: none; padding: 0 2px; border-radius: 4px; font: 700 14px/24px var(--font); color: #8B85E6; }
.stl-snack-undo:hover { background: rgba(255, 255, 255, 0.08); }

/* ---------- Request detail (152389 …) ---------- */
.stl-more { width: 40px; height: 40px; }
.sl-banner.stl-wait { background: var(--krillin-10); color: var(--bulma); }
.stl-verdict { display: flex; flex-direction: column; gap: 8px; padding: 16px; border-radius: 8px; }
.stl-verdict.approved { background: linear-gradient(var(--roshi-10), var(--roshi-10)), var(--gohan); }
.stl-verdict.rejected { background: linear-gradient(rgba(211, 48, 48, 0.12), rgba(211, 48, 48, 0.12)), var(--gohan); }
.stl-verdict p { font: 400 14px/24px var(--font); color: var(--trunks); overflow-wrap: anywhere; }
.stl-people { display: flex; flex-direction: column; gap: 8px; }
.stl-people-h { padding: 0 8px; font: 700 16px/24px var(--font); color: var(--bulma); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.stl-people-row { display: flex; }
.stl-person { width: 80px; display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 8px; border-radius: 8px; text-align: center; }
.stl-person:hover { background: var(--heles); }
.stl-person-av {
  width: 48px; height: 48px; display: grid; place-items: center; border: 1.5px solid var(--beerus); border-radius: 50%;
  background: var(--jiren); font: 700 18px/24px var(--font); color: var(--bulma);
}
.stl-person-name { width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font: 400 12px/16px var(--font); color: var(--bulma); }
.stl-person-type { width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font: 400 10px/16px var(--font); color: var(--piccolo); }

/* ---------- Leave Applications (149012 / 149180 / 149408) ---------- */
.screen.stl-apps { background: var(--goku); }
.stl-apps-top { background: var(--gohan); }
.stl-apps-head { display: flex; align-items: center; gap: 8px; padding: calc(var(--sb-dash) + 16px) 20px 20px; }
.stl-apps-head h1 { flex: 1; min-width: 0; }
.stl-apps-search { margin: -8px 20px 12px; background: var(--goku); }
.stl-apps-body { padding: 16px 20px 24px; }
.stl-apps-panel { display: flex; flex-direction: column; gap: 24px; padding-bottom: 12px; border-radius: 8px; background: var(--gohan); }
.stl-tabs { display: flex; gap: 8px; height: 56px; border-bottom: 1px solid var(--beerus); }
.stl-tab { flex: 1; min-width: 0; margin-bottom: -1px; padding: 8px 16px; text-align: center; border-bottom: 2px solid transparent; font: 700 14px/24px var(--font); color: var(--trunks); }
.stl-tab.is-on { border-color: var(--piccolo); color: var(--piccolo); }
.stl-tab:not(.is-on):hover { background: var(--heles); }
.stl-apps-chips { gap: 4px; padding: 0 20px; scroll-snap-type: none; }
.stl-chip { border-color: transparent; background: var(--goku); }
.stl-chip.is-on, .stl-chip.is-open { border-color: var(--piccolo); }
.stl-apps-list { display: flex; flex-direction: column; gap: 8px; padding: 0 12px; }
.stl-apps-list .sl-group { padding: 0 4px; }
.stl-apps-list .sl-group ~ .sl-group { margin-top: 8px; padding: 0 16px; }
.stl-app-cards { display: flex; flex-direction: column; gap: 8px; }
.stl-app-cards .n-empty:empty { display: none; }
.stl-app { display: flex; flex-direction: column; border: 1px solid rgba(0, 0, 0, 0.25); border-radius: 8px; background: var(--gohan); overflow: hidden; }
.stl-app-main {
  display: flex; align-items: flex-start; gap: 12px; width: 100%; padding: 16px; border: 4px solid var(--gohan); border-radius: 8px;
  background: linear-gradient(var(--heles), var(--heles)), var(--gohan); background-clip: padding-box; text-align: left;
}
.stl-app-main:hover { background: linear-gradient(rgba(0, 0, 0, 0.06), rgba(0, 0, 0, 0.06)), var(--gohan); }
.stl-app-main .m-avatar { flex: none; width: 40px; height: 40px; }
.stl-app-who { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.stl-app-right { flex: none; max-width: 150px; display: flex; flex-direction: column; align-items: flex-end; gap: 4px; text-align: right; }
.stl-app-dates { display: flex; flex-direction: column; align-items: flex-end; gap: 2px; font: 400 12px/16px var(--font); color: #5D626C; white-space: nowrap; }
.stl-app-type { font: 500 12px/16px var(--font); color: var(--bulma); }
.stl-app-foot { display: flex; align-items: center; gap: 8px; padding: 8px 12px 12px; border-top: 1px solid var(--beerus); }
.stl-app-foot .stl-reason { padding: 0; }
.stl-app-foot .stl-att { align-self: center; }
