.theme-editor{margin:0 0 18px;padding:12px 16px;border:1px solid #ced8ef;border-radius:14px;background:#fff;color:#17213a;font:14px/1.5 Arial,sans-serif}
.theme-editor summary{cursor:pointer;font-weight:700;min-height:28px}
.theme-editor p{font-size:13px;margin:10px 0;color:inherit}
.theme-controls,.theme-presets{display:flex;flex-wrap:wrap;align-items:center;gap:10px;margin:12px 0}
.theme-controls label{display:flex;align-items:center;gap:10px}
.theme-controls input[type=color]{width:64px;height:40px;padding:3px;border:1px solid #777;border-radius:8px}
.theme-presets button{min-height:40px;border:1px solid #777;border-radius:9px;padding:8px 16px;font:600 14px Arial;cursor:pointer}
@media screen {
  html[data-custom-theme] {--ink:var(--theme-ink);--muted:var(--theme-link);--line:var(--theme-tint);--paper:var(--theme-soft);--green:var(--theme-link);--green-deep:var(--theme-ink);--brand-gradient:linear-gradient(var(--theme-accent),var(--theme-accent));--brand-blue:var(--theme-accent);--brand-navy:var(--theme-ink)}
  html[data-custom-theme] body {background:var(--theme-soft)!important;color:var(--theme-ink)}
  html[data-custom-theme] body :is(.sidebar,.dealer-sidebar,.partner-sidebar,.delivery-sidebar,.dealer-sidenav,.registration-intro,.site-footer,.landing-promo) {background:var(--theme-accent)!important;color:var(--theme-on)!important;border-color:var(--theme-link)}
  html[data-custom-theme] body :is(.sidebar,.dealer-sidebar,.partner-sidebar,.delivery-sidebar,.dealer-sidenav,.registration-intro,.site-footer,.landing-promo) :is(a,button,span,strong,small,p,h1,h2,h3,.sidebar-label) {color:var(--theme-on)!important}
  html[data-custom-theme] body :is(.sidebar .nav-item.is-active,.dealer-sidenav button.is-active) {background:var(--theme-on)!important;color:var(--theme-accent)!important;box-shadow:none}
  html[data-custom-theme] body :is(.sidebar .nav-item.is-active,.dealer-sidenav button.is-active) :is(span,svg) {color:var(--theme-accent)!important}
  html[data-custom-theme] body .sidebar .nav-icon {background:transparent!important}
  html[data-custom-theme] body :is(.admin-button,.btn-primary,.primary-button,.auth-submit,.checkout-button,.button.primary,.product-bottom .button) {background:var(--theme-accent)!important;color:var(--theme-on)!important;border-color:var(--theme-link)!important;box-shadow:none}
  html[data-custom-theme] body :is(.admin-button,.btn-primary,.primary-button,.auth-submit,.checkout-button,.button.primary) :is(span,svg) {color:inherit!important}
  html[data-custom-theme] body table thead {background:var(--theme-accent)!important}
  html[data-custom-theme] body table thead th {color:var(--theme-on)!important;background:transparent!important}
  html[data-custom-theme] body :is(.panel,.ov-card,.metric-card,.ov-kpi,.ov-partner,.login-card,.auth-card,.delivery-card,.product-card,.signup-page fieldset,.catalog-filters,.orders-filters,.dealer-filters,.commission-filters,.net-filters) {background:var(--theme-soft)!important;border-color:var(--theme-tint)!important;color:var(--theme-ink)}
  html[data-custom-theme] body :is(.panel,.metric-card,.ov-card,.ov-kpi,.ov-partner,.login-card,.auth-card) :is(h1,h2,h3,label) {color:var(--theme-ink)}
  html[data-custom-theme] body :is(.quiet-button,.refresh-button,.catalog-footer button,.catalog-filters button:not(.admin-button)) {background:#fff!important;color:var(--theme-link)!important;border-color:var(--theme-link)!important}
  html[data-custom-theme] body table tbody tr:nth-child(even) {background:var(--theme-soft)!important}
  html[data-custom-theme] body table tbody tr:hover {background:var(--theme-tint)!important}
  html[data-custom-theme] body :is(input[type=checkbox],input[type=radio]) {accent-color:var(--theme-accent)}
  html[data-custom-theme] body :is(button,a,input,select,textarea):focus-visible {outline:3px solid var(--theme-link);outline-offset:3px}
  html[data-custom-theme] body .theme-editor {border-color:var(--theme-link)}
}
