:root {
    --ui-primary: #4f46e5;
    --ui-primary-hover: #4338ca;
    --ui-primary-soft: #eef2ff;
    --ui-success: #059669;
    --ui-warning: #d97706;
    --ui-danger: #dc2626;
    --ui-info: #0284c7;
    --ui-ink: #172033;
    --ui-text: #344054;
    --ui-muted: #667085;
    --ui-border: #e4e7ec;
    --ui-border-strong: #d0d5dd;
    --ui-canvas: #f5f7fa;
    --ui-surface: #ffffff;
    --ui-radius-sm: 8px;
    --ui-radius: 12px;
    --ui-radius-lg: 16px;
    --ui-shadow-sm: 0 1px 3px rgba(16, 24, 40, .06);
    --ui-shadow: 0 8px 24px rgba(16, 24, 40, .08);
    --ui-focus: 0 0 0 3px rgba(79, 70, 229, .14);
}

html { font-size: 16px; }

html,
body { max-width: 100%; }

img,
svg,
video,
canvas { max-width: 100%; }

.app-shell-main,
.app-scroll-area,
.content,
.content-wrapper { min-width: 0; }

.app-scroll-area { overflow-x: hidden; }

.container,
.container-fluid,
.row,
[class*="col-"] { min-width: 0; }

body.app-body {
    color: var(--ui-text);
    background: var(--ui-canvas) !important;
    font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

body.mobile-navigation-open { overflow: hidden !important; }

body.app-auth-body,
body.app-guest-body {
    min-height: 100vh;
    color: var(--ui-text);
    background: linear-gradient(145deg, #1e1b4b, #3730a3 52%, #4f46e5) fixed !important;
    font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.app-auth-body .right-col {
    min-height: 100vh;
    background: transparent !important;
}

.app-auth-body #login-form input,
.app-auth-body form input,
.app-auth-body form select,
.app-auth-body form textarea {
    width: 100%;
    border-color: var(--ui-border-strong) !important;
    border-radius: 9px !important;
    background: #fff !important;
}

.app-auth-body #login-form input:focus,
.app-auth-body form input:focus,
.app-auth-body form select:focus,
.app-auth-body form textarea:focus {
    border-color: var(--ui-primary) !important;
    box-shadow: var(--ui-focus) !important;
}

.app-auth-body #login-form button[type="submit"] {
    border-radius: 9px !important;
    background: var(--ui-primary) !important;
    box-shadow: 0 8px 18px rgba(79, 70, 229, .22);
}

.app-auth-body #login-form button[type="submit"]:hover { background: var(--ui-primary-hover) !important; }
.app-guest-body .container { padding-top: 18px; padding-bottom: 18px; }
.app-guest-body .container > .row > [class*="col-"] { border-radius: var(--ui-radius) !important; background: #fff; box-shadow: var(--ui-shadow); }

.app-shell-main,
.app-scroll-area { background: var(--ui-canvas) !important; }

.app-scroll-area {
    scroll-behavior: smooth;
    scrollbar-color: #cbd5e1 transparent;
    scrollbar-width: thin;
}

.app-scroll-area::-webkit-scrollbar { width: 8px; height: 8px; }
.app-scroll-area::-webkit-scrollbar-thumb { border: 2px solid transparent; border-radius: 999px; background: #cbd5e1; background-clip: padding-box; }

/* Application shell */
.app-topbar {
    min-height: 60px;
    border-color: rgba(255, 255, 255, .10) !important;
    background: linear-gradient(110deg, #312e81, #4338ca 55%, #4f46e5) !important;
    box-shadow: 0 1px 3px rgba(16, 24, 40, .12);
}

.pos-header {
    border-bottom: 1px solid var(--ui-border) !important;
    color: var(--ui-text);
    background: rgba(255, 255, 255, .97) !important;
    box-shadow: 0 1px 3px rgba(16, 24, 40, .06);
}

.app-topbar > div { max-width: 1920px; margin: 0 auto; }
.app-topbar button,
.app-topbar a { border-radius: var(--ui-radius-sm) !important; }

.app-sidebar {
    z-index: 40;
    width: 264px !important;
    border-right: 1px solid var(--ui-border);
    background: #fff !important;
    box-shadow: 4px 0 16px rgba(16, 24, 40, .035);
    transition: transform .22s ease, visibility .22s ease, box-shadow .22s ease;
}

.mobile-sidebar-close { display: none; }

.overlay {
    position: fixed;
    z-index: 1000;
    inset: 0;
    display: none;
    width: 100vw;
    height: 100vh;
    height: 100dvh;
    border: 0;
    background: rgba(15, 23, 42, .58);
    backdrop-filter: blur(2px);
}

.overlay.is-active { display: block !important; }

.app-sidebar-brand {
    min-height: 60px;
    border-color: rgba(255, 255, 255, .10) !important;
    background: #312e81 !important;
}

.app-sidebar-brand .side-bar-heading { font-size: 16px !important; font-weight: 750 !important; letter-spacing: -.015em; }
.app-sidebar .sidebar-menu { padding: 12px 10px 24px; background: #fff !important; }
.app-sidebar .sidebar-menu > li { margin: 2px 0; }
.app-sidebar .sidebar-menu > li > a,
.app-sidebar .treeview-menu > li > a {
    min-height: 42px;
    border: 0 !important;
    border-radius: 9px;
    color: #475467 !important;
    font-size: 13px;
    font-weight: 600;
    transition: color .15s ease, background .15s ease;
}

.app-sidebar .sidebar-menu > li > a { display: flex; align-items: center; padding: 10px 12px; }
.app-sidebar .sidebar-menu > li > a i { width: 20px; color: #667085; text-align: center; }
.app-sidebar .sidebar-menu > li:hover > a,
.app-sidebar .sidebar-menu > li.active > a,
.app-sidebar .sidebar-menu > li.menu-open > a {
    color: #3730a3 !important;
    background: var(--ui-primary-soft) !important;
}

.app-sidebar .sidebar-menu > li.active > a i,
.app-sidebar .sidebar-menu > li:hover > a i { color: var(--ui-primary); }
.app-sidebar .treeview-menu { margin: 3px 0 6px 15px; padding: 3px 0 3px 8px; border-left: 1px solid #e0e7ff; background: #fff !important; }
.app-sidebar .treeview-menu > li > a { min-height: 36px; padding: 8px 10px; font-size: 12px; }
.app-sidebar .treeview-menu > li.active > a,
.app-sidebar .treeview-menu > li > a:hover { color: #3730a3 !important; background: #f5f3ff !important; }

/* Page structure */
body:not(.lockscreen) .content-header {
    padding: 22px 24px 12px;
    background: transparent;
}

body:not(.lockscreen) .content-header h1 {
    margin: 0;
    color: var(--ui-ink) !important;
    font-size: clamp(1.35rem, 1.8vw, 1.9rem) !important;
    font-weight: 760 !important;
    line-height: 1.25;
    letter-spacing: -.025em;
}

body:not(.lockscreen) .content-header h1 small { color: var(--ui-muted) !important; font-size: .48em !important; }
body:not(.lockscreen) .content { padding: 12px 24px 32px; }
.breadcrumb { color: var(--ui-muted); background: transparent !important; font-size: 12px; }
.breadcrumb > li + li:before { color: #98a2b3; }

/* Surfaces and cards */
.box,
.box-solid,
.box-primary,
.box-widget,
.info-box,
.small-box,
.card {
    border: 1px solid var(--ui-border) !important;
    border-radius: var(--ui-radius) !important;
    background: var(--ui-surface);
    box-shadow: var(--ui-shadow-sm) !important;
}

.box:hover,
.info-box:hover { box-shadow: 0 4px 14px rgba(16, 24, 40, .08) !important; }
.box.box-primary { border-top-color: var(--ui-primary) !important; }
.box-header { padding: 15px 18px !important; border-bottom-color: var(--ui-border) !important; }
.box-header .box-title { color: var(--ui-ink); font-size: 15px; font-weight: 750; }
.box-body { padding: 18px !important; }
.box-footer { padding: 14px 18px !important; border-top: 1px solid var(--ui-border); border-radius: 0 0 var(--ui-radius) var(--ui-radius); background: #fcfcfd; }
.well { border: 1px solid var(--ui-border); border-radius: var(--ui-radius); background: #f9fafb; box-shadow: none; }
.panel { overflow: hidden; border-color: var(--ui-border); border-radius: var(--ui-radius); box-shadow: var(--ui-shadow-sm); }
.panel-heading { padding: 13px 16px; border-color: var(--ui-border) !important; color: var(--ui-ink) !important; background: #f8fafc !important; font-weight: 700; }

/* Forms */
label,
.control-label { color: #344054; font-size: 12px; font-weight: 700; }
.form-group { margin-bottom: 17px; }
.form-control,
.select2-container .select2-selection--single,
.select2-container .select2-selection--multiple {
    min-height: 42px;
    border: 1px solid var(--ui-border-strong) !important;
    border-radius: var(--ui-radius-sm) !important;
    color: var(--ui-ink);
    background: #fff;
    box-shadow: 0 1px 2px rgba(16, 24, 40, .025);
    transition: border-color .15s ease, box-shadow .15s ease;
}

.form-control:focus,
.select2-container--focus .select2-selection,
.select2-container--open .select2-selection {
    border-color: var(--ui-primary) !important;
    box-shadow: var(--ui-focus) !important;
    outline: none;
}

textarea.form-control { min-height: 92px; resize: vertical; }
.select2-container { max-width: 100%; }
.select2-container .select2-selection--single .select2-selection__rendered { padding-left: 11px; line-height: 40px; }
.select2-container .select2-selection--single .select2-selection__arrow { height: 40px; }
.select2-dropdown { overflow: hidden; border: 1px solid var(--ui-border-strong); border-radius: var(--ui-radius-sm); box-shadow: var(--ui-shadow); }
.select2-results__option { padding: 9px 11px; font-size: 13px; }
.select2-container--default .select2-results__option--highlighted[aria-selected] { color: #fff; background: var(--ui-primary); }
.input-group-addon { border-color: var(--ui-border-strong) !important; color: var(--ui-muted); background: #f9fafb !important; }
.input-group-btn .btn { min-height: 42px; border-color: var(--ui-border-strong); }
.help-block { margin-top: 6px; color: var(--ui-muted); font-size: 11px; }
.form-control[disabled],
.form-control[readonly],
fieldset[disabled] .form-control { color: #667085; background: #f2f4f7; }
.checkbox label,
.radio label { color: var(--ui-text); font-weight: 500; }

/* Buttons */
.btn,
.tw-dw-btn {
    border-radius: var(--ui-radius-sm) !important;
    font-weight: 700;
    transition: background .15s ease, border-color .15s ease, box-shadow .15s ease, transform .15s ease;
}

.btn:not(.btn-xs),
.tw-dw-btn:not(.tw-dw-btn-xs):not(.tw-dw-btn-sm) { min-height: 40px; }
.btn:hover,
.tw-dw-btn:hover { transform: translateY(-1px); }
.btn:active,
.tw-dw-btn:active { transform: translateY(0); }
.btn-primary,
.tw-dw-btn-primary { border-color: var(--ui-primary) !important; background: var(--ui-primary) !important; }
.btn-primary:hover,
.tw-dw-btn-primary:hover { border-color: var(--ui-primary-hover) !important; background: var(--ui-primary-hover) !important; }
.btn-success { border-color: var(--ui-success) !important; background: var(--ui-success) !important; }
.btn-danger { border-color: var(--ui-danger) !important; background: var(--ui-danger) !important; }
.btn-default { border-color: var(--ui-border-strong); color: #344054; background: #fff; }
.btn-default:hover { border-color: #98a2b3; color: var(--ui-ink); background: #f9fafb; }
.btn-group > .btn { margin-right: 1px; }

/* Tables and data grids */
.table-responsive {
    border: 0;
    border-radius: var(--ui-radius-sm);
    scrollbar-color: #cbd5e1 transparent;
    scrollbar-width: thin;
}

.table { margin-bottom: 14px; color: var(--ui-text); background: #fff; }
.table > thead > tr > th {
    padding: 11px 10px;
    border-top: 1px solid var(--ui-border) !important;
    border-bottom: 1px solid var(--ui-border-strong) !important;
    color: #475467;
    background: #f8fafc;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: .025em;
    text-transform: uppercase;
    vertical-align: middle;
}

.table > tbody > tr > td,
.table > tfoot > tr > td { padding: 10px; border-color: var(--ui-border) !important; vertical-align: middle; }
.table-striped > tbody > tr:nth-of-type(odd) { background: #fcfcfd; }
.table-hover > tbody > tr:hover { background: #f5f7ff; }
.table-bordered { border-color: var(--ui-border) !important; }
.table-bordered > thead > tr > th,
.table-bordered > tbody > tr > td { border-color: var(--ui-border) !important; }
.dataTables_wrapper .dataTables_filter input,
.dataTables_wrapper .dataTables_length select { min-height: 36px; border: 1px solid var(--ui-border-strong); border-radius: 7px; }
.dataTables_wrapper .dataTables_info { color: var(--ui-muted); font-size: 12px; }
.dataTables_processing { border: 1px solid var(--ui-border); border-radius: var(--ui-radius); background: rgba(255, 255, 255, .95); box-shadow: var(--ui-shadow); }

/* Navigation, tabs, pagination */
.nav-tabs { border-bottom: 1px solid var(--ui-border); }
.nav-tabs > li > a { margin-right: 4px; border: 0 !important; border-radius: 8px 8px 0 0; color: var(--ui-muted); font-size: 13px; font-weight: 700; }
.nav-tabs > li > a:hover { color: var(--ui-primary-hover); background: var(--ui-primary-soft); }
.nav-tabs > li.active > a,
.nav-tabs > li.active > a:focus,
.nav-tabs > li.active > a:hover { border-bottom: 2px solid var(--ui-primary) !important; color: var(--ui-primary-hover); background: #fff; }
.pagination > li > a,
.pagination > li > span { margin: 0 2px; border-color: var(--ui-border); border-radius: 7px !important; color: #475467; }
.pagination > .active > a,
.pagination > .active > span { border-color: var(--ui-primary); background: var(--ui-primary); }

/* Modals and dropdowns */
.modal-content { overflow: hidden; border: 0; border-radius: var(--ui-radius-lg); box-shadow: 0 24px 64px rgba(16, 24, 40, .24); }
.modal-header { padding: 17px 20px; border-bottom: 1px solid var(--ui-border); background: #fff; }
.modal-title { color: var(--ui-ink); font-size: 17px; font-weight: 760; }
.modal-body { padding: 20px; }
.modal-footer { padding: 14px 20px; border-top: 1px solid var(--ui-border); background: #f9fafb; }
.modal-backdrop.in { opacity: .45; }
.dropdown-menu { padding: 6px; border: 1px solid var(--ui-border); border-radius: 10px; box-shadow: var(--ui-shadow); }
.dropdown-menu > li > a { padding: 9px 11px; border-radius: 7px; color: #475467; font-size: 13px; }
.dropdown-menu > li > a:hover { color: #3730a3; background: var(--ui-primary-soft); }

/* Feedback and status */
.alert { border: 1px solid transparent; border-radius: var(--ui-radius); box-shadow: none; }
.alert-success { border-color: #a7f3d0; color: #065f46; background: #ecfdf5; }
.alert-warning { border-color: #fde68a; color: #92400e; background: #fffbeb; }
.alert-danger { border-color: #fecaca; color: #991b1b; background: #fef2f2; }
.alert-info { border-color: #bae6fd; color: #075985; background: #f0f9ff; }
.label { padding: .3em .55em; border-radius: 999px; font-size: 10px; font-weight: 750; }
.progress { overflow: hidden; height: 7px; border-radius: 999px; background: #eaecf0; box-shadow: none; }
.progress-bar { border-radius: 999px; box-shadow: none; }
.callout { border-radius: var(--ui-radius); }

/* Dashboard metrics */
.info-box { min-height: 104px; overflow: hidden; }
.info-box-icon { color: var(--ui-primary); background: var(--ui-primary-soft) !important; }
.info-box-text { color: var(--ui-muted); font-size: 12px; font-weight: 700; }
.info-box-number { color: var(--ui-ink); font-size: 21px; font-weight: 760; }
.small-box { overflow: hidden; color: var(--ui-ink) !important; background: #fff !important; }
.small-box > .inner { padding: 17px; }
.small-box h3 { color: var(--ui-ink); font-size: 25px; }
.small-box p { color: var(--ui-muted); }
.small-box .icon { color: rgba(79, 70, 229, .14); }

/* Utilities and footer */
.scrolltop { right: 18px; bottom: 18px; border-radius: 50%; background: var(--ui-primary); box-shadow: var(--ui-shadow); }
.scrolltop:hover { background: var(--ui-primary-hover); }
.app-scroll-area footer,
.app-scroll-area .main-footer { border-top: 1px solid var(--ui-border); color: var(--ui-muted); background: transparent; }
a { color: var(--ui-primary); }
a:hover { color: var(--ui-primary-hover); }
:focus-visible { outline: 2px solid var(--ui-primary); outline-offset: 2px; }

/* Responsive foundations */
@media (max-width: 1199px) {
    body:not(.lockscreen) .content-header { padding-left: 18px; padding-right: 18px; }
    body:not(.lockscreen) .content { padding-left: 18px; padding-right: 18px; }
    .box-body { padding: 16px !important; }
}

@media (max-width: 1023px) {
    .app-sidebar {
        position: fixed !important;
        z-index: 1001 !important;
        inset: 0 auto 0 0;
        display: flex !important;
        width: min(86vw, 288px) !important;
        height: 100vh !important;
        height: 100dvh !important;
        flex-direction: column;
        overflow: hidden;
        visibility: hidden;
        pointer-events: none;
        transform: translate3d(-105%, 0, 0);
        box-shadow: none;
    }
    [dir="rtl"] .app-sidebar { right: 0; left: auto; transform: translate3d(105%, 0, 0); }
    .app-sidebar.is-mobile-open { visibility: visible; pointer-events: auto; transform: translate3d(0, 0, 0); box-shadow: 16px 0 40px rgba(16, 24, 40, .24); }
    .app-sidebar-brand { position: relative; padding-right: 48px; padding-left: 14px; }
    .mobile-sidebar-close {
        position: absolute;
        z-index: 2;
        top: 11px;
        right: 10px;
        display: inline-flex;
        width: 38px;
        height: 38px;
        align-items: center;
        justify-content: center;
        border: 1px solid rgba(255, 255, 255, .25);
        border-radius: 9px;
        color: #fff;
        background: rgba(255, 255, 255, .12);
    }
    [dir="rtl"] .mobile-sidebar-close { right: auto; left: 10px; }
    .app-sidebar .sidebar-menu { flex: 1 1 auto; min-height: 0; overflow-x: hidden; overflow-y: auto; overscroll-behavior: contain; }
    .app-topbar { min-height: 58px; }
    .app-topbar > div { padding-left: 12px !important; padding-right: 12px !important; }
    .app-topbar > div > .tw-flex { align-items: center !important; gap: .5rem !important; }
    .app-topbar > div > .tw-flex > :last-child { min-width: 0; gap: .4rem !important; }
    .app-topbar details > ul { right: 0 !important; left: auto !important; max-width: calc(100vw - 24px); }
    .modal-dialog { width: calc(100% - 32px); margin: 20px auto; }
}

@media (max-width: 767px) {
    body.app-body { width: 100%; overflow: hidden !important; }
    .app-shell-main { width: 100%; max-width: 100vw; }
    .app-scroll-area { width: 100%; max-width: 100vw; overflow-x: hidden !important; overscroll-behavior: contain; }
    body:not(.lockscreen) .content-header { padding: 16px 12px 8px; }
    body:not(.lockscreen) .content { padding: 8px 12px 24px; }
    body:not(.lockscreen) .content-header h1 { display: flex; flex-direction: column; gap: 3px; overflow-wrap: anywhere; }
    body:not(.lockscreen) .content-header h1 small { display: block; margin: 0 !important; font-size: .72rem !important; line-height: 1.35; }
    .box,
    .box-solid,
    .box-primary,
    .box-widget,
    .card { margin-bottom: 12px; border-radius: 11px !important; }
    .box-header { display: flex; flex-wrap: wrap; align-items: center; gap: 9px; padding: 12px 14px !important; }
    .box-header::before,
    .box-header::after { display: none; }
    .box-header .box-title { min-width: 0; flex: 1 1 180px; line-height: 1.35; overflow-wrap: anywhere; }
    .box-header > .box-tools,
    .box-header .box-tools { position: static !important; top: auto !important; right: auto !important; float: none !important; display: flex; flex: 1 1 100%; flex-wrap: wrap; align-items: center; gap: 6px; margin: 0 !important; }
    .box-header .box-tools .btn,
    .box-header .box-tools .tw-dw-btn,
    .box-header .box-tools a { max-width: 100%; white-space: normal; }
    .box-body { padding: 14px !important; }
    .box-body > .row,
    .modal-body > .row,
    form > .row { margin-right: -7px; margin-left: -7px; }
    .box-body > .row > [class*="col-"],
    .modal-body > .row > [class*="col-"],
    form > .row > [class*="col-"] { padding-right: 7px; padding-left: 7px; }
    .form-group { margin-bottom: 14px; }
    .form-control,
    .select2-container .select2-selection--single { min-height: 44px; }
    .select2-container .select2-selection--single .select2-selection__rendered { line-height: 42px; }
    .select2-container .select2-selection--single .select2-selection__arrow { height: 42px; }
    .btn:not(.btn-xs),
    .tw-dw-btn:not(.tw-dw-btn-xs) { min-height: 42px; }
    .input-group,
    .select2-container { width: 100% !important; max-width: 100%; }
    .form-horizontal .control-label { padding-top: 0; text-align: left; }
    .table-responsive { position: relative; width: 100%; max-width: 100%; margin-bottom: 12px; overflow-x: auto !important; overflow-y: visible; -webkit-overflow-scrolling: touch; overscroll-behavior-inline: contain; }
    .table-responsive > .table { min-width: 720px; }
    .dataTables_wrapper { width: 100%; max-width: 100%; overflow: visible; }
    .dataTables_wrapper .dataTables_scroll,
    .dataTables_wrapper .dataTables_scrollHead,
    .dataTables_wrapper .dataTables_scrollBody { width: 100% !important; max-width: 100%; }
    .dataTables_wrapper .dataTables_scrollBody { overflow-x: auto !important; -webkit-overflow-scrolling: touch; }
    .dataTables_wrapper .row { margin-left: -5px; margin-right: -5px; }
    .dataTables_wrapper .row > [class*="col-"] { width: 100%; padding-right: 5px; padding-left: 5px; }
    .dataTables_filter,
    .dataTables_length { text-align: left !important; }
    .dataTables_filter label,
    .dataTables_length label { display: flex; width: 100%; flex-wrap: wrap; align-items: center; gap: 6px; }
    .dataTables_filter input { width: 100% !important; max-width: none; margin-left: 0 !important; }
    .dataTables_wrapper .dt-buttons { display: flex; float: none !important; width: 100%; flex-wrap: wrap; gap: 5px; margin: 7px 0; }
    .dataTables_wrapper .dt-buttons .btn { flex: 1 1 auto; margin: 0 !important; }
    .dataTables_wrapper .dataTables_info,
    .dataTables_wrapper .dataTables_paginate { float: none !important; width: 100%; text-align: left !important; }
    .dataTables_wrapper .dataTables_paginate { overflow-x: auto; padding-bottom: 4px; }
    .pagination { display: flex; width: max-content; min-width: 100%; flex-wrap: nowrap; }
    .nav-tabs,
    .nav-pills { display: flex; width: 100%; flex-wrap: nowrap; overflow-x: auto; overflow-y: hidden; scrollbar-width: thin; -webkit-overflow-scrolling: touch; }
    .nav-tabs > li,
    .nav-pills > li { float: none; flex: 0 0 auto; }
    .nav-tabs > li > a,
    .nav-pills > li > a { white-space: nowrap; }
    .tab-content { min-width: 0; }
    .modal { padding-right: 0 !important; }
    .modal-dialog { width: calc(100% - 16px); max-width: none; margin: 8px auto; }
    .modal-content { max-height: calc(100dvh - 16px); display: flex; flex-direction: column; border-radius: 12px; }
    .modal-header,
    .modal-footer { flex: 0 0 auto; padding: 13px 14px; }
    .modal-body { min-height: 0; max-height: none; flex: 1 1 auto; overflow-x: hidden; overflow-y: auto; padding: 14px; -webkit-overflow-scrolling: touch; }
    .modal-footer { display: flex; flex-wrap: wrap; gap: 6px; }
    .modal-footer::before,
    .modal-footer::after { display: none; }
    .modal-footer .btn { flex: 1 1 130px; margin: 0 !important; }
    .dropdown-menu { max-width: calc(100vw - 24px); }
    .dropdown-menu > li > a { white-space: normal; overflow-wrap: anywhere; }
    .alert { overflow-wrap: anywhere; }
    .fc-toolbar { display: flex; flex-wrap: wrap; gap: 7px; }
    .fc-toolbar > * { float: none !important; }
}

@media (max-width: 479px) {
    .app-topbar > div { padding: 8px !important; }
    .app-topbar .tw-gap-3 { gap: .3rem !important; }
    .app-topbar button,
    .app-topbar a,
    .app-topbar summary { min-width: 36px; min-height: 36px; }
    body:not(.lockscreen) .content-header h1 { font-size: 1.3rem !important; }
    body:not(.lockscreen) .content { padding-right: 8px; padding-left: 8px; }
    .box-body { padding: 12px !important; }
    .btn-group { display: flex; flex-wrap: wrap; gap: 4px; }
    .btn-group > .btn { flex: 1 1 auto; border-radius: 8px !important; }
    .box-footer { display: flex; flex-wrap: wrap; gap: 6px; padding: 12px !important; }
    .box-footer .btn { flex: 1 1 125px; margin: 0 !important; }
    .info-box { min-height: 88px; }
    .info-box-icon { width: 72px; font-size: 36px; line-height: 88px; }
    .info-box-content { margin-left: 72px; padding: 7px 9px; }
}

@media print {
    .app-topbar,
    .app-sidebar,
    .scrolltop,
    .no-print { display: none !important; }
    .app-scroll-area,
    .app-shell-main { overflow: visible !important; height: auto !important; background: #fff !important; }
    .box,
    .card { border-color: #ddd !important; box-shadow: none !important; }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; }
}
