:root {
    --bsx-navy: #0b1f3a;
    --bsx-navy-mid: #143154;
    --bsx-navy-deep: #071526;
    --bsx-accent: #105CA8;
    --bsx-paper: #f4f6fb;
    --bsx-line: #e3e6f0;
    --bsx-ink: #1a2340;
    --bsx-muted: #5a6a85;
}

html, body, body.header-fixed {
    background: var(--bsx-paper) !important;
    color: var(--bsx-ink);
    font-family: "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    font-size: 16px !important;
    line-height: 1.5;
}

#hex3, .idex-loader { display: none !important; }

.t-header,
.sidebar,
.sidebar .sidebar_footer {
    background: var(--bsx-navy) !important;
    border: 0 !important;
}

.t-header { min-height: 64px; }
.t-header .t-header-brand-wrapper,
.t-header .t-header-content-wrapper { background: transparent !important; }

.t-header .t-header-brand-wrapper .logo,
.t-header .t-header-brand-wrapper .logo-mini {
    height: 42px !important;
    width: auto !important;
}

.t-header-brand-wrapper a.bsx-brand {
    display: inline-flex;
    align-items: center;
    padding: 6px 8px;
    border-radius: 8px;
}

.page-body .page-content-wrapper { background: var(--bsx-paper) !important; }

.sidebar .navigation-menu .nav-category-divider,
.sidebar .navigation-menu li.nav-category-divider {
    background: transparent !important;
    color: #8aa0b8 !important;
    margin: 10px 16px 4px !important;
    padding: 10px 8px 4px !important;
    font-size: 12px !important;
    font-weight: 700 !important;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.sidebar .navigation-menu li a,
.sidebar .navigation-menu li a .link-title,
.sidebar .navigation-menu li a .link-icon {
    color: #d7e3f0 !important;
}

.sidebar .navigation-menu li a {
    border-radius: 8px;
    margin: 2px 10px;
    padding: 13px 14px !important;
    font-size: 17px !important;
    font-weight: 600 !important;
    line-height: 1.4 !important;
}
.sidebar .navigation-menu li a .link-title {
    font-size: 17px !important;
    font-weight: 600 !important;
    letter-spacing: 0.01em;
}
.sidebar .navigation-menu li a .link-icon {
    font-size: 22px !important;
}
.sidebar .navigation-menu li .navigation-submenu li a {
    font-size: 14px !important;
}

.sidebar .navigation-menu li a:hover,
.sidebar .navigation-menu li a.is-current,
.sidebar .navigation-menu li a.is-current .link-title,
.sidebar .navigation-menu li a.is-current .link-icon {
    background: var(--bsx-navy-mid) !important;
    color: #fff !important;
}

.sidebar .sidebar_footer .user-account { display: none !important; }
.sidebar .sidebar_footer .admin-access-level {
    background: var(--bsx-navy-mid) !important;
    border-radius: 10px;
    margin: 8px;
    padding: 12px 14px;
}
.sidebar .sidebar_footer .admin-access-level .user_name,
.sidebar .sidebar_footer .admin-access-level .user_access_level { color: #fff !important; }
.sidebar .sidebar_footer .admin-access-level .user-type-wrapper .user_name {
    font-size: 15px !important;
    font-weight: 700 !important;
    max-width: 160px !important;
    margin-bottom: 4px;
}
.sidebar .sidebar_footer .admin-access-level .user-type-wrapper .user_access_level {
    font-size: 13px !important;
    font-weight: 600 !important;
    color: #c5d4e4 !important;
}

.grid, .bsx-panel, .bsx-kpi, .platform-card, .filter-row {
    background: #fff;
    border: 1.5px solid var(--bsx-line);
    border-radius: 12px;
    box-shadow: 0 1px 4px rgba(0,0,0,.04);
}

.grid-header {
    background: var(--bsx-navy) !important;
    color: #fff !important;
    border: 0 !important;
    border-radius: 12px 12px 0 0;
    padding: 16px 18px;
    font-size: 17px !important;
    font-weight: 700 !important;
    letter-spacing: 0;
}
.grid-header:after { display: none !important; }

.btn-primary,
.page-item.active .page-link,
.dataTables_wrapper .dataTables_paginate .paginate_button.current {
    background: var(--bsx-navy) !important;
    border-color: var(--bsx-navy) !important;
    color: #fff !important;
}

.btn-outline-primary {
    color: var(--bsx-accent) !important;
    border-color: var(--bsx-accent) !important;
    background: transparent !important;
}
.btn-outline-primary:hover {
    color: #fff !important;
    background: var(--bsx-accent) !important;
}
.breadcrumb,
.breadcrumb .breadcrumb-item,
.breadcrumb .breadcrumb-item a,
.page-body .page-content-wrapper .page-content-wrapper-inner .viewport-header .breadcrumb .breadcrumb-item,
.page-body .page-content-wrapper .page-content-wrapper-inner .viewport-header .breadcrumb .breadcrumb-item a {
    font-size: 14px !important;
    font-weight: 600 !important;
}
.breadcrumb .breadcrumb-item a { color: var(--bsx-accent) !important; }
.breadcrumb .breadcrumb-item.active,
.page-body .page-content-wrapper .page-content-wrapper-inner .viewport-header .breadcrumb .breadcrumb-item.active {
    color: var(--bsx-ink) !important;
    font-size: 14px !important;
}

.viewport-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    margin-bottom: 8px;
}

.bsx-page-head { margin: 4px 0 18px; }
.bsx-page-head h1 {
    font-size: 28px;
    font-weight: 700;
    color: var(--bsx-navy);
    margin: 0 0 6px;
    line-height: 1.2;
}
.bsx-kicker {
    text-transform: uppercase;
    letter-spacing: .08em;
    font-size: 13px;
    font-weight: 700;
    color: var(--bsx-muted);
    margin: 0 0 4px;
}
.bsx-muted, .bsx-note { color: var(--bsx-muted); font-size: 15px; line-height: 1.45; }

.bsx-kpi-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
    margin-bottom: 18px;
}
.bsx-kpi {
    padding: 16px 16px 14px;
    min-height: 0;
    margin: 0;
}
.bsx-kpi i { color: var(--bsx-accent); font-size: 22px; }
.bsx-kpi strong {
    display: block;
    font-size: 28px;
    color: var(--bsx-navy);
    margin: 8px 0 4px;
    font-weight: 800;
    line-height: 1.15;
}
.bsx-kpi span {
    color: var(--bsx-muted);
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: .05em;
    font-weight: 700;
}
.bsx-kpi-money strong { font-size: 20px; }

.platform-row {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
    margin-bottom: 18px;
}
.platform-card { padding: 16px 18px; }
.platform-card .pc-count { font-size: 1.75rem; font-weight: 800; color: var(--bsx-navy); line-height: 1.1; }
.platform-card .pc-label {
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: .06em;
    color: #5a6a85;
    margin-top: .4rem;
    font-weight: 700;
}

.status-pill, .bsx-badge {
    display: inline-block;
    padding: .35em .85em;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 700;
    white-space: nowrap;
}
.bsx-plat {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 14px;
    border-radius: 999px;
    font-size: 15px;
    font-weight: 700;
    line-height: 1.2;
    white-space: nowrap;
}
.bsx-plat i { font-size: 18px; line-height: 1; }
.bsx-plat.plat-ios, .bsx-plat.bsx-apple { background: #111; color: #fff; }
.bsx-plat.plat-android, .bsx-plat.bsx-google { background: #e6f4ea; color: #1e7e34; }
.bsx-plat.plat-web, .bsx-plat.bsx-email { background: #e8f0fe; color: #1a73e8; }
.bsx-plat.plat-unknown, .bsx-plat.bsx-unknown { background: #f1f5f9; color: #64748b; }
.bsx-user-name { font-size: 16px; font-weight: 700; color: var(--bsx-navy); }
.bsx-user-email { font-size: 15px; color: #334155; }
.bsx-when { min-width: 188px; }
.bsx-when-row {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 15px;
    color: #1e293b;
    white-space: nowrap;
}
.bsx-when-row + .bsx-when-row { margin-top: 6px; }
.bsx-when-row i { color: #64748b; font-size: 17px; }
.bsx-when-time, .bsx-when-empty, .bsx-when-never { color: #64748b; font-size: 14px; font-weight: 600; }
.bsx-when-date { font-weight: 700; }
.pill-active { background: #d4edda; color: #155724; }
.pill-suspended { background: #cce5ff; color: #004085; }
.bsx-badge { background: #e8eef6; color: var(--bsx-navy); }
.bsx-badge.bsx-ios, .bsx-badge.bsx-apple { background: #111; color: #fff; }
.bsx-badge.bsx-android, .bsx-badge.bsx-google { background: #e6f4ea; color: #1e7e34; }
.bsx-badge.bsx-email, .bsx-badge.bsx-web { background: #e8f0fe; color: #1a73e8; }
.bsx-badge.bsx-unknown { background: #f8f9fa; color: #6c757d; }

.bsx-live {
    border-radius: 999px;
    padding: 8px 14px;
    font-size: 13px;
    font-weight: 700;
}
.bsx-live.is-up { background: #e7f6ee; color: #146c43; }
.bsx-live.is-down { background: #fbeaea; color: #8a1f1f; }

.bsx-panel { padding: 20px; margin-bottom: 18px; }
.bsx-panel h3 { font-size: 18px; font-weight: 700; color: var(--bsx-navy); margin: 0 0 14px; }
.bsx-list { list-style: none; padding: 0; margin: 0; }
.bsx-list li {
    display: flex;
    justify-content: space-between;
    padding: 10px 0;
    border-bottom: 1px solid var(--bsx-line);
    font-size: 15px;
}

.table thead th {
    background: #f4f6fb;
    font-size: 13px !important;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .04em;
    color: #5a5c69;
    border-bottom: 2px solid #e3e6f0 !important;
    white-space: nowrap;
    padding-top: 12px;
    padding-bottom: 12px;
}
.table tbody tr:hover { background: #f8f9fc; }
.table td,
.table tbody td {
    font-size: 15px !important;
    vertical-align: middle;
    padding-top: 14px;
    padding-bottom: 14px;
}
.users-table {
    width: 100% !important;
}
.users-table td,
.users-table tbody td {
    font-size: 16px !important;
    padding-top: 16px;
    padding-bottom: 16px;
}

.table th:last-child,
.table td:last-child,
table.dataTable thead th:last-child,
table.dataTable tbody td:last-child {
    width: 96px !important;
    min-width: 96px !important;
    text-align: center !important;
    padding-left: 10px !important;
    padding-right: 10px !important;
    vertical-align: middle !important;
}
table.dataTable thead th:last-child.sorting,
table.dataTable thead th:last-child.sorting_asc,
table.dataTable thead th:last-child.sorting_desc,
table.dataTable thead th:last-child.sorting_disabled {
    padding-right: 8px !important;
    background-image: none !important;
}
.table td:last-child .bsx-action-menu,
table.dataTable tbody td:last-child .bsx-action-menu {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    margin: 0 auto;
}
.bsx-action-menu { position: relative; display: inline-flex; }
.bsx-action-toggle {
    width: 44px; height: 44px; padding: 0;
    display: inline-flex; align-items: center; justify-content: center;
    border-radius: 10px;
    border: 1px solid #d5dbe6;
    background: #fff;
    color: #334155;
    font-size: 24px;
}
.bsx-action-toggle:hover,
.bsx-action-menu.is-open .bsx-action-toggle {
    background: #f8fafc;
    border-color: var(--bsx-accent);
    color: var(--bsx-navy);
}
.bsx-action-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, .46);
    z-index: 1990;
}
.bsx-action-panel[hidden] { display: none !important; }
.bsx-action-panel {
    position: fixed;
    right: 16px;
    bottom: 16px;
    width: min(380px, calc(100vw - 32px));
    max-height: calc(100dvh - 112px);
    display: flex;
    flex-direction: column;
    background: #fff;
    border: 1px solid #e6eaf2;
    border-radius: 16px;
    box-shadow: 0 18px 50px rgba(15, 23, 42, .18);
    z-index: 2000;
    transform: translateX(110%);
    transition: transform .2s ease;
    overflow: hidden;
}
.bsx-action-panel.is-shown { transform: translateX(0); }
.bsx-action-menu__head {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    padding: 18px 18px 14px;
    border-bottom: 1px solid #eef2f7;
}
.bsx-action-menu__kicker {
    display: block;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: .08em;
    text-transform: uppercase;
    color: #64748b;
}
.bsx-action-menu__name {
    display: block;
    margin-top: 4px;
    font-size: 17px;
    font-weight: 700;
    color: #0f172a;
}
.bsx-action-menu__email {
    display: block;
    margin-top: 2px;
    font-size: 14px;
    color: #64748b;
}
.bsx-action-menu__close {
    width: 36px; height: 36px;
    border: 1px solid #e6eaf2;
    border-radius: 8px;
    background: #fff;
}
.bsx-action-menu__body { overflow: auto; padding: 4px 12px 8px; }
.bsx-action-menu__foot {
    border-top: 1px solid #eef2f7;
    padding: 10px 12px 16px;
}
.bsx-action-menu__item {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    min-height: 44px;
    margin: 2px 0;
    padding: 8px 10px;
    border: 0;
    border-radius: 8px;
    background: transparent;
    color: #1e293b;
    font-size: 15px;
    font-weight: 600;
    text-align: left;
    text-decoration: none;
}
.bsx-action-menu__item i {
    width: 32px; height: 32px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    background: #f1f5f9;
    color: #475569;
}
.bsx-action-menu__item:hover { background: #f8fafc; color: var(--bsx-navy); text-decoration: none; }
.bsx-action-menu__danger { color: #b91c1c; }
.bsx-action-menu__danger i { background: #fef2f2; color: #b91c1c; }
.bsx-action-menu__fact {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    width: 100%;
    margin: 6px 0;
    padding: 10px;
    border-radius: 10px;
    background: #f8fafc;
}
.bsx-action-menu__fact i {
    width: 32px; height: 32px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    background: #e8eef6;
    color: var(--bsx-accent);
    flex: 0 0 32px;
}
.bsx-action-menu__fact-label {
    display: block;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: .06em;
    text-transform: uppercase;
    color: #64748b;
}
.bsx-action-menu__fact-value {
    display: block;
    margin-top: 2px;
    font-size: 15px;
    font-weight: 700;
    color: #0f172a;
}
body.bsx-action-sheet-open { overflow: hidden; }

.dataTables_wrapper .dataTables_filter input {
    border: 1px solid var(--bsx-line);
    border-radius: 8px;
    padding: 6px 10px;
}

.page-content-wrapper-inner { padding: 18px 22px 40px; }
.grid .item-wrapper { padding: 16px; }
.grid { overflow: hidden; }
.bsx-hero { margin-bottom: 18px; }
.bsx-hero h1 { font-size: 28px; font-weight: 700; color: var(--bsx-navy); margin: 0 0 6px; }

.btn,
.btn-primary,
.btn-outline-primary,
.btn-sm,
.btn-group-sm > .btn {
    font-size: 15px !important;
    font-weight: 600 !important;
    line-height: 1.4;
    padding: .45rem .9rem;
}
.form-control,
.t-header .t-header-search-box .form-control,
.dataTables_wrapper .dataTables_filter input,
.select2-container--default .select2-selection--single .select2-selection__rendered {
    font-size: 15px !important;
}
.dataTables_wrapper .dataTables_info,
.dataTables_wrapper .dataTables_length,
.dataTables_wrapper .dataTables_filter,
.dataTables_wrapper .dataTables_paginate,
.dataTables_wrapper .dataTables_paginate .paginate_button {
    font-size: 14px !important;
}
.page-item .page-link { font-size: 14px !important; }
label, .form-group label, .custom-control-label {
    font-size: 15px !important;
}
p, .content-viewport p, .grid .item-wrapper p {
    font-size: 15px;
}
.authentication .form-control { font-size: 16px !important; min-height: 44px; }
.authentication .btn, .authentication .btn-sm {
    font-size: 16px !important;
    min-height: 44px;
    padding: .7rem 1.1rem;
}
.authentication .signup-link p { font-size: 14px; }
footer, footer p { font-size: 14px; }

.t-header .t-header-search-box .form-control {
    background: var(--bsx-navy-mid) !important;
    border: 1px solid #1e4a78 !important;
    color: #fff !important;
}
.t-header .t-header-search-box .input-group-text {
    background: var(--bsx-navy-mid) !important;
    color: #8aa0b8 !important;
    border: 0 !important;
}
.t-header .t-header-toggler svg path { stroke: #fff; fill: none; }
footer { background: transparent; color: var(--bsx-muted); padding: 8px 22px 24px; }

::-webkit-scrollbar-thumb { background: var(--bsx-accent) !important; }
::selection, ::-moz-selection { background: var(--bsx-accent) !important; color: #fff !important; }

.authentication .logo-section img { height: 48px; width: auto; }
.authentication .btn-primary { background: var(--bsx-navy) !important; border-color: var(--bsx-navy) !important; }

a, a:hover { color: var(--bsx-accent); }
.custom-control-input:checked ~ .custom-control-label::before,
.form-check-input:checked { background-color: var(--bsx-accent) !important; border-color: var(--bsx-accent) !important; }

@media (max-width: 1199.98px) {
    .bsx-kpi-grid, .platform-row { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 575.98px) {
    .bsx-kpi-grid, .platform-row { grid-template-columns: 1fr 1fr; }
    .bsx-action-toggle { width: 44px; height: 44px; }
    .page-content-wrapper-inner { padding: 12px; }
}
