:root {
    --mbk-red: #bf1e2e;
    --mbk-red-deep: #9f1725;
    --mbk-ink: #231f20;
    --mbk-ink-soft: #3a3436;
    --mbk-mist: #f5f5f6;
    --mbk-paper: #ffffff;
    --mbk-line: #ded7da;
    --mbk-success: #1f7a4d;
    --mbk-warn: #c87900;
    --mbk-danger: #a3131f;
    --radius-lg: 18px;
    --radius-md: 12px;
    --shadow-soft: 0 12px 28px rgba(35, 31, 32, 0.12);
    --app-topbar-height: 92px;
}

.system-update-grid-single {
    grid-template-columns: minmax(0, 1fr);
}

.vehicle-card-print-page {
    min-height: 100vh;
    display: grid;
    place-items: center;
    padding: 14mm;
    background: #f4f4f4;
}

.vehicle-print-card {
    width: 148mm;
    min-height: 105mm;
    background: #fff;
    border: 1.4px solid #111;
    color: #000;
    font-family: Arial, sans-serif;
    overflow: hidden;
    box-sizing: border-box;
}

.vehicle-print-header {
    text-align: center;
    padding: 7mm 6mm 5mm;
    border-bottom: 1.2px solid #111;
}

.vehicle-print-header h1,
.vehicle-print-header h2 {
    margin: 0;
    font-weight: 900;
    letter-spacing: 0.02em;
}

.vehicle-print-header h1 {
    font-size: 18pt;
}

.vehicle-print-header h2 {
    margin-top: 3mm;
    color: #60656b;
    font-size: 15pt;
}

.vehicle-print-row {
    border-bottom: 1.2px solid #111;
    text-align: center;
}

.vehicle-print-row strong,
.vehicle-print-row span {
    display: block;
}

.vehicle-print-row strong {
    background: #d8d8d8;
    padding: 1.4mm 2mm;
    font-size: 11pt;
    line-height: 1.1;
}

.vehicle-print-row span {
    padding: 3mm 4mm;
    min-height: 11mm;
    font-size: 13pt;
    line-height: 1.15;
}

.vehicle-print-footer {
    display: grid;
    grid-template-columns: 28mm minmax(0, 1fr) 36mm;
    align-items: center;
    gap: 4mm;
    min-height: 20mm;
    padding: 2.5mm 4mm;
}

.vehicle-print-logo img {
    max-width: 27mm;
    max-height: 14mm;
    object-fit: contain;
}

.vehicle-print-logo strong {
    display: inline-block;
    font-size: 12pt;
    font-weight: 900;
}

.vehicle-print-company {
    text-align: center;
    line-height: 1.25;
}

.vehicle-print-company strong,
.vehicle-print-company span,
.vehicle-print-company small {
    display: block;
}

.vehicle-print-company strong {
    font-style: italic;
    font-size: 10.5pt;
}

.vehicle-print-company span {
    margin-top: 1.5mm;
    font-size: 9.2pt;
}

.vehicle-print-company small {
    margin-top: 1mm;
    font-size: 8.2pt;
}

.vehicle-print-plate {
    border: 1.2px solid #111;
    border-radius: 5px;
    padding: 2mm;
    text-align: center;
    font-size: 12pt;
    font-weight: 900;
}

.leave-scope-card {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 0.75rem;
}

.leave-scope-option {
    display: flex;
    gap: 0.7rem;
    align-items: flex-start;
    border: 1px solid #eadfe2;
    border-radius: 16px;
    background: #fff;
    padding: 0.85rem;
    cursor: pointer;
}

.leave-scope-option strong,
.leave-scope-option small {
    display: block;
}

.leave-scope-option small {
    margin-top: 0.18rem;
    color: #70676a;
}

@page vehicle-card-page {
    size: A6 landscape;
    margin: 0;
}

@media print {
    body.print-body .vehicle-card-print-page {
        width: 148mm !important;
        min-height: 105mm !important;
        padding: 0 !important;
        display: block !important;
        page: vehicle-card-page;
        background: #fff !important;
    }

    body.print-body .vehicle-print-card {
        width: 148mm !important;
        min-height: 105mm !important;
        margin: 0 !important;
        box-shadow: none !important;
    }
}

* {
    box-sizing: border-box;
}

html {
    font-size: 14.5px;
}

body {
    font-family: "Sora", sans-serif;
    color: var(--mbk-ink);
    background: radial-gradient(circle at 15% 20%, #fff2f4 0, #ffffff 45%, #f6f7f8 100%);
}

.auth-body {
    min-height: 100vh;
    display: grid;
    place-items: center;
    padding: 2rem 1rem;
}

.auth-container {
    width: min(100%, 580px);
}

.auth-container.install-shell {
    width: min(100%, 1120px);
}

.auth-card {
    background: var(--mbk-paper);
    border: 1px solid var(--mbk-line);
    border-radius: var(--radius-lg);
    padding: 2rem;
}

.install-shell .auth-card {
    padding: 0;
    overflow: hidden;
    border-radius: 22px;
    border-color: #eadfe2;
    box-shadow: 0 26px 70px rgba(191, 30, 46, 0.12);
}

.auth-body.install-shell {
    background: #fff;
}

.install-wizard {
    display: grid;
    grid-template-columns: 350px 1fr;
    min-height: 640px;
    background: #fff;
}

.install-side {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 1.2rem;
    padding: 1.5rem;
    background: #fff;
    color: var(--mbk-ink);
    border-right: 1px solid #eadfe2;
}

.install-side::before {
    content: "";
    position: absolute;
    inset: 0 auto 0 0;
    width: 5px;
    background: linear-gradient(180deg, var(--mbk-red), #f3a0aa);
}

.install-brand {
    position: relative;
    background: #fff;
    border-radius: 16px;
    padding: 0.85rem;
    border: 1px solid #eadfe2;
    box-shadow: 0 12px 30px rgba(35, 31, 32, 0.07);
}

.install-brand img {
    width: 100%;
    max-height: 64px;
    object-fit: contain;
}

.install-side-copy span {
    display: block;
    color: var(--mbk-red);
    font-size: 0.8rem;
    margin-bottom: 0.35rem;
    font-weight: 800;
    letter-spacing: 0.04em;
}

.install-side-copy h2 {
    font-size: 1.35rem;
    margin: 0 0 0.5rem;
    font-weight: 800;
    color: var(--mbk-ink);
}

.install-side-copy p {
    margin: 0;
    color: #63595c;
    font-size: 0.9rem;
    line-height: 1.55;
}

.install-steps {
    display: grid;
    gap: 0.7rem;
}

.install-step {
    display: flex;
    align-items: center;
    gap: 0.7rem;
    padding: 0.85rem;
    border-radius: 14px;
    background: #fff;
    border: 1px solid #eadfe2;
    box-shadow: 0 8px 22px rgba(35, 31, 32, 0.05);
}

.install-step b {
    display: grid;
    place-items: center;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: #fff0f2;
    color: var(--mbk-red);
    font-size: 0.8rem;
}

.install-step.active b {
    background: var(--mbk-red);
    color: #fff;
}

.install-step span {
    font-size: 0.88rem;
    color: var(--mbk-ink);
    font-weight: 700;
}

.install-support {
    margin-top: auto;
    display: grid;
    gap: 0.2rem;
    color: #63595c;
    font-size: 0.82rem;
    background: #fff;
    border: 1px solid #eadfe2;
    border-radius: 14px;
    padding: 0.9rem;
}

.install-support strong {
    color: var(--mbk-red);
}

.install-main {
    padding: 1.6rem;
    background: #fff;
}

.install-header {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    align-items: flex-start;
    padding-bottom: 1rem;
    margin-bottom: 1rem;
    border-bottom: 1px solid #eadfe2;
}

.install-header h1 {
    margin: 0 0 0.25rem;
    font-size: 1.35rem;
    font-weight: 800;
}

.install-header p {
    margin: 0;
    color: #625d5f;
    font-size: 0.88rem;
}

.install-check-score {
    min-width: 104px;
    text-align: right;
}

.install-check-score strong {
    display: block;
    font-size: 1.25rem;
    color: var(--mbk-red);
}

.install-check-score span {
    display: block;
    color: #6c6668;
    font-size: 0.78rem;
}

.install-check-list {
    display: grid;
    gap: 0.25rem;
    font-size: 0.86rem;
}

.install-section-title {
    font-weight: 800;
    color: var(--mbk-ink);
    margin-bottom: 0.8rem;
}

.btn-install-test {
    --bs-btn-color: var(--mbk-red);
    --bs-btn-border-color: #e5b8be;
    --bs-btn-bg: #fff;
    --bs-btn-hover-color: #fff;
    --bs-btn-hover-bg: var(--mbk-red);
    --bs-btn-hover-border-color: var(--mbk-red);
    --bs-btn-active-color: #fff;
    --bs-btn-active-bg: var(--mbk-red-deep);
    --bs-btn-active-border-color: var(--mbk-red-deep);
    font-weight: 700;
}

.install-actions {
    display: flex;
    justify-content: flex-end;
    margin-top: 1.25rem;
}

.auth-body.install-shell {
    align-items: start;
    place-items: start center;
    padding: 28px 1rem;
    background: radial-gradient(circle at 10% 20%, #fff2f4 0%, #f8fafc 35%, #eef2ff 100%);
    color: #0f172a;
    font-family: Calibri, "Segoe UI", Arial, sans-serif;
}

.auth-container.install-shell {
    width: min(100%, 1040px);
}

.install-shell .auth-card,
.install-shell .auth-card.shadow-lg {
    background: transparent;
    border: 0;
    border-radius: 0;
    box-shadow: none !important;
    overflow: visible;
    padding: 0;
}

.install-shell .alert {
    border-radius: 8px;
    margin: 0 auto 14px;
}

.setup-container {
    max-width: 1040px;
    margin: 0 auto;
    padding: 0 16px;
}

.setup-header {
    margin-bottom: 16px;
    text-align: center;
}

.setup-brand {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 10px;
}

.setup-brand-logo {
    display: block;
    width: auto;
    height: 56px;
    max-width: min(260px, 100%);
    object-fit: contain;
}

.setup-header h1 {
    margin: 0;
    color: #0f172a;
    font-family: Calibri, "Segoe UI", Arial, sans-serif;
    font-size: 30px;
    font-weight: 800;
    text-align: center;
}

.setup-header p {
    margin: 6px 0 0;
    color: #64748b;
    line-height: 1.45;
    text-align: center;
}

.setup-panel {
    background: #ffffff;
    border: 1px solid #dbe4ef;
    border-radius: 14px;
    padding: 20px;
    box-shadow: 0 8px 26px rgba(15, 23, 42, 0.06);
}

.setup-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
}

.setup-full {
    grid-column: 1 / -1;
}

.setup-field {
    display: flex;
    flex-direction: column;
}

.setup-container label {
    display: block;
    margin-bottom: 6px;
    color: #334155;
    font-size: 13px;
    font-weight: 700;
}

.setup-container input,
.setup-container select {
    width: 100%;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    background: #fff;
    color: #0f172a;
    font-family: Calibri, "Segoe UI", Arial, sans-serif;
    font-size: 14px;
    padding: 10px 12px;
}

.setup-container input:focus,
.setup-container select:focus {
    outline: none;
    border-color: var(--mbk-red);
    box-shadow: 0 0 0 3px rgba(191, 30, 46, 0.13);
}

.setup-section-title {
    margin: 18px 0 10px;
    color: #0f172a;
    font-size: 16px;
    font-weight: 800;
}

.setup-section-title:first-of-type {
    margin-top: 0;
}

.setup-error-box,
.setup-status-box,
.setup-progress-box {
    margin-bottom: 14px;
    border-radius: 8px;
    padding: 12px;
    font-size: 14px;
}

.setup-error-box {
    background: #fef2f2;
    border: 1px solid #fecaca;
    color: #b91c1c;
}

.setup-status-box {
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
    color: #166534;
}

.setup-progress-box {
    display: none;
    background: #fff7ed;
    border: 1px solid #fed7aa;
    color: #9a3412;
    font-weight: 700;
}

.setup-progress-box.show {
    display: block;
}

.setup-checks {
    border: 1px solid #dbe4ef;
    border-radius: 10px;
    overflow: hidden;
    margin-bottom: 14px;
}

.setup-check-row {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    padding: 10px 12px;
    background: #f8fafc;
    border-bottom: 1px solid #edf2f7;
    font-size: 13px;
}

.setup-check-row:last-child {
    border-bottom: 0;
}

.setup-check-ok {
    color: #166534;
    font-weight: 800;
}

.setup-check-fail {
    color: #b91c1c;
    font-weight: 800;
}

.setup-hint {
    color: #64748b;
    font-size: 12px;
    line-height: 1.45;
    margin-top: 4px;
}

.setup-field-error {
    min-height: 18px;
    margin-top: 4px;
    color: #b91c1c;
    font-size: 12px;
}

.setup-db-check-row {
    display: flex;
    justify-content: flex-end;
    margin-top: 4px;
}

.setup-actions {
    display: flex;
    justify-content: flex-end;
    margin-top: 18px;
}

.setup-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 0;
    border-radius: 8px;
    background: var(--mbk-red);
    color: #fff;
    cursor: pointer;
    font-family: Calibri, "Segoe UI", Arial, sans-serif;
    font-weight: 700;
    min-height: 40px;
    padding: 10px 16px;
    text-decoration: none;
}

.setup-button:hover {
    background: var(--mbk-red-deep);
    color: #fff;
}

.setup-button:disabled {
    cursor: not-allowed;
    opacity: 0.72;
}

.setup-secondary-button {
    background: #0f172a;
}

.setup-secondary-button:hover {
    background: #1e293b;
}

.setup-footer {
    margin-top: 16px;
    color: #475569;
    font-size: 13px;
    line-height: 1.6;
    text-align: center;
}

.setup-footer small {
    display: block;
    color: #64748b;
    font-size: 12px;
}

.setup-no-link {
    unicode-bidi: plaintext;
    white-space: nowrap;
}

.auth-logo {
    max-width: 340px;
    width: 100%;
    height: auto;
}

.btn-brand {
    --bs-btn-bg: var(--mbk-red);
    --bs-btn-border-color: var(--mbk-red);
    --bs-btn-hover-bg: var(--mbk-red-deep);
    --bs-btn-hover-border-color: var(--mbk-red-deep);
    --bs-btn-active-bg: var(--mbk-red-deep);
    --bs-btn-active-border-color: var(--mbk-red-deep);
    --bs-btn-color: #fff;
}

.app-shell {
    min-height: 100vh;
    display: grid;
    grid-template-columns: 280px 1fr;
}

.app-sidebar {
    background: linear-gradient(165deg, #171415 0%, #231f20 40%, #2d2728 100%);
    color: #fff;
    padding: 1.25rem;
    display: flex;
    flex-direction: column;
    border-right: 1px solid #302a2b;
}

.brand-block {
    padding: 0.25rem;
    border-radius: var(--radius-md);
    background: rgba(255, 255, 255, 0.06);
    margin-bottom: 1.25rem;
}

.brand-label {
    display: block;
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    margin: 0.2rem 0 0.35rem;
}

.brand-logo {
    width: 100%;
    max-height: 64px;
    object-fit: contain;
}

.company-logo-wrap {
    margin-top: 0.3rem;
}

.company-brand-logo {
    width: 100%;
    max-height: 52px;
    object-fit: contain;
    border-radius: 8px;
    background: #fff;
    padding: 0.25rem;
}

.company-brand-name {
    display: block;
    color: rgba(255, 255, 255, 0.86);
    margin-top: 0.35rem;
    font-size: 0.72rem;
}

.menu-nav {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.menu-link {
    color: #f6f5f5;
    text-decoration: none;
    padding: 0.7rem 0.8rem;
    border-radius: 10px;
    border: 1px solid transparent;
    transition: all 0.15s ease;
}

.menu-link:hover {
    background: rgba(191, 30, 46, 0.18);
    border-color: rgba(191, 30, 46, 0.36);
    color: #fff;
}

.app-main {
    display: grid;
    grid-template-rows: auto 1fr auto;
}

.app-topbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    min-height: var(--app-topbar-height);
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(5px);
    border-bottom: 1px solid var(--mbk-line);
    padding: 1rem 1.5rem;
}

.topbar-title {
    min-width: 160px;
}

.smart-search {
    position: relative;
    flex: 1 1 420px;
    max-width: 560px;
}

.smart-search .form-control {
    border-radius: 999px;
    border-color: #e2d8dc;
    background: #fff;
    padding-left: 1rem;
    min-height: 38px;
}

.smart-search-results {
    position: absolute;
    top: calc(100% + 0.45rem);
    left: 0;
    right: 0;
    z-index: 60;
    display: grid;
    gap: 0.35rem;
    border: 1px solid #eadfe2;
    border-radius: 18px;
    background: #fff;
    padding: 0.45rem;
    box-shadow: 0 18px 42px rgba(35, 31, 32, 0.14);
}

.smart-search-item {
    display: grid;
    gap: 0.1rem;
    width: 100%;
    border: 0;
    border-radius: 13px;
    background: transparent;
    padding: 0.65rem 0.75rem;
    text-align: left;
}

.smart-search-item:hover {
    background: #fff4f5;
}

.smart-search-item small {
    color: var(--mbk-red);
    font-size: 0.66rem;
    font-weight: 900;
}

.smart-search-item strong {
    color: var(--mbk-ink);
    font-size: 0.84rem;
}

.smart-search-item span {
    color: #756d70;
    font-size: 0.72rem;
}

.page-heading {
    font-size: 1.2rem;
    font-weight: 700;
}

.page-subtitle {
    color: #625d5f;
    font-size: 0.9rem;
}

.app-footer {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.35rem 0.85rem;
    border-top: 1px solid rgba(222, 215, 218, 0.72);
    background: rgba(255, 255, 255, 0.72);
    color: #756d70;
    padding: 0.38rem 0.8rem;
    font-size: 0.74rem;
    opacity: 0.82;
}

.app-footer span:first-child {
    color: var(--mbk-ink);
    font-weight: 700;
}

.app-footer span {
    pointer-events: none;
    color: inherit;
    text-decoration: none !important;
}

.app-footer .plain-contact,
.app-footer .plain-contact span {
    font-weight: 500 !important;
}

.auth-container > .app-footer {
    margin-top: 0.8rem;
    border: 0;
    background: transparent;
    text-align: center;
}

.user-chip {
    display: inline-flex;
    align-items: center;
    border-radius: 999px;
    border: 1px solid var(--mbk-line);
    background: #fff;
    padding: 0.45rem 0.8rem;
    margin-right: 0.5rem;
    font-size: 0.9rem;
}

.topbar-right {
    display: flex;
    align-items: center;
    gap: 0.45rem;
    flex-wrap: wrap;
}

.notification-bell {
    position: relative;
    width: 42px;
    height: 42px;
    display: grid;
    place-items: center;
    border: 1px solid var(--mbk-line);
    border-radius: 50%;
    background: #fff;
    color: var(--mbk-ink);
}

.notification-bell svg {
    width: 22px;
    height: 22px;
    fill: currentColor;
}

.notification-bell span {
    position: absolute;
    top: -5px;
    right: -5px;
    min-width: 20px;
    height: 20px;
    display: grid;
    place-items: center;
    border-radius: 999px;
    background: var(--mbk-red);
    color: #fff;
    font-size: 0.68rem;
    font-weight: 900;
    box-shadow: 0 0 0 3px #fff;
}

.notification-bell.has-notifications {
    color: var(--mbk-red);
    animation: mbkBellPulse 1.25s ease-in-out infinite;
}

@keyframes mbkBellPulse {
    0%, 100% { transform: rotate(0deg) scale(1); box-shadow: 0 0 0 rgba(191, 30, 46, 0); }
    35% { transform: rotate(-8deg) scale(1.04); box-shadow: 0 0 0 8px rgba(191, 30, 46, 0.08); }
    70% { transform: rotate(7deg) scale(1.02); }
}

.notification-panel {
    width: min(360px, calc(100vw - 2rem));
    padding: 0.55rem;
    border: 1px solid #eadfe2;
    border-radius: 18px;
}

.notification-panel-head {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    padding: 0.65rem 0.7rem 0.5rem;
}

.notification-panel-head strong {
    color: var(--mbk-ink);
}

.notification-panel-head small,
.notification-item small,
.notification-empty {
    color: #756d70;
}

.notification-item {
    display: grid;
    grid-template-columns: 34px 1fr;
    gap: 0.65rem;
    align-items: start;
    border-radius: 14px;
    padding: 0.65rem 0.7rem;
    color: inherit;
    text-decoration: none;
}

.notification-item:hover {
    background: #fff5f6;
    color: inherit;
}

.notification-item > span {
    width: 32px;
    height: 32px;
    display: grid;
    place-items: center;
    border-radius: 999px;
    background: #fff0f2;
    color: var(--mbk-red);
    font-weight: 900;
}

.notification-item strong,
.notification-item small {
    display: block;
}

.notification-empty {
    padding: 0.75rem;
    font-size: 0.86rem;
}

.company-transfer-panel {
    display: grid;
    gap: 1rem;
    border: 1px solid #eadfe2;
    border-radius: 22px;
    background: linear-gradient(145deg, #fff 0%, #fff8f9 100%);
    padding: 1rem;
}

.company-transfer-list {
    display: grid;
    gap: 0.65rem;
}

.company-transfer-item {
    display: grid;
    grid-template-columns: minmax(220px, 1fr) minmax(190px, 260px) auto;
    gap: 0.65rem;
    align-items: center;
    border: 1px solid #eee5e8;
    border-radius: 16px;
    background: #fff;
    padding: 0.75rem;
}

.company-transfer-item strong,
.company-transfer-item small {
    display: block;
}

.company-transfer-item small {
    color: #756d70;
}

.topbar-system-logo {
    width: 96px;
    max-height: 26px;
    object-fit: contain;
}

.topbar-company-logo {
    width: 74px;
    max-height: 26px;
    object-fit: contain;
    border-radius: 6px;
    border: 1px solid #ddd6da;
    background: #fff;
    padding: 0.2rem;
}

.company-chip {
    border-radius: 999px;
    border: 1px solid var(--mbk-line);
    background: #fff;
    padding: 0.35rem 0.7rem;
    font-size: 0.78rem;
    color: #4f494b;
}

.refined-brand {
    position: relative;
    isolation: isolate;
    display: grid;
    align-items: center;
    min-height: 104px;
    margin: -1.25rem -1.25rem 1.35rem;
    padding: 1.15rem 1.25rem;
    overflow: hidden;
    border-radius: 0;
    background: transparent;
}

.refined-brand::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -2;
    background: #fff;
}

.refined-brand::after {
    content: "";
    position: absolute;
    inset: auto 0 0;
    height: 1px;
    z-index: -1;
    background: linear-gradient(90deg, rgba(255, 255, 255, 0.06), rgba(191, 30, 46, 0.78), rgba(255, 255, 255, 0.08));
}

.system-logo-card {
    display: flex;
    align-items: center;
    min-height: 72px;
    border: 0;
    border-radius: 0;
    background: transparent;
    padding: 0;
    box-shadow: none;
}

.system-logo-card .brand-logo {
    display: block;
    width: min(100%, 232px);
    max-height: 74px;
    object-fit: contain;
    object-position: left center;
    filter: none;
}

.company-identity-card {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 18px;
    background: linear-gradient(145deg, rgba(255, 255, 255, 0.11), rgba(255, 255, 255, 0.04));
    padding: 0.85rem;
}

.company-identity-card small {
    display: block;
    color: rgba(255, 255, 255, 0.62);
    font-size: 0.68rem;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.company-identity-card strong {
    display: block;
    color: #fff;
    font-size: 0.95rem;
    line-height: 1.25;
}

.company-identity-card .company-brand-logo {
    width: 54px;
    height: 54px;
    flex: 0 0 54px;
    object-fit: contain;
    border-radius: 12px;
    background: #fff;
    padding: 0.25rem;
}

.user-menu .user-chip {
    margin-right: 0;
    cursor: pointer;
}

.management-hero {
    display: flex;
    justify-content: space-between;
    gap: 1.25rem;
    align-items: stretch;
    border-radius: 24px;
    padding: 1.4rem;
    background: linear-gradient(135deg, #231f20 0%, #3a2428 56%, #bf1e2e 140%);
    color: #fff;
    box-shadow: 0 18px 46px rgba(35, 31, 32, 0.18);
}

.management-hero h2 {
    margin: 0.2rem 0 0.35rem;
    font-weight: 800;
}

.management-hero p {
    max-width: 720px;
    margin: 0;
    color: rgba(255, 255, 255, 0.78);
}

.eyebrow {
    display: inline-block;
    color: var(--mbk-red);
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.management-hero .eyebrow {
    color: #ffd8dd;
}

.management-logos {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
    justify-content: flex-end;
}

.logo-tile {
    min-width: 150px;
    border-radius: 16px;
    background: #fff;
    color: var(--mbk-ink);
    padding: 0.8rem;
}

.logo-tile small {
    display: block;
    color: #6b6668;
    font-size: 0.72rem;
    margin-bottom: 0.35rem;
}

.logo-tile img {
    width: 150px;
    height: 50px;
    object-fit: contain;
}

.mini-logo {
    width: 72px;
    max-height: 34px;
    object-fit: contain;
    border-radius: 8px;
    background: #fff;
    border: 1px solid #e4dee1;
    padding: 0.2rem;
}

.employee-card-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.1fr) minmax(320px, 0.9fr);
    gap: 1rem;
}

.employee-profile-card {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.employee-photo-frame {
    width: 104px;
    height: 104px;
    display: grid;
    place-items: center;
    flex: 0 0 104px;
    border-radius: 24px;
    background: linear-gradient(145deg, #231f20, #bf1e2e);
    color: #fff;
    font-size: 2.4rem;
    font-weight: 800;
    overflow: hidden;
}

.employee-photo-frame img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.detail-list {
    display: grid;
    grid-template-columns: 150px 1fr;
    gap: 0.55rem 0.9rem;
    margin: 0;
}

.detail-list dt {
    color: #716b6d;
    font-size: 0.82rem;
}

.detail-list dd {
    margin: 0;
    font-weight: 650;
}

.employee-documents-panel {
    grid-column: 1 / -1;
}

.menu-card-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(220px, 1fr));
    gap: 1rem;
}

.meal-menu-card {
    border: 1px solid var(--mbk-line);
    border-radius: var(--radius-lg);
    background: #fff;
    padding: 1rem;
    box-shadow: var(--shadow-soft);
}

.meal-date {
    display: inline-flex;
    border-radius: 999px;
    background: #fff0f2;
    color: var(--mbk-red);
    padding: 0.25rem 0.65rem;
    font-size: 0.78rem;
    font-weight: 800;
    margin-bottom: 0.7rem;
}

.meal-menu-card h5 {
    margin-bottom: 0.2rem;
}

.meal-menu-card small {
    color: #716b6d;
}

.meal-menu-card p {
    margin: 0.75rem 0 0;
    color: #383234;
    line-height: 1.55;
}

.payslip-company-box {
    border-radius: 16px;
    border: 1px solid #eadfe2;
    background: #fff7f8;
    padding: 1rem;
}

.payroll-period-form {
    display: grid;
    grid-template-columns: 105px 135px minmax(180px, 1fr) auto;
    gap: 0.45rem;
    align-items: end;
}

.payroll-compact-card {
    padding: 0.8rem;
}

.payroll-compact-card .form-label {
    font-size: 0.78rem;
    margin-bottom: 0.25rem;
}

.payroll-compact-card .form-control,
.payroll-compact-card .form-select,
.payroll-compact-card .btn {
    min-height: 34px;
    font-size: 0.78rem;
}

.payroll-table-card .table-responsive {
    border-radius: 14px;
    overflow-x: auto;
}

.payslip-document {
    max-width: 1180px;
    margin: 0 auto;
}

.payslip-toolbar {
    display: flex;
    justify-content: space-between;
    gap: 0.75rem;
    margin-bottom: 1rem;
}

.payslip-sheet,
.certificate-sheet {
    background: #fff;
    border: 1px solid #d8d1d4;
    border-radius: 18px;
    box-shadow: 0 18px 46px rgba(35, 31, 32, 0.12);
}

.payslip-sheet {
    padding: 1.35rem;
}

.payslip-header {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 260px;
    gap: 1rem;
    align-items: stretch;
    padding-bottom: 1rem;
    border-bottom: 3px solid var(--mbk-red);
}

.payslip-company-identity {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.payslip-company-identity img {
    width: 150px;
    max-height: 78px;
    object-fit: contain;
}

.payslip-company-identity h2 {
    margin: 0 0 0.25rem;
    color: var(--mbk-ink);
    font-size: 1.15rem;
    font-weight: 900;
}

.payslip-company-identity p,
.certificate-company p {
    margin: 0.12rem 0;
    color: #625b5e;
    font-size: 0.82rem;
}

.payslip-title-box {
    display: grid;
    align-content: center;
    justify-items: end;
    border-left: 1px solid #eadfe2;
    padding-left: 1rem;
    text-align: right;
}

.payslip-title-box strong {
    color: var(--mbk-red);
    font-size: 1.25rem;
    font-weight: 950;
    letter-spacing: 0.06em;
}

.payslip-title-box span,
.payslip-title-box small,
.payslip-title-box em {
    display: block;
    color: #554d50;
    font-style: normal;
}

.payslip-info-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.85rem;
    margin: 1rem 0;
}

.payslip-info-grid > div,
.payslip-table-grid > section,
.payslip-sheet > section {
    border: 1px solid #e5dde0;
    border-radius: 14px;
    background: #fff;
    padding: 0.9rem;
}

.payslip-info-grid h5,
.payslip-table-grid h5,
.payslip-sheet > section h5 {
    margin: 0 0 0.65rem;
    color: var(--mbk-red);
    font-size: 0.86rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.payslip-info-grid dl {
    display: grid;
    grid-template-columns: 128px 1fr;
    gap: 0.35rem 0.65rem;
    margin: 0;
}

.payslip-info-grid dt {
    color: #756d70;
    font-size: 0.78rem;
}

.payslip-info-grid dd {
    margin: 0;
    color: var(--mbk-ink);
    font-size: 0.82rem;
    font-weight: 750;
}

.payslip-table-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.85rem;
    margin-bottom: 0.85rem;
}

.payslip-table-grid table,
.payslip-sheet > section table {
    margin-bottom: 0;
}

.payslip-table-grid th small {
    display: block;
    margin-top: 0.18rem;
    color: #80777a;
    font-size: 0.68rem;
    font-weight: 600;
}

.payslip-total-box {
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: 0.65rem;
    margin-top: 1rem;
}

.payslip-total-box > div {
    border: 1px solid #eadfe2;
    border-radius: 14px;
    background: #fff8f9;
    padding: 0.75rem;
}

.payslip-total-box span {
    display: block;
    color: #71696c;
    font-size: 0.74rem;
    font-weight: 800;
}

.payslip-total-box strong {
    display: block;
    margin-top: 0.22rem;
    color: var(--mbk-ink);
    font-size: 0.95rem;
    font-weight: 900;
}

.payslip-total-box .net {
    background: var(--mbk-red);
    color: #fff;
}

.payslip-total-box .net span,
.payslip-total-box .net strong {
    color: #fff;
}

.payslip-signatures,
.certificate-signatures {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1rem;
    margin-top: 1.1rem;
}

.payslip-signatures > div,
.certificate-signatures > div {
    min-height: 112px;
    border: 1px dashed #bfb6b9;
    border-radius: 14px;
    padding: 0.8rem;
}

.payslip-signatures strong,
.certificate-signatures strong {
    display: block;
    color: var(--mbk-ink);
    font-weight: 900;
}

.payslip-signatures span,
.certificate-signatures span {
    display: block;
    margin-top: 2.7rem;
    color: #71696c;
    font-size: 0.78rem;
}

.certificate-page {
    min-height: 100vh;
    display: grid;
    place-items: center;
    padding: 24px;
}

.certificate-sheet {
    width: min(100%, 900px);
    min-height: 1120px;
    padding: 2rem;
}

.certificate-header {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 150px;
    gap: 1rem;
    align-items: start;
    padding-bottom: 1rem;
    border-bottom: 3px solid var(--mbk-red);
}

.certificate-company {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.certificate-company img {
    width: 150px;
    max-height: 78px;
    object-fit: contain;
}

.certificate-company h1 {
    margin: 0 0 0.25rem;
    color: var(--mbk-ink);
    font-size: 1.15rem;
    font-weight: 950;
}

.certificate-date {
    border: 1px solid #eadfe2;
    border-radius: 12px;
    padding: 0.7rem;
    text-align: center;
}

.certificate-date span,
.certificate-date strong {
    display: block;
}

.certificate-date span {
    color: #71696c;
    font-size: 0.76rem;
    font-weight: 800;
}

.certificate-date strong {
    color: var(--mbk-red);
    font-size: 1rem;
    font-weight: 900;
}

.certificate-sheet h2 {
    margin: 2.2rem 0 1.4rem;
    color: var(--mbk-ink);
    font-size: 1.55rem;
    font-weight: 950;
    letter-spacing: 0.08em;
    text-align: center;
}

.certificate-identity {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 1.6rem;
}

.certificate-identity th,
.certificate-identity td {
    border: 1px solid #ddd4d8;
    padding: 0.72rem 0.85rem;
    text-align: left;
}

.certificate-identity th {
    width: 230px;
    background: #fff5f6;
    color: var(--mbk-red);
    font-weight: 900;
}

.certificate-text {
    color: var(--mbk-ink);
    font-size: 1.02rem;
    line-height: 1.9;
    text-align: justify;
}

@media print {
    .app-sidebar,
    .app-topbar,
    .app-footer,
    .mobile-sidebar-backdrop,
    .btn {
        display: none !important;
    }
    .app-shell {
        display: block;
    }
    .panel-card {
        box-shadow: none;
        border-color: #ddd;
    }
    .payslip-toolbar,
    .print-actions {
        display: none !important;
    }
    .payslip-document,
    .certificate-page {
        max-width: none;
        min-height: auto;
        padding: 0;
        display: block;
        page: document-page;
    }
    .payslip-sheet,
    .certificate-sheet {
        border: 0;
        border-radius: 0;
        box-shadow: none;
        width: 100%;
        min-height: auto;
        padding: 0;
    }
}

.app-content {
    padding-bottom: 3rem;
}

.panel-card {
    background: var(--mbk-paper);
    border-radius: var(--radius-lg);
    padding: 1.2rem;
    border: 1px solid var(--mbk-line);
    box-shadow: var(--shadow-soft);
}

.brand-preview-fixed,
.brand-preview-company {
    width: min(260px, 100%);
    max-height: 70px;
    object-fit: contain;
    border: 1px solid #e4dee1;
    border-radius: 10px;
    background: #fff;
    padding: 0.35rem;
}

.dashboard-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(160px, 1fr));
    gap: 1rem;
}

.stat-card {
    background: linear-gradient(145deg, #fff 0%, #fbf7f8 100%);
    border: 1px solid var(--mbk-line);
    border-radius: var(--radius-md);
    padding: 1rem;
    box-shadow: var(--shadow-soft);
}

.stat-card h3 {
    margin: 0 0 0.5rem;
    font-size: 0.88rem;
    color: #625d5f;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.stat-card p {
    margin: 0;
    font-size: 1.9rem;
    font-weight: 800;
    color: var(--mbk-red);
    line-height: 1;
}

.stat-card-link {
    display: block;
    color: inherit;
    text-decoration: none;
}

.stat-card-link:hover {
    color: inherit;
    transform: translateY(-1px);
}

.table > :not(caption) > * > * {
    padding: 0.8rem 0.65rem;
}

.table thead th {
    color: #6b6668;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    border-bottom-width: 1px;
}

.form-control,
.form-select {
    border-radius: 10px;
    border-color: #d7d0d3;
}

.form-control:focus,
.form-select:focus {
    border-color: rgba(191, 30, 46, 0.45);
    box-shadow: 0 0 0 0.2rem rgba(191, 30, 46, 0.18);
}

.employee-create-form .form-select:disabled,
.employee-create-form .form-control:disabled {
    background-color: #f8f4f5;
    color: #81777a;
    cursor: not-allowed;
}

.salary-wizard-card {
    position: relative;
    overflow: hidden;
    border: 1px solid #eadfe2;
    border-radius: 20px;
    padding: 1.15rem;
    background:
        radial-gradient(circle at 96% 8%, rgba(191, 30, 46, 0.12), transparent 28%),
        linear-gradient(135deg, #ffffff 0%, #fff8f9 54%, #ffffff 100%);
    box-shadow: 0 18px 42px rgba(35, 31, 32, 0.08);
}

.salary-wizard-card::before {
    content: "";
    position: absolute;
    inset: 0 auto 0 0;
    width: 5px;
    background: linear-gradient(180deg, var(--mbk-red), var(--mbk-ink));
}

.salary-wizard-head {
    position: relative;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 1rem;
    margin-bottom: 1rem;
}

.salary-wizard-head h5 {
    margin: 0.2rem 0 0.35rem;
    font-weight: 800;
    color: var(--mbk-ink);
}

.salary-wizard-head p {
    margin: 0;
    color: #655b5f;
}

.salary-source-note {
    flex: 0 0 auto;
    border: 1px solid rgba(191, 30, 46, 0.22);
    border-radius: 999px;
    padding: 0.42rem 0.72rem;
    background: #fff;
    color: var(--mbk-red);
    font-size: 0.74rem;
    font-weight: 800;
    box-shadow: 0 8px 20px rgba(35, 31, 32, 0.06);
}

.salary-result-grid {
    display: grid;
    grid-template-columns: repeat(5, minmax(130px, 1fr));
    gap: 0.75rem;
}

.salary-result-grid > div {
    border: 1px solid #eadfe2;
    border-radius: 15px;
    padding: 0.85rem;
    background: rgba(255, 255, 255, 0.88);
}

.salary-result-grid small {
    display: block;
    color: #786e72;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.03em;
    text-transform: uppercase;
}

.salary-result-grid strong {
    display: block;
    margin-top: 0.25rem;
    color: var(--mbk-ink);
    font-size: 1rem;
    font-weight: 800;
}

.alert {
    border-radius: 12px;
}

.auth-body.login-shell {
    min-height: 100vh;
    overflow: hidden;
    background:
        radial-gradient(circle at 12% 14%, rgba(191, 30, 46, 0.08), transparent 32%),
        linear-gradient(135deg, #ffffff 0%, #fbf8f9 46%, #ffffff 100%);
    padding: clamp(0.75rem, 2vw, 1.35rem);
}

.auth-container.login-shell {
    width: min(980px, calc(100vw - 56px));
    min-height: min(540px, calc(100vh - 86px));
    display: grid;
    grid-template-columns: minmax(360px, 1fr) minmax(330px, 0.9fr);
    grid-template-rows: 1fr;
    align-items: stretch;
    gap: 0;
    border: 1px solid rgba(35, 31, 32, 0.1);
    border-radius: 28px;
    overflow: hidden;
    box-shadow: 0 24px 70px rgba(35, 31, 32, 0.13);
    background: #fff;
}

.login-visual-panel {
    position: relative;
    isolation: isolate;
    grid-column: 1;
    grid-row: 1;
    display: flex;
    align-items: flex-end;
    min-height: 540px;
    padding: clamp(1.35rem, 2.5vw, 2.15rem);
    overflow: hidden;
    color: #fff;
    background:
        linear-gradient(125deg, rgba(11, 12, 14, 0.22), rgba(11, 12, 14, 0.72)),
        url("../img/login-hr-bg.png") left center / cover no-repeat;
}

.login-visual-panel::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -1;
    background:
        radial-gradient(circle at 20% 72%, rgba(191, 30, 46, 0.42), transparent 34%),
        linear-gradient(180deg, rgba(0, 0, 0, 0.02), rgba(0, 0, 0, 0.42));
}

.login-visual-panel::after {
    content: "";
    position: absolute;
    inset: 20px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 26px;
    pointer-events: none;
}

.login-visual-copy {
    width: min(100%, 430px);
    position: relative;
    z-index: 1;
}

.login-visual-copy span {
    display: inline-flex;
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.08);
    color: #ffdadd;
    font-size: 0.74rem;
    font-weight: 900;
    letter-spacing: 0.08em;
    padding: 0.42rem 0.72rem;
    text-transform: uppercase;
}

.login-visual-copy strong {
    display: block;
    margin-top: 0;
    font-size: clamp(1.42rem, 2.35vw, 1.95rem);
    font-weight: 950;
    line-height: 1.08;
}

.login-visual-copy p {
    max-width: 360px;
    margin: 0.9rem 0 0;
    color: rgba(255, 255, 255, 0.78);
    font-size: 0.96rem;
    line-height: 1.7;
}

.auth-container.login-shell .auth-card {
    grid-column: 2;
    grid-row: 1;
    border: 0;
    border-radius: 0;
    background:
        radial-gradient(circle at 100% 0%, rgba(191, 30, 46, 0.08), transparent 25%),
        #fff;
    box-shadow: none !important;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: clamp(1.55rem, 3.2vw, 2.75rem);
    min-height: 540px;
}

.auth-container.login-shell .app-footer {
    grid-column: 2;
    grid-row: 2;
    justify-content: flex-start;
    border-top: 1px solid #eee6e8;
    background: #fff;
    color: #8a8083;
    padding: 0.85rem clamp(2.5rem, 5vw, 4.6rem) 1rem;
    font-size: 0.76rem;
}

.auth-container.login-shell .app-footer span {
    text-decoration: none;
}

.login-form-shell {
    width: min(100%, 350px);
    margin-inline: auto;
}

.login-brand-panel {
    display: grid;
    gap: 0.48rem;
    margin-bottom: 1.45rem;
}

.login-eyebrow {
    display: inline-flex;
    width: max-content;
    border-radius: 999px;
    background: #fff0f2;
    color: var(--mbk-red);
    font-size: 0.72rem;
    font-weight: 900;
    letter-spacing: 0.08em;
    padding: 0.38rem 0.7rem;
    text-transform: uppercase;
}

.login-brand-panel img {
    width: min(100%, 270px);
    max-height: 64px;
    object-fit: contain;
    object-position: left center;
    margin-top: 0.35rem;
}

.login-brand-panel strong {
    color: var(--mbk-ink);
    font-size: clamp(1.08rem, 1.55vw, 1.22rem);
    font-weight: 950;
    line-height: 1.2;
    white-space: nowrap;
}

.login-brand-panel p {
    margin: 0;
    color: #746b6e;
    font-size: 0.84rem;
    line-height: 1.52;
}

.login-form-grid {
    display: grid;
    gap: 0.82rem;
}

.login-field {
    display: grid;
    gap: 0.36rem;
}

.login-form-grid .form-label {
    margin: 0;
    color: var(--mbk-ink);
    font-size: 0.86rem;
    font-weight: 850;
}

.login-form-grid .form-control {
    min-height: 46px;
    border: 1px solid #d8d0d3;
    border-radius: 14px;
    background: #fff;
    color: var(--mbk-ink);
    font-size: 1rem;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.8);
}

.login-form-grid .form-control:focus {
    border-color: rgba(191, 30, 46, 0.55);
    box-shadow: 0 0 0 0.22rem rgba(191, 30, 46, 0.13);
}

.login-form-grid .form-text {
    color: #7b7275;
    font-size: 0.78rem;
}

.login-form-grid .btn-brand {
    min-height: 48px;
    border-radius: 14px;
    font-size: 0.98rem;
    font-weight: 900;
    box-shadow: 0 16px 26px rgba(191, 30, 46, 0.22);
}

.login-captcha-row {
    display: grid;
    grid-template-columns: 132px 1fr;
    gap: 0.65rem;
    align-items: center;
}

.login-captcha-row img {
    width: 132px;
    height: 48px;
    border: 1px solid #eadfe2;
    border-radius: 16px;
    background: #fff7f8;
}

.login-security-note {
    display: none;
    justify-content: space-between;
    gap: 0.7rem;
    align-items: center;
    margin-top: 1rem;
    border: 1px solid #eee6e8;
    border-radius: 16px;
    background: #fffafb;
    padding: 0.75rem 0.85rem;
}

.login-page-footer {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0.35rem;
    display: flex;
    justify-content: center;
    pointer-events: none;
}

.login-page-footer .app-footer {
    border: 0;
    background: transparent;
    color: #8f8689;
    opacity: 0.68;
    padding: 0.2rem 0.7rem;
}

.login-security-note span {
    color: var(--mbk-red);
    font-size: 0.78rem;
    font-weight: 950;
}

.login-security-note small {
    color: #746b6e;
    font-size: 0.76rem;
    text-align: right;
}

.employee-search-input {
    min-width: 260px;
}

.employee-filter-bar {
    display: grid;
    grid-template-columns: minmax(260px, 1.4fr) repeat(3, minmax(150px, 0.7fr));
    gap: 0.65rem;
}

.manager-scope-card {
    border: 1px solid #eadfe2;
    border-radius: 16px;
    padding: 1rem;
    background: #fffafa;
}

.outlook-list {
    display: grid;
    gap: 0.75rem;
}

.outlook-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 0.95rem 1rem;
    border: 1px solid #eadfe2;
    border-radius: 16px;
    background: #fff;
    box-shadow: 0 10px 22px rgba(35, 31, 32, 0.05);
}

.outlook-item strong,
.outlook-item span,
.outlook-item p {
    display: block;
}

.outlook-item span {
    font-weight: 800;
    color: var(--mbk-ink);
}

.outlook-item p {
    margin: 0.18rem 0 0;
    color: #756b6f;
    font-size: 0.9rem;
}

.outlook-item small {
    color: var(--mbk-red);
    font-weight: 800;
    white-space: nowrap;
}

.outlook-item.compact {
    color: inherit;
    text-decoration: none;
    padding: 0.78rem 0.85rem;
}

.mini-list {
    display: grid;
    gap: 0.6rem;
}

.table-actions {
    min-width: 240px;
}

.garnishment-detail summary {
    color: var(--mbk-red);
    cursor: pointer;
    font-size: 0.78rem;
    font-weight: 800;
}

.garnishment-detail div {
    display: grid;
    gap: 0.12rem;
    margin-top: 0.35rem;
    color: #665e61;
    font-size: 0.76rem;
}

.inbox-action-form {
    display: grid;
    grid-template-columns: minmax(130px, 0.8fr) minmax(150px, 1fr) auto;
    gap: 0.35rem;
    align-items: center;
    min-width: min(100%, 420px);
}

.company-chip-plain {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    background: transparent;
    border: 0;
    padding-inline: 0;
}

.company-chip-plain .topbar-company-logo {
    width: 34px;
    max-height: 28px;
    object-fit: contain;
}

.mobile-sidebar-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.36);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.2s ease;
    z-index: 60;
}

.employee-page-head h3 {
    color: var(--mbk-ink);
    font-weight: 800;
}

.employee-tabs {
    gap: 0.35rem;
    border-bottom-color: #eadfe2;
}

.employee-tabs .nav-link {
    border: 1px solid transparent;
    border-radius: 999px;
    color: #625b5e;
    font-weight: 750;
}

.employee-tabs .nav-link.active {
    border-color: rgba(191, 30, 46, 0.22);
    background: #fff1f3;
    color: var(--mbk-red);
}

.detail-list-wide {
    grid-template-columns: 180px 1fr;
}

.id-card-preview-wrap {
    display: grid;
    grid-template-columns: 1fr minmax(260px, 360px);
    gap: 1.25rem;
    align-items: center;
}

.id-card-mini-preview,
.id-card-design-preview {
    position: relative;
    display: grid;
    grid-template-columns: 72px 1fr 62px;
    align-items: center;
    gap: 0.9rem;
    border: 1px solid color-mix(in srgb, var(--card-accent, #bf1e2e) 24%, #fff);
    border-radius: 18px;
    background: var(--card-bg, #fff);
    color: var(--card-text, #231f20);
    padding: 1rem;
    overflow: hidden;
}

.id-card-mini-preview::before,
.id-card-design-preview::before {
    content: "";
    position: absolute;
    inset: 0 auto 0 0;
    width: 8px;
    background: var(--card-accent, #bf1e2e);
}

.mini-photo,
.preview-photo {
    width: 72px;
    height: 72px;
    display: grid;
    place-items: center;
    border-radius: 16px;
    overflow: hidden;
    background: linear-gradient(145deg, var(--card-accent, #bf1e2e), #231f20);
    color: #fff;
    font-size: 1.6rem;
    font-weight: 800;
}

.mini-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.id-card-mini-preview strong,
.id-card-design-preview strong,
.id-card-mini-preview span,
.id-card-design-preview span,
.id-card-mini-preview small,
.id-card-design-preview small {
    display: block;
}

.preview-qr {
    display: grid;
    place-items: center;
    width: 62px;
    height: 62px;
    border-radius: 10px;
    border: 1px dashed var(--card-accent, #bf1e2e);
    font-weight: 800;
    color: var(--card-accent, #bf1e2e);
}

.parameter-value-preview {
    max-width: 360px;
    white-space: pre-wrap;
    font-size: 0.76rem;
    color: #514a4d;
}

.print-body {
    margin: 0;
    background: #f4f1f2;
    color: #231f20;
}

.id-card-print-page {
    min-height: 100vh;
    display: grid;
    place-items: center;
    padding: 20px;
}

.print-id-card {
    --card-w: 8cm;
    --card-h: 5cm;
    position: relative;
    width: var(--card-w);
    height: var(--card-h);
    overflow: hidden;
    border-radius: 0.35cm;
    background: var(--card-bg, #fff);
    color: var(--card-text, #231f20);
    box-shadow: 0 20px 60px rgba(35, 31, 32, 0.18);
    padding: 0;
    display: block;
}

.print-id-card.portrait {
    --card-w: 5cm;
    --card-h: 8cm;
}

.id-card-accent {
    position: absolute;
    inset: 0 auto 0 0;
    width: 0.16cm;
    background: var(--card-accent, #bf1e2e);
}

.id-card-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 0.2cm;
    min-height: 0.56cm;
    padding-left: 0.08cm;
}

.id-card-system-logo {
    position: absolute;
    right: 0.32cm;
    bottom: 0.18cm;
    width: 1.85cm;
    max-height: 0.42cm;
    object-fit: contain;
    object-position: right center;
    opacity: 0.78;
}

.id-card-company-logo {
    position: absolute;
    left: var(--company-logo-x, 6mm);
    top: var(--company-logo-y, 5mm);
    width: 2.2cm;
    max-height: 0.78cm;
    object-fit: contain;
    object-position: left center;
}

.id-card-body {
    display: contents;
}

.print-id-card.portrait .id-card-body {
    display: contents;
}

.id-card-photo {
    position: absolute;
    left: var(--photo-x, 6mm);
    top: var(--photo-y, 18mm);
    width: 1.34cm;
    height: 1.34cm;
    display: grid;
    place-items: center;
    border-radius: 0.28cm;
    background: linear-gradient(145deg, var(--card-accent, #bf1e2e), #231f20);
    color: #fff;
    overflow: hidden;
    font-size: 0.58cm;
    font-weight: 800;
}

.print-id-card.portrait .id-card-photo {
    margin-inline: 0;
}

.id-card-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.id-card-info {
    position: absolute;
    left: var(--info-x, 31mm);
    top: var(--info-y, 20mm);
    width: 3.85cm;
    min-width: 0;
}

.id-card-info strong,
.id-card-info span,
.id-card-info small,
.id-card-info em {
    display: block;
    line-height: 1.15;
}

.id-card-info strong {
    font-size: 0.28cm;
    font-weight: 900;
}

.id-card-info span {
    margin-top: 0.06cm;
    font-size: 0.21cm;
    font-weight: 800;
    color: var(--card-accent, #bf1e2e);
}

.id-card-info small,
.id-card-info em {
    margin-top: 0.04cm;
    font-size: 0.18cm;
    font-style: normal;
}

.id-card-qr {
    position: absolute;
    left: var(--qr-x, 66mm);
    top: var(--qr-y, 22mm);
    width: 1.12cm;
    height: 1.12cm;
    background: #fff;
    border-radius: 0.12cm;
    overflow: hidden;
}

.print-id-card.portrait .id-card-qr {
    margin-inline: 0;
}

.id-card-qr svg {
    display: block;
    width: 100%;
    height: 100%;
}

.print-actions {
    margin-top: 18px;
    text-align: center;
}

.print-actions button {
    border: 0;
    border-radius: 999px;
    background: #bf1e2e;
    color: #fff;
    font-weight: 800;
    padding: 0.7rem 1.25rem;
}

.system-management-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1rem;
}

.system-management-card {
    display: grid;
    gap: 0.45rem;
    min-height: 138px;
    border: 1px solid #eadfe2;
    border-radius: 18px;
    background: linear-gradient(145deg, #fff, #fff7f8);
    color: var(--mbk-ink);
    padding: 1.05rem;
    text-decoration: none;
    box-shadow: 0 12px 28px rgba(35, 31, 32, 0.07);
    transition: transform 0.16s ease, border-color 0.16s ease;
}

.system-management-card:hover {
    border-color: rgba(191, 30, 46, 0.36);
    color: var(--mbk-ink);
    transform: translateY(-2px);
}

.system-management-card strong {
    font-size: 1rem;
    font-weight: 900;
}

.system-management-card span {
    color: #6f6669;
    font-size: 0.84rem;
    line-height: 1.55;
}

.company-actions,
.company-delete-form {
    display: flex;
    align-items: center;
    gap: 0.45rem;
    flex-wrap: wrap;
}

.company-delete-form .form-select {
    min-width: 190px;
}

.company-tabs .nav-link {
    border-radius: 999px;
    color: #5f5659;
    font-weight: 800;
}

.company-tabs .nav-link.active {
    background: #fff0f2;
    border-color: rgba(191, 30, 46, 0.22);
    color: var(--mbk-red);
}

.payroll-summary-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(112px, 1fr));
    gap: 0.42rem;
}

.payroll-summary-card {
    border: 1px solid #eadfe2;
    border-radius: 12px;
    background: #fff;
    padding: 0.52rem 0.58rem;
}

.payroll-summary-card span {
    display: block;
    color: #70676a;
    font-size: 0.6rem;
    font-weight: 800;
    letter-spacing: 0.03em;
    text-transform: uppercase;
}

.payroll-summary-card strong {
    display: block;
    margin-top: 0.24rem;
    color: var(--mbk-ink);
    font-size: 0.78rem;
}

.payroll-filter-bar {
    display: grid;
    grid-template-columns: minmax(190px, 1.2fr) repeat(3, minmax(108px, 0.8fr));
    gap: 0.42rem;
}

.payroll-summary-link {
    color: inherit;
    text-decoration: none;
}

.payroll-summary-link:hover {
    color: inherit;
    transform: translateY(-1px);
}

#payrollTable {
    font-size: 0.62rem;
    min-width: 1080px;
}

#payrollTable th,
#payrollTable td {
    padding: 0.2rem 0.22rem;
    vertical-align: middle;
    white-space: nowrap;
}

#payrollTable td:first-child,
#payrollTable th:first-child {
    min-width: 138px;
    white-space: normal;
}

.offboarding-checklist {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 0.6rem;
}

.offboarding-checklist .form-check {
    border: 1px solid #eadfe2;
    border-radius: 14px;
    background: #fff;
    padding: 0.75rem 0.9rem 0.75rem 2.35rem;
}

.data-transfer-warning {
    border: 1px solid #f4c7ce;
    border-radius: 16px;
    background: #fff6f7;
    color: #672029;
    padding: 1rem;
}

@page id-card-page {
    size: 8cm 5cm;
    margin: 0;
}

@page id-card-page-portrait {
    size: 5cm 8cm;
    margin: 0;
}

@page document-page {
    size: A4;
    margin: 0;
}

@media print {
    .print-body {
        background: #fff;
    }
    .id-card-print-page {
        min-height: auto;
        padding: 0;
        page: id-card-page;
    }
    .print-id-card {
        box-shadow: none;
        border-radius: 0;
    }
    .print-actions {
        display: none;
    }
}

@media (max-width: 1200px) {
    .dashboard-grid {
        grid-template-columns: repeat(2, minmax(140px, 1fr));
    }
    .menu-card-grid {
        grid-template-columns: repeat(2, minmax(220px, 1fr));
    }
    .salary-result-grid {
        grid-template-columns: repeat(3, minmax(130px, 1fr));
    }
}

@media (max-width: 992px) {
    .auth-container.login-shell {
        width: min(100%, 720px);
        min-height: auto;
        grid-template-columns: 1fr;
        grid-template-rows: auto auto auto;
        border-radius: 22px;
    }
    .login-visual-panel {
        grid-column: 1;
        grid-row: 1;
        min-width: 0;
        min-height: 260px;
        padding: 1.5rem;
        background-position: left center;
    }
    .login-visual-panel::after {
        inset: 14px;
        border-radius: 18px;
    }
    .login-visual-copy {
        width: 100%;
        min-width: 0;
        max-width: 440px;
    }
    .login-visual-copy strong {
        font-size: 1.55rem;
    }
    .auth-container.login-shell .auth-card {
        grid-column: 1;
        grid-row: 2;
        min-width: 0;
        min-height: auto;
        padding: 2rem;
    }
    .auth-container.login-shell .app-footer {
        grid-column: 1;
        grid-row: 3;
        justify-content: center;
        padding: 0.8rem 1rem 1rem;
        text-align: center;
    }
    .login-page-footer {
        position: static;
        margin-top: 0.5rem;
        padding-bottom: 0.5rem;
    }
    .employee-filter-bar {
        grid-template-columns: 1fr 1fr;
    }
    .app-shell {
        grid-template-columns: 1fr;
    }
    .app-sidebar {
        position: fixed;
        left: -320px;
        top: 0;
        bottom: 0;
        z-index: 80;
        width: 300px;
        max-width: 85vw;
        overflow-y: auto;
        transition: left 0.2s ease;
        padding-bottom: 1rem;
    }
    .menu-nav {
        flex-direction: column;
    }
    body.sidebar-open .app-sidebar {
        left: 0;
    }
    body.sidebar-open .mobile-sidebar-backdrop {
        opacity: 1;
        visibility: visible;
    }
    .app-main {
        min-height: 100vh;
    }
    .table-responsive {
        border-radius: 10px;
    }
    .panel-card {
        padding: 1rem;
    }
    .id-card-preview-wrap,
    .id-card-design-preview,
    .id-card-mini-preview {
        grid-template-columns: 1fr;
    }
    .employee-tabs {
        overflow-x: auto;
        flex-wrap: nowrap;
        padding-bottom: 0.35rem;
    }
    .employee-tabs .nav-link {
        white-space: nowrap;
    }
    .user-chip {
        margin-right: 0;
    }
    .install-wizard {
        grid-template-columns: 1fr;
    }
    .install-side {
        padding: 1rem;
    }
    .install-steps {
        grid-template-columns: repeat(3, 1fr);
    }
    .install-support {
        display: none;
    }
    .payroll-period-form,
    .payslip-header,
    .payslip-info-grid,
    .payslip-table-grid,
    .payslip-total-box,
    .certificate-header {
        grid-template-columns: 1fr;
    }
    .payslip-title-box {
        justify-items: start;
        border-left: 0;
        border-top: 1px solid #eadfe2;
        padding: 0.85rem 0 0;
        text-align: left;
    }
    .payslip-signatures,
    .certificate-signatures {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 820px) {
    .setup-grid {
        grid-template-columns: 1fr;
    }
    .setup-container {
        padding: 0;
    }
    .setup-header h1 {
        font-size: 25px;
    }
}

@media (max-width: 768px) {
    .dashboard-grid {
        grid-template-columns: 1fr;
    }
    .app-topbar {
        flex-direction: column;
        align-items: flex-start;
        padding: 0.9rem 1rem;
    }
    .smart-search {
        width: 100%;
        max-width: none;
        flex-basis: auto;
    }
    .topbar-right {
        width: 100%;
        justify-content: flex-start;
        gap: 0.4rem;
    }
    .auth-card {
        padding: 1.4rem;
    }
    .auth-body.login-shell {
        overflow: auto;
        overflow-x: hidden;
        padding: 0;
    }
    .auth-container.login-shell {
        width: 100vw;
        max-width: 100vw;
        border: 0;
        border-radius: 0;
        box-shadow: none;
    }
    .auth-container.login-shell .auth-card {
        width: 100vw;
        max-width: 100vw;
        overflow: hidden;
        padding: 1.45rem;
    }
    .login-form-shell {
        width: calc(100vw - 2.9rem);
        max-width: calc(100vw - 2.9rem);
        min-width: 0;
        margin-inline: 0;
    }
    .login-brand-panel,
    .login-form-grid,
    .login-security-note {
        width: 100%;
        max-width: 100%;
    }
    .login-brand-panel img {
        width: min(100%, 270px);
    }
    .login-brand-panel strong {
        display: block;
        font-size: 1.22rem;
        max-width: 100%;
        overflow-wrap: break-word;
        white-space: normal;
    }
    .login-visual-copy strong {
        display: block;
        font-size: 1.34rem;
        line-height: 1.12;
        max-width: 100%;
        overflow-wrap: break-word;
        white-space: normal;
    }
    .login-visual-copy p,
    .login-brand-panel p,
    .login-form-grid .form-text {
        max-width: 100%;
        overflow-wrap: anywhere;
    }
    .login-security-note {
        align-items: flex-start;
        flex-direction: column;
    }
    .employee-filter-bar {
        grid-template-columns: 1fr;
    }
    .payroll-filter-bar {
        grid-template-columns: 1fr;
    }
    .login-captcha-row {
        grid-template-columns: 1fr;
    }
    .inbox-action-form {
        grid-template-columns: 1fr;
        min-width: 0;
    }
    .login-form-grid .form-control,
    .login-form-grid .btn-brand {
        width: 100%;
        max-width: 100%;
    }
    .login-security-note small {
        text-align: left;
    }
    .management-hero,
    .employee-profile-card {
        flex-direction: column;
    }
    .management-logos {
        justify-content: flex-start;
    }
    .employee-card-grid,
    .menu-card-grid {
        grid-template-columns: 1fr;
    }
    .salary-wizard-head {
        flex-direction: column;
    }
    .salary-source-note {
        align-self: flex-start;
    }
    .salary-result-grid {
        grid-template-columns: 1fr;
    }
    .detail-list {
        grid-template-columns: 1fr;
    }
    .install-shell .auth-card {
        padding: 0;
    }
    .install-main {
        padding: 1rem;
    }
    .install-header {
        flex-direction: column;
    }
    .install-check-score {
        text-align: left;
    }
    .install-steps {
        grid-template-columns: 1fr;
    }
    .install-actions .btn {
        width: 100%;
    }
    .page-heading {
        font-size: 1.05rem;
    }
    .stat-card p {
        font-size: 1.55rem;
    }
    .table > :not(caption) > * > * {
        padding: 0.62rem 0.52rem;
        font-size: 0.86rem;
    }
    .outlook-item {
        align-items: flex-start;
        flex-direction: column;
    }
    .employee-search-input {
        width: 100%;
        min-width: 0;
    }
    .payslip-company-identity,
    .certificate-company {
        align-items: flex-start;
        flex-direction: column;
    }
    .payslip-info-grid dl {
        grid-template-columns: 1fr;
    }
    .certificate-sheet {
        min-height: auto;
        padding: 1.2rem;
    }
}

@media (max-width: 480px) {
    .topbar-system-logo {
        width: 84px;
    }
    .topbar-company-logo {
        width: 62px;
    }
    .company-chip,
    .user-chip {
        font-size: 0.72rem;
        padding: 0.32rem 0.58rem;
    }
    .btn {
        --bs-btn-padding-y: 0.38rem;
        --bs-btn-padding-x: 0.68rem;
    }
}

/* System MBK UI refinements */
.app-sidebar {
    position: relative;
    box-shadow: 18px 0 34px rgba(17, 14, 15, 0.16);
}

.refined-brand {
    min-height: 92px;
    margin: -1.25rem -1.25rem 1.1rem;
    padding: 0.95rem 1.1rem;
    background: #fff !important;
    box-shadow: 0 12px 28px rgba(0, 0, 0, 0.18);
}

.refined-brand::before,
.refined-brand::after {
    display: none;
}

.system-logo-card {
    min-height: 66px;
    justify-content: flex-start;
}

.system-logo-card .brand-logo {
    width: min(100%, 236px);
    max-height: 66px;
    object-position: left center;
}

.menu-link {
    display: flex;
    align-items: center;
    gap: 0.72rem;
    min-height: 42px;
    padding: 0.62rem 0.72rem;
    font-size: 0.92rem;
    font-weight: 720;
}

.menu-icon {
    width: 20px;
    height: 20px;
    flex: 0 0 20px;
    display: inline-grid;
    place-items: center;
    opacity: 0.96;
}

.menu-icon svg {
    width: 20px;
    height: 20px;
    display: block;
    fill: #fff;
}

.smart-search .form-control {
    padding-left: 2.45rem;
    padding-right: 1.1rem;
}

.smart-search-icon {
    position: absolute;
    left: 0.92rem;
    top: 50%;
    z-index: 2;
    width: 18px;
    height: 18px;
    transform: translateY(-50%);
    color: var(--mbk-red);
    pointer-events: none;
}

.smart-search-icon svg {
    width: 18px;
    height: 18px;
    display: block;
    fill: currentColor;
}

.user-chip {
    gap: 0.58rem;
    padding: 0.33rem 0.48rem 0.33rem 0.74rem;
}

.user-avatar {
    width: 30px;
    height: 30px;
    display: inline-grid;
    place-items: center;
    border-radius: 50%;
    overflow: hidden;
    background: linear-gradient(145deg, var(--mbk-red), #231f20);
    color: #fff;
    font-size: 0.78rem;
    font-weight: 900;
}

.user-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.app-footer,
.app-footer * {
    pointer-events: none !important;
    cursor: default !important;
    text-decoration: none !important;
    color: inherit;
}

.app-footer .plain-contact {
    -webkit-user-select: text;
    user-select: text;
}

.dashboard-inbox-stack {
    display: grid;
    gap: 1rem;
}

.dashboard-inbox-stack .panel-card {
    width: 100%;
}

.offboarding-hero {
    position: relative;
    overflow: hidden;
    border: 1px solid rgba(191, 30, 46, 0.16);
    border-radius: 24px;
    background:
        radial-gradient(circle at 90% 15%, rgba(191, 30, 46, 0.16), transparent 32%),
        linear-gradient(135deg, #fff 0%, #fff7f8 54%, #fff 100%);
    padding: 1.35rem;
    box-shadow: 0 18px 44px rgba(35, 31, 32, 0.08);
}

.offboarding-hero::before {
    content: "";
    position: absolute;
    inset: 0 auto 0 0;
    width: 7px;
    background: linear-gradient(180deg, var(--mbk-red), var(--mbk-ink));
}

.offboarding-hero-main {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    align-items: flex-start;
    flex-wrap: wrap;
}

.offboarding-person strong {
    display: block;
    color: var(--mbk-ink);
    font-size: 1.45rem;
    font-weight: 950;
}

.offboarding-person span {
    display: block;
    margin-top: 0.25rem;
    color: #6f6669;
}

.offboarding-quick-actions {
    display: flex;
    gap: 0.45rem;
    flex-wrap: wrap;
}

.offboarding-step-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
    gap: 0.7rem;
    margin-top: 1rem;
}

.offboarding-step {
    border: 1px solid #eadfe2;
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.86);
    padding: 0.85rem;
}

.offboarding-step small {
    display: inline-flex;
    width: 28px;
    height: 28px;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: var(--mbk-red);
    color: #fff;
    font-weight: 900;
}

.offboarding-step strong {
    display: block;
    margin-top: 0.45rem;
    color: var(--mbk-ink);
    font-weight: 900;
}

.offboarding-step span {
    display: block;
    margin-top: 0.15rem;
    color: #756d70;
    font-size: 0.82rem;
}

.offboarding-form-shell {
    display: grid;
    gap: 1rem;
}

.offboarding-section {
    border: 1px solid #eadfe2;
    border-radius: 20px;
    background: #fff;
    padding: 1.1rem;
}

.offboarding-section h5 {
    margin-bottom: 0.9rem;
    color: var(--mbk-ink);
    font-weight: 900;
}

.data-transfer-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem;
}

.data-transfer-card {
    border: 1px solid #eadfe2;
    border-radius: 20px;
    background: #fff;
    padding: 1.15rem;
    box-shadow: 0 12px 28px rgba(35, 31, 32, 0.06);
}

.data-transfer-card.danger {
    border-color: #f0b8c1;
    background: #fff8f9;
}

.data-transfer-scope {
    border: 1px solid #eadfe2;
    border-radius: 16px;
    padding: 0.85rem;
    background: #faf8f9;
}

.collar-option-grid {
    display: grid;
    grid-template-columns: minmax(140px, 0.8fr) minmax(180px, 1fr) 90px;
    gap: 0.6rem;
    align-items: end;
}

.collar-option-row {
    display: contents;
}

.work-schedule-calendar {
    display: grid;
    grid-template-columns: repeat(7, minmax(100px, 1fr));
    gap: 0.6rem;
}

.work-schedule-employee-picker-row .employee-picker {
    max-width: 760px;
}

.work-schedule-day {
    border: 1px solid #eadfe2;
    border-radius: 16px;
    background: #fff;
    padding: 0.8rem;
}

.work-schedule-day strong,
.work-schedule-day span {
    display: block;
}

.work-schedule-day span {
    color: #756d70;
    font-size: 0.82rem;
}

.payslip-toolbar,
.print-actions {
    position: fixed;
    top: 16px;
    right: 16px;
    z-index: 20;
    display: flex;
    gap: 0.45rem;
    margin: 0;
}

.print-floating-button,
.print-actions button,
.payslip-toolbar .btn,
.payslip-approval-pill {
    border: 0;
    border-radius: 999px;
    background: #bf1e2e;
    color: #fff;
    font-weight: 850;
    padding: 0.55rem 0.95rem;
    text-decoration: none;
    box-shadow: 0 12px 26px rgba(35, 31, 32, 0.16);
}

.payslip-approval-pill {
    display: inline-flex;
    align-items: center;
    background: #fff;
    color: #1f7a3a;
    border: 1px solid #badfc6;
    box-shadow: 0 12px 26px rgba(35, 31, 32, 0.08);
}

.payslip-document,
.certificate-page {
    width: 210mm;
    min-height: 297mm;
    margin: 0 auto;
    padding: 8mm 0;
    display: block;
}

.payslip-sheet,
.certificate-sheet {
    width: 210mm;
    min-height: 297mm;
    margin: 0 auto;
    padding: 10mm;
    border-radius: 0;
    box-sizing: border-box;
}

.payslip-sheet {
    font-size: 10.2px;
}

.payslip-header {
    gap: 0.55rem;
    padding-bottom: 0.55rem;
}

.payslip-company-identity img,
.certificate-company img {
    max-width: 34mm;
    max-height: 17mm;
}

.payslip-company-identity h2 {
    font-size: 13px;
}

.payslip-company-identity p,
.certificate-company p {
    font-size: 8.8px;
    line-height: 1.25;
}

.payslip-title-box {
    padding: 0.55rem;
}

.payslip-info-grid,
.payslip-table-grid {
    gap: 0.45rem;
    margin-top: 0.5rem;
}

.payslip-info-grid > div,
.payslip-table-grid > section,
.payslip-sheet > section {
    padding: 0.5rem;
    border-radius: 10px;
}

.payslip-info-grid h5,
.payslip-table-grid h5,
.payslip-sheet > section h5 {
    margin-bottom: 0.35rem;
    font-size: 9.8px;
}

.payslip-info-grid dl {
    grid-template-columns: 78px 1fr;
    gap: 0.1rem 0.3rem;
}

.payslip-info-grid dt,
.payslip-info-grid dd,
.payslip-table-grid table,
.payslip-sheet > section table {
    font-size: 8.8px;
}

.payslip-sheet .table > :not(caption) > * > * {
    padding: 0.22rem 0.3rem;
}

.payslip-total-box {
    grid-template-columns: repeat(6, 1fr);
    gap: 0.35rem;
    margin-top: 0.5rem;
}

.payslip-total-box > div {
    padding: 0.4rem;
    border-radius: 9px;
}

.payslip-total-box span {
    font-size: 7.5px;
}

.payslip-total-box strong {
    font-size: 9.5px;
}

.payslip-signatures,
.certificate-signatures {
    gap: 0.6rem;
    margin-top: 0.7rem;
}

.payslip-signatures > div,
.certificate-signatures > div {
    min-height: 64px;
    padding: 0.55rem;
}

.certificate-sheet {
    font-size: 12px;
}

.certificate-sheet h2 {
    margin: 1.45rem 0 1rem;
    font-size: 1.35rem;
}

.certificate-identity th,
.certificate-identity td {
    padding: 0.45rem 0.6rem;
}

.certificate-text {
    font-size: 0.95rem;
    line-height: 1.75;
}

.id-card-print-page {
    min-height: 100vh;
    padding: 0;
    display: grid;
    place-items: center;
}

.print-id-card {
    box-shadow: 0 18px 54px rgba(35, 31, 32, 0.16);
}

@media print {
    @page {
        size: A4;
        margin: 0;
    }

    .print-body {
        background: #fff !important;
        margin: 0 !important;
        print-color-adjust: exact;
        -webkit-print-color-adjust: exact;
    }

    .payslip-toolbar,
    .print-actions,
    .print-floating-button {
        display: none !important;
    }

    .payslip-document,
    .certificate-page {
        width: 210mm;
        min-height: 297mm;
        margin: 0;
        padding: 0;
        page: document-page;
    }

    .payslip-sheet,
    .certificate-sheet {
        width: 210mm;
        min-height: 297mm;
        margin: 0;
        padding: 9mm;
        box-sizing: border-box;
        box-shadow: none !important;
        border: 0 !important;
    }

    .payslip-sheet {
        font-size: 9.4px;
        overflow: hidden;
    }

    .id-card-print-page {
        width: 8cm;
        min-height: 5cm;
        padding: 0;
        page: id-card-page;
    }

    .print-id-card {
        box-shadow: none !important;
        border-radius: 0;
    }
}

@media (max-width: 992px) {
    .data-transfer-grid,
    .work-schedule-calendar {
        grid-template-columns: 1fr;
    }

    .collar-option-grid {
        grid-template-columns: 1fr;
    }

    .offboarding-quick-actions,
    .payslip-toolbar,
    .print-actions {
        position: static;
        justify-content: flex-start;
        margin-bottom: 0.8rem;
    }
}

/* Compact desktop scale */
@media (min-width: 993px) {
    html {
        font-size: 15px;
    }

    .app-content.container-fluid {
        padding-top: 1.1rem !important;
        padding-left: 1.25rem !important;
        padding-right: 1.25rem !important;
    }

    .panel-card {
        padding: 1rem;
    }

    .table > :not(caption) > * > * {
        padding: 0.52rem 0.5rem;
    }

    .stat-card {
        padding: 0.85rem;
    }

    .stat-card p {
        font-size: 1.55rem;
    }

    .form-control,
    .form-select {
        min-height: 36px;
        font-size: 0.9rem;
    }
}

/* Sidebar logo capsule polish */
.refined-brand {
    min-height: var(--app-topbar-height);
    margin: -1.25rem -1.25rem 1.05rem;
    padding: 0 1.25rem;
    background: transparent !important;
    box-shadow: none;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    display: flex;
    align-items: center;
}

.refined-brand::before,
.refined-brand::after {
    display: none !important;
}

.system-logo-card {
    min-height: 58px;
    width: 100%;
    justify-content: center;
    border-radius: 999px;
    background: #ffffff;
    padding: 0.45rem 0.9rem;
    overflow: hidden;
    box-shadow:
        0 14px 30px rgba(0, 0, 0, 0.20),
        inset 0 0 0 1px rgba(35, 31, 32, 0.08);
}

.system-logo-card .brand-logo {
    width: min(100%, 220px);
    max-height: 48px;
    object-position: center center;
}

@media (max-width: 992px) {
    .system-logo-card {
        min-height: 76px;
    }

    .system-logo-card .brand-logo {
        width: min(100%, 220px);
    }
}

/* Fleet management */
.fleet-alert-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 0.9rem;
}

.fleet-alert-card {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    padding: 1rem 1.1rem;
    border: 1px solid rgba(188, 50, 54, 0.20);
    border-radius: 22px;
    background:
        linear-gradient(135deg, rgba(188, 50, 54, 0.10), rgba(255, 255, 255, 0.96)),
        #fff;
    color: var(--ink);
    text-decoration: none;
    box-shadow: 0 18px 42px rgba(42, 31, 31, 0.08);
}

.fleet-alert-card:hover {
    transform: translateY(-1px);
    color: var(--ink);
}

.fleet-alert-card strong,
.fleet-alert-card span,
.fleet-alert-card small {
    display: block;
}

.fleet-alert-card strong {
    font-size: 1.05rem;
    letter-spacing: 0.04em;
}

.fleet-alert-card small {
    color: var(--muted);
}

.fleet-filter-bar {
    display: grid;
    grid-template-columns: minmax(240px, 1fr) 170px;
    gap: 0.6rem;
    min-width: min(100%, 460px);
}

.fleet-plate-input {
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.fleet-card-grid {
    display: grid;
    grid-template-columns: minmax(280px, 0.9fr) minmax(320px, 1.1fr);
    gap: 1rem;
}

.fleet-visual-card {
    display: grid;
    gap: 1rem;
}

.fleet-photo-frame {
    min-height: 240px;
    border-radius: 28px;
    overflow: hidden;
    background:
        radial-gradient(circle at 18% 15%, rgba(188, 50, 54, 0.16), transparent 34%),
        linear-gradient(135deg, #ffffff, #f5f1f1);
    border: 1px solid rgba(35, 31, 32, 0.08);
    display: grid;
    place-items: center;
}

.fleet-photo-frame img {
    width: 100%;
    height: 100%;
    min-height: 240px;
    object-fit: cover;
}

.fleet-photo-frame span {
    width: 92px;
    height: 92px;
    display: grid;
    place-items: center;
    border-radius: 999px;
    background: #fff;
    color: var(--brand-red);
    font-size: 2.4rem;
    font-weight: 800;
    box-shadow: 0 18px 44px rgba(42, 31, 31, 0.12);
}

.fleet-plate-strip {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 0.75rem;
    padding: 0.8rem 1rem;
    border-radius: 18px;
    background: #ffffff;
    border: 1px solid rgba(35, 31, 32, 0.09);
}

.fleet-plate-strip strong {
    letter-spacing: 0.07em;
    font-size: 1.35rem;
}

.fleet-alert-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
}

.fleet-kpi-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0.9rem;
}

@media (max-width: 1200px) {
    .fleet-kpi-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 768px) {
    .fleet-card-grid,
    .fleet-filter-bar {
        grid-template-columns: 1fr;
    }

.fleet-kpi-grid {
    grid-template-columns: 1fr;
}
}

.payroll-publication-box {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 1rem;
    border: 1px solid rgba(22, 22, 26, 0.08);
    border-radius: 18px;
    background: linear-gradient(135deg, #fff, #fbf6f6);
}

.payroll-publication-box strong {
    display: block;
    font-size: 1.05rem;
}

.payroll-publish-form {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    flex-wrap: wrap;
    justify-content: flex-end;
}

.pdks-filter-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(150px, 1fr));
    gap: 0.75rem;
}

.pdks-explain-form {
    display: grid;
    grid-template-columns: minmax(170px, 1fr) auto;
    gap: 0.5rem;
    min-width: 260px;
}

.pdks-alert-row > * {
    background: rgba(184, 49, 53, 0.08) !important;
}

.pdks-link-input {
    min-width: 320px;
}

.employee-picker {
    border: 1px solid rgba(22, 22, 26, 0.1);
    border-radius: 22px;
    background: #fff;
    padding: 0.85rem;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.85);
}

.employee-picker-native {
    position: absolute;
    width: 1px;
    height: 1px;
    opacity: 0;
    pointer-events: none;
}

.employee-picker-search-wrap {
    margin-bottom: 0.7rem;
}

.employee-picker-results {
    display: grid;
    gap: 0.45rem;
    max-height: 220px;
    overflow: auto;
    padding-right: 0.25rem;
}

.employee-picker-result {
    width: 100%;
    border: 1px solid rgba(22, 22, 26, 0.08);
    border-radius: 15px;
    background: #fbfbfc;
    color: #17171d;
    padding: 0.62rem 0.72rem;
    text-align: left;
    transition: background 0.18s ease, border-color 0.18s ease, transform 0.18s ease;
}

.employee-picker-result:hover {
    background: #fff5f5;
    border-color: rgba(184, 49, 53, 0.22);
    transform: translateY(-1px);
}

.employee-picker-selected {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
    min-height: 38px;
    margin-top: 0.75rem;
    padding-top: 0.75rem;
    border-top: 1px solid rgba(22, 22, 26, 0.08);
}

.employee-picker-chip {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    border: 1px solid rgba(184, 49, 53, 0.2);
    border-radius: 999px;
    background: #fff2f2;
    color: #7f2429;
    padding: 0.35rem 0.6rem 0.35rem 0.75rem;
    font-size: 0.84rem;
    font-weight: 800;
}

.employee-picker-chip strong {
    display: grid;
    place-items: center;
    width: 20px;
    height: 20px;
    border-radius: 999px;
    background: rgba(184, 49, 53, 0.15);
}

.employee-picker-empty,
.employee-picker-no-result {
    color: #7a7d86;
    font-size: 0.9rem;
    padding: 0.45rem 0.2rem;
}

.pdks-kiosk-create-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1.25rem;
}

.pdks-kiosk-create-form {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(260px, 360px);
    gap: 1.25rem;
    align-items: stretch;
}

.pdks-kiosk-scope-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1rem;
}

.pdks-kiosk-name-panel {
    display: grid;
    align-content: end;
    gap: 0.75rem;
    padding: 1rem;
    border: 1px solid rgba(22, 22, 26, 0.08);
    border-radius: 24px;
    background: linear-gradient(135deg, #ffffff 0%, #fbf8f8 100%);
}

.pdks-kiosk-name-panel .form-label {
    text-align: right;
    margin-bottom: 0;
}

.pdks-kiosk-body {
    min-height: 100vh;
    background: linear-gradient(135deg, #ffffff 0%, #fbf7f7 50%, #f4f6f8 100%);
    color: #17171d;
    font-family: "Sora", sans-serif;
}

.pdks-kiosk-screen {
    min-height: 100vh;
    padding: clamp(1rem, 2vw, 2rem);
    display: grid;
    grid-template-rows: auto 1fr auto;
    gap: clamp(1rem, 2vw, 1.5rem);
}

.pdks-kiosk-brand {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 1rem 1.2rem;
    border-radius: 24px;
    background: #fff;
    border: 1px solid rgba(22, 22, 26, 0.08);
    box-shadow: 0 18px 45px rgba(25, 29, 39, 0.08);
}

.pdks-kiosk-brand img {
    width: min(240px, 42vw);
    max-height: 58px;
    object-fit: contain;
}

.pdks-kiosk-name-block {
    margin-left: auto;
    text-align: right;
}

.pdks-kiosk-brand span,
.pdks-kiosk-brand small {
    display: block;
    color: #6f727b;
}

.pdks-kiosk-brand strong {
    display: block;
    font-size: clamp(1.1rem, 1.8vw, 1.5rem);
}

.pdks-maintenance-card {
    width: min(760px, 100%);
    margin: auto;
    border: 1px solid rgba(184, 49, 53, 0.12);
    border-radius: 32px;
    background: #fff;
    padding: clamp(2rem, 5vw, 4rem);
    box-shadow: 0 30px 80px rgba(35, 31, 32, 0.12);
}

.pdks-maintenance-card h1 {
    margin: 0.65rem 0;
    font-size: clamp(2rem, 5vw, 4.2rem);
    line-height: 1;
}

.pdks-maintenance-card p {
    margin: 0;
    color: #6f727b;
    font-size: clamp(1rem, 1.4vw, 1.25rem);
}

.pdks-kiosk-grid {
    display: grid;
    grid-template-columns: minmax(320px, 1.05fr) minmax(320px, 0.95fr);
    gap: clamp(1rem, 2vw, 1.5rem);
    align-items: stretch;
}

.pdks-camera-card,
.pdks-result-card {
    border: 1px solid rgba(22, 22, 26, 0.08);
    border-radius: 32px;
    background: #fff;
    box-shadow: 0 24px 70px rgba(25, 29, 39, 0.11);
    overflow: hidden;
}

.pdks-camera-card {
    display: grid;
    grid-template-rows: 1fr;
}

.pdks-camera-frame {
    min-height: 58vh;
    position: relative;
    background: radial-gradient(circle at 30% 20%, rgba(184, 49, 53, 0.25), transparent 35%), #111217;
}

.pdks-camera-frame video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.pdks-scan-reticle {
    position: absolute;
    inset: 18%;
    border: 4px solid rgba(255, 255, 255, 0.85);
    border-radius: 28px;
    box-shadow: 0 0 0 999px rgba(0, 0, 0, 0.18);
}

.pdks-camera-status {
    position: absolute;
    left: 1rem;
    bottom: 1rem;
    z-index: 2;
    padding: 0.55rem 0.85rem;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.92);
    color: #17171d;
    font-size: 0.84rem;
    font-weight: 800;
    box-shadow: 0 14px 35px rgba(0, 0, 0, 0.18);
}

.pdks-camera-status-error {
    background: #fff0f1;
    color: #9d2b31;
}

.pdks-result-card {
    padding: clamp(1.5rem, 3vw, 3rem);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: flex-start;
    gap: 0.8rem;
}

.pdks-result-card h1 {
    font-size: clamp(2rem, 4vw, 4.6rem);
    line-height: 0.98;
    margin: 0;
}

.pdks-person-placeholder,
.pdks-person-photo {
    width: clamp(110px, 16vw, 180px);
    height: clamp(110px, 16vw, 180px);
    border-radius: 28px;
    display: grid;
    place-items: center;
    background: linear-gradient(135deg, #b83135, #7b2027);
    color: #fff;
    font-weight: 800;
    font-size: clamp(2rem, 4vw, 4rem);
    overflow: hidden;
}

.pdks-person-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.pdks-result-time {
    font-family: "IBM Plex Mono", monospace;
    font-size: clamp(2.2rem, 5vw, 5rem);
    font-weight: 700;
    color: #b83135;
}

.pdks-result-message {
    font-size: clamp(1.1rem, 2vw, 1.8rem);
}

.pdks-kiosk-alert {
    padding: 0.85rem 1rem;
    border-radius: 16px;
    background: rgba(184, 49, 53, 0.1);
    color: #8d252a;
    font-weight: 700;
}

.pdks-result-error {
    border-color: rgba(184, 49, 53, 0.28);
}

.pdks-kiosk-footer {
    display: flex;
    justify-content: center;
    gap: 1rem;
    color: #777b85;
    font-size: 0.88rem;
    padding: 0 0.5rem;
}

@media (max-width: 992px) {
    .payroll-publication-box,
    .pdks-kiosk-footer {
        align-items: flex-start;
        flex-direction: column;
    }

    .pdks-filter-grid,
    .pdks-kiosk-create-form,
    .pdks-kiosk-grid {
        grid-template-columns: 1fr;
    }

    .company-transfer-item {
        grid-template-columns: 1fr;
    }

    .pdks-kiosk-scope-grid {
        grid-template-columns: 1fr;
    }

    .pdks-kiosk-name-panel .form-label {
        text-align: left;
    }

    .pdks-camera-frame {
        min-height: 44vh;
    }
}

/* Overtime module and collapsible sidebar refinements */
.menu-nav {
    flex: 1 1 auto;
}

.sidebar-collapse-toggle {
    display: flex;
    align-items: center;
    gap: 0.72rem;
    width: 100%;
    min-height: 44px;
    margin-top: auto;
    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: 999px;
    color: #fff;
    background: rgba(255, 255, 255, 0.08);
    padding: 0.62rem 0.72rem;
    font-weight: 800;
    transition: background 0.18s ease, border-color 0.18s ease, transform 0.18s ease;
}

.sidebar-collapse-toggle:hover {
    background: rgba(191, 30, 46, 0.22);
    border-color: rgba(191, 30, 46, 0.42);
}

.sidebar-collapse-toggle .menu-icon svg {
    transition: transform 0.18s ease;
}

body.sidebar-collapsed .sidebar-collapse-toggle .menu-icon svg {
    transform: rotate(180deg);
}

body.sidebar-collapsed:not(.sidebar-peek) .app-shell {
    grid-template-columns: 86px 1fr;
}

body.sidebar-collapsed.sidebar-peek .app-shell {
    grid-template-columns: 280px 1fr;
}

.app-shell,
.app-sidebar,
.menu-link > span:not(.menu-icon),
.sidebar-collapse-toggle span,
.system-logo-card .brand-logo {
    transition: all 0.22s ease;
}

body.sidebar-collapsed:not(.sidebar-peek) .app-sidebar {
    padding-left: 0.75rem;
    padding-right: 0.75rem;
}

body.sidebar-collapsed:not(.sidebar-peek) .refined-brand {
    min-height: var(--app-topbar-height);
    margin-top: -1.25rem;
    margin-left: -0.75rem;
    margin-right: -0.75rem;
    padding: 0 0.65rem;
}

body.sidebar-collapsed:not(.sidebar-peek) .system-logo-card {
    justify-content: center;
    min-height: 54px;
    width: 54px;
    padding: 0.25rem;
    margin: 0 auto;
}

body.sidebar-collapsed:not(.sidebar-peek) .system-logo-card .brand-logo {
    width: 42px;
    max-height: 42px;
    object-fit: contain;
    object-position: center center;
}

body.sidebar-collapsed:not(.sidebar-peek) .menu-link,
body.sidebar-collapsed:not(.sidebar-peek) .sidebar-collapse-toggle {
    justify-content: center;
    padding-left: 0.6rem;
    padding-right: 0.6rem;
}

body.sidebar-collapsed:not(.sidebar-peek) .menu-link > span:not(.menu-icon),
body.sidebar-collapsed:not(.sidebar-peek) .sidebar-collapse-toggle span:last-child {
    opacity: 0;
    width: 0;
    max-width: 0;
    overflow: hidden;
    white-space: nowrap;
}

body.sidebar-collapsed:not(.sidebar-peek) .menu-link .menu-icon,
body.sidebar-collapsed:not(.sidebar-peek) .sidebar-collapse-toggle .menu-icon {
    opacity: 1;
    width: 22px;
    height: 22px;
    flex-basis: 22px;
}

.overtime-hero {
    background: linear-gradient(135deg, #fff 0%, #fff8f8 52%, #ffffff 100%);
}

.overtime-type-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
    gap: 0.75rem;
}

.overtime-type-card {
    border: 1px solid #eadfe2;
    border-radius: 16px;
    background: #fff;
    padding: 0.85rem;
    box-shadow: 0 10px 26px rgba(35, 31, 32, 0.06);
}

.overtime-type-card strong,
.overtime-rate-pill {
    display: inline-flex;
    align-items: center;
    border-radius: 999px;
    background: #fff0f1;
    color: var(--mbk-red);
    font-weight: 900;
    padding: 0.18rem 0.55rem;
    margin-bottom: 0.35rem;
}

.overtime-type-card span {
    display: block;
    color: var(--mbk-ink);
    font-weight: 800;
}

.overtime-type-card small {
    display: block;
    color: #6f6468;
    margin-top: 0.25rem;
}

.overtime-review-form {
    min-width: 180px;
}

@media (max-width: 991.98px) {
    body.sidebar-collapsed:not(.sidebar-peek) .app-shell,
    body.sidebar-collapsed.sidebar-peek .app-shell {
        grid-template-columns: 1fr;
    }
}

.tax-bracket-panel {
    border: 1px solid #eadfe2;
    border-radius: 18px;
    background:
        radial-gradient(circle at 100% 0%, rgba(191, 30, 46, 0.1), transparent 26%),
        linear-gradient(135deg, #ffffff 0%, #fff8f9 100%);
    padding: 1rem;
}

.tax-bracket-panel strong {
    display: block;
    color: var(--mbk-ink);
    font-weight: 950;
}

.tax-bracket-list {
    display: grid;
    gap: 0.48rem;
    margin-top: 0.8rem;
}

.tax-bracket-row {
    display: grid;
    grid-template-columns: 92px minmax(0, 1fr) 76px;
    gap: 0.6rem;
    align-items: center;
    border: 1px solid rgba(191, 30, 46, 0.12);
    border-radius: 13px;
    background: rgba(255, 255, 255, 0.88);
    padding: 0.55rem 0.65rem;
}

.tax-bracket-row span,
.tax-bracket-row em {
    color: var(--mbk-red);
    font-size: 0.76rem;
    font-style: normal;
    font-weight: 900;
}

.tax-bracket-row strong {
    min-width: 0;
    color: #332d2f;
    font-size: 0.84rem;
    font-weight: 850;
}

@media screen {
    .print-body .payslip-document,
    .print-body .certificate-page {
        width: min(210mm, calc(100vw - 32px));
    }

    .print-body .payslip-sheet,
    .print-body .certificate-sheet {
        width: 100%;
    }
}

@media print {
    html,
    body.print-body {
        width: 210mm !important;
        min-height: 297mm !important;
        margin: 0 !important;
        overflow: visible !important;
        background: #fff !important;
    }

    body.print-body {
        print-color-adjust: exact !important;
        -webkit-print-color-adjust: exact !important;
    }

    body.print-body .payslip-toolbar,
    body.print-body .print-actions,
    body.print-body .print-floating-button {
        display: none !important;
    }

    body.print-body .payslip-document,
    body.print-body .certificate-page {
        width: 210mm !important;
        min-height: 297mm !important;
        margin: 0 !important;
        padding: 0 !important;
        display: block !important;
        page: document-page;
    }

    body.print-body .payslip-sheet,
    body.print-body .certificate-sheet {
        width: 210mm !important;
        min-height: 297mm !important;
        margin: 0 !important;
        padding: 8mm !important;
        border: 0 !important;
        border-radius: 0 !important;
        box-shadow: none !important;
        break-after: page;
        box-sizing: border-box !important;
    }

    body.print-body .payslip-sheet {
        font-size: 9px !important;
        overflow: hidden !important;
    }

    body.print-body .payslip-header {
        grid-template-columns: minmax(0, 1fr) 48mm !important;
    }

    body.print-body .payslip-title-box strong {
        font-size: 12px !important;
    }

    body.print-body .payslip-info-grid,
    body.print-body .payslip-table-grid {
        gap: 0.38rem !important;
        margin: 0.42rem 0 !important;
    }

    body.print-body .payslip-info-grid > div,
    body.print-body .payslip-table-grid > section,
    body.print-body .payslip-sheet > section {
        padding: 0.42rem !important;
    }

    body.print-body .payslip-sheet .table > :not(caption) > * > * {
        padding: 0.16rem 0.24rem !important;
    }

    body.print-body .payslip-total-box {
        gap: 0.26rem !important;
        margin-top: 0.38rem !important;
    }

    body.print-body .payslip-signatures > div,
    body.print-body .certificate-signatures > div {
        min-height: 56px !important;
    }

    body.print-body .id-card-print-page {
        padding: 0 !important;
        display: block !important;
        page: id-card-page;
    }

    body.print-body .id-card-print-page.landscape-page {
        width: 8cm !important;
        min-height: 5cm !important;
        page: id-card-page;
    }

    body.print-body .id-card-print-page.portrait-page {
        width: 5cm !important;
        min-height: 8cm !important;
        page: id-card-page-portrait;
    }

    body.print-body .print-id-card {
        margin: 0 !important;
        box-shadow: none !important;
        border-radius: 0 !important;
    }
}

.system-update-grid.system-update-grid-single {
    grid-template-columns: minmax(0, 1fr);
}

.fleet-action-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1rem;
}

body,
.app-shell,
.app-main,
.app-content {
    min-width: 0;
}

@media (max-width: 1200px) {
    .fleet-action-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 991.98px) {
    html,
    body.app-body {
        width: 100%;
        max-width: 100%;
        overflow-x: hidden;
    }

    .app-shell {
        display: block;
        width: 100%;
        min-height: 100vh;
    }

    .app-main {
        width: 100%;
        min-height: 100vh;
    }

    .app-topbar {
        min-height: auto;
        align-items: stretch;
        gap: 0.75rem;
        padding: 0.75rem 0.85rem;
    }

    .topbar-title {
        min-width: 0;
        width: 100%;
    }

    .topbar-title .btn {
        margin-bottom: 0.45rem !important;
    }

    .smart-search {
        flex: 1 1 auto;
        width: 100%;
        max-width: none;
    }

    .topbar-right {
        width: 100%;
        justify-content: space-between;
    }

    .app-content.container-fluid {
        width: 100%;
        max-width: 100%;
        padding: 0.85rem !important;
        overflow-x: hidden;
    }

    .panel-card,
    .stat-card {
        border-radius: 16px;
        padding: 0.9rem;
    }

    .dashboard-grid,
    .fleet-alert-grid,
    .fleet-card-grid,
    .fleet-kpi-grid,
    .fleet-action-grid,
    .menu-card-grid,
    .employee-card-grid,
    .payroll-summary-grid {
        grid-template-columns: minmax(0, 1fr) !important;
    }

    .fleet-photo-frame,
    .fleet-photo-frame img {
        min-height: 180px;
    }

    .fleet-filter-bar,
    .employee-filter-bar,
    .payroll-filter-bar,
    .pdks-filter-grid,
    .pdks-kiosk-scope-grid {
        grid-template-columns: minmax(0, 1fr) !important;
        min-width: 0;
        width: 100%;
    }

    .table-responsive {
        max-width: 100%;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    .table {
        width: 100%;
    }

    .detail-list {
        grid-template-columns: minmax(0, 1fr) !important;
    }

    .app-footer {
        padding: 0.36rem 0.55rem;
        font-size: 0.68rem;
        line-height: 1.25;
    }
}

@media (max-width: 640px) {
    html {
        font-size: 13.25px;
    }

    .app-topbar {
        flex-direction: column;
    }

    .page-heading {
        font-size: 1rem;
        margin-bottom: 0 !important;
    }

    .notification-bell {
        width: 36px;
        height: 36px;
    }

    .user-chip {
        max-width: calc(100vw - 120px);
        overflow: hidden;
    }

    .user-chip > span:first-child {
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .company-chip {
        max-width: 100%;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .stat-card p {
        font-size: 1.45rem;
    }

    .fleet-plate-strip {
        align-items: flex-start;
        flex-direction: column;
    }
}

