/* Admin-only themes. Public checkout keeps the organizer's own branding. */
:root[data-admin-theme="light"]{color-scheme:light;background:#e9ebed}
:root[data-admin-theme="dark"]{color-scheme:dark;background:#0d131c}
.admin-body .theme-toggle{display:inline-flex;position:relative;flex-shrink:0;gap:3px;min-height:36px;padding:3px;border:1px solid #e0e6ed;border-radius:22px;background:#f0f3f7;color:#8390a1;box-shadow:none}
.theme-toggle>span{display:grid;place-items:center;width:28px;height:28px;border-radius:50%;position:relative;z-index:1}
.admin-body .theme-toggle .ui-icon{width:16px;height:16px}
.theme-toggle .theme-sun{background:#fff;color:#49657f;box-shadow:0 1px 4px #26344714}
.admin-body .theme-toggle:hover{background:#e8edf3;color:#526b86;box-shadow:none}
.auth-theme-switch{position:absolute;right:24px;top:24px}
@media(max-width:820px){.topbar-tools{gap:9px}.admin-topbar{gap:9px}.theme-toggle>span{width:24px;height:24px}.admin-body .theme-toggle{min-height:32px}.auth-theme-switch{position:static;justify-self:end;margin-bottom:12px}.admin-auth{align-content:center}}

:root[data-admin-theme="dark"] .admin-body{
    --ink:#e6edf6;--muted:#a5b1c2;--line:#2a3443;--accent:#99c6f0;
    --surface:#151c27;--raised:#1c2634;--hover:#243145;
    --blue:#223c56;--mint:#203d35;--peach:#403528;
    background:#0d131c;color:var(--ink);
}
[data-admin-theme="dark"] :is(.admin-shell,.admin-topbar,.sidebar,.auth-shell,.admin-main .card,.admin-main .table-wrap,.admin-main table,.organization-card,.admission-card,.scanner-dialog,.skip-link){background:var(--surface);color:var(--ink);border-color:var(--line)}
[data-admin-theme="dark"] .admin-shell{box-shadow:0 16px 70px #0003}
[data-admin-theme="dark"] .sidebar{scrollbar-color:#3b4b60 transparent}
[data-admin-theme="dark"] :is(.sidebar-help,.profile-panel,.context-icon,.period-pill,.role-pill,.detail-tabs,.filters,.participant-filters,.participant-search .actions,.logo-preview,.scan-result){background:var(--raised);color:var(--muted);border-color:var(--line)}
[data-admin-theme="dark"] :is(.help-icon,.profile-panel .role-pill,.dashboard-metrics>a,.metric-grid>a){background:var(--raised);color:var(--ink);border-color:var(--line)}
[data-admin-theme="dark"] :is(.admin-brand,.brand-mark,.organization-context strong,.metric-grid strong,.profile-panel h2,.next-event-panel h2,.activity-item strong,.quick-panel strong,.org-stats strong,.admin-main td.entity-name,.admin-main td.entity-name a,.admin-main td.amount,.money-total,.table-amount){color:var(--ink)}
[data-admin-theme="dark"] :is(.admin-brand small,.sidebar-help>p,.sidebar-profile small,.sidebar-profile>.ui-icon,.admin-body .logout-button,.side-nav a,.nav-details>summary,.organization-switcher label,.today-label,.admin-footer,.breadcrumbs a,.breadcrumbs span,.breadcrumbs [aria-current],.admin-main .eyebrow,.section-top>.ui-icon,.metric-grid span,.metric-grid small,.chart-summary>span,.chart-summary small,.chart-axis,.chart-date,.chart-value,.chart-caption,.date-tile span,.schedule-info small,.schedule-count,.schedule-arrow,.profile-panel p,.quick-panel small,.activity-item p,.activity-item time,.simple-row small,.overview-event p,.admin-main td,.admin-main th,.pagination,.org-stats,.empty-state p,.inline-empty,.detail-tabs a,.order-id,.account-facts dt,.participant-filters summary,.auth-story p,.auth-story>small,.auth-main .eyebrow,.auth-main p,.admin-body label){color:var(--muted)}
[data-admin-theme="dark"] :is(.admin-body a:not(.button):hover,.admin-main td a,.text-link,.card-link,.chart-data summary,.pwa-help summary,.auth-main p a,.schedule-row:hover .schedule-info){color:#a1d0f7!important}
[data-admin-theme="dark"] :is(.side-nav a:hover,.sidebar-profile:hover,.sidebar-profile.selected,.metric-grid>a:hover,.admin-main tbody tr:hover){background:var(--hover);color:var(--ink)}
[data-admin-theme="dark"] .side-nav a.selected{background:#233a53;color:#b1d7f8}
[data-admin-theme="dark"] .side-nav a.selected:after{background:#97c4ed}
[data-admin-theme="dark"] .admin-body .organization-switcher select{background:transparent;color:var(--ink)}
[data-admin-theme="dark"] .organization-switcher option{background:var(--surface);color:var(--ink)}
[data-admin-theme="dark"] :is(.avatar,.profile-avatar){background:#2c3d54;color:#c3ddf5;border-color:var(--raised)}
[data-admin-theme="dark"] .topbar-tools .avatar{border-color:#384b64}
[data-admin-theme="dark"] .profile-avatar i{border-color:var(--raised);background:#8ac8ae}
[data-admin-theme="dark"] .tone-blue{background:var(--blue)!important;color:#accff2!important}
[data-admin-theme="dark"] .tone-mint{background:var(--mint)!important;color:#a2d3bf!important}
[data-admin-theme="dark"] .tone-peach{background:var(--peach)!important;color:#e1bd91!important}
[data-admin-theme="dark"] :is(.date-tile,.org-monogram,.count,.empty-icon){background:var(--blue);color:#b6d6f3}
[data-admin-theme="dark"] .schedule-row:nth-of-type(2n) .date-tile{background:var(--peach);color:#e1c7a6}
[data-admin-theme="dark"] :is(.schedule-row:nth-of-type(3n) .date-tile,.organization-card:nth-child(3n+2) .org-monogram){background:var(--mint);color:#b0d9c8}
[data-admin-theme="dark"] .chart-bars{background:repeating-linear-gradient(to top,var(--line) 0,var(--line) 1px,transparent 1px,transparent 50%);border-color:var(--line)}
[data-admin-theme="dark"] .chart-bar{background:#6f9cc9}
[data-admin-theme="dark"] .chart-column:nth-child(3n) .chart-bar{background:#75b4a0}
[data-admin-theme="dark"] .chart-column:hover .chart-bar{background:#b0d8fc}
[data-admin-theme="dark"] .chart-bar.is-zero{background:#34465b}
[data-admin-theme="dark"] .chart-data .table-wrap{box-shadow:0 10px 30px #0006}
[data-admin-theme="dark"] .next-event-panel{background:#1c3046;border-color:#2f4861}
[data-admin-theme="dark"] :is(.next-event-panel .eyebrow,.next-event-panel .section-top .ui-icon,.next-event-panel p){color:#a6c1dc}
[data-admin-theme="dark"] .next-date{color:#c0ddf6}
[data-admin-theme="dark"] .activity-dot{background:#233f58;border-color:#7299be}
[data-admin-theme="dark"] .refund-attempt[data-result=succeeded] .refund-result{color:#a1d9bf}
[data-admin-theme="dark"] .refund-attempt[data-result=canceled] .refund-result{color:#efb4ad}
[data-admin-theme="dark"] :is(.quick-panel>a>.ui-icon,.simple-row .ui-icon,.activity-panel .section-top .ui-icon){color:#a6bed7}
[data-admin-theme="dark"] .admin-main th{background:var(--raised)}
[data-admin-theme="dark"] .badge{background:#283547;color:#c0cbda}
[data-admin-theme="dark"] :is(.badge[data-status=Paid],.badge[data-status=Published],.badge[data-status=Active],.badge[data-status="Действителен"],.badge[data-status="Опубликовано"],.badge[data-status="Успешно"],.badge[data-status="Активна"],.badge[data-status="Активен"]){background:#203d35;color:#a1d9bf}
[data-admin-theme="dark"] :is(.badge[data-status=PendingPayment],.badge[data-status=RefundPending],.badge[data-status="Ожидает оплаты"]){background:#433822;color:#ebcf94}
[data-admin-theme="dark"] :is(.badge[data-status=Cancelled],.badge[data-status=Refunded],.badge[data-status="Аннулирован"],.badge[data-status="Возвращён"],.badge[data-status="Отменён"],.badge[data-status="Ошибка оплаты"]){background:#452c31;color:#efb4ad}
[data-admin-theme="dark"] :is(.badge[data-status=Expired],.badge[data-status=Draft]){background:#2a3443;color:#bac5d3}
[data-admin-theme="dark"] .organization-card:hover{border-color:#506e8c;box-shadow:0 8px 25px #0002}
[data-admin-theme="dark"] :is(.empty-state,.empty-state.compact){background:var(--raised);border-color:#38495f;color:var(--muted)}
[data-admin-theme="dark"] :is(.empty-state h2,.empty-state h3){color:var(--ink)}
[data-admin-theme="dark"] .detail-tabs .selected{background:#30445d;color:#d4e6f8;box-shadow:none}
[data-admin-theme="dark"] .admin-body :is(input,select,textarea){background:#111a26;border-color:#3b485c;color:var(--ink)}
[data-admin-theme="dark"] .admin-body :is(input,select,textarea):focus{background:#192435;border-color:#7cadd7;outline-color:#6a98c3}
[data-admin-theme="dark"] .admin-body :is(input,textarea)::placeholder{color:#96a5b8}
[data-admin-theme="dark"] .admin-body input[type=checkbox]{accent-color:#9bc5ee}
[data-admin-theme="dark"] .admin-body input[type=file]::file-selector-button{background:#293e56;color:#c4ddf6}
[data-admin-theme="dark"] .color-swatch{border-color:#536378;box-shadow:inset 0 0 0 3px var(--raised)}
[data-admin-theme="dark"] .color-swatch.invalid{background:repeating-linear-gradient(45deg,#253247,#253247 5px,#3a485b 5px,#3a485b 10px)}
[data-admin-theme="dark"] .admin-body :is(button,.button){background:#a4c9ee;color:#152538;border-color:transparent}
[data-admin-theme="dark"] .admin-body :is(button,.button):hover{background:#c2def7;color:#152538;box-shadow:0 3px 10px #0002}
[data-admin-theme="dark"] .admin-body :is(.secondary,.next-event-panel .button){background:#273e57;color:#bedaf5;border-color:#38536e}
[data-admin-theme="dark"] .admin-body :is(.secondary,.next-event-panel .button):hover{background:#345270;color:#e6f2fc}
[data-admin-theme="dark"] .admin-body .quiet{background:transparent;color:#b7c7d9;border-color:transparent;box-shadow:none}
[data-admin-theme="dark"] .admin-body .quiet:hover{background:var(--hover);color:var(--ink)}
[data-admin-theme="dark"] .admin-body .danger{background:#452b31;color:#efb4ad;border-color:#6c414a}
[data-admin-theme="dark"] .admin-body .danger:hover{background:#623841;color:#ffd5cf}
[data-admin-theme="dark"] .admin-body :is(a,button,input,select,textarea,summary):focus-visible{outline-color:#8fc2ed}
[data-admin-theme="dark"] .admin-body :is(.notice,.checked-in,.scan-success){background:#1c342c;border-color:#365e4f;color:#b1dec7}
[data-admin-theme="dark"] .admin-body :is(.error,.invalid-ticket,.scan-error){background:#3c252b;border-color:#70444c;color:#f0b9b2}
[data-admin-theme="dark"] .invalid-ticket strong{color:#f0b9b2}
[data-admin-theme="dark"] .scan-warning{background:#3f3521;border-color:#715f39;color:#f1d594}
[data-admin-theme="dark"] .scanner-dialog::backdrop{background:#070d16cc}
[data-admin-theme="dark"] .scanner-camera{background:#0b111a}
[data-admin-theme="dark"] .participant-filters .filters{background:transparent}
[data-admin-theme="dark"] .admin-body .menu-toggle{background:var(--raised);color:#c6d6e7}
[data-admin-theme="dark"] .admin-body .sidebar-backdrop{background:#080d17a6}
[data-admin-theme="dark"] .auth-story{background:#1c3046}
[data-admin-theme="dark"] .auth-shell{box-shadow:0 20px 80px #0004}
[data-admin-theme="dark"] .auth-main .card{background:transparent}
[data-admin-theme="dark"] .admin-body .theme-toggle{background:#101824;border-color:#37465b;color:#9eafc4;box-shadow:none}
[data-admin-theme="dark"] .admin-body .theme-toggle:hover{background:#1d2b3d;color:#c6d9eb}
[data-admin-theme="dark"] .theme-toggle .theme-sun{background:transparent;color:inherit;box-shadow:none}
[data-admin-theme="dark"] .theme-toggle .theme-moon{background:#334d6c;color:#d8eaff;box-shadow:0 1px 4px #0003}
