
/*
  Language Dropdown
*/
.lang-dropdown {
    display: inline-block;
    position: relative;
}

.lang-toggle {
    position: relative;
}

.lang-flag-current {
    width: 17px;
    height: 17px;
    border-radius: 50%;
    object-fit: cover;
    vertical-align: middle;
}

.lang-flag-current + .lang-icon-fallback {
    display: none;
}

.lang-flag {
    width: 17px;
    height: 17px;
    border-radius: 50%;
    object-fit: cover;
    margin-right: 6px;
    vertical-align: middle;
}

.lang-dropdown-menu {
    display: none;
    position: absolute;
    top: 100%;
    right: -6px;
    min-width: 100px;
    margin: 4px 0 0 0;
    padding: 3px 0;
    list-style: none;
    background: var(--admin-surface-1);
    border: 1px solid #dee2e6;
    border-radius: 4px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    z-index: 1100;
}

.lang-dropdown-menu:before {
    content: '';
    position: absolute;
    top: -6px;
    right: 10px;
    width: 0;
    height: 0;
    border-left: 6px solid transparent;
    border-right: 6px solid transparent;
    border-bottom: 6px solid #fff;
}

.lang-dropdown-menu:after {
    content: '';
    position: absolute;
    top: -7px;
    right: 9px;
    width: 0;
    height: 0;
    border-left: 7px solid transparent;
    border-right: 7px solid transparent;
    border-bottom: 7px solid #dee2e6;
    z-index: -1;
}

.lang-dropdown.show .lang-dropdown-menu {
    display: block;
}

.lang-dropdown-menu li a {
    display: flex;
    align-items: center;
    padding: 4px 10px;
    color: #333;
    text-decoration: none;
    font-size: 12px;
}

.lang-dropdown-menu li a:hover {
    background: var(--admin-surface-2);
    color: #000;
}

.lang-dropdown-menu li a .lang-flag {
    width: 17px;
    height: 17px;
    border-radius: 50%;
    object-fit: cover;
    margin-right: 6px;
    vertical-align: middle;
    flex-shrink: 0;
    position: static;
    top: auto;
    left: auto;
}

.lang-dropdown .lang-flag-current {
    width: 17px;
    height: 17px;
    border-radius: 50%;
    object-fit: cover;
    margin-right: 0;
    margin-top: -3px;
    vertical-align: middle;
    position: static;
    top: auto;
    left: auto;
}

.widget-hidden {
    display: none;
}

.widget-toggle-list {
    display: grid;
    grid-template-columns: 1fr;
    gap: 8px;
}

@media (min-width: 768px) {
    .widget-toggle-list {
        grid-template-columns: 1fr 1fr;
        column-gap: 16px;
    }
}

.widget-toggle-item {
    margin: 0;
}


.panel-footer a,
.card-footer a {
    color: #777;
}

.panel-footer,
.card-footer {
    color: #555;
    padding: 10px 15px;
    background-color: var(--admin-surface-1);
}

/* Light mode card header - dark text on light bg */
.card-header {
    background-color: var(--admin-surface-2);
    border-bottom: 1px solid #dee2e6;
}

@media print {
    .journal-header {
        border: none !important;
        background: transparent !important;
        padding: 0 0 0.35rem 0 !important;
        margin-bottom: 0.15rem !important;
    }

    .journal-header .journal-title {
        display: block !important;
        color: #000 !important;
        font-weight: 600;
    }

    .journal-header .journal-title i,
    .journal-header .badge,
    .journal-header .btn,
    .journal-header .print-hide {
        display: none !important;
    }
}

.card-header a:not(.btn) {
    color: #333;
    font-weight: bold;
}

/* Ensure filled buttons have proper text color regardless of anchor styling */
a.btn-primary,
a.btn-primary i,
a.btn-success,
a.btn-success i,
a.btn-danger,
a.btn-danger i,
a.btn-warning,
a.btn-warning i,
a.btn-info,
a.btn-info i {
    color: #fff !important;
}

/* Preserve colored headers for widget cards */
.card.widget-colored .card-header a,
.card.widget-colored .card-header .widget-title {
    color: #fff;
}

.card.widget-colored .widget-icon {
    background: rgba(255, 255, 255, 0.2);
    color: #fff;
}

/* Custom widget colors (from module settings) */
.card.widget-colored {
    border-color: var(--widget-color);
}

.card.widget-colored .card-header {
    border-color: var(--widget-color);
    background-color: var(--widget-color);
    color: #fff;
}

/* Colored panel headers - white text */
.panel-heading a,
.card.panel-yellow .card-header a,
.card.panel-blue .card-header a,
.card.panel-green .card-header a,
.card.panel-red .card-header a {
    color: #fff;
    font-weight: bold;
}

.panel-yellow,
.card.panel-yellow {
    border-color: #e49e3a;
}

.panel-yellow .panel-heading,
.card.panel-yellow .card-header {
    border-color: #e49e3a;
    color: #fff;
    background-color: #f0ad4e;
}

.panel-blue,
.card.panel-blue {
    border-color: #04c;
}

.panel-blue .panel-heading,
.card.panel-blue .card-header {
    border-color: #04c;
    color: #fff;
    background-color: var(--admin-accent);
}

.panel-green,
.card.panel-green {
    border-color: #5cb85c;
}

.panel-green .panel-heading,
.card.panel-green .card-header {
    border-color: #5cb85c;
    color: #fff;
    background-color: #5cb85c;
}

.panel-red {
    border-color: #d9534f;
}

.panel-red .panel-heading {
    border-color: #d9534f;
    color: #fff;
    background-color: #d9534f;
}

.card.panel-red {
    border-color: #d9534f;
}

.card.panel-red .card-header {
    border-color: #d9534f;
    color: #fff;
    background-color: #d9534f;
}

.admin-widget .card.panel-red .card-header {
    border-color: #d9534f;
    background-color: #d9534f;
}

.admin-widget .card.panel-red .card-header a,
.admin-widget .card.panel-red .card-header .widget-title {
    color: #fff;
}

/*
  Tables
*/
caption {
    padding-left: 10px;
}

table.table-small,
table.table-small {
    margin: 0;
}

table.table-small tr th,
table.table-small tr td {
    padding: 6px;
    border-top: 1px solid #ddd;
}

table.table-small tr:first-child th,
table.table-small tr:first-child td {
    border: 0;
}

.bs-simple {
    margin-bottom: 20px;
}

.bs-simple .table {
    margin-bottom: 0;
}


/*
  Widgets
*/
.admin-widget {
    margin-bottom: 2px;
}

.admin-widget .card-header {
    cursor: grab;
}

.admin-widget .card-header:active {
    cursor: grabbing;
}

.admin-widget.widget-ghost {
    opacity: 0.4;
}

.admin-widget.widget-chosen {
    opacity: 0.8;
}

.admin-widget.widget-drag {
    opacity: 1;
}

.admin-widget .card-header a {
    font-weight: 600;
}

.admin-widget .widget-title {
    font-weight: 600;
}

.admin-widget .widget-link {
    font-size: 14px;
    opacity: 0.8;
    padding: 4px 6px;
    border-radius: 6px;
}

.admin-widget .widget-link:hover {
    opacity: 1;
}

.admin-widget .widget-icon {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.08);
    font-size: 13px;
}

.admin-widget .list-group-item {
    border-left: 0;
    border-right: 0;
    padding: 0.5rem 0.75rem;
    font-size: 0.875rem;
    line-height: 1.25;
}

.admin-widget .widget-row {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.admin-widget .widget-row-link {
    cursor: pointer;
}

.admin-widget .widget-row-link:hover {
    background-color: rgba(13, 110, 253, 0.04);
}

.admin-widget .widget-row-link .widget-truncate {
    margin-left: 0.25rem;
}

.admin-widget .widget-badge-date {
    font-weight: 600;
    min-width: 84px;
    text-align: center;
}

.admin-widget .widget-truncate {
    max-width: 180px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.admin-widget .widget-rate-list {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: minmax(90px, auto);
    gap: 0.75rem;
    align-items: center;
}

.admin-widget .widget-rate {
    display: inline-flex;
    gap: 0.35rem;
    font-weight: 600;
    justify-content: flex-end;
}

.admin-widget .widget-rate .currency {
    color: #9aa2ad;
    font-weight: 700;
}

.admin-widget .widget-rate .value {
    font-variant-numeric: tabular-nums;
    min-width: 64px;
    text-align: right;
}

.admin-widget .widget-amount {
    font-weight: 600;
    white-space: nowrap;
    font-variant-numeric: tabular-nums;
}

.admin-widget .card-body {
    background-color: var(--admin-surface-1);
}

.admin-widget .list-group-item .badge {
    font-size: 0.75rem;
}

.admin-widget .vat-widget-compact small {
    font-size: 0.8rem;
}

.admin-widget .vat-widget-compact .badge {
    font-size: 0.68rem;
    padding: 0.2rem 0.45rem;
}

.widget-big {
    text-align: center;
    font-size: 16px;
    padding-top: 30px;
}

.widget-ellipsis {
    display: block;
    display: -webkit-box;
    max-width: 650px;
    height: 59px;
    margin: 0 auto;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
}

.widget-ellipsis.widget-ellipsis-sm {
    height: 40px;
    -webkit-line-clamp: 2;
}

.widget-ellipsis.widget-ellipsis-xs {
    height: 30px;
    -webkit-line-clamp: 2;
}


/*
  Buttons
*/
.btn-circle {
    width: 42px;
    height: 42px;
    border-radius: 21px;
    padding: 0;
    position: fixed;
    top: auto;
    right: 15px;
    bottom: 30px;
    left: auto;
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
}

.btn-circle2 {
    width: 45px;
    height: 45px;
    border-radius: 25px;
    padding: 0;
    position: fixed;
    top: auto;
    right: 15px;
    bottom: 80px;
    left: auto;
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
}

.btn-default-nover {
    color: #333;
    background-color: var(--admin-surface-1);
    border-color: #ccc;
}

.btn-primary-nover {
    color: #000;
    background-color: var(--admin-accent);
    border-color: var(--admin-accent-strong);
}

.btn-success-nover {
    color: #fff;
    background-color: var(--admin-success);
    border-color: var(--admin-success);
}

.btn-info-nover {
    color: #fff;
    background-color: var(--admin-accent-strong);
    border-color: var(--admin-accent-strong);
}

.btn-warning-nover {
    color: #000;
    background-color: var(--admin-warning);
    border-color: var(--admin-warning);
}

.btn-danger-nover {
    color: #fff;
    background-color: var(--admin-danger);
    border-color: var(--admin-danger);
}

.btn-primary-nover:hover,
.btn-success-nover:hover,
.btn-info-nover:hover,
.btn-warning-nover:hover,
.btn-danger-nover:hover {
    color: #fff;
    cursor: default;
}

.btn-suspended {
    color: #fff;
    background-color: #d9534f;
    border-color: #d43f3a;
}

.btn-inctive {
    color: #fff;
    background-color: #f0ad4e;
    border-color: #eea236;
}

.btn-active {
    color: #fff;
    background-color: #5cb85c;
    border-color: #4cae4c;
}

.btn-suspended:hover,
.btn-inctive:hover,
.btn-active:hover {
    color: #fff;
    cursor: default;
}

.ico-circle {
    position: relative;
    width: 45px;
    height: 45px;
    border-radius: 25px;
    background: #ddd;
    font-size: 28px;
    line-height: 45px;
    text-align: center;
}


/*
  Grouping
*/
.bs-row {
    margin-bottom: 10px;
}

.bs-simple {
    border: 1px solid #ddd;
    border-radius: 4px 4px 0 0;
    background-color: var(--admin-surface-1);
}

.bs-callout {
    position: relative;
    padding: 20px;
    margin: 20px 0;
    border: 1px solid #eee;
    border-left-width: 5px;
    border-radius: 3px;
}

.bs-callout h1,
.bs-callout h2,
.bs-callout h3,
.bs-callout h4,
.bs-callout h5 {
    margin-top: 0;
}

.bs-callout-info {
    border-left-color: var(--admin-accent);
}

.bs-callout-warning {
    border-left-color: var(--admin-warning);
}

.bs-callout-danger {
    border-left-color: var(--admin-danger);
}

.bs-callout-bd-info {
    border-top-color: var(--admin-accent);
    border-right-color: var(--admin-accent);
    border-bottom-color: var(--admin-accent);
}

.bs-callout-bd-warning {
    border-top-color: var(--admin-warning);
    border-right-color: var(--admin-warning);
    border-bottom-color: var(--admin-warning);
}

.bs-callout-bd-danger {
    border-top-color: var(--admin-danger);
    border-right-color: var(--admin-danger);
    border-bottom-color: var(--admin-danger);
}


/*
  Users and roles
*/
.rbac-check {
    margin-bottom: 5px;
}

.rbac-user {
    height: 129px;
    margin: 0 0 30px 0;
}

.rbac-user h3 {
    margin-bottom: 5px;
}

.rbac-user .rbac-user-info {
    padding: 0 0 0 15px;
}

.rbac-user .rbac-user-info em {
    display: block;
    font-size: 12px;
    margin-top: 2px;
}


/*
  Forms
*/
.form-area {
    height: 110px !important;
}

.form-margin {
    margin: 0 15px;
}

.form-padding {
    padding-left: 15px;
    padding-right: 15px;
}

.form-spacing {
    padding-top: 15px;
    padding-bottom: 15px;
}

.form-table {
    margin: 0;
}

.form-group {
    position: relative;
}

.form-group.has-error input {
    margin: 0;
    z-index: 10;
}

.form-group .help-block.with-errors {
    margin: 0;
    padding: 0;
}

.form-group.has-error .help-block.with-errors {
    position: absolute;
    top: 10px;
    right: 10px;
    border-radius: 3px;
    background: #a94442;
    color: #fff;
    padding: 2px 5px;
    font-size: 12px;
    z-index: 11;
}

.form-group.has-error .help-block.with-errors.form-validator-errors {
    position: absolute;
    max-width: 200px;
    top: auto;
    right: auto;
    bottom: 35px;
    left: 2px;
    z-index: 12;
}

.form-group.has-error .help-block.with-errors.form-validator-errors:after {
    content: '';
    display: inline-block;
    border-top: 7px solid #a94442;
    border-left: 7px solid rgba(0, 0, 0, 0);
    border-right: 7px solid rgba(0, 0, 0, 0);
    position: absolute;
    bottom: -7px;
    left: 6px;
}

.form-auth {
    max-width: 330px;
    padding: 15px;
    margin: 0 auto;
}

.form-auth .form-group {
    margin: 0;
}

.form-auth .form-control {
    position: relative;
    height: auto;
    box-sizing: border-box;
    padding: 10px;
    font-size: 16px;
}

.form-auth .form-control:focus {
    z-index: 2;
}

.form-auth input[type="email"],
.form-auth input[type="text"]:not([type="hidden"]):first-of-type {
    margin-bottom: -1px !important;
    border-bottom-right-radius: 0 !important;
    border-bottom-left-radius: 0 !important;
    border-top-left-radius: 8px !important;
    border-top-right-radius: 8px !important;
}

.form-auth input[type="password"] {
    margin-bottom: -1px !important;
    border-radius: 0 !important;
}

.form-auth input[type="password"]:last-of-type {
    margin-bottom: -1px !important;
    border-radius: 0 !important;
}

.form-auth.form-setup .form-auth-stack > .form-control {
    margin-bottom: -1px !important;
    border-radius: 0 !important;
}

.form-auth.form-setup .form-auth-stack > .form-control:first-child {
    border-top-left-radius: 8px !important;
    border-top-right-radius: 8px !important;
}

.form-auth button {
    border-top-left-radius: 0 !important;
    border-top-right-radius: 0 !important;
    border-bottom-left-radius: 8px !important;
    border-bottom-right-radius: 8px !important;
    background: #0275d8;
}

.form-auth button:hover {
    background: #0269c2;
}

body.nav-hide {
    height: 100%;
    overflow: visible !important;
}

/* Login page vertical centering */
body.nav-hide .wrap {
    display: flex !important;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    padding: 40px 20px;
    box-sizing: border-box;
}

/* Login page glass card — matches admin chrome panel style */
body.nav-hide #page.container {
    max-width: 420px;
    width: 100%;
    background: var(--admin-chrome-bg);
    border: 1px solid var(--admin-border-soft);
    border-radius: 18px;
    backdrop-filter: blur(28px);
    -webkit-backdrop-filter: blur(28px);
    padding: 48px 40px 40px;
    box-shadow: var(--admin-float-shadow);
}

body.nav-hide h1 {
    color: var(--admin-text-main);
    font-size: 1.55rem;
    font-weight: 600;
    margin-bottom: 4px;
}

body.nav-hide p.lead {
    color: var(--admin-text-soft);
    font-size: 0.88rem;
    margin-bottom: 28px;
}

body.nav-hide .form-auth {
    max-width: 100%;
    padding: 0;
}

body.nav-hide #invite-form .form-control {
    margin-bottom: -1px !important;
    border-radius: 0 !important;
}

body.nav-hide #invite-form .form-control:first-of-type {
    border-top-left-radius: 8px !important;
    border-top-right-radius: 8px !important;
}

body.nav-hide #invite-form input[disabled] {
    background: var(--admin-surface-2);
    color: var(--admin-text-soft);
    cursor: default;
    opacity: 1;
}

body.nav-hide .form-auth .form-control {
    background: var(--admin-surface-1);
    border-color: var(--admin-border-soft);
    color: var(--admin-text-main);
    transition: background 0.15s, border-color 0.15s, box-shadow 0.15s;
}

body.nav-hide .form-auth .form-control::placeholder {
    color: var(--admin-text-muted);
}

body.nav-hide .form-auth .form-control:focus {
    background: var(--admin-surface-1);
    border-color: rgba(255, 159, 10, 0.60);
    box-shadow: 0 0 0 3px rgba(255, 159, 10, 0.14);
    color: var(--admin-text-main);
    outline: none;
}

body.nav-hide .form-auth button.btn-primary {
    background: linear-gradient(135deg, #ff9f0a 0%, #d97f04 100%);
    border: none;
    color: #000;
    font-weight: 700;
    letter-spacing: 0.04em;
    padding-top: 12px;
    padding-bottom: 12px;
    font-size: 15px;
    border-radius: 0 0 8px 8px !important;
    transition: opacity 0.15s, transform 0.10s;
}

body.nav-hide .form-auth button.btn-primary:hover {
    opacity: 0.88;
    transform: translateY(-1px);
}

/* Secondary icon button (recovery key / back to login) — overrides base .btn-circle */
body.nav-hide .btn-circle {
    bottom: 12px;
    background: var(--admin-icon-surface);
    border: 1px solid var(--admin-border-soft);
    color: var(--admin-text-soft);
    text-decoration: none;
    transition: background 0.15s, color 0.15s;
}

body.nav-hide .btn-circle:hover {
    background: var(--admin-icon-surface-hover);
    color: var(--admin-text-main);
}

/* Alert inside login form */
body.nav-hide .alert {
    background: rgba(255, 69, 58, 0.12);
    border-color: rgba(255, 69, 58, 0.32);
    color: var(--admin-danger);
    margin-bottom: 20px;
    border-radius: 8px;
}

/* Dark mode toggle fixed button (visible only on login/recover pages) */
.login-theme-toggle {
    display: none;
}

body.nav-hide .login-theme-toggle {
    display: flex !important;
    align-items: center;
    justify-content: center;
    position: fixed;
    top: 16px;
    right: 16px;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: 2px solid var(--admin-border-strong);
    background: var(--admin-surface-1);
    color: var(--admin-text-main);
    cursor: pointer;
    z-index: 9999;
    font-size: 0.88rem;
    backdrop-filter: blur(28px);
    -webkit-backdrop-filter: blur(28px);
    box-shadow: var(--admin-float-shadow);
    transition: background 0.15s, color 0.15s, transform 0.15s;
}

body.nav-hide .login-theme-toggle:hover {
    background: var(--admin-surface-2);
    color: var(--admin-accent);
    transform: scale(1.05);
}

.lang-entry .input-group .input-group-addon {
    cursor: pointer;
}

.lang-entry:hover .input-group .input-group-addon {
    color: #e00;
}

.lang-icon {
    width: 14px;
    height: 14px;
    border-radius: 7px;
}

.lang-flag {
    width: 50px;
    height: auto;
    position: relative;
    top: -10px;
    left: -15px;
}


/*
  Table sorter
*/
th.sortable,
td.sortable {
    position: relative;
    cursor: pointer;
    padding-right: 25px !important;
}

th.sortable.text-end,
td.sortable.text-end {
    padding-right: 25px !important;
}

th.sortable.text-end:before,
th.sortable.text-end:after,
td.sortable.text-end:before,
td.sortable.text-end:after {
    right: 5px;
}

th.sortable:before,
td.sortable:before,
th.sortable:after,
td.sortable:after {
    content: ' ';
    display: block;
    width: 0;
    height: 0;
    position: absolute;
    right: 10px;
    color: #aaa;
    border-right: 4px solid rgba(0, 0, 0, 0);
    border-left: 4px solid rgba(0, 0, 0, 0);
}

th.sortable:before,
td.sortable:before {
    top: 13px;
    border-bottom: 4px solid;
}

th.sortable:after,
td.sortable:after {
    top: 18px;
    border-top: 4px solid;
}

th.sortable[data-sorter="desc"]:before,
td.sortable[data-sorter="desc"]:before {
    color: var(--admin-accent);
}

th.sortable[data-sorter="asc"]:after,
td.sortable[data-sorter="asc"]:after {
    color: var(--admin-accent);
}

.table>tbody>tr>td,
.table>tbody>tr>th,
.table>tfoot>tr>td,
.table>tfoot>tr>th,
.table>thead>tr>td,
.table>thead>tr>th {
    vertical-align: middle;
}


/*
  Table sorter
*/
.lang-entries .lang-entry {
    color: var(--admin-accent);
    text-decoration: none;
}

.lang-entries .lang-entry:hover {
    color: var(--admin-accent);
    text-decoration: underline;
}

.lang-entries .lang-entry.selected {
    color: #d9534f;
    text-decoration: underline;
}


/*
  Medium Editor (Centralized)
*/
textarea.medium-editor-source {
    display: none !important;
}

.medium-editor-wrapper {
    border: 1px solid var(--admin-border-soft);
    border-radius: 0.375rem;
    background-color: var(--admin-surface-1);
    padding: 0.75rem;
}

.medium-editor {
    min-height: 260px;
    outline: none;
    color: var(--admin-text-main);
}

.medium-editor img {
    max-width: 100%;
    height: auto;
}

body.moon .medium-editor h1,
body.moon .medium-editor h2,
body.moon .medium-editor h3,
body.moon .medium-editor h4,
body.moon .medium-editor h5,
body.moon .medium-editor h6 {
    color: var(--admin-text-main);
}

/*
  Roles & Permissions Page
*/
.role-item {
    padding: 0.875rem 1rem;
    border-bottom: 1px solid var(--admin-border-soft);
    cursor: pointer;
    transition: all 0.15s ease;
    background: transparent;
}
.role-item:hover {
    background: var(--admin-surface-3);
}
.role-item.active {
    background: var(--admin-accent-soft);
    border-left: 4px solid var(--admin-accent);
    padding-left: calc(1rem - 4px);
}
.role-name {
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--admin-text-main);
}
.role-item .badge {
    font-weight: 500;
    font-size: 0.75rem;
}
.roles-page .role-delete-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 2rem;
    line-height: 1;
    flex-shrink: 0;
}
.roles-page .btn-delete-slot {
    margin-left: 0.5rem;
    display: inline-flex;
    align-items: center;
    justify-content: flex-end;
    flex-shrink: 0;
}
.roles-list-col {
    background-color: var(--admin-surface-2);
}
body.moon .roles-list-col {
    background-color: var(--admin-surface-1);
    border-color: var(--admin-border-soft) !important;
}
.roles-list {
    max-height: calc(100vh - 293px);
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: var(--admin-border-strong) transparent;
}
.roles-list::-webkit-scrollbar { width: 4px; }
.roles-list::-webkit-scrollbar-track { background: transparent; }
.roles-list::-webkit-scrollbar-thumb { background: var(--admin-border-strong); border-radius: 2px; }
.permissions-tree-container {
    max-height: calc(100vh - 350px);
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: var(--admin-border-strong) transparent;
}
.permissions-tree-container::-webkit-scrollbar { width: 4px; }
.permissions-tree-container::-webkit-scrollbar-track { background: transparent; }
.permissions-tree-container::-webkit-scrollbar-thumb { background: var(--admin-border-strong); border-radius: 2px; }
.module-group .card-header {
    cursor: pointer;
    user-select: none;
    background: var(--admin-surface-2);
    border-bottom: 1px solid var(--admin-border-soft);
}
.module-group .card-header:hover {
    background: var(--admin-surface-3);
}
.module-name {
    font-weight: 600;
    font-size: 1rem;
}
.module-icon {
    color: var(--admin-accent);
    width: 24px;
}
.module-controls {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}
.toggle-icon {
    transition: transform 0.2s;
    color: var(--admin-text-muted);
}
.module-group.collapsed .toggle-icon {
    transform: rotate(-90deg);
}
.module-group.collapsed .card-body {
    display: none;
}
.roles-page .perm-item {
    padding: 0.75rem;
    background: var(--admin-surface-2);
    border-radius: 0.375rem;
    border: 1px solid var(--admin-border-soft);
    transition: all 0.15s;
    margin-bottom: 0;
}
.roles-page .perm-item:hover {
    background: var(--admin-accent-soft);
    border-color: var(--admin-accent-strong);
}
.roles-page .form-check-input:checked ~ .form-check-label {
    font-weight: 600;
    color: var(--admin-accent);
}
.category-group {
    padding-left: 1.5rem;
    border-left: 3px solid var(--admin-accent);
}
.category-header {
    font-weight: 700;
    font-size: 0.875rem;
    color: var(--admin-text-soft);
    margin-bottom: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

/* Roles page dark mode handled by general overrides */


/*
  Users Page
*/
.user-avatar {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    font-weight: bold;
    color: #fff;
    position: relative;
    flex-shrink: 0;
}
.user-avatar img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border-radius: 50%;
}
.user-avatar-sm {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: bold;
    color: #fff;
    position: relative;
    flex-shrink: 0;
}
.user-avatar-sm img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border-radius: 50%;
}
.user-card {
    transition: transform 0.2s, box-shadow 0.2s;
}
.user-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}
.min-width-0 {
    min-width: 0;
}
.user-row:hover {
    background-color: rgba(0,0,0,0.02);
}
.view-toggle.active {
    background-color: var(--admin-accent);
    border-color: var(--admin-accent);
    color: #000;
}
.table th.check-col,
.table td.check-col {
    width: 40px;
    text-align: center;
}
.bulk-actions {
    display: none;
    padding: 0.5rem 1rem;
    background-color: var(--admin-accent-soft);
    border-bottom: 1px solid var(--admin-border-soft);
}
.bulk-actions.show {
    display: flex;
}
.bulk-actions-buttons {
    display: flex;
    align-items: center;
}
.bulk-actions .bulk-delete {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: auto;
    max-width: none;
    padding: 0.375rem 0.75rem;
    white-space: nowrap;
}
.filter-tags .badge {
    font-weight: normal;
    font-size: 0.75em;
}
.active-filters {
    padding-top: 0.5rem;
    border-top: 1px solid var(--admin-border-soft);
}

/* Users page dark mode */
body.moon .user-card {
    background-color: var(--admin-surface-1);
    border-color: var(--admin-border-soft);
}
body.moon .user-card:hover {
    box-shadow: var(--admin-panel-shadow);
}
body.moon .user-card .card-footer {
    border-color: var(--admin-border-soft);
}
body.moon .user-row:hover {
    background-color: var(--admin-surface-3);
}
body.moon .view-toggle.active {
    background-color: var(--admin-surface-3);
    border-color: var(--admin-border-strong);
    color: var(--admin-accent);
}
body.moon .bulk-actions {
    background-color: var(--admin-surface-2);
    border-bottom-color: var(--admin-border-soft);
}
body.moon .active-filters {
    border-top-color: var(--admin-border-soft);
}


/*
  User Edit Page
*/
.admin-user-summary-card .card-body {
    padding: 1.5rem 1rem;
}

.admin-user-avatar {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid #e9ecef;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

body.moon .admin-user-avatar {
    border-color: var(--admin-border-soft);
}

.admin-user-layout .card {
    border-radius: 0.5rem;
}

.admin-user-layout .card-header {
    font-weight: 600;
}

.role-badge {
    display: inline-flex;
    align-items: center;
    padding: 0.5rem 0.75rem;
    margin: 0.25rem;
    background: var(--admin-surface-2);
    border: 1px solid #dee2e6;
    border-radius: 0.375rem;
    font-size: 0.875rem;
}
body.moon .role-badge {
    background: var(--admin-surface-2);
    border-color: var(--admin-border-soft);
}
.role-badge .btn-remove {
    margin-left: 0.5rem;
    padding: 0;
    background: transparent;
    border: none;
    color: #dc3545;
    cursor: pointer;
    font-size: 0.75rem;
}
.role-badge .btn-remove:hover {
    color: #bb2d3b;
}
.role-template {
    display: none;
}

.business-switch-widget {
    background: var(--admin-surface-1);
}

.business-switch-widget-search-panel {
    background: var(--admin-surface-1);
}

.business-switch-widget-search-wrap {
    position: relative;
}

.business-switch-widget-search-icon {
    position: absolute;
    top: 50%;
    left: 0.85rem;
    transform: translateY(-50%);
    color: var(--admin-text-muted);
    pointer-events: none;
}

.business-switch-widget-search {
    padding-left: 2rem;
    border-color: var(--admin-border-soft);
    background: var(--admin-surface-1);
    color: var(--admin-text-main);
}

.business-switch-widget-search::placeholder {
    color: var(--admin-text-muted);
}

.business-switch-widget-list {
    display: flex;
    flex-direction: column;
}

.business-switch-widget-option {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    width: 100%;
    padding: 0.7rem 1rem;
    border: 0;
    border-bottom: 1px solid var(--admin-border-soft);
    background: transparent;
    text-align: left;
    color: var(--admin-text-main);
    transition: background 0.15s ease, color 0.15s ease;
}

.business-switch-widget-option:last-child {
    border-bottom: 0;
}

.business-switch-widget-option:hover,
.business-switch-widget-option:focus {
    background: var(--admin-surface-2);
    color: var(--admin-text-main);
}

.business-switch-widget-option.is-current {
    background: var(--admin-surface-2);
    box-shadow: inset 3px 0 0 var(--admin-accent);
}

.business-switch-widget-option-main {
    display: flex;
    min-width: 0;
}

.business-switch-widget-option-title {
    font-weight: 600;
    line-height: 1.3;
    color: inherit;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.business-switch-widget-option-detail {
    font-weight: 500;
    color: var(--admin-text-muted);
}

.business-switch-widget-option-badge,
.business-switch-widget-option-arrow {
    flex-shrink: 0;
    align-self: center;
}

.business-switch-widget-option-arrow {
    color: var(--admin-text-muted);
}

.business-switch-widget-empty {
    background: var(--admin-surface-1);
}


/*
  Languages Page
*/
.lang-card {
    transition: transform 0.2s, box-shadow 0.2s;
    cursor: pointer;
    text-decoration: none !important;
}
.lang-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}
body.moon .lang-card:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,0.3);
}
.lang-card .card-body {
    display: flex;
    align-items: center;
    padding: 0.5rem 0.75rem;
    gap: 0.5rem;
}
.lang-card .lang-name {
    font-weight: 600;
    font-size: 0.9rem;
    color: inherit;
    flex-grow: 1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.lang-card .lang-icon {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    object-fit: cover;
}
.lang-card.lang-disabled {
    opacity: 0.5;
}
.lang-card .form-check {
    min-height: auto;
    flex-shrink: 0;
}
.lang-card .lang-default-star {
    font-size: 1rem;
    color: var(--admin-border-strong);
    cursor: pointer;
    transition: color 0.15s;
    flex-shrink: 0;
}
.lang-card .lang-default-star:hover {
    color: var(--admin-warning);
}
.lang-card .lang-default-star.active {
    color: var(--admin-warning);
    cursor: default;
}
body.moon .lang-card .lang-default-star {
    color: var(--admin-text-muted);
}
body.moon .lang-card .lang-default-star:hover,
body.moon .lang-card .lang-default-star.active {
    color: var(--admin-warning);
}
.translation-group {
    margin-bottom: 1.5rem;
}
.translation-group .card-header {
    font-weight: 600;
    text-transform: capitalize;
}
.translation-entry {
    padding: 0.75rem 0;
    border-bottom: 1px solid #dee2e6;
}
body.moon .translation-entry {
    border-color: var(--admin-border-soft);
}
.translation-entry:last-child {
    border-bottom: none;
}
.translation-entry .original-text {
    font-size: 0.875rem;
    color: #6c757d;
    margin-bottom: 0.25rem;
}
body.moon .translation-entry .original-text {
    color: #a8b2c1;
}
.flag-preview {
    width: 50px;
    height: auto;
    border-radius: 4px;
}
.lang-group-header {
    cursor: pointer;
}
.lang-group-header:hover {
    background: #e9ecef;
}
.lang-group-toggle i {
    transition: transform 0.2s;
}
.lang-group-body.show ~ .card-header .lang-group-toggle i,
.translation-group.expanded .lang-group-toggle i {
    transform: rotate(180deg);
}
.translation-entry.highlight {
    background-color: var(--admin-accent-soft);
    margin: -0.75rem -1rem;
    padding: 0.75rem 1rem;
}
body.moon .lang-group-header:hover {
    background: var(--admin-surface-2);
}
body.moon .translation-entry.highlight {
    background-color: var(--admin-surface-3);
}


/*
  Config Page
*/
.config-group {
    border-bottom: 1px solid #dee2e6;
}
.config-group:last-child {
    border-bottom: none;
}
.config-group-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem 1rem;
    background: var(--admin-surface-2);
    cursor: pointer;
}
.config-group-header:hover {
    background: #e9ecef;
}
.config-group-name {
    font-weight: 600;
    font-size: 0.95rem;
}
.config-toggle {
    transition: transform 0.2s;
}
.config-group-body {
    padding: 0.5rem 1rem;
}
.config-entry {
    padding: 0.75rem 0;
    border-bottom: 1px solid #eee;
}
.config-entry:last-child {
    border-bottom: none;
}
.config-entry .config-label {
    font-weight: 600;
    font-size: 0.875rem;
    margin-bottom: 0;
}
.config-entry .config-desc {
    font-size: 0.8rem;
    color: #6c757d;
    font-style: italic;
}
.config-page .form-switch .form-check-input {
    width: 2.5em;
    height: 1.25em;
    cursor: pointer;
    margin-right: 5px;
}
.config-page .form-switch .form-check-input:checked {
    background-color: #198754;
    border-color: #198754;
}
.config-checkbox-group {
    display: flex;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
}
.config-checkbox-group .form-check {
    margin: 0;
}
.config-entry.highlight {
    background-color: var(--admin-accent-soft);
}
.config-save-row {
    padding: 0.15rem 0.4rem;
    font-size: 0.75rem;
    line-height: 1;
    opacity: 0.4;
    transition: opacity 0.2s, color 0.2s, background-color 0.2s, border-color 0.2s;
}
.config-entry:hover .config-save-row {
    opacity: 0.7;
}
.config-save-row.btn-danger,
.config-save-row.btn-outline-success {
    opacity: 1;
}
.empty-state i {
    display: block;
    margin-bottom: 1rem;
}

/*
  Notifications
*/
.admin-notification-empty-state {
    max-width: 360px;
    margin: 0 auto;
}

.admin-notification-empty-state-icon {
    width: 68px;
    height: 68px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 16px;
    border-radius: 999px;
    background: var(--admin-surface-3);
    color: var(--admin-text-muted);
    font-size: 24px;
    box-shadow: inset 0 0 0 1px var(--admin-border-soft);
}

.admin-notification-balloon-shell {
    height: 420px;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    border-radius: 18px;
    border: 1px solid var(--admin-border-soft);
    background: linear-gradient(180deg, rgba(var(--admin-shell-bg-rgb), 0.96), rgba(var(--admin-shell-bg-rgb), 0.92));
    box-shadow: var(--admin-float-shadow);
    backdrop-filter: blur(24px) saturate(150%);
    -webkit-backdrop-filter: blur(24px) saturate(150%);
}

.admin-notification-balloon-header,
.admin-notification-balloon-footer {
    flex-shrink: 0;
    padding: 0.9rem 1rem;
    background: var(--admin-surface-2);
}

.admin-notification-balloon-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    border-bottom: 1px solid var(--admin-border-soft);
}

.admin-notification-balloon-heading {
    min-width: 0;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.admin-notification-balloon-heading-icon {
    width: 38px;
    height: 38px;
    flex: 0 0 38px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    background: var(--admin-surface-3);
    color: var(--admin-text-main);
    box-shadow: inset 0 0 0 1px var(--admin-border-soft);
}

.admin-notification-balloon-heading-copy {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 0.15rem;
}

.admin-notification-balloon-heading-copy strong {
    font-size: 0.92rem;
    line-height: 1.2;
    color: var(--admin-text-main);
}

.admin-notification-balloon-heading-copy small {
    font-size: 0.74rem;
    line-height: 1.25;
    color: var(--admin-text-muted);
}

.admin-notification-balloon-mark-all {
    flex-shrink: 0;
}

.admin-notification-balloon-body {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    padding: 0.75rem;
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
    scrollbar-width: thin;
    scrollbar-color: var(--admin-border-strong) transparent;
}

.admin-notification-balloon-item {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 0.65rem;
    align-items: start;
    padding: 0.7rem;
    border-radius: 14px;
    border: 1px solid var(--admin-border-soft);
    background: var(--admin-surface-1);
    transition: border-color 0.15s ease, background-color 0.15s ease, transform 0.15s ease;
}

.admin-notification-balloon-item:hover {
    background: var(--admin-surface-2);
    border-color: var(--admin-border-strong);
}

.admin-notification-balloon-item.is-unread {
    border-color: var(--admin-accent-strong);
    box-shadow: inset 0 0 0 1px var(--admin-accent-soft);
}

.admin-notification-balloon-item-main {
    min-width: 0;
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    color: inherit;
    text-decoration: none;
}

body:not(.nav-hide) .admin-notification-balloon-item-main:hover {
    text-decoration: none;
}

.admin-notification-balloon-item-icon {
    width: 38px;
    height: 38px;
    flex: 0 0 38px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    color: var(--admin-text-main);
    background: var(--admin-surface-3);
}

.admin-notification-balloon-item-icon.tone-info {
    background: var(--admin-surface-3);
}

.admin-notification-balloon-item-icon.tone-success {
    background: rgba(50, 215, 75, 0.12);
    color: var(--admin-success);
}

.admin-notification-balloon-item-icon.tone-warning {
    background: rgba(255, 214, 10, 0.12);
    color: #b88600;
}

.admin-notification-balloon-item-icon.tone-danger {
    background: rgba(255, 69, 58, 0.12);
    color: var(--admin-danger);
}

body.moon .admin-notification-balloon-item-icon.tone-warning {
    color: var(--admin-warning);
}

.admin-notification-balloon-item-copy {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 0.22rem;
}

.admin-notification-balloon-item-head {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    min-width: 0;
}

.admin-notification-balloon-item-head strong {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: 0.84rem;
    line-height: 1.3;
    color: var(--admin-text-main);
}

.admin-notification-balloon-item-dot {
    width: 8px;
    height: 8px;
    flex: 0 0 8px;
    border-radius: 999px;
    background: var(--admin-accent);
    box-shadow: 0 0 0 4px var(--admin-accent-soft);
}

.admin-notification-balloon-item-body {
    display: block;
    color: var(--admin-text-soft);
    font-size: 0.76rem;
    line-height: 1.45;
}

.admin-notification-balloon-item-meta {
    display: block;
    color: var(--admin-text-muted);
    font-size: 0.7rem;
    line-height: 1.3;
}

.admin-notification-balloon-item-read {
    width: 34px;
    height: 34px;
    padding: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.admin-notification-balloon-empty {
    flex: 1;
    min-height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 0.7rem;
    padding: 1.5rem;
    text-align: center;
    border-radius: 16px;
    border: 1px dashed var(--admin-border-soft);
    background: linear-gradient(180deg, var(--admin-surface-1), var(--admin-surface-2));
}

.admin-notification-balloon-empty-icon {
    width: 72px;
    height: 72px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 22px;
    background: var(--admin-surface-3);
    color: var(--admin-accent);
    font-size: 1.45rem;
    box-shadow: inset 0 0 0 1px var(--admin-border-soft);
}

.admin-notification-balloon-empty-copy {
    max-width: 18rem;
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.admin-notification-balloon-empty-copy strong {
    color: var(--admin-text-main);
    font-size: 0.95rem;
    line-height: 1.3;
}

.admin-notification-balloon-empty-copy small {
    color: var(--admin-text-soft);
    font-size: 0.78rem;
    line-height: 1.5;
}

.admin-notification-balloon-footer {
    border-top: 1px solid var(--admin-border-soft);
}

.admin-notification-balloon-open {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    width: 100%;
    padding: 0.8rem 0.9rem;
    border-radius: 12px;
    border: 1px solid var(--admin-border-soft);
    background: var(--admin-surface-1);
    color: var(--admin-text-main);
    font-weight: 600;
    text-decoration: none;
}

.admin-notification-balloon-open:hover {
    background: var(--admin-surface-3);
    color: var(--admin-text-main);
    text-decoration: none;
}

/*
  Shared Context Switcher
*/
.admin-context-switcher-card {
    border-color: var(--admin-border-soft);
}

.admin-context-switcher-form {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.admin-context-switcher-label {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
}

.admin-context-switcher-dropdown {
    margin-left: auto;
}

.admin-context-switcher-toggle {
    min-width: min(22rem, 78vw);
    display: inline-flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    text-align: left;
    border-color: var(--admin-border-soft);
    background: var(--admin-surface-1);
    color: var(--admin-text-main);
}

.admin-context-switcher-toggle:hover,
.admin-context-switcher-toggle:focus,
.admin-context-switcher-toggle.show {
    background: var(--admin-surface-1);
    color: var(--admin-text-main);
    border-color: var(--admin-accent);
    box-shadow: 0 0 0 0.2rem rgba(13, 110, 253, 0.08);
}

.admin-context-switcher-current {
    display: block;
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-weight: 600;
}

.admin-context-switcher-menu {
    width: min(28rem, calc(100vw - 2rem));
    padding: 0.5rem;
    border-color: var(--admin-border-soft);
    background: var(--admin-surface-1);
    box-shadow: var(--admin-panel-shadow);
}

.admin-context-switcher-search-wrap {
    position: sticky;
    top: 0;
    z-index: 1;
    padding-bottom: 0.5rem;
    background: var(--admin-surface-1);
}

.admin-context-switcher-search-icon {
    position: absolute;
    top: 50%;
    left: 0.85rem;
    transform: translateY(calc(-50% + 1px));
    color: var(--admin-text-muted);
    pointer-events: none;
}

.admin-context-switcher-search {
    padding-left: 2rem;
    border-color: var(--admin-border-soft);
}

.admin-context-switcher-options {
    display: grid;
    gap: 0.35rem;
    max-height: 18rem;
    overflow-y: auto;
}

.admin-context-switcher-option {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 0.75rem;
    padding: 0.75rem;
    border: 1px solid transparent;
    border-radius: 0.65rem;
    background: transparent;
    white-space: normal;
    color: var(--admin-text-main);
}

.admin-context-switcher-option:hover,
.admin-context-switcher-option:focus {
    background: var(--admin-surface-2);
    color: var(--admin-text-main);
    border-color: var(--admin-accent-soft);
}

.admin-context-switcher-option.is-current {
    border-color: var(--admin-accent);
    background: var(--admin-surface-2);
}

.admin-context-switcher-option-main {
    min-width: 0;
    display: block;
}

.admin-context-switcher-option-primary {
    display: block;
    font-weight: 600;
}

.admin-context-switcher-option-secondary {
    display: block;
    margin-top: 0.15rem;
    color: var(--admin-text-muted);
    font-size: 0.85rem;
    word-break: break-word;
}

.admin-context-switcher-option-badges {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 0.35rem;
    flex-shrink: 0;
}

.admin-context-switcher-empty {
    padding: 1rem 0.5rem 0.5rem;
    text-align: center;
    color: var(--admin-text-muted);
    font-size: 0.9rem;
}

/* Config page dark mode */
body.moon .config-group {
    border-bottom-color: var(--admin-border-soft);
}
body.moon .config-group-header {
    background: var(--admin-surface-1);
}
body.moon .config-group-header:hover {
    background: var(--admin-surface-2);
}
body.moon .config-entry {
    border-bottom-color: var(--admin-border-soft);
}
body.moon .config-entry .config-desc {
    color: #a8b2c1;
}
body.moon .config-entry.highlight {
    background-color: #3d3a1f;
}
body.moon .config-page .form-switch .form-check-input:not(:checked) {
    background-color: var(--admin-border-soft);
    border-color: #4a5368;
}
body.moon .config-save-row.btn-outline-secondary {
    color: #a8b2c1;
    border-color: #4a5368;
}

body.moon .admin-context-switcher-card {
    background-color: var(--admin-surface-1) !important;
    border-color: var(--admin-border-soft);
}

body.moon .admin-context-switcher-toggle,
body.moon .admin-context-switcher-menu,
body.moon .admin-context-switcher-search-wrap {
    background: var(--admin-surface-1);
    border-color: var(--admin-border-soft);
    color: var(--admin-text-main);
}

body.moon .admin-context-switcher-option:hover,
body.moon .admin-context-switcher-option:focus,
body.moon .admin-context-switcher-option.is-current {
    background: var(--admin-surface-2);
    color: var(--admin-text-main);
    border-color: var(--admin-accent);
}

body.moon .admin-context-switcher-search {
    background: var(--admin-surface-2);
    border-color: var(--admin-border-soft);
    color: var(--admin-text-main);
}

body.moon .admin-context-switcher-search::placeholder {
    color: var(--admin-text-muted);
}

/* Sessions page - current session highlight in dark mode */
body.moon .table-primary {
    --bs-table-bg: var(--admin-surface-3);
    --bs-table-striped-bg: var(--admin-surface-3);
    --bs-table-hover-bg: var(--admin-accent-soft);
    background-color: var(--admin-surface-3) !important;
}
body.moon .table-primary td,
body.moon .table-primary th {
    border-color: var(--admin-border-soft) !important;
}

@media (max-width: 768px) {
    .admin-context-switcher-dropdown,
    .admin-context-switcher-toggle {
        width: 100%;
    }

    .admin-context-switcher-dropdown {
        margin-left: 0;
    }
}
/* Cache bust: 1772467421 */
/* Updated: 1772468295 */
