
/* =========================================
   LOGIN PAGE - MODERN GREEN THEME
========================================= */

.login-page {
    --login-green: #087f5b;
    --login-green-dark: #065f46;
    --login-green-deep: #064e3b;
    --login-green-light: #d1fae5;
    --login-text: #18352b;
    --login-muted: #81928a;

    min-height: 100vh;
    margin: 0;
    padding: 0;

    font-family: "Inter", "Segoe UI", system-ui, Arial, sans-serif;

    background:
        radial-gradient(
            circle at 15% 15%,
            rgba(16, 185, 129, 0.15),
            transparent 35%
        ),
        radial-gradient(
            circle at 85% 85%,
            rgba(5, 150, 105, 0.12),
            transparent 35%
        ),
        #f4f8f5;

    color: var(--login-text);

    overflow-x: hidden;
}


/* =========================================
   BACKGROUND ANIMATION
========================================= */

.login-background {
    position: fixed;
    inset: 0;
    overflow: hidden;
    pointer-events: none;
    z-index: 0;
}

.login-orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(2px);
    opacity: 0.5;
    animation: loginFloat 12s ease-in-out infinite;
}

.login-orb-one {
    width: 380px;
    height: 380px;

    top: -130px;
    left: -100px;

    background: linear-gradient(
        135deg,
        #a7f3d0,
        #34d399
    );
}

.login-orb-two {
    width: 280px;
    height: 280px;

    bottom: -90px;
    right: -50px;

    background: linear-gradient(
        135deg,
        #6ee7b7,
        #059669
    );

    animation-delay: -4s;
}

.login-orb-three {
    width: 150px;
    height: 150px;

    top: 40%;
    right: 15%;

    background: linear-gradient(
        135deg,
        #d1fae5,
        #10b981
    );

    animation-delay: -7s;
}

@keyframes loginFloat {
    0%,
    100% {
        transform: translate3d(0, 0, 0) scale(1);
    }

    50% {
        transform: translate3d(0, -25px, 0) scale(1.04);
    }
}


/* =========================================
   MAIN LAYOUT
========================================= */

.login-wrapper {
    position: relative;
    z-index: 1;

    display: grid;
    grid-template-columns: 1fr 1fr;

    width: min(1120px, calc(100% - 48px));
    min-height: 680px;

    margin: 40px auto;

    background: rgba(255, 255, 255, 0.76);

    border: 1px solid rgba(255, 255, 255, 0.85);
    border-radius: 28px;

    box-shadow:
        0 30px 90px rgba(6, 78, 59, 0.12),
        0 8px 24px rgba(6, 78, 59, 0.06);

    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);

    overflow: hidden;

    animation: loginAppear 0.8s ease both;
}

@keyframes loginAppear {
    from {
        opacity: 0;
        transform: translateY(25px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}


/* =========================================
   LEFT SHOWCASE PANEL
========================================= */

.login-showcase {
    position: relative;

    display: flex;
    flex-direction: column;
    justify-content: space-between;

    padding: 42px;

    color: #fff;

    background:
        radial-gradient(
            circle at 90% 10%,
            rgba(52, 211, 153, 0.35),
            transparent 35%
        ),
        linear-gradient(
            145deg,
            #065f46 0%,
            #047857 48%,
            #059669 100%
        );

    overflow: hidden;
}

.login-showcase::before {
    content: "";

    position: absolute;

    width: 360px;
    height: 360px;

    right: -140px;
    bottom: -150px;

    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: 50%;

    box-shadow:
        0 0 0 35px rgba(255, 255, 255, 0.04),
        0 0 0 70px rgba(255, 255, 255, 0.03);
}

.login-showcase::after {
    content: "";

    position: absolute;

    width: 200px;
    height: 200px;

    top: 28%;
    right: -100px;

    border-radius: 50%;

    background: rgba(255, 255, 255, 0.07);
}


/* BRAND */

.login-brand {
    position: relative;
    z-index: 1;

    display: flex;
    align-items: center;
    gap: 12px;

    font-size: 19px;
    font-weight: 850;
    letter-spacing: 1px;
}

.login-brand-icon {
    display: flex;
    align-items: center;
    justify-content: center;

    width: 46px;
    height: 46px;

    color: #fff;

    background: rgba(255, 255, 255, 0.16);

    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 14px;

    backdrop-filter: blur(8px);
}

.login-brand-icon svg {
    width: 27px;
    height: 27px;
}

.login-brand-highlight {
    color: #a7f3d0;
}


/* SHOWCASE CONTENT */

.login-showcase-content {
    position: relative;
    z-index: 1;

    max-width: 450px;

    margin: 50px 0;
}

.login-badge {
    display: inline-flex;
    align-items: center;
    gap: 9px;

    padding: 8px 13px;

    color: #d1fae5;

    background: rgba(255, 255, 255, 0.1);

    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 30px;

    font-size: 11px;
    font-weight: 750;
    letter-spacing: 1.2px;
}

.login-badge-dot {
    width: 7px;
    height: 7px;

    background: #6ee7b7;

    border-radius: 50%;

    box-shadow: 0 0 12px #6ee7b7;
}

.login-showcase h1 {
    margin: 25px 0 18px;

    color: #fff;

    font-size: clamp(34px, 4vw, 48px);
    line-height: 1.15;

    font-weight: 850;
    letter-spacing: -1.5px;
}

.login-showcase h1 span {
    display: block;
    color: #a7f3d0;
}

.login-showcase-content > p {
    max-width: 390px;

    margin: 0;

    color: rgba(255, 255, 255, 0.78);

    font-size: 15px;
    line-height: 1.8;
}


/* FEATURE LIST */

.login-feature-list {
    display: grid;
    gap: 17px;

    margin-top: 35px;
}

.login-feature-item {
    display: flex;
    align-items: center;
    gap: 12px;

    color: rgba(255, 255, 255, 0.92);

    font-size: 14px;
    font-weight: 550;
}

.login-feature-icon {
    display: flex;
    align-items: center;
    justify-content: center;

    flex-shrink: 0;

    width: 26px;
    height: 26px;

    color: #a7f3d0;

    background: rgba(255, 255, 255, 0.12);

    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: 50%;

    font-size: 13px;
    font-weight: 800;
}


/* SHOWCASE FOOTER */

.login-showcase-footer {
    position: relative;
    z-index: 1;

    display: flex;
    justify-content: space-between;
    gap: 15px;

    color: rgba(255, 255, 255, 0.6);

    font-size: 11px;
}


/* =========================================
   RIGHT LOGIN PANEL
========================================= */

.login-form-section {
    display: flex;
    align-items: center;
    justify-content: center;

    padding: 45px;
    background: rgba(255, 255, 255, 0.94);
}

.login-card {
    width: 100%;
    max-width: 390px;

    animation: loginCardAppear 0.9s 0.15s ease both;
}

@keyframes loginCardAppear {
    from {
        opacity: 0;
        transform: translateY(18px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}


/* CARD HEADER */

.login-card-header {
    margin-bottom: 30px;
}

.login-welcome-icon {
    display: flex;
    align-items: center;
    justify-content: center;

    width: 58px;
    height: 58px;

    margin-bottom: 22px;

    color: var(--login-green);

    background: #e7f8ef;

    border: 1px solid #d1fae5;
    border-radius: 18px;

    box-shadow: 0 8px 20px rgba(5, 150, 105, 0.08);
}

.login-welcome-icon svg {
    width: 29px;
    height: 29px;
}

.login-card-header h2 {
    margin: 0 0 8px;

    color: #143b2c;

    font-size: 30px;
    font-weight: 850;
    letter-spacing: -0.8px;
}

.login-card-header p {
    margin: 0;

    color: #84928b;

    font-size: 14px;
}


/* =========================================
   LOGIN ALERT
========================================= */

.login-alert {
    display: flex;
    align-items: center;
    gap: 10px;

    margin-bottom: 20px;
    padding: 12px 14px;

    color: #9f2424;

    background: #fff1f1;

    border: 1px solid #ffdada;
    border-radius: 10px;

    font-size: 13px;

    animation: loginAlertAppear 0.3s ease both;
}

@keyframes loginAlertAppear {
    from {
        opacity: 0;
        transform: translateY(-6px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.login-alert-icon {
    display: flex;
    align-items: center;
    justify-content: center;

    flex-shrink: 0;

    width: 20px;
    height: 20px;

    color: #fff;

    background: #dc2626;

    border-radius: 50%;

    font-size: 12px;
    font-weight: 800;
}


/* =========================================
   FORM
========================================= */

.login-form {
    display: flex;
    flex-direction: column;
    gap: 19px;
}

.login-input-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.login-input-group label {
    margin: 0;

    color: #34483d;

    font-size: 13px;
    font-weight: 750;
}

.login-input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.login-input-icon {
    position: absolute;
    left: 15px;

    display: flex;
    align-items: center;
    justify-content: center;

    width: 20px;
    height: 20px;

    color: #91a39a;

    pointer-events: none;
}

.login-input-icon svg {
    width: 20px;
    height: 20px;
}

.login-input-wrapper input {
    width: 100%;
    height: 52px;

    margin: 0;
    padding: 0 48px;

    color: #18352b;

    background: #f8faf9;

    border: 1px solid #e1e9e4;
    border-radius: 11px;

    outline: none;

    font: inherit;
    font-size: 14px;

    transition:
        border-color 0.25s,
        box-shadow 0.25s,
        background 0.25s,
        transform 0.25s;
}

.login-input-wrapper input::placeholder {
    color: #a5b1aa;
}

.login-input-wrapper input:hover {
    border-color: #b9d8c8;
}

.login-input-wrapper input:focus {
    background: #fff;

    border-color: #059669;

    box-shadow: 0 0 0 4px rgba(5, 150, 105, 0.1);
}


/* PASSWORD TOGGLE */

.login-password-toggle {
    position: absolute;
    right: 12px;

    display: flex;
    align-items: center;
    justify-content: center;

    width: 34px;
    height: 34px;

    padding: 0;

    color: #91a39a;

    background: transparent;

    border-radius: 8px;
}

.login-password-toggle:hover {
    color: var(--login-green);
    background: #e7f8ef;
}

.login-password-toggle svg {
    width: 19px;
    height: 19px;
}


/* =========================================
   LOGIN BUTTON
========================================= */

.login-submit {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;

    width: 100%;
    height: 54px;

    margin-top: 7px;
    padding: 0 20px;

    color: #fff;

    background: linear-gradient(
        135deg,
        #059669,
        #047857
    );

    border: 0;
    border-radius: 11px;

    box-shadow:
        0 8px 18px rgba(5, 150, 105, 0.2),
        inset 0 1px 0 rgba(255, 255, 255, 0.15);

    font: inherit;
    font-size: 14px;
    font-weight: 750;

    cursor: pointer;

    transition:
        transform 0.25s,
        box-shadow 0.25s,
        background 0.25s;
}

.login-submit svg {
    width: 19px;
    height: 19px;

    transition: transform 0.25s;
}

.login-submit:hover {
    color: #fff;

    background: linear-gradient(
        135deg,
        #047857,
        #065f46
    );

    transform: translateY(-2px);

    box-shadow:
        0 12px 24px rgba(5, 150, 105, 0.28),
        inset 0 1px 0 rgba(255, 255, 255, 0.15);
}

.login-submit:hover svg {
    transform: translateX(4px);
}

.login-submit:active {
    transform: translateY(0);
}


/* =========================================
   REGISTER LINK
========================================= */

.login-divider {
    display: flex;
    align-items: center;
    gap: 12px;

    margin: 25px 0;

    color: #9aa69f;

    font-size: 12px;
}

.login-divider::before,
.login-divider::after {
    content: "";

    flex: 1;

    height: 1px;

    background: #e8eeea;
}

.login-register-link {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;

    width: 100%;
    min-height: 50px;

    padding: 12px 16px;

    color: #087f5b;

    background: #effaf4;

    border: 1px solid #d1fae5;
    border-radius: 11px;

    font-size: 13px;
    font-weight: 750;

    transition:
        background 0.25s,
        border-color 0.25s,
        transform 0.25s;
}

.login-register-link svg {
    width: 17px;
    height: 17px;

    transition: transform 0.25s;
}

.login-register-link:hover {
    color: #065f46;

    background: #dff7e9;

    border-color: #a7f3d0;

    transform: translateY(-1px);
}

.login-register-link:hover svg {
    transform: translateX(4px);
}


/* =========================================
   SECURITY FOOTER
========================================= */

.login-security {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;

    margin: 25px 0 0;

    color: #9aa69f;

    font-size: 11px;
}

.login-security-dot {
    width: 7px;
    height: 7px;

    background: #10b981;

    border-radius: 50%;

    box-shadow: 0 0 0 4px #d1fae5;
}


/* =========================================
   RESPONSIVE
========================================= */

@media (max-width: 900px) {
    .login-wrapper {
        grid-template-columns: 1fr;

        max-width: 520px;
        min-height: auto;

        margin: 25px auto;
    }

    .login-showcase {
        min-height: 330px;

        padding: 30px;
    }

    .login-showcase-content {
        margin: 35px 0;
    }

    .login-showcase h1 {
        font-size: 35px;
    }

    .login-feature-list {
        display: none;
    }

    .login-showcase-footer {
        margin-top: 20px;
    }

    .login-form-section {
        padding: 35px;
    }
}

@media (max-width: 520px) {
    .login-wrapper {
        width: calc(100% - 24px);

        margin: 12px auto;

        border-radius: 20px;
    }

    .login-showcase {
        min-height: 280px;

        padding: 24px;
    }

    .login-brand {
        font-size: 16px;
    }

    .login-brand-icon {
        width: 40px;
        height: 40px;
    }

    .login-showcase-content {
        margin: 28px 0;
    }

    .login-showcase h1 {
        font-size: 30px;
    }

    .login-showcase-content > p {
        font-size: 13px;
    }

    .login-showcase-footer {
        font-size: 9px;
    }

    .login-form-section {
        padding: 28px 22px;
    }

    .login-card-header h2 {
        font-size: 26px;
    }
}


/* =========================================
   REDUCE MOTION ACCESSIBILITY
========================================= */

@media (prefers-reduced-motion: reduce) {
    .login-page *,
    .login-page *::before,
    .login-page *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}


/* =====================================================
   INVENTARIS APPLICATION LAYOUT
   Green Theme - Matching Login Page
===================================================== */

body.app-layout {
    --app-green: #087f5b;
    --app-green-dark: #065f46;
    --app-green-deep: #064e3b;
    --app-green-light: #d1fae5;
    --app-green-soft: #effaf4;

    --app-text: #18352b;
    --app-muted: #81928a;
    --app-border: #e4ece7;
    --app-background: #f4f8f5;
    --app-white: #ffffff;

    min-height: 100vh;
    margin: 0;

    display: flex;
    flex-direction: column;

    color: var(--app-text);
    background: var(--app-background);

    font-family: "Inter", "Segoe UI", system-ui, Arial, sans-serif;

    overflow-x: hidden;
}

body.app-layout *,
body.app-layout *::before,
body.app-layout *::after {
    box-sizing: border-box;
}

body.app-layout a {
    text-decoration: none;
}

/* =====================================================
   ANIMATION
===================================================== */

@keyframes appHeaderEnter {
    from {
        opacity: 0;
        transform: translateY(-15px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes appContentEnter {
    from {
        opacity: 0;
        transform: translateY(15px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes appFloat {
    0%, 100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-4px);
    }
}

@keyframes appMenuEnter {
    from {
        opacity: 0;
        transform: translateY(-8px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* =====================================================
   HEADER
===================================================== */

body.app-layout .app-header {
    position: relative;
    z-index: 20;

    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;

    width: 100%;
    min-height: 90px;

    padding: 18px 40px;

    color: #ffffff;

    background:
        radial-gradient(
            circle at 90% 10%,
            rgba(52, 211, 153, 0.3),
            transparent 35%
        ),
        linear-gradient(
            135deg,
            #065f46 0%,
            #047857 48%,
            #059669 100%
        );

    border: none;

    box-shadow:
        0 8px 24px rgba(6, 78, 59, 0.14);

    animation: appHeaderEnter 0.6s ease both;

    overflow: hidden;
}

/* Dekorasi header */

body.app-layout .app-header::before {
    content: "";

    position: absolute;
    top: -130px;
    right: 12%;

    width: 260px;
    height: 260px;

    border: 1px solid rgba(255, 255, 255, 0.13);
    border-radius: 50%;

    box-shadow:
        0 0 0 30px rgba(255, 255, 255, 0.035),
        0 0 0 65px rgba(255, 255, 255, 0.025);

    pointer-events: none;
}

body.app-layout .app-header::after {
    content: "";

    position: absolute;
    right: -90px;
    bottom: -150px;

    width: 300px;
    height: 300px;

    background: rgba(255, 255, 255, 0.055);
    border-radius: 50%;

    pointer-events: none;
}

/* =====================================================
   BRAND
===================================================== */

body.app-layout .app-header-brand {
    position: relative;
    z-index: 1;

    display: flex;
    align-items: center;
    gap: 15px;

    min-width: 0;
}

body.app-layout .app-brand-icon {
    display: flex;
    align-items: center;
    justify-content: center;

    flex: 0 0 50px;
    width: 50px;
    height: 50px;

    color: #ffffff;

    background: rgba(255, 255, 255, 0.16);

    border: 1px solid rgba(255, 255, 255, 0.23);
    border-radius: 15px;

    font-size: 25px;
    font-weight: 900;

    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);

    box-shadow:
        0 5px 18px rgba(0, 0, 0, 0.08);

    animation: appFloat 4s ease-in-out infinite;
}

body.app-layout .app-brand-info {
    display: flex;
    flex-direction: column;
    gap: 5px;

    min-width: 0;
}

body.app-layout .app-brand-info strong {
    color: #ffffff;

    font-size: 20px;
    font-weight: 850;
    letter-spacing: -0.5px;

    overflow-wrap: anywhere;
}

body.app-layout .app-brand-info small {
    color: rgba(255, 255, 255, 0.75);

    font-size: 11px;
    letter-spacing: 0.6px;
}

/* =====================================================
   USER PROFILE
===================================================== */

body.app-layout .app-header-user {
    position: relative;
    z-index: 1;

    display: flex;
    align-items: center;
    gap: 12px;

    flex-shrink: 0;

    padding: 9px 17px 9px 9px;

    background: rgba(255, 255, 255, 0.12);

    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 15px;

    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);

    transition:
        background 0.25s ease,
        transform 0.25s ease;
}

body.app-layout .app-header-user:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
}

body.app-layout .app-user-avatar {
    display: flex;
    align-items: center;
    justify-content: center;

    flex: 0 0 40px;
    width: 40px;
    height: 40px;

    color: #065f46;

    background: #d1fae5;

    border: 2px solid rgba(255, 255, 255, 0.35);
    border-radius: 12px;

    font-size: 16px;
    font-weight: 850;
}

body.app-layout .app-user-info {
    display: flex;
    flex-direction: column;
    gap: 4px;

    min-width: 0;
    max-width: 230px;
}

body.app-layout .app-user-info strong {
    color: #ffffff;

    font-size: 12px;
    font-weight: 800;

    overflow-wrap: anywhere;
}

body.app-layout .app-user-info small {
    color: #d1fae5;

    font-size: 10px;
}

/* =====================================================
   NAVBAR
===================================================== */

body.app-layout .app-navbar {
    position: relative;
    z-index: 15;

    width: 100%;

    background: #ffffff;

    border-bottom: 1px solid #dcebe1;

    box-shadow:
        0 5px 18px rgba(6, 78, 59, 0.045);
}

body.app-layout .app-navbar-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;

    width: 100%;
    max-width: 1800px;
    min-height: 70px;

    margin: 0 auto;
    padding: 12px 40px;
}

/* Menu utama */

body.app-layout .app-nav-menu {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;

    min-width: 0;
}

/* Menu link */

body.app-layout .app-nav-link {
    position: relative;

    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 9px;

    min-height: 44px;
    padding: 11px 17px;

    color: #587064;

    background: transparent;

    border: 1px solid transparent;
    border-radius: 11px;

    font-size: 12px;
    font-weight: 750;

    white-space: nowrap;

    transition:
        color 0.25s ease,
        background 0.25s ease,
        border-color 0.25s ease,
        transform 0.25s ease;
}

/* Garis animasi menu */

body.app-layout .app-nav-link::after {
    content: "";

    position: absolute;
    right: 13px;
    bottom: 3px;
    left: 13px;

    height: 2px;

    background: #059669;
    border-radius: 5px;

    transform: scaleX(0);
    transform-origin: center;

    transition: transform 0.25s ease;
}

/* Hover menu */

body.app-layout .app-nav-link:hover {
    color: #047857;

    background: #effaf4;

    border-color: #d5f1e1;

    transform: translateY(-2px);
}

body.app-layout .app-nav-link:hover::after {
    transform: scaleX(1);
}

/* Icon menu */

body.app-layout .app-nav-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    width: 20px;
    height: 20px;

    font-size: 19px;
    line-height: 1;
}

/* =====================================================
   LOGOUT
===================================================== */

body.app-layout .app-nav-actions {
    display: flex;
    align-items: center;

    flex-shrink: 0;
}

body.app-layout .app-logout-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;

    min-height: 42px;
    padding: 10px 16px;

    color: #b42332;

    background: #fff5f5;

    border: 1px solid #ffe0e0;
    border-radius: 11px;

    font-size: 12px;
    font-weight: 750;

    transition:
        color 0.25s ease,
        background 0.25s ease,
        transform 0.25s ease;
}

body.app-layout .app-logout-link:hover {
    color: #ffffff;

    background: #dc3545;

    border-color: #dc3545;

    transform: translateY(-2px);
}

/* =====================================================
   MOBILE TOGGLE
===================================================== */

/* Checkbox tidak terlihat */

body.app-layout .app-menu-toggle-checkbox {
    position: absolute;

    width: 1px;
    height: 1px;

    padding: 0;
    margin: -1px;

    overflow: hidden;
    clip: rect(0, 0, 0, 0);

    white-space: nowrap;

    border: 0;
}

/* Tombol menu disembunyikan pada desktop */

body.app-layout .app-menu-toggle {
    display: none;
}

/* =====================================================
   MAIN CONTENT
===================================================== */

body.app-layout .app-main {
    position: relative;

    flex: 1 0 auto;

    width: 100%;
    min-width: 0;
    min-height: 0;

    margin: 0;

    padding: 32px 40px 45px;

    background:
        radial-gradient(
            circle at 0% 0%,
            rgba(16, 185, 129, 0.055),
            transparent 36%
        ),
        #f4f8f5;
}

body.app-layout .app-main-content {
    width: 100%;
    max-width: 1600px;
    min-width: 0;

    margin: 0 auto;

    animation: appContentEnter 0.6s 0.08s ease both;
}

/* Mencegah konten melebar */

body.app-layout .app-main-content > * {
    min-width: 0;
    max-width: 100%;
}

/* =====================================================
   TABLET
===================================================== */

@media (max-width: 1024px) {

    body.app-layout .app-header {
        padding-right: 25px;
        padding-left: 25px;
    }

    body.app-layout .app-navbar-inner {
        padding-right: 25px;
        padding-left: 25px;
    }

    body.app-layout .app-main {
        padding: 26px 25px 35px;
    }

    body.app-layout .app-nav-link {
        padding-right: 12px;
        padding-left: 12px;
    }
}

/* =====================================================
   MOBILE RESPONSIVE
===================================================== */

@media (max-width: 768px) {

    /* Header */

    body.app-layout .app-header {
        align-items: flex-start;
        flex-direction: column;
        gap: 16px;

        min-height: auto;

        padding: 20px;
    }

    body.app-layout .app-header-brand {
        width: 100%;
    }

    body.app-layout .app-brand-info strong {
        font-size: 17px;
    }

    body.app-layout .app-header-user {
        align-self: stretch;
    }

    /* Navbar */

    body.app-layout .app-navbar-inner {
        display: flex;
        align-items: stretch;
        flex-direction: column;
        gap: 0;

        padding: 12px 16px;
    }

    /* Toggle button */

    body.app-layout .app-menu-toggle {
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 10px;

        width: 100%;
        min-height: 47px;

        padding: 12px 16px;

        color: #ffffff;

        background: linear-gradient(
            135deg,
            #087f5b,
            #047857
        );

        border: 1px solid #047857;
        border-radius: 11px;

        font-size: 13px;
        font-weight: 800;

        cursor: pointer;

        transition:
            background 0.25s ease,
            transform 0.25s ease;
    }

    body.app-layout .app-menu-toggle:hover {
        background: linear-gradient(
            135deg,
            #047857,
            #065f46
        );
    }

    /* Icon hamburger */

    body.app-layout .app-toggle-icon {
        position: relative;

        display: block;

        width: 19px;
        height: 14px;

        border-top: 2px solid #ffffff;
        border-bottom: 2px solid #ffffff;
    }

    body.app-layout .app-toggle-icon::before {
        content: "";

        position: absolute;

        top: 5px;
        left: 0;

        width: 100%;
        height: 2px;

        background: #ffffff;

        transition:
            transform 0.25s ease,
            top 0.25s ease;
    }

    /* Menu tertutup secara default */

    body.app-layout .app-nav-menu {
        display: none;

        width: 100%;

        flex-direction: column;
        align-items: stretch;
        flex-wrap: nowrap;
        gap: 6px;

        padding: 12px 0 0;
    }

    /* Menu terbuka saat toggle dicentang */

    body.app-layout .app-menu-toggle-checkbox:checked ~ .app-nav-menu {
        display: flex;

        animation: appMenuEnter 0.25s ease both;
    }

    /* Animasi icon menjadi X */

    body.app-layout .app-menu-toggle-checkbox:checked
    + .app-menu-toggle .app-toggle-icon {
        border-top-color: transparent;
        border-bottom-color: transparent;
    }

    body.app-layout .app-menu-toggle-checkbox:checked
    + .app-menu-toggle .app-toggle-icon::before {
        top: 5px;

        transform: rotate(45deg);
    }

    body.app-layout .app-menu-toggle-checkbox:checked
    + .app-menu-toggle .app-toggle-icon::after {
        content: "";

        position: absolute;

        top: 5px;
        left: 0;

        width: 100%;
        height: 2px;

        background: #ffffff;

        transform: rotate(-45deg);
    }

    /* Link menu mobile */

    body.app-layout .app-nav-link {
        display: flex;
        justify-content: flex-start;

        width: 100%;
        min-height: 45px;

        padding: 12px 16px;

        color: #466456;

        background: #f5faf6;

        border: 1px solid #e6f0e8;
        border-radius: 10px;

        font-size: 12px;
    }

    body.app-layout .app-nav-link:hover {
        color: #047857;

        background: #e7f8ef;

        border-color: #c6ead5;

        transform: translateX(3px);
    }

    body.app-layout .app-nav-link::after {
        display: none;
    }

    /* Logout */

    body.app-layout .app-nav-actions {
        display: none;

        width: 100%;

        padding-top: 10px;
    }

    body.app-layout .app-menu-toggle-checkbox:checked
    ~ .app-nav-actions {
        display: flex;

        animation: appMenuEnter 0.3s ease both;
    }

    body.app-layout .app-logout-link {
        width: 100%;
        justify-content: center;

        min-height: 45px;
    }

    /* Main content */

    body.app-layout .app-main {
        padding: 22px 16px 30px;
    }
}

/* =====================================================
   SMALL MOBILE
===================================================== */

@media (max-width: 400px) {

    body.app-layout .app-header {
        padding: 17px 14px;
    }

    body.app-layout .app-brand-icon {
        flex-basis: 43px;
        width: 43px;
        height: 43px;
    }

    body.app-layout .app-brand-info strong {
        font-size: 15px;
    }

    body.app-layout .app-brand-info small {
        font-size: 10px;
    }

    body.app-layout .app-header-user {
        padding: 8px;
    }

    body.app-layout .app-main {
        padding: 18px 12px 25px;
    }
}

/* =====================================================
   ACCESSIBILITY
===================================================== */

@media (prefers-reduced-motion: reduce) {

    body.app-layout *,
    body.app-layout *::before,
    body.app-layout *::after {
        animation: none !important;
        transition: none !important;
        scroll-behavior: auto !important;
    }
}






















/* =========================================================
   DASHBOARD INVENTARIS
   Tambahkan ke bagian paling bawah file style.css
========================================================= */


/* =========================================================
   1. DASHBOARD PAGE
========================================================= */

.dashboard-page {
    display: flex;
    flex-direction: column;
    gap: 24px;

    width: 100%;
    max-width: 1600px;
    min-width: 0;

    margin: 0 auto;
    padding: 26px;

    color: #1e293b;
    font-family: "Inter", "Segoe UI", Arial, sans-serif;

    animation: dashboardFadeIn 0.5s ease;
}


/* =========================================================
   2. DASHBOARD HEADER
========================================================= */

.dashboard-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 24px;

    position: relative;
    overflow: hidden;

    width: 100%;
    min-height: 190px;

    padding: 32px 36px;

    background: linear-gradient(
        120deg,
        #065f46 0%,
        #047857 55%,
        #059669 100%
    );

    border-radius: 22px;

    color: #ffffff;

    box-shadow:
        0 12px 30px rgba(6, 95, 70, 0.18);

    animation: dashboardSlideDown 0.5s ease;
}


/* Ornamen header */

.dashboard-header::before {
    content: "";

    position: absolute;

    width: 280px;
    height: 280px;

    top: -130px;
    right: 130px;

    border-radius: 50%;

    background: rgba(255, 255, 255, 0.055);

    pointer-events: none;
}

.dashboard-header::after {
    content: "";

    position: absolute;

    width: 190px;
    height: 190px;

    bottom: -110px;
    right: -35px;

    border-radius: 50%;

    background: rgba(255, 255, 255, 0.08);

    pointer-events: none;
}


.dashboard-header-info {
    position: relative;
    z-index: 1;

    max-width: 760px;
}


.dashboard-greeting {
    display: inline-flex;
    align-items: center;
    gap: 8px;

    margin-bottom: 12px;

    color: #bbf7d0;

    font-size: 11px;
    font-weight: 800;

    letter-spacing: 1.8px;
    text-transform: uppercase;
}


.dashboard-header h1 {
    margin: 0 0 12px;

    color: #ffffff;

    font-size: clamp(28px, 3vw, 38px);
    font-weight: 800;

    line-height: 1.2;
    letter-spacing: -0.8px;
}


.dashboard-header p {
    margin: 0;

    color: rgba(255, 255, 255, 0.85);

    font-size: 14px;
    line-height: 1.8;
}


.dashboard-header p strong {
    color: #ffffff;
    font-weight: 700;
}


/* Tanggal dashboard */

.dashboard-date {
    display: inline-flex;
    align-items: center;
    gap: 12px;

    position: relative;
    z-index: 1;

    flex-shrink: 0;

    padding: 13px 18px;

    border: 1px solid rgba(255, 255, 255, 0.22);
    border-radius: 14px;

    background: rgba(255, 255, 255, 0.12);

    backdrop-filter: blur(8px);

    color: #ffffff;

    font-size: 13px;
    font-weight: 700;

    white-space: nowrap;
}


.dashboard-date-icon {
    display: flex;
    align-items: center;
    justify-content: center;

    width: 36px;
    height: 36px;

    border-radius: 10px;

    background: rgba(255, 255, 255, 0.17);

    font-size: 16px;
}


/* =========================================================
   3. STATISTICS
========================================================= */

.dashboard-stats {
    display: grid;

    grid-template-columns: repeat(4, minmax(0, 1fr));

    gap: 20px;

    width: 100%;
}


.dashboard-stat-card {
    display: flex;
    flex-direction: column;

    min-width: 0;
    min-height: 170px;

    padding: 24px;

    background: #ffffff;

    border: 1px solid #e2e8f0;
    border-radius: 18px;

    box-shadow:
        0 8px 24px rgba(15, 23, 42, 0.045);

    transition: all 0.25s ease;

    animation: dashboardFadeUp 0.6s ease both;
}


.dashboard-stat-card:nth-child(1) {
    animation-delay: 0.05s;
}

.dashboard-stat-card:nth-child(2) {
    animation-delay: 0.10s;
}

.dashboard-stat-card:nth-child(3) {
    animation-delay: 0.15s;
}

.dashboard-stat-card:nth-child(4) {
    animation-delay: 0.20s;
}


.dashboard-stat-card:hover {
    transform: translateY(-5px);

    border-color: #a7f3d0;

    box-shadow:
        0 14px 32px rgba(15, 23, 42, 0.08);
}


.dashboard-stat-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
}


.dashboard-stat-label {
    color: #64748b;

    font-size: 13px;
    font-weight: 600;
}


/* Icon statistik */

.dashboard-stat-icon {
    display: flex;
    align-items: center;
    justify-content: center;

    width: 48px;
    height: 48px;

    flex-shrink: 0;

    border-radius: 14px;

    font-size: 20px;

    transition: transform 0.25s ease;
}


.dashboard-stat-card:hover .dashboard-stat-icon {
    transform: scale(1.08) rotate(-4deg);
}


.dashboard-icon-green {
    color: #087f5b;
    background: #d1fae5;
}

.dashboard-icon-blue {
    color: #2563eb;
    background: #dbeafe;
}

.dashboard-icon-purple {
    color: #7c3aed;
    background: #ede9fe;
}

.dashboard-icon-orange {
    color: #ea580c;
    background: #ffedd5;
}


/* Angka statistik */

.dashboard-stat-value {
    margin-top: 16px;

    color: #0f172a;

    font-size: clamp(27px, 2.2vw, 34px);
    font-weight: 800;

    line-height: 1.2;
    letter-spacing: -0.8px;

    overflow-wrap: anywhere;
}


.dashboard-stat-footer {
    margin-top: 8px;

    color: #94a3b8;

    font-size: 12px;
    line-height: 1.6;
}


/* =========================================================
   4. SECTION HEADER
========================================================= */

.dashboard-section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 24px;

    margin-bottom: 24px;
}


.dashboard-section-heading {
    min-width: 0;
}


.dashboard-section-label {
    display: block;

    margin-bottom: 8px;

    color: #087f5b;

    font-size: 10px;
    font-weight: 800;

    letter-spacing: 1.6px;
    text-transform: uppercase;
}


.dashboard-section-heading h2 {
    margin: 0;

    color: #0f172a;

    font-size: 21px;
    font-weight: 800;

    line-height: 1.4;
}


.dashboard-section-heading p {
    margin: 7px 0 0;

    color: #64748b;

    font-size: 13px;
    line-height: 1.6;
}


/* =========================================================
   5. CHART CARD
========================================================= */

.dashboard-chart-card {
    width: 100%;
    min-width: 0;

    padding: 28px;

    background: #ffffff;

    border: 1px solid #e2e8f0;
    border-radius: 18px;

    box-shadow:
        0 8px 24px rgba(15, 23, 42, 0.045);

    animation: dashboardFadeUp 0.6s ease both;
    animation-delay: 0.15s;
}


.dashboard-chart-container {
    position: relative;

    width: 100%;
    height: 340px;

    min-width: 0;

    margin-top: 10px;
}


.dashboard-chart-container canvas {
    display: block;

    width: 100% !important;
    height: 100% !important;
}


/* =========================================================
   6. STOCK CARD
========================================================= */

.dashboard-stock-card {
    width: 100%;
    min-width: 0;

    padding: 28px;

    background: #ffffff;

    border: 1px solid #e2e8f0;
    border-radius: 18px;

    box-shadow:
        0 8px 24px rgba(15, 23, 42, 0.045);

    animation: dashboardFadeUp 0.6s ease both;
    animation-delay: 0.2s;
}


/* =========================================================
   7. TRANSACTION CARD
========================================================= */

.dashboard-transaction-card {
    width: 100%;
    min-width: 0;

    padding: 28px;

    background: #ffffff;

    border: 1px solid #e2e8f0;
    border-radius: 18px;

    box-shadow:
        0 8px 24px rgba(15, 23, 42, 0.045);

    animation: dashboardFadeUp 0.6s ease both;
    animation-delay: 0.25s;
}


/* =========================================================
   8. VIEW ALL BUTTON
========================================================= */

.dashboard-view-all {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 9px;

    flex-shrink: 0;

    padding: 11px 16px;

    color: #087f5b;

    background: #ecfdf5;

    border: 1px solid #bbf7d0;
    border-radius: 10px;

    font-size: 12px;
    font-weight: 700;

    text-decoration: none;

    transition: all 0.25s ease;
}


.dashboard-view-all i {
    font-size: 11px;

    transition: transform 0.25s ease;
}


.dashboard-view-all:hover {
    color: #ffffff;

    background: #087f5b;

    border-color: #087f5b;

    transform: translateY(-2px);

    box-shadow:
        0 6px 16px rgba(8, 127, 91, 0.18);
}


.dashboard-view-all:hover i {
    transform: translateX(4px);
}


/* =========================================================
   9. TABLE WRAPPER
========================================================= */

.dashboard-table-wrapper {
    width: 100%;
    min-width: 0;

    overflow-x: auto;

    border: 1px solid #e2e8f0;
    border-radius: 12px;

    background: #ffffff;

    scrollbar-width: thin;
    scrollbar-color: #cbd5e1 #f8fafc;
}


/* =========================================================
   10. DASHBOARD TABLE
========================================================= */

.dashboard-table {
    width: 100%;

    border-collapse: separate;
    border-spacing: 0;

    font-size: 13px;

    text-align: left;
}


.dashboard-table thead {
    background: #f8fafc;
}


.dashboard-table thead th {
    padding: 16px 20px;

    color: #64748b;

    font-size: 11px;
    font-weight: 800;

    letter-spacing: 0.5px;
    text-transform: uppercase;

    white-space: nowrap;

    border-bottom: 1px solid #e2e8f0;
}


.dashboard-table tbody td {
    padding: 17px 20px;

    color: #475569;

    border-bottom: 1px solid #f1f5f9;

    vertical-align: middle;
}


.dashboard-table tbody tr:last-child td {
    border-bottom: none;
}


.dashboard-table tbody tr {
    transition: background 0.2s ease;
}


.dashboard-table tbody tr:hover {
    background: #f8fffb;
}


.dashboard-table tbody td strong {
    color: #1e293b;

    font-weight: 700;
}


/* =========================================================
   11. STOCK STATUS BADGES
========================================================= */

.dashboard-stock-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    padding: 7px 12px;

    border-radius: 20px;

    font-size: 11px;
    font-weight: 800;

    white-space: nowrap;
}


.dashboard-stock-safe {
    color: #047857;

    background: #d1fae5;

    border: 1px solid #a7f3d0;
}


.dashboard-stock-low {
    color: #b45309;

    background: #fef3c7;

    border: 1px solid #fde68a;
}


.dashboard-stock-empty {
    color: #b91c1c;

    background: #fee2e2;

    border: 1px solid #fecaca;
}


/* =========================================================
   12. TRANSACTION BADGES
========================================================= */

.dashboard-transaction-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;

    padding: 7px 12px;

    border-radius: 20px;

    font-size: 11px;
    font-weight: 800;

    white-space: nowrap;
}


.dashboard-transaction-in {
    color: #047857;

    background: #d1fae5;

    border: 1px solid #a7f3d0;
}


.dashboard-transaction-out {
    color: #c2410c;

    background: #ffedd5;

    border: 1px solid #fed7aa;
}


.dashboard-transaction-badge i {
    font-size: 10px;
}


/* =========================================================
   13. EMPTY DATA
========================================================= */

.dashboard-empty {
    padding: 45px 20px !important;

    text-align: center;

    color: #94a3b8 !important;
}


.dashboard-empty i {
    display: block;

    margin-bottom: 12px;

    color: #cbd5e1;

    font-size: 30px;
}


.dashboard-empty span {
    display: block;

    font-size: 13px;
}


/* =========================================================
   14. ANIMATIONS
========================================================= */

@keyframes dashboardFadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}


@keyframes dashboardFadeUp {
    from {
        opacity: 0;
        transform: translateY(18px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}


@keyframes dashboardSlideDown {
    from {
        opacity: 0;
        transform: translateY(-15px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}


/* =========================================================
   15. RESPONSIVE TABLET
========================================================= */

@media (max-width: 1100px) {

    .dashboard-page {
        padding: 22px;
        gap: 22px;
    }

    .dashboard-stats {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 16px;
    }

    .dashboard-header {
        padding: 28px;
    }

    .dashboard-stat-card {
        min-height: 155px;
    }

}


/* =========================================================
   16. RESPONSIVE MOBILE
========================================================= */

@media (max-width: 768px) {

    .dashboard-page {
        padding: 16px;
        gap: 18px;
    }


    /* Header */

    .dashboard-header {
        flex-direction: column;
        align-items: flex-start;

        gap: 20px;

        min-height: auto;

        padding: 25px 22px;

        border-radius: 16px;
    }


    .dashboard-header h1 {
        font-size: 29px;
    }


    .dashboard-header p {
        font-size: 13px;
    }


    .dashboard-date {
        padding: 10px 13px;

        font-size: 12px;
    }


    /* Statistics */

    .dashboard-stats {
        grid-template-columns: repeat(2, minmax(0, 1fr));

        gap: 12px;
    }


    .dashboard-stat-card {
        min-height: 145px;

        padding: 17px;

        border-radius: 14px;
    }


    .dashboard-stat-label {
        font-size: 12px;
    }


    .dashboard-stat-icon {
        width: 38px;
        height: 38px;

        border-radius: 11px;

        font-size: 16px;
    }


    .dashboard-stat-value {
        margin-top: 13px;

        font-size: 27px;
    }


    .dashboard-stat-footer {
        font-size: 11px;
    }


    /* Section */

    .dashboard-section-header {
        flex-direction: column;
        align-items: flex-start;

        gap: 16px;

        margin-bottom: 18px;
    }


    .dashboard-section-heading h2 {
        font-size: 18px;
    }


    .dashboard-section-heading p {
        font-size: 12px;
    }


    /* Cards */

    .dashboard-chart-card,
    .dashboard-stock-card,
    .dashboard-transaction-card {
        padding: 20px;

        border-radius: 15px;
    }


    /* Chart */

    .dashboard-chart-container {
        height: 270px;
    }


    /* Button */

    .dashboard-view-all {
        width: 100%;

        padding: 11px 14px;

        font-size: 12px;
    }


    /* Table */

    .dashboard-table {
        min-width: 600px;
    }


    .dashboard-table thead th {
        padding: 13px 15px;

        font-size: 10px;
    }


    .dashboard-table tbody td {
        padding: 14px 15px;

        font-size: 12px;
    }

}


/* =========================================================
   17. SMALL MOBILE
========================================================= */

@media (max-width: 480px) {

    .dashboard-page {
        padding: 12px;

        gap: 15px;
    }


    .dashboard-header {
        padding: 22px 18px;
    }


    .dashboard-greeting {
        font-size: 9px;

        letter-spacing: 1.2px;
    }


    .dashboard-header h1 {
        font-size: 26px;
    }


    .dashboard-header p {
        font-size: 12px;
    }


    .dashboard-stats {
        gap: 10px;
    }


    .dashboard-stat-card {
        padding: 14px;

        min-height: 135px;
    }


    .dashboard-stat-label {
        font-size: 11px;
    }


    .dashboard-stat-icon {
        width: 34px;
        height: 34px;

        font-size: 14px;
    }


    .dashboard-stat-value {
        font-size: 23px;
    }


    .dashboard-stat-footer {
        font-size: 10px;
    }


    .dashboard-section-heading h2 {
        font-size: 17px;
    }


    .dashboard-chart-card,
    .dashboard-stock-card,
    .dashboard-transaction-card {
        padding: 16px;
    }


    .dashboard-chart-container {
        height: 230px;
    }


    .dashboard-stock-badge,
    .dashboard-transaction-badge {
        padding: 6px 9px;

        font-size: 10px;
    }

}


/* =========================================================
   18. REDUCE MOTION
========================================================= */

@media (prefers-reduced-motion: reduce) {

    .dashboard-page,
    .dashboard-header,
    .dashboard-stat-card,
    .dashboard-chart-card,
    .dashboard-stock-card,
    .dashboard-transaction-card {
        animation: none !important;
    }

    .dashboard-stat-card,
    .dashboard-view-all,
    .dashboard-stat-icon {
        transition: none !important;
    }

}























/* =====================================================
   MASTER BARANG
===================================================== */

.barang-page {
    display: flex;
    flex-direction: column;
    gap: 24px;

    width: 100%;
    max-width: 1600px;
    min-width: 0;

    margin: 0 auto;
    padding: 26px;

    color: #1e293b;

    font-family: "Inter", "Segoe UI", Arial, sans-serif;
}


/* =====================================================
   HEADER HALAMAN
===================================================== */

.barang-page-header {
    display: flex;
    align-items: center;
    justify-content: space-between;

    gap: 20px;

    padding: 28px 32px;

    background: linear-gradient(
        120deg,
        #065f46,
        #047857,
        #059669
    );

    color: #ffffff;

    border-radius: 18px;

    box-shadow:
        0 10px 28px rgba(6, 95, 70, 0.15);

    animation: barangFadeUp 0.45s ease;
}


.barang-page-heading {
    min-width: 0;
}


.barang-page-label {
    display: block;

    margin-bottom: 9px;

    color: #bbf7d0;

    font-size: 10px;
    font-weight: 800;

    letter-spacing: 1.6px;
}


.barang-page-heading h1 {
    margin: 0;

    color: #ffffff;

    font-size: 28px;
    font-weight: 800;
}


.barang-page-heading p {
    margin: 9px 0 0;

    color: rgba(255, 255, 255, 0.85);

    font-size: 13px;
    line-height: 1.7;
}


/* =====================================================
   BUTTON
===================================================== */

.barang-btn-primary {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    gap: 9px;

    padding: 12px 20px;

    border: none;
    border-radius: 10px;

    background: #087f5b;

    color: #ffffff;

    font-size: 13px;
    font-weight: 700;

    text-decoration: none;

    cursor: pointer;

    white-space: nowrap;

    transition: all 0.25s ease;
}


.barang-page-header .barang-btn-primary {
    background: #ffffff;

    color: #065f46;
}


.barang-btn-primary:hover {
    background: #065f46;

    color: #ffffff;

    transform: translateY(-2px);

    box-shadow:
        0 7px 18px rgba(6, 95, 70, 0.18);
}


.barang-page-header .barang-btn-primary:hover {
    background: #d1fae5;

    color: #064e3b;
}


/* =====================================================
   ALERT
===================================================== */

.barang-alert {
    display: flex;
    align-items: center;

    gap: 12px;

    padding: 15px 18px;

    color: #b91c1c;

    background: #fef2f2;

    border: 1px solid #fecaca;
    border-radius: 12px;

    font-size: 13px;
}


/* =====================================================
   TABLE CARD
===================================================== */

.barang-table-card {
    width: 100%;
    min-width: 0;

    padding: 26px;

    background: #ffffff;

    border: 1px solid #e2e8f0;
    border-radius: 18px;

    box-shadow:
        0 8px 24px rgba(15, 23, 42, 0.045);

    animation: barangFadeUp 0.5s ease;
}


.barang-table-header {
    display: flex;
    justify-content: space-between;
    align-items: center;

    gap: 20px;

    margin-bottom: 22px;
}


.barang-table-header h2 {
    margin: 0;

    color: #0f172a;

    font-size: 20px;
    font-weight: 800;
}


.barang-table-header p {
    margin: 7px 0 0;

    color: #64748b;

    font-size: 13px;
}


.barang-total {
    display: inline-flex;
    align-items: center;

    gap: 9px;

    padding: 10px 14px;

    color: #087f5b;

    background: #ecfdf5;

    border: 1px solid #bbf7d0;
    border-radius: 10px;

    font-size: 12px;
    font-weight: 800;

    white-space: nowrap;
}


/* =====================================================
   TABLE
===================================================== */

.barang-table-wrapper {
    width: 100%;

    overflow-x: auto;

    border: 1px solid #e2e8f0;
    border-radius: 12px;
}


.barang-table {
    width: 100%;

    border-collapse: separate;
    border-spacing: 0;

    text-align: left;

    font-size: 13px;
}


.barang-table thead {
    background: #f8fafc;
}


.barang-table thead th {
    padding: 16px 20px;

    color: #64748b;

    font-size: 11px;
    font-weight: 800;

    text-transform: uppercase;
    letter-spacing: 0.5px;

    white-space: nowrap;

    border-bottom: 1px solid #e2e8f0;
}


.barang-table tbody td {
    padding: 17px 20px;

    color: #475569;

    border-bottom: 1px solid #f1f5f9;

    vertical-align: middle;
}


.barang-table tbody tr:last-child td {
    border-bottom: none;
}


.barang-table tbody tr {
    transition: background 0.2s ease;
}


.barang-table tbody tr:hover {
    background: #f8fffb;
}


.barang-table tbody td strong {
    color: #1e293b;

    font-weight: 700;
}


.barang-kode {
    display: inline-flex;

    padding: 6px 10px;

    color: #087f5b;

    background: #ecfdf5;

    border-radius: 7px;

    font-size: 11px;
    font-weight: 800;
}


.barang-stok {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    min-width: 35px;

    padding: 6px 10px;

    color: #065f46;

    background: #d1fae5;

    border-radius: 8px;

    font-size: 12px;
    font-weight: 800;
}


/* Empty data */

.barang-empty {
    padding: 45px 20px !important;

    text-align: center;

    color: #94a3b8 !important;
}


.barang-empty i {
    display: block;

    margin-bottom: 12px;

    color: #cbd5e1;

    font-size: 30px;
}


.barang-empty span {
    display: block;

    font-size: 13px;
}


/* =====================================================
   POPUP / MODAL
===================================================== */

.barang-modal-overlay {
    display: flex;
    align-items: center;
    justify-content: center;

    position: fixed;
    z-index: 9999;

    inset: 0;

    padding: 20px;

    background: rgba(15, 23, 42, 0.58);

    backdrop-filter: blur(5px);

    opacity: 0;
    visibility: hidden;

    transition:
        opacity 0.25s ease,
        visibility 0.25s ease;
}


.barang-modal-overlay.barang-modal-show {
    opacity: 1;
    visibility: visible;
}


body.barang-modal-open {
    overflow: hidden;
}


/* Popup box */

.barang-modal {
    width: 100%;
    max-width: 620px;

    max-height: calc(100vh - 40px);

    overflow-y: auto;

    background: #ffffff;

    border-radius: 20px;

    box-shadow:
        0 25px 80px rgba(0, 0, 0, 0.25);

    transform: translateY(20px) scale(0.97);

    transition: transform 0.25s ease;
}


.barang-modal-show .barang-modal {
    transform: translateY(0) scale(1);
}


/* Modal header */

.barang-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;

    gap: 20px;

    padding: 24px 28px;

    background: linear-gradient(
        120deg,
        #065f46,
        #047857
    );

    color: #ffffff;

    border-radius: 20px 20px 0 0;
}


.barang-modal-title {
    display: flex;
    align-items: center;

    gap: 14px;
}


.barang-modal-icon {
    display: flex;
    align-items: center;
    justify-content: center;

    width: 48px;
    height: 48px;

    flex-shrink: 0;

    background: rgba(255, 255, 255, 0.16);

    border: 1px solid rgba(255, 255, 255, 0.18);

    border-radius: 13px;

    font-size: 20px;
}


.barang-modal-title h2 {
    margin: 0;

    color: #ffffff;

    font-size: 20px;
    font-weight: 800;
}


.barang-modal-title p {
    margin: 6px 0 0;

    color: rgba(255, 255, 255, 0.8);

    font-size: 12px;
}


/* Close button */

.barang-modal-close {
    display: flex;
    align-items: center;
    justify-content: center;

    width: 38px;
    height: 38px;

    flex-shrink: 0;

    border: 1px solid rgba(255, 255, 255, 0.2);

    border-radius: 10px;

    background: rgba(255, 255, 255, 0.12);

    color: #ffffff;

    font-size: 17px;

    cursor: pointer;

    transition: all 0.2s ease;
}


.barang-modal-close:hover {
    background: rgba(255, 255, 255, 0.25);

    transform: rotate(90deg);
}


/* =====================================================
   FORM
===================================================== */

.barang-modal-form {
    padding: 28px;
}


.barang-form-grid {
    display: grid;

    grid-template-columns: repeat(2, minmax(0, 1fr));

    gap: 20px;
}


.barang-form-group {
    display: flex;
    flex-direction: column;

    gap: 9px;

    min-width: 0;
}


.barang-form-group label {
    color: #334155;

    font-size: 12px;
    font-weight: 800;
}


.barang-form-group label span {
    color: #dc2626;
}


/* Form inputs */

.barang-form-group input {
    width: 100%;
    min-width: 0;

    padding: 13px 14px;

    border: 1px solid #dbe3ed;
    border-radius: 10px;

    outline: none;

    background: #f8fafc;

    color: #1e293b;

    font-family: inherit;

    font-size: 13px;

    transition:
        border-color 0.2s ease,
        box-shadow 0.2s ease,
        background 0.2s ease;
}


.barang-form-group input::placeholder {
    color: #94a3b8;
}


.barang-form-group input:focus {
    background: #ffffff;

    border-color: #087f5b;

    box-shadow:
        0 0 0 3px rgba(8, 127, 91, 0.10);
}


/* =====================================================
   MODAL FOOTER
===================================================== */

.barang-modal-footer {
    display: flex;
    justify-content: flex-end;
    align-items: center;

    gap: 12px;

    margin-top: 28px;
    padding-top: 20px;

    border-top: 1px solid #e2e8f0;
}


.barang-btn-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    padding: 12px 20px;

    color: #475569;

    background: #ffffff;

    border: 1px solid #cbd5e1;
    border-radius: 10px;

    font-size: 13px;
    font-weight: 700;

    cursor: pointer;

    transition: all 0.2s ease;
}


.barang-btn-secondary:hover {
    color: #0f172a;

    background: #f1f5f9;
}


/* =====================================================
   ANIMATION
===================================================== */

@keyframes barangFadeUp {
    from {
        opacity: 0;
        transform: translateY(15px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}


/* =====================================================
   RESPONSIVE TABLET
===================================================== */

@media (max-width: 900px) {

    .barang-page {
        padding: 20px;
    }

    .barang-page-header {
        padding: 24px;
    }

    .barang-table-card {
        padding: 20px;
    }

}


/* =====================================================
   RESPONSIVE MOBILE
===================================================== */

@media (max-width: 600px) {

    .barang-page {
        padding: 14px;
        gap: 18px;
    }


    .barang-page-header {
        flex-direction: column;
        align-items: flex-start;

        gap: 20px;

        padding: 22px;

        border-radius: 15px;
    }


    .barang-page-heading h1 {
        font-size: 24px;
    }


    .barang-page-heading p {
        font-size: 12px;
    }


    .barang-page-header .barang-btn-primary {
        width: 100%;
    }


    .barang-table-card {
        padding: 16px;

        border-radius: 15px;
    }


    .barang-table-header {
        flex-direction: column;
        align-items: flex-start;

        gap: 14px;
    }


    .barang-table-header h2 {
        font-size: 18px;
    }


    .barang-table {
        min-width: 650px;
    }


    /* Modal mobile */

    .barang-modal-overlay {
        padding: 12px;
    }


    .barang-modal {
        max-height: calc(100vh - 24px);

        border-radius: 16px;
    }


    .barang-modal-header {
        padding: 20px;

        border-radius: 16px 16px 0 0;
    }


    .barang-modal-title h2 {
        font-size: 18px;
    }


    .barang-modal-form {
        padding: 20px;
    }


    .barang-form-grid {
        grid-template-columns: 1fr;

        gap: 16px;
    }


    .barang-modal-footer {
        flex-direction: column-reverse;

        gap: 10px;
    }


    .barang-modal-footer button {
        width: 100%;
    }

}


/* =====================================================
   SMALL MOBILE
===================================================== */

@media (max-width: 380px) {

    .barang-page {
        padding: 10px;
    }

    .barang-page-header {
        padding: 18px;
    }

    .barang-page-heading h1 {
        font-size: 22px;
    }

    .barang-modal-header {
        padding: 16px;
    }

    .barang-modal-form {
        padding: 16px;
    }

}





/* =====================================================
   PERBAIKI JARAK CONTENT DARI NAVBAR
===================================================== */

.app-main {
    padding-top: 0 !important;
    margin-top: 0 !important;
}

.app-main-content {
    padding-top: 24px !important;
    margin-top: 0 !important;
}


/* Container halaman */

.barang-page {
    margin-top: 0 !important;
    padding-top: 0 !important;
}


/* Jarak header Master Barang */

.barang-page-header {
    margin-top: 0 !important;
}


/* Responsive */

@media (max-width: 768px) {

    .app-main-content {
        padding-top: 16px !important;
    }

    .barang-page {
        padding-top: 0 !important;
    }

}






/* =====================================================
   TRANSAKSI STOK
===================================================== */

.transaksi-page {
    display: flex;
    flex-direction: column;
    gap: 24px;

    width: 100%;
    max-width: 1600px;
    min-width: 0;

    margin: 0 auto;
    padding: 26px;

    color: #1e293b;

    font-family: "Inter", "Segoe UI", Arial, sans-serif;
}


/* =====================================================
   HEADER
===================================================== */

.transaksi-page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;

    gap: 20px;

    padding: 28px 32px;

    background: linear-gradient(
        120deg,
        #065f46,
        #047857,
        #059669
    );

    color: #ffffff;

    border-radius: 18px;

    box-shadow:
        0 10px 28px rgba(6, 95, 70, 0.15);
}


.transaksi-page-label {
    display: block;

    margin-bottom: 9px;

    color: #bbf7d0;

    font-size: 10px;
    font-weight: 800;

    letter-spacing: 1.6px;
}


.transaksi-page-heading h1 {
    margin: 0;

    color: #ffffff;

    font-size: 28px;
    font-weight: 800;
}


.transaksi-page-heading p {
    margin: 9px 0 0;

    color: rgba(255, 255, 255, 0.85);

    font-size: 13px;
    line-height: 1.7;
}


/* =====================================================
   BUTTON
===================================================== */

.transaksi-btn-primary {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    gap: 9px;

    padding: 12px 20px;

    border: none;
    border-radius: 10px;

    background: #087f5b;

    color: #ffffff;

    font-size: 13px;
    font-weight: 700;

    cursor: pointer;

    white-space: nowrap;

    transition: all 0.25s ease;
}


.transaksi-page-header .transaksi-btn-primary {
    background: #ffffff;

    color: #065f46;
}


.transaksi-btn-primary:hover {
    background: #065f46;

    color: #ffffff;

    transform: translateY(-2px);

    box-shadow:
        0 7px 18px rgba(6, 95, 70, 0.18);
}


.transaksi-page-header .transaksi-btn-primary:hover {
    background: #d1fae5;

    color: #064e3b;
}


/* =====================================================
   ALERT
===================================================== */

.transaksi-alert {
    display: flex;
    align-items: center;

    gap: 12px;

    padding: 15px 18px;

    color: #b91c1c;

    background: #fef2f2;

    border: 1px solid #fecaca;
    border-radius: 12px;

    font-size: 13px;
}


/* =====================================================
   TABLE CARD
===================================================== */

.transaksi-table-card {
    width: 100%;
    min-width: 0;

    padding: 26px;

    background: #ffffff;

    border: 1px solid #e2e8f0;
    border-radius: 18px;

    box-shadow:
        0 8px 24px rgba(15, 23, 42, 0.045);
}


.transaksi-table-header {
    display: flex;
    justify-content: space-between;
    align-items: center;

    gap: 20px;

    margin-bottom: 22px;
}


.transaksi-table-header h2 {
    margin: 0;

    color: #0f172a;

    font-size: 20px;
    font-weight: 800;
}


.transaksi-table-header p {
    margin: 7px 0 0;

    color: #64748b;

    font-size: 13px;
}


.transaksi-total {
    display: inline-flex;
    align-items: center;

    gap: 9px;

    padding: 10px 14px;

    color: #087f5b;

    background: #ecfdf5;

    border: 1px solid #bbf7d0;
    border-radius: 10px;

    font-size: 12px;
    font-weight: 800;

    white-space: nowrap;
}


/* =====================================================
   TABLE
===================================================== */

.transaksi-table-wrapper {
    width: 100%;

    overflow-x: auto;

    border: 1px solid #e2e8f0;
    border-radius: 12px;
}


.transaksi-table {
    width: 100%;

    border-collapse: separate;
    border-spacing: 0;

    text-align: left;

    font-size: 13px;
}


.transaksi-table thead {
    background: #f8fafc;
}


.transaksi-table thead th {
    padding: 16px 20px;

    color: #64748b;

    font-size: 11px;
    font-weight: 800;

    text-transform: uppercase;
    letter-spacing: 0.5px;

    white-space: nowrap;

    border-bottom: 1px solid #e2e8f0;
}


.transaksi-table tbody td {
    padding: 17px 20px;

    color: #475569;

    border-bottom: 1px solid #f1f5f9;

    vertical-align: middle;
}


.transaksi-table tbody tr:last-child td {
    border-bottom: none;
}


.transaksi-table tbody tr {
    transition: background 0.2s ease;
}


.transaksi-table tbody tr:hover {
    background: #f8fffb;
}


.transaksi-table tbody td strong {
    color: #1e293b;

    font-weight: 700;
}


/* Nomor transaksi */

.transaksi-nomor {
    display: inline-flex;

    padding: 6px 10px;

    color: #087f5b;

    background: #ecfdf5;

    border-radius: 7px;

    font-size: 11px;
    font-weight: 800;
}


/* Jumlah transaksi */

.transaksi-jumlah {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    min-width: 35px;

    padding: 6px 10px;

    color: #065f46;

    background: #d1fae5;

    border-radius: 8px;

    font-size: 12px;
    font-weight: 800;
}


/* =====================================================
   TRANSACTION TYPE BADGES
===================================================== */

.transaksi-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    gap: 7px;

    padding: 7px 12px;

    border-radius: 20px;

    font-size: 11px;
    font-weight: 800;

    white-space: nowrap;
}


.transaksi-masuk {
    color: #047857;

    background: #d1fae5;

    border: 1px solid #a7f3d0;
}


.transaksi-keluar {
    color: #c2410c;

    background: #ffedd5;

    border: 1px solid #fed7aa;
}


/* =====================================================
   EMPTY DATA
===================================================== */

.transaksi-empty {
    padding: 45px 20px !important;

    text-align: center;

    color: #94a3b8 !important;
}


.transaksi-empty i {
    display: block;

    margin-bottom: 12px;

    color: #cbd5e1;

    font-size: 30px;
}


.transaksi-empty span {
    display: block;

    font-size: 13px;
}


/* =====================================================
   POPUP MODAL
===================================================== */

.transaksi-modal-overlay {
    display: flex;
    align-items: center;
    justify-content: center;

    position: fixed;
    z-index: 9999;

    inset: 0;

    padding: 20px;

    background: rgba(15, 23, 42, 0.58);

    backdrop-filter: blur(5px);

    opacity: 0;
    visibility: hidden;

    transition:
        opacity 0.25s ease,
        visibility 0.25s ease;
}


.transaksi-modal-overlay.transaksi-modal-show {
    opacity: 1;
    visibility: visible;
}


body.transaksi-modal-open {
    overflow: hidden;
}


/* Modal box */

.transaksi-modal {
    width: 100%;
    max-width: 620px;

    max-height: calc(100vh - 40px);

    overflow-y: auto;

    background: #ffffff;

    border-radius: 20px;

    box-shadow:
        0 25px 80px rgba(0, 0, 0, 0.25);

    transform: translateY(20px) scale(0.97);

    transition: transform 0.25s ease;
}


.transaksi-modal-show .transaksi-modal {
    transform: translateY(0) scale(1);
}


/* Modal header */

.transaksi-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;

    gap: 20px;

    padding: 24px 28px;

    background: linear-gradient(
        120deg,
        #065f46,
        #047857
    );

    color: #ffffff;

    border-radius: 20px 20px 0 0;
}


.transaksi-modal-title {
    display: flex;
    align-items: center;

    gap: 14px;
}


.transaksi-modal-icon {
    display: flex;
    align-items: center;
    justify-content: center;

    width: 48px;
    height: 48px;

    flex-shrink: 0;

    background: rgba(255, 255, 255, 0.16);

    border: 1px solid rgba(255, 255, 255, 0.18);

    border-radius: 13px;

    font-size: 20px;
}


.transaksi-modal-title h2 {
    margin: 0;

    color: #ffffff;

    font-size: 20px;
    font-weight: 800;
}


.transaksi-modal-title p {
    margin: 6px 0 0;

    color: rgba(255, 255, 255, 0.8);

    font-size: 12px;
}


/* Close button */

.transaksi-modal-close {
    display: flex;
    align-items: center;
    justify-content: center;

    width: 38px;
    height: 38px;

    flex-shrink: 0;

    border: 1px solid rgba(255, 255, 255, 0.2);

    border-radius: 10px;

    background: rgba(255, 255, 255, 0.12);

    color: #ffffff;

    font-size: 17px;

    cursor: pointer;

    transition: all 0.2s ease;
}


.transaksi-modal-close:hover {
    background: rgba(255, 255, 255, 0.25);

    transform: rotate(90deg);
}


/* =====================================================
   FORM
===================================================== */

.transaksi-modal-form {
    padding: 28px;
}


.transaksi-form-grid {
    display: grid;

    grid-template-columns: repeat(2, minmax(0, 1fr));

    gap: 20px;
}


.transaksi-form-group {
    display: flex;
    flex-direction: column;

    gap: 9px;

    min-width: 0;
}


.transaksi-form-group label {
    color: #334155;

    font-size: 12px;
    font-weight: 800;
}


.transaksi-form-group label span {
    color: #dc2626;
}


/* Inputs */

.transaksi-form-group input,
.transaksi-form-group select {
    width: 100%;
    min-width: 0;

    padding: 13px 14px;

    border: 1px solid #dbe3ed;
    border-radius: 10px;

    outline: none;

    background: #f8fafc;

    color: #1e293b;

    font-family: inherit;

    font-size: 13px;

    transition:
        border-color 0.2s ease,
        box-shadow 0.2s ease,
        background 0.2s ease;
}


.transaksi-form-group input:focus,
.transaksi-form-group select:focus {
    background: #ffffff;

    border-color: #087f5b;

    box-shadow:
        0 0 0 3px rgba(8, 127, 91, 0.10);
}


.transaksi-form-group input::placeholder {
    color: #94a3b8;
}


/* =====================================================
   MODAL FOOTER
===================================================== */

.transaksi-modal-footer {
    display: flex;
    justify-content: flex-end;
    align-items: center;

    gap: 12px;

    margin-top: 28px;
    padding-top: 20px;

    border-top: 1px solid #e2e8f0;
}


.transaksi-btn-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    padding: 12px 20px;

    color: #475569;

    background: #ffffff;

    border: 1px solid #cbd5e1;
    border-radius: 10px;

    font-size: 13px;
    font-weight: 700;

    cursor: pointer;

    transition: all 0.2s ease;
}


.transaksi-btn-secondary:hover {
    color: #0f172a;

    background: #f1f5f9;
}


/* =====================================================
   RESPONSIVE TABLET
===================================================== */

@media (max-width: 900px) {

    .transaksi-page {
        padding: 20px;
    }

    .transaksi-page-header {
        padding: 24px;
    }

    .transaksi-table-card {
        padding: 20px;
    }

}


/* =====================================================
   RESPONSIVE MOBILE
===================================================== */

@media (max-width: 600px) {

    .transaksi-page {
        padding: 14px;
        gap: 18px;
    }


    .transaksi-page-header {
        flex-direction: column;
        align-items: flex-start;

        gap: 20px;

        padding: 22px;

        border-radius: 15px;
    }


    .transaksi-page-heading h1 {
        font-size: 24px;
    }


    .transaksi-page-heading p {
        font-size: 12px;
    }


    .transaksi-page-header .transaksi-btn-primary {
        width: 100%;
    }


    .transaksi-table-card {
        padding: 16px;

        border-radius: 15px;
    }


    .transaksi-table-header {
        flex-direction: column;
        align-items: flex-start;

        gap: 14px;
    }


    .transaksi-table-header h2 {
        font-size: 18px;
    }


    .transaksi-table {
        min-width: 750px;
    }


    /* Modal mobile */

    .transaksi-modal-overlay {
        padding: 12px;
    }


    .transaksi-modal {
        max-height: calc(100vh - 24px);

        border-radius: 16px;
    }


    .transaksi-modal-header {
        padding: 20px;

        border-radius: 16px 16px 0 0;
    }


    .transaksi-modal-title h2 {
        font-size: 18px;
    }


    .transaksi-modal-form {
        padding: 20px;
    }


    .transaksi-form-grid {
        grid-template-columns: 1fr;

        gap: 16px;
    }


    .transaksi-modal-footer {
        flex-direction: column-reverse;

        gap: 10px;
    }


    .transaksi-modal-footer button {
        width: 100%;
    }

}


/* =====================================================
   SMALL MOBILE
===================================================== */

@media (max-width: 380px) {

    .transaksi-page {
        padding: 10px;
    }

    .transaksi-page-header {
        padding: 18px;
    }

    .transaksi-page-heading h1 {
        font-size: 22px;
    }

    .transaksi-modal-header {
        padding: 16px;
    }

    .transaksi-modal-form {
        padding: 16px;
    }

}


/* =====================================================
   LAPORAN TRANSAKSI
===================================================== */

.laporan-page {
    display: flex;
    flex-direction: column;

    gap: 24px;

    width: 100%;
    max-width: 1600px;
    min-width: 0;

    margin: 0 auto;
    padding: 26px;

    color: #1e293b;

    font-family: "Inter", "Segoe UI", Arial, sans-serif;
}


/* =====================================================
   HEADER
===================================================== */

.laporan-page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;

    gap: 20px;

    padding: 28px 32px;

    color: #ffffff;

    background: linear-gradient(
        120deg,
        #065f46,
        #047857,
        #059669
    );

    border-radius: 18px;

    box-shadow:
        0 10px 28px rgba(6, 95, 70, 0.15);
}


.laporan-page-label {
    display: block;

    margin-bottom: 9px;

    color: #bbf7d0;

    font-size: 10px;
    font-weight: 800;

    letter-spacing: 1.6px;
}


.laporan-page-heading h1 {
    margin: 0;

    color: #ffffff;

    font-size: 28px;
    font-weight: 800;
}


.laporan-page-heading p {
    margin: 9px 0 0;

    color: rgba(255, 255, 255, 0.85);

    font-size: 13px;
    line-height: 1.7;
}


/* =====================================================
   BUTTON PRINT
===================================================== */

.laporan-btn-print {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    gap: 9px;

    padding: 12px 20px;

    border: none;
    border-radius: 10px;

    background: #ffffff;

    color: #065f46;

    font-size: 13px;
    font-weight: 800;

    cursor: pointer;

    white-space: nowrap;

    transition: all 0.25s ease;
}


.laporan-btn-print:hover {
    background: #d1fae5;

    transform: translateY(-2px);

    box-shadow:
        0 7px 18px rgba(6, 95, 70, 0.18);
}


/* =====================================================
   FILTER CARD
===================================================== */

.laporan-filter-card {
    padding: 24px 26px;

    background: #ffffff;

    border: 1px solid #e2e8f0;
    border-radius: 18px;

    box-shadow:
        0 8px 24px rgba(15, 23, 42, 0.04);
}


.laporan-filter-heading {
    margin-bottom: 20px;
}


.laporan-filter-heading h2 {
    margin: 0;

    color: #0f172a;

    font-size: 19px;
    font-weight: 800;
}


.laporan-filter-heading p {
    margin: 7px 0 0;

    color: #64748b;

    font-size: 13px;
}


/* Filter form */

.laporan-filter-form {
    display: grid;

    grid-template-columns:
        repeat(3, minmax(0, 1fr))
        auto;

    align-items: end;

    gap: 16px;
}


.laporan-filter-group {
    display: flex;
    flex-direction: column;

    gap: 9px;

    min-width: 0;
}


.laporan-filter-group label {
    color: #334155;

    font-size: 12px;
    font-weight: 800;
}


.laporan-filter-group input,
.laporan-filter-group select {
    width: 100%;
    min-width: 0;

    padding: 12px 14px;

    background: #f8fafc;

    border: 1px solid #dbe3ed;
    border-radius: 10px;

    color: #1e293b;

    outline: none;

    font-family: inherit;
    font-size: 13px;

    transition: all 0.2s ease;
}


.laporan-filter-group input:focus,
.laporan-filter-group select:focus {
    background: #ffffff;

    border-color: #087f5b;

    box-shadow:
        0 0 0 3px rgba(8, 127, 91, 0.10);
}


/* Filter actions */

.laporan-filter-actions {
    display: flex;
    align-items: center;

    gap: 9px;
}


.laporan-btn-filter {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    gap: 8px;

    padding: 12px 18px;

    background: #087f5b;

    color: #ffffff;

    border: none;
    border-radius: 10px;

    font-size: 12px;
    font-weight: 800;

    cursor: pointer;

    transition: all 0.2s ease;
}


.laporan-btn-filter:hover {
    background: #065f46;

    transform: translateY(-1px);
}


.laporan-btn-reset {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    padding: 12px 16px;

    background: #f1f5f9;

    color: #475569;

    border: 1px solid #e2e8f0;
    border-radius: 10px;

    font-size: 12px;
    font-weight: 800;

    text-decoration: none;

    transition: all 0.2s ease;
}


.laporan-btn-reset:hover {
    background: #e2e8f0;
}


/* =====================================================
   TABLE CARD
===================================================== */

.laporan-table-card {
    width: 100%;
    min-width: 0;

    padding: 26px;

    background: #ffffff;

    border: 1px solid #e2e8f0;
    border-radius: 18px;

    box-shadow:
        0 8px 24px rgba(15, 23, 42, 0.045);
}


.laporan-table-header {
    display: flex;
    justify-content: space-between;
    align-items: center;

    gap: 20px;

    margin-bottom: 22px;
}


.laporan-table-header h2 {
    margin: 0;

    color: #0f172a;

    font-size: 20px;
    font-weight: 800;
}


.laporan-table-header p {
    margin: 7px 0 0;

    color: #64748b;

    font-size: 13px;
}


.laporan-total {
    display: inline-flex;
    align-items: center;

    gap: 9px;

    padding: 10px 14px;

    color: #087f5b;

    background: #ecfdf5;

    border: 1px solid #bbf7d0;
    border-radius: 10px;

    font-size: 12px;
    font-weight: 800;

    white-space: nowrap;
}


/* =====================================================
   TABLE
===================================================== */

.laporan-table-wrapper {
    width: 100%;

    overflow-x: auto;

    border: 1px solid #e2e8f0;
    border-radius: 12px;
}


.laporan-table {
    width: 100%;

    border-collapse: separate;
    border-spacing: 0;

    text-align: left;

    font-size: 13px;
}


.laporan-table thead {
    background: #f8fafc;
}


.laporan-table thead th {
    padding: 16px 20px;

    color: #64748b;

    font-size: 11px;
    font-weight: 800;

    text-transform: uppercase;
    letter-spacing: 0.5px;

    white-space: nowrap;

    border-bottom: 1px solid #e2e8f0;
}


.laporan-table tbody td {
    padding: 17px 20px;

    color: #475569;

    border-bottom: 1px solid #f1f5f9;

    vertical-align: middle;
}


.laporan-table tbody tr:last-child td {
    border-bottom: none;
}


.laporan-table tbody tr {
    transition: background 0.2s ease;
}


.laporan-table tbody tr:hover {
    background: #f8fffb;
}


.laporan-table tbody td strong {
    color: #1e293b;

    font-weight: 700;
}


/* Nomor transaksi */

.laporan-nomor {
    display: inline-flex;

    padding: 6px 10px;

    color: #087f5b;

    background: #ecfdf5;

    border-radius: 7px;

    font-size: 11px;
    font-weight: 800;
}


/* Jumlah */

.laporan-jumlah {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    min-width: 35px;

    padding: 6px 10px;

    color: #065f46;

    background: #d1fae5;

    border-radius: 8px;

    font-size: 12px;
    font-weight: 800;
}


/* =====================================================
   BADGE
===================================================== */

.laporan-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    gap: 7px;

    padding: 7px 12px;

    border-radius: 20px;

    font-size: 11px;
    font-weight: 800;

    white-space: nowrap;
}


.laporan-masuk {
    color: #047857;

    background: #d1fae5;

    border: 1px solid #a7f3d0;
}


.laporan-keluar {
    color: #c2410c;

    background: #ffedd5;

    border: 1px solid #fed7aa;
}


/* =====================================================
   EMPTY DATA
===================================================== */

.laporan-empty {
    padding: 45px 20px !important;

    text-align: center;

    color: #94a3b8 !important;
}


.laporan-empty i {
    display: block;

    margin-bottom: 12px;

    color: #cbd5e1;

    font-size: 30px;
}


.laporan-empty span {
    display: block;

    font-size: 13px;
}


/* =====================================================
   RESPONSIVE
===================================================== */

@media (max-width: 1000px) {

    .laporan-filter-form {
        grid-template-columns:
            repeat(2, minmax(0, 1fr));
    }

    .laporan-filter-actions {
        grid-column: 1 / -1;
    }

}


@media (max-width: 600px) {

    .laporan-page {
        padding: 14px;
        gap: 18px;
    }


    .laporan-page-header {
        flex-direction: column;
        align-items: flex-start;

        gap: 20px;

        padding: 22px;

        border-radius: 15px;
    }


    .laporan-page-heading h1 {
        font-size: 24px;
    }


    .laporan-page-heading p {
        font-size: 12px;
    }


    .laporan-btn-print {
        width: 100%;
    }


    .laporan-filter-card {
        padding: 18px;

        border-radius: 15px;
    }


    .laporan-filter-form {
        grid-template-columns: 1fr;

        gap: 14px;
    }


    .laporan-filter-actions {
        display: grid;

        grid-template-columns: 1fr 1fr;

        grid-column: auto;
    }


    .laporan-table-card {
        padding: 16px;

        border-radius: 15px;
    }


    .laporan-table-header {
        flex-direction: column;
        align-items: flex-start;

        gap: 14px;
    }


    .laporan-table-header h2 {
        font-size: 18px;
    }


    .laporan-table {
        min-width: 700px;
    }

}

/* =====================================================
   MANAJEMEN PENGGUNA
===================================================== */

.users-page {
    display: flex;
    flex-direction: column;

    gap: 24px;

    width: 100%;
    max-width: 1600px;
    min-width: 0;

    margin: 0 auto;
    padding: 26px;

    color: #1e293b;

    font-family: "Inter", "Segoe UI", Arial, sans-serif;
}


/* =====================================================
   HEADER
===================================================== */

.users-page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;

    gap: 20px;

    padding: 28px 32px;

    color: #ffffff;

    background: linear-gradient(
        120deg,
        #065f46,
        #047857,
        #059669
    );

    border-radius: 18px;

    box-shadow:
        0 10px 28px rgba(6, 95, 70, 0.15);
}


.users-page-label {
    display: block;

    margin-bottom: 9px;

    color: #bbf7d0;

    font-size: 10px;
    font-weight: 800;

    letter-spacing: 1.6px;
}


.users-page-heading h1 {
    margin: 0;

    color: #ffffff;

    font-size: 28px;
    font-weight: 800;
}


.users-page-heading p {
    margin: 9px 0 0;

    color: rgba(255, 255, 255, 0.85);

    font-size: 13px;
    line-height: 1.7;
}


/* =====================================================
   BUTTON
===================================================== */

.users-btn-primary {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    gap: 9px;

    padding: 12px 20px;

    border: none;
    border-radius: 10px;

    background: #087f5b;

    color: #ffffff;

    font-size: 13px;
    font-weight: 800;

    cursor: pointer;

    white-space: nowrap;

    transition: all 0.25s ease;
}


.users-page-header .users-btn-primary {
    background: #ffffff;

    color: #065f46;
}


.users-btn-primary:hover {
    background: #065f46;

    color: #ffffff;

    transform: translateY(-2px);

    box-shadow:
        0 7px 18px rgba(6, 95, 70, 0.18);
}


.users-page-header .users-btn-primary:hover {
    background: #d1fae5;

    color: #064e3b;
}


/* =====================================================
   ALERT
===================================================== */

.users-alert {
    display: flex;
    align-items: center;

    gap: 12px;

    padding: 15px 18px;

    color: #b91c1c;

    background: #fef2f2;

    border: 1px solid #fecaca;
    border-radius: 12px;

    font-size: 13px;
}


/* =====================================================
   TABLE CARD
===================================================== */

.users-table-card {
    width: 100%;
    min-width: 0;

    padding: 26px;

    background: #ffffff;

    border: 1px solid #e2e8f0;
    border-radius: 18px;

    box-shadow:
        0 8px 24px rgba(15, 23, 42, 0.045);
}


.users-table-header {
    display: flex;
    justify-content: space-between;
    align-items: center;

    gap: 20px;

    margin-bottom: 22px;
}


.users-table-header h2 {
    margin: 0;

    color: #0f172a;

    font-size: 20px;
    font-weight: 800;
}


.users-table-header p {
    margin: 7px 0 0;

    color: #64748b;

    font-size: 13px;
}


.users-total {
    display: inline-flex;
    align-items: center;

    gap: 9px;

    padding: 10px 14px;

    color: #087f5b;

    background: #ecfdf5;

    border: 1px solid #bbf7d0;
    border-radius: 10px;

    font-size: 12px;
    font-weight: 800;

    white-space: nowrap;
}


/* =====================================================
   TABLE
===================================================== */

.users-table-wrapper {
    width: 100%;

    overflow-x: auto;

    border: 1px solid #e2e8f0;
    border-radius: 12px;
}


.users-table {
    width: 100%;

    border-collapse: separate;
    border-spacing: 0;

    text-align: left;

    font-size: 13px;
}


.users-table thead {
    background: #f8fafc;
}


.users-table thead th {
    padding: 16px 20px;

    color: #64748b;

    font-size: 11px;
    font-weight: 800;

    text-transform: uppercase;
    letter-spacing: 0.5px;

    white-space: nowrap;

    border-bottom: 1px solid #e2e8f0;
}


.users-table tbody td {
    padding: 17px 20px;

    color: #475569;

    border-bottom: 1px solid #f1f5f9;

    vertical-align: middle;
}


.users-table tbody tr:last-child td {
    border-bottom: none;
}


.users-table tbody tr {
    transition: background 0.2s ease;
}


.users-table tbody tr:hover {
    background: #f8fffb;
}


/* =====================================================
   USER NAME
===================================================== */

.users-name-cell {
    display: flex;
    align-items: center;

    gap: 12px;
}


.users-name-cell strong {
    color: #1e293b;

    font-size: 13px;
    font-weight: 800;
}


.users-avatar {
    display: flex;
    align-items: center;
    justify-content: center;

    width: 38px;
    height: 38px;

    flex-shrink: 0;

    color: #047857;

    background: #d1fae5;

    border: 1px solid #a7f3d0;
    border-radius: 12px;

    font-size: 14px;
    font-weight: 900;
}


.users-username {
    color: #475569;

    font-weight: 600;
}


/* =====================================================
   ROLE
===================================================== */

.users-role {
    display: inline-flex;
    align-items: center;

    gap: 7px;

    padding: 7px 11px;

    color: #475569;

    background: #f1f5f9;

    border: 1px solid #e2e8f0;
    border-radius: 20px;

    font-size: 11px;
    font-weight: 800;
}


/* =====================================================
   STATUS
===================================================== */

.users-status {
    display: inline-flex;
    align-items: center;

    gap: 8px;

    padding: 7px 12px;

    border-radius: 20px;

    font-size: 11px;
    font-weight: 800;
}


.users-status-dot {
    width: 7px;
    height: 7px;

    border-radius: 50%;
}


.users-status-active {
    color: #047857;

    background: #d1fae5;

    border: 1px solid #a7f3d0;
}


.users-status-active .users-status-dot {
    background: #10b981;
}


.users-status-inactive {
    color: #b91c1c;

    background: #fee2e2;

    border: 1px solid #fecaca;
}


.users-status-inactive .users-status-dot {
    background: #ef4444;
}


/* =====================================================
   EMPTY DATA
===================================================== */

.users-empty {
    padding: 45px 20px !important;

    text-align: center;

    color: #94a3b8 !important;
}


.users-empty i {
    display: block;

    margin-bottom: 12px;

    color: #cbd5e1;

    font-size: 30px;
}


.users-empty span {
    display: block;

    font-size: 13px;
}


/* =====================================================
   POPUP MODAL
===================================================== */

.users-modal-overlay {
    display: flex;
    align-items: center;
    justify-content: center;

    position: fixed;
    z-index: 9999;

    inset: 0;

    padding: 20px;

    background: rgba(15, 23, 42, 0.58);

    backdrop-filter: blur(5px);

    opacity: 0;
    visibility: hidden;

    transition:
        opacity 0.25s ease,
        visibility 0.25s ease;
}


.users-modal-overlay.users-modal-show {
    opacity: 1;
    visibility: visible;
}


body.users-modal-open {
    overflow: hidden;
}


/* Modal box */

.users-modal {
    width: 100%;
    max-width: 520px;

    max-height: calc(100vh - 40px);

    overflow-y: auto;

    background: #ffffff;

    border-radius: 20px;

    box-shadow:
        0 25px 80px rgba(0, 0, 0, 0.25);

    transform: translateY(20px) scale(0.97);

    transition: transform 0.25s ease;
}


.users-modal-show .users-modal {
    transform: translateY(0) scale(1);
}


/* Modal header */

.users-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;

    gap: 20px;

    padding: 24px 28px;

    color: #ffffff;

    background: linear-gradient(
        120deg,
        #065f46,
        #047857
    );

    border-radius: 20px 20px 0 0;
}


.users-modal-title {
    display: flex;
    align-items: center;

    gap: 14px;
}


.users-modal-icon {
    display: flex;
    align-items: center;
    justify-content: center;

    width: 48px;
    height: 48px;

    flex-shrink: 0;

    background: rgba(255, 255, 255, 0.16);

    border: 1px solid rgba(255, 255, 255, 0.18);

    border-radius: 13px;

    font-size: 20px;
}


.users-modal-title h2 {
    margin: 0;

    color: #ffffff;

    font-size: 20px;
    font-weight: 800;
}


.users-modal-title p {
    margin: 6px 0 0;

    color: rgba(255, 255, 255, 0.8);

    font-size: 12px;
}


/* Close button */

.users-modal-close {
    display: flex;
    align-items: center;
    justify-content: center;

    width: 38px;
    height: 38px;

    flex-shrink: 0;

    border: 1px solid rgba(255, 255, 255, 0.2);

    border-radius: 10px;

    background: rgba(255, 255, 255, 0.12);

    color: #ffffff;

    font-size: 17px;

    cursor: pointer;

    transition: all 0.2s ease;
}


.users-modal-close:hover {
    background: rgba(255, 255, 255, 0.25);

    transform: rotate(90deg);
}


/* =====================================================
   FORM
===================================================== */

.users-modal-form {
    display: flex;
    flex-direction: column;

    gap: 20px;

    padding: 28px;
}


.users-form-group {
    display: flex;
    flex-direction: column;

    gap: 9px;
}


.users-form-group label {
    color: #334155;

    font-size: 12px;
    font-weight: 800;
}


.users-form-group label span {
    color: #dc2626;
}


.users-form-group input {
    width: 100%;

    padding: 13px 14px;

    border: 1px solid #dbe3ed;
    border-radius: 10px;

    outline: none;

    background: #f8fafc;

    color: #1e293b;

    font-family: inherit;
    font-size: 13px;

    transition: all 0.2s ease;
}


.users-form-group input:focus {
    background: #ffffff;

    border-color: #087f5b;

    box-shadow:
        0 0 0 3px rgba(8, 127, 91, 0.10);
}


.users-form-group input::placeholder {
    color: #94a3b8;
}


.users-form-group small {
    color: #64748b;

    font-size: 11px;
}


/* =====================================================
   MODAL FOOTER
===================================================== */

.users-modal-footer {
    display: flex;
    justify-content: flex-end;
    align-items: center;

    gap: 12px;

    margin-top: 6px;
    padding-top: 20px;

    border-top: 1px solid #e2e8f0;
}


.users-btn-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    padding: 12px 20px;

    color: #475569;

    background: #ffffff;

    border: 1px solid #cbd5e1;
    border-radius: 10px;

    font-size: 13px;
    font-weight: 700;

    cursor: pointer;

    transition: all 0.2s ease;
}


.users-btn-secondary:hover {
    color: #0f172a;

    background: #f1f5f9;
}


/* =====================================================
   RESPONSIVE
===================================================== */

@media (max-width: 900px) {

    .users-page {
        padding: 20px;
    }

    .users-page-header {
        padding: 24px;
    }

    .users-table-card {
        padding: 20px;
    }

}


@media (max-width: 600px) {

    .users-page {
        padding: 14px;
        gap: 18px;
    }


    .users-page-header {
        flex-direction: column;
        align-items: flex-start;

        gap: 20px;

        padding: 22px;

        border-radius: 15px;
    }


    .users-page-heading h1 {
        font-size: 24px;
    }


    .users-page-heading p {
        font-size: 12px;
    }


    .users-page-header .users-btn-primary {
        width: 100%;
    }


    .users-table-card {
        padding: 16px;

        border-radius: 15px;
    }


    .users-table-header {
        flex-direction: column;
        align-items: flex-start;

        gap: 14px;
    }


    .users-table-header h2 {
        font-size: 18px;
    }


    .users-table {
        min-width: 650px;
    }


    /* Modal mobile */

    .users-modal-overlay {
        padding: 12px;
    }


    .users-modal {
        max-height: calc(100vh - 24px);

        border-radius: 16px;
    }


    .users-modal-header {
        padding: 20px;

        border-radius: 16px 16px 0 0;
    }


    .users-modal-title h2 {
        font-size: 18px;
    }


    .users-modal-form {
        padding: 20px;
    }


    .users-modal-footer {
        flex-direction: column-reverse;

        gap: 10px;
    }


    .users-modal-footer button {
        width: 100%;
    }

}








/* =========================================
   MASTER KODE BARANG
========================================= */

.master-kode-page {
    width: 100%;
    max-width: 1600px;
    min-width: 0;

    margin: 0 auto;
    padding: 24px;

    display: flex;
    flex-direction: column;
    gap: 24px;
}


/* =========================================
   HEADER
========================================= */

.master-kode-header {
    display: flex;
    justify-content: space-between;
    align-items: center;

    gap: 20px;
    flex-wrap: wrap;
}

.master-kode-title {
    display: flex;
    align-items: center;
    gap: 15px;
}

.master-kode-title-icon {
    width: 52px;
    height: 52px;

    display: flex;
    align-items: center;
    justify-content: center;

    flex-shrink: 0;

    border-radius: 14px;

    background: linear-gradient(
        135deg,
        #16a34a,
        #15803d
    );

    color: #fff;
    font-size: 22px;

    box-shadow: 0 5px 12px rgba(22, 163, 74, 0.18);
}

.master-kode-title h2 {
    margin: 0;

    color: #14532d;

    font-size: 25px;
    font-weight: 700;
}

.master-kode-title p {
    margin: 6px 0 0;

    color: #64748b;

    font-size: 14px;
}


/* =========================================
   BUTTON TAMBAH
========================================= */

.master-kode-btn-tambah {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 9px;

    min-height: 44px;

    padding: 12px 18px;

    border: none;
    border-radius: 10px;

    background: #16a34a;
    color: #fff;

    font-family: inherit;
    font-size: 14px;
    font-weight: 600;

    cursor: pointer;

    transition:
        background 0.2s ease,
        transform 0.2s ease,
        box-shadow 0.2s ease;
}

.master-kode-btn-tambah:hover {
    background: #15803d;

    transform: translateY(-1px);

    box-shadow: 0 5px 12px rgba(22, 163, 74, 0.2);
}


/* =========================================
   ALERT ERROR
========================================= */

.master-kode-alert {
    display: flex;
    align-items: center;
    gap: 10px;

    padding: 14px 16px;

    border: 1px solid #fecaca;
    border-radius: 10px;

    background: #fef2f2;
    color: #b91c1c;

    font-size: 14px;
}


/* =========================================
   STAT CARD
========================================= */

.master-kode-stat-card {
    width: 100%;
    max-width: 300px;

    display: flex;
    align-items: center;
    gap: 16px;

    padding: 20px;

    border: 1px solid #dcfce7;
    border-radius: 14px;

    background: #fff;

    box-shadow: 0 4px 14px rgba(15, 23, 42, 0.03);
}

.master-kode-stat-icon {
    width: 52px;
    height: 52px;

    display: flex;
    align-items: center;
    justify-content: center;

    flex-shrink: 0;

    border-radius: 12px;

    background: #dcfce7;
    color: #15803d;

    font-size: 22px;
}

.master-kode-stat-info span {
    color: #64748b;
    font-size: 13px;
}

.master-kode-stat-info h3 {
    margin: 5px 0 0;

    color: #14532d;

    font-size: 25px;
    font-weight: 700;
}


/* =========================================
   CARD DAFTAR KODE BARANG
========================================= */

.master-kode-card {
    width: 100%;
    min-width: 0;

    overflow: hidden;

    border: 1px solid #e2e8f0;
    border-radius: 14px;

    background: #fff;

    box-shadow: 0 4px 15px rgba(15, 23, 42, 0.04);
}

.master-kode-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;

    gap: 15px;

    padding: 20px 24px;

    border-bottom: 1px solid #e2e8f0;
}

.master-kode-card-header h3 {
    margin: 0;

    color: #1e293b;

    font-size: 17px;
    font-weight: 700;
}

.master-kode-card-header p {
    margin: 6px 0 0;

    color: #64748b;

    font-size: 13px;
}

.master-kode-total {
    padding: 7px 12px;

    border-radius: 8px;

    background: #dcfce7;
    color: #166534;

    font-size: 12px;
    font-weight: 700;

    white-space: nowrap;
}


/* =========================================
   TABLE
========================================= */

.master-kode-table-wrapper {
    width: 100%;
    overflow-x: auto;
}

.master-kode-table {
    width: 100%;
    min-width: 650px;

    border-collapse: collapse;
}

.master-kode-table thead {
    background: #f0fdf4;
}

.master-kode-table th {
    padding: 15px 20px;

    color: #166534;

    text-align: left;

    font-size: 13px;
    font-weight: 700;

    white-space: nowrap;
}

.master-kode-table td {
    padding: 16px 20px;

    border-bottom: 1px solid #f1f5f9;

    color: #334155;

    font-size: 14px;
}

.master-kode-table tbody tr {
    transition: background 0.2s ease;
}

.master-kode-table tbody tr:hover {
    background: #f8fafc;
}

.master-kode-table tbody tr:last-child td {
    border-bottom: none;
}


/* KODE BARANG */

.master-kode-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;

    padding: 7px 11px;

    border-radius: 7px;

    background: #dcfce7;
    color: #166534;

    font-size: 12px;
    font-weight: 700;

    white-space: nowrap;
}

.master-kode-badge i {
    font-size: 12px;
}


/* NAMA BARANG */

.master-kode-nama {
    color: #1e293b;
    font-weight: 500;
}


/* HARGA */

.master-kode-harga {
    color: #166534;
    font-weight: 700;
    white-space: nowrap;
}


/* =========================================
   EMPTY STATE
========================================= */

.master-kode-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;

    padding: 55px 20px;

    text-align: center;
}

.master-kode-empty-icon {
    width: 65px;
    height: 65px;

    display: flex;
    align-items: center;
    justify-content: center;

    margin-bottom: 15px;

    border-radius: 50%;

    background: #f1f5f9;
    color: #94a3b8;

    font-size: 27px;
}

.master-kode-empty h4 {
    margin: 0;

    color: #334155;

    font-size: 16px;
    font-weight: 700;
}

.master-kode-empty p {
    margin: 8px 0 18px;

    color: #94a3b8;

    font-size: 13px;
}

.master-kode-empty-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;

    padding: 10px 15px;

    border: none;
    border-radius: 9px;

    background: #16a34a;
    color: #fff;

    font-size: 13px;
    font-weight: 600;

    cursor: pointer;
}

.master-kode-empty-btn:hover {
    background: #15803d;
}


/* =========================================
   MODAL OVERLAY
========================================= */

.master-kode-modal-overlay {
    position: fixed;
    inset: 0;

    z-index: 99999;

    display: none;
    align-items: center;
    justify-content: center;

    padding: 20px;

    background: rgba(15, 23, 42, 0.55);

    backdrop-filter: blur(3px);
    -webkit-backdrop-filter: blur(3px);
}

.master-kode-modal-overlay.active {
    display: flex;
}

body.master-kode-modal-open {
    overflow: hidden;
}


/* =========================================
   MODAL
========================================= */

.master-kode-modal {
    width: 100%;
    max-width: 480px;

    max-height: 90vh;
    overflow-y: auto;

    border-radius: 16px;

    background: #fff;

    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.2);

    animation: masterKodeModalShow 0.22s ease;
}

@keyframes masterKodeModalShow {
    from {
        opacity: 0;
        transform: translateY(15px) scale(0.98);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}


/* =========================================
   MODAL HEADER
========================================= */

.master-kode-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;

    gap: 15px;

    padding: 22px 24px;

    border-bottom: 1px solid #e2e8f0;
}

.master-kode-modal-heading {
    display: flex;
    align-items: center;
    gap: 13px;
}

.master-kode-modal-icon {
    width: 45px;
    height: 45px;

    display: flex;
    align-items: center;
    justify-content: center;

    flex-shrink: 0;

    border-radius: 11px;

    background: #dcfce7;
    color: #15803d;

    font-size: 19px;
}

.master-kode-modal-header h3 {
    margin: 0;

    color: #14532d;

    font-size: 19px;
    font-weight: 700;
}

.master-kode-modal-header p {
    margin: 6px 0 0;

    color: #64748b;

    font-size: 13px;
}


/* TOMBOL CLOSE */

.master-kode-modal-close {
    width: 34px;
    height: 34px;

    display: flex;
    align-items: center;
    justify-content: center;

    flex-shrink: 0;

    border: none;
    border-radius: 8px;

    background: #f1f5f9;
    color: #64748b;

    font-size: 25px;
    line-height: 1;

    cursor: pointer;

    transition: 0.2s ease;
}

.master-kode-modal-close:hover {
    background: #fee2e2;
    color: #dc2626;
}


/* =========================================
   MODAL BODY
========================================= */

.master-kode-modal-body {
    display: flex;
    flex-direction: column;
    gap: 20px;

    padding: 24px;
}


/* FORM GROUP */

.master-kode-form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.master-kode-form-group label {
    color: #334155;

    font-size: 13px;
    font-weight: 600;
}

.master-kode-form-group label span {
    color: #dc2626;
}


/* INPUT WRAPPER */

.master-kode-input-wrapper {
    position: relative;
    width: 100%;
}

.master-kode-input-wrapper > i {
    position: absolute;

    top: 50%;
    left: 14px;

    transform: translateY(-50%);

    color: #94a3b8;

    font-size: 14px;

    pointer-events: none;
}


/* INPUT */

.master-kode-form-group input {
    width: 100%;
    min-height: 46px;

    padding: 12px 14px 12px 40px;

    border: 1px solid #cbd5e1;
    border-radius: 9px;

    outline: none;

    background: #fff;
    color: #1e293b;

    font-family: inherit;
    font-size: 14px;

    transition:
        border-color 0.2s ease,
        box-shadow 0.2s ease;
}

.master-kode-form-group input:focus {
    border-color: #16a34a;

    box-shadow: 0 0 0 3px rgba(22, 163, 74, 0.12);
}

.master-kode-form-group input::placeholder {
    color: #94a3b8;
}

.master-kode-form-group small {
    color: #94a3b8;
    font-size: 12px;
}


/* INFO */

.master-kode-form-info {
    display: flex;
    align-items: flex-start;
    gap: 9px;

    padding: 12px;

    border: 1px solid #dcfce7;
    border-radius: 9px;

    background: #f0fdf4;
    color: #166534;

    font-size: 12px;
    line-height: 1.5;
}

.master-kode-form-info i {
    margin-top: 2px;
    flex-shrink: 0;
}


/* =========================================
   MODAL FOOTER
========================================= */

.master-kode-modal-footer {
    display: flex;
    justify-content: flex-end;
    align-items: center;

    gap: 10px;

    padding: 18px 24px;

    border-top: 1px solid #e2e8f0;

    background: #f8fafc;
}


/* BUTTON BATAL DAN SIMPAN */

.master-kode-btn-batal,
.master-kode-btn-simpan {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;

    min-height: 42px;

    padding: 10px 17px;

    border: none;
    border-radius: 9px;

    font-family: inherit;
    font-size: 13px;
    font-weight: 600;

    cursor: pointer;

    transition: 0.2s ease;
}

.master-kode-btn-batal {
    background: #e2e8f0;
    color: #334155;
}

.master-kode-btn-batal:hover {
    background: #cbd5e1;
}

.master-kode-btn-simpan {
    background: #16a34a;
    color: #fff;
}

.master-kode-btn-simpan:hover {
    background: #15803d;

    box-shadow: 0 4px 10px rgba(22, 163, 74, 0.15);
}


/* =========================================
   RESPONSIVE
========================================= */

@media (max-width: 768px) {

    .master-kode-page {
        padding: 16px;
        gap: 18px;
    }

    .master-kode-header {
        align-items: stretch;
        flex-direction: column;
    }

    .master-kode-title h2 {
        font-size: 21px;
    }

    .master-kode-btn-tambah {
        width: 100%;
    }

    .master-kode-stat-card {
        max-width: 100%;
    }

    .master-kode-card-header {
        padding: 16px;
    }

    .master-kode-modal-overlay {
        padding: 12px;
    }

    .master-kode-modal {
        max-width: 100%;
    }

    .master-kode-modal-header,
    .master-kode-modal-body,
    .master-kode-modal-footer {
        padding: 18px;
    }

    .master-kode-modal-footer {
        flex-direction: column-reverse;
    }

    .master-kode-btn-batal,
    .master-kode-btn-simpan {
        width: 100%;
    }

}

@media (max-width: 480px) {

    .master-kode-title {
        align-items: flex-start;
    }

    .master-kode-title-icon {
        width: 44px;
        height: 44px;

        font-size: 18px;
    }

    .master-kode-title h2 {
        font-size: 19px;
    }

    .master-kode-title p {
        font-size: 12px;
    }

    .master-kode-modal-header h3 {
        font-size: 17px;
    }

    .master-kode-modal-icon {
        width: 38px;
        height: 38px;

        font-size: 16px;
    }

}


/* =========================================================
   BARANG KELUAR - PAGE
========================================================= */

.bk-page,
.bk-page *,
.bk-modal-overlay,
.bk-modal-overlay * {
    box-sizing: border-box;
}

.bk-page {
    width: 100%;
    max-width: 1600px;
    min-width: 0;
    margin: 0 auto;
    padding: 24px;

    display: flex;
    flex-direction: column;
    gap: 24px;
}

/* =========================================================
   HEADER
========================================================= */

.bk-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    flex-wrap: wrap;
}

.bk-header-content {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.bk-title {
    margin: 0;
    color: #1e293b;
    font-size: 26px;
    font-weight: 700;
}

.bk-subtitle {
    margin: 0;
    color: #64748b;
    font-size: 14px;
    line-height: 1.6;
}

/* =========================================================
   BUTTON
========================================================= */

.bk-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;

    min-height: 42px;
    padding: 11px 18px;

    border: none;
    border-radius: 10px;

    font-family: inherit;
    font-size: 14px;
    font-weight: 600;

    text-decoration: none;
    cursor: pointer;

    transition: background 0.2s ease;
}

.bk-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.bk-btn-primary {
    color: #ffffff;
    background: #2563eb;
}

.bk-btn-primary:hover:not(:disabled) {
    background: #1d4ed8;
}

.bk-btn-secondary {
    color: #334155;
    background: #e2e8f0;
}

.bk-btn-secondary:hover {
    background: #cbd5e1;
}

/* =========================================================
   SUMMARY
========================================================= */

.bk-summary {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
}

.bk-summary-card {
    display: flex;
    flex-direction: column;
    gap: 10px;

    padding: 22px;

    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 16px;

    box-shadow: 0 4px 14px rgba(15, 23, 42, 0.04);
}

.bk-summary-label {
    color: #64748b;
    font-size: 13px;
}

.bk-summary-value {
    color: #0f172a;
    font-size: 28px;
    font-weight: 700;
}

/* =========================================================
   TABLE
========================================================= */

.bk-table-card {
    width: 100%;
    min-width: 0;

    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 16px;

    box-shadow: 0 4px 14px rgba(15, 23, 42, 0.04);
    overflow: hidden;
}

.bk-table-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;

    padding: 20px 24px;
    border-bottom: 1px solid #e2e8f0;
}

.bk-table-title {
    margin: 0;
    color: #1e293b;
    font-size: 18px;
    font-weight: 700;
}

.bk-table-wrapper {
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.bk-table {
    width: 100%;
    min-width: 850px;
    border-collapse: collapse;
}

.bk-table th {
    padding: 14px 18px;

    background: #f8fafc;
    border-bottom: 1px solid #e2e8f0;

    color: #64748b;
    text-align: left;
    white-space: nowrap;

    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
}

.bk-table td {
    padding: 15px 18px;

    border-bottom: 1px solid #f1f5f9;

    color: #334155;
    font-size: 14px;
    vertical-align: middle;
}

.bk-table tbody tr:hover {
    background: #f8fafc;
}

.bk-table tbody tr:last-child td {
    border-bottom: none;
}

.bk-table-empty {
    padding: 35px 20px !important;
    color: #94a3b8 !important;
    text-align: center;
}

/* =========================================================
   BADGE
========================================================= */

.bk-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    padding: 5px 10px;
    border-radius: 20px;

    font-size: 12px;
    font-weight: 600;
    white-space: nowrap;
}

.bk-badge-blue {
    color: #1d4ed8;
    background: #dbeafe;
}

.bk-badge-orange {
    color: #c2410c;
    background: #ffedd5;
}

/* =========================================================
   ALERT
========================================================= */

.bk-alert {
    padding: 14px 16px;
    border-radius: 10px;

    font-size: 14px;
    line-height: 1.5;
}

.bk-alert-success {
    color: #166534;
    background: #dcfce7;
    border: 1px solid #bbf7d0;
}

.bk-alert-danger {
    color: #991b1b;
    background: #fee2e2;
    border: 1px solid #fecaca;
}

/* =========================================================
   MODAL OVERLAY
   Popup menggunakan overlay sebagai scroll container.
   Ini membuat seluruh form bisa discroll di desktop/mobile.
========================================================= */

.bk-modal-overlay {
    position: fixed;
    inset: 0;
    z-index: 99999;

    display: none;

    width: 100%;
    height: 100%;
    height: 100vh;

    padding: 20px;

    background: rgba(15, 23, 42, 0.65);

    overflow-x: hidden;
    overflow-y: auto;

    -webkit-overflow-scrolling: touch;
    overscroll-behavior: contain;
}

/* =========================================================
   MODAL CONTENT
========================================================= */

.bk-modal {
    position: relative;

    width: 100%;
    max-width: 650px;

    height: auto;
    max-height: none;

    margin: 20px auto;

    background: #ffffff;
    border-radius: 18px;

    box-shadow: 0 25px 70px rgba(0, 0, 0, 0.25);

    overflow: visible;
}

/* =========================================================
   MODAL HEADER
========================================================= */

.bk-modal-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 15px;

    padding: 22px 26px;

    border-bottom: 1px solid #e2e8f0;
}

.bk-modal-heading {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.bk-modal-title {
    margin: 0;

    color: #1e293b;
    font-size: 20px;
    font-weight: 700;
}

.bk-modal-description {
    margin: 0;

    color: #64748b;
    font-size: 13px;
    line-height: 1.5;
}

.bk-modal-close {
    display: flex;
    align-items: center;
    justify-content: center;

    width: 36px;
    height: 36px;
    flex-shrink: 0;

    border: none;
    border-radius: 9px;

    background: #f1f5f9;
    color: #475569;

    font-size: 24px;
    cursor: pointer;
}

.bk-modal-close:hover {
    background: #e2e8f0;
}

/* =========================================================
   FORM BODY
========================================================= */

.bk-form-body {
    display: flex;
    flex-direction: column;
    gap: 18px;

    width: 100%;
    padding: 24px 26px;
}

/* =========================================================
   FORM GROUP
========================================================= */

.bk-form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;

    width: 100%;
    min-width: 0;
}

.bk-form-label {
    color: #334155;
    font-size: 13px;
    font-weight: 600;
}

.bk-form-label span {
    color: #dc2626;
}

.bk-form-control {
    display: block;

    width: 100%;
    min-width: 0;
    min-height: 44px;

    padding: 11px 13px;

    border: 1px solid #cbd5e1;
    border-radius: 10px;

    outline: none;

    background: #ffffff;
    color: #1e293b;

    font-family: inherit;
    font-size: 14px;

    transition: border-color 0.2s, box-shadow 0.2s;
}

.bk-form-control:focus {
    border-color: #2563eb;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.12);
}

.bk-form-control:disabled {
    background: #f1f5f9;
    color: #64748b;
    cursor: not-allowed;
}

textarea.bk-form-control {
    min-height: 100px;
    resize: vertical;
}

/* =========================================================
   FORM GRID
========================================================= */

.bk-form-row {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
}

/* =========================================================
   ITEM INFORMATION
========================================================= */

.bk-item-info {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;

    padding: 16px;

    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
}

.bk-item-info-box {
    display: flex;
    flex-direction: column;
    gap: 5px;

    min-width: 0;
}

.bk-item-info-label {
    color: #64748b;
    font-size: 12px;
}

.bk-item-info-value {
    color: #1e293b;
    font-size: 14px;
    font-weight: 700;
    overflow-wrap: anywhere;
}

/* =========================================================
   STOCK WARNING
========================================================= */

.bk-stock-warning {
    display: none;

    padding: 12px 14px;

    border-radius: 10px;

    color: #b91c1c;
    background: #fee2e2;

    font-size: 13px;
    line-height: 1.5;
}

.bk-stock-warning.show {
    display: block;
}

/* =========================================================
   MODAL FOOTER
========================================================= */

.bk-modal-footer {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 12px;
    flex-wrap: wrap;

    padding: 20px 26px;

    border-top: 1px solid #e2e8f0;
    background: #ffffff;

    border-radius: 0 0 18px 18px;
}

/* =========================================================
   TABLET
========================================================= */

@media (max-width: 1024px) {
    .bk-page {
        padding: 20px;
        gap: 20px;
    }

    .bk-summary {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

/* =========================================================
   MOBILE
========================================================= */

@media (max-width: 768px) {
    .bk-page {
        padding: 14px;
        gap: 18px;
    }

    .bk-header {
        align-items: stretch;
        flex-direction: column;
    }

    .bk-header .bk-btn {
        width: 100%;
    }

    .bk-title {
        font-size: 22px;
    }

    .bk-subtitle {
        font-size: 13px;
    }

    .bk-summary {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .bk-summary-card {
        padding: 18px;
    }

    .bk-summary-value {
        font-size: 24px;
    }

    .bk-table-header {
        padding: 16px;
    }

    /* Modal overlay bisa scroll sampai bawah */
    .bk-modal-overlay {
        padding: 10px;

        overflow-y: auto;
        overflow-x: hidden;

        -webkit-overflow-scrolling: touch;
    }

    .bk-modal {
        width: 100%;
        max-width: 100%;

        margin: 10px auto;

        height: auto;
        max-height: none;

        overflow: visible;
        border-radius: 14px;
    }

    .bk-modal-header {
        padding: 18px;
    }

    .bk-modal-title {
        font-size: 18px;
    }

    .bk-modal-description {
        font-size: 12px;
    }

    .bk-form-body {
        padding: 18px;
        gap: 16px;
    }

    .bk-form-row {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    .bk-item-info {
        grid-template-columns: 1fr 1fr;
        padding: 14px;
    }

    .bk-modal-footer {
        padding: 16px 18px;

        flex-direction: column-reverse;
        align-items: stretch;
    }

    .bk-modal-footer .bk-btn {
        width: 100%;
    }
}

/* =========================================================
   MOBILE KECIL
========================================================= */

@media (max-width: 480px) {
    .bk-page {
        padding: 10px;
    }

    .bk-title {
        font-size: 20px;
    }

    .bk-modal-overlay {
        padding: 6px;
    }

    .bk-modal {
        margin: 6px auto;
    }

    .bk-modal-header {
        padding: 15px;
    }

    .bk-form-body {
        padding: 15px;
    }

    .bk-modal-footer {
        padding: 15px;
    }

    .bk-item-info {
        grid-template-columns: 1fr;
    }

    .bk-form-control {
        font-size: 16px;
    }
}






/* =====================================================
   BARANG MASUK - DESKTOP, TABLET, MOBILE
   ===================================================== */

/* Reset khusus halaman barang masuk */
.bm-page,
.bm-page *,
.bm-page *::before,
.bm-page *::after {
    box-sizing: border-box;
}

.bm-page {
    display: flex;
    flex-direction: column;
    gap: 22px;

    width: 100%;
    max-width: 1600px;
    min-width: 0;

    margin: 0 auto;
    padding: 24px 28px 32px;

    min-height: auto;
    height: auto;
}

/* =====================================================
   HEADER HALAMAN
   ===================================================== */

.bm-page-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 16px;

    width: 100%;
    margin: 0;
    padding: 0;
}

.bm-page-header > div {
    min-width: 0;
}

.bm-page-title {
    margin: 0 0 7px;

    color: #172b4d;
    font-size: 26px;
    font-weight: 750;
    line-height: 1.3;
    overflow-wrap: anywhere;
}

.bm-page-subtitle {
    margin: 0;

    color: #64748b;
    font-size: 14px;
    line-height: 1.6;
}

/* =====================================================
   BUTTON
   ===================================================== */

.bm-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;

    min-height: 42px;
    padding: 11px 18px;

    border: 1px solid transparent;
    border-radius: 9px;

    font-family: inherit;
    font-size: 14px;
    font-weight: 650;
    line-height: 1.3;
    text-align: center;
    text-decoration: none;

    white-space: normal;
    cursor: pointer;

    transition:
        background-color 0.2s ease,
        border-color 0.2s ease,
        box-shadow 0.2s ease,
        transform 0.2s ease;
}

.bm-btn-primary {
    color: #fff;
    background: #2563eb;
    border-color: #2563eb;
}

.bm-btn-primary:hover {
    color: #fff;
    background: #1d4ed8;
    border-color: #1d4ed8;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.18);
}

.bm-btn-secondary {
    color: #334155;
    background: #fff;
    border-color: #cbd5e1;
}

.bm-btn-secondary:hover {
    color: #1e293b;
    background: #f1f5f9;
    border-color: #94a3b8;
}

.bm-btn:focus-visible {
    outline: 3px solid rgba(37, 99, 235, 0.25);
    outline-offset: 3px;
}

.bm-btn:active {
    transform: translateY(1px);
}

/* =====================================================
   CARD
   ===================================================== */

.bm-card {
    display: block;

    width: 100%;
    min-width: 0;
    height: auto;

    margin: 0;

    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 14px;

    box-shadow: 0 4px 18px rgba(15, 23, 42, 0.04);

    overflow: hidden;
}

.bm-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;

    min-height: 64px;
    padding: 18px 24px;

    background: #fff;
    border-bottom: 1px solid #e2e8f0;
}

.bm-card-title {
    margin: 0;

    color: #172b4d;
    font-size: 17px;
    font-weight: 700;
    line-height: 1.5;
}

.bm-card-body {
    width: 100%;
    min-width: 0;
    padding: 24px;
}

/* =====================================================
   ALERT / NOTIFIKASI
   ===================================================== */

.bm-alert {
    display: flex;
    align-items: flex-start;
    gap: 10px;

    width: 100%;
    margin: 0;
    padding: 14px 18px;

    border: 1px solid transparent;
    border-radius: 9px;

    font-size: 14px;
    line-height: 1.6;

    overflow-wrap: anywhere;
}

.bm-alert-success {
    color: #166534;
    background: #f0fdf4;
    border-color: #bbf7d0;
}

.bm-alert-danger {
    color: #991b1b;
    background: #fef2f2;
    border-color: #fecaca;
}

.bm-alert-warning {
    color: #92400e;
    background: #fffbeb;
    border-color: #fde68a;
}

/* =====================================================
   TABEL BARANG MASUK
   ===================================================== */

.bm-table-wrapper {
    display: block;

    width: 100%;
    max-width: 100%;
    min-width: 0;

    overflow-x: auto;
    overflow-y: hidden;

    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
}

.bm-table {
    width: 100%;
    min-width: 900px;

    margin: 0;
    border-collapse: separate;
    border-spacing: 0;

    background: #fff;

    color: #334155;
    font-size: 13px;
    text-align: left;
}

.bm-table thead {
    background: #f8fafc;
}

.bm-table thead th {
    padding: 15px 18px;

    color: #475569;
    background: #f8fafc;

    font-size: 12px;
    font-weight: 750;
    line-height: 1.5;
    letter-spacing: 0.35px;
    text-transform: uppercase;

    white-space: nowrap;
    vertical-align: middle;

    border-bottom: 1px solid #e2e8f0;
}

.bm-table tbody td {
    padding: 15px 18px;

    color: #334155;
    background: #fff;

    line-height: 1.6;
    vertical-align: middle;

    border-bottom: 1px solid #f1f5f9;
}

.bm-table tbody tr {
    transition: background-color 0.15s ease;
}

.bm-table tbody tr:hover td {
    background: #f8fafc;
}

.bm-table tbody tr:last-child td {
    border-bottom: none;
}

.bm-table-empty {
    height: 90px;
    padding: 25px 18px !important;

    color: #64748b !important;
    text-align: center !important;
    white-space: normal;

    background: #fff !important;
}

/* Badge jumlah barang */
.bm-quantity {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    min-width: 42px;
    padding: 5px 10px;

    color: #166534;
    background: #dcfce7;

    border-radius: 7px;

    font-size: 13px;
    font-weight: 700;
    white-space: nowrap;
}

/* =====================================================
   FORM TAMBAH BARANG MASUK
   ===================================================== */

.bm-form {
    display: flex;
    flex-direction: column;
    gap: 20px;

    width: 100%;
    max-width: 850px;
    margin: 0;
}

.bm-form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;

    width: 100%;
    min-width: 0;
    margin: 0;
}

.bm-form-label {
    display: block;

    margin: 0;

    color: #334155;
    font-size: 14px;
    font-weight: 650;
    line-height: 1.5;
}

.bm-required {
    color: #dc2626;
}

.bm-form-control {
    display: block;

    width: 100%;
    max-width: 100%;
    min-width: 0;
    min-height: 45px;

    margin: 0;
    padding: 11px 14px;

    color: #1e293b;
    background-color: #fff;

    border: 1px solid #cbd5e1;
    border-radius: 8px;

    font-family: inherit;
    font-size: 14px;
    line-height: 1.5;

    outline: none;

    transition:
        border-color 0.2s ease,
        box-shadow 0.2s ease;
}

.bm-form-control:hover {
    border-color: #94a3b8;
}

.bm-form-control:focus {
    border-color: #2563eb;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.bm-form-control::placeholder {
    color: #94a3b8;
    opacity: 1;
}

.bm-form-control:disabled {
    color: #64748b;
    background: #f1f5f9;
    cursor: not-allowed;
}

textarea.bm-form-control {
    min-height: 115px;
    resize: vertical;
}

select.bm-form-control {
    cursor: pointer;
}

.bm-form-help {
    margin: 0;

    color: #64748b;
    font-size: 12px;
    line-height: 1.6;
}

/* =====================================================
   TOMBOL FORM
   ===================================================== */

.bm-form-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    flex-wrap: wrap;
    gap: 12px;

    width: 100%;
    margin-top: 4px;
    padding-top: 20px;

    border-top: 1px solid #e2e8f0;
}

/* =====================================================
   TABLET
   ===================================================== */

@media (max-width: 1024px) {
    .bm-page {
        padding: 22px 22px 28px;
        gap: 20px;
    }

    .bm-page-title {
        font-size: 24px;
    }

    .bm-card-header {
        padding: 17px 20px;
    }

    .bm-card-body {
        padding: 20px;
    }
}

/* =====================================================
   MOBILE
   ===================================================== */

@media (max-width: 768px) {
    .bm-page {
        gap: 18px;
        padding: 18px 16px 24px;
    }

    .bm-page-header {
        align-items: stretch;
        flex-direction: column;
        gap: 14px;
    }

    .bm-page-title {
        font-size: 22px;
    }

    .bm-page-subtitle {
        font-size: 13px;
    }

    .bm-page-header > .bm-btn,
    .bm-page-header > a.bm-btn {
        width: 100%;
    }

    .bm-card {
        border-radius: 11px;
    }

    .bm-card-header {
        min-height: auto;
        padding: 16px;
    }

    .bm-card-title {
        font-size: 16px;
    }

    .bm-card-body {
        padding: 17px;
    }

    .bm-table {
        min-width: 850px;
    }

    .bm-table thead th {
        padding: 13px 14px;
    }

    .bm-table tbody td {
        padding: 13px 14px;
    }

    .bm-form {
        gap: 18px;
    }

    .bm-form-actions {
        flex-direction: column-reverse;
        align-items: stretch;
        gap: 10px;
    }

    .bm-form-actions .bm-btn {
        width: 100%;
    }
}

/* =====================================================
   MOBILE KECIL
   ===================================================== */

@media (max-width: 480px) {
    .bm-page {
        padding: 15px 12px 20px;
        gap: 16px;
    }

    .bm-page-title {
        font-size: 20px;
    }

    .bm-page-subtitle {
        font-size: 12px;
    }

    .bm-card-header {
        padding: 14px;
    }

    .bm-card-body {
        padding: 14px;
    }

    .bm-btn {
        min-height: 42px;
        padding: 10px 14px;
        font-size: 13px;
    }

    .bm-form-control {
        min-height: 44px;
        font-size: 16px;
    }

    textarea.bm-form-control {
        min-height: 100px;
    }

    .bm-alert {
        padding: 12px 14px;
        font-size: 13px;
    }
}

/* =====================================================
   AKSESIBILITAS: KURANGI ANIMASI
   ===================================================== */

@media (prefers-reduced-motion: reduce) {
    .bm-btn,
    .bm-table tbody tr,
    .bm-form-control {
        transition: none;
    }
}


/* =========================================
   BARANG KELUAR
========================================= */

.bk-page,
.bk-page *,
.bk-page *::before,
.bk-page *::after {
    box-sizing: border-box;
}

.bk-page {
    display: flex;
    flex-direction: column;
    gap: 22px;

    width: 100%;
    max-width: 1600px;
    min-width: 0;

    height: auto;
    min-height: auto;

    margin: 0 auto;
    padding: 24px 28px 32px;
}

/* HEADER */

.bk-page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 16px;
}

.bk-page-title {
    margin: 0 0 7px;
    color: #172b4d;
    font-size: 26px;
    font-weight: 750;
    line-height: 1.3;
}

.bk-page-subtitle {
    margin: 0;
    color: #64748b;
    font-size: 14px;
    line-height: 1.6;
}

/* BUTTON */

.bk-btn {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    gap: 8px;

    min-height: 42px;
    padding: 11px 18px;

    border: 1px solid transparent;
    border-radius: 9px;

    font-family: inherit;
    font-size: 14px;
    font-weight: 650;
    text-decoration: none;
    text-align: center;

    cursor: pointer;
    transition: 0.2s ease;
}

.bk-btn-primary {
    color: #fff;
    background: #2563eb;
    border-color: #2563eb;
}

.bk-btn-primary:hover {
    color: #fff;
    background: #1d4ed8;
    box-shadow: 0 4px 12px rgba(37, 99, 235, .18);
}

.bk-btn-secondary {
    color: #334155;
    background: #fff;
    border-color: #cbd5e1;
}

.bk-btn-secondary:hover {
    background: #f1f5f9;
}

/* CARD */

.bk-card {
    width: 100%;
    min-width: 0;
    height: auto;

    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 14px;

    box-shadow: 0 4px 18px rgba(15, 23, 42, .04);
    overflow: hidden;
}

.bk-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;

    min-height: 64px;
    padding: 18px 24px;

    border-bottom: 1px solid #e2e8f0;
}

.bk-card-title {
    margin: 0;
    color: #172b4d;
    font-size: 17px;
    font-weight: 700;
}

.bk-card-body {
    width: 100%;
    min-width: 0;
    padding: 24px;
}

/* ALERT */

.bk-alert {
    padding: 14px 18px;
    border: 1px solid transparent;
    border-radius: 9px;
    font-size: 14px;
    line-height: 1.6;
    overflow-wrap: anywhere;
}

.bk-alert-success {
    color: #166534;
    background: #f0fdf4;
    border-color: #bbf7d0;
}

.bk-alert-danger {
    color: #991b1b;
    background: #fef2f2;
    border-color: #fecaca;
}

.bk-alert-warning {
    color: #92400e;
    background: #fffbeb;
    border-color: #fde68a;
}

/* TABLE */

.bk-table-wrapper {
    width: 100%;
    min-width: 0;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.bk-table {
    width: 100%;
    min-width: 950px;

    margin: 0;
    border-collapse: separate;
    border-spacing: 0;

    font-size: 13px;
    text-align: left;
}

.bk-table thead {
    background: #f8fafc;
}

.bk-table th {
    padding: 15px 18px;
    color: #475569;
    background: #f8fafc;

    font-size: 12px;
    font-weight: 750;
    text-transform: uppercase;
    letter-spacing: .35px;
    white-space: nowrap;

    border-bottom: 1px solid #e2e8f0;
}

.bk-table td {
    padding: 15px 18px;
    color: #334155;
    line-height: 1.6;
    vertical-align: middle;

    border-bottom: 1px solid #f1f5f9;
}

.bk-table tbody tr:hover td {
    background: #f8fafc;
}

.bk-table tbody tr:last-child td {
    border-bottom: none;
}

.bk-table-empty {
    height: 90px;
    padding: 25px 18px !important;
    color: #64748b !important;
    text-align: center;
    white-space: normal;
}

.bk-quantity {
    display: inline-flex;
    justify-content: center;
    align-items: center;

    min-width: 42px;
    padding: 5px 10px;

    color: #9a3412;
    background: #ffedd5;
    border-radius: 7px;

    font-size: 13px;
    font-weight: 700;
}

/* FORM */

.bk-form {
    display: flex;
    flex-direction: column;
    gap: 20px;

    width: 100%;
    max-width: 850px;
}

.bk-form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
    width: 100%;
    min-width: 0;
}

.bk-form-label {
    color: #334155;
    font-size: 14px;
    font-weight: 650;
    line-height: 1.5;
}

.bk-required {
    color: #dc2626;
}

.bk-form-control {
    display: block;
    width: 100%;
    min-width: 0;
    min-height: 45px;

    padding: 11px 14px;

    color: #1e293b;
    background: #fff;

    border: 1px solid #cbd5e1;
    border-radius: 8px;

    font-family: inherit;
    font-size: 14px;
    line-height: 1.5;

    outline: none;
    transition: border-color .2s, box-shadow .2s;
}

.bk-form-control:focus {
    border-color: #2563eb;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, .1);
}

.bk-form-control::placeholder {
    color: #94a3b8;
}

textarea.bk-form-control {
    min-height: 115px;
    resize: vertical;
}

/* INFORMASI STOK */

.bk-stock-info {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;

    padding: 15px 18px;

    color: #1e40af;
    background: #eff6ff;
    border: 1px solid #bfdbfe;
    border-radius: 10px;
}

.bk-stock-label {
    font-size: 13px;
    font-weight: 600;
}

.bk-stock-info strong {
    font-size: 17px;
    font-weight: 750;
}

/* FORM ACTION */

.bk-form-actions {
    display: flex;
    justify-content: flex-end;
    flex-wrap: wrap;
    gap: 12px;

    padding-top: 20px;
    border-top: 1px solid #e2e8f0;
}

/* TABLET */

@media (max-width: 1024px) {
    .bk-page {
        padding: 22px;
        gap: 20px;
    }

    .bk-card-header {
        padding: 17px 20px;
    }

    .bk-card-body {
        padding: 20px;
    }
}

/* MOBILE */

@media (max-width: 768px) {
    .bk-page {
        padding: 18px 16px 24px;
        gap: 18px;
    }

    .bk-page-header {
        flex-direction: column;
        align-items: stretch;
        gap: 14px;
    }

    .bk-page-title {
        font-size: 22px;
    }

    .bk-page-subtitle {
        font-size: 13px;
    }

    .bk-page-header .bk-btn {
        width: 100%;
    }

    .bk-card {
        border-radius: 11px;
    }

    .bk-card-header {
        min-height: auto;
        padding: 16px;
    }

    .bk-card-body {
        padding: 17px;
    }

    .bk-table {
        min-width: 950px;
    }

    .bk-table th,
    .bk-table td {
        padding: 13px 14px;
    }

    .bk-form {
        gap: 18px;
    }

    .bk-form-actions {
        flex-direction: column-reverse;
        align-items: stretch;
    }

    .bk-form-actions .bk-btn {
        width: 100%;
    }
}

/* MOBILE KECIL */

@media (max-width: 480px) {
    .bk-page {
        padding: 15px 12px 20px;
        gap: 16px;
    }

    .bk-page-title {
        font-size: 20px;
    }

    .bk-card-header,
    .bk-card-body {
        padding: 14px;
    }

    .bk-btn {
        min-height: 42px;
        padding: 10px 14px;
        font-size: 13px;
    }

    .bk-form-control {
        font-size: 16px;
    }

    .bk-stock-info {
        align-items: flex-start;
        flex-direction: column;
        gap: 6px;
    }
}





/* =========================================
   HALAMAN STOK BARANG
========================================= */

.stk-page,
.stk-page *,
.stk-page *::before,
.stk-page *::after {
    box-sizing: border-box;
}

.stk-page {
    display: flex;
    flex-direction: column;
    gap: 22px;

    width: 100%;
    max-width: 1600px;
    min-width: 0;

    margin: 0 auto;
    padding: 24px 28px 32px;
}

.stk-page-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 16px;
}

.stk-page-title {
    margin: 0 0 7px;
    color: #172b4d;
    font-size: 26px;
    font-weight: 750;
    line-height: 1.3;
}

.stk-page-subtitle {
    margin: 0;
    color: #64748b;
    font-size: 14px;
    line-height: 1.6;
}

/* RINGKASAN */

.stk-summary-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 16px;
    width: 100%;
}

.stk-summary-card {
    min-width: 0;
    padding: 22px;

    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 13px;

    box-shadow: 0 4px 15px rgba(15, 23, 42, .035);
}

.stk-summary-label {
    margin-bottom: 12px;
    color: #64748b;
    font-size: 13px;
    font-weight: 600;
}

.stk-summary-value {
    color: #172b4d;
    font-size: 29px;
    font-weight: 750;
    line-height: 1.25;
    overflow-wrap: anywhere;
}

.stk-summary-note {
    margin-top: 10px;
    color: #94a3b8;
    font-size: 12px;
    line-height: 1.5;
}

.stk-summary-in {
    border-top: 3px solid #16a34a;
}

.stk-summary-in .stk-summary-value {
    color: #15803d;
}

.stk-summary-out {
    border-top: 3px solid #ea580c;
}

.stk-summary-out .stk-summary-value {
    color: #c2410c;
}

/* CARD TABEL */

.stk-card {
    width: 100%;
    min-width: 0;

    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 14px;

    box-shadow: 0 4px 18px rgba(15, 23, 42, .04);
    overflow: hidden;
}

.stk-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 16px;

    padding: 21px 24px;
    border-bottom: 1px solid #e2e8f0;
}

.stk-card-title {
    margin: 0;
    color: #172b4d;
    font-size: 17px;
    font-weight: 750;
}

.stk-card-subtitle {
    margin: 7px 0 0;
    color: #64748b;
    font-size: 13px;
    line-height: 1.5;
}

/* BUTTON */

.stk-btn {
    display: inline-flex;
    justify-content: center;
    align-items: center;

    min-height: 42px;
    padding: 11px 17px;

    color: #fff;
    background: #2563eb;
    border: 1px solid #2563eb;
    border-radius: 9px;

    font-family: inherit;
    font-size: 13px;
    font-weight: 650;
    text-decoration: none;
    text-align: center;

    transition: background .2s ease;
}

.stk-btn:hover {
    color: #fff;
    background: #1d4ed8;
}

/* TABEL */

.stk-table-wrapper {
    width: 100%;
    min-width: 0;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.stk-table {
    width: 100%;
    min-width: 1000px;

    border-collapse: separate;
    border-spacing: 0;

    color: #334155;
    background: #fff;
    font-size: 13px;
    text-align: left;
}

.stk-table thead th {
    padding: 15px 17px;

    color: #475569;
    background: #f8fafc;

    border-bottom: 1px solid #e2e8f0;

    font-size: 11px;
    font-weight: 750;
    letter-spacing: .35px;
    text-transform: uppercase;
    white-space: nowrap;
}

.stk-table tbody td {
    padding: 16px 17px;
    border-bottom: 1px solid #f1f5f9;
    vertical-align: middle;
    line-height: 1.5;
}

.stk-table tbody tr:hover td {
    background: #f8fafc;
}

.stk-table tbody tr:last-child td {
    border-bottom: none;
}

.stk-code {
    display: inline-block;
    padding: 5px 8px;

    color: #1d4ed8;
    background: #eff6ff;
    border-radius: 6px;

    font-size: 12px;
    font-weight: 700;
    white-space: nowrap;
}

.stk-name {
    min-width: 140px;
    color: #172b4d !important;
    font-weight: 650;
}

.stk-number {
    font-weight: 700;
    white-space: nowrap;
}

.stk-number-in {
    color: #15803d;
}

.stk-number-out {
    color: #c2410c;
}

.stk-ending {
    color: #172b4d;
    font-size: 15px;
    white-space: nowrap;
}

.stk-unit {
    display: inline-block;
    padding: 5px 9px;

    color: #475569;
    background: #f1f5f9;
    border: 1px solid #e2e8f0;
    border-radius: 6px;

    font-size: 12px;
    font-weight: 650;
    white-space: nowrap;
}

/* STATUS */

.stk-status {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    padding: 6px 9px;
    border-radius: 20px;

    font-size: 11px;
    font-weight: 700;
    white-space: nowrap;
}

.stk-status-available {
    color: #166534;
    background: #dcfce7;
}

.stk-status-empty {
    color: #92400e;
    background: #fef3c7;
}

.stk-status-negative {
    color: #991b1b;
    background: #fee2e2;
}

.stk-empty {
    padding: 40px 20px !important;
    color: #64748b;
    text-align: center;
}

.stk-card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 10px;

    padding: 15px 24px;

    color: #64748b;
    background: #fafcff;
    border-top: 1px solid #e2e8f0;

    font-size: 12px;
    line-height: 1.5;
}

/* TABLET */

@media (max-width: 1100px) {
    .stk-summary-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .stk-page {
        padding: 22px;
    }
}

/* MOBILE */

@media (max-width: 768px) {
    .stk-page {
        gap: 18px;
        padding: 18px 16px 24px;
    }

    .stk-page-title {
        font-size: 22px;
    }

    .stk-page-subtitle {
        font-size: 13px;
    }

    .stk-summary-grid {
        gap: 12px;
    }

    .stk-summary-card {
        padding: 17px;
        border-radius: 11px;
    }

    .stk-summary-value {
        font-size: 24px;
    }

    .stk-summary-label {
        font-size: 12px;
    }

    .stk-summary-note {
        font-size: 11px;
    }

    .stk-card {
        border-radius: 11px;
    }

    .stk-card-header {
        align-items: stretch;
        flex-direction: column;
        padding: 17px;
    }

    .stk-card-header .stk-btn {
        width: 100%;
    }

    .stk-table {
        min-width: 1000px;
    }

    .stk-card-footer {
        align-items: flex-start;
        flex-direction: column;
        padding: 14px 17px;
    }
}

/* HP KECIL */

@media (max-width: 380px) {
    .stk-page {
        padding: 14px 10px 20px;
    }

    .stk-summary-grid {
        grid-template-columns: minmax(0, 1fr);
    }

    .stk-summary-card {
        padding: 16px;
    }

    .stk-summary-value {
        font-size: 25px;
    }
}



/* =========================
   BARANG MASUK
========================= */
.bm-page {
    width: 100%;
    max-width: 1600px;
    min-width: 0;
    margin: 0 auto;
    padding: 24px;
    display: flex;
    flex-direction: column;
    gap: 22px;
    box-sizing: border-box;
}

.bm-page *,
.bm-page *::before,
.bm-page *::after {
    box-sizing: border-box;
}

.bm-page-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
}

.bm-page-header h1 {
    margin: 0;
    font-size: 27px;
    color: #172033;
}

.bm-page-header p,
.bm-card-header p {
    margin: 6px 0 0;
    color: #64748b;
    font-size: 13px;
}

.bm-btn {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    padding: 11px 17px;
    border: 0;
    border-radius: 9px;
    font-size: 13px;
    font-weight: 650;
    text-decoration: none;
    cursor: pointer;
}

.bm-btn-primary {
    color: #fff;
    background: #2563eb;
}

.bm-btn-primary:hover {
    background: #1d4ed8;
}

.bm-btn-secondary {
    color: #334155;
    background: #f1f5f9;
    border: 1px solid #dbe3ed;
}

.bm-summary-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
}

.bm-summary-card,
.bm-card {
    min-width: 0;
    background: #fff;
    border: 1px solid #e7edf4;
    border-radius: 14px;
    box-shadow: 0 4px 16px rgba(15, 23, 42, .04);
}

.bm-summary-card {
    padding: 21px;
}

.bm-summary-card span {
    display: block;
    margin-bottom: 10px;
    color: #64748b;
    font-size: 13px;
}

.bm-summary-card strong {
    display: block;
    color: #172033;
    font-size: 23px;
    overflow-wrap: anywhere;
}

.bm-summary-card:last-child strong {
    color: #047857;
}

.bm-card {
    overflow: hidden;
}

.bm-card-header {
    padding: 22px 24px;
    border-bottom: 1px solid #edf1f5;
}

.bm-card-header h2 {
    margin: 0;
    color: #172033;
    font-size: 18px;
}

.bm-table-wrap {
    width: 100%;
    overflow-x: auto;
}

.bm-table {
    width: 100%;
    min-width: 1150px;
    border-collapse: collapse;
    font-size: 13px;
}

.bm-table th,
.bm-table td {
    padding: 14px 15px;
    border-bottom: 1px solid #edf1f5;
    text-align: left;
    white-space: nowrap;
}

.bm-table thead th {
    background: #f8fafc;
    color: #64748b;
    font-size: 11px;
    font-weight: 750;
    text-transform: uppercase;
}

.bm-table tbody tr:hover {
    background: #f8fafc;
}

.bm-table .bm-right {
    text-align: right;
}

.bm-table tfoot th {
    padding: 17px 15px;
    background: #f8fafc;
    border-top: 1px solid #e2e8f0;
}

.bm-code {
    display: inline-block;
    padding: 5px 8px;
    border-radius: 6px;
    background: #eff6ff;
    color: #1d4ed8;
    font-weight: 650;
}

.bm-price-total {
    color: #047857;
    font-weight: 750;
}

.bm-empty {
    padding: 35px !important;
    text-align: center !important;
    color: #64748b;
}

.bm-form {
    padding: 24px;
}

.bm-form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px;
}

.bm-form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
    min-width: 0;
}

.bm-form-group label {
    color: #334155;
    font-size: 13px;
    font-weight: 650;
}

.bm-form-group input,
.bm-form-group select,
.bm-form-group textarea {
    width: 100%;
    min-width: 0;
    padding: 11px 12px;
    border: 1px solid #dbe3ed;
    border-radius: 8px;
    background: #fff;
    color: #1e293b;
    font: inherit;
    outline: none;
}

.bm-form-group input,
.bm-form-group select {
    min-height: 44px;
}

.bm-form-group input:focus,
.bm-form-group select:focus,
.bm-form-group textarea:focus {
    border-color: #2563eb;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, .1);
}

.bm-form-group input[readonly] {
    background: #f8fafc;
    font-weight: 600;
}

.bm-form-group small {
    color: #64748b;
    font-size: 12px;
}

.bm-span-2 {
    grid-column: span 2;
}

.bm-form-actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 25px;
    padding-top: 20px;
    border-top: 1px solid #edf1f5;
}

.bm-alert {
    padding: 13px 16px;
    border-radius: 9px;
    font-size: 14px;
}

.bm-alert-success {
    color: #166534;
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
}

.bm-alert-error {
    color: #991b1b;
    background: #fef2f2;
    border: 1px solid #fecaca;
}

@media (max-width: 900px) {
    .bm-summary-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 600px) {
    .bm-page {
        padding: 14px;
        gap: 16px;
    }

    .bm-page-header h1 {
        font-size: 23px;
    }

    .bm-summary-grid,
    .bm-form-grid {
        grid-template-columns: 1fr;
    }

    .bm-span-2 {
        grid-column: auto;
    }

    .bm-form {
        padding: 17px;
    }

    .bm-card-header {
        padding: 18px;
    }

    .bm-form-actions {
        flex-direction: column-reverse;
    }

    .bm-form-actions .bm-btn {
        width: 100%;
    }
}


/* =========================
   BARANG KELUAR
========================= */
.bk-page {
    width: 100%;
    max-width: 1600px;
    min-width: 0;
    margin: 0 auto;
    padding: 24px;
    display: flex;
    flex-direction: column;
    gap: 22px;
    box-sizing: border-box;
}

.bk-page *,
.bk-page *::before,
.bk-page *::after {
    box-sizing: border-box;
}

.bk-page-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
}

.bk-page-header h1 {
    margin: 0;
    font-size: 27px;
    color: #172033;
}

.bk-page-header p,
.bk-card-header p {
    margin: 6px 0 0;
    color: #64748b;
    font-size: 13px;
}

.bk-btn {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    padding: 11px 17px;
    border: 0;
    border-radius: 9px;
    font-size: 13px;
    font-weight: 650;
    text-decoration: none;
    cursor: pointer;
}

.bk-btn-primary {
    color: #fff;
    background: #2563eb;
}

.bk-btn-primary:hover {
    background: #1d4ed8;
}

.bk-btn-secondary {
    color: #334155;
    background: #f1f5f9;
    border: 1px solid #dbe3ed;
}

.bk-summary-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
}

.bk-summary-card,
.bk-card {
    min-width: 0;
    background: #fff;
    border: 1px solid #e7edf4;
    border-radius: 14px;
    box-shadow: 0 4px 16px rgba(15, 23, 42, .04);
}

.bk-summary-card {
    padding: 21px;
}

.bk-summary-card span {
    display: block;
    margin-bottom: 10px;
    color: #64748b;
    font-size: 13px;
}

.bk-summary-card strong {
    display: block;
    color: #172033;
    font-size: 23px;
    overflow-wrap: anywhere;
}

.bk-summary-card:last-child strong {
    color: #dc2626;
}

.bk-card {
    overflow: hidden;
}

.bk-card-header {
    padding: 22px 24px;
    border-bottom: 1px solid #edf1f5;
}

.bk-card-header h2 {
    margin: 0;
    color: #172033;
    font-size: 18px;
}

.bk-table-wrap {
    width: 100%;
    overflow-x: auto;
}

.bk-table {
    width: 100%;
    min-width: 1300px;
    border-collapse: collapse;
    font-size: 13px;
}

.bk-table th,
.bk-table td {
    padding: 14px 15px;
    border-bottom: 1px solid #edf1f5;
    text-align: left;
    white-space: nowrap;
}

.bk-table thead th {
    background: #f8fafc;
    color: #64748b;
    font-size: 11px;
    font-weight: 750;
    text-transform: uppercase;
}

.bk-table tbody tr:hover {
    background: #f8fafc;
}

.bk-table .bk-right {
    text-align: right;
}

.bk-table tfoot th {
    padding: 17px 15px;
    background: #f8fafc;
    border-top: 1px solid #e2e8f0;
}

.bk-code {
    display: inline-block;
    padding: 5px 8px;
    border-radius: 6px;
    background: #eff6ff;
    color: #1d4ed8;
    font-weight: 650;
}

.bk-price-total {
    color: #dc2626;
    font-weight: 750;
}

.bk-empty {
    padding: 35px !important;
    text-align: center !important;
    color: #64748b;
}

.bk-form {
    padding: 24px;
}

.bk-form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px;
}

.bk-form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
    min-width: 0;
}

.bk-form-group label {
    color: #334155;
    font-size: 13px;
    font-weight: 650;
}

.bk-form-group input,
.bk-form-group select,
.bk-form-group textarea {
    width: 100%;
    min-width: 0;
    padding: 11px 12px;
    border: 1px solid #dbe3ed;
    border-radius: 8px;
    background: #fff;
    color: #1e293b;
    font: inherit;
    outline: none;
}

.bk-form-group input,
.bk-form-group select {
    min-height: 44px;
}

.bk-form-group input:focus,
.bk-form-group select:focus,
.bk-form-group textarea:focus {
    border-color: #2563eb;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, .1);
}

.bk-form-group input[readonly] {
    background: #f8fafc;
    font-weight: 600;
}

.bk-form-group small {
    color: #64748b;
    font-size: 12px;
}

.bk-span-2 {
    grid-column: span 2;
}

.bk-form-actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 25px;
    padding-top: 20px;
    border-top: 1px solid #edf1f5;
}

.bk-alert {
    padding: 13px 16px;
    border-radius: 9px;
    font-size: 14px;
}

.bk-alert-success {
    color: #166534;
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
}

.bk-alert-error {
    color: #991b1b;
    background: #fef2f2;
    border: 1px solid #fecaca;
}

@media (max-width: 900px) {
    .bk-summary-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 600px) {
    .bk-page {
        padding: 14px;
        gap: 16px;
    }

    .bk-page-header h1 {
        font-size: 23px;
    }

    .bk-summary-grid,
    .bk-form-grid {
        grid-template-columns: 1fr;
    }

    .bk-span-2 {
        grid-column: auto;
    }

    .bk-form {
        padding: 17px;
    }

    .bk-card-header {
        padding: 18px;
    }

    .bk-form-actions {
        flex-direction: column-reverse;
    }

    .bk-form-actions .bk-btn {
        width: 100%;
    }
}



/* =========================
   DASHBOARD INVENTARIS
========================= */
.dash-page {
    width: 100%;
    max-width: 1600px;
    min-width: 0;
    margin: 0 auto;
    padding: 24px;
    display: flex;
    flex-direction: column;
    gap: 24px;
    box-sizing: border-box;
}

.dash-page *,
.dash-page *::before,
.dash-page *::after {
    box-sizing: border-box;
}

.dash-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 18px;
}

.dash-header h1 {
    margin: 0;
    color: #172033;
    font-size: 28px;
    font-weight: 750;
}

.dash-header p {
    margin: 7px 0 0;
    color: #718096;
    font-size: 13px;
}

.dash-year-filter {
    display: flex;
    align-items: center;
    gap: 10px;
}

.dash-year-filter label {
    color: #64748b;
    font-size: 13px;
    font-weight: 600;
}

.dash-year-filter select {
    min-width: 110px;
    padding: 10px 12px;
    border: 1px solid #dbe3ed;
    border-radius: 9px;
    background: #fff;
    color: #1e293b;
    font: inherit;
}

.dash-summary-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 18px;
}

.dash-summary-card {
    display: flex;
    align-items: flex-start;
    gap: 15px;
    min-width: 0;
    padding: 22px;
    border: 1px solid #e7edf4;
    border-radius: 15px;
    background: #fff;
    box-shadow: 0 4px 18px rgba(15, 23, 42, .04);
}

.dash-summary-icon {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-shrink: 0;
    width: 48px;
    height: 48px;
    border-radius: 12px;
    font-size: 23px;
}

.dash-icon-blue {
    background: #eff6ff;
}

.dash-icon-purple {
    background: #f5f3ff;
}

.dash-icon-green {
    background: #ecfdf5;
}

.dash-icon-orange {
    background: #fff7ed;
}

.dash-summary-info {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.dash-summary-info span {
    color: #64748b;
    font-size: 12px;
    font-weight: 600;
}

.dash-summary-info strong {
    color: #172033;
    font-size: 21px;
    font-weight: 750;
    overflow-wrap: anywhere;
}

.dash-summary-info small {
    color: #94a3b8;
    font-size: 11px;
}

.dash-chart-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px;
}

.dash-chart-card {
    min-width: 0;
    padding: 22px;
    border: 1px solid #e7edf4;
    border-radius: 15px;
    background: #fff;
    box-shadow: 0 4px 18px rgba(15, 23, 42, .04);
}

.dash-chart-header {
    margin-bottom: 20px;
}

.dash-chart-header h2 {
    margin: 0;
    color: #172033;
    font-size: 17px;
    font-weight: 750;
}

.dash-chart-header p {
    margin: 7px 0 0;
    color: #718096;
    font-size: 12px;
}

.dash-chart-container {
    position: relative;
    width: 100%;
    height: 340px;
}

@media (max-width: 1250px) {
    .dash-summary-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .dash-chart-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 650px) {
    .dash-page {
        padding: 14px;
        gap: 16px;
    }

    .dash-header h1 {
        font-size: 23px;
    }

    .dash-summary-grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .dash-summary-card {
        padding: 17px;
    }

    .dash-summary-info strong {
        font-size: 19px;
    }

    .dash-chart-card {
        padding: 16px;
    }

    .dash-chart-container {
        height: 280px;
    }

    .dash-year-filter {
        width: 100%;
        justify-content: space-between;
    }
}




/* =========================================================
   MANAJEMEN USER
   Modern, Clean, Responsive Dashboard
========================================================= */

/* =========================
   GLOBAL
========================= */

.user-page,
.user-page *,
.user-modal-overlay,
.user-modal-overlay * {
    box-sizing: border-box;
}

.user-page {
    width: 100%;
    max-width: 1600px;
    min-width: 0;

    margin: 0 auto;
    padding: 28px;

    display: flex;
    flex-direction: column;
    gap: 24px;

    color: #1e293b;
    font-family: "Inter", "Segoe UI", Arial, sans-serif;
}

/* =========================
   HEADER
========================= */

.user-page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;

    padding: 0;
}

.user-page-header > div {
    min-width: 0;
}

.user-page-header h2 {
    margin: 0 0 7px;

    color: #0f172a;
    font-size: 27px;
    font-weight: 750;
    letter-spacing: -0.5px;
}

.user-page-header p {
    margin: 0;

    color: #64748b;
    font-size: 14px;
    line-height: 1.6;
}

/* =========================
   BUTTON TAMBAH USER
========================= */

.user-btn-tambah {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 9px;

    min-height: 44px;
    padding: 11px 19px;

    color: #ffffff;
    background: #2563eb;

    border: 1px solid #2563eb;
    border-radius: 10px;

    font-family: inherit;
    font-size: 13px;
    font-weight: 650;

    white-space: nowrap;
    cursor: pointer;

    box-shadow: 0 4px 10px rgba(37, 99, 235, 0.13);

    transition:
        background 0.2s ease,
        box-shadow 0.2s ease,
        transform 0.2s ease;
}

.user-btn-tambah:hover {
    background: #1d4ed8;
    border-color: #1d4ed8;

    box-shadow: 0 6px 15px rgba(37, 99, 235, 0.2);
    transform: translateY(-1px);
}

.user-btn-tambah:active {
    transform: scale(0.98);
}

/* =========================
   ALERT
========================= */

.user-alert {
    display: flex;
    align-items: center;
    gap: 11px;

    width: 100%;
    padding: 14px 17px;

    border-radius: 10px;

    font-size: 13px;
    font-weight: 550;
    line-height: 1.6;
}

.user-alert i {
    font-size: 17px;
    flex-shrink: 0;
}

.user-alert-success {
    color: #166534;
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
}

.user-alert-error {
    color: #991b1b;
    background: #fff1f2;
    border: 1px solid #fecdd3;
}

/* =========================
   STATISTIK
========================= */

.user-stat-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
}

.user-stat-card {
    display: flex;
    align-items: center;
    gap: 17px;

    min-width: 0;
    padding: 22px;

    background: #ffffff;

    border: 1px solid #e8edf4;
    border-radius: 14px;

    box-shadow: 0 3px 12px rgba(15, 23, 42, 0.035);

    transition:
        box-shadow 0.2s ease,
        transform 0.2s ease;
}

.user-stat-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 22px rgba(15, 23, 42, 0.06);
}

.user-stat-icon {
    width: 50px;
    height: 50px;

    display: flex;
    align-items: center;
    justify-content: center;

    flex-shrink: 0;

    color: #2563eb;
    background: #eff6ff;

    border-radius: 13px;

    font-size: 22px;
}

.user-stat-card > div:last-child {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.user-stat-card span {
    color: #64748b;
    font-size: 12px;
    font-weight: 550;
}

.user-stat-card h3 {
    margin: 0;

    color: #0f172a;
    font-size: 26px;
    font-weight: 750;
    line-height: 1.2;
}

/* =========================
   USER CARD
========================= */

.user-card {
    width: 100%;
    min-width: 0;

    background: #ffffff;

    border: 1px solid #e8edf4;
    border-radius: 14px;

    overflow: hidden;

    box-shadow: 0 3px 12px rgba(15, 23, 42, 0.035);
}

/* =========================
   USER CARD HEADER
========================= */

.user-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;

    padding: 22px 24px;

    border-bottom: 1px solid #edf1f6;
}

.user-card-header > div {
    min-width: 0;
}

.user-card-header h3 {
    margin: 0;

    color: #0f172a;
    font-size: 17px;
    font-weight: 750;
}

.user-card-header p {
    margin: 6px 0 0;

    color: #64748b;
    font-size: 12px;
    line-height: 1.6;
}

.user-total {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    min-height: 30px;
    padding: 6px 12px;

    color: #1d4ed8;
    background: #eff6ff;

    border: 1px solid #dbeafe;
    border-radius: 8px;

    font-size: 12px;
    font-weight: 700;

    white-space: nowrap;
}

/* =========================
   TABLE WRAPPER
========================= */

.user-table-wrapper {
    width: 100%;
    overflow-x: auto;
}

/* =========================
   TABLE
========================= */

.user-table {
    width: 100%;
    min-width: 950px;

    border-collapse: separate;
    border-spacing: 0;
}

.user-table thead {
    background: #f8fafc;
}

.user-table thead th {
    padding: 15px 20px;

    color: #64748b;

    font-size: 11px;
    font-weight: 750;
    text-transform: uppercase;
    letter-spacing: 0.045em;

    text-align: left;
    white-space: nowrap;

    border-bottom: 1px solid #e8edf4;
}

.user-table tbody td {
    padding: 16px 20px;

    color: #334155;
    font-size: 13px;

    vertical-align: middle;

    border-bottom: 1px solid #f0f3f8;
}

.user-table tbody tr {
    transition: background 0.15s ease;
}

.user-table tbody tr:hover {
    background: #f8fbff;
}

.user-table tbody tr:last-child td {
    border-bottom: none;
}

/* Kolom nomor */

.user-table th:first-child,
.user-table td:first-child {
    width: 55px;
    text-align: center;
}

/* Kolom aksi */

.user-table th:last-child {
    min-width: 220px;
}

.user-table td:last-child {
    min-width: 220px;
}

/* =========================
   ROLE BADGE
========================= */

.user-role {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;

    min-height: 28px;
    padding: 6px 11px;

    border-radius: 7px;

    font-size: 11px;
    font-weight: 700;

    white-space: nowrap;
}

.user-role-admin {
    color: #6d28d9;
    background: #f3e8ff;

    border: 1px solid #e9d5ff;
}

.user-role-user {
    color: #1d4ed8;
    background: #eff6ff;

    border: 1px solid #dbeafe;
}

/* =========================
   STATUS BADGE
========================= */

.user-status {
    display: inline-flex;
    align-items: center;
    gap: 7px;

    min-height: 27px;
    padding: 6px 11px;

    border-radius: 7px;

    font-size: 11px;
    font-weight: 700;

    white-space: nowrap;
}

.user-status::before {
    content: "";

    width: 6px;
    height: 6px;

    flex-shrink: 0;

    border-radius: 50%;
    background: currentColor;
}

.user-status-active {
    color: #15803d;
    background: #f0fdf4;

    border: 1px solid #dcfce7;
}

.user-status-inactive {
    color: #b91c1c;
    background: #fff1f2;

    border: 1px solid #ffe4e6;
}

/* =========================
   ACTION BUTTONS
========================= */

.user-action-buttons {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.user-action-buttons form {
    display: inline-flex;
    margin: 0;
}

/* Edit */

.user-btn-edit {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;

    min-height: 33px;
    padding: 7px 12px;

    color: #1d4ed8;
    background: #eff6ff;

    border: 1px solid #dbeafe;
    border-radius: 7px;

    font-family: inherit;
    font-size: 12px;
    font-weight: 650;

    cursor: pointer;

    transition: all 0.2s ease;
}

.user-btn-edit:hover {
    color: #ffffff;
    background: #2563eb;
    border-color: #2563eb;
}

/* Nonaktifkan */

.user-btn-nonaktif {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;

    min-height: 33px;
    padding: 7px 12px;

    color: #b91c1c;
    background: #fff1f2;

    border: 1px solid #fecdd3;
    border-radius: 7px;

    font-family: inherit;
    font-size: 12px;
    font-weight: 650;

    cursor: pointer;

    transition: all 0.2s ease;
}

.user-btn-nonaktif:hover:not(:disabled) {
    color: #ffffff;
    background: #dc2626;
    border-color: #dc2626;
}

/* Aktifkan */

.user-btn-aktif {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;

    min-height: 33px;
    padding: 7px 12px;

    color: #166534;
    background: #f0fdf4;

    border: 1px solid #bbf7d0;
    border-radius: 7px;

    font-family: inherit;
    font-size: 12px;
    font-weight: 650;

    cursor: pointer;

    transition: all 0.2s ease;
}

.user-btn-aktif:hover {
    color: #ffffff;
    background: #16a34a;
    border-color: #16a34a;
}

/* Disabled */

.user-btn-nonaktif:disabled {
    opacity: 0.45;
    cursor: not-allowed;
}

/* =========================
   MODAL OVERLAY
========================= */

.user-modal-overlay {
    position: fixed;
    inset: 0;

    z-index: 99999;

    display: none;
    align-items: center;
    justify-content: center;

    padding: 20px;

    background: rgba(15, 23, 42, 0.55);

    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
}

.user-modal-overlay.active {
    display: flex;
}

/* Hindari halaman belakang ikut scroll */

body.user-modal-open {
    overflow: hidden;
}

/* =========================
   MODAL
========================= */

.user-modal {
    position: relative;

    width: 100%;
    max-width: 500px;
    max-height: calc(100vh - 40px);

    display: flex;
    flex-direction: column;

    overflow-y: auto;

    background: #ffffff;

    border: 1px solid rgba(226, 232, 240, 0.9);
    border-radius: 16px;

    box-shadow: 0 25px 80px rgba(15, 23, 42, 0.25);

    animation: userModalShow 0.2s ease-out;
}

@keyframes userModalShow {
    from {
        opacity: 0;
        transform: translateY(12px) scale(0.98);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

/* =========================
   MODAL HEADER
========================= */

.user-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 16px;

    padding: 23px 25px;

    background: #ffffff;
    border-bottom: 1px solid #edf1f6;
}

.user-modal-heading {
    display: flex;
    align-items: center;
    gap: 13px;

    min-width: 0;
}

.user-modal-icon {
    width: 43px;
    height: 43px;

    display: flex;
    align-items: center;
    justify-content: center;

    flex-shrink: 0;

    color: #2563eb;
    background: #eff6ff;

    border: 1px solid #dbeafe;
    border-radius: 11px;

    font-size: 17px;
}

.user-modal-heading > div:last-child {
    min-width: 0;
}

.user-modal-header h3 {
    margin: 0;

    color: #0f172a;
    font-size: 18px;
    font-weight: 750;
}

.user-modal-header p {
    margin: 5px 0 0;

    color: #64748b;
    font-size: 12px;
    line-height: 1.6;
}

/* Close button */

.user-modal-close {
    width: 34px;
    height: 34px;

    display: flex;
    align-items: center;
    justify-content: center;

    flex-shrink: 0;

    color: #64748b;
    background: #f1f5f9;

    border: none;
    border-radius: 8px;

    font-size: 23px;
    line-height: 1;

    cursor: pointer;

    transition: all 0.2s ease;
}

.user-modal-close:hover {
    color: #dc2626;
    background: #fee2e2;
}

/* =========================
   MODAL BODY
========================= */

.user-modal-body {
    padding: 24px 25px;

    display: flex;
    flex-direction: column;
    gap: 18px;
}

/* =========================
   FORM GROUP
========================= */

.user-form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.user-form-group label {
    color: #334155;
    font-size: 12px;
    font-weight: 700;
}

.user-form-group input,
.user-form-group select {
    width: 100%;
    min-height: 44px;

    padding: 11px 13px;

    color: #0f172a;
    background: #ffffff;

    border: 1px solid #cbd5e1;
    border-radius: 8px;

    outline: none;

    font-family: inherit;
    font-size: 13px;

    transition:
        border-color 0.2s ease,
        box-shadow 0.2s ease;
}

.user-form-group input:hover,
.user-form-group select:hover {
    border-color: #94a3b8;
}

.user-form-group input:focus,
.user-form-group select:focus {
    border-color: #2563eb;

    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.11);
}

.user-form-group input::placeholder {
    color: #94a3b8;
}

/* =========================
   FORM INFO
========================= */

.user-form-info {
    display: flex;
    align-items: flex-start;
    gap: 9px;

    padding: 12px 13px;

    color: #1d4ed8;
    background: #eff6ff;

    border: 1px solid #dbeafe;
    border-radius: 8px;

    font-size: 11px;
    line-height: 1.6;
}

.user-form-info i {
    margin-top: 2px;
    flex-shrink: 0;
}

/* =========================
   MODAL FOOTER
========================= */

.user-modal-footer {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 10px;

    padding: 18px 25px 23px;

    background: #ffffff;
    border-top: 1px solid #edf1f6;
}

/* Batal */

.user-btn-batal {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    min-height: 42px;
    min-width: 100px;

    padding: 10px 16px;

    color: #475569;
    background: #ffffff;

    border: 1px solid #cbd5e1;
    border-radius: 8px;

    font-family: inherit;
    font-size: 12px;
    font-weight: 650;

    cursor: pointer;

    transition: all 0.2s ease;
}

.user-btn-batal:hover {
    color: #1e293b;
    background: #f8fafc;
    border-color: #94a3b8;
}

/* Simpan */

.user-btn-simpan {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;

    min-height: 42px;
    min-width: 145px;

    padding: 10px 17px;

    color: #ffffff;
    background: #2563eb;

    border: 1px solid #2563eb;
    border-radius: 8px;

    font-family: inherit;
    font-size: 12px;
    font-weight: 700;

    cursor: pointer;

    transition: all 0.2s ease;
}

.user-btn-simpan:hover {
    background: #1d4ed8;
    border-color: #1d4ed8;
    box-shadow: 0 4px 10px rgba(37, 99, 235, 0.15);
}

/* =========================
   EMPTY STATE
========================= */

.user-empty {
    padding: 45px 20px !important;

    color: #94a3b8 !important;

    text-align: center;
    font-size: 13px !important;
}

/* =========================
   RESPONSIVE TABLET
========================= */

@media (max-width: 1024px) {
    .user-page {
        padding: 22px;
        gap: 20px;
    }

    .user-stat-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

/* =========================
   RESPONSIVE MOBILE
========================= */

@media (max-width: 600px) {
    .user-page {
        padding: 14px;
        gap: 16px;
    }

    .user-page-header {
        align-items: stretch;
        flex-direction: column;
    }

    .user-page-header h2 {
        font-size: 22px;
    }

    .user-page-header p {
        font-size: 12px;
    }

    .user-btn-tambah {
        width: 100%;
    }

    .user-stat-grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .user-stat-card {
        padding: 17px;
    }

    .user-card-header {
        padding: 17px;
    }

    .user-card-header h3 {
        font-size: 15px;
    }

    .user-card-header p {
        font-size: 11px;
    }

    .user-modal-overlay {
        padding: 10px;
    }

    .user-modal {
        max-height: calc(100vh - 20px);
        border-radius: 13px;
    }

    .user-modal-header {
        padding: 18px;
    }

    .user-modal-header h3 {
        font-size: 16px;
    }

    .user-modal-body {
        padding: 18px;
        gap: 16px;
    }

    .user-modal-footer {
        padding: 16px 18px 18px;
        flex-direction: column-reverse;
    }

    .user-modal-footer button {
        width: 100%;
    }

    .user-action-buttons {
        flex-direction: column;
        align-items: stretch;
    }

    .user-action-buttons button {
        width: 100%;
    }
}

/* =========================
   REDUCE MOTION
========================= */

@media (prefers-reduced-motion: reduce) {
    .user-page *,
    .user-modal-overlay * {
        animation: none !important;
        transition: none !important;
    }
}



/* =========================================================
   USER PAGE
========================================================= */

.user-page,
.user-page * {
    box-sizing: border-box;
}

.user-page {
    width: 100%;
    max-width: 1600px;
    min-width: 0;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 24px;
    color: #1e293b;
    font-family: Arial, Helvetica, sans-serif;
}


/* =========================================================
   HEADER
========================================================= */

.user-page-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    flex-wrap: wrap;
}

.user-page-title {
    display: flex;
    align-items: center;
    gap: 15px;
}

.user-page-title-icon {
    width: 54px;
    height: 54px;
    border-radius: 16px;
    background: #eaf2ff;
    color: #2563eb;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 23px;
    flex-shrink: 0;
}

.user-page-title h1 {
    margin: 0;
    font-size: 25px;
    font-weight: 800;
    color: #0f172a;
}

.user-page-title p {
    margin: 6px 0 0;
    color: #64748b;
    font-size: 14px;
}


/* =========================================================
   BUTTON TAMBAH
========================================================= */

.user-btn-tambah {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    padding: 12px 18px;
    border: none;
    border-radius: 11px;
    background: #2563eb;
    color: #ffffff;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    transition: 0.2s ease;
    text-decoration: none;
}

.user-btn-tambah:hover {
    background: #1d4ed8;
    transform: translateY(-1px);
    box-shadow: 0 7px 18px rgba(37, 99, 235, 0.18);
}


/* =========================================================
   ALERT
========================================================= */

.user-alert {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 17px;
    border-radius: 12px;
    font-size: 14px;
    line-height: 1.5;
}

.user-alert-success {
    color: #166534;
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
}

.user-alert-error {
    color: #991b1b;
    background: #fef2f2;
    border: 1px solid #fecaca;
}

.user-alert i {
    font-size: 18px;
    flex-shrink: 0;
}


/* =========================================================
   STATISTIK
========================================================= */

.user-stat-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
}

.user-stat-card {
    min-width: 0;
    display: flex;
    align-items: center;
    gap: 17px;
    padding: 23px;
    border-radius: 16px;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    box-shadow: 0 4px 15px rgba(15, 23, 42, 0.035);
}

.user-stat-icon {
    width: 52px;
    height: 52px;
    border-radius: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 21px;
    flex-shrink: 0;
}

.user-stat-icon-total {
    background: #eff6ff;
    color: #2563eb;
}

.user-stat-icon-active {
    background: #ecfdf5;
    color: #059669;
}

.user-stat-icon-inactive {
    background: #fff7ed;
    color: #ea580c;
}

.user-stat-content {
    min-width: 0;
}

.user-stat-content span {
    display: block;
    color: #64748b;
    font-size: 13px;
    font-weight: 600;
}

.user-stat-content h3 {
    margin: 5px 0;
    color: #0f172a;
    font-size: 28px;
    font-weight: 800;
}

.user-stat-content small {
    display: block;
    color: #94a3b8;
    font-size: 12px;
}


/* =========================================================
   CARD TABEL
========================================================= */

.user-card {
    width: 100%;
    min-width: 0;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(15, 23, 42, 0.035);
}

.user-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    padding: 23px 25px;
    border-bottom: 1px solid #e2e8f0;
}

.user-card-header h2 {
    margin: 0;
    font-size: 18px;
    font-weight: 800;
    color: #0f172a;
}

.user-card-header p {
    margin: 6px 0 0;
    color: #64748b;
    font-size: 13px;
}

.user-total {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 9px 13px;
    border-radius: 10px;
    background: #eff6ff;
    color: #2563eb;
    font-size: 13px;
    font-weight: 700;
    white-space: nowrap;
}


/* =========================================================
   TOOLBAR
========================================================= */

.user-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 15px;
    flex-wrap: wrap;
    padding: 18px 25px;
    border-bottom: 1px solid #e2e8f0;
}

.user-search-box {
    width: 100%;
    max-width: 360px;
    position: relative;
}

.user-search-box i {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: #94a3b8;
    font-size: 14px;
}

.user-search-box input {
    width: 100%;
    height: 42px;
    padding: 0 15px 0 40px;
    border: 1px solid #cbd5e1;
    border-radius: 10px;
    outline: none;
    background: #ffffff;
    color: #1e293b;
    font-size: 13px;
    transition: 0.2s;
}

.user-search-box input:focus {
    border-color: #2563eb;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.09);
}

.user-filter-box {
    display: flex;
    align-items: center;
    gap: 10px;
}

.user-filter-box select {
    min-width: 130px;
    height: 42px;
    padding: 0 12px;
    border: 1px solid #cbd5e1;
    border-radius: 10px;
    outline: none;
    background: #ffffff;
    color: #334155;
    font-size: 13px;
    cursor: pointer;
}

.user-filter-box select:focus {
    border-color: #2563eb;
}


/* =========================================================
   TABLE
========================================================= */

.user-table-wrapper {
    width: 100%;
    overflow-x: auto;
}

.user-table {
    width: 100%;
    border-collapse: collapse;
    white-space: nowrap;
}

.user-table thead {
    background: #f8fafc;
}

.user-table th {
    padding: 15px 17px;
    text-align: left;
    color: #64748b;
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-bottom: 1px solid #e2e8f0;
}

.user-table td {
    padding: 15px 17px;
    border-bottom: 1px solid #f1f5f9;
    color: #334155;
    font-size: 13px;
    vertical-align: middle;
}

.user-table tbody tr {
    transition: background 0.15s ease;
}

.user-table tbody tr:hover {
    background: #f8fafc;
}

.user-table tbody tr:last-child td {
    border-bottom: none;
}

.user-col-number {
    width: 55px;
}

.user-col-action {
    width: 120px;
    text-align: center !important;
}

.user-number {
    color: #94a3b8;
    font-size: 12px;
    font-weight: 700;
}


/* =========================================================
   NAMA USER
========================================================= */

.user-name-cell {
    display: flex;
    align-items: center;
    gap: 12px;
}

.user-avatar {
    width: 39px;
    height: 39px;
    border-radius: 12px;
    background: #eaf2ff;
    color: #2563eb;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 15px;
    font-weight: 800;
    flex-shrink: 0;
}

.user-name-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.user-name-info strong {
    color: #1e293b;
    font-size: 13px;
    font-weight: 700;
}

.user-name-info small {
    color: #94a3b8;
    font-size: 11px;
}

.user-username {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: #64748b;
    font-size: 12px;
}

.user-username i {
    color: #94a3b8;
}


/* =========================================================
   ROLE
========================================================= */

.user-role {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 10px;
    border-radius: 8px;
    font-size: 11px;
    font-weight: 700;
}

.user-role-admin {
    background: #f3e8ff;
    color: #7e22ce;
}

.user-role-user {
    background: #eff6ff;
    color: #2563eb;
}


/* =========================================================
   STATUS
========================================================= */

.user-status {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 6px 10px;
    border-radius: 8px;
    font-size: 11px;
    font-weight: 700;
}

.user-status-active {
    background: #ecfdf5;
    color: #047857;
}

.user-status-inactive {
    background: #fef2f2;
    color: #b91c1c;
}

.user-status-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: currentColor;
}

.user-date {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    color: #64748b;
    font-size: 12px;
}

.user-date i {
    color: #94a3b8;
}


/* =========================================================
   ACTION BUTTON
========================================================= */

.user-action-buttons {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
}

.user-action-buttons form {
    display: inline-flex;
    margin: 0;
}

.user-btn-edit,
.user-btn-nonaktif,
.user-btn-aktif {
    width: 34px;
    height: 34px;
    border: 1px solid transparent;
    border-radius: 9px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    cursor: pointer;
    transition: 0.2s ease;
}

.user-btn-edit {
    background: #eff6ff;
    border-color: #dbeafe;
    color: #2563eb;
}

.user-btn-edit:hover {
    background: #2563eb;
    color: #ffffff;
}

.user-btn-nonaktif {
    background: #fff7ed;
    border-color: #fed7aa;
    color: #ea580c;
}

.user-btn-nonaktif:hover {
    background: #ea580c;
    color: #ffffff;
}

.user-btn-aktif {
    background: #ecfdf5;
    border-color: #a7f3d0;
    color: #059669;
}

.user-btn-aktif:hover {
    background: #059669;
    color: #ffffff;
}


/* =========================================================
   EMPTY STATE
========================================================= */

.user-empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 55px 20px;
    text-align: center;
}

.user-empty-icon {
    width: 65px;
    height: 65px;
    margin-bottom: 15px;
    border-radius: 18px;
    background: #eff6ff;
    color: #2563eb;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 25px;
}

.user-empty-state h3 {
    margin: 0;
    color: #1e293b;
    font-size: 17px;
}

.user-empty-state p {
    margin: 8px 0 20px;
    color: #64748b;
    font-size: 13px;
}

.user-search-empty {
    display: none;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 30px;
    color: #94a3b8;
    font-size: 13px;
}

.user-search-empty i {
    font-size: 25px;
}

.user-search-empty p {
    margin: 0;
}


/* =========================================================
   MODAL OVERLAY
========================================================= */

.user-modal-overlay {
    position: fixed;
    inset: 0;
    z-index: 9999;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background: rgba(15, 23, 42, 0.55);
    backdrop-filter: blur(4px);
    overflow-y: auto;
}

.user-modal-overlay.active {
    display: flex;
}

body.user-modal-open {
    overflow: hidden;
}


/* =========================================================
   MODAL
========================================================= */

.user-modal {
    width: 100%;
    max-width: 520px;
    max-height: calc(100vh - 40px);
    background: #ffffff;
    border-radius: 18px;
    overflow-y: auto;
    box-shadow: 0 25px 70px rgba(15, 23, 42, 0.25);
    animation: userModalIn 0.2s ease;
}

@keyframes userModalIn {
    from {
        opacity: 0;
        transform: translateY(12px) scale(0.98);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}


/* =========================================================
   MODAL HEADER
========================================================= */

.user-modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 15px;
    padding: 23px 25px;
    border-bottom: 1px solid #e2e8f0;
}

.user-modal-heading {
    display: flex;
    align-items: center;
    gap: 13px;
}

.user-modal-heading h2 {
    margin: 0;
    color: #0f172a;
    font-size: 18px;
    font-weight: 800;
}

.user-modal-heading p {
    margin: 5px 0 0;
    color: #64748b;
    font-size: 12px;
}

.user-modal-icon {
    width: 45px;
    height: 45px;
    border-radius: 13px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    flex-shrink: 0;
}

.user-modal-icon-add {
    background: #eff6ff;
    color: #2563eb;
}

.user-modal-icon-edit {
    background: #f3e8ff;
    color: #9333ea;
}

.user-modal-close {
    width: 34px;
    height: 34px;
    border: none;
    border-radius: 9px;
    background: #f1f5f9;
    color: #64748b;
    font-size: 23px;
    line-height: 1;
    cursor: pointer;
    transition: 0.2s;
}

.user-modal-close:hover {
    background: #e2e8f0;
    color: #0f172a;
}


/* =========================================================
   MODAL BODY
========================================================= */

.user-modal-body {
    display: flex;
    flex-direction: column;
    gap: 18px;
    padding: 25px;
}

.user-form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.user-form-group label {
    color: #334155;
    font-size: 13px;
    font-weight: 700;
}

.user-form-group label span {
    color: #ef4444;
}

.user-form-group input,
.user-form-group select {
    width: 100%;
    height: 45px;
    padding: 0 13px;
    border: 1px solid #cbd5e1;
    border-radius: 10px;
    outline: none;
    background: #ffffff;
    color: #1e293b;
    font-size: 13px;
    transition: 0.2s;
}

.user-form-group input::placeholder {
    color: #94a3b8;
}

.user-form-group input:focus,
.user-form-group select:focus {
    border-color: #2563eb;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.09);
}

.user-form-help {
    display: block;
    color: #64748b;
    font-size: 11px;
    line-height: 1.5;
}


/* =========================================================
   MODAL FOOTER
========================================================= */

.user-modal-footer {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 10px;
    padding: 18px 25px;
    border-top: 1px solid #e2e8f0;
    background: #f8fafc;
}

.user-btn-batal,
.user-btn-simpan {
    min-height: 40px;
    padding: 0 17px;
    border-radius: 9px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    transition: 0.2s;
}

.user-btn-batal {
    background: #ffffff;
    border: 1px solid #cbd5e1;
    color: #475569;
}

.user-btn-batal:hover {
    background: #f1f5f9;
}

.user-btn-simpan {
    background: #2563eb;
    border: 1px solid #2563eb;
    color: #ffffff;
}

.user-btn-simpan:hover {
    background: #1d4ed8;
    border-color: #1d4ed8;
}


/* =========================================================
   RESPONSIVE TABLET
========================================================= */

@media (max-width: 1024px) {
    .user-stat-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .user-stat-card:last-child {
        grid-column: 1 / -1;
    }

    .user-table {
        min-width: 950px;
    }
}


/* =========================================================
   RESPONSIVE MOBILE
========================================================= */

@media (max-width: 768px) {
    .user-page {
        gap: 18px;
    }

    .user-page-header {
        align-items: flex-start;
    }

    .user-page-title {
        gap: 11px;
    }

    .user-page-title-icon {
        width: 45px;
        height: 45px;
        border-radius: 12px;
        font-size: 19px;
    }

    .user-page-title h1 {
        font-size: 20px;
    }

    .user-page-title p {
        font-size: 12px;
    }

    .user-btn-tambah {
        width: 100%;
    }

    .user-stat-grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .user-stat-card:last-child {
        grid-column: auto;
    }

    .user-stat-card {
        padding: 17px;
    }

    .user-stat-content h3 {
        font-size: 24px;
    }

    .user-card-header {
        padding: 18px;
        align-items: flex-start;
    }

    .user-card-header h2 {
        font-size: 16px;
    }

    .user-card-header p {
        font-size: 12px;
    }

    .user-toolbar {
        padding: 15px;
    }

    .user-search-box {
        max-width: none;
    }

    .user-filter-box {
        width: 100%;
    }

    .user-filter-box select {
        width: 50%;
        min-width: 0;
    }

    .user-modal-overlay {
        padding: 12px;
        align-items: center;
    }

    .user-modal {
        max-height: calc(100vh - 24px);
        border-radius: 14px;
    }

    .user-modal-header {
        padding: 18px;
    }

    .user-modal-body {
        padding: 18px;
        gap: 15px;
    }

    .user-modal-footer {
        padding: 15px 18px;
    }
}


/* =========================================================
   RESPONSIVE SMALL MOBILE
========================================================= */

@media (max-width: 420px) {
    .user-page-title h1 {
        font-size: 18px;
    }

    .user-page-title p {
        max-width: 220px;
        line-height: 1.5;
    }

    .user-card-header {
        flex-direction: column;
    }

    .user-total {
        align-self: flex-start;
    }

    .user-modal-heading h2 {
        font-size: 16px;
    }

    .user-modal-heading p {
        font-size: 11px;
    }

    .user-modal-footer {
        flex-direction: column-reverse;
    }

    .user-btn-batal,
    .user-btn-simpan {
        width: 100%;
    }
}

