/* 5.8.1 UI compatibility fixes, loaded after the foundation. */
:root,html[data-theme="dark"],html[data-contrast="high"],html[data-theme="dark"][data-contrast="high"] {
 --bg:var(--background);--surface-2:var(--surface-secondary);--ink:var(--text-primary);--muted:var(--text-secondary);--line:var(--border);--teal:var(--brand-600);
}
/* Legacy .icon-button has display:inline-flex!important. Match priority with exact controls. */
@media(min-width:1024px) {.topbar #mobileMenu {display:none!important}.topbar #sidebarToggle {display:inline-flex!important}}
@media(max-width:1023px) {.topbar #sidebarToggle {display:none!important}.topbar #mobileMenu {display:inline-flex!important}}
#dashboardView .compact-empty {min-height:164px;padding:22px 16px}
#dashboardView .compact-empty>span {font-size:0;width:56px;height:56px}
#dashboardView .compact-empty>span::before {content:"";display:block;width:28px;height:28px;background:currentColor;
 -webkit-mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.5'%3E%3Crect x='4' y='3' width='16' height='18' rx='3'/%3E%3Cpath d='M8 8h8M8 12h8M8 16h5'/%3E%3C/svg%3E") center/contain no-repeat;
 mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.5'%3E%3Crect x='4' y='3' width='16' height='18' rx='3'/%3E%3Cpath d='M8 8h8M8 12h8M8 16h5'/%3E%3C/svg%3E") center/contain no-repeat;
}
