/* =====================================================================
   Portal Dokumen Keuangan Rektorat — lapisan tema di atas AdminLTE 3.2
   Palet: tinta biru tua (navigasi), permukaan buku besar (abu dingin),
   kunyit (aksen fokus & penanda aktif), status bernada tanah.
   ===================================================================== */
@font-face { font-family: "Plus Jakarta Sans"; font-weight: 400; font-display: swap; src: url("../vendor/fonts/plus-jakarta-sans-latin-400-normal.woff2") format("woff2"); }
@font-face { font-family: "Plus Jakarta Sans"; font-weight: 500; font-display: swap; src: url("../vendor/fonts/plus-jakarta-sans-latin-500-normal.woff2") format("woff2"); }
@font-face { font-family: "Plus Jakarta Sans"; font-weight: 600; font-display: swap; src: url("../vendor/fonts/plus-jakarta-sans-latin-600-normal.woff2") format("woff2"); }
@font-face { font-family: "Plus Jakarta Sans"; font-weight: 700; font-display: swap; src: url("../vendor/fonts/plus-jakarta-sans-latin-700-normal.woff2") format("woff2"); }
@font-face { font-family: "Plus Jakarta Sans"; font-weight: 800; font-display: swap; src: url("../vendor/fonts/plus-jakarta-sans-latin-800-normal.woff2") format("woff2"); }

:root {
    --ink: #1b3354;
    --ink-deep: #132640;
    --ink-soft: #2c4a72;
    --surface: #f3f5f8;
    --paper: #ffffff;
    --rule: #dde3ea;
    --text: #1c2633;
    --muted: #5b6878;
    --kunyit: #c08a24;
    --kunyit-soft: #f6ead2;
    --ok: #2f7d5b;
    --warn: #a8701a;
    --bad: #b3443b;
    --revise: #c4622d;
    --info: #2b6cb0;
    --radius: 6px;
    --font: "Plus Jakarta Sans", "Segoe UI", system-ui, -apple-system, Roboto, sans-serif;
}

body, .main-header, .main-sidebar, .content-wrapper, .btn, .form-control, .custom-select, .dropdown-menu, .table {
    font-family: var(--font);
}
body { color: var(--text); font-size: 0.925rem; letter-spacing: 0.005em; }
.content-wrapper { background: var(--surface); }
.num, .table td.num, .ledger-value { font-variant-numeric: tabular-nums; }
a { color: var(--info); }
h1, h2, h3, h4, h5 { font-weight: 700; color: var(--ink-deep); letter-spacing: -0.01em; }
.content-header h1 { font-size: 1.45rem; font-weight: 800; }
.content-header .lead-sub { color: var(--muted); font-size: 0.9rem; margin-top: 0.15rem; }

/* Fokus keyboard yang jelas */
:focus-visible { outline: 3px solid var(--kunyit) !important; outline-offset: 2px; }
.btn:focus, .form-control:focus, .custom-select:focus { box-shadow: 0 0 0 0.2rem rgba(192, 138, 36, 0.35); border-color: var(--kunyit); }

/* ---------- Sidebar ---------- */
.main-sidebar, .main-sidebar .brand-link { background: var(--ink) !important; }
.main-sidebar .brand-link { border-bottom: 1px solid rgba(255,255,255,0.08) !important; padding: 0.9rem 0.9rem; }
.brand-mark { display: inline-flex; align-items: center; justify-content: center; width: 2.1rem; height: 2.1rem; border-radius: 6px; background: var(--kunyit); color: var(--ink-deep); font-weight: 800; margin-right: 0.55rem; font-size: 0.95rem; }
.brand-text { font-weight: 700 !important; font-size: 0.95rem; color: #fff; }
.brand-sub { display: block; font-size: 0.7rem; color: rgba(255,255,255,0.6); font-weight: 500; margin-left: 2.65rem; margin-top: -0.35rem; }
.nav-sidebar .nav-link { color: rgba(255,255,255,0.78) !important; border-radius: 4px; font-weight: 500; }
.nav-sidebar .nav-link:hover { background: rgba(255,255,255,0.07) !important; color: #fff !important; }
.nav-sidebar .nav-link.active { background: rgba(255,255,255,0.1) !important; color: #fff !important; box-shadow: inset 3px 0 0 var(--kunyit) !important; }
.nav-sidebar .nav-header { color: rgba(255,255,255,0.45); font-size: 0.72rem; font-weight: 600; padding-top: 1rem; }
.sidebar .user-panel { border-bottom: 1px solid rgba(255,255,255,0.08) !important; }
.user-panel .info a { color: #fff; font-weight: 600; white-space: normal; line-height: 1.25; }
.user-panel .info small { color: rgba(255,255,255,0.6); }

/* ---------- Kartu ---------- */
.card { border-radius: var(--radius); box-shadow: none; border: 1px solid var(--rule); }
.card-header { background: var(--paper); border-bottom: 1px solid var(--rule); }
.card-title { font-weight: 700; font-size: 1rem; color: var(--ink-deep); }
.card-outline-kunyit { border-top: 3px solid var(--kunyit); }

/* ---------- Strip buku besar (statistik) ---------- */
.ledger { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); background: var(--paper); border: 1px solid var(--rule); border-radius: var(--radius); margin-bottom: 1.25rem; overflow: hidden; }
.ledger-cell { padding: 0.95rem 1.1rem; border-right: 1px solid var(--rule); border-bottom: 1px solid var(--rule); position: relative; color: inherit; display: block; }
a.ledger-cell:hover { background: #f8fafc; text-decoration: none; color: inherit; }
.ledger-label { color: var(--muted); font-size: 0.78rem; font-weight: 600; display: block; }
.ledger-value { font-size: 1.75rem; font-weight: 800; color: var(--ink-deep); line-height: 1.15; display: block; margin-top: 0.2rem; }
.ledger-cell::before { content: ""; position: absolute; left: 0; top: 0.95rem; bottom: 0.95rem; width: 3px; background: var(--tone, transparent); border-radius: 0 2px 2px 0; }
.tone-ok { --tone: var(--ok); } .tone-warn { --tone: var(--warn); } .tone-bad { --tone: var(--bad); }
.tone-revise { --tone: var(--revise); } .tone-ink { --tone: var(--ink-soft); } .tone-kunyit { --tone: var(--kunyit); }

/* ---------- Badge status ---------- */
.badge { font-weight: 600; font-size: 0.76rem; padding: 0.35em 0.65em; }
.bg-success, .badge.bg-success { background: var(--ok) !important; color: #fff; }
.bg-warning, .badge.bg-warning { background: #f3e3c2 !important; color: #7a4f0c !important; }
.bg-danger, .badge.bg-danger { background: var(--bad) !important; color: #fff; }
.bg-orange, .badge.bg-orange { background: var(--revise) !important; color: #fff !important; }
.bg-info, .badge.bg-info { background: var(--info) !important; color: #fff; }
.bg-primary, .badge.bg-primary { background: var(--ink-soft) !important; color: #fff; }
.bg-secondary, .badge.bg-secondary { background: #e4e8ee !important; color: #3c4858 !important; }
.bg-light, .badge.bg-light { background: #eef1f5 !important; color: #3c4858 !important; border: 1px solid var(--rule); }
.bg-dark, .badge.bg-dark { background: #3c4858 !important; color: #fff; }
.text-revise { color: var(--revise) !important; }

/* ---------- Tombol ---------- */
.btn { border-radius: 5px; font-weight: 600; }
.btn-primary { background: var(--ink); border-color: var(--ink); }
.btn-primary:hover, .btn-primary:focus { background: var(--ink-deep); border-color: var(--ink-deep); }
.btn-kunyit { background: var(--kunyit); border-color: var(--kunyit); color: var(--ink-deep); }
.btn-kunyit:hover { background: #a97818; color: #fff; }
.btn-outline-primary { color: var(--ink); border-color: var(--ink); }
.btn-outline-primary:hover { background: var(--ink); border-color: var(--ink); }

/* ---------- Tabel ---------- */
.table thead th { border-top: 0; border-bottom: 1px solid var(--rule); color: var(--muted); font-size: 0.78rem; font-weight: 700; background: #f8fafc; }
.table td { vertical-align: middle; border-top: 1px solid #edf0f4; }
.table-responsive { border-radius: var(--radius); }
.cell-title { font-weight: 600; color: var(--text); }
.cell-sub { color: var(--muted); font-size: 0.8rem; }

/* ---------- Filter bar ---------- */
.filter-bar { background: var(--paper); border: 1px solid var(--rule); border-radius: var(--radius); padding: 0.75rem; margin-bottom: 1rem; }
.filter-bar .form-control, .filter-bar .custom-select { font-size: 0.875rem; }

/* ---------- Pelat identitas fakultas (elemen khas) ---------- */
.identity-plate { display: flex; align-items: center; gap: 0.9rem; background: var(--ink); color: #fff; border-radius: var(--radius); padding: 1rem 1.2rem; margin-bottom: 1.25rem; position: relative; overflow: hidden; }
.identity-plate::after { content: ""; position: absolute; inset: 0; background: repeating-linear-gradient(135deg, rgba(255,255,255,0.035) 0 2px, transparent 2px 14px); pointer-events: none; }
.identity-plate .lock { flex: 0 0 auto; width: 2.75rem; height: 2.75rem; border-radius: 50%; background: var(--kunyit); color: var(--ink-deep); display: flex; align-items: center; justify-content: center; font-size: 1.15rem; }
.identity-plate .who { font-size: 1.25rem; font-weight: 800; line-height: 1.2; letter-spacing: -0.01em; }
.identity-plate .why { font-size: 0.8rem; color: rgba(255,255,255,0.72); margin-top: 0.15rem; }

/* ---------- Area unggah ---------- */
.dropzone { border: 2px dashed #b9c4d2; border-radius: var(--radius); background: var(--paper); padding: 2.2rem 1rem; text-align: center; cursor: pointer; transition: border-color .15s, background .15s; }
.dropzone:hover, .dropzone.is-over { border-color: var(--kunyit); background: #fffaf0; }
.dropzone .dz-icon { font-size: 2rem; color: var(--ink-soft); }
.dropzone .dz-title { font-weight: 700; margin-top: 0.5rem; color: var(--ink-deep); }
.dropzone .dz-hint { color: var(--muted); font-size: 0.85rem; }
.dropzone.is-disabled { opacity: 0.55; cursor: not-allowed; }
.upload-item { background: var(--paper); border: 1px solid var(--rule); border-radius: var(--radius); padding: 0.75rem 0.9rem; margin-top: 0.6rem; }
.upload-item .name { font-weight: 600; word-break: break-all; }
.upload-item .meta { color: var(--muted); font-size: 0.8rem; }
.upload-item .progress { height: 0.55rem; background: #e7ebf0; margin: 0.5rem 0 0.35rem; }
.upload-item .progress-bar { background: var(--ink-soft); transition: width .25s linear; }
.upload-item.is-done .progress-bar { background: var(--ok); }
.upload-item.is-error .progress-bar { background: var(--bad); }
.upload-item .ref { font-weight: 700; color: var(--ok); font-variant-numeric: tabular-nums; }

/* ---------- Login ---------- */
.auth-shell { min-height: 100vh; display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); background: var(--surface); }
.auth-aside { background: var(--ink); color: #fff; padding: 3rem; display: flex; flex-direction: column; justify-content: space-between; position: relative; overflow: hidden; }
.auth-aside::after { content: ""; position: absolute; inset: 0; background: repeating-linear-gradient(135deg, rgba(255,255,255,0.03) 0 2px, transparent 2px 16px); pointer-events: none; }
.auth-aside h1 { color: #fff; font-size: 2.1rem; font-weight: 800; line-height: 1.15; max-width: 18ch; }
.auth-aside p { color: rgba(255,255,255,0.75); max-width: 46ch; }
.auth-aside .org { font-weight: 700; color: var(--kunyit); }
.auth-main { display: flex; align-items: center; justify-content: center; padding: 2rem 1.25rem; }
.auth-card { width: 100%; max-width: 400px; }
.auth-card h2 { font-size: 1.35rem; font-weight: 800; }
@media (max-width: 860px) { .auth-shell { grid-template-columns: 1fr; } .auth-aside { padding: 1.75rem; } .auth-aside h1 { font-size: 1.5rem; } .auth-aside .foot { display: none; } }

/* ---------- Lain-lain ---------- */
.note-box { background: #fff7ee; border-left: 3px solid var(--revise); padding: 0.65rem 0.8rem; border-radius: 0 4px 4px 0; font-size: 0.875rem; }
.secret { background: var(--kunyit-soft); color: var(--ink-deep); padding: 0.1rem 0.4rem; border-radius: 3px; font-size: 1rem; user-select: all; }
.dl-grid { display: grid; grid-template-columns: max-content 1fr; gap: 0.35rem 1rem; margin: 0; }
.dl-grid dt { color: var(--muted); font-weight: 600; font-size: 0.85rem; }
.dl-grid dd { margin: 0; }
.notif-item { white-space: normal; border-bottom: 1px solid #eef1f4; }
.notif-item.unread { background: #fbf6ea; }
.notif-item .t { font-weight: 700; font-size: 0.85rem; }
.notif-item .m { font-size: 0.8rem; color: var(--muted); }
.dropdown-menu-notif { width: 340px; max-width: 92vw; }
.empty-state { text-align: center; padding: 2.5rem 1rem; color: var(--muted); }
.empty-state i { font-size: 1.8rem; color: #b9c4d2; margin-bottom: 0.6rem; }
.timeline-mini { list-style: none; padding: 0; margin: 0; }
.timeline-mini li { padding: 0.55rem 0 0.55rem 1.1rem; border-left: 2px solid var(--rule); position: relative; }
.timeline-mini li::before { content: ""; position: absolute; left: -6px; top: 0.85rem; width: 10px; height: 10px; border-radius: 50%; background: var(--paper); border: 2px solid var(--ink-soft); }
.deadline-chip { font-weight: 700; font-variant-numeric: tabular-nums; }
.chart-box { position: relative; height: 290px; }
.main-footer { font-size: 0.8rem; color: var(--muted); }
@media (prefers-reduced-motion: reduce) { * { transition: none !important; animation: none !important; } }
@media (max-width: 576px) { .ledger-value { font-size: 1.4rem; } .content-header h1 { font-size: 1.2rem; } }
