/* Compact UI overrides: Buttons, Navigation, Alerts */

body,
.content-wrapper {
  font-size: 0.82rem;
}

/* === 1. Tombol (Buttons) === */
.btn {
  font-size: 0.78rem;
  padding: 0.25rem 0.55rem;
  line-height: 1.35;
}

.btn-sm,
.btn-group-sm>.btn {
  font-size: 0.72rem;
  padding: 0.18rem 0.45rem;
  line-height: 1.3;
  border-radius: 0.2rem;
}

.btn-xs,
.btn-group-xs>.btn {
  font-size: 0.68rem;
  padding: 0.12rem 0.35rem;
  line-height: 1.2;
}

.btn-lg,
.btn-group-lg>.btn {
  font-size: 0.9rem;
  padding: 0.35rem 0.75rem;
  line-height: 1.4;
}

.btn-tool {
  font-size: 0.75rem;
  padding: 0.15rem 0.35rem;
}

/* === 2. Navigasi (Navbar, Sidebar, Tabs, Breadcrumb, Pagination) === */
.main-header.navbar {
  min-height: 42px;
  padding: 0.15rem 0.5rem;
}

.main-header .nav-link {
  height: 2rem;
  padding: 0.3rem 0.65rem;
  font-size: 0.84rem;
}

.main-header .navbar-badge {
  font-size: 0.55rem;
  padding: 2px 4px;
  top: 4px;
  right: 4px;
}

.navbar-nav>.user-menu .user-image {
  width: 1.5rem;
  height: 1.5rem;
  margin-top: -2px;
}

.brand-link {
  padding: 0.55rem 0.5rem;
  font-size: 0.95rem;
  line-height: 1.3;
}

.brand-link .brand-image {
  max-height: 26px;
  margin-top: -2px;
}

.nav-sidebar .nav-link {
  padding: 0.35rem 0.75rem;
  font-size: 0.82rem;
}

.nav-sidebar .nav-link>.right,
.nav-sidebar .nav-link>p>.right {
  top: 0.5rem;
  font-size: 0.75rem;
}

.nav-sidebar .nav-icon {
  font-size: 0.85rem;
  margin-right: 0.35rem;
}

.nav-treeview>.nav-item>.nav-link {
  padding: 0.28rem 0.75rem;
  font-size: 0.79rem;
}

.nav-tabs .nav-link,
.nav-pills .nav-link {
  padding: 0.32rem 0.65rem;
  font-size: 0.82rem;
}

.breadcrumb {
  padding: 0.35rem 0.65rem;
  font-size: 0.8rem;
}

.page-link {
  padding: 0.25rem 0.55rem;
  font-size: 0.78rem;
}

/* === 3. Alert & Notifikasi === */
.alert {
  padding: 0.45rem 0.85rem;
  font-size: 0.82rem;
  margin-bottom: 0.75rem;
  border-radius: 0.2rem;
}

.alert-dismissible {
  padding-right: 2.4rem;
}

.alert-dismissible .close {
  padding: 0.4rem 0.75rem;
  font-size: 1.05rem;
}

.alert h4,
.alert h5,
.alert .alert-heading {
  font-size: 0.9rem;
  margin-bottom: 0.25rem;
}

.swal2-popup {
  font-size: 0.78rem !important;
  padding: 0.85rem !important;
}

.swal2-title {
  font-size: 1.05rem !important;
}

.swal2-styled {
  padding: 0.3rem 0.85rem !important;
  font-size: 0.78rem !important;
}

#toast-container>div {
  padding: 8px 12px 8px 42px;
  font-size: 0.8rem;
  width: 260px;
}

/* === 4. Tabel (Tables & DataTables) === */
.table {
  font-size: 0.8rem;
  margin-bottom: 0.75rem;
}

.table th,
.table td {
  padding: 0.35rem 0.5rem;
  vertical-align: middle;
}

.table thead th {
  font-size: 0.78rem;
  padding: 0.42rem 0.5rem;
}

.table-sm th,
.table-sm td {
  padding: 0.25rem 0.4rem;
}

.dataTables_wrapper .dataTables_length,
.dataTables_wrapper .dataTables_filter,
.dataTables_wrapper .dataTables_info,
.dataTables_wrapper .dataTables_paginate {
  font-size: 0.78rem;
}

.dataTables_wrapper .dataTables_filter input,
.dataTables_wrapper .dataTables_length select {
  height: calc(1.5em + 0.35rem + 2px);
  padding: 0.18rem 0.4rem;
  font-size: 0.78rem;
}

.badge {
  font-size: 0.7rem;
  padding: 0.22em 0.45em;
}

/* === 5. Objek Form (Inputs, Selects, Select2, File, Input Group) === */
.form-group {
  margin-bottom: 0.65rem;
}

.form-control {
  height: calc(1.5em + 0.45rem + 2px);
  padding: 0.225rem 0.5rem;
  font-size: 0.8rem;
  line-height: 1.4;
  border-radius: 0.2rem;
}

textarea.form-control {
  height: auto;
  min-height: 64px;
}

select.form-control[multiple],
select.form-control[size] {
  height: auto;
}

.form-control-sm {
  height: calc(1.5em + 0.35rem + 2px);
  padding: 0.18rem 0.4rem;
  font-size: 0.75rem;
}

.input-group-text {
  padding: 0.225rem 0.5rem;
  font-size: 0.8rem;
}

.custom-file,
.custom-file-input,
.custom-file-label {
  height: calc(1.5em + 0.45rem + 2px);
  font-size: 0.8rem;
}

.custom-file-label {
  padding: 0.225rem 0.5rem;
  line-height: 1.4;
}

.custom-file-label::after {
  height: calc(1.5em + 0.45rem);
  padding: 0.225rem 0.5rem;
  font-size: 0.8rem;
  line-height: 1.4;
}

.form-check-input {
  margin-top: 0.22rem;
}

.custom-select {
  height: calc(1.5em + 0.45rem + 2px);
  padding: 0.225rem 1.5rem 0.225rem 0.5rem;
  font-size: 0.8rem;
  line-height: 1.4;
}

.custom-select[multiple],
.custom-select[size] {
  height: auto;
  padding-right: 0.5rem;
}

.custom-control-label {
  font-size: 0.8rem;
  padding-top: 0.05rem;
}

.custom-control-label::before,
.custom-control-label::after {
  width: 0.9rem;
  height: 0.9rem;
  top: 0.2rem;
}

.select2-container--bootstrap4 .select2-selection--single {
  height: calc(1.5em + 0.45rem + 2px) !important;
  font-size: 0.8rem;
}

.select2-container--bootstrap4 .select2-selection--single .select2-selection__rendered {
  line-height: calc(1.5em + 0.45rem) !important;
  padding-left: 0.5rem;
}

.select2-container--bootstrap4 .select2-selection--single .select2-selection__arrow {
  height: calc(1.5em + 0.45rem) !important;
}

.select2-container--bootstrap4 .select2-results__option {
  padding: 0.3rem 0.6rem;
  font-size: 0.8rem;
}

/* === 6. Label === */
label:not(.form-check-label):not(.custom-file-label),
.col-form-label {
  font-size: 0.8rem;
  margin-bottom: 0.25rem;
}

.form-check-label {
  font-size: 0.8rem;
}

.form-text,
small,
.small {
  font-size: 0.74rem;
}

/* === 7. Header (Halaman, Card, Modal, Box Statistik) === */
.content-header {
  padding: 8px 0.5rem;
}

.content-header h1 {
  font-size: 1.25rem;
  margin-bottom: 0;
}

.card-header {
  padding: 0.45rem 0.85rem;
}

.card-title {
  font-size: 0.92rem;
  margin-bottom: 0;
}

.card-body {
  padding: 0.75rem 0.85rem;
}

.card-footer {
  padding: 0.5rem 0.85rem;
}

.modal-header {
  padding: 0.55rem 0.85rem;
}

.modal-title {
  font-size: 0.98rem;
}

.modal-body {
  padding: 0.75rem 0.85rem;
  font-size: 0.82rem;
}

.modal-footer {
  padding: 0.45rem 0.85rem;
}

.small-box .inner h3 {
  font-size: 1.5rem;
}

.small-box .inner p {
  font-size: 0.82rem;
}

.info-box {
  min-height: 68px;
}

.info-box .info-box-icon {
  width: 56px;
  font-size: 1.4rem;
}

.callout {
  padding: 0.65rem 0.85rem;
  margin-bottom: 0.75rem;
  font-size: 0.8rem;
}

.callout h5 {
  font-size: 0.92rem;
  margin-bottom: 0.4rem;
}

.callout p {
  font-size: 0.8rem;
  margin-bottom: 0.4rem;
}