:root {
  --primary: #1e3c72;
  --primary2: #2a5298;
  --bg: #f2f5fa;
  --text: #1f2937;
  --muted: #6b7280;
  --border: #e3e8f0;
  --green: #1b8a4c;
  --orange: #e65100;
  --red: #c62828;
  --blue: #1565c0;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
body {
  font-family: 'Segoe UI', system-ui, -apple-system, Roboto, Arial, sans-serif;
  background: var(--bg); color: var(--text); font-size: 14px; line-height: 1.45;
}
button { font-family: inherit; cursor: pointer; }
input, select, textarea { font-family: inherit; font-size: 14px; }
label { display: block; font-size: 12px; font-weight: 600; color: var(--muted); margin: 12px 0 5px; }
input[type=text], input[type=password], input[type=number], select, textarea {
  width: 100%; padding: 9px 11px; border: 1px solid #cfd8e3; border-radius: 8px; background: #fff; outline: none;
}
input:focus, select:focus, textarea:focus { border-color: var(--primary2); box-shadow: 0 0 0 3px rgba(42,82,152,.12); }
textarea { resize: vertical; min-height: 60px; }

/* ===== Login ===== */
#loginPage {
  display: none; min-height: 100vh; align-items: center; justify-content: center; padding: 20px;
  background: linear-gradient(135deg, var(--primary), var(--primary2));
}
.login-box { background: #fff; width: 100%; max-width: 380px; border-radius: 16px; padding: 32px 28px; box-shadow: 0 20px 50px rgba(0,0,0,.25); }
.login-box h1 { font-size: 22px; color: var(--primary); }
.login-box .sub { color: var(--muted); font-size: 13px; margin-bottom: 18px; }
.login-box button { width: 100%; margin-top: 18px; padding: 11px; border: 0; border-radius: 8px; background: var(--primary2); color: #fff; font-weight: 700; font-size: 15px; }
.login-box button:hover { background: var(--primary); }
.login-hint { text-align: center; font-size: 12px; color: var(--muted); margin-top: 14px; }
.login-error, .form-error { display: none; background: #fdecea; color: var(--red); padding: 9px 12px; border-radius: 8px; font-size: 13px; margin-bottom: 8px; }

/* ===== Layout ===== */
#app { display: none; }
.layout { display: flex; min-height: 100vh; }
.sidebar {
  width: 260px; background: linear-gradient(180deg, #14284f, var(--primary)); color: #fff;
  position: fixed; top: 0; bottom: 0; left: 0; overflow-y: auto; z-index: 50; transition: transform .25s;
}
.brand { padding: 20px 20px 14px; border-bottom: 1px solid rgba(255,255,255,.12); }
.brand h2 { font-size: 19px; }
.brand span { font-size: 12px; opacity: .7; }
.nav-title { font-size: 11px; text-transform: uppercase; letter-spacing: 1px; opacity: .55; padding: 16px 20px 6px; }
.nav-item {
  display: flex; align-items: center; justify-content: space-between; gap: 8px;
  padding: 10px 20px; cursor: pointer; font-size: 13.5px; border-left: 3px solid transparent;
}
.nav-item:hover { background: rgba(255,255,255,.08); }
.nav-item.active { background: rgba(255,255,255,.16); border-left-color: #ffca28; font-weight: 600; }
.nav-item .badge,
.nav-group-meta .badge { background: rgba(255,255,255,.2); border-radius: 10px; padding: 1px 8px; font-size: 11px; }

/* ===== Sidebar Groups & Departments ===== */
.sidebar-groups {
  margin-top: 8px;
  padding-bottom: 24px;
  border-top: 1px solid rgba(255,255,255,.1);
}
.nav-group {
  border-bottom: 1px solid rgba(255,255,255,.08);
}
.nav-group-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 12px 16px 10px 20px;
  font-size: 11.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.7px;
  color: rgba(255,255,255,.85);
  cursor: pointer;
  user-select: none;
  transition: background .15s;
}
.nav-group-header:hover {
  background: rgba(255,255,255,.07);
}
.nav-group-label {
  display: flex;
  align-items: center;
  gap: 6px;
}
.nav-group-meta {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.nav-chevron {
  font-size: 11px;
  opacity: .75;
  transition: transform .18s ease;
  display: inline-block;
  transform: rotate(-90deg);
}
.nav-group.is-open > .nav-group-header .nav-chevron,
.nav-dept.is-open > .nav-dept-header .nav-chevron {
  transform: rotate(0deg);
}
.nav-group-body {
  display: none;
  padding-bottom: 6px;
}
.nav-group.is-open > .nav-group-body {
  display: block;
}
.nav-dept-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 8px 16px 8px 24px;
  font-size: 13px;
  font-weight: 600;
  color: #e2e8f0;
  cursor: pointer;
  user-select: none;
  transition: background .15s;
}
.nav-dept-header:hover {
  background: rgba(255,255,255,.08);
}
.nav-dept.is-open > .nav-dept-header {
  background: rgba(255,255,255,.06);
  color: #ffca28;
}
.nav-dept-label {
  display: flex;
  align-items: center;
  gap: 7px;
}
.nav-dept-dot {
  font-size: 14px;
  line-height: 1;
  opacity: .75;
}
.nav-group-meta .badge-sub {
  background: rgba(255,255,255,.14);
  color: rgba(255,255,255,.9);
  font-size: 10.5px;
  padding: 1px 7px;
}
.nav-dept-body {
  display: none;
  background: rgba(0,0,0,.14);
}
.nav-dept.is-open > .nav-dept-body {
  display: block;
}
.nav-folder-item {
  padding: 8px 16px 8px 34px;
  font-size: 12.8px;
  color: rgba(255,255,255,.9);
}
.main { margin-left: 260px; flex: 1; min-width: 0; }
.topbar {
  position: sticky; top: 0; z-index: 40; background: #fff; border-bottom: 1px solid var(--border);
  display: flex; align-items: center; justify-content: space-between; padding: 12px 24px; gap: 12px; flex-wrap: wrap;
}
.topbar h2 { font-size: 18px; color: var(--primary); }
.menu-toggle { display: none; background: none; border: 0; font-size: 22px; }
.user-info { display: flex; align-items: center; gap: 10px; font-size: 13px; }
.avatar { width: 34px; height: 34px; border-radius: 50%; background: var(--primary2); color: #fff; display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: 13px; }
.content { padding: 24px; }

@media (max-width: 900px) {
  .it-summary-cards { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .sidebar { transform: translateX(-100%); }
  .sidebar.open { transform: none; box-shadow: 0 0 30px rgba(0,0,0,.4); }
  .main { margin-left: 0; }
  .menu-toggle { display: inline-block; }
  .content { padding: 14px; }
  .topbar { padding: 10px 14px; }
}

/* ===== Buttons ===== */
.btn { border: 1px solid transparent; border-radius: 8px; padding: 9px 16px; font-weight: 600; font-size: 13px; transition: .15s; }
.btn-sm { padding: 5px 10px; font-size: 12px; }
.btn-primary { background: var(--primary2); color: #fff; }
.btn-primary:hover { background: var(--primary); }
.btn-ghost { background: #fff; color: var(--primary2); border-color: #cfd8e3; }
.btn-ghost:hover { background: #eef2f9; }
.btn-danger { background: #fdecea; color: var(--red); border-color: #f5c6c2; }
.btn-danger:hover { background: #f8d7d3; }
.btn-success { background: #e6f4ea; color: var(--green); border-color: #b9e0c5; }

/* ===== Cards & tables ===== */
.card-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 16px; margin-bottom: 20px; }
.card { background: #fff; border-radius: 12px; padding: 18px 20px; box-shadow: 0 1px 4px rgba(16,24,40,.07); }
.card .lbl { font-size: 12px; color: var(--muted); text-transform: uppercase; letter-spacing: .5px; }
.card .val { font-size: 28px; font-weight: 800; color: var(--primary); margin-top: 4px; }
.card .sub { font-size: 12px; color: var(--muted); margin-top: 2px; }
.it-summary-cards { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; margin-bottom: 20px; }
.it-summary-cards .card { min-width: 0; }
.it-summary-cards .card .val { overflow-wrap: anywhere; }
.it-summary-cards .pred { margin-top: 3px; }
.it-kpi-table-wrap { padding: 20px 24px; }
.it-kpi-table-wrap h3 { margin-bottom: 16px; font-size: 16px; color: #172b4d; }
.it-kpi-table { min-width: 760px; }
.it-kpi-table th { background: #f3f5f8; color: #46566b; }
.it-kpi-table td:first-child { min-width: 330px; }
.it-kpi-table td:not(:first-child) { white-space: nowrap; }
.it-score-good { color: #17834d; }
.it-score-warn { color: #d38b18; }
.it-score-bad { color: #c52b2b; }
.it-muted { color: #98a2b3; }
.it-status { display: inline-flex; align-items: center; gap: 7px; padding: 5px 12px; border-radius: 999px; font-size: 11px; font-weight: 800; white-space: nowrap; }
.it-status::before { content: ''; width: 10px; height: 10px; border-radius: 50%; background: currentColor; }
.it-status-good { color: #17834d; background: #e6f4ea; }
.it-status-warn { color: #a76400; background: #fff3dc; }
.it-status-bad { color: #c52b2b; background: #fde9e8; }
.it-formulas { margin-top: 14px; padding: 12px 16px; border: 1px solid var(--border); border-radius: 8px; background: #fff; color: #46566b; font-size: 13px; }
.it-formulas summary { cursor: pointer; font-weight: 700; color: var(--primary); }
.it-formulas ul { display: grid; gap: 8px; padding-left: 20px; margin: 12px 0 2px; }
.it-formulas li { line-height: 1.5; }
.it-source-form { min-width: 0; }
.it-source-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 12px; }
.it-source-heading h4 { margin: 0 0 4px; color: var(--primary); }
.it-source-heading p { margin: 0; color: var(--muted); font-size: 12px; }
.it-source-summary { margin: 14px 0; padding: 14px; border: 1px solid var(--border); border-radius: 10px; background: #f9fbfe; }
.it-source-summary h5 { margin-bottom: 10px; color: var(--primary); font-size: 13px; }
.it-source-metrics { display: grid; grid-template-columns: repeat(auto-fit, minmax(135px, 1fr)); gap: 8px; }
.it-source-metric { min-width: 0; padding: 10px 12px; border: 1px solid var(--border); border-radius: 8px; background: #fff; }
.it-source-metric span, .it-source-metric b { display: block; }
.it-source-metric span { color: var(--muted); font-size: 11px; }
.it-source-metric b { margin-top: 3px; color: var(--primary); font-size: 17px; font-variant-numeric: tabular-nums; }
.it-bulk-paste { margin: 12px 0; padding: 12px; border: 1px dashed #a9bad1; border-radius: 8px; background: #f9fbfe; }
.it-bulk-paste[hidden] { display: none; }
.it-bulk-paste label { margin-top: 0; }
.it-bulk-paste textarea { min-height: 90px; margin-bottom: 8px; font-family: ui-monospace, Consolas, monospace; font-size: 12px; }
.it-source-tools { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin: 8px 0; color: var(--muted); font-size: 12px; }
.it-source-tools input { width: min(100%, 260px); padding: 7px 10px; }
.it-source-scroll { max-width: 100%; overflow: auto; border: 1px solid var(--border); border-radius: 8px; }
.it-source-table, .it-log-table { width: max-content; min-width: 100%; border-collapse: separate; border-spacing: 0; }
.it-source-table th, .it-log-table th { position: sticky; top: 0; z-index: 1; background: #f3f5f8; }
.it-source-table td, .it-log-table td { min-width: 135px; padding: 7px; }
.it-source-table td .cell-input, .it-log-table td .cell-input { min-width: 120px; }
.it-source-table td .cell-input:disabled, .it-log-table td .cell-input:disabled { background: #f6f7f9; color: #596579; }
.it-information-table { min-width: 2100px; }
.it-information-table td { max-width: 280px; white-space: normal; line-height: 1.45; }
.it-cell-formula { margin-top: 4px; color: var(--muted); font: 10px/1.35 ui-monospace, Consolas, monospace; overflow-wrap: anywhere; }
.it-log-table { min-width: 1100px; }
.it-log-table td { min-width: 105px; }
.it-log-table td:first-child { position: sticky; left: 0; z-index: 1; background: #fff; }
.it-log-table th:first-child { position: sticky; left: 0; z-index: 2; }
.it-formula-note { margin-top: 12px; color: var(--muted); font-size: 12px; }
.it-method-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.it-method-grid .raw-form { min-width: 0; }
.it-method-grid h4 { color: var(--primary); margin-bottom: 10px; }
.it-method-table { width: 100%; }
.it-method-table th { text-align: left; }
.it-method-table td { font-size: 13px; }
.it-dashboard { padding: 18px 20px; }
.it-dashboard-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin-bottom: 14px; flex-wrap: wrap; }
.it-dashboard-heading h3 { color: var(--primary); font-size: 16px; }
.it-dashboard-heading p { margin-top: 3px; color: var(--muted); font-size: 12px; }
.it-dashboard-score { display: flex; align-items: center; gap: 10px; margin-bottom: 14px; padding: 12px 14px; border-radius: 8px; background: #f3f6fb; flex-wrap: wrap; }
.it-dashboard-score > span:first-child { color: var(--muted); font-size: 12px; }
.it-dashboard-score strong { color: var(--primary); font-size: 22px; }

/* Diagram Ringkasan KPI Semua Divisi & Kuartal (Q1-Q4) di Dashboard */
.dash-grade-pills { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.dash-grade-pills .pred { font-size: 11px; padding: 3px 9px; min-width: 0; }
.dash-bars-wrap { display: flex; flex-direction: column; gap: 8px; }
.dash-bar-row { display: grid; grid-template-columns: 220px 1fr 125px; align-items: center; gap: 12px; padding: 8px 12px; border: 1px solid #e6ebf2; border-radius: 10px; background: #fcfdff; cursor: pointer; transition: background .15s, border-color .15s, transform .1s; }
.dash-bar-row:hover { background: #f2f7ff; border-color: #b9d0f0; }
.dash-bar-name { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; min-width: 0; }
.dash-bar-name b { font-size: 13px; color: #1e293b; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dash-bar-name small { font-size: 11px; color: #64748b; white-space: nowrap; }
.dash-bar-track { position: relative; height: 18px; border-radius: 999px; background: #eef2f7; overflow: hidden; border: 1px solid #e2e8f0; }
.dash-bar-gridline { position: absolute; top: 0; bottom: 0; width: 1px; background: rgba(15, 23, 42, .12); z-index: 1; pointer-events: none; }
.dash-bar-fill { height: 100%; border-radius: inherit; transition: width .3s ease; }
.dash-bar-val { display: flex; align-items: center; justify-content: flex-end; gap: 8px; font-variant-numeric: tabular-nums; }
.dash-bar-val strong { font-size: 13.5px; color: var(--primary); }
.dash-bar-val .pred { font-size: 11px; padding: 2px 8px; min-width: 30px; }

.dash-q-tabs { display: flex; flex-wrap: wrap; gap: 6px; }
.dash-q-tab { border: 1px solid #d0d8e5; border-radius: 8px; background: #fff; color: #475467; padding: 6px 12px; font-size: 12px; font-weight: 700; cursor: pointer; transition: all .15s; }
.dash-q-tab:hover { background: #f3f6fb; border-color: #a9bad1; }
.dash-q-tab.active { background: var(--primary2); border-color: var(--primary2); color: #fff; }
.dash-q-cards { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin-bottom: 16px; }
.dash-q-card { padding: 14px 16px; border: 1px solid #e3e8f0; border-radius: 10px; background: #fbfcfe; cursor: pointer; transition: all .15s; display: flex; flex-direction: column; gap: 6px; }
.dash-q-card:hover { border-color: #aac2e6; background: #f4f8ff; }
.dash-q-card.is-selected { border-color: var(--primary2); background: #eef5ff; box-shadow: 0 0 0 2px rgba(42, 82, 152, .15); }
.dash-q-card-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.dash-q-card-top b { font-size: 12.5px; color: #334155; }
.dash-q-badge { display: inline-block; padding: 2px 7px; border-radius: 6px; background: #e0ebff; color: var(--primary2); font-size: 11px; font-weight: 800; margin-right: 4px; }
.dash-q-card-val { font-size: 24px; font-weight: 800; font-variant-numeric: tabular-nums; }
.dash-q-card-meta { font-size: 11px; color: #64748b; }
.dash-q-table td:first-child { min-width: 210px; }
.dash-q-cell { display: inline-flex; align-items: center; gap: 6px; font-variant-numeric: tabular-nums; }
.dash-q-cell .pred { font-size: 10.5px; padding: 2px 7px; min-width: 26px; }
.dash-q-minibars { display: inline-flex; align-items: flex-end; gap: 8px; height: 42px; padding: 2px 4px; }
.dash-q-minibar-col { display: flex; flex-direction: column; align-items: center; gap: 2px; }
.dash-q-minibar { width: 16px; border-radius: 4px 4px 2px 2px; display: block; }
.dash-q-minibar-col small { font-size: 10px; color: #64748b; font-weight: 700; }
.dash-q-detail-head { display: flex; align-items: baseline; justify-content: space-between; flex-wrap: wrap; gap: 6px 12px; margin-bottom: 10px; }
.dash-q-detail-head h4 { color: var(--primary); font-size: 14.5px; margin: 0; }
.dash-q-detail-head span { color: var(--muted); font-size: 12px; }
@media (max-width: 820px) {
  .dash-bar-row { grid-template-columns: 1fr; gap: 6px; }
  .dash-bar-val { justify-content: space-between; }
  .dash-q-cards { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
.table-wrap { background: #fff; border-radius: 12px; box-shadow: 0 1px 4px rgba(16,24,40,.07); margin-bottom: 20px; overflow-x: auto; }
table { width: 100%; border-collapse: collapse; }
th { background: #f3f6fb; color: var(--muted); font-size: 12px; text-transform: uppercase; letter-spacing: .4px; text-align: left; padding: 10px 12px; white-space: nowrap; }
td { padding: 10px 12px; border-top: 1px solid var(--border); vertical-align: middle; }
tbody tr:hover { background: #fafcff; }
.mini-table th, .mini-table td, .trend-table th, .trend-table td, .pen-table th, .pen-table td, .users-table th, .users-table td { font-size: 13px; }
.empty { text-align: center; color: #9aa5b5; padding: 28px 10px; font-size: 13px; }
.cell-input { width: 100%; min-width: 90px; padding: 6px 8px; border: 1px solid #cfd8e3; border-radius: 6px; }
.num { text-align: right; font-variant-numeric: tabular-nums; }

.sheet-header { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin-bottom: 16px; flex-wrap: wrap; }
.sheet-header h3 { font-size: 19px; color: var(--primary); }
.sheet-header p { color: var(--muted); font-size: 13px; margin-top: 2px; }
.toolbar { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }

.tabs { display: flex; gap: 4px; border-bottom: 2px solid var(--border); margin-bottom: 18px; overflow-x: auto; }
.tab { background: none; border: 0; padding: 10px 16px; font-weight: 600; color: var(--muted); border-bottom: 3px solid transparent; margin-bottom: -2px; white-space: nowrap; }
.tab:hover { color: var(--primary2); }
.tab.active { color: var(--primary2); border-bottom-color: var(--primary2); }
.tabs .tab.tab-type-Independent { background: #f3faf4; color: #1f7a42; border-top: 3px solid #2e9d57; border-radius: 8px 8px 0 0; }
.tabs .tab.tab-type-Independent:hover { background: #e6f5ea; color: #166534; }
.tabs .tab.tab-type-Independent.active { background: #e8f5e9; color: #14532d; border-bottom-color: #2e9d57; }
.tabs .tab.tab-type-Aligned { background: #f9f2fb; color: #7b1fa2; border-top: 3px solid #8e3bb5; border-radius: 8px 8px 0 0; }
.tabs .tab.tab-type-Aligned:hover { background: #f3e5f5; color: #6a1b9a; }
.tabs .tab.tab-type-Aligned.active { background: #f3e5f5; color: #4a148c; border-bottom-color: #8e3bb5; }
.tabs .tab.tab-type-Shared { background: #eef6fd; color: #1d5fa8; border-top: 3px solid #2a6fc0; border-radius: 8px 8px 0 0; }
.tabs .tab.tab-type-Shared:hover { background: #e3f2fd; color: #154d8c; }
.tabs .tab.tab-type-Shared.active { background: #e3f2fd; color: #0d3b6e; border-bottom-color: #2a6fc0; }

/* ===== Badges / tags ===== */
.type-tag { display: inline-block; padding: 2px 9px; border-radius: 10px; font-size: 11px; font-weight: 700; white-space: nowrap; }
.type-Shared { background: #e3f2fd; color: var(--blue); }
.type-Aligned { background: #f3e5f5; color: #7b1fa2; }
.type-Independent { background: #e8f5e9; color: var(--green); }

/* Pembeda warna baris KPI per tipe (tab KPI IT) */
.kpi-type-legend { display: flex; flex-wrap: wrap; gap: 8px 18px; margin: 4px 0 12px; font-size: 12px; color: #596579; }
.kpi-type-legend-item { display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px 4px 6px; border-radius: 8px; border-left: 4px solid transparent; }
.kpi-type-row:hover td { filter: brightness(0.97); }
.kpi-type-row td:first-child { border-left: 5px solid transparent; }
.kpi-type-Independent.kpi-type-legend-item, .kpi-type-row.kpi-type-Independent td { background: #f3faf4; }
.kpi-type-Independent.kpi-type-legend-item, .kpi-type-row.kpi-type-Independent td:first-child { border-left-color: #2e9d57; }
.kpi-type-Aligned.kpi-type-legend-item, .kpi-type-row.kpi-type-Aligned td { background: #f9f2fb; }
.kpi-type-Aligned.kpi-type-legend-item, .kpi-type-row.kpi-type-Aligned td:first-child { border-left-color: #8e3bb5; }
.kpi-type-Shared.kpi-type-legend-item, .kpi-type-row.kpi-type-Shared td { background: #eef6fd; }
.kpi-type-Shared.kpi-type-legend-item, .kpi-type-row.kpi-type-Shared td:first-child { border-left-color: #2a6fc0; }

/* Grafik Log Per Bulan IT & Form Input Cepat */
.it-chart-stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(185px, 1fr)); gap: 10px; margin: 6px 0 14px; }
.it-chart-stat { display: flex; flex-direction: column; gap: 3px; padding: 10px 14px; border: 1px solid #e3e7ee; border-radius: 10px; background: #fbfcfe; }
.it-chart-stat > span { font-size: 12px; color: #6b7587; }
.it-chart-stat > b { font-size: 20px; display: flex; align-items: center; gap: 8px; }
.it-chart-stat small { font-size: 12px; color: #6b7587; }
.it-trend { font-size: 12px; font-weight: 700; }
.it-trend.up { color: #17834d; }
.it-trend.down { color: #c52b2b; }
.it-trend.flat { color: #6b7587; }
.it-chart-band-legend { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; padding: 6px 10px 8px; font-size: 11.5px; color: #596579; }
.it-chart-band-legend .pred { font-size: 11px; padding: 2px 8px; min-width: 0; }
.it-chart-wrap { position: relative; border: 1px solid #e3e7ee; border-radius: 10px; background: #fff; padding: 6px; }
.it-chart-svg { display: block; width: 100%; height: auto; }
.it-chart-grid { stroke: rgba(0, 0, 0, .08); stroke-width: 1; }
.it-chart-axis { font-size: 12px; fill: #6b7587; }
.it-chart-band-label { font-size: 11px; font-weight: 800; }
.it-chart-value { font-size: 11px; font-weight: 700; fill: #1f3c88; paint-order: stroke; stroke: #fff; stroke-width: 3px; }
.it-chart-empty { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; color: #8a93a3; font-weight: 600; }
.it-month-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(135px, 1fr)); gap: 8px; margin-top: 14px; }
.it-month-card { padding: 10px 12px; border: 1px solid #e3e7ee; border-radius: 10px; background: #fff; display: flex; flex-direction: column; gap: 4px; }
.it-month-card.is-empty { background: #fafbfd; opacity: .75; }
.it-month-card-head { display: flex; align-items: center; justify-content: space-between; gap: 6px; font-size: 12.5px; }
.it-month-card-head .pred { font-size: 11px; padding: 2px 7px; min-width: 28px; }
.it-month-card-score { font-size: 19px; font-weight: 800; color: var(--primary); font-variant-numeric: tabular-nums; }
.it-month-card-meta { font-size: 11px; color: #6b7587; min-height: 16px; }
.it-log-edit { margin-top: 14px; border: 1px solid #e3e7ee; border-radius: 10px; padding: 10px 14px; background: #fbfcfe; }
.it-log-edit > summary { cursor: pointer; font-weight: 700; color: #2a5298; }
.it-log-edit[open] > summary { margin-bottom: 8px; }
.it-manual-log-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(175px, 1fr)); gap: 10px; margin-top: 8px; }
.it-manual-log-item { display: flex; flex-direction: column; gap: 4px; margin: 0; font-size: 12px; font-weight: 600; color: #344054; }
.it-manual-log-input { display: flex; align-items: center; gap: 6px; }
.it-manual-log-input input { margin: 0; padding: 6px 8px; }
.it-manual-log-input .pred { font-size: 11px; padding: 3px 8px; min-width: 32px; }
.it-log-edit-actions { justify-content: flex-end; margin-top: 10px; }

/* Kartu Form Input Cepat (Data Tiket, Proyek, Aset, Survei) */
.it-entry-card { margin: 12px 0 16px; padding: 16px 18px; border: 1px solid #cfe0f5; border-radius: 12px; background: linear-gradient(180deg, #f8fbff 0%, #ffffff 100%); box-shadow: 0 2px 6px rgba(21, 101, 192, .05); }
.it-entry-card.is-editing { border-color: #f5b971; background: linear-gradient(180deg, #fffaf2 0%, #ffffff 100%); }
.it-entry-head { display: flex; align-items: baseline; justify-content: space-between; flex-wrap: wrap; gap: 6px 14px; margin-bottom: 12px; padding-bottom: 8px; border-bottom: 1px solid #e6edf7; }
.it-entry-head b { font-size: 14px; color: var(--primary); }
.it-entry-head span { font-size: 12px; color: var(--muted); }
.it-entry-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(185px, 1fr)); gap: 12px 14px; align-items: end; }
.it-field { display: flex; flex-direction: column; gap: 5px; margin: 0; font-weight: 500; }
.it-field.wide { grid-column: 1 / -1; }
.it-field-label { font-size: 12px; font-weight: 700; color: #344054; }
.it-field-label i { color: #c52b2b; font-style: normal; }
.it-field input[type="text"], .it-field input[type="date"], .it-field input[type="time"], .it-field input[type="number"] { margin: 0; padding: 8px 10px; border: 1px solid #cfd8e3; border-radius: 8px; font-size: 13px; background: #fff; }
.it-field input:focus { outline: none; border-color: var(--primary2); box-shadow: 0 0 0 3px rgba(42, 82, 152, .12); }
.it-seg { display: flex; flex-wrap: wrap; gap: 5px; }
.it-seg-item { position: relative; margin: 0; cursor: pointer; user-select: none; }
.it-seg-item input { position: absolute; opacity: 0; pointer-events: none; }
.it-seg-item span { display: inline-block; padding: 6px 11px; border: 1px solid #d0d7e2; border-radius: 8px; background: #fff; font-size: 12px; font-weight: 700; color: #475467; transition: all .15s ease; }
.it-seg-item:hover span { border-color: #98a8c0; background: #f5f8fc; }
.it-seg-item input:checked + span { background: var(--primary2); border-color: var(--primary2); color: #fff; box-shadow: 0 1px 3px rgba(26, 58, 108, .25); }
.it-seg-item.it-tone-good input:checked + span { background: #17834d; border-color: #17834d; }
.it-seg-item.it-tone-warn input:checked + span { background: #d38b18; border-color: #d38b18; }
.it-seg-item.it-tone-bad input:checked + span { background: #c52b2b; border-color: #c52b2b; }
.it-rating .it-seg-item input:checked + span { background: #f59e0b; border-color: #d97706; color: #fff; }
.it-range { display: flex; align-items: center; gap: 10px; padding: 4px 0; }
.it-range input[type="range"] { flex: 1; margin: 0; accent-color: var(--primary2); cursor: pointer; }
.it-range output { min-width: 44px; text-align: right; font-weight: 800; font-size: 13px; color: var(--primary); }
.it-entry-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 14px; padding-top: 10px; border-top: 1px solid #e6edf7; }
.it-list-table td { min-width: 0; padding: 9px 10px; font-size: 13px; }
.it-list-table tr.is-editing td { background: #fff6e5; }
.it-row-actions { display: flex; align-items: center; gap: 5px; white-space: nowrap; }
.it-badge { display: inline-block; padding: 3px 9px; border-radius: 999px; font-size: 11.5px; font-weight: 700; white-space: nowrap; }
.it-badge.it-tone-good { background: #e6f4ea; color: #17834d; }
.it-badge.it-tone-warn { background: #fff3dc; color: #a76400; }
.it-badge.it-tone-bad { background: #fde9e8; color: #c52b2b; }
.it-badge.it-tone-info { background: #e8f1fd; color: #1d5bbf; }
.it-stars { color: #f59e0b; font-size: 14px; letter-spacing: 1px; }
.it-stars span { color: #d5dce6; }
.it-mini-progress { display: inline-block; width: 70px; height: 8px; background: #e6ebf2; border-radius: 99px; overflow: hidden; vertical-align: middle; margin-right: 6px; }
.it-mini-progress span { display: block; height: 100%; background: #17834d; }
.pred { display: inline-block; min-width: 38px; text-align: center; padding: 3px 10px; border-radius: 8px; font-weight: 800; color: #fff; }
.pred-Ap { background: #0d7a3f; } .pred-A { background: #2e9e5b; } .pred-B { background: #f9a825; }
.pred-C { background: #ef6c00; } .pred-D { background: var(--red); }
.score-pill { display: inline-block; padding: 3px 11px; border-radius: 12px; font-weight: 700; font-size: 12.5px; }
.score-good { background: #e6f4ea; color: var(--green); } .score-warn { background: #fff3e0; color: var(--orange); } .score-bad { background: #fdecea; color: var(--red); }
.role-badge { padding: 3px 10px; border-radius: 10px; font-size: 11px; font-weight: 700; text-transform: capitalize; }
.role-superadmin { background: #fce4ec; color: #ad1457; } .role-it { background: #fff8e1; color: #e65100; } .role-director { background: #e0f2f1; color: #00695c; } .role-manager { background: #e3f2fd; color: var(--blue); } .role-user { background: #eceff1; color: #546e7a; } .role-hr { background: #e6f4ea; color: var(--green); } .role-sales { background: #ede7f6; color: #5e35b1; }
.derived { font-size: 11px; color: #7b1fa2; font-weight: 600; }

.bar { background: #e8edf5; border-radius: 6px; height: 8px; overflow: hidden; min-width: 70px; }
.bar > span { display: block; height: 100%; background: var(--primary2); border-radius: 6px; }
.dashboard-attendance-rate { display: grid; gap: 5px; min-width: 150px; }
.dashboard-attendance-rate-label { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; white-space: nowrap; }
.dashboard-attendance-rate-label b { color: var(--primary); font-variant-numeric: tabular-nums; }
.dashboard-attendance-rate-label span { color: var(--muted); font-size: 11px; }
.dashboard-attendance-rate-bar { height: 8px; overflow: hidden; border-radius: 6px; background: #e8edf5; }
.dashboard-attendance-rate-bar span { display: block; height: 100%; border-radius: inherit; transition: width .25s ease; }

/* ===== Boxes ===== */
.rules-box { background: #fff8e1; border-left: 4px solid #ffb300; padding: 14px 18px; border-radius: 8px; margin-bottom: 18px; font-size: 13px; line-height: 1.8; }
.raw-form { background: #fff; border-radius: 12px; padding: 18px 20px; box-shadow: 0 1px 4px rgba(16,24,40,.07); margin-bottom: 20px; }
.raw-form h4 { font-size: 15px; margin-bottom: 10px; color: var(--primary); }
.pen-summary { background: #fff; border-radius: 12px; padding: 20px; box-shadow: 0 1px 4px rgba(16,24,40,.07); overflow-x: auto; }
.pen-summary h3 { font-size: 15px; margin-bottom: 14px; }

/* ===== Ranking ===== */
.rank-list { display: flex; flex-direction: column; gap: 8px; }
.rank-item { display: flex; align-items: center; gap: 14px; padding: 10px 14px; border: 1px solid var(--border); border-radius: 10px; }
.rank-badge { width: 34px; height: 34px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-weight: 800; flex: none; }
.rank-1 { background: #ffd54f; color: #6d4c00; } .rank-2 { background: #cfd8dc; color: #37474f; } .rank-3 { background: #ffccbc; color: #6d2c0f; } .rank-other { background: #eceff1; color: #546e7a; }
.rank-info { flex: 1; min-width: 0; } .rank-info .name { font-weight: 700; } .rank-info .meta { font-size: 12px; color: var(--muted); }
.rank-score { text-align: right; } .rank-score .big { font-size: 20px; font-weight: 800; } .rank-score .small { font-size: 12px; color: var(--muted); }

/* ===== Rating ===== */
.rating-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 14px; }
.rating-card { border: 1px solid var(--border); border-radius: 12px; padding: 14px 16px; background: #fcfdff; }
.rating-card .dept-title { font-weight: 700; color: var(--primary); }
.rating-card .dept-sub { font-size: 12px; color: var(--muted); margin: 2px 0 10px; }
.star-row { display: flex; gap: 6px; margin-bottom: 10px; }
.star-btn { flex: 1; padding: 7px 0; border: 1px solid #cfd8e3; border-radius: 8px; background: #fff; font-weight: 700; color: #78909c; }
.star-btn:hover { border-color: #f9a825; }
.star-btn.active { background: #ffb300; border-color: #ffb300; color: #fff; }
.rating-card .actions { margin-top: 10px; text-align: right; }

/* ===== Kehadiran ===== */
.upload-box { border: 2px dashed #b8c4d6; border-radius: 12px; text-align: center; padding: 18px; cursor: pointer; margin-bottom: 14px; background: #f8faff; }
.upload-box:hover { background: #eef3fc; border-color: var(--primary2); }
.upload-box input[type=file] { display: none; }
.upload-box .icon { font-size: 26px; } .upload-box .text { font-weight: 600; margin-top: 4px; } .upload-box .hint { font-size: 12px; color: var(--muted); }
.att-summary { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin-bottom: 12px; }
.att-stat { border-radius: 10px; padding: 8px 10px; text-align: center; }
.att-stat .lbl { font-size: 11px; font-weight: 600; } .att-stat .val { font-size: 20px; font-weight: 800; }
.att-stat.green { background: #e6f4ea; color: var(--green); } .att-stat.orange { background: #fff3e0; color: var(--orange); }
.att-stat.red { background: #fdecea; color: var(--red); } .att-stat.blue { background: #e3f2fd; color: var(--blue); }
.raw-form .mini-table { display: block; overflow-x: auto; }
.attendance-detail-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin: 14px 0 10px; }
.attendance-detail-head strong, .attendance-detail-head > div:first-child span { display: block; }
.attendance-detail-head > div:first-child span { color: var(--muted); font-size: 12px; margin-top: 3px; }
.attendance-legend { display: flex; align-items: center; gap: 8px 12px; flex-wrap: wrap; }
.attendance-legend > span { display: inline-flex; align-items: center; gap: 5px; font-size: 11px; color: var(--muted); white-space: nowrap; }
.attendance-matrix-wrap { max-width: 100%; max-height: 62vh; overflow: auto; border: 1px solid var(--border); border-radius: 8px; overscroll-behavior: contain; }
.attendance-matrix { width: max-content; min-width: 100%; table-layout: fixed; border-collapse: separate; border-spacing: 0; }
.attendance-matrix th, .attendance-matrix td { padding: 7px 8px; border-bottom: 1px solid var(--border); text-align: center; font-size: 12px; white-space: nowrap; background: #fff; }
.attendance-matrix thead th { position: sticky; top: 0; z-index: 3; background: #f3f6fb; color: var(--muted); }
.attendance-matrix thead th:not(.att-matrix-name):not(.att-matrix-division) { width: 58px; }
.attendance-matrix .att-matrix-name, .attendance-matrix .att-matrix-division { overflow: hidden; text-overflow: ellipsis; }
.attendance-matrix .att-matrix-name { position: sticky; left: 0; z-index: 2; width: 170px; min-width: 170px; text-align: left; }
.attendance-matrix .att-matrix-division { position: sticky; left: 170px; z-index: 2; width: 135px; min-width: 135px; text-align: left; border-right: 1px solid var(--border); }
.attendance-matrix thead .att-matrix-name, .attendance-matrix thead .att-matrix-division { z-index: 5; background: #f3f6fb; }
.attendance-matrix thead th span, .attendance-matrix thead th small { display: block; }
.attendance-matrix thead th small { font-size: 10px; font-weight: 500; text-transform: none; }
.attendance-matrix .att-matrix-empty { color: #a0a9b5; }
.attendance-code { display: inline-flex; align-items: center; justify-content: center; width: 25px; height: 25px; border-radius: 5px; font-size: 11px; font-weight: 800; font-style: normal; }
.status-hadir { background: #e6f4ea; color: var(--green); }
.status-izin { background: #e3f2fd; color: var(--blue); }
.status-sakit { background: #fff3e0; color: var(--orange); }
.status-cuti { background: #f1f3f5; color: #53616d; }
.status-tanpaKeterangan { background: #fdecea; color: var(--red); }
@media (max-width: 600px) {
  .attendance-matrix-wrap { max-height: 58vh; }
  .attendance-matrix .att-matrix-name { width: 125px; min-width: 125px; }
  .attendance-matrix .att-matrix-division { left: 125px; width: 105px; min-width: 105px; }
  .attendance-matrix thead th:not(.att-matrix-name):not(.att-matrix-division) { width: 54px; }
}

/* ===== Hierarki ===== */
.hierarchy-box { background: #fff; border-radius: 12px; padding: 18px 20px; box-shadow: 0 1px 4px rgba(16,24,40,.07); margin-bottom: 16px; }
.hierarchy-box h4 { color: var(--primary); margin-bottom: 10px; }
.hierarchy-list { display: flex; flex-direction: column; gap: 6px; }
.hier-item { display: flex; align-items: center; gap: 10px; padding: 8px 12px; border: 1px solid var(--border); border-radius: 8px; flex-wrap: wrap; }
.hier-item .name { font-weight: 700; } .hier-item .src { color: var(--muted); font-size: 12px; margin-left: auto; }
.role-pill { padding: 2px 9px; border-radius: 10px; font-size: 11px; font-weight: 700; }
.role-pill.manager { background: #fff3e0; color: var(--orange); } .role-pill.sub { background: #e3f2fd; color: var(--blue); }
.org-chart-scroll { max-width: 100%; overflow-x: auto; padding: 8px 4px 24px; }
.org-chart { min-width: 860px; padding: 12px 10px 20px; }
.org-leadership { display: flex; flex-direction: column; align-items: center; }
.org-leader { width: min(100%, 340px); padding: 14px 18px; border: 1px solid var(--border); border-radius: 8px; text-align: center; background: #fff; box-shadow: 0 2px 8px rgba(16,24,40,.08); }
.org-president { background: #173c36; color: #fff; border-color: #173c36; }
.org-director { border-top: 3px solid #d59a2a; }
.org-role { font-size: 11px; font-weight: 700; text-transform: uppercase; color: var(--muted); }
.org-president .org-role { color: #c5d9d3; }
.org-name { margin-top: 4px; font-size: 15px; font-weight: 700; }
.org-leadership-link { height: 24px; border-left: 1px solid #9aa8a6; }
.org-departments { position: relative; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 26px 18px; margin-top: 28px; padding-top: 26px; border-top: 1px solid #9aa8a6; }
.org-departments::before { content: ''; position: absolute; top: -29px; left: 50%; height: 28px; border-left: 1px solid #9aa8a6; }
.org-department { position: relative; min-width: 0; padding: 12px 13px 10px; border: 1px solid var(--border); border-radius: 8px; background: #fff; box-shadow: 0 1px 5px rgba(16,24,40,.06); }
.org-department::before { content: ''; position: absolute; top: -27px; left: 50%; height: 26px; border-left: 1px solid #9aa8a6; }
.org-manager { padding-bottom: 9px; border-bottom: 1px solid var(--border); }
.org-manager .org-role { color: var(--primary2); line-height: 1.4; }
.org-manager .org-name { color: var(--primary); }
.org-members { display: grid; gap: 0; margin: 0; padding: 4px 0 0; list-style: none; }
.org-members li { padding: 7px 2px; border-bottom: 1px solid #edf0f3; color: #475467; font-size: 12px; line-height: 1.35; }
.org-members li:last-child { border-bottom: 0; }
@media (max-width: 700px) { .org-chart { min-width: 760px; } .org-departments { grid-template-columns: repeat(3, minmax(220px, 1fr)); } }

/* ===== Department grid ===== */
.dept-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 14px; }
.dept-card { background: #fff; border-radius: 12px; padding: 16px 18px; box-shadow: 0 1px 4px rgba(16,24,40,.07); cursor: pointer; transition: .15s; border: 1px solid transparent; }
.dept-card:hover { border-color: var(--primary2); transform: translateY(-2px); }
.dept-card .top { display: flex; justify-content: space-between; align-items: flex-start; gap: 8px; }
.dept-card .nm { font-weight: 700; color: var(--primary); }
.dept-card .score { font-size: 26px; font-weight: 800; margin: 8px 0 4px; }
.dept-card .meta { font-size: 12px; color: var(--muted); }

.trend-bars { display: flex; align-items: flex-end; gap: 8px; height: 140px; padding: 10px 4px 0; }
.trend-bars .col { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: flex-end; height: 100%; font-size: 10px; color: var(--muted); }
.trend-bars .col .b { width: 100%; max-width: 34px; background: var(--primary2); border-radius: 5px 5px 0 0; min-height: 2px; }
.trend-bars .col.empty-col .b { background: #e3e8f0; }

/* ===== Modal & toast ===== */
.modal-overlay { display: none; position: fixed; inset: 0; background: rgba(15,23,42,.5); z-index: 100; align-items: center; justify-content: center; padding: 16px; }
.modal-overlay.show { display: flex; }
.modal { background: #fff; border-radius: 14px; padding: 24px; width: 100%; max-width: 420px; }
.modal h3 { color: var(--primary); }
.modal.modal-wide { max-width: 760px; max-height: 90vh; overflow-y: auto; }
.permission-help { margin: 8px 0 14px; color: var(--muted); font-size: 13px; line-height: 1.5; }
.permission-table-wrap { max-height: 58vh; overflow: auto; border: 1px solid var(--border); border-radius: 8px; }
.permission-table { min-width: 480px; }
.permission-table th { position: sticky; top: 0; z-index: 1; }
.permission-table td { padding: 7px 12px; }
.permission-table select { width: 100%; min-width: 170px; padding: 7px 9px; border: 1px solid #cfd8e3; border-radius: 6px; background: #fff; }
.permission-summary { color: var(--green); font-size: 12px; font-weight: 700; }
.modal-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 20px; }
.toast {
  position: fixed; bottom: 24px; left: 50%; transform: translate(-50%, 30px); opacity: 0; pointer-events: none;
  background: #263238; color: #fff; padding: 11px 20px; border-radius: 10px; z-index: 200; transition: .25s; font-size: 13px; max-width: 90vw;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.toast.success { background: var(--green); } .toast.error { background: var(--red); }
@media (max-width: 600px) {
  .it-summary-cards { grid-template-columns: 1fr; gap: 10px; }
  .it-summary-cards .card { padding: 14px 16px; }
  .it-summary-cards .card .val { font-size: 24px; }
  .it-kpi-table-wrap { padding: 16px; }
  .it-source-heading .toolbar { width: 100%; }
  .it-source-heading .toolbar .btn { flex: 1; }
  .it-source-tools { align-items: stretch; flex-direction: column; }
  .it-source-tools input { width: 100%; }
  .it-source-metrics { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .it-source-metric { padding: 8px; }
  .it-source-metric b { font-size: 15px; }
  .it-dashboard { padding: 15px; }
  .it-dashboard-heading { flex-direction: column; }
  .it-dashboard-score { align-items: flex-start; flex-wrap: wrap; }
  .it-method-grid { grid-template-columns: 1fr; gap: 10px; }
  .it-method-grid .raw-form { padding: 15px; }
  .modal.modal-wide { padding: 18px; }
  .permission-table-wrap { max-height: 54vh; }
}

/* ===== Sales Ops (SO 1) Kuartal Otomatis, Ringkasan 3 Bulan & Tabel Target ===== */
.so-quarter-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  background: linear-gradient(135deg, #f3f7ff 0%, #eef4ff 100%);
  border: 1px solid #cddbf5;
  border-radius: 12px;
  padding: 14px 18px;
  margin-bottom: 14px;
}
.so-quarter-info { flex: 1 1 360px; }
.so-quarter-badge-row { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 6px; }
.so-auto-badge {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 4px 11px; border-radius: 999px; font-size: 12px;
  background: #e3f5eb; color: #126b3c; border: 1px solid #a8dfc0;
}
.so-auto-badge.is-manual { background: #fff4e0; color: #9a5b00; border-color: #f3ce8a; }
.so-target-ref-badge {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 4px 11px; border-radius: 999px; font-size: 12px;
  background: #e8eefc; color: #1f3c88; border: 1px solid #bfd0f7;
}
.so-quarter-desc { margin: 0; font-size: 12.5px; color: #475467; line-height: 1.45; }
.so-quarter-controls { display: flex; flex-direction: column; align-items: flex-end; gap: 8px; }
.so-month-sim { display: flex; align-items: center; gap: 8px; font-size: 12px; color: #344054; font-weight: 600; }
.so-month-sim select { width: auto; padding: 6px 10px; border-radius: 8px; border: 1px solid #b8c7e0; background: #fff; font-size: 12.5px; color: #1f3c88; font-weight: 600; }
.so-quarter-pills { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.so-q-pill {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 6px 11px; border-radius: 8px; border: 1px solid #c9d5e8;
  background: #fff; color: #344054; font-size: 12px; cursor: pointer; transition: .15s;
}
.so-q-pill span { color: #667085; font-size: 11px; }
.so-q-pill:hover { border-color: var(--primary2); color: var(--primary); }
.so-q-pill.active { background: var(--primary); color: #fff; border-color: var(--primary); box-shadow: 0 2px 6px rgba(31,60,136,.22); }
.so-q-pill.active span { color: #dbe7ff; }
.so-quarter-notice {
  display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap;
  background: #fff9eb; border: 1px solid #f5d488; color: #7a4b00;
  border-radius: 10px; padding: 10px 14px; margin-bottom: 14px; font-size: 12.5px;
}
.so-sheet-banner {
  display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap;
  padding-bottom: 12px; margin-bottom: 12px; border-bottom: 2px solid #e6ecf5;
}
.so-banner-kicker { font-size: 11px; font-weight: 800; letter-spacing: .08em; color: #2a5298; text-transform: uppercase; }
.so-sheet-banner h4 { margin: 2px 0 0; font-size: 16px; color: #162b5b; }
.so-summary-table th, .so-target-table th { vertical-align: middle; text-align: center; }
.so-summary-table td:first-child,
.so-summary-table th:first-child,
.so-ref-table td:first-child,
.so-ref-table th:first-child,
.so-col-no {
  width: 1% !important;
  min-width: 0 !important;
  max-width: 32px;
  padding: 6px 8px !important;
  text-align: center !important;
  white-space: nowrap;
  font-size: 12.5px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}
.so-summary-table td:nth-child(3) {
  min-width: 240px;
  white-space: normal;
}
.so-summary-table .th-sub, .so-target-table .th-sub { font-size: 10.5px; font-weight: 600; color: #5c6f91; margin-top: 2px; text-transform: none; }
.so-result-group-head { background: #dce8ff !important; color: #163273 !important; font-weight: 800; letter-spacing: .04em; }
.so-result-month-row th.so-month-col { background: #edf3ff !important; color: #1f3c88; min-width: 112px; }
.so-kpi-meta { font-size: 11.5px; color: #667085; margin-top: 3px; line-height: 1.35; }
.so-target-cell { background: rgba(42, 82, 152, 0.04); }
.so-target-sub { font-size: 10.5px; color: #2a5298; font-weight: 600; margin-top: 2px; }
.so-cell-input-wrap { display: flex; align-items: center; gap: 4px; }
.so-month-input, .so-target-input { text-align: right; font-weight: 600; padding: 6px 8px; min-width: 82px; }
.so-unit-prefix, .so-unit-suffix { font-size: 11px; font-weight: 700; color: #667085; }
.so-summary-foot td { background: #f4f7fc; border-top: 2px solid #cbd6e8; padding: 10px 12px; }
.so-foot-note { font-size: 11.5px; color: #52627a; text-align: center; font-style: italic; }
.so-talenta-note {
  display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap;
  margin-top: 12px; padding-top: 10px; border-top: 1px dashed #d5deec;
  font-size: 12px; color: #52627a; font-style: italic;
}
.so-target-banner {
  display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap;
  background: #f5f8ff; border: 1px solid #d4e0f7; border-radius: 10px; padding: 12px 16px; margin-bottom: 14px;
}
.so-target-banner b { display: block; color: #1f3c88; font-size: 13.5px; }
.so-target-banner span { font-size: 12px; color: #52627a; }
.so-active-q-tag { display: inline !important; background: #1f3c88; color: #fff !important; padding: 1px 7px; border-radius: 5px; font-size: 11px !important; }
.so-q-target-col.is-active-q { background: rgba(31, 60, 136, 0.065) !important; border-left: 2px solid #9ab5f0; border-right: 2px solid #9ab5f0; }
.so-dir-tag { display: inline-block; padding: 2px 7px; border-radius: 6px; font-size: 11px; font-weight: 700; }
.so-dir-tag.dir-up { background: #e6f6ec; color: #157343; }
.so-dir-tag.dir-down { background: #fff2e2; color: #b25900; }
.so-sim-box { display: flex; flex-direction: column; gap: 2px; text-align: right; font-size: 12px; }
.so-sim-box small { font-size: 11px; color: #596579; }

.so-revenue-editable-row {
  background: linear-gradient(90deg, #eff6ff 0%, #f8fafc 100%) !important;
  box-shadow: inset 3px 0 0 #2563eb;
}
.so-editable-pill {
  display: inline-block;
  margin-left: 6px;
  padding: 2px 8px;
  font-size: 10px;
  font-weight: 700;
  color: #1d4ed8;
  background: #dbeafe;
  border: 1px solid #93c5fd;
  border-radius: 999px;
  vertical-align: middle;
}
.so-rev-input-group {
  display: flex;
  flex-direction: column;
  gap: 3px;
  text-align: left;
  min-width: 155px;
}
.so-rev-field-lbl {
  font-size: 10px;
  font-weight: 700;
  color: #334155;
  text-transform: uppercase;
  letter-spacing: 0.2px;
}
.so-rev-target-input {
  border-color: #60a5fa !important;
  background: #eff6ff !important;
  color: #1e3a8a !important;
}
.so-rev-real-input {
  border-color: #34d399 !important;
  background: #ecfdf5 !important;
  color: #065f46 !important;
}
.so-rev-pct-badge {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  margin-top: 2px;
  padding: 3px 7px;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 800;
}
.so-rev-pct-badge.tone-good { background: #dcfce7; color: #166534; border: 1px solid #86efac; }
.so-rev-pct-badge.tone-warn { background: #fef9c3; color: #854d0e; border: 1px solid #fde047; }
.so-rev-pct-badge.tone-bad  { background: #fee2e2; color: #991b1b; border: 1px solid #fca5a5; }
.so-rev-pct-badge.tone-muted { background: #f1f5f9; color: #64748b; border: 1px solid #cbd5e1; }
.so-ach-status {
  font-size: 10px;
  font-weight: 700;
  padding: 1px 5px;
  border-radius: 4px;
  background: rgba(255,255,255,0.65);
}
.so-auto-result-cell {
  background: #f8fafc;
}
.so-auto-result-val {
  font-weight: 700;
  color: #0f172a;
  font-size: 12px;
}
.so-auto-result-sub {
  font-size: 10px;
  color: #475569;
  margin-top: 2px;
}
.so-quarter-Summary-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 10px;
}
.so-q-accum-card {
  background: #f8fafc;
  border: 1px solid #cbd5e1;
  border-radius: 10px;
  padding: 10px 12px;
}
.so-q-accum-card.active {
  background: #eff6ff;
  border-color: #60a5fa;
  box-shadow: 0 2px 6px rgba(37,99,235,0.1);
}
.so-q-accum-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 4px;
}
.so-q-accum-body {
  font-size: 11px;
  color: #334155;
  line-height: 1.45;
}
.so-q-group-cell {
  background: #f1f5f9;
  vertical-align: middle;
}
.so-q-accum-cell {
  background: #f8fafc;
  vertical-align: middle;
}

/* ==========================================================
 * HR ATTENDANCE ANALYSIS & RECAP UI (FORMAT PT RAI)
 * ========================================================== */
.att-hr-page {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.att-hr-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
  flex-wrap: wrap;
  background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  padding: 18px 22px;
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.04);
}

.att-hr-title-block h3 {
  margin: 6px 0 4px;
  font-size: 19px;
  font-weight: 800;
  color: #0f172a;
}

.att-hr-title-block p {
  margin: 0;
  font-size: 13px;
  color: #475569;
  max-width: 780px;
  line-height: 1.45;
}

.att-hr-eyebrow {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.att-company-pill {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: #1e3a8a;
  color: #ffffff;
  font-size: 11px;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 999px;
  letter-spacing: 0.3px;
}

.att-period-pill {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: #eff6ff;
  color: #1d4ed8;
  border: 1px solid #bfdbfe;
  font-size: 11.5px;
  padding: 3px 10px;
  border-radius: 999px;
}

.att-hr-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

/* KPI Cards HR */
.att-kpi-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(205px, 1fr));
  gap: 12px;
}

.att-kpi-card {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 14px 16px;
  box-shadow: 0 1px 4px rgba(15, 23, 42, 0.03);
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.att-kpi-lbl {
  font-size: 11.5px;
  font-weight: 700;
  color: #64748b;
  text-transform: uppercase;
  letter-spacing: 0.25px;
}

.att-kpi-val {
  font-size: 24px;
  font-weight: 800;
  color: #0f172a;
  line-height: 1.2;
}

.att-kpi-val small {
  font-size: 12px;
  font-weight: 600;
  color: #64748b;
}

.att-kpi-sub {
  font-size: 11.5px;
  color: #475569;
  display: flex;
  align-items: center;
  gap: 5px;
  flex-wrap: wrap;
}
.att-absence-breakdown {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 5px 8px;
  margin: 4px 0;
}
.att-absence-item {
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 4px 7px;
  border-radius: 6px;
  background: #fff7ed;
  color: #7c2d12;
  font-size: 11px;
}
.att-absence-item b { font-size: 12px; }
.att-absence-row-breakdown {
  margin-top: 3px;
  color: #64748b;
  font-size: 10px;
  line-height: 1.4;
  white-space: normal;
}

.att-dot {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
}
.att-dot.good { background: #16a34a; }
.att-dot.muted { background: #94a3b8; }

/* View Tabs */
.att-view-tabs {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  border-bottom: 2px solid #e2e8f0;
  padding-bottom: 2px;
}

.att-view-tab {
  background: #f8fafc;
  border: 1px solid #cbd5e1;
  border-bottom: none;
  color: #475569;
  padding: 9px 16px;
  font-size: 13px;
  font-weight: 700;
  border-radius: 10px 10px 0 0;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: all 0.15s ease;
}

.att-view-tab:hover {
  background: #f1f5f9;
  color: #0f172a;
}

.att-view-tab.active {
  background: #1e40af;
  color: #ffffff;
  border-color: #1e40af;
}

.att-tab-count {
  background: rgba(15, 23, 42, 0.12);
  color: inherit;
  padding: 1px 7px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 800;
}

.att-view-tab.active .att-tab-count {
  background: rgba(255, 255, 255, 0.22);
  color: #ffffff;
}

/* Filter Bar */
.att-section-card {
  border-radius: 12px;
  padding: 16px;
  background: #ffffff;
  border: 1px solid #e2e8f0;
}

.att-filter-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 14px;
}

.att-search-box {
  flex: 1;
  min-width: 260px;
}

.att-search-box input {
  width: 100%;
  padding: 8px 12px;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  font-size: 13px;
}

.att-filter-group {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.att-filter-group select,
.att-filter-group input[type="search"] {
  padding: 8px 11px;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  font-size: 12.5px;
  background: #f8fafc;
  color: #0f172a;
}

/* Recap Table */
.att-recap-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12.5px;
}

.att-recap-table thead th {
  background: #f1f5f9;
  color: #1e293b;
  font-weight: 700;
  padding: 10px 10px;
  border-bottom: 2px solid #cbd5e1;
  text-align: left;
  position: sticky;
  top: 0;
  z-index: 2;
}

.att-recap-table tbody td {
  padding: 10px 10px;
  border-bottom: 1px solid #e2e8f0;
  vertical-align: top;
}

.att-recap-table tbody tr:hover {
  background: #f8fafc;
}

.att-emp-name-cell {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.att-shift-tag {
  display: inline-block;
  width: fit-content;
  font-size: 10px;
  font-weight: 700;
  background: #ede9fe;
  color: #6d28d9;
  border: 1px solid #ddd6fe;
  padding: 1px 6px;
  border-radius: 6px;
}

.att-loc-badge {
  display: inline-block;
  font-size: 11px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 999px;
}
.att-loc-badge.sentul { background: #dbeafe; color: #1e40af; }
.att-loc-badge.bpn { background: #dcfce7; color: #166534; }
.att-loc-badge.bjm { background: #fef3c7; color: #92400e; }
.att-loc-badge.luar { background: #f1f5f9; color: #475569; }

.att-tz-sub {
  display: block;
  font-size: 10.5px;
  color: #64748b;
  margin-top: 2px;
  padding-left: 4px;
}

.att-pct-cell {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.att-pct-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 6px;
}

.att-status-chip {
  display: inline-block;
  font-size: 10.5px;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: 999px;
  white-space: nowrap;
}
.att-status-chip.good { background: #dcfce7; color: #166534; border: 1px solid #86efac; }
.att-status-chip.warn { background: #fef3c7; color: #92400e; border: 1px solid #fde047; }
.att-status-chip.bad { background: #fee2e2; color: #991b1b; border: 1px solid #fca5a5; }
.att-status-chip.muted { background: #f1f5f9; color: #64748b; border: 1px solid #cbd5e1; }

/* Date Pills for Absent Dates */
.att-date-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}

.att-date-pill {
  display: inline-flex;
  align-items: center;
  font-size: 11px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 6px;
  white-space: nowrap;
}

.att-date-pill.absent {
  background: #fef2f2;
  color: #b91c1c;
  border: 1px solid #fecaca;
}

.att-date-pill.warn {
  background: #fffbeb;
  color: #b45309;
  border: 1px solid #fde68a;
}

.att-badge-ok {
  display: inline-flex;
  align-items: center;
  font-size: 11.5px;
  font-weight: 700;
  color: #15803d;
  background: #f0fdf4;
  border: 1px solid #bbf7d0;
  padding: 3px 9px;
  border-radius: 8px;
}

.att-badge-inactive {
  display: inline-block;
  font-size: 11px;
  font-weight: 700;
  color: #475569;
  background: #f1f5f9;
  border: 1px solid #cbd5e1;
  padding: 3px 8px;
  border-radius: 6px;
}

.att-absent-details summary {
  font-size: 11px;
  color: #2563eb;
  cursor: pointer;
  margin-top: 4px;
  font-weight: 600;
}

.att-absent-details .att-date-pills {
  margin-top: 6px;
}

.att-issue-list {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.att-issue-item {
  display: flex;
  align-items: center;
  gap: 5px;
  flex-wrap: wrap;
  font-size: 11px;
  color: #334155;
}

.att-more-note {
  font-size: 10.5px;
  color: #64748b;
  font-style: italic;
}

.att-hours-cell {
  display: flex;
  flex-direction: column;
  gap: 3px;
  font-size: 12px;
}

.att-ot-pill {
  display: inline-block;
  width: fit-content;
  background: #eff6ff;
  color: #1d4ed8;
  border: 1px solid #bfdbfe;
  padding: 2px 7px;
  border-radius: 6px;
  font-size: 11px;
}

/* Calendar Matrix */
.att-cal-table th.is-weekend-col {
  background: #f1f5f9;
  color: #64748b;
}

.att-cal-cell {
  text-align: center;
  padding: 4px !important;
}

.att-cal-cell.is-weekend {
  background: #f8fafc;
}

.att-cal-cell.is-absent {
  background: #fff1f2;
}

.att-cal-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 800;
}
.att-cal-badge.present { background: #dcfce7; color: #15803d; }
.att-cal-badge.ot { background: #dbeafe; color: #1d4ed8; }
.att-cal-badge.warn { background: #fef3c7; color: #b45309; }
.att-cal-badge.absent { background: #fee2e2; color: #b91c1c; }
.att-cal-badge.off { background: #f1f5f9; color: #94a3b8; }

.att-row-absent { background: #fffafa; }
.att-row-weekend { background: #f8fafc; color: #64748b; }

.att-mini-loc {
  display: inline-block;
  font-size: 11px;
  font-weight: 600;
  color: #1e293b;
}

.att-note-text {
  font-size: 11px;
  color: #b45309;
  background: #fffbeb;
  border: 1px solid #fde68a;
  padding: 2px 6px;
  border-radius: 5px;
  margin-top: 2px;
}

/* Modal Backdrop & Card */
.att-modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.55);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2000;
  padding: 16px;
}

.att-modal-card {
  background: #ffffff;
  border-radius: 14px;
  width: 100%;
  max-width: 560px;
  padding: 20px 22px;
  box-shadow: 0 20px 45px rgba(15, 23, 42, 0.25);
  border: 1px solid #e2e8f0;
}

.att-modal-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
  padding-bottom: 10px;
  border-bottom: 1px solid #e2e8f0;
}

.att-modal-head h4 {
  margin: 0;
  font-size: 16px;
  font-weight: 800;
  color: #0f172a;
}

/* ===== Menu Khusus NPS (Shared Per Site) ===== */
.nps-notice {
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  color: #1e40af;
  padding: 10px 14px;
  border-radius: 10px;
  font-size: 12.5px;
  margin-bottom: 14px;
}
.nps-site-tabs {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 10px;
  margin-bottom: 16px;
}
.nps-site-tab {
  text-align: left;
  background: #fff;
  border: 1.5px solid #dbe4f0;
  border-radius: 12px;
  padding: 12px 14px;
  cursor: pointer;
  transition: all .15s ease;
}
.nps-site-tab:hover {
  border-color: #60a5fa;
  background: #f8fafc;
}
.nps-site-tab.active {
  border-color: var(--primary);
  background: linear-gradient(135deg, #f0f7ff, #ffffff);
  box-shadow: 0 4px 12px rgba(30, 58, 138, 0.12);
}
.nps-site-tab-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  font-size: 14px;
  color: var(--primary);
}
.nps-site-tab-sub {
  margin-top: 4px;
  font-size: 11.5px;
  color: #64748b;
  line-height: 1.4;
}
.nps-site-score-pill {
  padding: 2px 9px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
}
.nps-site-score-pill.good { background: #dcfce7; color: #166534; }
.nps-site-score-pill.warn { background: #fef3c7; color: #92400e; }
.nps-site-score-pill.muted { background: #f1f5f9; color: #64748b; }
.nps-month-strip {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(72px, 1fr));
  gap: 6px;
  margin-bottom: 14px;
}
.nps-month-chip {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  padding: 6px 8px;
  text-align: center;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: 2px;
  font-size: 11px;
  color: #475569;
  transition: all .15s;
}
.nps-month-chip b {
  font-size: 12px;
  color: #0f172a;
}
.nps-month-chip.has-data {
  border-color: #93c5fd;
  background: #eff6ff;
}
.nps-month-chip.active {
  background: var(--primary);
  border-color: var(--primary);
  color: #fff;
}
.nps-month-chip.active b {
  color: #fff;
}
.nps-score-input-row {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.nps-quick-scores {
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
}
.nps-quick-score-btn {
  width: 32px;
  height: 32px;
  border-radius: 7px;
  border: 1px solid #cbd5e1;
  background: #fff;
  font-weight: 700;
  font-size: 12.5px;
  cursor: pointer;
  color: #334155;
  transition: all .12s;
}
.nps-quick-score-btn:hover { transform: translateY(-1px); }
.nps-quick-score-btn.tone-promoter.active { background: #16a34a; border-color: #16a34a; color: #fff; }
.nps-quick-score-btn.tone-passive.active { background: #d97706; border-color: #d97706; color: #fff; }
.nps-quick-score-btn.tone-detractor.active { background: #dc2626; border-color: #dc2626; color: #fff; }
.nps-by-chip {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 999px;
  background: #f1f5f9;
  color: #334155;
  font-size: 11px;
  font-weight: 600;
}
.aligned-sync-badge {
  display: inline-block;
  margin-top: 4px;
  padding: 2px 8px;
  border-radius: 999px;
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  color: #1d4ed8;
  font-size: 11px;
  font-weight: 500;
  line-height: 1.4;
}
.aligned-sync-badge.is-source {
  background: #f0fdf4;
  border-color: #bbf7d0;
  color: #15803d;
}



/* ===== Menu DSI User-Friendly, Lock Bulanan & Ranking ===== */
.nav-item.is-dsi-locked {
  opacity: 0.65;
  cursor: not-allowed;
}
.nav-item.is-dsi-locked:hover {
  background: rgba(255, 255, 255, 0.04);
}
.dsi-nav-badge {
  font-size: 10px !important;
  font-weight: 800;
  padding: 2px 7px !important;
}
.dsi-nav-badge.is-required {
  background: #ffb300 !important;
  color: #3d2c00 !important;
}
.dsi-nav-badge.is-locked {
  background: rgba(148, 163, 184, 0.35) !important;
  color: #e2e8f0 !important;
}
.dsi-nav-badge.is-admin {
  background: rgba(56, 189, 248, 0.25) !important;
  color: #e0f2fe !important;
}

.dsi-alert-banner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
  padding: 14px 18px;
  border-radius: 12px;
  margin-bottom: 18px;
  border: 1px solid transparent;
}
.dsi-alert-banner.is-pending {
  background: linear-gradient(135deg, #fffbeb 0%, #fef3c7 100%);
  border-color: #fcd34d;
  box-shadow: 0 2px 10px rgba(245, 158, 11, 0.12);
}
.dsi-alert-banner.is-done {
  background: linear-gradient(135deg, #f0fdf4 0%, #dcfce7 100%);
  border-color: #86efac;
}
.dsi-alert-icon {
  font-size: 26px;
  line-height: 1;
}
.dsi-alert-body {
  flex: 1 1 260px;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.dsi-alert-body b {
  font-size: 14.5px;
  color: #1e293b;
}
.dsi-alert-body span {
  font-size: 12.5px;
  color: #475569;
}

.dsi-ranking-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 14px;
}
.dsi-ranking-controls {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
.dsi-rank-bar {
  margin-top: 6px;
  height: 6px;
  border-radius: 999px;
  background: #e8edf5;
  overflow: hidden;
  max-width: 340px;
}
.dsi-rank-bar > span {
  display: block;
  height: 100%;
  border-radius: inherit;
  transition: width .3s ease;
}
.rank-item.is-unrated {
  opacity: 0.72;
}

.dsi-hero {
  background: linear-gradient(135deg, #162f60 0%, #2a5298 100%);
  color: #fff;
  border-radius: 14px;
  padding: 20px 22px;
  margin-bottom: 16px;
  box-shadow: 0 8px 24px rgba(22, 47, 96, 0.18);
}
.dsi-hero-kicker {
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.08em;
  color: #fcd34d;
  margin-bottom: 4px;
}
.dsi-hero h3 {
  font-size: 20px;
  margin: 0 0 6px;
}
.dsi-hero p {
  font-size: 13px;
  color: rgba(255, 255, 255, 0.9);
  margin: 0;
  max-width: 760px;
}
.dsi-hero-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 14px;
}
.dsi-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 5px 12px;
  border-radius: 999px;
  font-size: 12px;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.24);
  color: #fff;
}

.dsi-scale-guide {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 12px 16px;
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
}
.dsi-scale-title {
  font-size: 12.5px;
  font-weight: 700;
  color: var(--primary);
}
.dsi-scale-items {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.dsi-scale-chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  color: #334155;
}
.dsi-scale-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: #e2e8f0;
  font-size: 11px;
  font-weight: 800;
}

.dsi-progress-bar-wrap {
  position: sticky;
  top: 58px;
  z-index: 25;
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(6px);
  border: 1px solid #cbd5e1;
  border-radius: 12px;
  padding: 12px 16px;
  margin-bottom: 16px;
  box-shadow: 0 4px 14px rgba(15, 23, 42, 0.08);
}
.dsi-progress-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 8px;
  font-size: 13px;
}
.dsi-progress-top b {
  color: var(--primary);
}
.dsi-progress-top span {
  color: var(--muted);
  font-size: 12px;
}
.dsi-progress-status {
  font-weight: 700;
  color: #b45309 !important;
}
.dsi-progress-status.is-ready {
  color: #15803d !important;
}
.dsi-progress-track {
  height: 9px;
  border-radius: 999px;
  background: #e2e8f0;
  overflow: hidden;
}
.dsi-progress-track > span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #2563eb, #16a34a);
  transition: width .25s ease;
}

.dsi-dept-list {
  display: grid;
  gap: 14px;
  margin-bottom: 18px;
}
.dsi-dept-card {
  background: #fff;
  border: 2px solid var(--border);
  border-radius: 14px;
  padding: 16px 18px;
  box-shadow: 0 1px 4px rgba(16, 24, 40, 0.06);
  transition: border-color .2s, box-shadow .2s;
}
.dsi-dept-card.is-completed {
  border-color: #86efac;
  background: linear-gradient(180deg, #ffffff 0%, #f7fef9 100%);
}
.dsi-dept-card.is-missing {
  border-color: #ef4444;
  box-shadow: 0 0 0 4px rgba(239, 68, 68, 0.16);
}
.dsi-dept-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}
.dsi-dept-title {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  font-size: 15.5px;
  color: var(--primary);
}
.dsi-dept-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: #e0ebff;
  color: var(--primary);
  font-size: 12px;
  font-weight: 800;
}
.dsi-unit-count {
  padding: 2px 8px;
  border-radius: 999px;
  background: #f1f5f9;
  color: #475569;
  font-size: 11px;
  font-weight: 700;
}
.dsi-dept-units-sub {
  margin-top: 4px;
  font-size: 12px;
  color: var(--muted);
}
.dsi-dept-status {
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 11.5px;
  font-weight: 700;
  background: #fff7ed;
  color: #c2410c;
  border: 1px solid #fed7aa;
  white-space: nowrap;
}
.dsi-dept-status.is-done {
  background: #dcfce7;
  color: #15803d;
  border-color: #86efac;
}

.dsi-question-list {
  display: grid;
  gap: 8px;
}
.dsi-question-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(210px, 250px);
  align-items: center;
  gap: 14px;
  padding: 10px 12px;
  border: 1px solid #e2e8f0;
  border-radius: 9px;
  background: #f8fafc;
}
.dsi-question-label {
  color: #334155;
  font-size: 13px;
  line-height: 1.45;
}
.dsi-question-label b {
  color: var(--primary);
}
.dsi-question-select,
.dsi-response-field select,
.dsi-response-field textarea {
  width: 100%;
  min-width: 0;
  padding: 9px 10px;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  background: #fff;
  color: #1e293b;
  font: inherit;
}
.dsi-response-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}
.dsi-response-field {
  display: grid;
  gap: 6px;
  color: #334155;
  font-size: 13px;
  font-weight: 600;
}
.dsi-response-field small {
  color: var(--muted);
  font-weight: 400;
}
.dsi-response-field textarea {
  resize: vertical;
  line-height: 1.45;
}

.dsi-rate-row {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
}
.dsi-rate-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  padding: 10px 6px;
  border-radius: 10px;
  border: 1.5px solid #cbd5e1;
  background: #fff;
  color: #334155;
  transition: all .15s ease;
}
.dsi-rate-btn:hover {
  border-color: #64748b;
  transform: translateY(-1px);
  background: #f8fafc;
}
.dsi-rate-top {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 15px;
}
.dsi-rate-emoji {
  font-size: 18px;
}
.dsi-rate-lbl {
  font-size: 11px;
  font-weight: 600;
  text-align: center;
}
.dsi-rate-btn.active {
  color: #fff;
  box-shadow: 0 3px 10px rgba(15, 23, 42, 0.16);
}
.dsi-rate-btn.tone-bad.active { background: #dc2626; border-color: #b91c1c; }
.dsi-rate-btn.tone-warn.active { background: #ea580c; border-color: #c2410c; }
.dsi-rate-btn.tone-mid.active { background: #d97706; border-color: #b45309; }
.dsi-rate-btn.tone-good.active { background: #16a34a; border-color: #15803d; }
.dsi-rate-btn.tone-great.active { background: #0d7a3f; border-color: #065f46; }

.dsi-dept-extra {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 12px;
}
.dsi-comment-input {
  flex: 1 1 240px;
  padding: 8px 11px !important;
  font-size: 13px !important;
}
.dsi-unit-toggle {
  background: #f1f5f9;
  border: 1px solid #cbd5e1;
  color: #334155;
  border-radius: 8px;
  padding: 7px 12px;
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
}
.dsi-unit-toggle:hover {
  background: #e2e8f0;
}

.dsi-unit-breakdown {
  display: none;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px dashed #cbd5e1;
  gap: 8px;
}
.dsi-unit-breakdown.is-open {
  display: grid;
}
.dsi-unit-row {
  display: grid;
  grid-template-columns: minmax(170px, 1.1fr) auto minmax(160px, 1fr);
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  border-radius: 9px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
}
.dsi-unit-name {
  font-size: 12.5px;
  font-weight: 700;
  color: #1e293b;
}
.dsi-unit-stars {
  display: flex;
  gap: 4px;
}
.dsi-mini-rate {
  padding: 4px 8px;
  border-radius: 7px;
  border: 1px solid #cbd5e1;
  background: #fff;
  font-size: 11.5px;
  font-weight: 700;
  color: #334155;
}
.dsi-mini-rate.active { color: #fff; }
.dsi-mini-rate.tone-bad.active { background: #dc2626; border-color: #dc2626; }
.dsi-mini-rate.tone-warn.active { background: #ea580c; border-color: #ea580c; }
.dsi-mini-rate.tone-mid.active { background: #d97706; border-color: #d97706; }
.dsi-mini-rate.tone-good.active { background: #16a34a; border-color: #16a34a; }
.dsi-mini-rate.tone-great.active { background: #0d7a3f; border-color: #0d7a3f; }
.dsi-unit-comment {
  padding: 6px 9px !important;
  font-size: 12px !important;
}

.dsi-submit-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid var(--border);
}
.dsi-submit-note {
  font-size: 12.5px;
  color: #7c2d12;
  background: #fff7ed;
  border: 1px solid #fed7aa;
  padding: 8px 12px;
  border-radius: 8px;
  flex: 1 1 260px;
}
.dsi-submit-btn {
  padding: 12px 22px;
  font-size: 14px;
}

.dsi-confirm-box {
  margin: 12px 0;
  padding: 12px;
  border-radius: 10px;
  background: #f8fafc;
  border: 1px solid var(--border);
}
.dsi-confirm-row {
  display: flex;
  justify-content: space-between;
  font-size: 13px;
  padding: 3px 0;
}
.dsi-confirm-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px 12px;
  margin-top: 10px;
  padding-top: 8px;
  border-top: 1px dashed #cbd5e1;
  font-size: 12px;
}
.dsi-confirm-list > div {
  display: flex;
  justify-content: space-between;
}
.dsi-confirm-warn {
  font-size: 12px;
  color: #9a3412;
  background: #fff7ed;
  border: 1px solid #fed7aa;
  border-radius: 8px;
  padding: 9px 11px;
}

.dsi-locked-wrap {
  display: flex;
  justify-content: center;
  padding: 28px 12px;
}
.dsi-locked-card {
  width: 100%;
  max-width: 540px;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 30px 26px;
  text-align: center;
  box-shadow: 0 8px 28px rgba(15, 23, 42, 0.08);
}
.dsi-locked-icon {
  font-size: 46px;
  margin-bottom: 10px;
}
.dsi-locked-card h3 {
  font-size: 20px;
  color: var(--primary);
  margin-bottom: 8px;
}
.dsi-locked-desc {
  font-size: 13.5px;
  color: #475569;
  margin-bottom: 18px;
}
.dsi-locked-meta {
  display: grid;
  gap: 8px;
  text-align: left;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 12px 14px;
  margin-bottom: 20px;
  font-size: 12.5px;
}
.dsi-locked-meta > div {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
}
.dsi-locked-meta span {
  color: var(--muted);
}

.dsi-admin-filter-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 12px;
}
.dsi-admin-filter-row label {
  margin: 0;
}
.dsi-admin-filter-row select,
.dsi-admin-filter-row input {
  margin-top: 5px;
}

@media (max-width: 720px) {
  .dsi-question-row {
    grid-template-columns: 1fr;
    gap: 7px;
  }
  .dsi-response-grid {
    grid-template-columns: 1fr;
  }
  .dsi-rate-row {
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 5px;
  }
  .dsi-rate-btn {
    padding: 8px 3px;
  }
  .dsi-rate-lbl {
    font-size: 9.5px;
  }
  .dsi-unit-row {
    grid-template-columns: 1fr;
  }
  .dsi-confirm-list {
    grid-template-columns: 1fr;
  }
}

/* ==========================================================
 * UPLOAD EXCEL PER FOLDER & SINKRONISASI KUARTAL (Q1-Q4)
 * ========================================================== */
.folder-q-strip {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 12px 16px;
  margin-bottom: 14px;
  box-shadow: 0 1px 4px rgba(15, 23, 42, 0.03);
}
.folder-q-strip-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 10px;
  font-size: 13px;
  color: #1e293b;
}
.folder-q-strip-head small {
  font-size: 11.5px;
  color: #64748b;
}
.folder-q-cards {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}
.folder-q-card {
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 10px 12px;
  background: #f8fafc;
  cursor: pointer;
  transition: border-color 0.15s, background 0.15s;
}
.folder-q-card:hover {
  border-color: #93c5fd;
  background: #eff6ff;
}
.folder-q-card.has-data {
  background: #ffffff;
  border-color: #cbd5e1;
}
.folder-q-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  margin-bottom: 4px;
}
.folder-q-top small {
  font-size: 11px;
  color: #64748b;
}
.folder-q-val {
  font-size: 20px;
  font-weight: 800;
  color: #0f172a;
  font-variant-numeric: tabular-nums;
}
.folder-q-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 4px;
  font-size: 11px;
  color: #64748b;
}
.excel-upload-actions-top {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin: 10px 0 12px;
}
.excel-upload-hint {
  font-size: 12px;
  color: #64748b;
}
.excel-upload-preview {
  margin-top: 14px;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 12px;
  background: #f8fafc;
}
.excel-preview-empty {
  font-size: 12.5px;
  color: #64748b;
  text-align: center;
  padding: 10px;
}
.excel-preview-warn {
  font-size: 12.5px;
  color: #b45309;
  background: #fef3c7;
  border: 1px solid #fcd34d;
  border-radius: 8px;
  padding: 10px 12px;
}
.excel-preview-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 10px;
}
.excel-preview-badges {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}
.excel-preview-qgrid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}
.excel-preview-qcard {
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  padding: 8px 10px;
  background: #ffffff;
  font-size: 12px;
}
.excel-preview-qcard.active {
  border-color: #60a5fa;
  background: #eff6ff;
}
.excel-preview-qcard .val {
  font-size: 17px;
  font-weight: 800;
  color: #0f172a;
  margin: 3px 0;
}
@media (max-width: 720px) {
  .folder-q-cards, .excel-preview-qgrid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.excel-analysis-table-wrap {
  margin-top: 12px;
  max-height: 240px;
  overflow: auto;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  background: #ffffff;
}
.excel-analysis-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12px;
}
.excel-analysis-table th,
.excel-analysis-table td {
  padding: 6px 8px;
  border-bottom: 1px solid #f1f5f9;
  text-align: left;
}
.excel-analysis-table th {
  position: sticky;
  top: 0;
  background: #f8fafc;
  color: #334155;
  font-weight: 700;
  z-index: 1;
}
.excel-ach-pill {
  display: inline-block;
  padding: 2px 7px;
  border-radius: 6px;
  font-weight: 700;
  font-size: 11px;
}
.excel-ach-pill.tone-good { background: #dcfce7; color: #166534; }
.excel-ach-pill.tone-warn { background: #fef3c7; color: #92400e; }
.excel-ach-pill.tone-bad  { background: #fee2e2; color: #991b1b; }
.excel-insights-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-top: 10px;
}
.excel-insight-box {
  border-radius: 8px;
  padding: 10px 12px;
  font-size: 12px;
  border: 1px solid #e2e8f0;
  background: #ffffff;
}
.excel-insight-box.is-critical {
  border-color: #fecaca;
  background: #fff5f5;
}
.excel-insight-box.is-strength {
  border-color: #bbf7d0;
  background: #f0fdf4;
}
.excel-insight-box h5 {
  margin: 0 0 6px;
  font-size: 12.5px;
}
.excel-insight-box ul {
  margin: 0;
  padding-left: 16px;
}
.excel-insight-box li {
  margin-bottom: 3px;
}
.excel-insight-box p {
  margin: 0;
  color: #64748b;
}
@media (max-width: 720px) {
  .excel-insights-grid {
    grid-template-columns: 1fr;
  }
}
