/* ============================================================
   LPPM STP Petrus — Stylesheet CMS Administrator
   ============================================================ */
:root {
  --navy: #183153; --royal: #315B91; --gold: #D6A84F; --bg: #F5F7FA;
  --text: #273449; --muted: #64748b; --sidebar-w: 262px; --sidebar-w-collapsed: 76px;
  --radius: 12px; --shadow: 0 6px 22px rgba(24,49,83,.08);
  --font-head: 'Plus Jakarta Sans', system-ui; --font-body: 'Inter', system-ui;
}
body.admin-body { font-family: var(--font-body); background: var(--bg); color: var(--text); font-size: .925rem; }
body.admin-body h1,body.admin-body h2,body.admin-body h3,body.admin-body h4,body.admin-body h5,body.admin-body h6 { font-family: var(--font-head); color: var(--navy); }

/* ---------- Layout ---------- */
.admin-sidebar { position: fixed; inset: 0 auto 0 0; width: var(--sidebar-w); background: linear-gradient(180deg, var(--navy), #12233f); color: #cdd8e6; z-index: 1040; display: flex; flex-direction: column; transition: width .22s ease; }
.admin-sidebar .brand { display: flex; align-items: center; gap: .7rem; padding: 1.05rem 1.25rem; border-bottom: 1px solid rgba(255,255,255,.07); }
.admin-sidebar .brand .logo-badge { width: 40px; height: 40px; border-radius: 10px; background: var(--gold); color: var(--navy); font-family: var(--font-head); font-weight: 800; display: grid; place-items: center; flex: 0 0 auto; }
.admin-sidebar .brand .logo-img { width: 40px; height: 40px; object-fit: contain; flex: 0 0 auto; }
.admin-sidebar .brand .t { font-family: var(--font-head); color: #fff; font-weight: 700; font-size: .92rem; line-height: 1.15; white-space: nowrap; }
.admin-sidebar .brand .s { font-size: .68rem; color: rgba(255,255,255,.55); white-space: nowrap; }
.admin-nav { flex: 1; overflow-y: auto; padding: .9rem .75rem; }
.admin-nav::-webkit-scrollbar { width: 5px; } .admin-nav::-webkit-scrollbar-thumb { background: rgba(255,255,255,.15); border-radius: 3px; }
.nav-group-title { font-size: .68rem; text-transform: uppercase; letter-spacing: .1em; color: rgba(255,255,255,.4); padding: .85rem .75rem .35rem; white-space: nowrap; }
.admin-nav a.nav-item { display: flex; align-items: center; gap: .7rem; color: #cdd8e6; font-weight: 600; font-size: .87rem; padding: .6rem .75rem; border-radius: 9px; margin-bottom: .15rem; white-space: nowrap; }
.admin-nav a.nav-item i { font-size: 1.02rem; width: 20px; text-align: center; flex: 0 0 auto; }
.admin-nav a.nav-item:hover { background: rgba(255,255,255,.07); color: #fff; }
.admin-nav a.nav-item.active { background: var(--royal); color: #fff; box-shadow: 0 4px 14px rgba(49,91,145,.5); }
.admin-nav a.nav-item .bubble { margin-left: auto; background: var(--gold); color: var(--navy); border-radius: 999px; font-size: .68rem; font-weight: 700; padding: 0 .5rem; }
.admin-sidebar .sidebar-footer { padding: .9rem 1rem; border-top: 1px solid rgba(255,255,255,.07); font-size: .78rem; color: rgba(255,255,255,.45); white-space: nowrap; }

.admin-main { margin-left: var(--sidebar-w); min-height: 100vh; transition: margin-left .22s ease; display: flex; flex-direction: column; }
body.sidebar-collapsed .admin-sidebar { width: var(--sidebar-w-collapsed); }
body.sidebar-collapsed .admin-sidebar .t, body.sidebar-collapsed .admin-sidebar .s,
body.sidebar-collapsed .admin-sidebar .nav-item span.lbl, body.sidebar-collapsed .nav-group-title,
body.sidebar-collapsed .sidebar-footer span { display: none; }
body.sidebar-collapsed .admin-sidebar .admin-nav a.nav-item { justify-content: center; }
body.sidebar-collapsed .admin-sidebar .brand { justify-content: center; }
body.sidebar-collapsed .admin-main { margin-left: var(--sidebar-w-collapsed); }

.admin-topbar { position: sticky; top: 0; z-index: 1030; background: rgba(255,255,255,.92); backdrop-filter: blur(6px); border-bottom: 1px solid rgba(24,49,83,.06); padding: .65rem 1.5rem; display: flex; align-items: center; gap: 1rem; min-height: 60px; }
.burger { border: none; background: transparent; font-size: 1.25rem; color: var(--navy); }
.page-title { font-family: var(--font-head); font-weight: 700; color: var(--navy); font-size: 1.05rem; margin: 0; }
.user-chip { display: flex; align-items: center; gap: .6rem; }
.user-chip .name { font-weight: 700; font-size: .85rem; color: var(--navy); line-height: 1.1; }
.user-chip .role { font-size: .7rem; color: var(--muted); }
.avatar-sm { width: 38px; height: 38px; border-radius: 50%; background: var(--royal); color: #fff; font-weight: 700; font-family: var(--font-head); display: grid; place-items: center; object-fit: cover; }

.admin-content { padding: 1.5rem; flex: 1; }

/* ---------- Kartu, tabel, form ---------- */
.admin-card { background: #fff; border-radius: var(--radius); box-shadow: var(--shadow); border: none; }
.admin-card .card-header { background: transparent; border-bottom: 1px solid rgba(24,49,83,.06); padding: 1rem 1.25rem; display: flex; align-items: center; justify-content: space-between; gap: 1rem; flex-wrap: wrap; }
.admin-card .card-header h6 { font-family: var(--font-head); font-weight: 700; margin: 0; }
.admin-table { margin: 0; font-size: .86rem; }
.admin-table thead th { background: #f7f9fc; color: #5b6c84; font-size: .72rem; text-transform: uppercase; letter-spacing: .07em; font-weight: 700; border-bottom: 1px solid rgba(24,49,83,.07); white-space: nowrap; }
.admin-table td { vertical-align: middle; border-color: rgba(24,49,83,.06); }
.admin-table .actions .btn { --bs-btn-padding-y: .2rem; --bs-btn-padding-x: .5rem; }
.row-title { font-weight: 700; color: var(--navy); }

.stat-tile { background: #fff; border-radius: var(--radius); box-shadow: var(--shadow); padding: 1.15rem 1.25rem; height: 100%; }
.stat-tile .t-icon { width: 46px; height: 46px; border-radius: 12px; display: grid; place-items: center; font-size: 1.3rem; }
.stat-tile .t-num { font-family: var(--font-head); font-weight: 800; font-size: 1.65rem; color: var(--navy); line-height: 1; }
.stat-tile .t-label { color: var(--muted); font-size: .8rem; }

.form-label { font-weight: 600; font-size: .84rem; color: #3c4a61; margin-bottom: .3rem; }
.form-control, .form-select { border-radius: 9px; border-color: #dde4ee; font-size: .88rem; }
.form-control:focus, .form-select:focus { border-color: var(--royal); box-shadow: 0 0 0 .2rem rgba(49,91,145,.12); }
.form-text { font-size: .76rem; }
.required::after { content: " *"; color: #dc3545; }

.site-badge { font-weight: 600; padding: .45em .8em; font-size: .7rem; }
.avatar-md { width: 64px; height: 64px; border-radius: 14px; object-fit: cover; background: #eef2f7; }

/* Login */
.login-wrap { min-height: 100vh; display: grid; grid-template-columns: 1.05fr 1fr; }
.login-hero { background: linear-gradient(150deg, var(--navy), var(--royal)); color: #fff; padding: 4rem; position: relative; overflow: hidden; }
.login-hero::after { content:""; position: absolute; inset: 0; background-image: radial-gradient(rgba(255,255,255,.07) 1px, transparent 1px); background-size: 24px 24px; }
.login-hero h2, .login-hero h3 { color: #fff; }
@media (max-width: 900px) { .login-wrap { grid-template-columns: 1fr; } .login-hero { padding: 2.4rem; min-height: 220px; } }

/* minim panjang teks editor */
.tiny-wrap .tox.tox-tinymce { border-radius: 9px; }

@media (max-width: 767px) { .admin-content { padding: 1rem; } .admin-topbar { padding: .65rem 1rem; } }
