/* ==========================================================================
   E-Sign Verifikasi — Tema replika ra-esign.tangerangkota.go.id
   Font : "Source Sans 3"   |   Aksen: #0d6efd → #4f46e5
   ========================================================================== */
/* Font TIDAK di-load dari internet — disamakan dgn halaman aslinya, yang hanya
   mendeklarasikan "Source Sans 3" di stack tanpa meng-load webfont, sehingga
   browser memakai font sistem (Segoe UI di Windows). Biarkan sama agar tampilan
   identik. Bila ingin memaksa Source Sans 3, aktifkan @import berikut:
   @import url('https://fonts.googleapis.com/css2?family=Source+Sans+3:wght@200..900&display=swap'); */

:root {
  --bs-font-sans-serif: "Source Sans 3", system-ui, -apple-system, "Segoe UI",
    Roboto, "Helvetica Neue", "Noto Sans", "Liberation Sans", Arial, sans-serif;
  /* jangan override --bs-body-bg: biarkan putih agar sel tabel tetap putih,
     latar body diatur eksplisit di bawah (setara class bg-body-tertiary) */
  --bs-body-color: #212529;
  --bs-primary: #0d6efd;
  --bs-link-color: #0d6efd;
  --card-radius: 14px;
  --soft-border: #e9ecef;
  --brand-1: #0d6efd;
  --brand-2: #4f46e5;
  --head-grad: linear-gradient(90deg, #0d6efd 0%, #4f46e5 100%);
}

* { box-sizing: border-box; }

body {
  font-family: var(--bs-font-sans-serif);
  background-color: #f8f9fa;
  color: #212529;
  font-size: 16px;
  line-height: 1.5;
  margin: 0;
}

a { color: #0d6efd; text-decoration: none; }
a:hover { text-decoration: underline; }

/* ---- Card ---------------------------------------------------------------- */
.card {
  background: #fff;
  border-radius: var(--card-radius);
  border: 1px solid var(--soft-border);
  box-shadow: 0 1px 2px rgba(0,0,0,.05);
  overflow: hidden;
}
.card-outline { border-top: 3px solid var(--brand-1); }

.card-header {
  background: var(--head-grad);
  color: #fff;
  padding: 1rem;
  border-bottom: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
/* AdminLTE memakai clearfix ::after pada .card-header; di dalam flex ia menjadi
   flex-item ketiga sehingga badge "Valid" berada di tengah (identik aslinya). */
.card-header::after { content: ""; display: block; }
.card-title { color: #fff; font-size: 1.1rem; font-weight: 400; margin: 0; }
.card-title svg, .card-title i { opacity: .9; }
.card-body { padding: 1rem; }

/* ---- Typography ---------------------------------------------------------- */
h5 { font-size: 1.25rem; font-weight: 500; margin: 0 0 .5rem; }
/* h6: pakai bawaan Bootstrap (font-weight 500, margin 0 0 .5rem) — sama spt aslinya */
.signature-detail h6 { font-weight: 600; }
.text-muted { color: #6c757d !important; }
.fw-semibold { font-weight: 600 !important; }

/* ---- Table --------------------------------------------------------------- */
.table-responsive { overflow-x: auto; }
table.table { width: 100%; border-collapse: collapse; margin-bottom: 1rem; }
/* biarkan padding & border-bawah dari Bootstrap (.table-sm) apa adanya — itulah
   "garis lurus" antar baris yang terlihat di halaman asli. */
.table-sm th { color: #6b7280; font-weight: 600; }
.table-sm td { color: #111827; }

/* ---- Badges -------------------------------------------------------------- */
/* .badge & .bg-*: pakai bawaan Bootstrap (font-size .75em RELATIF, padding
   .35em .65em, teks #fff, radius 6px) supaya badge "Field: esc_…" dan "VALID"
   berukuran/warna sama persis seperti aslinya. Yang di-override hanya status
   badge halaman verifikasi (di bawah). */

.status-badge { font-size: .85rem; }
.status-valid { background-color: #28a745; }
.status-partial { background-color: #ffc107; color: #212529; }
.status-rejected { background-color: #dc3545; }
.status-invalid { background-color: #6c757d; }
.status-not-found { background-color: #343a40; }

/* ---- Buttons ------------------------------------------------------------- */
.btn {
  display: inline-block; padding: .375rem .75rem; border-radius: .375rem;
  border: 1px solid transparent; font-size: .875rem; font-weight: 400;
  cursor: pointer; text-align: center; text-decoration: none; line-height: 1.5;
}
.btn:hover { text-decoration: none; }
.btn-sm { padding: .25rem .5rem; font-size: .8125rem; border-radius: .25rem; }
.btn-info { background-color: #0dcaf0; border-color: #0dcaf0; color: #000; }
.btn-info:hover { background-color: #0bb2d4; }
.btn-outline-primary { color: #0d6efd; border-color: #0d6efd; background: transparent; }
.btn-outline-primary:hover { background-color: #0d6efd; color: #fff; }
.btn-outline-light { color: #fff; border-color: rgba(255,255,255,.6); background: transparent; }
.btn-outline-light:hover { background-color: rgba(255,255,255,.15); color: #fff; }
.btn-primary { background-color: #0d6efd; border-color: #0d6efd; color: #fff; }
.btn-primary:hover { background-color: #0b5ed7; }
.btn-danger { background-color: #dc3545; border-color: #dc3545; color: #fff; }
.btn-danger:hover { background-color: #bb2d3b; }
.btn-secondary { background-color: #6c757d; border-color: #6c757d; color: #fff; }
.btn-light { background-color: #f8f9fa; border-color: #dee2e6; color: #212529; }

/* ---- Progress ------------------------------------------------------------ */
.progress { background-color: #eef2ff; border-radius: .375rem; overflow: hidden; }
.progress-bar {
  background-color: #28a745; color: #fff; text-align: center;
  transition: width .6s ease; height: 100%;
}
.progress-bar.bg-success { background-color: #28a745; }

/* ---- Signature detail ---------------------------------------------------- */
.signature-detail { font-size: .9rem; }
.signature-detail .list-unstyled { list-style: none; padding-left: 0; margin: 0; }
.signature-detail .list-unstyled li { margin-bottom: .25rem; }
.signature-detail .list-unstyled li, .signature-detail table td { font-weight: 500; }
.signature-detail h6, .signature-detail strong { font-weight: 600; }
.signature-detail .text-muted { font-size: .85rem; }
.signature-detail h6.border-bottom { border-bottom: 1px solid #dee2e6; padding-bottom: .25rem; }

/* ---- Utilities ----------------------------------------------------------- */
/* .container: pakai milik Bootstrap (responsif) — jangan override max-width */
.py-4 { padding-top: 1.5rem; padding-bottom: 1.5rem; }
.mb-0{margin-bottom:0}.mb-1{margin-bottom:.25rem}.mb-2{margin-bottom:.5rem}
.mb-3{margin-bottom:1rem}.mb-4{margin-bottom:1.5rem}.mt-1{margin-top:.25rem}
.mt-2{margin-top:.5rem}.mt-3{margin-top:1rem}.me-1{margin-right:.25rem}
.me-2{margin-right:.5rem}.pb-1{padding-bottom:.25rem}.p-0{padding:0}
.d-flex{display:flex}.d-block{display:block}.d-none{display:none}
.justify-content-between{justify-content:space-between}
.justify-content-center{justify-content:center}
.align-items-center{align-items:center}.text-end{text-align:right}
.text-md-end{text-align:right}.small{font-size:.875rem}
.visually-hidden{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0,0,0,0)}
hr { border: 0; border-top: 1px solid; color: inherit; opacity: .25; margin: 1rem 0; }

/* Grid: JANGAN override .row/.col-* — pakai grid bawaan Bootstrap (CDN) supaya
   .col-md-6 = 50%, .col-md-4 = 33%, dst. (sebelumnya tertimpa jadi 100% & menumpuk). */
@media (max-width: 576px) {
  .card-header .status-badge { margin-top: .5rem; }
}

/* ---- Form controls ------------------------------------------------------- */
.form-label { display: block; margin-bottom: .35rem; font-weight: 600; color: #374151; }
.form-control, .form-select {
  width: 100%; padding: .45rem .7rem; border: 1px solid #ced4da;
  border-radius: .375rem; font-family: inherit; font-size: 1rem;
  color: #212529; background: #fff;
}
.form-control:focus, .form-select:focus {
  border-color: #86b7fe; outline: 0; box-shadow: 0 0 0 .2rem rgba(13,110,253,.25);
}
textarea.form-control { min-height: 70px; resize: vertical; }
.form-text { font-size: .8rem; color: #6c757d; }

/* ---- Alert --------------------------------------------------------------- */
.alert { padding: .85rem 1rem; border-radius: .5rem; border: 1px solid transparent; margin-bottom: 1rem; }
.alert-success { background: #d1e7dd; border-color: #badbcc; color: #0f5132; }
.alert-danger { background: #f8d7da; border-color: #f5c2c7; color: #842029; }
.alert-info { background: #cff4fc; border-color: #b6effb; color: #055160; }

/* ---- Modal --------------------------------------------------------------- */
.modal { position: fixed; inset: 0; z-index: 1055; display: none; background: rgba(0,0,0,.5); }
.modal.show { display: block; overflow: auto; }
.modal-dialog { margin: 1.75rem auto; max-width: 1140px; }
.modal-dialog-scrollable { max-height: calc(100vh - 3.5rem); }
.modal-content { background: #fff; border-radius: .5rem; overflow: hidden; position: relative; }
.modal-header { display: flex; justify-content: space-between; align-items: center; padding: 1rem 1.25rem; border-bottom: 1px solid #dee2e6; }
.modal-title { font-size: 1.1rem; font-weight: 500; margin: 0; }
.modal-body { padding: 1rem 1.25rem; }
.btn-close { background: transparent; border: 0; font-size: 1.25rem; line-height: 1; cursor: pointer; color: #000; opacity: .5; }
.btn-close:hover { opacity: .8; }
iframe { border: 0; }
