/* FiberX SMS Gateway — Radius administration visual theme.
 * The existing application controls, permissions and workflows remain intact.
 */
:root {
  --fx-bg: #f4f6f9;
  --fx-surface: #fff;
  --fx-border: #dde3ec;
  --fx-border-soft: #edf0f4;
  --fx-text: #172033;
  --fx-muted: #667085;
  --fx-primary: #2f6fea;
  --fx-primary-hover: #245fca;
  --fx-sidebar: #111827;
  --fx-success: #168a45;
  --fx-shadow: 0 6px 26px rgba(16, 24, 40, .04);
}

html { background: var(--fx-bg); }
body {
  background: var(--fx-bg);
  color: var(--fx-text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 13px;
  line-height: 1.55;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3, h4, h5, h6, .h1, .h2, .h3, .h4, .h5, .h6,
button, input, textarea, select, .main-header .logo {
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}
a { color: var(--fx-primary); }
a:hover, a:active { color: var(--fx-primary-hover); }
a:focus-visible, button:focus-visible, [role="button"]:focus-visible {
  outline: 2px solid var(--fx-primary);
  outline-offset: 3px;
}
img { max-width: 100%; }
.wrapper { background: var(--fx-bg) !important; overflow: visible; }

/* Fixed chrome, matching the Radius workspace. */
body[class*="skin-"] .main-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 72px;
  max-height: none;
  z-index: 1020;
  box-shadow: none;
}
body[class*="skin-"] .main-header .logo {
  width: 248px;
  height: 72px;
  padding: 0 21px;
  background: var(--fx-sidebar);
  color: #fff;
  line-height: normal;
  text-align: left;
}
body[class*="skin-"] .main-header .logo:hover { background: var(--fx-sidebar); }
.main-header .logo .logo-lg {
  display: flex;
  align-items: center;
  gap: 11px;
  height: 72px;
}
.main-header .logo img.fx-brand-emblem,
.main-header .logo .logo-mini img {
  width: 39px;
  height: 39px;
  padding: 0;
  margin: 0;
  object-fit: contain;
  flex-shrink: 0;
}
.fx-brand-name {
  display: block;
  color: #fff;
  font-size: 20px;
  font-weight: 800;
  letter-spacing: -.7px;
  line-height: 1.15;
}
.fx-brand-lockup { display: grid; min-width: 0; }
.fx-brand-name span {
  color: #79c7ff;
  background: linear-gradient(135deg, #86e6ff, #5794ff);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}
.fx-brand-caption {
  display: block;
  color: #8797ad;
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 1.5px;
  line-height: 1.4;
  text-transform: uppercase;
  margin-top: 4px;
}
body[class*="skin-"] .main-header .navbar {
  margin-left: 248px;
  height: 72px;
  min-height: 72px;
  background: rgba(255, 255, 255, .98);
  border-bottom: 1px solid var(--fx-border);
  padding: 0 20px;
}
body[class*="skin-"] .main-header .navbar .sidebar-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  margin: 16px 0;
  padding: 0;
  border-radius: 9px;
  color: #64748b;
  font-size: 17px;
}
body[class*="skin-"] .main-header .navbar .sidebar-toggle:hover,
body[class*="skin-"] .main-header .navbar .sidebar-toggle:focus,
body[class*="skin-"] .main-header .navbar .nav > li > a:hover,
body[class*="skin-"] .main-header .navbar .nav > li > a:focus {
  background: #f1f5f9;
  color: var(--fx-text);
}
.main-header .navbar-custom-menu { margin-top: 12px; }
body[class*="skin-"] .main-header .navbar .nav > li > a {
  color: #526079;
  height: 48px;
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 8px 12px;
  border-radius: 10px;
  font-size: 12px;
  font-weight: 600;
}
.main-header .navbar .nav > li > a > .user-image {
  float: none;
  margin: 0;
  width: 34px;
  height: 34px;
  border-radius: 10px;
  border: 1px solid #e4eaf4;
  background: #e8efff;
}
.fx-user-avatar {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 35px;
  height: 35px;
  border-radius: 10px;
  background: #e8efff;
  color: #2f6fea;
  flex-shrink: 0;
  font-size: 16px;
}
.main-sidebar .fx-user-avatar { background: rgba(79, 140, 255, .14); color: #6ea0ff; }
.fx-page-context {
  display: flex;
  flex-direction: column;
  justify-content: center;
  float: left;
  height: 72px;
  max-width: calc(100% - 245px);
  min-width: 0;
  margin-left: 14px;
}
.fx-page-caption { color: #8793a4; font-size: 9px; font-weight: 650; letter-spacing: .9px; text-transform: uppercase; }
.fx-page-title { color: #42516a; display: block; font-size: 12px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; margin-top: 2px; }
body[class*="skin-"] .main-sidebar {
  position: fixed;
  top: 72px;
  left: 0;
  width: 248px;
  height: calc(100vh - 72px);
  height: calc(100dvh - 72px);
  min-height: 0;
  padding-top: 15px;
  background: var(--fx-sidebar);
  z-index: 1010;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: #344155 transparent;
  transform: none;
}
.main-sidebar .sidebar { padding: 0 13px 20px; }
.main-sidebar .user-panel {
  padding: 12px 9px 19px;
  margin-bottom: 12px;
  border-bottom: 1px solid rgba(255, 255, 255, .07);
}
.main-sidebar .user-panel .image img { width: 36px; height: 36px; border-radius: 10px; }
.main-sidebar .user-panel .info { left: 45px; padding-top: 3px; }
body[class*="skin-"] .user-panel > .info,
body[class*="skin-"] .user-panel > .info > a { color: #d7deea; }
.main-sidebar .user-panel .info p { font-size: 12px; margin-bottom: 5px; }
.main-sidebar .user-panel .info a { color: #8392a7 !important; font-size: 10px; }
.main-sidebar .user-panel .text-success { color: #40be8f !important; }
.main-sidebar .sidebar-menu > li { margin-bottom: 4px; }
body[class*="skin-"] .sidebar-menu > li > a {
  padding: 11px 12px;
  min-height: 42px;
  border-left: 0;
  border-radius: 10px;
  color: #9ca9bb;
  font-size: 12px;
  font-weight: 550;
}
.sidebar-menu > li > a > .fa,
.sidebar-menu > li > a > .ion,
.sidebar-menu > li > a > .glyphicon { width: 24px; font-size: 15px; }
body[class*="skin-"] .sidebar-menu > li:hover > a {
  background: rgba(255, 255, 255, .05);
  color: #eaf1ff;
}
body[class*="skin-"] .sidebar-menu > li.active > a,
body[class*="skin-"] .sidebar-menu > li.menu-open > a {
  background: rgba(55, 124, 246, .14);
  color: #eaf1ff;
  border-left: 0;
}
.sidebar-menu > li.active::before {
  content: "";
  position: absolute;
  left: -13px;
  top: 10px;
  width: 3px;
  height: 22px;
  border-radius: 2px;
  background: #4f8cff;
}
.sidebar-menu > li.active > a > i { color: #6ea0ff; }
body[class*="skin-"] .sidebar-menu > li > .treeview-menu { background: transparent; }
body[class*="skin-"] .treeview-menu > li > a { color: #9ca9bb; padding-block: 8px; }
.sidebar-menu hr { border-color: rgba(255, 255, 255, .08); margin: 18px 10px; }
.sidebar-menu li.header { background: transparent !important; color: #718097 !important; font-size: 10px; letter-spacing: 1px; }

body[class*="skin-"] .content-wrapper {
  margin-left: 248px;
  padding-top: 0;
  margin-top: 72px;
  background: var(--fx-bg);
  min-height: calc(100vh - 128px) !important;
  min-width: 0;
  transform: none;
}
.content-header { max-width: 1536px; margin: auto; padding: 27px 28px 5px; }
.content-header h1 { font-size: 24px; font-weight: 700; letter-spacing: -.65px; line-height: 1.35; margin: 0; }
.content-header h1 small { color: var(--fx-muted); font-size: 12px; font-weight: 400; margin-left: 8px; }
.content-header > .breadcrumb { padding: 0; background: transparent; color: var(--fx-muted); top: 30px; right: 28px; font-size: 11px; }
.content { max-width: 1536px; margin: 0 auto; padding: 20px 28px 28px; min-width: 0; }
.content > .row { margin-left: -9px; margin-right: -9px; }
.content > .row > [class*="col-"] { padding-left: 9px; padding-right: 9px; }
.content > .row > a > [class*="col-"] { padding-left: 9px; padding-right: 9px; }
.content .row > .col-md-12 > h3.text-bold { font-size: 14px; font-weight: 650 !important; margin-top: 5px; margin-bottom: 15px; color: #526079; }
.main-footer {
  margin-left: 248px;
  padding: 16px 28px;
  background: #fff;
  color: #8793a4;
  border-color: var(--fx-border-soft);
  font-size: 11px;
  transform: none;
}
.main-footer a { color: #526079; }
.main-footer b { font-weight: 600; }

/* Metrics: readable values, muted accents, no saturated dashboard panels. */
.small-box,
.small-box[class*="bg-"] {
  background: #fff !important;
  color: var(--fx-text) !important;
  border: 1px solid var(--fx-border);
  border-radius: 14px;
  box-shadow: var(--fx-shadow);
  min-height: 116px;
  margin-bottom: 18px;
  overflow: hidden;
  transition: border-color .16s ease, box-shadow .16s ease;
}
.small-box:hover { color: var(--fx-text) !important; border-color: #c5d7f6; box-shadow: 0 7px 22px rgba(47, 111, 234, .07); }
.small-box > .inner { padding: 20px 73px 18px 19px; color: var(--fx-text) !important; }
.small-box h3 { color: var(--fx-text) !important; font-size: 29px; font-weight: 750; letter-spacing: -.8px; margin: 0 0 7px; line-height: 1.25; white-space: normal; overflow-wrap: anywhere; }
.small-box p { color: var(--fx-muted) !important; font-size: 12px; font-weight: 500; line-height: 1.4; margin: 0; }
.small-box > .icon {
  position: absolute;
  right: 17px;
  top: 21px;
  width: 42px;
  height: 42px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #eaf1ff;
  border-radius: 11px;
  color: #3972d9 !important;
  font-size: 23px;
}
.small-box:hover .icon { font-size: 23px; }
.small-box.bg-green-gradient > .icon { background: #e8f8f1; color: #168a62 !important; }
.small-box.bg-yellow-gradient > .icon { background: #fff2e2; color: #d17a18 !important; }
.small-box.bg-red-gradient > .icon { background: #fff0ee; color: #c24b42 !important; }
.small-box.bg-purple-gradient > .icon { background: #f1eafe; color: #7c4bd6 !important; }
.small-box.bg-maroon-gradient > .icon { background: #fcebf2; color: #b3537c !important; }
.small-box.bg-black-gradient > .icon { background: #eef2f7; color: #68768a !important; }
.small-box .small-box-footer { background: #f8fafc; color: #526079 !important; font-size: 11px; padding: 8px 12px; border-top: 1px solid var(--fx-border-soft); }
.info-box { border: 1px solid var(--fx-border); border-radius: 13px; box-shadow: var(--fx-shadow); }
.info-box-icon { border-radius: 12px 0 0 12px; font-size: 29px; background: #eaf1ff !important; color: #3972d9 !important; }
.info-box-text { color: var(--fx-muted); font-size: 11px; text-transform: none; }
.info-box-number { color: var(--fx-text); font-size: 23px; }

/* Content panels. Overflow belongs to tables, not the card or menus. */
.box,
.box.box-primary,
.box.box-success,
.box.box-warning,
.box.box-danger,
.box.box-info,
.box.box-default {
  border: 1px solid var(--fx-border);
  border-top: 1px solid var(--fx-border);
  border-radius: 14px;
  background: #fff;
  box-shadow: var(--fx-shadow);
  margin-bottom: 22px;
}
.box-header { color: var(--fx-text); padding: 17px 20px; border-radius: 14px 14px 0 0; }
.box-header.with-border { border-bottom: 1px solid var(--fx-border-soft); }
.box-header::after { content: ""; display: table; clear: both; }
.box-header .box-title { font-size: 15px; font-weight: 650; line-height: 1.5; }
.box-header .box-tools { top: 12px; right: 15px; }
.box-header .btn-box-tool { color: #7b8798; border-radius: 7px; }
.box-header .btn-box-tool:hover { background: #f1f5f9; color: var(--fx-text); }
.box-body { padding: 19px 20px; min-width: 0; }
.box-footer { border-color: var(--fx-border-soft); border-radius: 0 0 14px 14px; padding: 16px 20px; background: #fff; }
.box-body > p { color: #667085; }
.box .overlay { border-radius: 14px; background: rgba(255, 255, 255, .84); }
.box .overlay > .fa { color: var(--fx-primary); }
.panel { border: 1px solid var(--fx-border-soft); border-radius: 11px; box-shadow: none; }
.panel-default > .panel-heading { border-color: var(--fx-border-soft); color: #526079; background: #f8fafc; border-radius: 10px 10px 0 0; padding: 13px 16px; }
.panel-title { font-size: 13px; font-weight: 650; }
.panel-body { padding: 17px; }
.well { border-color: var(--fx-border); border-radius: 10px; background: #f8fafc; box-shadow: none; }
.callout { border-radius: 10px; background: #f8fafc; color: #526079; box-shadow: none; }
.callout.callout-info { background: #edf4ff !important; border-color: #7fa8ec; color: #285fae !important; }
.box-profile .profile-user-img { width: 86px; border: 3px solid #e7eef9; border-radius: 22px; }
.profile-username { font-size: 20px; font-weight: 650; }
.list-group-item { border-color: var(--fx-border-soft); padding: 12px 15px; }
.list-group-item:first-child { border-radius: 10px 10px 0 0; }
.list-group-item:last-child { border-radius: 0 0 10px 10px; }

/* Shared actions and accessible forms. */
.btn {
  border-radius: 9px;
  font-size: 12px;
  font-weight: 650;
  line-height: 1.5;
  min-height: 38px;
  padding: 9px 13px;
  box-shadow: none;
  transition: background-color .15s ease, border-color .15s ease, color .15s ease;
}
.btn.btn-flat { border-radius: 9px; }
.btn-primary, .btn-info { background: var(--fx-primary); border-color: var(--fx-primary); color: #fff; }
.btn-primary:hover, .btn-primary:focus, .btn-primary:active,
.btn-info:hover, .btn-info:focus, .btn-info:active,
.btn-primary.active, .btn-primary.active:hover,
.open > .dropdown-toggle.btn-primary { background: var(--fx-primary-hover); border-color: var(--fx-primary-hover); color: #fff; }
.btn-default { background: #fff; border-color: #d3dce8; color: #526079; }
.btn-default:hover, .btn-default:focus, .btn-default:active { background: #f5f8fc; border-color: #bdc9d8; color: #344054; }
.btn-success { background: #168a62; border-color: #168a62; color: #fff; }
.btn-success:hover, .btn-success:focus { background: #117552; border-color: #117552; }
.btn-danger { background: #fff1ef; border-color: #f0d7d2; color: #b64038; }
.btn-danger:hover, .btn-danger:focus, .btn-danger:active { background: #fde8e4; border-color: #e8c2bc; color: #9d342d; }
.btn-warning { background: #fff6e8; border-color: #efddba; color: #956016; }
.btn-warning:hover, .btn-warning:focus { background: #fff0d7; border-color: #e6cd9b; color: #7e4f10; }
.btn-link { color: var(--fx-primary); }
.btn-sm { min-height: 32px; padding: 6px 10px; font-size: 11px; }
.btn-xs { min-height: 29px; padding: 4px 8px; font-size: 11px; border-radius: 7px; }
.btn-lg { min-height: 44px; padding: 11px 18px; font-size: 14px; }
.btn.disabled, .btn[disabled], fieldset[disabled] .btn { opacity: .48; cursor: not-allowed; box-shadow: none; }
.btn-group > .btn { margin-bottom: 0; }
.btn-group > .btn:first-child:not(:last-child) { border-radius: 9px 0 0 9px; }
.btn-group > .btn:last-child:not(:first-child) { border-radius: 0 9px 9px 0; }
.form-group { margin-bottom: 18px; }
.form-group > label, .control-label { color: #526079; font-size: 12px; font-weight: 600; margin-bottom: 7px; }
.form-control {
  border: 1px solid #d5deea;
  border-radius: 9px;
  background: #fff;
  box-shadow: none;
  color: #344054;
  min-height: 40px;
  height: 40px;
  padding: 9px 12px;
  font-size: 13px;
  line-height: 20px;
}
.form-control::placeholder { color: #98a2b3; opacity: 1; }
.form-control:focus { border-color: #6e9bf0; box-shadow: 0 0 0 3px rgba(47, 111, 234, .10); }
textarea.form-control { height: auto; min-height: 108px; line-height: 1.6; resize: vertical; }
.form-control[disabled], .form-control[readonly] { color: #7b8798; background: #f6f8fb; }
.has-feedback .form-control { padding-right: 40px; }
.form-control-feedback { color: #94a3b8; height: 40px; line-height: 40px; }
.has-error .form-control { border-color: #e7a39b; }
.has-error .help-block, .has-error .control-label { color: #b64038; }
.help-block { color: #8793a4; font-size: 11px; line-height: 1.6; margin-top: 7px; }
.input-group-addon { background: #f8fafc; border: 1px solid #d5deea; color: #7b8798; font-size: 13px; min-width: 40px; }
.input-group-addon:first-child { border-radius: 9px 0 0 9px; }
.input-group-addon:last-child { border-radius: 0 9px 9px 0; }
.input-group .form-control:first-child { border-radius: 9px 0 0 9px; }
.input-group .form-control:last-child { border-radius: 0 9px 9px 0; }
.input-group .form-control:not(:first-child):not(:last-child) { border-radius: 0; }
.input-group-btn:first-child > .btn { border-radius: 9px 0 0 9px; min-height: 40px; }
.input-group-btn:last-child > .btn { border-radius: 0 9px 9px 0; min-height: 40px; }
input[type="checkbox"], input[type="radio"] { accent-color: var(--fx-primary); }
.checkbox label, .radio label { font-size: 12px; color: #526079; }
.select2-container--default .select2-selection--single {
  border: 1px solid #d5deea;
  border-radius: 9px;
  min-height: 40px;
  height: 40px;
  padding: 4px 7px;
}
.select2-container--default .select2-selection--single .select2-selection__rendered { color: #344054; line-height: 30px; padding-left: 5px; padding-right: 23px; }
.select2-container--default .select2-selection--single .select2-selection__arrow { height: 38px; right: 6px; }
.select2-container--default .select2-selection--multiple { border: 1px solid #d5deea; border-radius: 9px; min-height: 40px; padding: 2px 7px; }
.select2-container--default.select2-container--focus .select2-selection--multiple,
.select2-container--default.select2-container--open .select2-selection--single { border-color: #6e9bf0; }
.select2-container--default .select2-selection--multiple .select2-selection__choice { background: #edf4ff; border: 1px solid #d7e4f8; border-radius: 5px; color: #285fae; font-size: 11px; padding: 3px 7px; }
.select2-dropdown { border-color: #d5deea; border-radius: 9px; box-shadow: 0 10px 28px rgba(15, 23, 42, .12); }
.select2-results__option { padding: 8px 12px; font-size: 12px; }
.select2-container--default .select2-results__option--highlighted[aria-selected] { background: var(--fx-primary); }
.select2-container--default .select2-search--dropdown .select2-search__field { border: 1px solid #d5deea; border-radius: 6px; }
.input-group > .select2-container { min-width: 0; }
.trumbowyg-box, .trumbowyg-editor { border-color: #d5deea; border-radius: 9px; }
.trumbowyg-button-pane { background: #f8fafc; border-color: var(--fx-border-soft); border-radius: 9px 9px 0 0; }
.dropzone { background: #f8fbff; border: 2px dashed #bdd0ef; border-radius: 12px; color: #667085; }
.dropzone:hover { border-color: #6e9bf0; }

/* Dense information stays clear on desktop and independently scrollable on mobile. */
.table { color: #526079; font-size: 12px; margin-bottom: 0; }
.table > thead > tr > th {
  background: #f8fafc;
  border-bottom: 1px solid var(--fx-border-soft);
  color: #7b8798;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .35px;
  line-height: 1.5;
  padding: 12px 13px;
  text-transform: uppercase;
  vertical-align: middle;
}
.table > tbody > tr > td { border-color: var(--fx-border-soft); padding: 13px; vertical-align: middle; line-height: 1.55; }
.table > tbody > tr > td > strong { color: var(--fx-text); }
.table-bordered { border-color: var(--fx-border-soft); }
.table-bordered > thead > tr > th,
.table-bordered > tbody > tr > td,
.table-bordered > tfoot > tr > td { border-left: 0; border-right: 0; }
.table-striped > tbody > tr:nth-of-type(odd) { background: #fcfdff; }
.table-hover > tbody > tr:hover, .table-striped > tbody > tr:hover { background: #f5f8ff; }
.table-responsive, .fx-table-scroll { width: 100%; overflow-x: auto; -webkit-overflow-scrolling: touch; border: 0; min-width: 0; }
.table-responsive > .table { margin-bottom: 0; }
.dataTables_wrapper { min-width: 0; }
.dataTables_wrapper > .row:first-child { margin-bottom: 15px; }
.dataTables_wrapper > .row:last-child { margin-top: 15px; }
.dataTables_wrapper .dataTables_length label,
.dataTables_wrapper .dataTables_filter label { color: #667085; font-size: 11px; font-weight: 400; }
.dataTables_wrapper .dataTables_length select { width: auto; min-width: 65px; margin-inline: 5px; }
.dataTables_wrapper .dataTables_filter input { min-height: 36px; height: 36px; margin-left: 8px; max-width: 220px; }
div.dataTables_wrapper div.dataTables_info { color: #8793a4; font-size: 11px; padding-top: 10px; }
.dataTables_empty { color: #8793a4; padding: 38px 15px !important; text-align: center; }
.pagination { margin: 0; }
.pagination > li > a, .pagination > li > span {
  color: #526079;
  background: #fff;
  border-color: #d8e0eb;
  min-height: 34px;
  padding: 7px 11px;
  font-size: 11px;
  font-weight: 600;
}
.pagination > li:first-child > a, .pagination > li:first-child > span { border-radius: 8px 0 0 8px; }
.pagination > li:last-child > a, .pagination > li:last-child > span { border-radius: 0 8px 8px 0; }
.pagination > .active > a, .pagination > .active > a:hover, .pagination > .active > a:focus { background: #edf4ff; border-color: #c9d9f5; color: #2f6fea; }
.pagination > li > a:hover { background: #f5f8fc; border-color: #bdc9d8; color: #2f6fea; }
.pagination > .disabled > a { color: #a4aebc; background: #f8fafc; }
.label { font-size: 10px; font-weight: 650; line-height: 1.4; border-radius: 20px; padding: 4px 8px; display: inline-block; }
.label-success { background: #e9f8f1 !important; color: #168a62 !important; }
.label-danger { background: #fff0ee !important; color: #b64038 !important; }
.label-warning { background: #fff7e8 !important; color: #956016 !important; }
.label-primary, .label-info { background: #edf3ff !important; color: #3b70ca !important; }
.label-default { background: #f2f5f8 !important; color: #69778b !important; }
.badge { background: #eaf1ff; color: #3b70ca; font-weight: 650; }
.text-muted { color: #8793a4 !important; }
.text-success { color: #168a62 !important; }
.text-danger { color: #b64038 !important; }
.text-warning { color: #956016 !important; }

/* Tabs, popups and feedback share the same surfaces and hierarchy. */
.nav-tabs-custom { border: 1px solid var(--fx-border); border-radius: 14px; box-shadow: var(--fx-shadow); background: #fff; }
.nav-tabs-custom > .nav-tabs { border-bottom-color: var(--fx-border-soft); padding: 7px 12px 0; border-radius: 14px 14px 0 0; }
.nav-tabs-custom > .nav-tabs > li { margin-right: 4px; border-top: 0; }
.nav-tabs-custom > .nav-tabs > li > a { color: #667085; font-size: 12px; font-weight: 600; padding: 14px 13px; border: 0; border-bottom: 2px solid transparent; border-radius: 7px 7px 0 0; }
.nav-tabs-custom > .nav-tabs > li.active > a,
.nav-tabs-custom > .nav-tabs > li.active > a:hover { background: #fff; color: var(--fx-primary); border: 0; border-bottom: 2px solid var(--fx-primary); }
.nav-tabs-custom > .nav-tabs > li > a:hover { background: #f8fafc; color: var(--fx-primary); }
.nav-tabs-custom > .tab-content { padding: 20px; border-radius: 0 0 14px 14px; }
.nav-tabs-custom .tab-content > .tab-pane .box { box-shadow: none; }
.nav-pills > li > a { color: #667085; border-radius: 8px; font-size: 12px; }
.nav-pills > li.active > a, .nav-pills > li.active > a:hover { background: #eaf1ff; color: #2f6fea; }
.dropdown-menu { border: 1px solid var(--fx-border); border-radius: 11px; box-shadow: 0 12px 32px rgba(15, 23, 42, .14); padding: 5px; font-size: 12px; }
.dropdown-menu > li > a { border-radius: 7px; padding: 9px 11px; color: #526079; }
.dropdown-menu > li > a:hover { color: var(--fx-primary); background: #f4f7fb; }
.dropdown-menu .divider { background-color: var(--fx-border-soft); margin: 5px 0; }
.modal-backdrop.in { opacity: .42; }
.modal-content { border: 1px solid var(--fx-border); border-radius: 15px; box-shadow: 0 24px 64px rgba(15, 23, 42, .23); }
.modal-header { border-color: var(--fx-border-soft); padding: 19px 22px; }
.modal-title { color: var(--fx-text); font-size: 17px; font-weight: 650; }
.modal-header .close { color: #667085; opacity: .7; font-size: 25px; }
.modal-body { padding: 22px; }
.modal-footer { padding: 15px 22px; border-color: var(--fx-border-soft); border-radius: 0 0 15px 15px; background: #fcfdff; }
.modal-footer .btn { margin-top: 4px; }
.alert { border: 1px solid transparent; border-radius: 11px; padding: 15px 18px; font-size: 12px; line-height: 1.65; }
.alert h4 { font-size: 14px; font-weight: 650; }
.alert-danger, .alert-error { background: #fff0ee !important; color: #b64038 !important; border-color: #efd2cf !important; }
.alert-success { background: #e9f8f1 !important; color: #168a62 !important; border-color: #d0ecdf !important; }
.alert-warning { background: #fff7e8 !important; color: #956016 !important; border-color: #efdcac !important; }
.alert-info { background: #edf3ff !important; color: #3b70ca !important; border-color: #d7e3fa !important; }
.alert.bg-gray { background: #edf2f8 !important; color: #526079 !important; border-color: #dae3ee !important; }
.alert a { color: inherit !important; text-decoration: underline; }
.alert .close { color: inherit; opacity: .55; }
#toast-container > div { border-radius: 11px; box-shadow: 0 8px 30px rgba(15, 23, 42, .15); font-family: inherit; font-size: 12px; opacity: .98; }
.timeline > li > .timeline-item { border: 1px solid var(--fx-border); border-radius: 12px; box-shadow: var(--fx-shadow); }
.timeline > li > .timeline-item > .timeline-header { border-color: var(--fx-border-soft); font-size: 14px; padding: 15px; }
.timeline > li > .timeline-item > .timeline-body { padding: 15px; line-height: 1.7; }
.timeline > li > .timeline-item > .timeline-footer { padding: 0 15px 15px; gap: 6px; }
.timeline > li > .timeline-item > .time { color: #98a2b3; font-size: 10px; }
.timeline::before { background: #dde5ef; width: 2px; }
.timeline > li > .fa, .timeline > li > .glyphicon, .timeline > li > .ion { box-shadow: 0 0 0 4px #f4f6f9; }
pre { background: #f8fafc; border-color: #e1e7ef; border-radius: 10px; color: #344054; font-size: 12px; }
.progress { border-radius: 7px; background: #eef2f7; box-shadow: none; }
.progress-bar { background: #2f6fea; box-shadow: none; }

/* Public account pages also match Radius; inline legacy overflow is overridden. */
body.login-page, body.register-page {
  background: radial-gradient(circle at 20% 15%, rgba(28, 118, 219, .13), transparent 550px),
    radial-gradient(circle at 85% 85%, rgba(0, 190, 206, .10), transparent 500px), #f4f7fb;
  min-height: 100vh;
  min-height: 100dvh;
  height: auto;
  overflow-y: auto !important;
  overflow-x: hidden !important;
  padding: 76px 20px 35px;
}
.login-page .login-box, .register-page .register-box {
  width: 425px;
  max-width: 100%;
  top: auto !important;
  margin: max(0px, calc((100vh - 690px) / 2)) auto 25px;
  position: relative;
  background: #fff;
  border: 1px solid #dfe7f1;
  border-radius: 17px;
  box-shadow: 0 24px 64px rgba(15, 23, 42, .10);
  padding: 27px;
}
.login-page .login-logo, .register-page .register-logo {
  font-size: 19px;
  font-weight: 750;
  margin: 0 0 23px;
  padding: 0 0 21px;
  border-bottom: 1px solid var(--fx-border-soft);
  text-align: left;
  line-height: 1.3;
}
.login-logo a, .register-logo a { color: var(--fx-text); }
.fx-login-brand { display: flex; align-items: center; gap: 12px; }
.fx-login-brand > a { display: flex; align-items: center; gap: 12px; }
.fx-login-brand .fx-brand-name { color: var(--fx-text); }
.fx-login-brand .fx-brand-caption { color: var(--fx-muted); }
.fx-login-brand img { width: 43px !important; height: 43px !important; object-fit: contain; }
.fx-login-brand > div { min-width: 0; }
.fx-login-title { color: #17243a; display: block; margin: 0 0 10px; font-size: 20px; font-weight: 800; line-height: 1.35; letter-spacing: -.65px; }
.fx-login-title span { color: #1789dc; }
.fx-login-caption { display: block; margin-top: 4px; color: #7a8799; font-size: 9px; font-weight: 600; line-height: 1.4; letter-spacing: 1.3px; text-transform: uppercase; }
.login-box-body, .register-box-body { padding: 0; background: transparent; color: #526079; }
.login-box-msg { padding: 0 0 23px; font-size: 14px; color: #526079; text-align: left; line-height: 1.6; }
.login-box-body .form-control, .register-box-body .form-control { min-height: 46px; height: 46px; font-size: 14px; padding: 12px 14px; }
.login-box-body .form-control-feedback, .register-box-body .form-control-feedback { height: 46px; line-height: 46px; }
.login-box-body .btn, .register-box-body .btn { min-height: 42px; }
.login-box-body form > .row, .register-box-body form > .row { display: flex; align-items: center; flex-wrap: wrap; }
.login-box-body a, .register-box-body a { font-size: 12px; }
.login-box > .box-footer, .register-box > .box-footer { margin: 24px -27px -27px; padding: 18px 20px; color: #7b8798; font-size: 12px; background: #f8fafc; border-radius: 0 0 17px 17px; }
.register-box-body .free-credits-badge { background: #e9f8f1; color: #168a62; border: 1px solid #d0ecdf; border-radius: 8px; font-size: 12px; }

/* The original desktop mini-sidebar remains available. */
@media (min-width: 1101px) {
  body.sidebar-mini.sidebar-collapse .main-header .logo { width: 50px; padding: 0 7px; }
  body.sidebar-mini.sidebar-collapse .main-header .logo .logo-lg { display: none; }
  body.sidebar-mini.sidebar-collapse .main-header .logo .logo-mini { display: flex; align-items: center; justify-content: center; height: 72px; }
  body.sidebar-mini.sidebar-collapse .main-header .logo .logo-mini img { width: 34px; height: 34px; }
  body.sidebar-mini.sidebar-collapse .main-header .navbar { margin-left: 50px; }
  body.sidebar-mini.sidebar-collapse .main-sidebar { width: 50px !important; overflow-x: visible; }
  body.sidebar-mini.sidebar-collapse .main-sidebar .sidebar { padding-inline: 0; }
  body.sidebar-mini.sidebar-collapse .sidebar-menu > li > a { border-radius: 0; padding-left: 16px; }
  body.sidebar-mini.sidebar-collapse .sidebar-menu > li > a > .fa { width: 20px; }
  body.sidebar-mini.sidebar-collapse .sidebar-menu > li.active::before { left: 0; }
  body.sidebar-mini.sidebar-collapse .content-wrapper,
  body.sidebar-mini.sidebar-collapse .main-footer { margin-left: 50px !important; }
  body.sidebar-mini.sidebar-collapse .sidebar-menu > li:hover > a > span:not(.pull-right) { left: 50px; background: #172033; color: #eaf1ff; padding: 12px 15px; top: 0; border-radius: 0 9px 9px 0; }
}

/* Drawer overlay is wired by the theme script without replacing navigation. */
.fx-sidebar-backdrop { display: none; }
@media (max-width: 1100px) {
  body[class*="skin-"] .main-header .logo { width: 190px; padding: 0 17px; background: #fff; color: var(--fx-text); border-bottom: 1px solid var(--fx-border); }
  body[class*="skin-"] .main-header .logo:hover { background: #fff; }
  .fx-brand-name { color: #172033; }
  .fx-brand-caption { color: #8793a4; }
  .main-header .logo .logo-lg { display: flex !important; }
  .main-header .logo .logo-mini { display: none !important; }
  body[class*="skin-"] .main-header .navbar { margin-left: 190px !important; padding: 0 17px 0 0; }
  body[class*="skin-"] .main-sidebar,
  body.sidebar-mini.sidebar-collapse .main-sidebar {
    width: min(304px, 86vw) !important;
    transform: translateX(-100%) !important;
    transition: transform .2s ease;
    box-shadow: none;
  }
  body.sidebar-open .main-sidebar,
  body.sidebar-open.sidebar-collapse .main-sidebar { transform: translateX(0) !important; box-shadow: 12px 0 32px rgba(15, 23, 42, .18); }
  body.sidebar-mini.sidebar-collapse .main-sidebar .user-panel > .info,
  body.sidebar-mini.sidebar-collapse .sidebar-menu > li > a > span,
  body.sidebar-mini.sidebar-collapse .sidebar-menu li.header { display: block !important; }
  body.sidebar-mini.sidebar-collapse .sidebar-menu > li > a > span { position: static; width: auto; padding: 0; background: transparent; }
  body.sidebar-mini.sidebar-collapse .sidebar-menu > li > .treeview-menu { position: static; width: auto; margin-left: 0; }
  body[class*="skin-"] .content-wrapper,
  body[class*="skin-"] .main-footer,
  body.sidebar-mini.sidebar-collapse .content-wrapper,
  body.sidebar-mini.sidebar-collapse .main-footer { margin-left: 0 !important; transform: none !important; }
  .fx-sidebar-backdrop { position: fixed; inset: 72px 0 0; z-index: 1000; border: 0; padding: 0; background: rgba(15, 23, 42, .42); cursor: pointer; }
  body.sidebar-open .fx-sidebar-backdrop { display: block; }
  .content-header { padding: 24px 22px 4px; }
  .content { padding: 19px 22px 24px; }
}
@media (max-width: 767px) {
  .main-header .navbar-custom-menu { float: right; }
  .main-header .navbar-custom-menu > .navbar-nav { float: right; margin: 0; }
  .main-header .navbar-custom-menu > .navbar-nav > li { float: left; }
  .main-header .logo { float: left; }
  .main-header .navbar { float: none; width: auto; }
  .content-header > .breadcrumb { position: static; display: block; margin: 10px 0 0; padding: 0; background: transparent; }
  .content-header h1 { font-size: 22px; }
  .content-header h1 small { display: block; margin-left: 0; margin-top: 6px; }
  .content-header h1 > .pull-right { float: none !important; display: block; margin-top: 12px !important; }
  .content-header { padding: 21px 15px 2px; }
  .content { padding: 16px 15px 22px; }
  .content > .row { margin-left: -7px; margin-right: -7px; }
  .content > .row > [class*="col-"], .content > .row > a > [class*="col-"] { padding-left: 7px; padding-right: 7px; }
  .box-header { padding: 15px; }
  .box-body { padding: 15px; }
  .box-footer { padding: 14px 15px; }
  .box-header .pull-left, .box-header .pull-right { max-width: 100%; }
  .box-header .pull-right { display: flex; gap: 5px; flex-wrap: wrap; }
  .box-header .select-user { width: min(220px, 100%); margin-bottom: 9px; }
  .small-box > .inner { padding: 17px 53px 16px 15px; }
  .small-box > .icon { width: 32px; height: 32px; top: 19px; right: 12px; border-radius: 9px; font-size: 19px; }
  .small-box:hover .icon { font-size: 19px; }
  .small-box h3 { font-size: 25px; }
  .small-box p { font-size: 11px; }
  .small-box { min-height: 110px; margin-bottom: 14px; }
  .dataTables_wrapper > .row > [class*="col-"] { width: 100%; }
  div.dataTables_wrapper div.dataTables_length,
  div.dataTables_wrapper div.dataTables_filter,
  div.dataTables_wrapper div.dataTables_info,
  div.dataTables_wrapper div.dataTables_paginate { text-align: left; }
  div.dataTables_wrapper div.dataTables_filter { margin-top: 9px; }
  .dataTables_wrapper .dataTables_filter input { max-width: calc(100vw - 155px); }
  div.dataTables_wrapper div.dataTables_paginate ul.pagination { margin-top: 9px; display: flex; flex-wrap: wrap; }
  .nav-tabs-custom > .nav-tabs { display: flex; overflow-x: auto; flex-wrap: nowrap; -webkit-overflow-scrolling: touch; padding-inline: 9px; }
  .nav-tabs-custom > .nav-tabs > li { float: none; flex-shrink: 0; }
  .nav-tabs-custom > .tab-content { padding: 15px; }
  .modal-dialog { margin: 16px 12px; }
  .modal-header { padding: 17px; }
  .modal-body { padding: 17px; }
  .modal-footer { padding: 12px 17px; }
  .modal-title { font-size: 16px; }
  .main-footer { padding: 14px 16px; }
}
@media (max-width: 520px) {
  body[class*="skin-"] .main-header .logo { width: 157px; padding-inline: 13px; }
  body[class*="skin-"] .main-header .navbar { margin-left: 157px !important; padding-right: 8px; }
  .main-header .logo .logo-lg { gap: 8px; }
  .main-header .logo img.fx-brand-emblem { width: 32px; height: 32px; }
  .fx-brand-name { font-size: 18px; }
  .fx-brand-caption { font-size: 7px; letter-spacing: 1px; }
  body[class*="skin-"] .main-header .navbar .nav > li > a { padding-inline: 8px; }
  .main-header .navbar .user-name { display: none; }
  .box-header .pull-right { float: none !important; clear: both; padding-top: 10px; }
  .box-header .pull-left { float: none !important; }
  .small-box h3 { font-size: 23px; }
  body.login-page, body.register-page { padding: 72px 14px 25px; }
  .login-page .login-box, .register-page .register-box { padding: 22px; margin: 0 auto 20px; }
  .login-box > .box-footer, .register-box > .box-footer { margin: 24px -22px -22px; }
  .login-box-body .form-control, .register-box-body .form-control { font-size: 16px; }
  .login-box-body form > .row > [class*="col-"],
  .register-box-body form > .row > [class*="col-"] { width: 100%; }
  .login-box-body form > .row .btn-block,
  .register-box-body form > .row .btn-block { margin-top: 14px; }
}
@media (max-width: 640px) {
  .fx-page-context { display: none; }
}
.fx-login-brand .fx-brand-caption { font-size: 9px; }
body.fx-webview .content-wrapper { margin: 0 !important; }
body.fx-webview .wrapper { background: var(--fx-bg); }
@media (prefers-reduced-motion: reduce) {
  .main-sidebar, .main-header .navbar, .content-wrapper, .main-footer,
  .small-box, .btn { transition: none !important; }
}
@media print {
  .main-header, .main-sidebar, .fx-sidebar-backdrop { display: none !important; }
  body[class*="skin-"] .content-wrapper { margin: 0 !important; }
  .main-footer { margin-left: 0 !important; }
}
