:root {
  color-scheme: light;
  --ink: #202638;
  --muted: #607088;
  --faint: #52627a;
  --surface: #fff;
  --canvas: #f5f7fb;
  --line: #dfe5ef;
  --accent: #4938a8;
  --accent-deep: #3e2c96;
  --accent-light: #efeaff;
  --green: #126950;
  --orange: #98600d;
  --red: #a53148;
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", "Noto Sans CJK SC", sans-serif;
  font-size: 16px;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; background: var(--canvas); color: var(--ink); }
button, input, select, textarea { font: inherit; }
button, summary, select { cursor: pointer; }
button { color: inherit; }
button:focus-visible, a:focus-visible, summary:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible { outline: 2px solid #7355dc; outline-offset: 2px; }
button:disabled { cursor: not-allowed; }
a { color: var(--accent-deep); }
svg { width: 1.15em; height: 1.15em; flex: none; vertical-align: middle; }
.shell { min-height: 100vh; }
body:has(.icp-footer) { display: flex; flex-direction: column; min-height: 100vh; }
body:has(.icp-footer) > :is(.auth, .shell) { flex: 1; min-height: 0; }
.icp-footer { padding: 14px 16px; text-align: center; font-size: .8rem; }
#auth[hidden] ~ .icp-footer { display: none; }
.icp-footer a { color: var(--muted); }
.brand-mark { width: 37px; height: 37px; flex: none; display: grid; place-content: center; gap: 2px; border-radius: 10px; background: #a594fd; color: #231654; }
.brand-mark span { width: 17px; height: 4px; border: 1.5px solid currentColor; border-radius: 3px; transform: skewX(-22deg); }
.brand-mark span:nth-child(2) { width: 13px; justify-self: center; }
.brand-mark span:nth-child(3) { width: 9px; justify-self: center; }
.workspace { min-width: 0; }
.topbar { position: sticky; top: 0; z-index: 5; min-height: 62px; background: var(--surface); border-bottom: 1px solid var(--line); padding: 10px clamp(16px, 2.4vw, 36px); display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.topbar-main, .topbar-brand, .identity { display: flex; align-items: center; min-width: 0; }
.topbar-main { gap: 16px; }
.topbar-brand { flex: none; gap: 9px; white-space: nowrap; }
.topbar-brand strong { font-size: .94rem; }
.topbar-brand .brand-mark { width: 34px; height: 34px; }
.store-navigation { min-width: 0; padding-inline-start: 16px; border-inline-start: 1px solid var(--line); }
.store-name { display: block; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
#current-store { font-size: .9rem; font-weight: 650; }
.identity { flex: none; gap: 8px; }
.identity-name { max-width: min(16vw, 155px); font-size: .88rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.connection { display: flex; align-items: center; gap: 6px; padding: 4px 8px; border-radius: 7px; background: #f1f3f8; color: var(--faint); font-size: .75rem; white-space: nowrap; }
.connection-dot { width: 7px; height: 7px; flex: none; border-radius: 50%; background: #8795ad; }
.connection[data-online="true"] { background: #eff7f3; color: #22654f; }
.connection[data-online="true"] .connection-dot { background: #278363; }
.connection[data-online="false"] { background: #fff4e3; color: #80500e; }
.connection[data-online="false"] .connection-dot { background: #a5651b; }
.topbar-menu { position: relative; }
.topbar-menu > summary { list-style: none; }
.topbar-menu > summary::-webkit-details-marker { display: none; }
.topbar-menu[open] > summary { background: var(--accent-light); border-color: #d7cef2; color: var(--accent-deep); }
.store-menu > summary { display: flex; justify-content: space-between; width: max-content; max-width: 100%; min-height: 36px; padding: 5px 8px; }
#store-menu-chevron { flex: none; color: var(--faint); }
.account-menu { flex: none; margin-inline-start: 4px; }
.account-menu > summary { display: grid; place-items: center; width: 36px; height: 36px; min-height: 0; padding: 0; color: var(--faint); list-style: none; }
.account-menu > summary svg { width: 19px; height: 19px; }
.topbar-menu-panel { position: absolute; top: calc(100% + 7px); z-index: 1; padding: 5px; border: 1px solid var(--line); border-radius: 9px; background: var(--surface); box-shadow: 0 8px 25px #252b4026; }
.account-menu-panel { inset-inline-end: 0; min-width: 172px; }
.store-menu-panel { inset-inline-start: 0; width: max-content; min-width: min(216px, calc(100vw - 66px)); max-width: min(320px, calc(100vw - 66px)); max-height: min(55vh, 375px); overflow-y: auto; }
.topbar-menu-panel button { display: flex; align-items: center; gap: 8px; width: 100%; min-height: 36px; padding: 6px 9px; border: 0; border-radius: 6px; background: transparent; white-space: nowrap; font-size: .86rem; text-align: start; }
.topbar-menu-panel button:hover, .topbar-menu-panel button[aria-current="page"] { background: #f5f4ff; color: var(--accent-deep); }
.topbar-menu-panel button + button { margin-top: 2px; }
.topbar-menu-panel button[hidden] + button { margin-top: 0; }
.account-version-row { margin-top: 4px; padding-top: 4px; border-top: 1px solid var(--line); }
.topbar-menu-panel .account-version { justify-content: space-between; gap: 12px; color: var(--muted); font-size: .76rem; font-variant-numeric: tabular-nums; }
.account-version-link { color: var(--accent-deep); font-weight: 650; }
.store-count { flex: none; margin-inline-start: auto; padding-inline-start: 8px; color: var(--muted); font-size: .76rem; font-variant-numeric: tabular-nums; }
.auth { min-height: 100vh; display: grid; place-items: center; padding: 24px; }
.auth-card { width: min(100%, 380px); padding: 27px; border: 1px solid var(--line); border-radius: 15px; background: #fff; box-shadow: 0 12px 36px #252b4011; }
.auth-brand { display: flex; align-items: center; gap: 10px; color: var(--accent-deep); font-weight: 730; }
.auth-card h1 { margin: 21px 0 16px; font-size: 1.6rem; }
.auth-card .field + .field { margin-top: 12px; }
.auth-card > .btn { width: 100%; margin-top: 17px; }
.editing-notice { margin: 0 0 12px; padding: 8px 10px; border-radius: 7px; background: #fff1d9; color: #80500e; font-size: .85rem; }
.avatar { display: inline-grid; place-items: center; width: 28px; height: 28px; background: #ece7ff; color: #443281; border-radius: 9px; font-size: .77rem; font-weight: 720; flex: none; }
select { border-radius: 7px; border: 1px solid var(--line); appearance: none; padding: 8px 30px 8px 10px; color: var(--ink); background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='m1 1 5 5 5-5' fill='none' stroke='%2358637a' stroke-width='1.6' stroke-linecap='round'/%3E%3C/svg%3E") right 10px center / 11px no-repeat; }
.page { padding: 26px clamp(16px, 2.4vw, 36px) 32px; max-width: 1900px; margin: 0 auto; }
.page-heading { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 14px; margin-bottom: 21px; }
.page-heading h1 { font-size: clamp(1.62rem, 2.5vw, 2.1rem); margin: 0; line-height: 1.2; letter-spacing: -.04em; }
.page-heading p { margin: 8px 0 0; font-size: .875rem; color: var(--muted); }
.page.no-store .page-heading {
  display: grid;
  place-items: center;
  min-height: clamp(240px, 56vh, 520px);
  margin: 0;
  padding: 24px 12px;
  text-align: center;
}
.page.no-store h1 { font-size: clamp(2rem, 5vw, 3.25rem); }
.page.no-store .page-heading p { margin-top: 12px; font-size: 1rem; line-height: 1.55; }
.btn { display: inline-flex; justify-content: center; align-items: center; gap: 6px; padding: 9px 13px; min-height: 38px; border: 1px solid var(--line); background: white; border-radius: 8px; font-size: .88rem; font-weight: 650; text-decoration: none; color: var(--ink); white-space: nowrap; }
.btn:hover { background: #f5f4ff; border-color: #d7cef2; }
.btn.primary { background: var(--accent); border-color: var(--accent); color: white; }
.btn.primary:hover { background: var(--accent-deep); border-color: var(--accent-deep); }
.btn.soft { background: var(--accent-light); color: var(--accent-deep); border-color: transparent; }
.btn.soft:hover { background: #e5dcfc; }
.btn.danger { border-color: #efc8d0; color: var(--red); }
.btn.danger:hover { background: #fff1f3; }
.btn[aria-disabled="true"], .btn:disabled { background: #f2f4f8; border-color: #e3e7ee; color: #637086; }
.icon-btn { display: inline-grid; place-items: center; width: 35px; height: 35px; border-radius: 8px; border: 1px solid var(--line); background: #fff; color: var(--muted); }
.icon-btn:hover { color: var(--accent); background: #f5f2ff; }
.summary { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin-bottom: 22px; }
.stat { width: 100%; display: grid; grid-template-columns: 39px minmax(0, 1fr); align-items: center; gap: 12px; min-height: 77px; text-align: left; padding: 10px 13px; background: #fff; border: 1px solid var(--line); border-radius: 10px; }
.stat:hover, .stat[aria-pressed="true"] { border-color: #a999e3; }
.stat-icon { display: grid; place-items: center; width: 39px; height: 39px; border-radius: 9px; color: #513eb3; background: #efeaff; }
.stat-icon.amber { color: #925409; background: #fff2db; }
.stat-icon.blue { color: #2d5391; background: #e9f0ff; }
.stat-icon.rose { color: #a33a51; background: #fce9ee; }
.stat-label, .stat-number { display: block; }
.stat-label { font-size: .84rem; color: var(--muted); line-height: 1.36; }
.stat-number { font-size: 1.52rem; font-weight: 720; font-variant-numeric: tabular-nums; line-height: 1.15; }
.board-toolbar { display: flex; justify-content: space-between; align-items: center; gap: 12px; border-bottom: 1px solid var(--line); margin-bottom: 14px; }
.board-tabs { display: flex; gap: 14px; min-width: 0; }
.tab { display: flex; align-items: center; gap: 6px; border: 0; background: transparent; border-bottom: 2px solid transparent; padding: 10px 3px 12px; margin-bottom: -1px; color: var(--muted); font-size: .9rem; font-weight: 660; white-space: nowrap; }
.tab:hover, .tab[aria-pressed="true"] { color: var(--accent-deep); }
.tab[aria-pressed="true"] { border-bottom-color: #694cce; }
.tab .count { background: #e9eaf3; color: #475571; }
.search { display: flex; align-items: center; gap: 7px; min-width: 0; margin-bottom: 7px; padding: 0 8px; border: 1px solid var(--line); border-radius: 8px; background: #fff; color: var(--muted); }
.search:focus-within { outline: 2px solid #ab9ae9; outline-offset: 1px; }
.search input { width: 185px; min-width: 75px; height: 33px; outline: 0; border: 0; background: transparent; font-size: .85rem; color: var(--ink); }
.search input:focus-visible { outline: none; }
.lanes { display: grid; grid-template-columns: repeat(4, minmax(220px, 1fr)); align-items: start; gap: 12px; overflow-x: auto; padding: 1px 1px 15px; scrollbar-color: #c4cddd transparent; }
.lanes.has-collapsed-complete { --collapsed-complete-width: 100px; grid-template-columns: repeat(3, minmax(220px, 1fr)) var(--collapsed-complete-width); }
.lanes.secondary { grid-template-columns: minmax(220px, 1fr); }
.lane { min-height: 220px; border: 1px solid #e0e6f0; border-radius: 11px; background: #eef1f7; padding: 9px; }
.lane.collapsed { min-height: 0; padding-inline: 7px; }
.lane-header { display: flex; align-items: center; gap: 7px; margin: 0 0 8px; padding: 3px 3px 8px; border-bottom: 1px solid #e0e5ee; }
.lane-header h2 { flex: 1; font-size: .97rem; margin: 0; white-space: nowrap; }
.lane-header.lane-toggle-header { padding: 0 0 5px; }
.lane.collapsed .lane-toggle-header { margin: 0; padding: 0; border: 0; }
.lane-toggle { display: flex; align-items: center; gap: 5px; width: 100%; padding: 3px; border: 0; border-radius: 5px; background: transparent; font-weight: inherit; text-align: left; }
.lane-toggle:hover { background: #e4e9f1; }
.lane-toggle-heading { display: flex; flex: 1; align-items: center; gap: 5px; }
.lane-toggle-label { flex: 1; }
.lane-toggle .lane-indicator { flex: none; }
.lane-toggle-action { display: flex; align-items: center; gap: 3px; color: var(--accent); font-size: .75rem; line-height: 1.35; }
.lane-toggle-action svg { width: 14px; height: 14px; }
.lane-toggle[aria-expanded="true"] .lane-toggle-action svg { transform: rotate(180deg); }
.lane.collapsed .lane-toggle { flex-direction: column; align-items: stretch; gap: 4px; padding-inline: 2px; }
.lane.collapsed .lane-toggle-heading { gap: 3px; }
.lane.collapsed .lane-toggle-heading .count { padding-inline: 4px; }
.lane.collapsed .lane-toggle-action { justify-content: center; padding-block: 2px 1px; }
.lane.collapsed .lane-toggle-action svg { width: 11px; height: 11px; }
.lane-indicator { background: var(--lane, #7d8ca5); width: 4px; height: 17px; border-radius: 3px; }
.count { display: inline-flex; justify-content: center; min-width: 22px; border-radius: 6px; padding: 1px 6px; background: #e1e6f0; color: #4d5b73; font-size: .75rem; font-variant-numeric: tabular-nums; }
.lane-body { display: grid; gap: 8px; }
.secondary .lane-body { grid-template-columns: repeat(auto-fill, minmax(227px, 1fr)); align-items: start; }
.sublane h3 { margin: 3px 3px 7px; display: flex; align-items: center; gap: 6px; font-size: .81rem; color: #51617c; }
.sublane h3 .count { font-size: .71rem; min-width: 19px; }
.sublane h3::before { content: ''; width: 7px; height: 7px; border-radius: 50%; background: #987434; }
.sublane.approved h3::before { background: #318267; }
.sublane + .sublane { margin-top: 5px; padding-top: 7px; border-top: 1px dashed #d1d9e8; }
.sublane-cards { display: grid; gap: 8px; }
.card { min-width: 0; padding: 11px; border: 1px solid #dfe5ef; border-radius: 9px; background: var(--surface); box-shadow: 0 2px 3px #26345508; }
.card:hover { border-color: #c2b8e1; }
.card.dragging { border: 1px dashed #a99abc; background: #e8e3f3; box-shadow: none; }
.card.dragging > * { visibility: hidden; }
.card.drag-preview { position: fixed; top: 0; left: 0; z-index: 8; pointer-events: none; will-change: transform;
  border-color: #b8aad8; background: #fff; box-shadow: 0 10px 28px #21183a26, 0 1px 5px #21183a1a; }
.card.drag-preview.outside-group { opacity: .72; }
.card-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 5px; }
.card-title { display: flex; flex: 1; align-items: flex-start; justify-content: space-between; gap: 6px; min-width: 0; text-align: left; background: none; border: 0; border-radius: 4px; padding: 0; font-weight: 710; font-size: .96rem; line-height: 1.4; }
.card-title-name { min-width: 0; overflow-wrap: anywhere; }
.card-detail-hint { flex: none; padding-inline: 5px; border-radius: 4px; background: #f2edff; color: var(--accent-deep); font-size: .74rem; font-weight: 650; line-height: 1.8; white-space: nowrap; }
.card-title:is(:hover, :focus-visible) .card-title-name { color: var(--accent-deep); text-decoration: underline; text-underline-offset: 3px; }
.card-title:is(:hover, :focus-visible) .card-detail-hint { background: #e9e1fa; }
.grip { color: #718099; cursor: grab; padding: 1px 0 1px 4px; user-select: none; touch-action: none; font-size: .95rem; }
body:not(:has(#drag-sort-switch[aria-checked="true"]:not([hidden]))) .grip { display: none; }
.lanes:has(.card.dragging) { cursor: grabbing; user-select: none; }
.card-id { margin: 5px 0 8px; font-size: .76rem; color: var(--faint); line-height: 1.3; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.store-label { display: inline-flex; margin: 6px 0 1px; font-size: .76rem; color: #4a4975; border-radius: 4px; background: #eeedf7; padding: 2px 5px; }
.card-material, .card-estimate { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 6px; color: var(--muted); font-size: .8rem; line-height: 1.35; margin-bottom: 7px; }
.material { font-size: .73rem; font-weight: 740; padding: 3px 6px; background: #e8effa; color: #365888; border-radius: 5px; }
.material.pla { background: #eaf3e8; color: #28613b; }
.color-inline { display: inline-flex; min-width: 0; align-items: center; gap: 4px; flex-wrap: wrap; }
.color-inline > span:last-child { min-width: 0; overflow-wrap: anywhere; }
.color-variant-list { display: grid; gap: 6px; min-width: 0; }
.color-dot { display: inline-block; width: 11px; height: 11px; flex: none; border-radius: 4px; border: 1px solid #252b3962; background: var(--swatch, #fff); }
.color-dot.transparent { background: repeating-conic-gradient(#dfe5ed 0% 25%, #fff 0% 50%) 0 0 / 6px 6px; }
.card-estimate svg { font-size: .82rem; }
.card-estimate { font-variant-numeric: tabular-nums; }
.estimate-scope { color: #53647a; font-size: .73rem; }
.card-states { display: flex; flex-wrap: wrap; gap: 4px; margin: 8px 0; }
.state { padding: 3px 6px; display: inline-flex; align-items: center; min-width: 0; border-radius: 5px; background: #edf0f7; color: #52627c; font-size: .75rem; font-weight: 630; line-height: 1.35; }
.state.good { background: #e6f4ed; color: #17684e; }
.state.warn { background: #fff1d9; color: #88530c; }
.state.alert { background: #fce9ed; color: #9b2c42; }
.state.editing-state { display: inline-block; }
.editing-status { white-space: nowrap; }
.editing-dots { display: inline-block; animation: editing-dots 2s steps(4, jump-none) infinite; }
@keyframes editing-dots {
  from { clip-path: inset(0 100% 0 0); }
  to { clip-path: inset(0); }
}
@media (prefers-reduced-motion: reduce) {
  .editing-dots { display: none; animation: none; }
}
.card-bottom { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 6px; border-top: 1px solid #edf0f5; padding-top: 8px; margin-top: 8px; }
.person { display: inline-flex; gap: 5px; align-items: center; color: var(--muted); font-size: .8rem; white-space: nowrap; }
.person .avatar { width: 22px; height: 22px; border-radius: 6px; font-size: .67rem; }
.card-bottom .btn { padding: 5px 7px; min-height: 29px; font-size: .75rem; border-radius: 6px; }
.card-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 5px; margin-top: 7px; }
.card-actions .btn { width: 100%; min-height: 32px; padding: 5px 7px; font-size: .8rem; border-radius: 6px; }
.empty { color: var(--muted); text-align: center; font-size: .79rem; padding: 14px 5px; border: 1px dashed #d4dcea; border-radius: 8px; }
dialog { padding: 0; border: 0; color: var(--ink); background: #fff; }
dialog::backdrop { background: #12172e70; }
.detail-dialog { width: min(100%, 556px); max-width: 100%; max-height: 100%; height: 100%; height: 100dvh; margin: 0 0 0 auto; border-left: 1px solid var(--line); box-shadow: -14px 0 55px #151c3930; }
.detail-inner { display: flex; flex-direction: column; height: 100%; }
.dialog-head, .dialog-foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 16px 20px; background: white; }
.dialog-head { border-bottom: 1px solid var(--line); }
.dialog-head h2 { margin: 0; font-size: 1.22rem; overflow-wrap: anywhere; }
.dialog-head p { margin: 5px 0 0; font-size: .83rem; color: var(--muted); }
.release-history { display: grid; gap: 8px; max-height: min(60vh, 480px); overflow-y: auto; overscroll-behavior: contain; }
.release-entry { border: 1px solid var(--line); border-radius: 8px; }
.release-entry > summary { display: flex; align-items: center; flex-wrap: wrap; gap: 5px 10px; min-height: 42px; padding: 9px 12px; border-radius: 8px; list-style: none; font-size: .85rem; }
.release-entry > summary::-webkit-details-marker { display: none; }
.release-entry > summary:hover { background: var(--canvas); }
.release-entry > summary::after { content: ""; width: 6px; height: 6px; margin-inline-start: auto; border: solid var(--muted); border-width: 0 1.5px 1.5px 0; transform: rotate(45deg); }
.release-entry[open] > summary::after { transform: rotate(225deg); }
.release-entry time { color: var(--muted); font-size: .78rem; font-variant-numeric: tabular-nums; }
.release-current { color: var(--accent-deep); font-size: .78rem; }
.release-entry ul { margin: 0; padding: 0 12px 12px 31px; font-size: .88rem; line-height: 1.55; }
.release-entry li + li { margin-top: 4px; }
.dialog-foot { justify-content: flex-end; border-top: 1px solid var(--line); }
.detail-body { overflow-y: auto; padding: 16px 20px 22px; flex: 1; }
.form-section + .form-section { border-top: 1px solid #e7ebf3; margin-top: 19px; padding-top: 16px; }
.form-section h3 { margin: 0 0 11px; font-size: .98rem; }
.fields { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 11px; }
fieldset.fields { border: 0; min-inline-size: 0; padding: 0; margin: 0; }
.field { min-width: 0; display: flex; flex-direction: column; gap: 5px; }
.fields .full { grid-column: 1 / -1; }
.field-link-tools { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 4px 10px; }
.text-btn { padding: 0; border: 0; background: transparent; color: var(--accent-deep); font-size: .8rem; }
.text-btn:hover { text-decoration: underline; }
.field-label { color: #38465e; font-size: .85rem; font-weight: 650; }
.field input, .field select, .field textarea { width: 100%; padding: 9px 10px; border-radius: 7px; border: 1px solid #d6dfed; color: var(--ink); background-color: #fff; font-size: .89rem; }
.field select { padding-right: 26px; }
.field input:disabled, .field select:disabled, .field textarea:disabled { color: #53617a; background-color: #f4f6fa; opacity: 1; }
.field textarea { min-height: 86px; resize: vertical; }
.indicator-line { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.action-row { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 9px; }
.hint { margin: 0; font-size: .78rem; color: var(--muted); line-height: 1.55; }
.form-error { color: var(--red); font-size: .86rem; margin: 9px 0 0; }
.form-error:empty { display: none; }
.segmented { display: flex; gap: 6px; }
.segmented label { position: relative; flex: 1 1 auto; }
.segmented input, .swatch input { position: absolute; width: 1px; height: 1px; padding: 0; margin: 0; opacity: 0; }
.segmented span { display: grid; place-items: center; min-height: 35px; padding: 4px 8px; border-radius: 7px; border: 1px solid var(--line); font-size: .84rem; cursor: pointer; color: var(--muted); }
.segmented input:checked + span { color: var(--accent-deep); border-color: #ad9de7; background: #f2edff; font-weight: 650; }
.segmented input:focus-visible + span, .swatch input:focus-visible + span { outline: 2px solid #7355dc; outline-offset: 2px; }
.color-mode { border: 0; min-inline-size: 0; margin: 0; padding: 0; }
.color-variant { min-width: 0; padding: 7px; border: 1px solid var(--line); border-radius: 8px; background: #f7f8fc; }
.color-variant-header { display: flex; align-items: center; justify-content: space-between; gap: 5px; margin-bottom: 5px; }
.color-variant-remove { min-height: 25px; padding: 2px 6px; font-size: .76rem; }
.add-color-variant { align-self: flex-start; }
.inline-color-picker { display: grid; gap: 6px; }
.color-picker-actions { display: flex; flex-wrap: wrap; gap: 5px; }
.color-picker-actions .btn { min-height: 28px; padding: 3px 7px; font-size: .76rem; }
.selected-extra-colors { display: flex; flex-wrap: wrap; gap: 5px; }
.extra-color-chip { display: inline-flex; align-items: center; gap: 4px; padding: 3px 6px; border-radius: 5px; background: #f2edff; color: var(--accent-deep); font-size: .76rem; }
.extra-color-chip > span:not(.color-dot), .swatch-name { min-width: 0; overflow-wrap: anywhere; }
.palette { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 5px; }
.swatch { position: relative; }
.swatch > span { display: flex; align-items: center; gap: 5px; background: white; border: 1px solid #e2e6ee; border-radius: 7px; color: #46546a; padding: 6px 5px; min-height: 31px; font-size: .78rem; cursor: pointer; }
.swatch input:checked + span { border-color: #a798db; background: #f3eeff; color: var(--accent-deep); }
.swatch .selected-mark { visibility: hidden; margin-left: auto; font-size: .74rem; }
.swatch input:checked + span .selected-mark { visibility: visible; }
.swatch .color-dot { width: 14px; height: 14px; }
.color-picker-content .palette { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.color-picker-group + .color-picker-group { margin-top: 10px; }
.color-picker-group h3 { margin: 0 0 5px; }
.color-picker-search input { width: 100%; }
.color-picker-foot .hint { margin-inline-end: auto; }
.custom-color-fields { grid-template-columns: auto minmax(0, 1fr); }
.color-wheel { display: block; position: relative; width: min(238px, 68vw, 37vh); aspect-ratio: 1; margin: 0 auto 13px; padding: 0; border: 0; border-radius: 50%; cursor: crosshair; touch-action: none; user-select: none;
  background: radial-gradient(circle closest-side, #fff, #fff0), conic-gradient(from 90deg, #f00, #f0f, #00f, #0ff, #0f0, #ff0, #f00); }
.color-wheel::before { content: ""; position: absolute; inset: 0; border-radius: inherit; background: #000; opacity: var(--wheel-shade, 0); pointer-events: none; }
.color-wheel-marker { position: absolute; left: var(--wheel-x, 50%); top: var(--wheel-y, 50%); width: 15px; height: 15px; transform: translate(-50%, -50%); border: 2px solid #fff; border-radius: 50%; box-shadow: 0 0 0 1px #202638; pointer-events: none; }
.color-wheel-brightness { display: flex; align-items: center; gap: 9px; margin-bottom: 12px; }
.color-wheel-brightness input { flex: 1; min-width: 0; height: 20px; margin: 0; border: 1px solid #a1aaba; border-radius: 6px;
  appearance: none; direction: rtl; cursor: ew-resize; background: linear-gradient(to right, var(--wheel-bright-color, #fff), #000); }
.color-wheel-brightness input::-webkit-slider-runnable-track { height: 18px; border-radius: inherit; background: transparent; }
.color-wheel-brightness input::-webkit-slider-thumb { appearance: none; width: 13px; height: 24px; margin-top: -3px;
  border: 1px solid #858e9d; border-radius: 8px; background: #d4d9e1; box-shadow: 0 1px 2px #13182740; }
.color-wheel-brightness input::-moz-range-track { height: 18px; border-radius: inherit; background: transparent; }
.color-wheel-brightness input::-moz-range-progress { background: transparent; }
.color-wheel-brightness input::-moz-range-thumb { box-sizing: border-box; width: 13px; height: 24px;
  border: 1px solid #858e9d; border-radius: 8px; background: #d4d9e1; box-shadow: 0 1px 2px #13182740; }
.custom-color-preview { display: flex; align-items: center; gap: 6px; min-height: 38px; padding: 5px 7px; border: 1px solid var(--line); border-radius: 7px; color: var(--muted); font-size: .76rem; }
.custom-color-preview .color-dot { width: 19px; height: 19px; }
.history { width: 100%; table-layout: fixed; border-collapse: collapse; font-size: .83rem; color: #44526b; }
.history th, .history td { padding: 9px 12px; border: 1px solid var(--line); text-align: left; vertical-align: top; overflow-wrap: anywhere; }
.history th { background: #f4f6fa; color: var(--ink); }
.history th:first-child { width: 5.5rem; }
.history th:last-child { width: 10.5rem; }
.history time { color: var(--muted); font-size: .78rem; font-variant-numeric: tabular-nums; }
.history time span { white-space: nowrap; }
.note-text { white-space: pre-wrap; overflow-wrap: anywhere; margin: 0; color: #44526b; font-size: .9rem; line-height: 1.55; }
.action-dialog { width: min(426px, calc(100% - 30px)); border-radius: 13px; box-shadow: 0 20px 75px #1c23454d; }
.action-dialog:has(.history) { width: min(700px, calc(100% - 24px)); }
.action-content { padding: 16px 20px; }
.management-list { overflow-x: auto; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); }
.management-empty { margin: 0; padding: 20px; color: var(--muted); font-size: .9rem; }
.management-empty p { margin: 0 0 10px; }
.management-table { border-collapse: collapse; width: 100%; min-width: 420px; text-align: left; font-size: .9rem; }
.management-table th, .management-table td { padding: 12px 15px; border-bottom: 1px solid var(--line); overflow-wrap: anywhere; }
.management-table thead th { background: #f2f4f9; color: #43526a; font-size: .83rem; white-space: nowrap; }
.management-table th[scope="row"] { font-weight: 650; }
.management-table tr:last-child :is(th, td) { border-bottom: 0; }
.management-table :is(th, td):last-child { width: 1%; text-align: right; white-space: nowrap; }
.management-table .account-name { color: var(--muted); }
.management-table .state { margin: 2px 0; }
.action-dialog:has(.management-form) { width: min(500px, calc(100% - 26px)); }
.management-operators { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px; padding: 0; margin: 0; border: 0; min-width: 0; }
.management-operators legend { margin-bottom: 5px; }
.management-operators .hint { grid-column: 1 / -1; }
.management-option { display: flex; gap: 7px; align-items: center; min-width: 0; padding: 7px 9px; border: 1px solid var(--line); border-radius: 7px; cursor: pointer; }
.management-option:has(input:checked) { background: #f2edff; border-color: #ad9de7; }
.management-option input { flex: none; margin: 0; accent-color: var(--accent); }
.management-option span { min-width: 0; overflow-wrap: anywhere; }
.management-option strong, .management-option small { display: block; font-size: .85rem; }
.management-option small { margin-top: 2px; font-size: .74rem; color: var(--muted); }
@media (max-width: 480px) {
  .action-dialog:has(.history) .action-content { padding: 12px; }
  .history th, .history td { padding: 7px; }
  .history th:first-child { width: 3.7rem; }
  .history th:last-child { width: 6rem; }
}
.toast { position: fixed; z-index: 10; bottom: 17px; left: 50%; transform: translateX(-50%); padding: 11px 17px; max-width: calc(100% - 24px); border-radius: 9px; background: #222940; color: white; font-size: .88rem; box-shadow: 0 7px 24px #191d3d36; pointer-events: none; }
.toast:empty { display: none; }
body:has(dialog[open]) { overflow: hidden; }
@media (max-width: 1100px) {
  .summary { gap: 8px; }
  .stat { gap: 8px; padding: 8px 9px; }
}
@media (max-width: 760px) {
  .topbar { padding: 7px 12px; min-height: 47px; gap: 8px; }
  .topbar-brand .brand-mark { width: 29px; height: 29px; border-radius: 7px; }
  .topbar-main, .identity { gap: 7px; }
  .store-navigation { padding-inline-start: 7px; }
  .topbar-brand strong, #connection-environment { display: none; }
  .connection { padding-inline: 5px; }
  .page { padding: 17px 12px 22px; }
  .page-heading { margin-bottom: 13px; }
  .page-heading p { margin-top: 5px; }
  .summary { grid-template-columns: repeat(2, minmax(0, 1fr)); margin-bottom: 12px; }
  .stat { min-height: 65px; }
  .board-toolbar { align-items: flex-start; flex-wrap: wrap; gap: 5px; margin-bottom: 9px; }
  .board-tabs { gap: 10px; }
  .tab { padding: 7px 2px; }
  .search { width: 100%; }
  .search input { width: 100%; }
  .lanes { grid-template-columns: repeat(4, minmax(242px, 77vw)); scroll-snap-type: x proximity; }
  .lanes.has-collapsed-complete { grid-template-columns: repeat(3, minmax(242px, 77vw)) var(--collapsed-complete-width); }
  .lane { scroll-snap-align: start; }
}
@media (max-width: 390px) {
  .identity-name { position: absolute; width: 1px; height: 1px; clip-path: inset(50%); }
  .account-menu { margin-inline-start: 0; }
  .palette { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .detail-body, .dialog-head, .dialog-foot { padding-left: 12px; padding-right: 12px; }
}
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { scroll-behavior: auto !important; } }

.more-row { display: flex; justify-content: flex-end; margin-top: 4px; }
.more-row .quiet { border-color: transparent; background: transparent; color: var(--muted); min-height: 26px; padding: 2px 5px; font-size: .78rem; }
.more-row .quiet:hover { color: var(--accent-deep); background: #f2eff9; }
.heading-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 6px; }
.heading-actions:not(:has(> button:not([hidden]), > #page-actions:not(:empty))), #page-actions:empty { display: none; }
.heading-switch { display: inline-flex; align-items: center; gap: 8px; min-height: 36px; padding: 4px 8px; border: 0; border-radius: 8px; background: transparent; color: var(--ink); font-size: .83rem; cursor: pointer; }
.heading-switch:hover { background: #edf0f6; }
.heading-switch:disabled { cursor: wait; }
.switch-track { width: 37px; height: 22px; flex: none; border-radius: 11px; background: #8692a5; padding: 3px; transition: background-color 200ms ease; }
.switch-track::before { content: ""; display: block; width: 16px; height: 16px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px #20283c42; transition: transform 200ms ease; }
.heading-switch[aria-checked="true"] .switch-track { background: var(--accent); }
.heading-switch[aria-checked="true"] .switch-track::before { transform: translateX(15px); }
@media (prefers-reduced-motion: reduce) {
  .switch-track, .switch-track::before { transition: none; }
}
#file-form { display: grid; justify-items: start; gap: 10px; }
#file-form input { max-width: 100%; }
.file-list { padding: 0; list-style: none; }
.file-list li { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; padding: 6px 0; }
.file-list a { overflow-wrap: anywhere; }
.file-list small { flex-shrink: 0; color: var(--muted); }
