/* ============================================================
   SERVICE CATALOG - daftar katalog Service Desk
   ------------------------------------------------------------
   Dipakai bersama oleh:
     - Beranda (index)          : HANYA TAMPIL
     - /service-catalog         : HANYA TAMPIL
     - Dashboard administrator : Ubah & Hapus
   ============================================================ */

.sc-head{
  display:flex;align-items:flex-start;justify-content:space-between;
  gap:14px;flex-wrap:wrap;margin-bottom:14px;
}
.sc-head h2{margin:0;font-size:18px;line-height:1.35}
.sc-head p{margin:5px 0 0;font-size:13px;color:var(--text-soft, #486581);line-height:1.5}
.sc-badge{
  display:inline-flex;align-items:center;gap:6px;white-space:nowrap;
  font-size:12px;font-weight:800;padding:7px 13px;border-radius:999px;
  border:1px solid #cddbec;background:#f2f7fc;color:#486581;
}
.sc-badge.is-ok{background:#ecfdf5;border-color:#a7e3c5;color:#047857}
.sc-badge.is-err{background:#fff1f0;border-color:#f0b7b0;color:#b42318}

/* ---------- kontrol ---------- */
.sc-kontrol{display:flex;gap:12px;flex-wrap:wrap;align-items:flex-end;margin-bottom:12px}
.sc-field{display:flex;flex-direction:column;gap:5px;min-width:0}
.sc-field>span{font-size:11px;font-weight:800;letter-spacing:.05em;text-transform:uppercase;color:#486581}
.sc-field select,.sc-field input{
  height:38px;padding:0 11px;border:1px solid #d5e2ee;border-radius:9px;
  background:#fff;color:#102a43;font:inherit;font-size:13px;box-sizing:border-box;
}
.sc-field select:focus-visible,.sc-field input:focus-visible{outline:2px solid #2f86d6;outline-offset:1px}
.sc-pilih-sheet{flex:0 1 320px;min-width:200px}
.sc-cari{flex:1 1 260px}
.sc-cari input{width:100%}

.sc-hint{margin:0 0 10px;font-size:11.5px;color:#829ab1;display:flex;gap:6px;flex-wrap:wrap}
.sc-hint b{color:#0f4c81;font-weight:800}

/* ---------- daftar ---------- */
.sc-list-wrap{position:relative}
.sc-list{
  list-style:none;margin:0;padding:0;max-height:560px;overflow:auto;
}
.sc-list.is-gulir{height:440px;padding-bottom:56px}
.sc-list::-webkit-scrollbar{width:10px}
.sc-list::-webkit-scrollbar-track{background:#f2f7fb;border-radius:999px}
.sc-list::-webkit-scrollbar-thumb{background:#c3d9ec;border-radius:999px;border:2px solid #f2f7fb}
.sc-list::-webkit-scrollbar-thumb:hover{background:#9fc0e0}

.sc-item{
  display:block;padding:12px 14px;margin:0 0 8px;border:1px solid #e4edf5;
  border-left:3px solid #0f4c81;border-radius:12px;background:#fff;
}
.sc-item:hover{border-color:#c9dcef;background:#fbfdff}
.sc-item-head{display:flex;align-items:flex-start;justify-content:space-between;gap:10px;flex-wrap:wrap}
.sc-title{font-size:13.5px;font-weight:800;color:#102a43;line-height:1.4;overflow-wrap:anywhere}
.sc-sheet{
  flex:none;font-size:10px;font-weight:800;text-transform:uppercase;letter-spacing:.04em;
  padding:3px 8px;border-radius:999px;background:#eaf4fd;color:#0f4c81;white-space:nowrap;
}
.sc-meta{margin:5px 0 0;font-size:11.5px;color:#627d98;line-height:1.5;overflow-wrap:anywhere}
.sc-meta span{display:inline-block;margin-right:10px}
.sc-aksi{display:flex;gap:8px;margin-top:10px;flex-wrap:wrap}
.sc-btn{
  display:inline-flex;align-items:center;gap:6px;height:30px;padding:0 12px;
  border:1px solid #9fc0e0;border-radius:8px;background:#fff;color:#0f4c81;
  font:inherit;font-size:12px;font-weight:800;cursor:pointer;
}
.sc-btn:hover{background:#eaf3fb;border-color:#0f4c81}
.sc-btn-danger{border-color:#f0b7b0;background:#fff5f4;color:#b42318}
.sc-btn-danger:hover{background:#ffe8e5;border-color:#e58d83}
.sc-kosong{padding:24px 12px;text-align:center;color:#829ab1;font-size:13px;font-style:italic}
.sc-foot{margin:10px 0 0;font-size:11.5px;color:#829ab1}

/* ---------- modal ubah (dashboard administrator) ---------- */
.sc-modal{position:fixed;inset:0;z-index:90;display:grid;place-items:center;padding:18px;background:rgba(15,23,42,.45)}
.sc-modal[hidden]{display:none}
.sc-modal-box{
  width:min(760px,100%);max-height:86vh;display:flex;flex-direction:column;
  background:#fff;border-radius:16px;box-shadow:0 24px 60px rgba(15,23,42,.28);overflow:hidden;
}
.sc-modal-head{display:flex;align-items:flex-start;justify-content:space-between;gap:12px;padding:16px 18px;border-bottom:1px solid #e6eef6}
.sc-modal-head h3{margin:0;font-size:16px}
.sc-modal-head p{margin:4px 0 0;font-size:12px;color:#627d98}
.sc-modal-body{padding:16px 18px;overflow:auto}
.sc-modal-foot{display:flex;gap:10px;justify-content:flex-end;padding:14px 18px;border-top:1px solid #e6eef6;background:#f8fbfe}
.sc-edit-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(280px,1fr));gap:12px}
.sc-edit-field{display:flex;flex-direction:column;gap:5px}
.sc-edit-field>span{font-size:11px;font-weight:800;letter-spacing:.04em;text-transform:uppercase;color:#486581}
.sc-edit-field input,.sc-edit-field textarea{
  width:100%;border:1px solid #d5e2ee;border-radius:9px;padding:8px 10px;
  font:inherit;font-size:12.5px;color:#102a43;background:#fff;box-sizing:border-box;
}
.sc-edit-field textarea{min-height:74px;resize:vertical}
.sc-edit-field input:focus-visible,.sc-edit-field textarea:focus-visible{outline:2px solid #2f86d6;outline-offset:1px}
.sc-modal-msg{font-size:12.5px;font-weight:700;margin-right:auto;align-self:center}
.sc-modal-msg.is-err{color:#b42318}
.sc-modal-msg.is-ok{color:#047857}

/* ---------- mode gelap ---------- */
html[data-theme="dark"] .sc-item{background:#16223c;border-color:#243a5e;border-left-color:#4a6ea8}
html[data-theme="dark"] .sc-item:hover{background:#1b2a49}
html[data-theme="dark"] .sc-title{color:#e6edf7}
html[data-theme="dark"] .sc-meta{color:#9fb3c8}
html[data-theme="dark"] .sc-field select,html[data-theme="dark"] .sc-field input{background:#16223c;border-color:#31456d;color:#e6edf7}
html[data-theme="dark"] .sc-hint{color:#9fb3c8}
html[data-theme="dark"] .sc-hint b{color:#7db4f5}
html[data-theme="dark"] .sc-badge{background:#16223c;border-color:#31456d;color:#9fb3c8}
html[data-theme="dark"] .sc-btn{background:#1b2a49;border-color:#31456d;color:#cfe1f8}
html[data-theme="dark"] .sc-btn:hover{background:#24365c;border-color:#4a6ea8}
html[data-theme="dark"] .sc-btn-danger{background:#2a1a1a;border-color:#6b3833;color:#fca5a5}
html[data-theme="dark"] .sc-modal{background:rgba(2,8,23,.66)}
html[data-theme="dark"] .sc-modal-box{background:#131d33;border:1px solid #243a5e}
html[data-theme="dark"] .sc-modal-head,html[data-theme="dark"] .sc-modal-foot{border-color:#243a5e}
html[data-theme="dark"] .sc-modal-foot{background:#101a2e}
html[data-theme="dark"] .sc-modal-head p{color:#9fb3c8}
html[data-theme="dark"] .sc-edit-field>span{color:#9fb3c8}
html[data-theme="dark"] .sc-edit-field input,html[data-theme="dark"] .sc-edit-field textarea{background:#101a2e;border-color:#31456d;color:#e6edf7}

/* ---------- HP ---------- */
@media(max-width:640px){
  .sc-kontrol{flex-direction:column;align-items:stretch}
  .sc-pilih-sheet,.sc-cari{flex:1 1 auto;min-width:0}
  .sc-list{max-height:none;overflow:visible}
  .sc-list.is-gulir{height:auto;padding-bottom:0}
  .sc-item{padding:11px 12px}
  .sc-btn{height:32px}
}
