/*
 * QMO ERP visual system
 * Progressive visual layer: it keeps BeyondAdmin's existing HTML and JS hooks
 * intact while presenting the application as a contemporary workspace.
 */
:root {
    --qmo-ink: #172038;
    --qmo-muted: #74809a;
    --qmo-surface: #ffffff;
    --qmo-canvas: #f5f7fb;
    --qmo-line: #e7eaf2;
    --qmo-primary: #6157d9;
    --qmo-primary-dark: #4036ad;
    --qmo-accent: #a59bfa;
    --qmo-shadow: 0 14px 32px rgba(23, 32, 56, .08);
}

body.qmo-app-shell {
    background: var(--qmo-canvas);
    color: var(--qmo-ink);
    font-family: "Inter", "Open Sans", "Segoe UI", Arial, sans-serif;
}

body.qmo-app-shell:before { background: var(--qmo-canvas); }

/* Application chrome */
.qmo-app-shell .navbar.qmo-topbar {
    height: 72px;
    min-height: 72px;
    background: rgba(255, 255, 255, .96);
    border-bottom: 1px solid var(--qmo-line);
    box-shadow: 0 1px 0 rgba(23, 32, 56, .02);
}

.qmo-app-shell .navbar.qmo-topbar .navbar-inner,
.qmo-app-shell .navbar.qmo-topbar .navbar-container {
    min-height: 72px;
    height: 72px;
    background: transparent;
}

.qmo-app-shell .navbar.qmo-topbar .navbar-header { height: 72px; }

.qmo-brand {
    align-items: center;
    color: var(--qmo-ink) !important;
    display: inline-flex !important;
    gap: 10px;
    height: 72px;
    min-width: 220px;
    padding: 0 26px !important;
    text-decoration: none !important;
}

.qmo-brand-mark {
    align-items: center;
    background: linear-gradient(135deg, #786ef3 0%, #4c43c2 56%, #29c6b4 57%, #8ce6d9 100%);
    border-radius: 10px;
    box-shadow: 0 7px 16px rgba(92, 82, 214, .25);
    color: #fff;
    display: inline-flex;
    font-size: 18px;
    font-weight: 800;
    height: 34px;
    justify-content: center;
    letter-spacing: -1px;
    width: 34px;
}

.qmo-brand-name {
    color: var(--qmo-ink);
    font-size: 19px;
    font-weight: 800;
    letter-spacing: -.55px;
    line-height: 1;
}

.qmo-brand-name small {
    color: var(--qmo-primary);
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 1.4px;
    margin-left: 3px;
    vertical-align: 2px;
}

.qmo-app-shell .qmo-menu-toggle {
    align-items: center;
    border-left: 1px solid var(--qmo-line);
    color: #66718c;
    cursor: pointer;
    display: flex;
    height: 72px;
    justify-content: center;
    transition: background .18s ease, color .18s ease;
    width: 64px;
}

.qmo-app-shell .qmo-menu-toggle:hover { background: #f7f7fd; color: var(--qmo-primary); }
.qmo-app-shell .qmo-menu-toggle .collapse-icon { font-size: 18px; }

.qmo-app-shell .navbar-account { height: 72px; }
.qmo-app-shell .navbar-account .account-area > li > .qmo-user-menu {
    align-items: center;
    color: var(--qmo-ink) !important;
    display: flex;
    height: 72px;
    padding: 0 25px 0 14px;
}

.qmo-app-shell .navbar-account .account-area > li > .qmo-user-menu:hover,
.qmo-app-shell .navbar-account .account-area > li.open > .qmo-user-menu {
    background: #f8f9fc !important;
}

.qmo-app-shell .navbar-account .account-area > li .avatar {
    border: 2px solid #edeaff;
    height: 38px;
    margin-right: 10px;
    width: 38px;
}

.qmo-app-shell .navbar-account .account-area > li .avatar img { height: 34px; width: 34px; }
.qmo-app-shell .navbar-account .account-area > li .login-area section { min-width: 112px; }
.qmo-app-shell .navbar-account .account-area > li .login-area section h2 { margin: 0; }
.qmo-app-shell .navbar-account .account-area > li .login-area section h2 span { color: var(--qmo-ink); font-size: 13px; font-weight: 700; }
.qmo-app-shell .dropdown-menu.dropdown-login-area { border: 1px solid var(--qmo-line); border-radius: 10px; box-shadow: var(--qmo-shadow); margin-top: 8px; overflow: hidden; }
.qmo-app-shell .dropdown-menu.dropdown-login-area > li > a { color: #4e5870; padding: 11px 16px; }
.qmo-app-shell .dropdown-menu.dropdown-login-area > li > a:hover { background: #f5f4ff; color: var(--qmo-primary); }

/* Sidebar */
.qmo-app-shell .page-container { background: var(--qmo-canvas); }
.qmo-app-shell .qmo-sidebar {
    background: #fff;
    border-right: 1px solid var(--qmo-line);
    box-shadow: none;
    padding: 20px 12px;
    top: 72px;
    width: 232px;
}

.qmo-app-shell .qmo-sidebar-caption {
    color: #a1a9ba;
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 1.15px;
    padding: 0 14px 11px;
}

.qmo-app-shell .page-sidebar .sidebar-menu { border: 0; margin: 0; }
.qmo-app-shell .page-sidebar .sidebar-menu > li { border: 0; margin: 2px 0; }
.qmo-app-shell .page-sidebar .sidebar-menu > li > a {
    border: 0 !important;
    border-radius: 8px;
    color: #5f6a82;
    font-size: 13px;
    font-weight: 600;
    min-height: 42px;
    padding: 11px 12px;
    transition: background .16s ease, color .16s ease;
}

.qmo-app-shell .page-sidebar .sidebar-menu > li > a:hover,
.qmo-app-shell .page-sidebar .sidebar-menu > li.open > a,
.qmo-app-shell .page-sidebar .sidebar-menu > li.active > a {
    background: #f0efff;
    color: var(--qmo-primary-dark);
}

.qmo-app-shell .page-sidebar .sidebar-menu > li > a:before { display: none; }
.qmo-app-shell .page-sidebar .sidebar-menu > li > a > .menu-icon,
.qmo-app-shell .page-sidebar .sidebar-menu > li > a > i:not(.menu-expand) {
    color: #8e96a9;
    font-size: 16px;
    margin-right: 12px;
    width: 18px;
}

.qmo-app-shell .page-sidebar .sidebar-menu > li > a:hover > .menu-icon,
.qmo-app-shell .page-sidebar .sidebar-menu > li > a:hover > i:not(.menu-expand),
.qmo-app-shell .page-sidebar .sidebar-menu > li.open > a > i { color: var(--qmo-primary); }
.qmo-app-shell .page-sidebar .sidebar-menu > li > a .menu-expand { color: #aeb5c3; font-size: 14px; }

.qmo-app-shell .page-sidebar .sidebar-menu .submenu {
    background: transparent;
    border: 0;
    box-shadow: none;
    padding: 3px 0 5px 13px;
}

.qmo-app-shell .page-sidebar .sidebar-menu .submenu > li { background: transparent; border: 0; }
.qmo-app-shell .page-sidebar .sidebar-menu .submenu > li > a {
    color: #788399;
    font-size: 12px;
    padding: 8px 12px 8px 29px;
}

.qmo-app-shell .page-sidebar .sidebar-menu .submenu > li > a:hover { color: var(--qmo-primary); }
.qmo-app-shell .page-sidebar.menu-compact { width: 56px; }

/* Workspace and data UI */
.qmo-app-shell .page-content { background: var(--qmo-canvas); margin-left: 232px; }
.qmo-app-shell .page-breadcrumbs {
    background: transparent;
    border: 0;
    box-shadow: none;
    min-height: 40px;
    padding: 16px 30px 0;
}

.qmo-app-shell .breadcrumb { background: transparent; margin: 0; padding: 0; }
.qmo-app-shell .breadcrumb > li,
.qmo-app-shell .breadcrumb > li > a { color: #8a93a5; font-size: 12px; }
.qmo-app-shell .breadcrumb > li.active { color: var(--qmo-primary); font-weight: 700; }
.qmo-app-shell .breadcrumb > li + li:before { color: #b8bfcc; }

.qmo-app-shell .qmo-page-header {
    background: transparent;
    border: 0;
    box-shadow: none;
    min-height: 80px;
    padding: 8px 30px 16px;
}

.qmo-app-shell .qmo-page-header .header-title h1 {
    color: var(--qmo-ink);
    font-size: 24px;
    font-weight: 750 !important;
    letter-spacing: -.55px;
    margin: 0;
}

.qmo-page-subtitle { color: var(--qmo-muted); font-size: 12px; margin-top: 3px; }
.qmo-app-shell .qmo-page-header .header-buttons { right: 30px; top: 15px; }
.qmo-app-shell .qmo-page-header .header-buttons a { border: 1px solid var(--qmo-line); border-radius: 8px; color: #8b95a7; height: 32px; line-height: 30px; margin-left: 7px; width: 32px; }
.qmo-app-shell .qmo-page-header .header-buttons a:hover { border-color: #d7d3ff; color: var(--qmo-primary); }
.qmo-app-shell .page-body { padding: 0 30px 32px; }

.qmo-app-shell .widget,
.qmo-app-shell .well,
.qmo-app-shell .panel,
.qmo-app-shell .databox {
    background: var(--qmo-surface);
    border: 1px solid var(--qmo-line);
    border-radius: 11px;
    box-shadow: var(--qmo-shadow);
}

.qmo-app-shell .widget { margin-bottom: 20px; overflow: hidden; }
.qmo-app-shell .widget-header {
    background: #fff;
    border-bottom: 1px solid var(--qmo-line);
    min-height: 52px;
    padding: 15px 18px;
}

.qmo-app-shell .widget-header > .widget-caption { color: var(--qmo-ink); font-size: 14px; font-weight: 750; line-height: 21px; }
.qmo-app-shell .widget-body { background: #fff; padding: 18px; }
.qmo-app-shell .qmo-document-source-card { margin-bottom: 18px; }
.qmo-app-shell .qmo-document-source-card .widget-body { padding: 0; }
.qmo-app-shell .qmo-document-source-card__content {
    display: flex;
    align-items: flex-end;
    justify-content: flex-start;
    flex-wrap: wrap;
    gap: 14px;
    padding: 18px;
}
.qmo-app-shell .qmo-document-source-card__tenant:empty { display: none; }
.qmo-app-shell .qmo-document-source-card__tenant,
.qmo-app-shell .qmo-document-source-card__action,
.qmo-app-shell .qmo-document-source-card__selected { flex: 0 1 300px; min-width: 250px; }
.qmo-app-shell .qmo-document-source-card__tenant .qmo-tenant-selector { margin: 0; }
.qmo-app-shell .qmo-document-source-card__action .btn { margin: 0; min-height: 34px; }
.qmo-app-shell .qmo-document-source-card__selected label { display: block; margin: 0 0 6px; }
.qmo-app-shell .qmo-document-source-card .panel-body.qmo-document-source-card__content { background: #fff; border: 0; }
.qmo-app-shell .well { padding: 18px; }

.qmo-app-shell .table-responsive,
.qmo-app-shell .table-scrollable { border: 1px solid var(--qmo-line); border-radius: 9px; }
.qmo-app-shell .table { background: #fff; margin-bottom: 0; }
.qmo-app-shell .table > thead > tr > th {
    background: #fafbfe;
    border-bottom: 1px solid var(--qmo-line) !important;
    color: #667187;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: .25px;
    padding: 12px 10px;
    text-transform: uppercase;
}

.qmo-app-shell .table > tbody > tr > td { border-top-color: #edf0f5; color: #48536a; padding: 11px 10px; vertical-align: middle; }
.qmo-app-shell .table-hover > tbody > tr:hover > td,
.qmo-app-shell .table-hover > tbody > tr:hover > th { background: #f7f6ff; }

.qmo-app-shell .form-control,
.qmo-app-shell .select2-container .select2-choice {
    border-color: #dfe3ed;
    border-radius: 7px;
    box-shadow: none;
    color: #313b53;
    min-height: 32px;
}

.qmo-app-shell .form-control:focus,
.qmo-app-shell .select2-container .select2-choice:focus { border-color: #9f98ef; box-shadow: 0 0 0 3px rgba(97, 87, 217, .11); }
.qmo-app-shell .btn { border-radius: 7px; font-weight: 700; text-shadow: none; transition: transform .15s ease, box-shadow .15s ease; }
.qmo-app-shell .btn:hover { transform: translateY(-1px); }
.qmo-app-shell .btn-primary,
.qmo-app-shell .btn-success { background: var(--qmo-primary); border-color: var(--qmo-primary); }
.qmo-app-shell .btn-primary:hover,
.qmo-app-shell .btn-success:hover { background: var(--qmo-primary-dark); border-color: var(--qmo-primary-dark); box-shadow: 0 7px 14px rgba(82, 72, 198, .2); }
.qmo-app-shell .btn-default { background: #fff; border-color: #dfe3ed; color: #59647a; }
.qmo-app-shell .btn-default:hover { background: #f7f7fc; border-color: #cfd4e0; color: var(--qmo-primary); }
.qmo-app-shell .modal-content { border: 0; border-radius: 12px; box-shadow: 0 20px 54px rgba(23, 32, 56, .22); overflow: hidden; }
.qmo-app-shell .modal-header { background: #fff; border-bottom: 1px solid var(--qmo-line); padding: 15px 20px; }
.qmo-app-shell .modal-header .modal-title { color: var(--qmo-ink); font-size: 18px; font-weight: 500; line-height: 26px; }
.qmo-app-shell .modal-header .close { color: #9ba4b4; font-size: 26px; line-height: 24px; opacity: 1; text-shadow: none; }
.qmo-app-shell .modal-header .close:hover { color: var(--qmo-primary-dark); }
.qmo-app-shell .modal-footer { background: #fafbfe; border-top: 1px solid var(--qmo-line); padding: 12px 20px; }
.qmo-app-shell .modal-footer,
.qmo-app-shell .modal-footer-mod {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 8px;
    padding: 14px 20px;
}
.qmo-app-shell .modal-footer-mod {
    background: #fafbfe;
    border-top: 1px solid var(--qmo-line);
    overflow: hidden;
}
.qmo-app-shell .modal-footer-mod > .col-md-6 {
    float: none;
    width: auto;
    padding: 0;
}
.qmo-app-shell .modal-footer .btn,
.qmo-app-shell .modal-footer-mod .btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 38px;
    padding: 0 16px !important;
    border-radius: 9px;
    font-size: 12px;
    line-height: 1;
}
.qmo-app-shell .modal-footer .qmo-modal-save,
.qmo-app-shell .modal-footer-mod .qmo-modal-save {
    border-color: var(--qmo-primary) !important;
    background: var(--qmo-primary) !important;
    color: #fff !important;
}
.qmo-app-shell .modal-footer .qmo-modal-cancel,
.qmo-app-shell .modal-footer-mod .qmo-modal-cancel {
    border-color: #dfe3ed !important;
    background: #fff !important;
    color: #59647a !important;
}
.qmo-app-shell .modal-footer .qmo-modal-cancel:hover,
.qmo-app-shell .modal-footer-mod .qmo-modal-cancel:hover { background: #f4f6fa !important; border-color: #cfd4e0 !important; }
.qmo-app-shell .qmo-new-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    min-height: 38px;
    padding: 0 15px !important;
    border-radius: 10px !important;
    box-shadow: none !important;
    font-size: 12px;
    font-weight: 750;
    line-height: 1;
    text-shadow: none;
}
.qmo-app-shell .qmo-new-button > i { margin: 0; font-size: 13px; }
.qmo-app-shell .nav-tabs { border-bottom-color: var(--qmo-line); }
.qmo-app-shell .nav-tabs > li > a { border-radius: 7px 7px 0 0; color: #6d778c; font-weight: 700; }
.qmo-app-shell .nav-tabs > li.active > a,
.qmo-app-shell .nav-tabs > li.active > a:hover,
.qmo-app-shell .nav-tabs > li.active > a:focus { border-top-color: var(--qmo-primary); color: var(--qmo-primary); }

/* Login */
body.qmo-login-page {
    background: #11152a;
    color: var(--qmo-ink);
    font-family: "Inter", "Open Sans", "Segoe UI", Arial, sans-serif;
    min-height: 100vh;
    padding: 0;
}

/* Reference-style workspace refinements. These overrides intentionally live
   after the base layer so legacy theme dimensions cannot add empty spacing. */
.qmo-app-shell .qmo-menu-toggle {
    appearance: none;
    background: transparent;
    border-bottom: 0;
    border-right: 1px solid var(--qmo-line);
    border-top: 0;
    padding: 0;
}

.qmo-app-shell .qmo-sidebar {
    overflow-x: hidden;
    padding: 8px 10px 18px !important;
    transition: transform .22s ease, width .22s ease;
}

.qmo-app-shell .page-sidebar .sidebar-menu,
.qmo-app-shell #menu_principal {
    margin: 0 !important;
    padding: 0 !important;
}

.qmo-app-shell .page-sidebar .sidebar-menu > li:first-child { margin-top: 0; }
.qmo-app-shell .page-sidebar .sidebar-menu > li > a { border-radius: 6px; min-height: 39px; padding: 10px 11px; }
.qmo-app-shell .page-sidebar .sidebar-menu .submenu { margin: 0; padding-top: 2px; }

.qmo-app-shell .qmo-content-card {
    background: #fff;
    border: 1px solid #eaedf3;
    border-radius: 10px;
    box-shadow: 0 12px 30px rgba(23, 32, 56, .055);
    min-height: 470px;
    padding: 22px;
}

.qmo-app-shell .page-body { padding-top: 2px; }
.qmo-app-shell .qmo-page-header { min-height: 70px; padding-bottom: 12px; }
.qmo-app-shell .qmo-page-header .header-title h1 { font-family: "Inter", "Open Sans", sans-serif; font-size: 23px; }
.qmo-app-shell .breadcrumb > li,
.qmo-app-shell .breadcrumb > li > a { font-family: "Inter", "Open Sans", sans-serif; font-size: 11px; }

.qmo-app-shell .qmo-content-card > .widget,
.qmo-app-shell .qmo-content-card > .well,
.qmo-app-shell .qmo-content-card > .panel { box-shadow: none; }

.qmo-app-shell .table-responsive,
.qmo-app-shell .table-scrollable { border: 0; border-radius: 0; }
.qmo-app-shell .table { border-collapse: separate; border-spacing: 0; font-family: "Inter", "Open Sans", sans-serif; }
.qmo-app-shell .table > thead > tr > th {
    background: #fbfcfe;
    border-bottom: 1px solid #e8ebf1 !important;
    border-top: 1px solid #e8ebf1;
    color: #6f788c;
    font-size: 10px;
    letter-spacing: .38px;
    padding: 13px 12px;
}

.qmo-app-shell .table > thead > tr > th:first-child { border-left: 1px solid #e8ebf1; border-radius: 7px 0 0 0; }
.qmo-app-shell .table > thead > tr > th:last-child { border-radius: 0 7px 0 0; border-right: 1px solid #e8ebf1; }
.qmo-app-shell .table > tbody > tr > td {
    border-bottom: 1px solid #edf0f4;
    border-right: 1px solid #edf0f4;
    border-top: 0;
    color: #4c566b;
    font-size: 12px;
    padding: 12px;
}

.qmo-app-shell .table > tbody > tr > td:first-child { border-left: 1px solid #edf0f4; }
.qmo-app-shell .table > tbody > tr:last-child > td:first-child { border-radius: 0 0 0 7px; }
.qmo-app-shell .table > tbody > tr:last-child > td:last-child { border-radius: 0 0 7px 0; }
.qmo-app-shell .table-hover > tbody > tr:hover > td { background: #f7f6ff; }
.qmo-app-shell .dataTables_wrapper .dataTables_filter input,
.qmo-app-shell .dataTables_wrapper .dataTables_length select { border: 1px solid #dfe4ee; border-radius: 6px; box-shadow: none; }
.qmo-app-shell .dataTables_wrapper .dataTables_filter label,
.qmo-app-shell .dataTables_wrapper .dataTables_length label,
.qmo-app-shell .dataTables_wrapper .dataTables_info { color: #7c8699; font-family: "Inter", "Open Sans", sans-serif; font-size: 11px; font-weight: 600; }
.qmo-app-shell .pagination > li > a { border-color: #e3e7ee; color: #6a63d3; font-family: "Inter", "Open Sans", sans-serif; }
.qmo-app-shell .pagination > .active > a,
.qmo-app-shell .pagination > .active > a:hover { background-color: #635bd7; border-color: #635bd7; }

.qmo-dashboard { padding: 0; }
.qmo-dashboard-heading { align-items: center; border-bottom: 1px solid #edf0f4; display: flex; justify-content: space-between; margin: -2px 0 20px; padding: 0 0 18px; }
.qmo-dashboard-eyebrow { color: #938ce8; font-family: "Inter", "Open Sans", sans-serif; font-size: 10px; font-weight: 800; letter-spacing: 1px; }
.qmo-dashboard-heading h2 { color: #202a40; font-family: "Inter", "Open Sans", sans-serif; font-size: 18px; font-weight: 800 !important; letter-spacing: -.35px; margin: 5px 0 0; }
.qmo-dashboard-period { background: #f4f3ff; border-radius: 20px; color: #6159c9; font-size: 11px; font-weight: 700; padding: 7px 10px; }
.qmo-dashboard-period i { margin-right: 5px; }
.qmo-dashboard-row { margin-left: -9px; margin-right: -9px; }
.qmo-dashboard-row > [class*="col-"] { padding-left: 9px; padding-right: 9px; }
.qmo-dashboard .qmo-dashboard-widget { border: 1px solid #e9ecf2; border-radius: 8px; box-shadow: none; margin-bottom: 18px; }
.qmo-dashboard .qmo-dashboard-widget .widget-header { border-bottom-color: #edf0f4; min-height: 47px; padding: 13px 15px; }
.qmo-dashboard .qmo-dashboard-widget .widget-caption { color: #4d5770; font-family: "Inter", "Open Sans", sans-serif; font-size: 12px; font-weight: 750; }
.qmo-dashboard .qmo-dashboard-widget .widget-caption i { color: #756de0; margin-right: 6px; }
.qmo-dashboard .qmo-dashboard-widget .widget-body { padding: 12px 15px 14px; }
.qmo-dashboard .chartcontainer { min-height: 255px; position: relative; }
.qmo-dashboard .chartcontainer canvas { max-height: 265px; }
.qmo-dashboard #stockCritico { overflow-x: auto; }
.qmo-dashboard .qmo-data-table { margin-bottom: 0; }

body.qmo-app-shell.qmo-sidebar-collapsed .qmo-menu-toggle { background: #f5f4ff; color: var(--qmo-primary); }

@media (max-width: 767px) {
    .qmo-app-shell .qmo-content-card { border: 0; border-radius: 0; box-shadow: none; margin-left: -18px; margin-right: -18px; padding: 18px; }
    .qmo-dashboard-heading { align-items: flex-start; flex-direction: column; gap: 10px; }
    .qmo-dashboard .chartcontainer { min-height: 215px; }
}

body.qmo-login-page:before { background: #11152a; }
.qmo-login-layout { display: flex; min-height: 100vh; overflow: hidden; }
.qmo-login-intro {
    background: linear-gradient(135deg, #151a36 0%, #24245a 55%, #443699 100%);
    color: #fff;
    display: flex;
    flex: 1 1 57%;
    flex-direction: column;
    justify-content: space-between;
    min-height: 100vh;
    overflow: hidden;
    padding: 54px 9%;
    position: relative;
}

.qmo-login-intro:after {
    background: linear-gradient(90deg, rgba(97, 87, 217, .15), transparent 46%);
    bottom: 0;
    content: "";
    left: 0;
    pointer-events: none;
    position: absolute;
    right: 0;
    top: 0;
}

.qmo-login-intro .qmo-login-brand { position: relative; z-index: 1; }
.qmo-login-intro .qmo-brand-name { color: #fff; }
.qmo-login-intro .qmo-brand-name small { color: #9cf0e5; }
.qmo-login-copy { max-width: 520px; position: relative; z-index: 1; }
.qmo-login-eyebrow { color: #9cf0e5; font-size: 11px; font-weight: 800; letter-spacing: 1.45px; }
.qmo-login-copy h1 { color: #fff; font-size: clamp(34px, 4.2vw, 54px); font-weight: 300 !important; letter-spacing: -1.7px; line-height: 1.14; margin: 18px 0; }
.qmo-login-copy h1 strong { color: #a29cff; font-weight: 800; }
.qmo-login-copy p { color: #d4d7f1; font-size: 16px; line-height: 1.75; max-width: 460px; }
.qmo-login-footer { color: #aeb3dd; font-size: 12px; position: relative; z-index: 1; }
.qmo-login-orb { border-radius: 50%; filter: blur(2px); opacity: .75; position: absolute; }
.qmo-login-orb-one { background: #5d50dc; height: 390px; right: -150px; top: -120px; width: 390px; }
.qmo-login-orb-two { background: #23c6b5; bottom: -180px; height: 350px; left: -130px; opacity: .28; width: 350px; }

.qmo-login-panel {
    align-items: center;
    background: #fbfcff;
    display: flex;
    flex: 0 1 520px;
    justify-content: center;
    min-height: 100vh;
    padding: 42px;
}

.qmo-login-card {
    background: transparent !important;
    box-shadow: none !important;
    margin: 0;
    max-width: 370px;
    padding: 0;
    width: 100%;
}

.qmo-login-card-header { align-items: center; display: flex; gap: 14px; margin-bottom: 36px; }
.qmo-login-icon { align-items: center; background: #efeeff; border-radius: 10px; color: var(--qmo-primary); display: flex; font-size: 17px; height: 43px; justify-content: center; width: 43px; }
.qmo-login-card .loginbox-title { color: var(--qmo-ink); font-size: 26px; font-weight: 800; letter-spacing: -.55px; line-height: 1.1; padding: 0; text-align: left; }
.qmo-login-card-header p { color: var(--qmo-muted); font-size: 12px; margin: 4px 0 0; }
.qmo-login-card .loginbox-textbox { margin: 0 0 19px; padding: 0; width: 100%; }
.qmo-input-group label { color: #566078; display: block; font-size: 12px; font-weight: 800; margin: 0 0 7px; }
.qmo-input-wrap { position: relative; }
.qmo-input-wrap > i { color: #9aa3b4; left: 15px; position: absolute; top: 14px; z-index: 1; }
.qmo-login-card .form-control { background: #fff; border: 1px solid #dfe3ed; border-radius: 8px; box-shadow: none; font-size: 13px; height: 45px; padding: 10px 13px 10px 42px; }
.qmo-login-card .form-control:focus { border-color: #938bec; box-shadow: 0 0 0 3px rgba(97, 87, 217, .12); }
.qmo-login-submit { margin-top: 28px; padding: 0; }
.qmo-login-card .btn-success { background: linear-gradient(135deg, #6b60e9, #4d43c5); border: 0; border-radius: 8px; box-shadow: 0 9px 18px rgba(76, 66, 193, .22); font-size: 13px; font-weight: 800; height: 46px; letter-spacing: .05px; text-transform: none; }
.qmo-login-card .btn-success:hover { background: linear-gradient(135deg, #5b50d4, #4035ae); box-shadow: 0 11px 21px rgba(76, 66, 193, .3); transform: translateY(-1px); }
.qmo-login-button { align-items: center; display: flex !important; justify-content: center; overflow: hidden; position: relative; transition: background .24s ease, box-shadow .24s ease, transform .24s ease; }
.qmo-login-button-label { display: inline-block; transition: opacity .18s ease, transform .18s ease; }
.qmo-login-button-spinner { align-items: center; display: flex; inset: 0; justify-content: center; opacity: 0; pointer-events: none; position: absolute; transform: scale(.65); transition: opacity .18s ease, transform .18s ease; }
.qmo-login-button-spinner i { animation: qmo-login-spinner .7s linear infinite; font-size: 16px; }
.qmo-login-button.is-loading { cursor: wait; }
.qmo-login-button.is-loading .qmo-login-button-label { opacity: 0; transform: translateY(-9px) scale(.96); }
.qmo-login-button.is-loading .qmo-login-button-spinner { opacity: 1; transform: scale(1); }
.qmo-login-button.is-success { background: linear-gradient(135deg, #20af72, #118b59) !important; box-shadow: 0 9px 18px rgba(17, 139, 89, .25) !important; cursor: default; animation: qmo-login-success .38s ease both; }
.qmo-login-button.is-returning { animation: qmo-login-button-return .28s ease both; }
.qmo-login-button[disabled] { opacity: 1; }
@keyframes qmo-login-spinner { to { transform: rotate(360deg); } }
@keyframes qmo-login-success { 0% { transform: scale(.98); } 55% { transform: scale(1.02); } 100% { transform: scale(1); } }
@keyframes qmo-login-button-return { 0% { transform: scale(.98); } 100% { transform: scale(1); } }
.qmo-login-help { color: #939caf; font-size: 11px; margin: 18px 0 0; text-align: center; }
.qmo-login-help i { color: var(--qmo-accent); margin-right: 3px; }

@media (prefers-reduced-motion: reduce) {
    .qmo-login-button,
    .qmo-login-button-label,
    .qmo-login-button-spinner { transition: none; }
    .qmo-login-button-spinner i,
    .qmo-login-button.is-success,
    .qmo-login-button.is-returning { animation: none; }
}

@media (max-width: 900px) {
    .qmo-login-intro { flex-basis: 48%; padding: 42px; }
    .qmo-login-panel { flex-basis: 52%; padding: 34px; }
    .qmo-login-copy p { font-size: 14px; }
}

@media (max-width: 767px) {
    .qmo-app-shell .navbar.qmo-topbar,
    .qmo-app-shell .navbar.qmo-topbar .navbar-inner,
    .qmo-app-shell .navbar.qmo-topbar .navbar-container,
    .qmo-app-shell .navbar.qmo-topbar .navbar-header { height: 60px; min-height: 60px; }
    .qmo-brand { height: 60px; min-width: 175px; padding: 0 15px !important; }
    .qmo-app-shell .qmo-menu-toggle { height: 60px; width: 51px; }
    .qmo-app-shell .navbar-account,
    .qmo-app-shell .navbar-account .account-area > li > .qmo-user-menu { height: 60px; }
    .qmo-app-shell .navbar-account .account-area > li .login-area section { display: none; }
    .qmo-app-shell .qmo-sidebar { top: 60px; }
    .qmo-app-shell .page-content { margin-left: 0; }
    .qmo-app-shell .page-breadcrumbs { padding-left: 18px; padding-right: 18px; }
    .qmo-app-shell .qmo-page-header { padding-left: 18px; padding-right: 18px; }
    .qmo-app-shell .page-body { padding-left: 18px; padding-right: 18px; }
    .qmo-app-shell .qmo-page-header .header-buttons { display: none; }
    .qmo-login-layout { display: block; }
    .qmo-login-intro { min-height: 280px; padding: 35px 28px; }
    .qmo-login-copy { margin-top: 46px; }
    .qmo-login-copy h1 { font-size: 31px; margin: 12px 0; }
    .qmo-login-copy p,
    .qmo-login-footer { display: none; }
    .qmo-login-panel { min-height: calc(100vh - 280px); padding: 42px 28px; }
}

@media (max-width: 400px) {
    .qmo-brand-name { font-size: 17px; }
    .qmo-brand { min-width: 148px; }
    .qmo-login-panel { padding: 35px 22px; }
}

/* Native shell: isolated from the theme's navbar, avatar and header-button rules. */
:root { --qmo-topbar-height: 72px; --qmo-sidebar-width: 248px; --qmo-sidebar-collapsed-width: 68px; }
.qmo-icon { width: 20px; height: 20px; display: inline-block; flex: 0 0 auto; vertical-align: middle; color: inherit; }
.qmo-app-shell .qmo-topbar { height: var(--qmo-topbar-height); display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 0 28px 0 0; position: sticky; top: 0; z-index: 1040; background: #fff; border-bottom: 1px solid var(--qmo-line); }
.qmo-topbar-start { display: flex; align-items: center; height: 100%; }
.qmo-topbar .qmo-brand { min-width: var(--qmo-sidebar-width); height: 100%; padding: 0 25px !important; }
.qmo-brand-mark { background: linear-gradient(135deg, #786ef3, #4d43c5); }
.qmo-app-shell .qmo-topbar .qmo-menu-toggle { display: inline-flex; align-items: center; justify-content: center; width: 38px; height: 38px; border: 1px solid var(--qmo-line); border-radius: 10px; color: #68728a; background: #fff; padding: 0; }
.qmo-icon-button { appearance: none; display: inline-flex; align-items: center; justify-content: center; width: 38px; height: 38px; padding: 0; background: #fff; color: #68728a; border: 1px solid var(--qmo-line); border-radius: 10px; cursor: pointer; transition: color .15s, border-color .15s, background .15s; }
.qmo-app-shell .qmo-icon-button:hover, .qmo-app-shell .qmo-menu-toggle:hover { color: var(--qmo-primary); background: #f4f2ff; border-color: #d8d3fb; }
.qmo-icon-button:focus-visible, .qmo-user-menu:focus-visible, .qmo-sidebar a:focus-visible { outline: 3px solid #c9c1ff; outline-offset: 3px; }
.qmo-icon-button:disabled { cursor: wait; opacity: .65; }
.qmo-account { position: relative; flex: 0 1 auto; min-width: 0; }
.qmo-user-menu { border: 0; background: transparent; display: flex; align-items: center; gap: 11px; padding: 7px 9px; border-radius: 12px; color: var(--qmo-ink); text-align: left; cursor: pointer; max-width: 420px; }
.qmo-user-menu:hover, .qmo-account.open .qmo-user-menu { background: #f7f6fd; }
.qmo-user-avatar { display: flex; align-items: center; justify-content: center; flex: 0 0 38px; width: 38px; height: 38px; border-radius: 50%; background: var(--qmo-primary); color: #fff; font-size: 13px; letter-spacing: .3px; font-weight: 750; }
.qmo-user-details { display: flex; flex-direction: column; min-width: 0; gap: 3px; }
.qmo-user-name { color: var(--qmo-ink); font-size: 13px; font-weight: 700; line-height: 18px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.qmo-user-role { color: var(--qmo-muted); font-size: 11px; line-height: 15px; }
.qmo-user-menu > .qmo-icon { color: #8b93a4; width: 16px; height: 16px; margin-left: 7px; }
.qmo-account-dropdown { border: 1px solid var(--qmo-line); border-radius: 12px; padding: 6px; margin-top: 7px; min-width: 230px; box-shadow: var(--qmo-shadow); }
.qmo-account-dropdown > li > a, .qmo-account-dropdown > li > button, .qmo-account-dropdown form > button { display: flex; align-items: center; gap: 10px; width: 100%; text-align: left; padding: 11px 12px; border: 0; border-radius: 7px; background: transparent; color: #4e5870; font-size: 13px; font-weight: 500; line-height: 20px; cursor: pointer; text-decoration: none; }
.qmo-account-dropdown > li > a:hover, .qmo-account-dropdown > li > button:hover, .qmo-account-dropdown form > button:hover { color: var(--qmo-primary-dark); background: #f4f2ff; }
.qmo-account-dropdown .qmo-icon { width: 18px; height: 18px; }
.qmo-app-shell .main-container { padding: 0; }
.qmo-app-shell .page-container { min-height: calc(100vh - var(--qmo-topbar-height)); }
.qmo-app-shell .page-sidebar.qmo-sidebar { position: fixed; top: var(--qmo-topbar-height); bottom: 0; left: 0; width: var(--qmo-sidebar-width); overflow-y: auto; display: block !important; padding: 23px 12px !important; z-index: 1030; border-right: 1px solid var(--qmo-line); }
.qmo-app-shell .page-content.qmo-page-content { margin-left: var(--qmo-sidebar-width); min-height: calc(100vh - var(--qmo-topbar-height)); }
.qmo-app-shell .qmo-sidebar-caption { font-size: 10px; letter-spacing: 1px; padding: 0 12px 14px; color: #929bb0; }
.qmo-app-shell .qmo-sidebar .sidebar-menu > li > a { display: flex; align-items: center; gap: 12px; padding: 11px 12px; line-height: 20px; min-height: 42px; height: auto; }
.qmo-app-shell .qmo-sidebar .sidebar-menu > li > a > .menu-icon { width: 19px; min-width: 19px; height: 19px; margin: 0; color: #929bb0; }
.qmo-app-shell .qmo-sidebar .sidebar-menu .qmo-menu-chevron { margin-left: auto; width: 14px; height: 14px; color: #9aa3b7; transition: transform .15s; }
.qmo-app-shell .qmo-sidebar .sidebar-menu li.open > a > .qmo-menu-chevron { transform: rotate(90deg); }
.qmo-app-shell .qmo-sidebar .sidebar-menu li.active > a > .menu-icon { color: var(--qmo-primary); }
.qmo-app-shell .qmo-sidebar .sidebar-menu .submenu > li > a { display: flex; align-items: center; gap: 8px; padding: 9px 12px 9px 24px; line-height: 18px; height: auto; }
.qmo-menu-status { margin: 12px; color: var(--qmo-muted); font-size: 12px; line-height: 1.7; }
.qmo-text-button { border: 0; padding: 0; color: var(--qmo-primary); text-decoration: underline; background: transparent; cursor: pointer; font: inherit; }
.qmo-app-shell .qmo-page-header { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 86px; padding: 12px 30px 18px; }
.qmo-app-shell .qmo-page-header .header-title { float: none; display: block; padding: 0; height: auto; line-height: normal; }
.qmo-app-shell .qmo-page-header .header-title h1 { line-height: 1.3; }
.qmo-page-actions { display: flex; align-items: center; gap: 9px; flex: 0 0 auto; }
.qmo-app-shell .breadcrumb .qmo-icon { width: 15px; height: 15px; margin-right: 6px; vertical-align: -3px; }
.qmo-app-shell .page-body { padding: 0 30px 30px; }
.qmo-app-shell .qmo-content-card { padding: 24px; min-height: 470px; }
#divCuerpo[aria-busy="true"] { opacity: .55; transition: opacity .15s; pointer-events: none; }
.qmo-empty-state { text-align: center; padding: 64px 20px; color: var(--qmo-muted); }
.qmo-empty-state > .qmo-icon { color: var(--qmo-primary); width: 32px; height: 32px; }
.qmo-empty-state h3 { color: var(--qmo-ink); font-size: 18px; }
.qmo-app-shell .btn-info { background: var(--qmo-primary) !important; border-color: var(--qmo-primary) !important; }
.qmo-app-shell .btn-info:hover { background: var(--qmo-primary-dark) !important; border-color: var(--qmo-primary-dark) !important; }
.qmo-app-shell .progress-bar-success, .qmo-app-shell .progress-bar-info { background-color: var(--qmo-primary); }
.qmo-app-shell .loading-container { position: fixed; z-index: 2100; inset: 0; display: flex; width: 100vw; height: 100vh; height: 100dvh; margin: 0; align-items: center; justify-content: center; overflow: hidden; background: linear-gradient(135deg, #6b60e9, #4d43c5); }
.qmo-loading-content { display: flex; min-height: 0; margin: 0; flex-direction: column; align-items: center; justify-content: center; gap: 20px; color: #eeeaff; font-size: 13px; text-align: center; }
.qmo-loading-brand { display: flex; align-items: center; justify-content: center; font-size: 38px; font-weight: 800; width: 78px; height: 78px; border: 1px solid #a59af5; border-radius: 22px; color: #fff; background: rgba(255,255,255,.1); }
.qmo-app-shell .loading-container .loader { width: 34px; height: 34px; border: 4px solid rgba(255,255,255,.22); border-top-color: #fff; background: transparent; border-radius: 50%; margin: 0; left: auto; flex: 0 0 auto; animation: qmo-spin .8s linear infinite; box-shadow: none; }
.qmo-app-shell .loading-container .loader::before, .qmo-app-shell .loading-container .loader::after { display: none; }
.qmo-app-shell .loading-container.loading-inactive { display: none; }
.qmo-app-shell .qmo-password-help { margin: 0 0 18px; color: var(--qmo-muted); font-size: 12px; line-height: 1.55; }
.qmo-app-shell .qmo-password-dialog { width: 440px; max-width: calc(100% - 30px); }
.qmo-app-shell #qmo-password-feedback { margin: 0 0 16px; padding: 10px 12px; font-size: 12px; line-height: 1.45; }
.qmo-app-shell #qmo-password-feedback[hidden] { display: none; }
.qmo-app-shell .qmo-password-confirmation { margin-bottom: 0; }
.is-refreshing .qmo-icon { animation: qmo-spin .8s linear infinite; }
@keyframes qmo-spin { to { transform: rotate(360deg); } }
.qmo-login-eyebrow, .qmo-login-intro .qmo-brand-name small { color: #c9c1ff; }
.qmo-login-orb-two { background: #8b7cf8; }
.qmo-dashboard-stats { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 15px; margin-bottom: 24px; }
.qmo-platform-dashboard .qmo-dashboard-stats { grid-template-columns: repeat(4,minmax(0,1fr)); }
.qmo-stat { padding: 18px; border: 1px solid var(--qmo-line); border-radius: 10px; position: relative; background: #fff; min-height: 112px; }
.qmo-stat > .qmo-icon { color: var(--qmo-primary); width: 19px; height: 19px; position: absolute; right: 17px; top: 18px; }
.qmo-stat-label { display: block; color: #7c859a; font-size: 11px; font-weight: 600; margin-bottom: 13px; padding-right: 22px; }
.qmo-stat-value { font-size: 23px; font-weight: 750; letter-spacing: -.7px; color: #29324b; line-height: 1.2; }
.qmo-dashboard-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 20px; }
.qmo-dashboard-activity-grid { grid-template-columns: repeat(3,minmax(0,1fr)); }
.qmo-dashboard-panel { border: 1px solid var(--qmo-line); border-radius: 10px; padding: 20px; min-width: 0; background: #fff; }
.qmo-dashboard-panel h3 { font: 650 13px/20px Inter,Arial,sans-serif; color: #4e5870; margin: 0 0 5px; display: flex; gap: 9px; align-items: center; }
.qmo-dashboard-panel h3 > .qmo-icon { color: var(--qmo-primary); width: 18px; height: 18px; }
.qmo-chart-hint { font-size: 11px; color: #929bb0; margin-bottom: 19px; }
.qmo-dashboard-panel .chartcontainer { min-height: 245px; position: relative; }
.qmo-dashboard-panel canvas { max-height: 245px; }
.qmo-dashboard-stock { margin-top: 20px; }
.qmo-dashboard-secondary-grid { margin-top: 20px; }
.qmo-dashboard-platform-table { margin-top: 20px; }
.qmo-platform-status { display: inline-flex; align-items: center; border-radius: 999px; font-size: 11px; font-weight: 700; padding: 4px 8px; }
.qmo-platform-status--active { background: #e8f7ef; color: #16764b; }
.qmo-platform-status--suspended { background: #fff0ec; color: #b7462c; }
.qmo-panel-status { color: var(--qmo-muted); font-size: 12px; line-height: 1.8; padding: 10px 0; }
.qmo-panel-status:empty { display: none; }
.qmo-dashboard-period { display: inline-flex; align-items: center; gap: 6px; }
.qmo-dashboard-period .qmo-icon { width: 15px; height: 15px; }
@media (max-width: 1100px) { .qmo-dashboard-stats, .qmo-platform-dashboard .qmo-dashboard-stats { grid-template-columns: repeat(2,minmax(0,1fr)); } }
@media (max-width: 1200px) { .qmo-dashboard-activity-grid { grid-template-columns: repeat(2,minmax(0,1fr)); } }
@media (max-width: 767px) {
    :root { --qmo-topbar-height: 64px; }
    .qmo-app-shell .qmo-topbar { padding-right: 12px; gap: 8px; }
    .qmo-topbar .qmo-brand { min-width: auto; padding: 0 15px !important; }
    .qmo-topbar .qmo-brand-name { font-size: 17px; }
    .qmo-user-details, .qmo-user-menu > .qmo-icon { display: none; }
    .qmo-user-menu { padding: 4px; }
    .qmo-app-shell .qmo-sidebar { box-shadow: 12px 0 28px rgba(23,32,56,.12); }
    .qmo-app-shell .page-content.qmo-page-content { margin-left: 0; }
    .qmo-app-shell .qmo-page-header { padding: 12px 18px 18px; }
    .qmo-app-shell .page-body { padding: 0 18px 24px; }
    .qmo-app-shell .qmo-content-card { padding: 18px; margin: 0; border: 1px solid var(--qmo-line); border-radius: 10px; }
    .qmo-dashboard-grid { grid-template-columns: minmax(0,1fr); }
}
@media (max-width: 420px) { .qmo-dashboard-stats { grid-template-columns: minmax(0,1fr); } .qmo-topbar .qmo-brand small { display: none; } }
@media (prefers-reduced-motion: reduce) { .qmo-app-shell *, .qmo-app-shell *::before, .qmo-app-shell *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; } }

/* The legacy theme declares a narrower sidebar with !important.  Keep the
   rail and workspace on exactly the same measured edge, including padding. */
.qmo-app-shell .page-sidebar.qmo-sidebar {
    box-sizing: border-box !important;
    width: var(--qmo-sidebar-width) !important;
}
.qmo-app-shell .page-content.qmo-page-content { margin-left: var(--qmo-sidebar-width) !important; }
.qmo-app-shell .qmo-sidebar .sidebar-menu,
.qmo-app-shell .qmo-sidebar .sidebar-menu > li,
.qmo-app-shell .qmo-sidebar .sidebar-menu > li > a {
    box-sizing: border-box;
    max-width: 100%;
}
.qmo-app-shell .qmo-sidebar .sidebar-menu > li > a { overflow: hidden; }
@media (max-width: 767px) {
    .qmo-app-shell .page-content.qmo-page-content { margin-left: 0 !important; }
}

/* Application shell does not use the legacy .page-sidebar/.page-content
   classes. BeyondAdmin fixes those at 224px and adds pseudo-elements, which
   created a gap and let selected entries overflow the rail. */
.qmo-app-shell .qmo-shell { min-height: calc(100vh - var(--qmo-topbar-height)); }
.qmo-app-shell #sidebar.qmo-sidebar {
    box-sizing: border-box !important;
    position: fixed !important;
    top: var(--qmo-topbar-height) !important;
    bottom: 0 !important;
    left: 0 !important;
    width: var(--qmo-sidebar-width) !important;
    margin: 0 !important;
    padding: 23px 12px !important;
    overflow-x: hidden !important;
    overflow-y: auto !important;
    background: #fff !important;
    border-right: 1px solid var(--qmo-line) !important;
    z-index: 1030;
    transition: width .2s ease, padding .2s ease;
}
.qmo-app-shell .qmo-page-content {
    box-sizing: border-box;
    display: block;
    min-height: calc(100vh - var(--qmo-topbar-height));
    margin: 0 0 0 var(--qmo-sidebar-width) !important;
    background: var(--qmo-canvas);
    transition: margin-left .2s ease;
}
.qmo-app-shell #menu_principal,
.qmo-app-shell #menu_principal li,
.qmo-app-shell #menu_principal a {
    box-sizing: border-box;
    max-width: 100%;
}
.qmo-app-shell #menu_principal { width: 100%; overflow: hidden; }
.qmo-app-shell #menu_principal li { list-style: none; position: relative; }
.qmo-app-shell #menu_principal li::before,
.qmo-app-shell #menu_principal li::after,
.qmo-app-shell #menu_principal a::before,
.qmo-app-shell #menu_principal a::after { content: none !important; display: none !important; }
.qmo-app-shell #menu_principal > li { margin: 2px 0; width: 100%; }
.qmo-app-shell #menu_principal > li > a {
    display: flex;
    align-items: center;
    width: 100%;
    min-height: 42px;
    padding: 11px 12px;
    overflow: hidden;
    border: 0 !important;
    border-radius: 8px;
    color: #5f6a82;
    font-size: 13px;
    font-weight: 600;
    line-height: 20px;
    text-decoration: none;
}
.qmo-app-shell #menu_principal > li:hover > a,
.qmo-app-shell #menu_principal > li.open > a,
.qmo-app-shell #menu_principal > li.active > a { background: #f0efff !important; color: var(--qmo-primary-dark) !important; }
.qmo-app-shell #menu_principal > li > a > .menu-icon { flex: 0 0 19px; width: 19px; height: 19px; margin: 0 12px 0 0; color: #929bb0; }
.qmo-app-shell #menu_principal > li.active > a > .menu-icon { color: var(--qmo-primary); }
.qmo-app-shell #menu_principal .menu-text { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.qmo-app-shell #menu_principal .qmo-menu-chevron { flex: 0 0 14px; margin-left: auto; }
.qmo-app-shell #menu_principal > li > .submenu {
    display: none;
    width: 100%;
    margin: 0;
    padding: 3px 0 5px 13px;
    overflow: hidden;
    background: transparent;
    border: 0;
    box-shadow: none;
}
.qmo-app-shell #menu_principal li.open > .submenu { display: block; }
.qmo-app-shell #menu_principal .submenu > li > a { display: flex; width: 100%; padding: 9px 12px 9px 24px; color: #788399; font-size: 12px; line-height: 18px; text-decoration: none; }
.qmo-app-shell #menu_principal .submenu > li.active > a,
.qmo-app-shell #menu_principal .submenu > li > a:hover { color: var(--qmo-primary-dark); background: #f7f6ff; }

/* Keep the menu available as an icon rail.  The previous state translated the
   sidebar out of view, leaving the workspace and navigation out of sync. */
body.qmo-app-shell.qmo-sidebar-collapsed #sidebar.qmo-sidebar {
    transform: none !important;
    width: var(--qmo-sidebar-collapsed-width) !important;
    padding: 18px 9px !important;
}
body.qmo-app-shell.qmo-sidebar-collapsed .qmo-page-content {
    margin-left: var(--qmo-sidebar-collapsed-width) !important;
}
body.qmo-app-shell.qmo-sidebar-collapsed .qmo-topbar .qmo-brand {
    min-width: var(--qmo-sidebar-collapsed-width);
    width: var(--qmo-sidebar-collapsed-width);
    padding: 0 10px !important;
}
body.qmo-app-shell.qmo-sidebar-collapsed .qmo-brand-name { font-size: 18px; }
body.qmo-app-shell.qmo-sidebar-collapsed .qmo-brand-name small,
body.qmo-app-shell.qmo-sidebar-collapsed .qmo-sidebar-caption,
body.qmo-app-shell.qmo-sidebar-collapsed .qmo-menu-status,
body.qmo-app-shell.qmo-sidebar-collapsed #menu_principal .menu-text,
body.qmo-app-shell.qmo-sidebar-collapsed #menu_principal .qmo-menu-chevron,
body.qmo-app-shell.qmo-sidebar-collapsed #menu_principal .submenu { display: none !important; }
body.qmo-app-shell.qmo-sidebar-collapsed #menu_principal > li > a {
    justify-content: center;
    padding: 11px;
}
body.qmo-app-shell.qmo-sidebar-collapsed #menu_principal > li > a > .menu-icon {
    margin: 0;
}

/* Shared DataTables presentation for every legacy screen. */
.qmo-app-shell .qmo-content-card .dataTables_wrapper { padding-top: 2px; }
.qmo-app-shell .qmo-content-card .dataTables_filter label { margin: 0 0 14px; }
.qmo-app-shell .qmo-content-card .dataTables_filter label::before { display: none; }
.qmo-app-shell .qmo-content-card .dataTables_filter input {
    width: 250px;
    height: 36px;
    margin: 0;
    padding: 8px 12px 8px 36px;
    border: 1px solid #dfe3ed;
    border-radius: 9px;
    color: var(--qmo-ink);
    background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%236157d9' stroke-width='2' stroke-linecap='round'%3E%3Ccircle cx='11' cy='11' r='6'/%3E%3Cpath d='m16 16 4 4'/%3E%3C/svg%3E") no-repeat 12px center;
    box-shadow: none;
}
.qmo-app-shell .qmo-content-card .dataTables_filter input:focus { border-color: #9f98ef; box-shadow: 0 0 0 3px rgba(97,87,217,.12); outline: 0; }
.qmo-app-shell .qmo-content-card .dataTables_length select { width: auto; height: 36px; border: 1px solid #dfe3ed; border-radius: 8px; background: #fff; color: #4e5870; font-weight: 600; }
.qmo-app-shell .qmo-content-card .DTTTFooter { display: flex; align-items: center; min-height: 48px; margin: 0; padding: 7px 10px; border: 1px solid var(--qmo-line); border-top: 0; border-radius: 0 0 9px 9px; background: #fafbfe; }
.qmo-app-shell .qmo-content-card .DTTTFooter .row { width: 100%; margin: 0; }
.qmo-app-shell .qmo-content-card .dataTables_info { padding-top: 7px; color: #68748c; font-size: 12px; }
.qmo-app-shell .qmo-content-card .dataTables_paginate { margin: 0; }
.qmo-app-shell .qmo-content-card .pagination { display: flex; margin: 0; }
.qmo-app-shell .qmo-content-card .pagination > li > a { min-width: 34px; height: 32px; padding: 7px 10px; border-color: #e0e4ed; color: var(--qmo-primary); background: #fff; text-align: center; line-height: 16px; }
.qmo-app-shell .qmo-content-card .pagination > .active > a,
.qmo-app-shell .qmo-content-card .pagination > .active > a:hover,
.qmo-app-shell .qmo-content-card .pagination > .active > a:focus { color: #fff !important; background: var(--qmo-primary) !important; border-color: var(--qmo-primary) !important; }
.qmo-app-shell .qmo-content-card .pagination > .disabled > a { color: #a7afbe; background: #f7f8fb; }
.qmo-app-shell .qmo-content-card .btn.btn-success:not(.icon-only) { border-color: var(--qmo-primary); background: var(--qmo-primary); box-shadow: 0 5px 12px rgba(97,87,217,.2); }
.qmo-app-shell .qmo-content-card .btn.btn-success:not(.icon-only):hover { border-color: var(--qmo-primary-dark); background: var(--qmo-primary-dark); }
.qmo-app-shell .qmo-content-card table.dataTable td:last-child .btn,
.qmo-app-shell .qmo-content-card table.dataTable td:last-child .btn.icon-only {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 29px;
    height: 29px;
    min-width: 29px;
    margin: 1px 2px;
    padding: 0;
    border-radius: 8px;
    line-height: 1;
}
.qmo-app-shell .qmo-content-card table.dataTable td:last-child .btn > i { margin: 0; font-size: 13px; }

@media (max-width: 767px) {
    .qmo-app-shell .qmo-page-content { margin-left: 0 !important; }
    .qmo-app-shell .qmo-content-card .dataTables_filter input { width: 100%; }
    .qmo-app-shell .qmo-content-card .DTTTFooter { display: block; }
}

/* Keep the workspace on one canvas: BeyondAdmin otherwise paints .page-body
   with a second grey below and beside every content card. */
.qmo-app-shell,
.qmo-app-shell .main-container,
.qmo-app-shell .qmo-shell,
.qmo-app-shell .qmo-page-content,
.qmo-app-shell .page-body { background: var(--qmo-canvas) !important; }
.qmo-app-shell .page-body { min-height: calc(100vh - 176px); }

/* Default action-button sizing, based on the compact "Nuevo" button. */
.qmo-app-shell .btn:not(.icon-only) {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    min-height: 38px;
    padding: 0 15px !important;
    border-radius: 10px !important;
    box-shadow: none !important;
    font-size: 12px;
    font-weight: 750;
    line-height: 1;
    text-shadow: none;
}
.qmo-app-shell .qmo-content-card .btn.btn-success:not(.icon-only):hover,
.qmo-app-shell .qmo-content-card .btn.btn-success:not(.icon-only):focus { background: var(--qmo-primary-dark) !important; box-shadow: none !important; transform: none !important; }
.qmo-app-shell .qmo-content-card .btn.btn-success:not(.icon-only) > i { margin: 0; font-size: 13px; }
.qmo-app-shell .qmo-content-card .table > tbody > tr > td { padding: 7px 10px !important; line-height: 18px; }
.qmo-app-shell .qmo-content-card .table > thead > tr > th { padding: 10px !important; }
.qmo-app-shell .qmo-content-card table.dataTable td:last-child .btn,
.qmo-app-shell .qmo-content-card table.dataTable td:last-child .btn.icon-only {
    width: 30px;
    height: 30px;
    margin: 1px 3px;
    border: 1px solid #ded9ff !important;
    border-radius: 9px;
    background: #f2f0ff !important;
    box-shadow: none !important;
    color: #574bca !important;
}
.qmo-app-shell .qmo-content-card table.dataTable td:last-child .btn:hover { background: #e6e2ff !important; border-color: #c6beff !important; color: #4036ad !important; transform: translateY(-1px); }
.qmo-app-shell .qmo-content-card table.dataTable td:last-child .btn.btn-danger { border-color: #ffd8dd !important; background: #fff1f3 !important; color: #d92d3d !important; }
.qmo-app-shell .qmo-content-card table.dataTable td:last-child .btn.btn-danger:hover { border-color: #ffb9c2 !important; background: #ffe5e9 !important; color: #b42332 !important; }
.qmo-app-shell .qmo-content-card table.dataTable th:last-child,
.qmo-app-shell .qmo-content-card table.dataTable td:last-child {
    width: 84px !important;
    min-width: 84px !important;
    white-space: nowrap !important;
    text-align: center;
}
.qmo-app-shell .qmo-content-card table.dataTable td:last-child .btn { vertical-align: middle; }
.qmo-app-shell .qmo-content-card #tablaCheques th:last-child,
.qmo-app-shell .qmo-content-card #tablaCheques td:last-child { width: 205px !important; min-width: 205px !important; }
.qmo-app-shell .qmo-content-card #tablaCheques td:last-child .btn.qmo-mark-paid {
    width: auto;
    min-width: auto;
    height: 30px;
    min-height: 30px;
    margin: 1px 3px;
    padding: 0 10px !important;
    white-space: nowrap;
}

/* Binary catalog fields share one accessible, optimistic switch control. */
.qmo-app-shell .qmo-state-switch {
    display: inline-flex;
    position: relative;
    width: 38px;
    height: 22px;
    margin: 0;
    vertical-align: middle;
    cursor: pointer;
}
.qmo-app-shell .qmo-state-switch__input {
    position: absolute;
    width: 1px;
    height: 1px;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}
.qmo-app-shell .qmo-state-switch__track {
    position: relative;
    width: 38px;
    height: 22px;
    border-radius: 999px;
    background: #d8ddea;
    box-shadow: inset 0 0 0 1px rgba(45, 56, 80, .12);
    transition: background .18s ease, box-shadow .18s ease;
}
.qmo-app-shell .qmo-state-switch__track::after {
    position: absolute;
    top: 3px;
    left: 3px;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: #fff;
    box-shadow: 0 1px 3px rgba(23, 32, 56, .24);
    content: '';
    transition: transform .18s ease;
}
.qmo-app-shell .qmo-state-switch__input:checked + .qmo-state-switch__track { background: var(--qmo-primary); }
.qmo-app-shell .qmo-state-switch__input:checked + .qmo-state-switch__track::after { transform: translateX(16px); }
.qmo-app-shell .qmo-state-switch__input:focus + .qmo-state-switch__track { box-shadow: 0 0 0 3px rgba(97, 87, 217, .22); }
.qmo-app-shell .qmo-state-switch__input:disabled + .qmo-state-switch__track { cursor: wait; opacity: .65; }
.qmo-app-shell .qmo-boolean-setting,
.qmo-app-shell .qmo-config-module {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-height: 28px;
}
.qmo-app-shell .qmo-boolean-setting__label,
.qmo-app-shell .qmo-config-module__label {
    color: var(--qmo-ink);
    font-size: 12px;
    font-weight: 650;
}
.qmo-app-shell .qmo-config-module { margin: 1px 0 5px; }
.qmo-app-shell .qmo-email-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    min-height: 4px;
    margin-top: 8px;
}
.qmo-app-shell .qmo-email-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    max-width: 100%;
    padding: 4px 7px 4px 9px;
    border: 1px solid #d9d5ff;
    border-radius: 999px;
    background: #f0efff;
    color: var(--qmo-primary-dark);
    font-size: 11px;
    font-weight: 700;
}
.qmo-app-shell .qmo-email-badge > span { overflow: hidden; text-overflow: ellipsis; }
.qmo-app-shell .qmo-email-badge__remove {
    width: 17px;
    height: 17px;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: transparent;
    color: inherit;
    font-size: 16px;
    line-height: 15px;
}
.qmo-app-shell .qmo-email-badge__remove:hover,
.qmo-app-shell .qmo-email-badge__remove:focus { background: #d9d5ff; outline: 0; }
.qmo-app-shell .qmo-tenants__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    margin-bottom: 20px;
}
.qmo-app-shell .qmo-tenants__header h2 { margin: 0 0 5px; color: var(--qmo-ink); font-size: 20px; font-weight: 800; }
.qmo-app-shell .qmo-tenants__header p { margin: 0; color: var(--qmo-muted); font-size: 13px; }
.qmo-app-shell .qmo-tenants__table th { font-size: 11px; letter-spacing: .04em; text-transform: uppercase; }
.qmo-app-shell .qmo-tenants__actions { white-space: nowrap; }
.qmo-app-shell .qmo-tenants__actions .btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    margin: 1px 3px;
    border: 1px solid #ded9ff !important;
    border-radius: 9px;
    background: #f2f0ff !important;
    box-shadow: none !important;
    color: #574bca !important;
}
.qmo-app-shell .qmo-tenants__actions .btn:hover,
.qmo-app-shell .qmo-tenants__actions .btn:focus { background: #e6e2ff !important; border-color: #c6beff !important; color: #4036ad !important; transform: translateY(-1px); }
.qmo-app-shell .qmo-tenants__actions .btn.btn-danger { border-color: #ffd8dd !important; background: #fff1f3 !important; color: #d92d3d !important; }
.qmo-app-shell .qmo-tenants__actions .btn.btn-danger:hover,
.qmo-app-shell .qmo-tenants__actions .btn.btn-danger:focus { border-color: #ffb9c2 !important; background: #ffe5e9 !important; color: #b42332 !important; }
.qmo-app-shell .qmo-tenants__actions .btn.btn-info { border-color: #c9e8ff !important; background: #eef8ff !important; color: #1671b9 !important; }
.qmo-app-shell .qmo-tenants__actions .btn.btn-info:hover,
.qmo-app-shell .qmo-tenants__actions .btn.btn-info:focus { border-color: #9bd4ff !important; background: #def1ff !important; color: #095991 !important; }
.qmo-app-shell .qmo-tenant-selector--fixed .form-control[disabled] { background: #f7f8fc; border-color: #dfe3ed; color: var(--qmo-ink); cursor: default; opacity: 1; }
.qmo-app-shell .qmo-tenant-selector__help { display: block; margin-top: 5px; color: var(--qmo-muted); font-size: 11px; }
.qmo-app-shell .qmo-tenant-configuration-selector {
    display: flex;
    align-items: end;
    gap: 12px;
    margin: 0 0 14px;
    padding: 12px 14px;
    border: 1px solid #dcd8ff;
    border-radius: 10px;
    background: #f8f7ff;
}
.qmo-app-shell .qmo-tenant-configuration-selector label { margin: 0; color: var(--qmo-ink); font-size: 12px; font-weight: 800; }
.qmo-app-shell .qmo-tenant-configuration-selector select { width: min(330px, 100%); }
.qmo-app-shell .qmo-tenant-configuration-selector small { color: var(--qmo-muted); font-size: 11px; }
.qmo-app-shell .qmo-config-modules__help { margin: -2px 0 10px; color: var(--qmo-muted); font-size: 12px; }
.qmo-app-shell .qmo-config-modules {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
    gap: 8px;
}
.qmo-app-shell .qmo-config-modules .qmo-config-module {
    min-height: 44px;
    margin: 0;
    padding: 8px 10px;
    border: 1px solid #e4e7ef;
    border-radius: 8px;
    background: #fbfcfe;
}
.qmo-app-shell .qmo-config-modules .qmo-config-module:hover { border-color: #cbc5fb; background: #f7f6ff; }
.qmo-app-shell .qmo-tenant-state { display: flex; align-items: center; gap: 9px; color: var(--qmo-ink); font-size: 13px; font-weight: 650; }
.qmo-app-shell .qmo-tenant-wizard {
    display: flex;
    gap: 0;
    margin: 0 0 22px;
    padding: 0;
    list-style: none;
}
.qmo-app-shell .qmo-tenant-wizard__item {
    position: relative;
    display: flex;
    flex: 1;
    align-items: center;
    gap: 9px;
    min-width: 0;
    color: var(--qmo-muted);
}
.qmo-app-shell .qmo-tenant-wizard__item:not(:last-child)::after {
    position: absolute;
    top: 17px;
    right: 12px;
    left: 43px;
    height: 2px;
    background: #e2e6ef;
    content: '';
}
.qmo-app-shell .qmo-tenant-wizard__item > span {
    position: relative;
    z-index: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    border: 1px solid #d8dde8;
    border-radius: 50%;
    background: #fff;
    font-size: 13px;
    font-weight: 800;
}
.qmo-app-shell .qmo-tenant-wizard__item strong,
.qmo-app-shell .qmo-tenant-wizard__item small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.qmo-app-shell .qmo-tenant-wizard__item strong { color: inherit; font-size: 12px; }
.qmo-app-shell .qmo-tenant-wizard__item small { margin-top: 1px; font-size: 10px; }
.qmo-app-shell .qmo-tenant-wizard__item.is-active { color: var(--qmo-primary-dark); }
.qmo-app-shell .qmo-tenant-wizard__item.is-active > span { border-color: var(--qmo-primary); background: var(--qmo-primary); color: #fff; box-shadow: 0 3px 8px rgba(97, 87, 217, .25); }
.qmo-app-shell .qmo-tenant-wizard__item.is-complete:not(:last-child)::after { background: var(--qmo-primary); }
.qmo-app-shell .qmo-tenant-wizard__organization { margin-bottom: 4px; }
.qmo-app-shell .qmo-tenant-logo-drop {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-height: 126px;
    padding: 12px;
    border: 2px dashed #cfc9fb;
    border-radius: 10px;
    background: #faf9ff;
    color: var(--qmo-primary-dark);
    cursor: pointer;
    transition: border-color .16s ease, background .16s ease, box-shadow .16s ease;
}
.qmo-app-shell .qmo-tenant-logo-drop:hover,
.qmo-app-shell .qmo-tenant-logo-drop:focus,
.qmo-app-shell .qmo-tenant-logo-drop.is-dragover { border-color: var(--qmo-primary); background: #f2f0ff; box-shadow: 0 0 0 3px rgba(97, 87, 217, .16); outline: 0; }
.qmo-app-shell .qmo-tenant-logo-drop__empty { display: flex; flex-direction: column; align-items: center; gap: 4px; }
.qmo-app-shell .qmo-tenant-logo-drop__empty i { margin-bottom: 2px; font-size: 22px; }
.qmo-app-shell .qmo-tenant-logo-drop__empty strong { font-size: 12px; }
.qmo-app-shell .qmo-tenant-logo-drop__empty small { color: var(--qmo-muted); font-size: 11px; }
.qmo-app-shell .qmo-tenant-logo-drop__preview { display: block; max-width: 100%; max-height: 100px; object-fit: contain; }
.qmo-app-shell .qmo-tenant-logo-drop__preview[hidden],
.qmo-app-shell .qmo-tenant-logo-remove[hidden],
.qmo-app-shell .modal-footer #qmo-tenant-previous[hidden],
.qmo-app-shell .modal-footer #qmo-tenant-next[hidden],
.qmo-app-shell .modal-footer #qmo-tenant-save[hidden] { display: none !important; }
.qmo-app-shell .qmo-tenant-logo-drop.has-preview .qmo-tenant-logo-drop__empty { display: none; }
.qmo-app-shell .qmo-tenant-logo-remove { margin: 8px 0 0; color: #8f3040; }
.qmo-app-shell .qmo-tenant-wizard__intro { margin: -3px 0 18px; color: var(--qmo-muted); font-size: 12px; }
.qmo-app-shell .qmo-tenant-admin-role__value {
    display: flex;
    align-items: center;
    gap: 8px;
    min-height: 38px;
    padding: 9px 11px;
    border: 1px solid #d9d5ff;
    border-radius: 8px;
    background: #f6f5ff;
    color: var(--qmo-primary-dark);
    font-size: 13px;
    font-weight: 800;
}
.qmo-app-shell .qmo-tenant-admin-role__value span { margin-left: auto; color: var(--qmo-muted); font-size: 11px; font-weight: 500; }
@media (max-width: 640px) {
    .qmo-app-shell .qmo-tenants__header { align-items: flex-start; flex-direction: column; }
    .qmo-app-shell .qmo-tenant-configuration-selector { align-items: stretch; flex-direction: column; }
    .qmo-app-shell .qmo-config-modules { grid-template-columns: 1fr; }
    .qmo-app-shell .qmo-tenant-wizard__item small { display: none; }
    .qmo-app-shell .qmo-tenant-wizard__item:not(:last-child)::after { right: 6px; }
    .qmo-app-shell .qmo-tenant-admin-role__value { align-items: flex-start; flex-wrap: wrap; }
    .qmo-app-shell .qmo-tenant-admin-role__value span { width: 100%; margin-left: 24px; }
}
.qmo-app-shell .qmo-state-field-hidden { display: none !important; }
.qmo-app-shell #tabla_permisos td { vertical-align: middle; }
.qmo-app-shell .qmo-permission-item { display: inline-flex; align-items: center; gap: 8px; min-height: 38px; margin: 3px 16px 3px 0; }
.qmo-app-shell .qmo-permission-item--module { margin-right: 0; }
.qmo-app-shell .qmo-permission-item__label { color: var(--qmo-ink); font-size: 12px; font-weight: 650; }
.qmo-app-shell .qmo-permission-item--module .qmo-permission-item__label { font-weight: 800; }
.qmo-app-shell table.qmo-table-reloading { visibility: hidden; }
.qmo-app-shell .qmo-money-field .input-group-addon,
.qmo-app-shell .qmo-percent-field .input-group-addon {
    min-width: 34px;
    border-color: #dfe4ee;
    background: #f5f4ff;
    color: var(--qmo-primary-dark);
    font-weight: 800;
}
.qmo-app-shell .qmo-money-field .form-control,
.qmo-app-shell .qmo-percent-field .form-control { text-align: right; }
.qmo-app-shell .qmo-rut-copy {
    display: inline-flex;
    align-items: center;
    max-width: 100%;
    white-space: nowrap;
    vertical-align: middle;
}
.qmo-app-shell .qmo-rut-value { display: inline-block; overflow: hidden; text-overflow: ellipsis; vertical-align: middle; }
.qmo-app-shell .qmo-copy-rut {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    margin-left: 6px;
    padding: 0;
    border: 0;
    border-radius: 5px;
    background: #f0efff;
    color: var(--qmo-primary);
    vertical-align: middle;
}
.qmo-app-shell .qmo-copy-rut:hover,
.qmo-app-shell .qmo-copy-rut:focus { background: #ddd9ff; color: var(--qmo-primary-dark); outline: 0; }
/* Los selectores de activación Sí/No no forman parte del alta. Esta regla se
   aplica antes de abrir el modal, evitando el destello inicial del campo. */
.qmo-app-shell .modal label:has(+ [class*="col-"] > select[id*="_activo"]:not(#periodo_activo)),
.qmo-app-shell .modal label:has(+ [class*="col-"] > select[id$="_activa"]),
.qmo-app-shell .modal label:has(+ [class*="col-"] > select#usuario_estado),
.qmo-app-shell .modal label:has(+ [class*="col-"] > select#personal_estado),
.qmo-app-shell .modal [class*="col-"]:has(> select[id*="_activo"]:not(#periodo_activo)),
.qmo-app-shell .modal [class*="col-"]:has(> select[id$="_activa"]),
.qmo-app-shell .modal [class*="col-"]:has(> select#usuario_estado),
.qmo-app-shell .modal [class*="col-"]:has(> select#personal_estado) { display: none !important; }
.qmo-app-shell .modal .qmo-tenant-selector {
    margin: 0 0 18px;
    padding: 0 0 14px;
    border-bottom: 1px solid var(--qmo-line);
}
.qmo-app-shell .modal .qmo-tenant-selector label { display: block; margin: 0 0 7px; color: var(--qmo-muted); font-size: 12px; font-weight: 750; }
.qmo-app-shell .qmo-approval-config {
    margin-top: 22px;
    padding: 20px;
    border: 1px solid var(--qmo-line);
    border-radius: 10px;
    background: #fbfcff;
}
.qmo-app-shell .qmo-approval-config__header { margin-bottom: 16px; }
.qmo-app-shell .qmo-approval-config__header h5 { margin: 0 0 5px; color: var(--qmo-ink); font-size: 15px; font-weight: 750; }
.qmo-app-shell .qmo-approval-config__header p { margin: 0; color: var(--qmo-muted); font-size: 12px; line-height: 1.45; }
.qmo-app-shell .qmo-approval-grid__head,
.qmo-app-shell .qmo-approval-grid__row {
    display: grid;
    grid-template-columns: 58px minmax(112px, 1fr) minmax(112px, 1fr) minmax(190px, 2.1fr) 62px;
    gap: 10px;
    align-items: center;
}
.qmo-app-shell .qmo-approval-grid__head { padding: 0 10px 8px; color: var(--qmo-muted); font-size: 11px; font-weight: 800; letter-spacing: .025em; text-transform: uppercase; }
.qmo-app-shell .qmo-approval-grid__row { min-height: 52px; padding: 7px 10px; border-top: 1px solid #e8ebf2; }
.qmo-app-shell .qmo-approval-grid__row:nth-child(odd) { background: #f5f4ff; }
.qmo-app-shell .qmo-approval-grid__row--inactive { opacity: .58; }
.qmo-app-shell .qmo-approval-range { justify-self: start; min-width: 25px; padding: 4px 8px; border-radius: 999px; background: #e9e6ff; color: var(--qmo-primary-dark); font-size: 12px; font-weight: 800; text-align: center; }
.qmo-app-shell .qmo-approval-grid .input-group-addon { border-color: #dfe4ee; background: #f0efff; color: var(--qmo-primary-dark); font-weight: 800; }
.qmo-app-shell .qmo-approval-grid .form-control { min-width: 0; }
.qmo-app-shell .qmo-approval-infinite { padding: 7px 10px; border: 1px dashed #d8ddea; border-radius: 4px; color: var(--qmo-muted); font-size: 12px; font-weight: 700; text-align: center; }
.qmo-app-shell .qmo-approval-switch { justify-self: center; margin: 0; }
@media (max-width: 767px) {
    .qmo-app-shell .qmo-approval-config { padding: 14px; }
    .qmo-app-shell .qmo-approval-grid__head { display: none; }
    .qmo-app-shell .qmo-approval-grid__row { grid-template-columns: 34px minmax(0, 1fr) minmax(0, 1fr) 48px; }
    .qmo-app-shell .qmo-approval-grid__row > select { grid-column: 2 / span 2; }
    .qmo-app-shell .qmo-approval-switch { grid-column: 4; grid-row: 1; }
}

/* Resúmenes de pantalla: van bajo el subtítulo y antes de la tarjeta de contenido. */
#qmo-screen-summary:empty { display: none; }
#qmo-screen-summary:not(:empty) { margin: 0 0 20px; }
.qmo-cheques-summary .row { margin-right: -9px; margin-left: -9px; }
.qmo-cheques-summary [class*="col-"] { padding-right: 9px; padding-left: 9px; }
.qmo-cheques-summary .qmo-cheques-databox { display: flex !important; flex-direction: column; height: 164px !important; min-height: 164px !important; margin: 0 0 10px; overflow: hidden; border: 1px solid var(--qmo-line); border-radius: 8px; box-shadow: 0 5px 16px rgba(31,42,68,.08); }
.qmo-cheques-summary .qmo-cheques-card-top { position: relative !important; display: block !important; flex: 0 0 92px; height: 92px !important; min-height: 92px !important; overflow: hidden; }
.qmo-cheques-summary .qmo-cheques-card-top--issued { background: linear-gradient(135deg, #8ecb59, #a6dc73); }
.qmo-cheques-summary .qmo-cheques-card-top--today { background: linear-gradient(135deg, #1fb3d0, #42c6df); }
.qmo-cheques-summary .qmo-cheques-card-top--week { background: linear-gradient(135deg, #f26e57, #ff8468); }
.qmo-cheques-summary .qmo-cheques-chart-caption { position: absolute; z-index: 2; top: 10px; left: 13px; color: rgba(255,255,255,.92); font-size: 10px; font-weight: 700; letter-spacing: .02em; text-shadow: 0 1px 1px rgba(0,0,0,.12); }
.qmo-cheques-summary .databox-sparkline { position: absolute !important; inset: 0 !important; width: 100% !important; height: 92px !important; }
.qmo-cheques-summary .qmo-cheques-spark { display: block; width: 100%; height: 92px; }
.qmo-ventas-summary .row { margin-right: -9px; margin-left: -9px; }
.qmo-ventas-summary [class*="col-"] { padding-right: 9px; padding-left: 9px; }
.qmo-ventas-summary .qmo-ventas-databox { display: flex !important; flex-direction: column; height: 164px !important; min-height: 164px !important; margin: 0 0 10px; overflow: hidden; border: 1px solid var(--qmo-line); border-radius: 8px; box-shadow: 0 5px 16px rgba(31,42,68,.08); }
.qmo-ventas-summary .qmo-ventas-card-top { position: relative !important; display: block !important; flex: 0 0 92px; height: 92px !important; min-height: 92px !important; overflow: hidden; }
.qmo-ventas-summary .qmo-ventas-card-top--sales { background: linear-gradient(135deg, #8ecb59, #a6dc73); }
.qmo-ventas-summary .qmo-ventas-card-top--debt { background: linear-gradient(135deg, #1fb3d0, #42c6df); }
.qmo-ventas-summary .qmo-ventas-card-top--overdue { background: linear-gradient(135deg, #f26e57, #ff8468); }
.qmo-ventas-summary .qmo-ventas-chart-caption { position: absolute; z-index: 2; top: 10px; left: 13px; color: rgba(255,255,255,.92); font-size: 10px; font-weight: 700; letter-spacing: .02em; text-shadow: 0 1px 1px rgba(0,0,0,.12); }
.qmo-ventas-summary .databox-sparkline { position: absolute !important; inset: 0 !important; width: 100% !important; height: 92px !important; }
.qmo-ventas-summary .qmo-ventas-sparkline { display: block; width: 100%; height: 92px; }
.qmo-ventas-summary .databox-bottom { position: relative !important; display: block !important; flex: 0 0 70px; height: 70px !important; min-height: 70px !important; overflow: visible !important; background: #fff; }
.qmo-ventas-summary .databox-row { display: table !important; width: 100%; height: 70px !important; table-layout: fixed; }
.qmo-ventas-summary .databox-cell { display: table-cell !important; float: none !important; height: 70px !important; padding: 13px 13px 12px; vertical-align: middle; }
.qmo-ventas-summary .databox-text { display: block; color: #667188; font-size: 11px; font-weight: 700; }
.qmo-ventas-summary .databox-number { color: #313b53; font-size: 17px; font-weight: 750; letter-spacing: -.25px; }
.qmo-ventas-summary .databox-number.font-70 { font-size: 14px; }
.qmo-cheques-summary .databox-bottom { position: relative !important; display: block !important; flex: 0 0 70px; height: 70px !important; min-height: 70px !important; overflow: visible !important; background: #fff; }
.qmo-cheques-summary .databox-row { display: table !important; width: 100%; height: 70px !important; table-layout: fixed; }
.qmo-cheques-summary .databox-cell { display: table-cell !important; float: none !important; height: 70px !important; padding: 13px 13px 12px; vertical-align: middle; }
.qmo-cheques-summary .databox-text { display: block; color: #667188; font-size: 11px; font-weight: 700; }
.qmo-cheques-summary .databox-number { color: #313b53; font-size: 17px; font-weight: 750; letter-spacing: -.25px; }
.qmo-cheques-summary .databox-number.font-70 { font-size: 14px; }
.jqsfield .qmo-cheques-tooltip { min-width: 156px; }
.qmo-cheques-tooltip strong, .qmo-cheques-tooltip span { display: block; }
.qmo-cheques-tooltip strong { margin-bottom: 4px; font-weight: 800; }
.qmo-cheques-tooltip span { line-height: 1.45; }
.qmo-app-shell .qmo-cheques-filters label { display: block; margin-bottom: 6px; color: #4e5870; font-size: 12px; font-weight: 700; }
.qmo-app-shell .qmo-cheques-search label { display: block; }
.qmo-app-shell .qmo-cheques-search .btn { min-width: 78px; }
.qmo-app-shell .qmo-selected-row > td {
    background: #6258d9 !important;
    color: #fff !important;
    font-weight: 700;
    box-shadow: inset 0 1px 0 rgba(255,255,255,.2), inset 0 -1px 0 rgba(41,31,133,.35);
}
.qmo-app-shell .qmo-selected-row > td:first-child { box-shadow: inset 4px 0 0 #3930a7, inset 0 1px 0 rgba(255,255,255,.2), inset 0 -1px 0 rgba(41,31,133,.35); }
.qmo-provider-search { cursor: pointer; }
.qmo-provider-selector tbody > tr { cursor: pointer; }
.qmo-provider-selector tbody > tr:hover > td { background: #e7e4ff !important; color: #313b53 !important; }
.qmo-provider-selector tbody > tr.qmo-selected-row > td,
.qmo-provider-selector tbody > tr.qmo-selected-row:hover > td { background: #6258d9 !important; color: #fff !important; }
.qmo-selector-search,
.qmo-app-shell #buscarOC { cursor: pointer; }
.qmo-app-shell .input-icon > .glyphicon-search,
.qmo-app-shell .glyphicon-search[id^="buscar"] { cursor: pointer; }
.qmo-app-shell #tablaOC tbody > tr,
.qmo-app-shell #tablaProductos tbody > tr,
.qmo-app-shell .qmo-selectable-table tbody > tr { cursor: pointer; }
.qmo-app-shell #tablaOC tbody > tr:hover > td,
.qmo-app-shell #tablaProductos tbody > tr:hover > td,
.qmo-app-shell .qmo-selectable-table tbody > tr:hover > td { background: #e7e4ff !important; color: #313b53 !important; }
.qmo-app-shell #tablaOC tbody > tr.qmo-selected-row > td,
.qmo-app-shell #tablaOC tbody > tr.qmo-selected-row:hover > td,
.qmo-app-shell #tablaProductos tbody > tr.qmo-selected-row > td,
.qmo-app-shell #tablaProductos tbody > tr.qmo-selected-row:hover > td,
.qmo-app-shell .qmo-selectable-table tbody > tr.qmo-selected-row > td,
.qmo-app-shell .qmo-selectable-table tbody > tr.qmo-selected-row:hover > td { background: #6258d9 !important; color: #fff !important; }
.qmo-app-shell .qmo-cotizacion-spinbox { width: 100%; }
.qmo-app-shell #tablaCotizaciones td.details-control { text-align: center; vertical-align: middle; }
.qmo-app-shell .qmo-cotizacion-detail { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; margin: 8px 14px; padding: 13px 15px; border: 1px solid #e2e0f7; border-radius: 8px; background: linear-gradient(135deg, #fbfbff, #f4f3ff); }
.qmo-app-shell .qmo-cotizacion-detail__item { min-width: 0; }
.qmo-app-shell .qmo-cotizacion-detail__item span { display: block; margin-bottom: 3px; color: #778198; font-size: 10px; font-weight: 800; letter-spacing: .025em; text-transform: uppercase; }
.qmo-app-shell .qmo-cotizacion-detail__item strong { display: block; overflow: hidden; color: #36405a; font-size: 12px; font-weight: 700; text-overflow: ellipsis; white-space: nowrap; }
@media (max-width: 767px) { .qmo-app-shell .qmo-cotizacion-detail { grid-template-columns: 1fr; } }
.qmo-app-shell .qmo-cotizacion-spinbox .spinbox-buttons {
    display: flex;
    align-items: stretch;
    width: 54px;
    height: 30px;
    border-left: 1px solid #dfe4ee;
    background: #f8f9fc;
}
.qmo-app-shell .qmo-cotizacion-spinbox.spinbox-right .spinbox-buttons { right: 0; left: auto; }
.qmo-app-shell .qmo-cotizacion-spinbox .spinbox-buttons > .btn {
    float: none;
    flex: 1 1 50%;
    width: 27px;
    height: 30px !important;
    min-width: 0;
    margin: 0;
    padding: 0 !important;
    border: 0;
    border-radius: 0;
    background: transparent;
    color: var(--qmo-primary);
    font-size: 14px !important;
    line-height: 30px !important;
    vertical-align: middle !important;
}
.qmo-app-shell .qmo-cotizacion-spinbox .spinbox-buttons > .spinbox-down { border-right: 1px solid #dfe4ee; }
.qmo-app-shell .qmo-cotizacion-spinbox .spinbox-buttons > .btn:hover,
.qmo-app-shell .qmo-cotizacion-spinbox .spinbox-buttons > .btn:focus { background: #e7e4ff; color: var(--qmo-primary-dark); opacity: 1; outline: 0; }
.qmo-app-shell .qmo-cotizacion-spinbox .spinbox-buttons > .btn > i { position: static; top: auto; margin: 0; }
.qmo-app-shell .qmo-cotizacion-spinbox input { height: 30px; padding-right: 62px !important; padding-left: 10px !important; }
.qmo-app-shell .qmo-cotizacion-actions { display: flex; align-items: center; flex-wrap: wrap; gap: 10px 14px; margin-top: 18px; padding: 14px 0 0; border-top: 1px solid var(--qmo-line); }
.qmo-app-shell .qmo-cotizacion-actions__group { display: inline-flex; align-items: center; flex-wrap: wrap; gap: 7px; }
.qmo-app-shell .qmo-cotizacion-actions__group + .qmo-cotizacion-actions__group { padding-left: 14px; border-left: 1px solid var(--qmo-line); }
.qmo-app-shell .qmo-cotizacion-actions__group--danger { padding-left: 14px; border-left: 1px solid var(--qmo-line); }
.qmo-app-shell .qmo-cotizacion-actions__spacer { flex: 1 1 18px; }
.qmo-app-shell .qmo-cotizacion-actions .btn { min-width: 102px; margin: 0; font-weight: 700; }
.qmo-app-shell .qmo-cotizacion-actions__group--secondary .btn { min-width: auto; }
.qmo-app-shell .qmo-pdf-branding-control { display: flex; align-items: center; flex-wrap: nowrap; gap: 8px 12px; margin: 0; }
.qmo-app-shell .qmo-pdf-branding-control__file { flex: 0 0 390px; width: 390px; min-width: 0; max-width: 100%; }
.qmo-app-shell .qmo-pdf-branding-control__file input { width: 100%; min-width: 0; }
.qmo-app-shell .qmo-pdf-branding-preview { flex: 0 0 auto; white-space: nowrap; }
.qmo-app-shell .qmo-pdf-branding-preview a { font-size: 12px; font-weight: 700; }
.qmo-app-shell .qmo-pdf-branding-actions { display: inline-flex; flex: 0 0 auto; align-items: center; gap: 8px; white-space: nowrap; }
.qmo-app-shell .qmo-pdf-branding-actions .btn { margin: 0; white-space: nowrap; }
.qmo-app-shell .qmo-pdf-branding-actions__pending { color: #a15c00; font-size: 12px; font-weight: 700; }
@media (max-width: 991px) { .qmo-app-shell .qmo-pdf-branding-control { flex-wrap: wrap; } .qmo-app-shell .qmo-pdf-branding-control__file { flex-basis: 100%; width: 100%; } }
.qmo-app-shell .qmo-cotizacion-actions__group--secondary .btn-warning { background: #fff; border-color: #dfe4ee; color: #65728a; }
.qmo-app-shell .qmo-cotizacion-actions__group--secondary .btn-warning:hover,
.qmo-app-shell .qmo-cotizacion-actions__group--secondary .btn-warning:focus { background: #f4f6fa; border-color: #cbd3e1; color: #3d4961; }
@media (max-width: 767px) {
    .qmo-app-shell .qmo-cotizacion-actions { align-items: stretch; }
    .qmo-app-shell .qmo-cotizacion-actions__group,
    .qmo-app-shell .qmo-cotizacion-actions__group--secondary { width: 100%; padding-left: 0; border-left: 0; }
    .qmo-app-shell .qmo-cotizacion-actions__spacer { display: none; }
    .qmo-app-shell .qmo-cotizacion-actions .btn { flex: 1 1 132px; }
}
.qmo-app-shell .qmo-info-tooltip { display: inline-flex; align-items: center; justify-content: center; width: 18px; height: 18px; margin-left: 4px; padding: 0; border: 0; border-radius: 50%; background: transparent; color: #68748c; cursor: help; vertical-align: middle; }
.qmo-app-shell .qmo-info-tooltip:hover,
.qmo-app-shell .qmo-info-tooltip:focus { color: var(--qmo-primary); outline: 0; }
.qmo-sales-sparkline-tooltip { min-width: 184px; padding: 10px 12px; border: 0; border-radius: 9px; background: rgba(22, 31, 49, .96); box-shadow: 0 8px 20px rgba(20, 29, 45, .22); color: #fff; font: 12px/1.45 Inter, "Open Sans", sans-serif; }
.qmo-sales-sparkline-tooltip__title { margin-bottom: 2px; color: #fff; font-size: 12px; font-weight: 800; }
.qmo-sales-sparkline-tooltip__period { margin-bottom: 7px; color: #c9d2e3; font-size: 10px; font-weight: 700; letter-spacing: .02em; text-transform: uppercase; }
.qmo-sales-sparkline-tooltip__value { display: flex; align-items: center; gap: 6px; color: #edf2fa; }
.qmo-sales-sparkline-tooltip__value + .qmo-sales-sparkline-tooltip__value { margin-top: 3px; }
.qmo-sales-sparkline-tooltip__value strong { color: #fff; font-weight: 800; }
.qmo-sales-sparkline-tooltip__dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: #a9dc7a; }
.qmo-sales-sparkline-tooltip__line { display: inline-block; width: 11px; height: 2px; border-radius: 2px; background: #fff; }
@media (max-width: 991px) { .qmo-cheques-summary .qmo-cheques-databox, .qmo-ventas-summary .qmo-ventas-databox { margin-bottom: 18px; } .qmo-app-shell .qmo-cheques-filters > [class*="col-"] { margin-bottom: 12px; } }

/* Global asynchronous feedback: no blocking legacy "Procesando datos" modal. */
#qmo-request-progress { position: fixed; top: 0; right: 0; left: 0; z-index: 2005; height: 3px; overflow: hidden; opacity: 0; pointer-events: none; transition: opacity .18s; }
#qmo-request-progress > span { display: block; width: 42%; height: 100%; border-radius: 0 3px 3px 0; background: linear-gradient(90deg, #4d43c5, #8d83ff); transform: translateX(-115%); }
#qmo-request-progress.is-active { opacity: 1; }
#qmo-request-progress.is-active > span { animation: qmo-request-progress 1.05s ease-in-out infinite; }
@keyframes qmo-request-progress { 0% { transform: translateX(-115%); } 55% { transform: translateX(135%); } 100% { transform: translateX(260%); } }
#cargaModal, #carga_modal { display: none !important; }
.qmo-table-loading { position: absolute; z-index: 5; inset: 0; display: flex; align-items: center; justify-content: center; min-height: 130px; background: rgba(255,255,255,.78); backdrop-filter: blur(1px); }
.qmo-table-loading > span { width: 30px; height: 30px; border: 3px solid #ddd9ff; border-top-color: var(--qmo-primary); border-radius: 50%; animation: qmo-spin .75s linear infinite; }
.qmo-restoring-screen .loading-container { display: flex !important; z-index: 2100 !important; }
