/* Shell aplikasi — ganti nuansa AdminLTE jadi produk mandiri */
.app-shell,
.auth-gate {
    font-family: "Plus Jakarta Sans", "Segoe UI", system-ui, sans-serif;
    -webkit-font-smoothing: antialiased;
}

/* —— Sidebar —— */
.app-shell .main-sidebar.app-sidebar {
    background: linear-gradient(185deg, #073532 0%, #0a5c56 38%, #0e6e68 100%) !important;
    box-shadow: none !important;
    border-right: 0;
}

.app-shell .brand-link.app-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 1.1rem 1rem;
    background: rgba(0, 0, 0, 0.14) !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08) !important;
}

.app-brand-mark {
    width: 36px;
    height: 36px;
    border-radius: 11px;
    background: rgba(255, 255, 255, 0.14);
    display: grid;
    place-items: center;
    color: #fff;
    font-size: 0.95rem;
}

.app-shell .brand-link .brand-text {
    color: #fff !important;
    font-weight: 800 !important;
    letter-spacing: -0.03em;
    font-size: 1.02rem;
}

.app-shell .sidebar {
    padding: 0.35rem 0 1rem;
}

.app-shell .nav-sidebar .nav-item {
    margin-bottom: 2px;
}

.app-shell .nav-sidebar > .nav-item > .nav-link {
    margin: 0 10px;
    width: calc(100% - 20px);
    border-radius: 12px;
    color: rgba(255, 255, 255, 0.82);
    font-weight: 600;
    font-size: 0.88rem;
    transition: background 0.15s ease, color 0.15s ease;
}

.app-shell .nav-sidebar .nav-icon {
    color: rgba(255, 255, 255, 0.9);
    font-size: 0.95rem;
    width: 1.6rem;
}

.app-shell .nav-sidebar > .nav-item > .nav-link:hover {
    background: rgba(255, 255, 255, 0.1) !important;
    color: #fff;
}

.app-shell .nav-sidebar > .nav-item > .nav-link.active {
    background: rgba(255, 255, 255, 0.18) !important;
    color: #fff !important;
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.12);
}

.app-shell .nav-treeview {
    padding-left: 0.35rem;
}

.app-shell .nav-treeview > .nav-item > .nav-link {
    margin: 0 10px 0 18px;
    width: calc(100% - 28px);
    border-radius: 10px;
    color: rgba(255, 255, 255, 0.72);
    font-size: 0.82rem;
    font-weight: 600;
}

.app-shell .nav-treeview .nav-icon.fa-circle {
    display: none;
}

.app-shell .nav-treeview .nav-link.active {
    background: rgba(255, 255, 255, 0.12) !important;
    color: #fff !important;
}

.app-shell .nav-sidebar .badge {
    border-radius: 999px;
    font-weight: 700;
    padding: 0.2rem 0.45rem;
}

.app-shell .has-treeview.menu-open > .nav-link {
    background: rgba(255, 255, 255, 0.08);
}

/* —— Top bar —— */
.app-shell .main-header.app-topbar {
    background: rgba(255, 255, 255, 0.94) !important;
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--line) !important;
    box-shadow: 0 4px 24px rgba(14, 47, 44, 0.04);
    min-height: 58px;
}

.app-shell .main-header .nav-link {
    color: var(--ink) !important;
    font-weight: 600;
    font-size: 0.88rem;
}

.app-shell .main-header .btn-link.nav-link {
    color: var(--accent) !important;
    text-decoration: none;
}

.app-shell .main-header .nav-link .badge {
    border-radius: 999px;
}

.app-shell .app-topbar-meta {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 0.35rem 0.7rem;
    margin-right: 0.35rem;
    border-radius: 999px;
    background: #eef6f5;
    color: var(--ink);
    font-size: 0.8rem;
    font-weight: 700;
}

.app-shell .app-topbar-field {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-right: 0.5rem;
    padding: 0.4rem 0.75rem;
    border-radius: 999px;
    background: var(--accent);
    color: #fff !important;
    font-size: 0.78rem;
    font-weight: 700;
    text-decoration: none !important;
}

.app-shell .app-topbar-field:hover {
    background: var(--accent-dark);
    color: #fff;
}

/* —— Konten —— */
.app-shell .content-wrapper {
    background: linear-gradient(180deg, #f2f7f6 0%, #f8fafb 120px, #f4f7f8 100%);
}

.app-shell .content-header {
    padding: 1.35rem 1.35rem 0.5rem;
}

.app-shell .content-header h1 {
    font-size: 1.55rem;
    font-weight: 800;
    letter-spacing: -0.04em;
}

.app-shell .content-header .app-kicker {
    font-size: 0.9rem;
    max-width: 52rem;
}

.app-shell .content {
    padding: 0 1.35rem 1.75rem;
}

.app-shell .main-footer {
    background: transparent;
    border-top: 1px solid var(--line);
    color: var(--muted);
    padding: 0.9rem 1.25rem;
}

/* —— Kartu & widget —— */
.app-shell .card {
    border-radius: 1rem;
    box-shadow: 0 6px 24px rgba(15, 40, 38, 0.04);
}

.app-shell .card-header {
    font-size: 0.95rem;
    font-weight: 800;
    letter-spacing: -0.02em;
}

.app-shell .info-box,
.app-shell .small-box {
    border-radius: 1rem;
    border: 1px solid var(--line);
    background: #fff !important;
    overflow: hidden;
    box-shadow: 0 4px 18px rgba(14, 70, 66, 0.05);
}

.app-shell .info-box-icon {
    border-radius: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.35rem;
    width: 78px;
}

.app-shell .bg-teal {
    background: linear-gradient(145deg, #0e6e68, #138f87) !important;
}

.app-shell .bg-info {
    background: linear-gradient(145deg, #1a7f9a, #2aa0b8) !important;
}

.app-shell .bg-success {
    background: linear-gradient(145deg, #157a52, #1f9a6c) !important;
}

.app-shell .bg-warning {
    background: linear-gradient(145deg, #c47d14, #e8a020) !important;
}

.app-shell .bg-primary {
    background: linear-gradient(145deg, #3d6fd6, #5a8af0) !important;
}

.app-shell .bg-orange {
    background: linear-gradient(145deg, #d97814, #f59b34) !important;
}

.app-shell .bg-danger {
    background: linear-gradient(145deg, #c43d3d, #e25555) !important;
}

.app-shell .bg-secondary {
    background: linear-gradient(145deg, #6d7a86, #8a96a2) !important;
}

.app-shell .info-box-content {
    padding: 0.65rem 0.85rem;
}

.app-shell .info-box-text {
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: var(--muted);
}

.app-shell .info-box-number {
    font-size: 1.35rem;
    font-weight: 800;
    color: var(--ink);
}

.app-shell .small-box {
    min-height: 120px;
}

.app-shell .small-box .inner h3 {
    font-weight: 800 !important;
    letter-spacing: -0.03em;
}

.app-shell .small-box .inner p {
    font-weight: 600;
    color: var(--muted) !important;
}

.app-shell .small-box .icon {
    color: rgba(14, 110, 104, 0.12) !important;
    font-size: 4.2rem;
    right: 12px;
}

.app-shell .callout {
    border-left: 4px solid var(--accent);
    background: #fff;
    border-radius: 0.9rem;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.03);
}

.app-shell .callout-info {
    border-left-color: var(--accent);
}

/* —— Tombol & form global di shell —— */
.app-shell .btn-primary,
.auth-gate .btn-primary {
    background: linear-gradient(180deg, #138f87, var(--accent));
    border-color: var(--accent-dark);
    box-shadow: 0 4px 14px rgba(14, 110, 104, 0.22);
}

.app-shell .btn-primary:hover,
.auth-gate .btn-primary:hover {
    background: var(--accent-dark);
    border-color: var(--accent-dark);
}

.app-shell .btn-sm {
    border-radius: 0.5rem;
    font-weight: 700;
}

.app-shell h2.h5 {
    font-weight: 800;
    letter-spacing: -0.02em;
    color: var(--ink);
}

/* —— Login —— */
.auth-gate.login-page {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    margin: 0;
    padding: 1.5rem;
    background:
        radial-gradient(circle at 15% 10%, rgba(14, 110, 104, 0.22), transparent 42%),
        radial-gradient(circle at 85% 90%, rgba(14, 110, 104, 0.12), transparent 40%),
        linear-gradient(165deg, #e8f2f1, #f6f8f7 45%, #f3f0ea);
}

.auth-gate .login-box {
    width: min(440px, 100%);
}

.auth-gate .login-hero {
    text-align: center;
    margin-bottom: 1.15rem;
}

.auth-gate .login-mark {
    display: inline-grid;
    place-items: center;
    width: 52px;
    height: 52px;
    margin-bottom: 0.65rem;
    border-radius: 16px;
    background: linear-gradient(145deg, #0e6e68, #12897f);
    color: #fff;
    font-size: 1.2rem;
    box-shadow: 0 10px 28px rgba(14, 110, 104, 0.28);
}

.auth-gate .login-logo {
    font-size: 1.55rem;
    font-weight: 800;
    letter-spacing: -0.04em;
    color: var(--ink);
}

.auth-gate .login-logo b {
    color: var(--accent);
}

.auth-gate .login-tagline {
    margin: 0.35rem 0 0;
    color: var(--muted);
    font-size: 0.88rem;
    font-weight: 600;
}

.auth-gate .login-card {
    border: 1px solid rgba(14, 110, 104, 0.08);
    border-radius: 1.15rem;
    box-shadow: 0 18px 48px rgba(22, 40, 38, 0.1);
}

.auth-gate .login-box-msg {
    color: var(--muted);
    font-weight: 600;
    font-size: 0.9rem;
}

@media (max-width: 991.98px) {
    .app-shell .content {
        padding-left: 1rem;
        padding-right: 1rem;
    }

    .app-shell .app-topbar-meta {
        display: none;
    }
}