/* Shared light palette for account, pricing, administration and canvas. */
:root,.light,.dark{color-scheme:light!important;--background:#fff!important;--foreground:#172033!important;--card:#fff!important;--card-foreground:#172033!important;--popover:#fff!important;--popover-foreground:#172033!important;--primary:#2563eb!important;--primary-foreground:#fff!important;--secondary:#f8fafc!important;--secondary-foreground:#334155!important;--muted:#f8fafc!important;--muted-foreground:#64748b!important;--accent:#eff6ff!important;--accent-foreground:#1d4ed8!important;--border:#e5e7eb!important;--input:#dbe1ea!important;--ring:#2563eb!important;--radius:.5rem!important;--sidebar:#fff!important;--sidebar-foreground:#334155!important;--sidebar-primary:#2563eb!important;--sidebar-primary-foreground:#fff!important;--sidebar-accent:#eff6ff!important;--sidebar-accent-foreground:#1d4ed8!important;--sidebar-border:#e5e7eb!important;--sidebar-ring:#2563eb!important;--chart-1:#2563eb!important;--skeleton-base:#f1f5f9!important;--skeleton-highlight:#f8fafc!important}
html,body{background:#fff!important;color:#000;font-family:-apple-system,BlinkMacSystemFont,"PingFang SC","Microsoft YaHei",sans-serif!important}button[data-slot=button]:not([data-size=icon]):not([data-size^=icon]){border-radius:0!important}input,textarea,select{font-family:inherit}h1,h2,h3{letter-spacing:-.025em}a,button{touch-action:manipulation}[data-slot=card]{box-shadow:none!important;border:1px solid #000;border-radius:0!important}[data-slot=sidebar-inner],[data-slot=sidebar-inset]{background:#fff!important}[data-slot=table-head]{color:#000;font-weight:600}[data-slot=table-row]{border-color:#000}[data-slot=badge]{border-radius:0!important}button:focus-visible,a:focus-visible{outline:2px solid #2563eb;outline-offset:3px}::selection{background:#fff;color:#000}
@media(prefers-reduced-motion:reduce){*,*::before,*::after{animation:none!important;transition:none!important}}

#root:not(:empty)~#unlil-loading{display:none}

/* UNLIL: monochrome, sharp edges. Media content retains its original pixels. */
:root,.light,.dark{color-scheme:light!important;--bg:#fff!important;--panel:#fff!important;--raised:#fff!important;--surface:#fff!important;--text:#000!important;--muted:#000!important;--dim:#000!important;--line:#000!important;--brand:#000!important;--soft:#fff!important;--hover:#fff!important;--shadow:none!important;--lime:#000!important;--ink:#fff!important;--hl:#fff!important;--background:#fff!important;--foreground:#000!important;--card:#fff!important;--card-foreground:#000!important;--popover:#fff!important;--popover-foreground:#000!important;--primary:#000!important;--primary-foreground:#fff!important;--secondary:#fff!important;--secondary-foreground:#000!important;--muted-foreground:#000!important;--accent:#fff!important;--accent-foreground:#000!important;--border:#000!important;--input:#000!important;--ring:#000!important;--sidebar:#fff!important;--sidebar-foreground:#000!important;--sidebar-primary:#000!important;--sidebar-primary-foreground:#fff!important;--sidebar-accent:#fff!important;--sidebar-accent-foreground:#000!important;--sidebar-border:#000!important;--sidebar-ring:#000!important;--destructive:#000!important;--destructive-foreground:#fff!important;--chart-1:#000!important;--chart-2:#000!important;--chart-3:#000!important;--chart-4:#000!important;--chart-5:#000!important;--radius:0px!important;--ok:#000!important;--bad:#000!important;--gray:#fff!important;--skeleton-base:#fff!important;--skeleton-highlight:#fff!important}
*,*::before,*::after{border-radius:0!important;box-shadow:none!important;text-shadow:none!important;backdrop-filter:none!important;accent-color:#000!important;caret-color:#000}
html,body{background:#fff!important;color:#000!important}body :where(main,section,aside,header,footer,nav,dialog,input,textarea,select){border-color:#000!important}input,textarea,select{color:inherit}a:focus-visible,button:focus-visible,input:focus-visible,textarea:focus-visible,select:focus-visible{outline:2px solid #000!important;outline-offset:3px}::selection{background:#000!important;color:#fff!important}
/* Explicit local workspace controls. */
.side,.shell,.topbar,.composer,.agent-workspace,.agent-sidebar,.mobile-nav,.agent-message,.agent-message.user,.stat,.dashboard-panel,.work-card,.empty-state,.notice,.select-wrap,.search,#prompt,#agentForm,#agentInput,#wfJson,.wf-node,.node-inspector,.json-panel{background:#fff!important;color:#000!important;border-color:#000!important}
.side-nav>button,.side-nav>a,.side-links a,.side-bottom .logout,.topbar a,.composer-meta,.subtle,.fine-print,.agent-capability,.message-text,.message-author,.message-actions button,.skill-card small,.skill-card strong,footer,#agentHistory button,.mobile-nav button{color:#000!important}
.side-nav>button.active,.side-nav>button:hover,.side-nav>a:hover,.mobile-nav button.active,.agent-skills button.selected,#agentHistory button.selected{background:#000!important;color:#fff!important}
.send,.button.primary,#agentSend,.btn.primary{background:#000!important;color:#fff!important;border:1px solid #000!important}.send:hover,.button.primary:hover,.btn.primary:hover{background:#fff!important;color:#000!important}.button.secondary,.button.small,.btn:not(.primary),.select-wrap,.select-wrap select{background:#fff!important;color:#000!important;border-color:#000!important}
.mode-tabs button,.mode-tabs button[aria-selected=true]{background:#fff!important;color:#000!important}.mode-tabs button[aria-selected=true]{border-bottom:2px solid #000!important}
#agentWelcome h1 span{color:#000!important;-webkit-text-fill-color:#000!important}.connection i,.connection.connected i,.dot{background:#000!important}.icon{background:#fff!important;color:#000!important;border:1px solid #000}.card,.guide{border-color:#000!important}.card:hover{transform:none!important}.btn:hover{transform:none!important}#toast{background:#000!important;color:#fff!important}#wfLines path{stroke:#000!important}dialog::backdrop{background:rgba(0,0,0,.45)}
/* Semantic distinction remains textual; failures also use a dashed outline. */
.bars i{border:1px solid #000;background:#fff!important}.bars i.ok{background:#000!important}.bars i.bad{background:#fff!important;border:1px dashed #000}.row .state{color:#000!important}
/* Upstream utility colors are neutralized without filtering generated pictures. */
[class*="text-red"],[class*="text-blue"],[class*="text-green"],[class*="text-yellow"],[class*="text-orange"],[class*="text-purple"],[class*="text-emerald"],[class*="text-indigo"],[class*="text-rose"],[class*="text-amber"],[class*="text-cyan"],[class*="text-violet"],[class*="text-muted"]{color:#000!important}
[class*="bg-red"],[class*="bg-blue"],[class*="bg-green"],[class*="bg-yellow"],[class*="bg-orange"],[class*="bg-purple"],[class*="bg-emerald"],[class*="bg-indigo"],[class*="bg-rose"],[class*="bg-amber"],[class*="bg-cyan"],[class*="bg-violet"],[class*="bg-gradient"]{background:#fff!important;color:#000!important;background-image:none!important}
[data-slot=badge]{border:1px solid #000!important;background:#fff!important;color:#000!important}[data-slot=button]{border-color:#000!important}[data-slot=card],[data-slot=table-row],[data-slot=sidebar-inner]{border-color:#000!important}
button:disabled{opacity:1!important;background:#fff!important;color:#000!important;border-style:dashed!important;cursor:not-allowed}

/* Dark fills (primary / foreground / destructive in this monochrome palette) always carry white text, including hover, checked and selected states. */
:is(.bg-primary,.bg-foreground,.bg-destructive,.bg-destructive\/80,.hover\:bg-primary\/90:hover,.data-checked\:bg-primary[data-state=checked],.data-checked\:bg-primary[data-checked]:not([data-checked=false]),.data-\[selected-single\=true\]\:bg-primary[data-selected-single=true],.data-\[range-start\=true\]\:bg-primary[data-range-start=true],.data-\[range-end\=true\]\:bg-primary[data-range-end=true],.group-\[\.is-user\]\:bg-primary:is(.is-user *)),:is(.bg-primary,.bg-foreground,.bg-destructive,.bg-destructive\/80,.hover\:bg-primary\/90:hover,.group-\[\.is-user\]\:bg-primary:is(.is-user *)) *{color:#fff!important;-webkit-text-fill-color:#fff}

/* new-api console only: shadcn uses --muted / --accent as light fills (hover, tabs, boxes); the monochrome palette set them to black/white, which made hovered controls black and hover states invisible. */
html.unlil-console{--muted:#f2f2f2!important;--accent:#ededed!important;--accent-foreground:#000!important;--secondary:#f5f5f5!important;--sidebar-accent:#ededed!important}

/* unlil-preset-wrap: top-up preset cards — "$500 额度" plus the discount badge must wrap instead of overflowing. */
html.unlil-console button[data-slot=button].flex-col{min-width:0;height:auto!important;justify-content:flex-start!important;gap:4px}
html.unlil-console button[data-slot=button].flex-col>div{min-width:0;max-width:100%;overflow-wrap:anywhere}
html.unlil-console button[data-slot=button].flex-col>div.flex.w-full{flex-wrap:wrap;column-gap:6px;row-gap:2px}
html.unlil-console button[data-slot=button].flex-col>div.flex.w-full>div{white-space:nowrap}

/* Audit fix: disabled primary buttons must retain visible labels. */
html.unlil-console button:disabled,html.unlil-console button:disabled * {color:#000!important;-webkit-text-fill-color:#000!important;}
html.unlil-console button:disabled {background:#fff!important;border-style:dashed!important;}
