:root {
  color-scheme: light;
  --ws-bg: #f4f6f8;
  --ws-surface: #ffffff;
  --ws-sidebar: #ffffff;
  --ws-sidebar-soft: #f5f7f8;
  --ws-topbar: #ffffff;
  --ws-text: #17202a;
  --ws-muted: #66717e;
  --ws-line: #dfe4e8;
  --ws-primary: #164a3a;
  --ws-primary-strong: #0f382c;
  --ws-accent: #d75a3d;
  --ws-focus: #4b82f0;
  --ws-shadow: 0 10px 30px rgba(22, 31, 39, 0.08);
  --ws-sidebar-width: 252px;
  font-family: Inter, "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
}

.project-assets-toolbar,
.project-assets-layout {
  display: grid;
  grid-template-columns: minmax(260px, 0.72fr) minmax(0, 1.6fr);
  gap: 10px;
  margin-bottom: 16px;
}

.project-create-form,
.project-assets-filters {
  display: grid;
  gap: 12px;
  align-content: start;
}

.project-trash-toggle {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 700;
}

.project-trash-toggle input {
  width: 16px;
  height: 16px;
}

.project-list-section,
.asset-library-section {
  min-width: 0;
}

.project-list {
  display: grid;
  gap: 8px;
}

.project-list-item {
  width: 100%;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto 20px;
  gap: 10px;
  align-items: center;
  padding: 12px;
  border: 1px solid var(--workspace-border, #dce3eb);
  border-radius: 8px;
  background: var(--workspace-surface, #fff);
  color: inherit;
  text-align: left;
  cursor: pointer;
}

.project-list-item:hover,
.project-list-item.is-active {
  border-color: var(--aurora-accent, #2979ff);
  box-shadow: inset 3px 0 0 var(--aurora-accent, #2979ff);
}

.project-list-item span,
.project-list-item em {
  min-width: 0;
}

.project-list-item strong,
.project-list-item small {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.project-list-item small {
  margin-top: 4px;
  color: var(--workspace-muted, #667085);
}

.project-list-item em {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 4px;
  color: var(--workspace-muted, #667085);
  font-style: normal;
  font-size: 12px;
}

.project-list-item em b {
  padding: 3px 6px;
  border-radius: 4px;
  background: color-mix(in srgb, var(--aurora-accent, #2979ff) 10%, #fff);
  color: var(--aurora-accent, #2979ff);
}

.asset-attach-form {
  display: grid;
  grid-template-columns: 110px minmax(0, 1fr) auto;
  gap: 8px;
  margin-bottom: 14px;
}

.asset-attach-form input,
.asset-attach-form select {
  min-width: 0;
  min-height: 40px;
  border: 1px solid var(--workspace-border, #dce3eb);
  border-radius: 6px;
  padding: 0 10px;
  background: var(--workspace-surface, #fff);
  color: inherit;
}

.asset-library-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.asset-library-item {
  min-width: 0;
  overflow: hidden;
  border: 1px solid var(--workspace-border, #dce3eb);
  border-radius: 8px;
  background: var(--workspace-surface, #fff);
}

.asset-preview {
  position: relative;
  aspect-ratio: 4 / 3;
  display: grid;
  place-items: center;
  overflow: hidden;
  background: #eef2f6;
}

.asset-preview img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.asset-preview > span:not(.asset-file-icon) {
  position: absolute;
  left: 8px;
  bottom: 8px;
  padding: 3px 6px;
  border-radius: 4px;
  background: rgba(17, 24, 39, 0.82);
  color: #fff;
  font-size: 11px;
  text-transform: uppercase;
}

.asset-file-icon svg {
  width: 42px;
  height: 42px;
  color: var(--aurora-accent, #2979ff);
}

.asset-library-copy {
  display: grid;
  gap: 3px;
  padding: 10px;
}

.asset-library-copy strong,
.asset-library-copy small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.asset-library-copy small {
  color: var(--workspace-muted, #667085);
}

.asset-library-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  padding: 0 10px 10px;
}

.asset-library-actions button,
.asset-library-actions a {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  min-height: 30px;
  padding: 0 7px;
  border: 1px solid var(--workspace-border, #dce3eb);
  border-radius: 5px;
  background: transparent;
  color: inherit;
  font-size: 12px;
  text-decoration: none;
  cursor: pointer;
}

.asset-library-actions svg {
  width: 14px;
  height: 14px;
}

.asset-library-actions .danger {
  color: #b42318;
}

.workspace-asset-preview-dialog {
  width: min(920px, calc(100vw - 32px));
  max-height: calc(100vh - 32px);
  padding: 42px 14px 14px;
  border: 0;
  border-radius: 8px;
  background: #111827;
}

.workspace-asset-preview-dialog::backdrop {
  background: rgba(15, 23, 42, 0.74);
}

.workspace-asset-preview-dialog > button {
  position: absolute;
  top: 8px;
  right: 8px;
  color: #fff;
}

.workspace-asset-preview-dialog img,
.workspace-asset-preview-dialog video {
  display: block;
  max-width: 100%;
  max-height: calc(100vh - 100px);
  margin: 0 auto;
}

@media (max-width: 980px) {
  .project-assets-toolbar,
  .project-assets-layout {
    grid-template-columns: 1fr;
  }

  .asset-library-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 620px) {
  .asset-attach-form,
  .asset-library-grid {
    grid-template-columns: 1fr;
  }
}

* { box-sizing: border-box; }
html { min-width: 320px; background: var(--ws-bg); }
body { margin: 0; color: var(--ws-text); background: var(--ws-bg); font-size: 14px; }
button, input, textarea { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
a { color: inherit; text-decoration: none; }
button { letter-spacing: 0; }
[hidden] { display: none !important; }

.workspace-shell { min-height: 100vh; }
.workspace-sidebar {
  position: fixed;
  inset: 0 auto 0 0;
  z-index: 30;
  width: var(--ws-sidebar-width);
  display: flex;
  flex-direction: column;
  padding: 10px 12px;
  color: var(--ws-text);
  background: var(--ws-sidebar);
  border-right: 1px solid var(--ws-line);
  overflow-y: hidden;
}

.workspace-brand { display: flex; align-items: center; gap: 9px; min-height: 44px; padding: 0 6px 8px; border-bottom: 1px solid var(--ws-line); }
.workspace-brand-mark, .workspace-login-mark {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  flex: 0 0 32px;
  color: #fff;
  background: var(--ws-primary);
  border: 1px solid #407161;
  border-radius: 7px;
  font-weight: 800;
  font-size: 12px;
}
.workspace-brand strong { display: block; font-size: 14px; line-height: 1.25; }
.workspace-brand small { display: block; margin-top: 1px; color: var(--ws-muted); font-size: 10px; }
.workspace-nav {
  display: grid;
  grid-template-rows: minmax(45px, .8fr) minmax(183px, 3fr) minmax(211px, 3.45fr) minmax(127px, 2.1fr) minmax(71px, 1.15fr);
  min-height: 0;
  flex: 1;
  padding: 4px 0;
  overflow: visible;
}
.workspace-nav-group { display: grid; grid-template-rows: auto; grid-auto-rows: minmax(28px, 1fr); align-content: stretch; min-height: 0; margin: 0; }
.workspace-nav-group > span {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 4px 6px 3px;
  color: #74827c;
  font-size: 11px;
  font-weight: 800;
  line-height: 1;
  letter-spacing: 0;
  text-align: center;
}
.workspace-nav-group > span::before,
.workspace-nav-group > span::after { content: ""; height: 1px; flex: 1; background: linear-gradient(90deg, transparent, #d4ddd9); }
.workspace-nav-group > span::after { background: linear-gradient(90deg, #d4ddd9, transparent); }
.workspace-nav a {
  position: relative;
  display: flex;
  align-items: center;
  gap: 5px;
  min-height: 28px;
  margin: 0;
  padding: 2px 8px;
  color: #42514b;
  border-radius: 6px;
  font-size: 12.5px;
  font-weight: 600;
  line-height: 1.25;
  transition: color 150ms ease, background 150ms ease;
}
.workspace-nav a:hover { color: var(--ws-primary); background: #f0f5f2; }
.workspace-nav a.is-active { color: var(--ws-primary); background: #e7f1ec; box-shadow: inset 3px 0 0 #58a487; }
.workspace-nav a > svg { display: none; }
.workspace-menu-label { min-width: 0; flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.workspace-menu-badge { display: inline-flex; align-items: center; justify-content: center; flex: 0 0 auto; max-width: 112px; min-height: 18px; padding: 1px 8px; overflow: hidden; border: 1px solid transparent; border-radius: 999px; font-size: 12px; font-weight: 900; line-height: 1.05; text-overflow: ellipsis; white-space: nowrap; }
.workspace-menu-badge.is-green { color: #14623f; background: #e2f5e9; border-color: #b8dfc7; }
.workspace-menu-badge.is-blue { color: #245d9b; background: #e8f2ff; border-color: #bdd6f4; }
.workspace-menu-badge.is-orange { color: #9a4b0b; background: #fff0db; border-color: #efca95; }
.workspace-menu-badge.is-red { color: #a3342d; background: #ffebe8; border-color: #efc2bd; }
.workspace-menu-badge.is-purple { color: #6f4591; background: #f3eafb; border-color: #d9c1ec; }
.workspace-menu-badge.is-slate { color: #4e5d68; background: #edf1f3; border-color: #ced7dc; }
.workspace-nav-reward { margin-left: auto; padding: 2px 5px; color: #163d30; background: #9fe0a9; border-radius: 4px; font-size: 9px; font-weight: 900; }
.workspace-service { display: flex; width: 100%; min-height: 52px; align-items: center; justify-content: center; gap: 0; padding: 8px 10px; color: #fff; background: #111318; border: 1px solid #111318; border-radius: 7px; box-shadow: 0 6px 14px rgba(17, 19, 24, 0.14); cursor: pointer; text-align: center; text-decoration: none; }
.workspace-service svg { display: none; }
.workspace-service span { min-width: 0; width: 100%; }
.workspace-service strong, .workspace-service small { display: block; }
.workspace-service strong { color: #fff; font-size: 15px; font-weight: 900; line-height: 1.2; }
.workspace-service small { margin-top: 3px; color: #c8cbd2; font-size: 10px; font-weight: 700; line-height: 1.2; }
.workspace-service.is-active { border-color: #586174; box-shadow: inset 0 0 0 1px rgba(255,255,255,.12), 0 8px 18px rgba(17,19,24,.2); }

.workspace-stage { min-height: 100vh; margin-left: var(--ws-sidebar-width); }
.workspace-topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  gap: 16px;
  min-height: 66px;
  padding: 10px 28px;
  background: color-mix(in srgb, var(--ws-topbar) 95%, transparent);
  border-bottom: 1px solid var(--ws-line);
  backdrop-filter: blur(12px);
}
.workspace-menu-button { display: none !important; }
.workspace-search { display: flex; align-items: center; gap: 9px; width: min(280px, 24vw); height: 38px; padding: 0 12px; color: var(--ws-muted); background: #f4f6f7; border: 1px solid transparent; border-radius: 6px; }
.workspace-search:focus-within { background: #fff; border-color: #9fbbb1; box-shadow: 0 0 0 3px rgba(22, 74, 58, 0.09); }
.workspace-search svg { width: 17px; }
.workspace-search input { width: 100%; color: var(--ws-text); background: transparent; border: 0; outline: 0; }
.workspace-topbar-slogan {
  position: absolute;
  left: 50%;
  width: min(640px, 38vw);
  min-width: 0;
  margin: 0;
  background: linear-gradient(90deg, #8b5cf6 0%, #d946ef 28%, #22d3ee 58%, #a78bfa 78%, #f472b6 100%);
  background-clip: text;
  color: transparent;
  font-size: 20px;
  font-weight: 950;
  line-height: 1.2;
  text-align: center;
  text-shadow: 0 0 18px rgba(168, 85, 247, 0.3);
  transform: translateX(-50%);
  white-space: nowrap;
}
.workspace-topbar-actions { position: relative; display: flex; align-items: center; gap: 9px; margin-left: auto; }
.workspace-leaf-chip { display: inline-flex; align-items: center; gap: 5px; min-width: 80px; height: 36px; padding: 0 10px; color: #14533c; background: #e4f4e9; border: 1px solid #bcdcc7; border-radius: 6px; font-weight: 800; }
.workspace-leaf-chip:hover, .workspace-leaf-chip.is-active { color: #fff; background: #286b4d; border-color: #286b4d; }
.workspace-leaf-chip svg { width: 16px; height: 16px; }
.workspace-leaf-chip span { margin-left: auto; font-variant-numeric: tabular-nums; }
.workspace-leaf-chip small { font-size: 10px; font-weight: 700; }
.workspace-icon-button { position: relative; display: inline-grid; place-items: center; width: 36px; height: 36px; padding: 0; color: #4c5864; background: #fff; border: 1px solid var(--ws-line); border-radius: 6px; cursor: pointer; }
.workspace-icon-button:hover { color: var(--ws-primary); border-color: #a8beb6; }
.workspace-icon-button svg { width: 17px; height: 17px; }
.workspace-unread-dot { position: absolute; top: 7px; right: 7px; width: 6px; height: 6px; background: #e0563f; border: 1px solid #fff; border-radius: 50%; }

.workspace-notice-drawer {
  position: fixed;
  top: 64px;
  right: 18px;
  z-index: 70;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  width: min(410px, calc(100vw - 28px));
  max-height: min(650px, calc(100vh - 92px));
  overflow: hidden;
  color: var(--ws-text);
  background: #fff;
  border: 1px solid var(--ws-line);
  border-radius: 8px;
  box-shadow: 0 24px 70px rgba(21, 31, 38, .2);
}
.workspace-notice-drawer > header { display: flex; align-items: center; justify-content: space-between; padding: 15px 16px; border-bottom: 1px solid var(--ws-line); }
.workspace-notice-drawer h2, .workspace-notice-drawer small { margin: 0; }
.workspace-notice-drawer h2 { margin-top: 2px; font-size: 18px; }
.workspace-notice-drawer small { color: var(--ws-primary); font-size: 9px; font-weight: 900; }
.workspace-notice-list { display: grid; gap: 10px; padding: 12px; overflow-y: auto; }
.workspace-notice-item { padding: 13px; border: 1px solid var(--ws-line); border-radius: 7px; background: #fff; }
.workspace-notice-item.is-unread { border-color: #a8cbbd; box-shadow: inset 3px 0 0 #2c8060; }
.workspace-notice-item.is-read { background: #f6f8f8; opacity: .82; }
.workspace-notice-item > div { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.workspace-notice-item > div span { color: #1c674c; font-size: 10px; font-weight: 900; }
.workspace-notice-item.is-read > div span { color: var(--ws-muted); }
.workspace-notice-item time { color: var(--ws-muted); font-size: 10px; }
.workspace-notice-item h3 { margin: 9px 0 5px; line-height: 1.25; letter-spacing: 0; }
.workspace-notice-item p { display: -webkit-box; margin: 0 0 10px; overflow: hidden; line-height: 1.65; white-space: pre-wrap; -webkit-box-orient: vertical; -webkit-line-clamp: 4; }
.workspace-notice-empty { margin: 0; padding: 32px 18px; color: var(--ws-muted); text-align: center; }
.workspace-notice-empty.is-error { color: #a23c32; }

.workspace-notice-dialog { width: min(560px, calc(100vw - 28px)); padding: 0; overflow: hidden; color: var(--ws-text); background: #fff; border: 0; border-radius: 8px; box-shadow: 0 30px 90px rgba(10, 20, 28, .34); }
.workspace-notice-dialog::backdrop { background: rgba(8, 13, 18, .68); backdrop-filter: blur(5px); }
.workspace-notice-dialog-accent { height: 6px; background: linear-gradient(90deg, #164a3a, #3f8b6c, #d75a3d); }
.workspace-notice-dialog-body { display: grid; gap: 14px; padding: 28px; }
.workspace-notice-dialog-body > small { color: var(--ws-primary); font-size: 10px; font-weight: 900; }
.workspace-notice-dialog h2 { margin: 0; line-height: 1.25; letter-spacing: 0; }
#workspaceNoticeDialogContent { max-height: min(46vh, 360px); overflow-y: auto; line-height: 1.8; white-space: pre-wrap; overflow-wrap: anywhere; }
#workspaceNoticeDialogTime { margin: 0; color: var(--ws-muted); font-size: 11px; }
#workspaceNoticeReadStatus { min-height: 18px; color: var(--ws-muted); font-size: 11px; text-align: center; }
.workspace-profile { display: flex; align-items: center; gap: 9px; min-width: 170px; height: 44px; padding: 3px 7px 3px 4px; text-align: left; background: transparent; border: 0; border-radius: 6px; cursor: pointer; }
.workspace-profile:hover { background: #f3f5f6; }
.workspace-profile > span:nth-child(2) { min-width: 0; flex: 1; }
.workspace-profile strong, .workspace-profile small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.workspace-profile strong { font-size: 12px; }
.workspace-profile small { margin-top: 2px; color: var(--ws-muted); font-size: 10px; }
.workspace-profile > svg { width: 15px; }
.workspace-profile-menu { position: absolute; top: calc(100% + 8px); right: 0; z-index: 60; width: 170px; padding: 6px; background: #fff; border: 1px solid var(--ws-line); border-radius: 7px; box-shadow: 0 16px 42px rgba(20, 31, 27, .18); }
.workspace-profile-menu[hidden] { display: none; }
.workspace-profile-menu button { display: flex; align-items: center; gap: 9px; width: 100%; min-height: 38px; padding: 8px 10px; color: var(--ws-text); background: transparent; border: 0; border-radius: 5px; cursor: pointer; font-size: 12px; font-weight: 700; }
.workspace-profile-menu button:hover { color: var(--ws-primary); background: #eef5f1; }
.workspace-profile-menu svg { width: 16px; height: 16px; }
.workspace-avatar { display: grid; place-items: center; width: 34px; height: 34px; flex: 0 0 34px; color: #fff; background: #386a59; border-radius: 50%; font-size: 11px; font-weight: 800; }
.workspace-avatar.large { width: 52px; height: 52px; flex-basis: 52px; font-size: 14px; }

.workspace-visit-tabs-shell {
  position: sticky;
  top: 66px;
  z-index: 19;
  display: flex;
  align-items: flex-end;
  gap: 7px;
  min-width: 0;
  height: 46px;
  padding: 7px 28px 0;
  background: color-mix(in srgb, var(--ws-topbar) 93%, #eef2ff 7%);
  border-bottom: 1px solid var(--ws-line);
  box-shadow: 0 7px 18px rgba(34, 28, 73, .035);
  backdrop-filter: blur(14px);
}
.workspace-visit-back {
  display: inline-grid;
  place-items: center;
  width: 34px;
  height: 34px;
  flex: 0 0 34px;
  margin-bottom: 5px;
  padding: 0;
  color: #596172;
  background: rgba(255, 255, 255, .86);
  border: 1px solid #dfe3eb;
  border-radius: 7px;
  cursor: pointer;
}
.workspace-visit-back:hover:not(:disabled) { color: #6d28d9; border-color: #b9a6ff; background: #fff; }
.workspace-visit-back:disabled { opacity: .38; cursor: default; }
.workspace-visit-back svg { width: 16px; height: 16px; }
.workspace-visit-tabs {
  display: flex;
  align-items: flex-end;
  gap: 5px;
  min-width: 0;
  flex: 1;
  height: 39px;
  overflow-x: auto;
  overflow-y: hidden;
  scrollbar-width: thin;
  scrollbar-color: rgba(124, 58, 237, .28) transparent;
}
.workspace-visit-tab {
  position: relative;
  display: flex;
  align-items: center;
  min-width: 126px;
  max-width: 210px;
  height: 34px;
  flex: 0 1 180px;
  color: #5d6472;
  background: rgba(255, 255, 255, .66);
  border: 1px solid #e0e3eb;
  border-bottom-color: #d7dbe5;
  border-radius: 7px 7px 0 0;
  transition: color 150ms ease, background 150ms ease, border-color 150ms ease;
}
.workspace-visit-tab::before {
  position: absolute;
  top: -1px;
  right: 9px;
  left: 9px;
  height: 2px;
  content: "";
  background: transparent;
  border-radius: 2px;
}
.workspace-visit-tab:hover { color: #27233b; background: rgba(255, 255, 255, .94); }
.workspace-visit-tab.is-active {
  z-index: 1;
  color: #262139;
  background: #fff;
  border-color: #d6d0e8;
  border-bottom-color: #fff;
  box-shadow: 0 -5px 14px rgba(105, 74, 173, .08);
}
.workspace-visit-tab.is-active::before { background: linear-gradient(90deg, #7c3aed, #d946ef 48%, #22d3ee); }
.workspace-visit-tab > a {
  display: flex;
  align-items: center;
  gap: 7px;
  min-width: 0;
  height: 100%;
  flex: 1;
  padding: 0 4px 0 10px;
  color: inherit;
  text-decoration: none;
}
.workspace-visit-tab > a svg { width: 14px; height: 14px; flex: 0 0 14px; color: #8b5cf6; }
.workspace-visit-tab > a span { overflow: hidden; font-size: 12px; font-weight: 800; text-overflow: ellipsis; white-space: nowrap; }
.workspace-visit-tab > button {
  display: inline-grid;
  place-items: center;
  width: 26px;
  height: 26px;
  flex: 0 0 26px;
  margin-right: 3px;
  padding: 0;
  color: #8a8f9b;
  background: transparent;
  border: 0;
  border-radius: 5px;
  cursor: pointer;
}
.workspace-visit-tab > button:hover { color: #111827; background: #edf0f5; }
.workspace-visit-tab > button svg { width: 13px; height: 13px; }

.workspace-main { width: min(1440px, 100%); margin: 0 auto; padding: 22px 28px 28px; }
.workspace-tool-subnav {
  display: flex;
  align-items: center;
  gap: 16px;
  min-width: 0;
  margin-bottom: 14px;
  padding: 6px;
  color: #282438;
  background: rgba(255, 255, 255, .9);
  border: 1px solid rgba(106, 91, 142, .15);
  border-radius: 8px;
  box-shadow: 0 10px 26px rgba(43, 31, 79, .06);
}
.workspace-tool-subnav[hidden] { display: none; }
.workspace-tool-subnav-label {
  display: grid;
  align-content: center;
  gap: 2px;
  min-width: 142px;
  padding: 3px 8px 3px 10px;
  box-sizing: border-box;
  border-right: 1px solid #e6e1f0;
}
.workspace-tool-subnav-label small { color: #7c3aed; font-size: 9px; font-weight: 900; line-height: 1.2; }
.workspace-tool-subnav-label strong { overflow: visible; font-size: 13px; font-weight: 900; line-height: 1.25; white-space: nowrap; }
.workspace-tool-subnav-links { display: flex; align-items: center; gap: 6px; min-width: 0; flex: 1; overflow-x: auto; scrollbar-width: none; }
.workspace-tool-subnav-links::-webkit-scrollbar { display: none; }
.workspace-tool-subnav-link {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-width: 108px;
  min-height: 34px;
  flex: 0 0 auto;
  padding: 7px 13px;
  color: #616573;
  background: transparent;
  border: 1px solid transparent;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 850;
  text-decoration: none;
  white-space: nowrap;
}
.workspace-tool-subnav-link:hover { color: #5b21b6; background: #f5f1ff; }
.workspace-tool-subnav-link.is-active {
  color: #fff;
  background: linear-gradient(105deg, #6d28d9, #8b5cf6 55%, #2563eb);
  border-color: rgba(91, 33, 182, .24);
  box-shadow: 0 7px 16px rgba(109, 40, 217, .19);
}
.workspace-tool-subnav-link svg { width: 15px; height: 15px; flex: 0 0 15px; }
html.workspace-route-pending .workspace-view { display: none !important; }
.workspace-view { display: none; }
.workspace-view.is-active { display: block; }
.user-workbench-tabs { display: flex; align-items: center; gap: 4px; margin-bottom: 20px; padding: 5px; background: #edf1f0; border: 1px solid var(--ws-line); border-radius: 7px; overflow-x: auto; scrollbar-width: thin; }
.user-workbench-tabs button { display: inline-flex; align-items: center; justify-content: center; gap: 7px; flex: 1 0 150px; min-height: 40px; padding: 8px 14px; color: #53615c; background: transparent; border: 0; border-radius: 5px; cursor: pointer; font-size: 12px; font-weight: 800; white-space: nowrap; }
.user-workbench-tabs button:hover { color: var(--ws-primary); background: rgba(255, 255, 255, .62); }
.user-workbench-tabs button.is-active { color: #fff; background: var(--ws-primary); box-shadow: 0 5px 14px rgba(25, 75, 57, .18); }
.user-workbench-tabs svg { width: 16px; height: 16px; }
.user-workbench-panel[hidden] { display: none; }
.user-workbench-panel.is-active { display: block; }
.user-workbench-panel > .workspace-page-heading { margin-top: 8px; }
.user-workbench-metrics { margin-bottom: 18px; }
.workspace-product-prices { display: grid; grid-template-columns: minmax(150px, .45fr) minmax(0, 1.55fr); align-items: stretch; gap: 0; margin-bottom: 18px; overflow: hidden; background: #fff; border: 1px solid var(--ws-line); border-radius: 7px; }
.workspace-product-prices header { display: flex; align-items: center; gap: 9px; min-height: 78px; padding: 14px 18px; color: #fff; background: #245c49; }
.workspace-product-prices header svg { width: 19px; height: 19px; }
.workspace-product-prices header strong { font-size: 14px; }
.workspace-product-price-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
.workspace-product-price-grid span { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; min-width: 0; min-height: 39px; padding: 9px 14px; color: #34413c; border-left: 1px solid var(--ws-line); border-top: 1px solid var(--ws-line); font-size: 12px; font-weight: 700; }
.workspace-product-price-grid span:nth-child(-n + 2) { border-top: 0; }
.workspace-product-price-grid strong { margin-left: auto; color: #d92d20; font-size: 15px; font-weight: 850; }
.workspace-product-price-grid small { color: var(--ws-muted); font-size: 10px; }
.user-finance-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; margin-top: 18px; }
.user-finance-grid .workspace-form-surface { display: grid; align-content: start; gap: 13px; }
.workspace-referral-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; margin-top: 18px; }
.workspace-referral-transfer { display: grid; grid-template-columns: minmax(0, 1fr) minmax(180px, 280px) auto; align-items: end; gap: 14px; margin-top: 18px; }
.workspace-referral-transfer .workspace-section-head { grid-column: 1 / -1; }
.workspace-referral-transfer .workspace-form-note { align-self: center; margin: 0; }
.theme-switcher, .referral-widget, .referral-floating-button { display: none !important; }
.workspace-account-actions { display: flex; align-items: center; gap: 13px; margin-top: 14px; }
.workspace-account-actions > span { color: var(--ws-muted); font-size: 11px; }
.workspace-password-form { margin-top: 14px; }
.workspace-form-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin-bottom: 15px; }
.workspace-form-note { margin: -4px 0 2px; color: var(--ws-muted); font-size: 11px; line-height: 1.65; }
.workspace-list { overflow: hidden; background: #fff; border: 1px solid var(--ws-line); border-radius: 7px; }
.workspace-list-row { display: flex; align-items: center; justify-content: space-between; gap: 18px; min-height: 58px; padding: 11px 14px; border-top: 1px solid var(--ws-line); }
.workspace-list-row:first-child { border-top: 0; }
.workspace-list-row div { min-width: 0; }
.workspace-list-row strong, .workspace-list-row small { display: block; }
.workspace-list-row strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 12px; }
.workspace-list-row small { margin-top: 5px; color: var(--ws-muted); font-size: 10px; }
.workspace-pagination { display: flex; align-items: center; justify-content: flex-end; gap: 8px; padding: 12px 14px; color: var(--ws-muted); border-top: 1px solid var(--ws-line); font-size: 11px; }
.workspace-pagination label { display: inline-flex; align-items: center; gap: 5px; }
.workspace-pagination select, .workspace-pagination input { height: 30px; color: var(--ws-text); background: #fff; border: 1px solid var(--ws-line); border-radius: 5px; }
.workspace-pagination input { width: 52px; padding: 0 6px; }
.workspace-pagination button { min-height: 30px; padding: 0 9px; color: var(--ws-text); background: #fff; border: 1px solid var(--ws-line); border-radius: 5px; cursor: pointer; }
.workspace-pagination button:disabled { opacity: .45; cursor: default; }

.media-tool-layout { display: grid; grid-template-columns: minmax(300px, 390px) minmax(0, 1fr); gap: 18px; }
.media-tool-controls { display: grid; align-content: start; gap: 16px; }
.media-dropzone { display: grid; place-items: center; min-height: 148px; padding: 22px; text-align: center; color: var(--ws-muted); background: #f7faf8; border: 1px dashed #9eb9ae; border-radius: 7px; cursor: pointer; }
.media-dropzone.is-dragging { color: var(--ws-primary); background: #eaf4ef; border-color: var(--ws-primary); }
.media-dropzone input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.media-dropzone svg { width: 28px; height: 28px; margin-bottom: 8px; color: var(--ws-primary); }
.media-dropzone strong, .media-dropzone span { display: block; }
.media-dropzone strong { color: var(--ws-text); }
.media-dropzone span { margin-top: 5px; font-size: 11px; }
.media-control-group { display: grid; gap: 10px; padding-top: 14px; border-top: 1px solid var(--ws-line); }
.media-control-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.media-layer-list { display: grid; gap: 6px; }
.media-layer-list p { margin: 0; color: var(--ws-muted); font-size: 11px; }
.media-layer-list button { display: flex; align-items: center; gap: 8px; min-height: 36px; padding: 7px 9px; color: var(--ws-text); background: #f6f8f7; border: 1px solid var(--ws-line); border-radius: 5px; cursor: pointer; }
.media-layer-list button.is-active { color: var(--ws-primary); background: #eaf4ef; border-color: #9eb9ae; }
.media-layer-list svg { width: 15px; }
.media-export-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 9px; }
.media-export-actions:has(#retouchDownloadColor) { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.media-segmented.compact { display: grid; grid-template-columns: 1fr 1fr; width: 100%; margin: 0; }
.media-segmented.compact.retouch-mode-control { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.media-segmented.compact button { justify-content: center; min-height: 36px; padding: 6px 10px; }
.workspace-field-label { display: block; font-size: 12px; font-weight: 700; }
.retouch-subject-options { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.retouch-subject-options button { min-height: 38px; padding: 7px 10px; color: var(--ws-text); background: #f6f8f7; border: 1px solid var(--ws-line); border-radius: 5px; cursor: pointer; font-size: 12px; font-weight: 800; }
.retouch-subject-options button:hover { color: var(--ws-primary); border-color: #9eb9ae; background: #eef5f1; }
.retouch-subject-options button.is-active { color: #fff; background: var(--ws-primary); border-color: var(--ws-primary); }
.retouch-subject-options button:focus-visible { outline: 3px solid rgba(75, 130, 240, .38); outline-offset: 2px; }
.retouch-history-actions { display: grid; grid-template-columns: 1fr 1fr 1.35fr; gap: 8px; }
.retouch-history-actions .workspace-button { min-width: 0; padding-inline: 8px; }
.retouch-color-field input[type="color"] { width: 100%; min-height: 40px; padding: 4px; cursor: pointer; }
#retouchProgress { width: 100%; accent-color: var(--ws-primary); }
.media-canvas-stage, .media-compressor-preview { display: grid; place-items: center; align-content: center; min-height: 620px; padding: 20px; background: #e8ecee; border: 1px solid var(--ws-line); border-radius: 7px; overflow: hidden; }
.media-canvas-stage canvas { width: min(100%, 680px); height: auto; background-color: #fff; background-image: linear-gradient(45deg,#e6e9eb 25%,transparent 25%),linear-gradient(-45deg,#e6e9eb 25%,transparent 25%),linear-gradient(45deg,transparent 75%,#e6e9eb 75%),linear-gradient(-45deg,transparent 75%,#e6e9eb 75%); background-size: 28px 28px; background-position: 0 0,0 14px,14px -14px,-14px 0; box-shadow: 0 8px 28px rgba(24,35,31,.12); touch-action: none; }
.media-canvas-stage p, .media-compressor-preview div { margin: 12px 0 0; color: var(--ws-muted); font-size: 11px; }
.media-canvas-stage .is-error, .media-compressor-preview .is-error { color: #a7392d; }
.media-segmented { display: inline-flex; gap: 4px; margin-bottom: 16px; padding: 4px; background: #e8edeb; border: 1px solid var(--ws-line); border-radius: 7px; }
.media-segmented button { display: inline-flex; align-items: center; gap: 7px; min-height: 38px; padding: 7px 18px; color: var(--ws-muted); background: transparent; border: 0; border-radius: 5px; cursor: pointer; font-weight: 800; }
.media-segmented button.is-active { color: #fff; background: var(--ws-primary); }
.media-segmented svg { width: 16px; }
.media-compressor-panel { display: grid; grid-template-columns: minmax(290px, 380px) minmax(0, 1fr); gap: 18px; }
.media-compressor-form { display: grid; align-content: start; gap: 14px; }
.media-compressor-preview { min-height: 500px; }
.media-compressor-preview canvas, .media-compressor-preview video { display: block; max-width: 100%; max-height: 430px; background: #121614; }

.media-dedupe-view { --dedupe-bg: #07100d; --dedupe-panel: #0e1a16; --dedupe-line: #29453a; --dedupe-text: #eff8f3; --dedupe-muted: #8da399; --dedupe-green: #58e59a; --dedupe-cyan: #58dbe5; --dedupe-amber: #f5bd62; --dedupe-violet: #a99af5; margin: 0 -28px -28px; padding: 16px 28px 28px; min-height: calc(100vh - 94px); color: var(--dedupe-text); background: radial-gradient(circle at 72% 0, #143128 0, transparent 32%), var(--dedupe-bg); }
.media-dedupe-heading { align-items: flex-end; }
.media-dedupe-heading p { color: var(--dedupe-green); font-family: Consolas, monospace; }
.media-dedupe-heading h1 { color: #fff; }
.media-dedupe-heading span { color: var(--dedupe-muted); }
.media-dedupe-engine-state { display: grid; grid-template-columns: 9px 1fr; gap: 2px 9px; min-width: 230px; padding: 10px 13px; background: #0f211a; border: 1px solid #2d5945; border-radius: 8px; }
.media-dedupe-engine-state i { grid-row: 1 / 3; align-self: center; width: 8px; height: 8px; background: var(--dedupe-green); border-radius: 50%; box-shadow: 0 0 14px var(--dedupe-green); }
.media-dedupe-engine-state b { color: #c5f8db; font: 800 11px Consolas, monospace; }
.media-dedupe-engine-state small { color: var(--dedupe-muted); font-size: 10px; }
.media-dedupe-layout { display: grid; grid-template-columns: minmax(300px, .85fr) minmax(430px, 1.3fr) minmax(280px, .78fr); gap: 12px; }
.media-dedupe-card { min-width: 0; overflow: hidden; background: linear-gradient(145deg, rgba(18, 33, 27, .98), rgba(10, 20, 16, .98)); border: 1px solid var(--dedupe-line); border-radius: 10px; box-shadow: 0 14px 36px rgba(0, 0, 0, .24); }
.media-dedupe-card > header { display: flex; align-items: center; justify-content: space-between; min-height: 72px; padding: 15px 16px; border-bottom: 1px solid var(--dedupe-line); }
.media-dedupe-card > header small { color: var(--dedupe-green); font: 800 11px Consolas, monospace; }
.media-dedupe-card > header h2 { margin: 5px 0 0; color: #fff; font-size: 17px; }
.media-dedupe-card > header > span { padding: 5px 7px; color: var(--dedupe-cyan); background: #102729; border: 1px solid #28545a; border-radius: 5px; font: 800 10px Consolas, monospace; }
.media-dedupe-controls, .media-dedupe-monitor, .media-dedupe-report { padding-bottom: 14px; }
.media-dedupe-controls > :not(header), .media-dedupe-monitor > :not(header), .media-dedupe-report > :not(header) { margin-left: 14px; margin-right: 14px; }
.media-dedupe-dropzone { display: grid; place-items: center; align-content: center; min-height: 112px; margin-top: 14px; color: #d8eee3; text-align: center; background: linear-gradient(135deg, #10251c, #0b1914); border: 1px dashed #3a6654; border-radius: 8px; cursor: pointer; }
.media-dedupe-dropzone input { display: none; }
.media-dedupe-dropzone svg { width: 25px; height: 25px; margin-bottom: 7px; color: var(--dedupe-green); }
.media-dedupe-dropzone strong { font-size: 14px; }
.media-dedupe-dropzone span { margin-top: 5px; color: var(--dedupe-muted); font-size: 11px; }
.media-dedupe-dropzone.is-dragging { border-color: var(--dedupe-green); box-shadow: inset 0 0 24px rgba(88, 229, 154, .1); }
.media-dedupe-mode { display: flex; justify-content: space-between; margin-top: 12px !important; color: var(--dedupe-muted); font-size: 12px; }
.media-dedupe-mode b { color: var(--dedupe-green); }
.media-dedupe-options { display: grid; gap: 7px; margin-top: 8px !important; }
.media-dedupe-options label { display: grid; grid-template-columns: 8px minmax(0, 1fr) 32px; gap: 9px; align-items: center; min-height: 58px; padding: 9px; background: #0d1b16; border: 1px solid #233e34; border-radius: 7px; }
.media-dedupe-options label > i { width: 7px; height: 7px; background: var(--dedupe-green); border-radius: 50%; box-shadow: 0 0 9px currentColor; }
.media-dedupe-options label > i.cyan { background: var(--dedupe-cyan); }
.media-dedupe-options label > i.amber { background: var(--dedupe-amber); }
.media-dedupe-options label > i.violet { background: var(--dedupe-violet); }
.media-dedupe-options b, .media-dedupe-options small { display: block; }
.media-dedupe-options b { color: #eff8f3; font-size: 12px; }
.media-dedupe-options small { margin-top: 4px; color: #789087; font-size: 10px; }
.media-dedupe-options input { appearance: none; width: 31px; height: 18px; margin: 0; background: #294037; border-radius: 9px; cursor: pointer; position: relative; }
.media-dedupe-options input::after { content: ""; position: absolute; top: 2px; left: 2px; width: 14px; height: 14px; background: #8ba097; border-radius: 50%; transition: transform 150ms ease; }
.media-dedupe-options input:checked { background: #2a7050; }
.media-dedupe-options input:checked::after { background: #c9f9dd; transform: translateX(13px); }
.media-dedupe-guard { display: flex; gap: 9px; align-items: center; margin-top: 9px !important; padding: 9px; color: #bff5d5; background: #10271e; border: 1px solid #2d5746; border-radius: 7px; }
.media-dedupe-guard svg { width: 18px; flex: 0 0 18px; }
.media-dedupe-guard b, .media-dedupe-guard small { display: block; }
.media-dedupe-guard b { font-size: 12px; }
.media-dedupe-guard small { margin-top: 3px; color: #85a294; font-size: 10px; }
.media-dedupe-run, .media-dedupe-clear { width: calc(100% - 28px); margin-top: 9px !important; }
.media-dedupe-run { color: #06130d !important; background: linear-gradient(90deg, #39bd78, #54e598) !important; border-color: transparent !important; box-shadow: 0 0 22px rgba(76, 224, 145, .18); }
.media-dedupe-summary { display: grid; grid-template-columns: auto 1fr auto; gap: 12px; align-items: center; margin-top: 14px !important; padding: 11px; background: #10221b; border: 1px solid #29473b; border-radius: 8px; }
.media-dedupe-summary > strong { color: var(--dedupe-green); font: 850 26px Consolas, monospace; }
.media-dedupe-summary > strong small { font-size: 11px; }
.media-dedupe-summary progress { width: 100%; height: 6px; appearance: none; }
.media-dedupe-summary progress::-webkit-progress-bar { background: #1d352b; border-radius: 4px; }
.media-dedupe-summary progress::-webkit-progress-value { background: linear-gradient(90deg, var(--dedupe-cyan), var(--dedupe-green)); border-radius: 4px; }
.media-dedupe-summary span { display: block; margin-top: 4px; color: var(--dedupe-muted); font-size: 11px; }
.media-dedupe-summary > b { color: var(--dedupe-cyan); font: 800 11px Consolas, monospace; }
.media-dedupe-queue { display: grid; gap: 7px; min-height: 166px; margin-top: 10px !important; }
.media-dedupe-queue .workspace-empty-state { color: var(--dedupe-muted); background: #0c1915; border-color: #213a31; }
.media-dedupe-task { display: grid; grid-template-columns: 42px minmax(0, 1fr) auto; gap: 10px; align-items: center; padding: 9px; background: #0c1915; border: 1px solid #213a31; border-radius: 7px; }
.media-dedupe-task-icon { display: grid; place-items: center; width: 42px; height: 38px; color: #061510; background: var(--dedupe-green); border-radius: 5px; font: 800 8px Consolas, monospace; }
.media-dedupe-task b, .media-dedupe-task small { display: block; }
.media-dedupe-task b { overflow: hidden; color: #eff8f3; font-size: 12px; text-overflow: ellipsis; white-space: nowrap; }
.media-dedupe-task small { margin-top: 4px; color: var(--dedupe-muted); font-size: 10px; }
.media-dedupe-task > strong { color: var(--dedupe-green); font: 800 11px Consolas, monospace; }
.media-dedupe-task button { padding: 6px 8px; color: #aef1ca; background: #173326; border: 1px solid #34644f; border-radius: 5px; cursor: pointer; }
.media-dedupe-task-progress { height: 4px; margin-top: 6px; overflow: hidden; background: #1d352b; border-radius: 3px; }
.media-dedupe-task-progress i { display: block; height: 100%; background: linear-gradient(90deg, var(--dedupe-cyan), var(--dedupe-green)); }
.media-dedupe-log-head { display: flex; justify-content: space-between; margin-top: 12px !important; color: var(--dedupe-cyan); font: 800 10px Consolas, monospace; }
.media-dedupe-log { height: 205px; margin-top: 7px !important; padding: 10px; overflow: hidden auto; color: #9bc0ae; background: #050b09; border: 1px solid #234037; border-radius: 8px; font: 10px/1.65 Consolas, monospace; scrollbar-width: thin; }
.media-dedupe-log.is-streaming { border-color: #2f8f68; box-shadow: inset 0 0 0 1px rgba(70, 210, 149, .12); }
.media-dedupe-log.is-streaming::after { content: "LIVE"; position: sticky; right: 0; bottom: 0; float: right; padding: 1px 5px; color: #7ff0b6; background: rgba(5, 11, 9, .88); border: 1px solid #2f8f68; border-radius: 3px; font: 800 7px/1.4 Consolas, monospace; animation: media-dedupe-live-pulse 1.1s ease-in-out infinite; }
.media-dedupe-log p { display: grid; grid-template-columns: 75px 1fr auto; gap: 7px; margin: 0; animation: media-dedupe-log-in 180ms ease both; }
.media-dedupe-log time { color: #5d8372; }
.media-dedupe-log b { color: var(--dedupe-green); }
@keyframes media-dedupe-log-in { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }
@keyframes media-dedupe-live-pulse { 50% { opacity: .45; } }
.media-dedupe-report > div { margin-top: 14px; }
.media-dedupe-report-empty { display: grid; place-items: center; min-height: 390px; padding: 25px; color: var(--dedupe-muted); text-align: center; border: 1px dashed #29473b; border-radius: 8px; }
.media-dedupe-report-empty svg { width: 34px; color: var(--dedupe-cyan); }
.media-dedupe-report-empty strong { margin-top: 12px; color: #eff8f3; }
.media-dedupe-report-empty span { margin-top: 5px; font-size: 11px; line-height: 1.7; }
.media-dedupe-quality { display: grid; grid-template-columns: 64px 1fr; gap: 11px; align-items: center; padding-bottom: 12px; border-bottom: 1px solid var(--dedupe-line); }
.media-dedupe-quality-score { display: grid; place-content: center; width: 62px; height: 62px; text-align: center; border: 5px solid #1f4b38; border-top-color: var(--dedupe-green); border-radius: 50%; }
.media-dedupe-quality-score b { color: var(--dedupe-green); font: 850 18px Consolas, monospace; }
.media-dedupe-quality-score small { color: var(--dedupe-muted); font: 700 7px Consolas, monospace; }
.media-dedupe-quality > div > b, .media-dedupe-quality > div > span { display: block; }
.media-dedupe-quality > div > b { color: #eff8f3; font-size: 13px; }
.media-dedupe-quality > div > span { margin-top: 4px; color: var(--dedupe-muted); font-size: 10px; }
.media-dedupe-risk { display: grid; grid-template-columns: 112px minmax(0, 1fr); gap: 12px; align-items: center; padding: 11px 12px; border: 1px solid currentColor; border-radius: 7px; background: #10231c; }
.media-dedupe-risk > div { display: grid; grid-template-columns: 1fr auto; align-items: end; gap: 2px 6px; }
.media-dedupe-risk > div small { grid-column: 1 / -1; color: var(--dedupe-muted); font-size: 10px; }
.media-dedupe-risk > div strong { color: currentColor; font: 850 20px Consolas, monospace; }
.media-dedupe-risk > div span { padding-bottom: 2px; font-size: 10px; font-weight: 800; }
.media-dedupe-risk p { display: grid; gap: 3px; margin: 0; min-width: 0; }
.media-dedupe-risk p b { overflow: hidden; color: #eff8f3; font-size: 12px; text-overflow: ellipsis; white-space: nowrap; }
.media-dedupe-risk p span, .media-dedupe-risk p small { color: var(--dedupe-muted); font-size: 10px; }
.media-dedupe-risk--high { color: #ff777d; border-color: #71373b; background: #28191b; }
.media-dedupe-risk--medium { color: #f3bc55; border-color: #66512d; background: #282319; }
.media-dedupe-risk--low { color: #64d89c; border-color: #315d48; background: #15271f; }
.media-dedupe-report-group { margin-top: 10px; overflow: hidden; border: 1px solid #213a31; border-radius: 7px; }
.media-dedupe-report-group header, .media-dedupe-report-group p { display: flex; justify-content: space-between; }
.media-dedupe-report-group header { padding: 8px; color: #eff8f3; background: #14261f; font-size: 11px; }
.media-dedupe-report-group header span { color: var(--dedupe-green); }
.media-dedupe-report-group p { margin: 0; padding: 8px 9px; border-top: 1px solid #1d342a; font-size: 10px; }
.media-dedupe-report-group p span { color: var(--dedupe-muted); }
.media-dedupe-report-group p b { color: #eff8f3; font-family: Consolas, monospace; }
.media-dedupe-hash { margin-top: 10px; padding: 9px; background: #0b1713; border: 1px solid #28473a; border-radius: 7px; }
.media-dedupe-hash small, .media-dedupe-hash b { display: block; }
.media-dedupe-hash small { color: var(--dedupe-muted); font: 9px Consolas, monospace; }
.media-dedupe-hash b { margin-top: 4px; overflow-wrap: anywhere; color: var(--dedupe-cyan); font: 9px Consolas, monospace; }
.media-dedupe-download { width: 100%; margin-top: 10px; color: #06130d !important; background: var(--dedupe-cyan) !important; border-color: transparent !important; }
.media-dedupe-disclaimer { margin: 12px 0 0; padding: 10px 13px; color: #789086; background: #0b1713; border: 1px solid #203a30; border-radius: 8px; font-size: 10px; text-align: center; }
.media-dedupe-summary-metrics { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); margin: -8px 0 14px; overflow: hidden; background: #fff; border: 1px solid var(--ws-line); border-radius: 8px; }
.media-dedupe-summary-metrics > span { min-width: 0; padding: 10px 13px; border-right: 1px solid var(--ws-line); }
.media-dedupe-summary-metrics > span:last-child { border-right: 0; }
.media-dedupe-summary-metrics small, .media-dedupe-summary-metrics b { display: block; }
.media-dedupe-summary-metrics small { color: #76817c; font-size: 10px; }
.media-dedupe-summary-metrics b { margin-top: 4px; overflow: hidden; color: #164a3a; font: 850 15px Consolas, monospace; text-overflow: ellipsis; white-space: nowrap; }
.media-dedupe-presets { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; margin-top: 8px !important; }
.media-dedupe-presets button { min-width: 0; min-height: 66px; padding: 8px 5px; color: #5e6964; background: #f7f9f8; border: 1px solid #dce4e0; border-radius: 7px; cursor: pointer; }
.media-dedupe-presets button svg { width: 15px; height: 15px; }
.media-dedupe-presets button b, .media-dedupe-presets button small { display: block; }
.media-dedupe-presets button b { margin-top: 4px; color: #26342e; font-size: 11px; }
.media-dedupe-presets button small { margin-top: 2px; overflow: hidden; font-size: 9px; text-overflow: ellipsis; white-space: nowrap; }
.media-dedupe-presets button.is-active { color: #176447; background: #eaf7f0; border-color: #67ad8d; box-shadow: inset 0 0 0 1px #b8dfce; }
.media-dedupe-options label.is-required { background: #f3f7f5; }
.media-dedupe-options input:disabled { cursor: not-allowed; opacity: .72; }
.media-dedupe-pipeline { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 6px; margin: 10px 14px 0; padding: 0; list-style: none; }
.media-dedupe-pipeline li { position: relative; min-width: 0; min-height: 52px; padding: 7px 5px; color: #7b8681; text-align: center; background: #f6f8f7; border: 1px solid #e0e6e3; border-radius: 6px; }
.media-dedupe-pipeline li i, .media-dedupe-pipeline li span { display: block; }
.media-dedupe-pipeline li i { width: 20px; height: 20px; margin: 0 auto 4px; color: #718079; font: 800 7px/20px Consolas, monospace; background: #e3e9e6; border-radius: 50%; }
.media-dedupe-pipeline li span { overflow: hidden; font-size: 9px; font-weight: 800; text-overflow: ellipsis; white-space: nowrap; }
.media-dedupe-pipeline li.is-done { color: #25714f; background: #edf8f2; border-color: #b8ddca; }
.media-dedupe-pipeline li.is-done i { color: #fff; background: #31825d; }
.media-dedupe-pipeline li.is-active { color: #1e6047; background: #def3e8; border-color: #58a984; box-shadow: 0 0 0 2px rgba(72, 157, 115, .12); }
.media-dedupe-pipeline li.is-active i { color: #fff; background: #2b7956; animation: media-dedupe-stage-pulse 1.2s ease-in-out infinite; }
.media-dedupe-pipeline li.is-skipped { opacity: .48; text-decoration: line-through; }
@keyframes media-dedupe-stage-pulse { 50% { transform: scale(.86); box-shadow: 0 0 0 5px rgba(49,130,93,.13); } }
.media-dedupe-task-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 4px; }
.media-dedupe-task-actions button.is-danger { color: #a43d46; background: #fff2f2; border-color: #efc5c7; }
.media-dedupe-task.is-cancelled { opacity: .72; }
.media-dedupe-task.is-failed { border-color: #efc5c7; background: #fff8f8; }
.media-dedupe-compare { display: grid; grid-template-columns: minmax(0, 1fr) 18px minmax(0, 1fr); gap: 6px; align-items: center; margin-top: 14px !important; }
.media-dedupe-compare > span { min-width: 0; padding: 9px; background: #f5f8f6; border: 1px solid #dfe7e3; border-radius: 7px; }
.media-dedupe-compare small, .media-dedupe-compare b { display: block; }
.media-dedupe-compare small { color: #7b8781; font-size: 9px; }
.media-dedupe-compare b { margin-top: 4px; overflow: hidden; color: #25332d; font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.media-dedupe-compare > svg { width: 15px; color: #388261; }
.media-dedupe-executed { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 10px; }
.media-dedupe-executed span { padding: 4px 6px; color: #25684a; background: #e9f5ee; border: 1px solid #c6e2d2; border-radius: 4px; font-size: 9px; font-weight: 800; }
.media-dedupe-history { margin-top: 12px; overflow: hidden; background: #fff; border: 1px solid var(--ws-line); border-radius: 8px; }
.media-dedupe-history > header { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 64px; padding: 11px 14px; border-bottom: 1px solid var(--ws-line); }
.media-dedupe-history > header small { color: #2d8060; font: 800 9px Consolas, monospace; }
.media-dedupe-history > header h2 { margin: 4px 0 0; color: #17202a; font-size: 16px; }
.media-dedupe-history > header > div:last-child { display: flex; flex-wrap: wrap; gap: 5px; }
.media-dedupe-history > header button { min-height: 30px; padding: 0 9px; color: #65716b; background: #fff; border: 1px solid #dce3df; border-radius: 5px; cursor: pointer; font-size: 10px; }
.media-dedupe-history > header button.is-active { color: #fff; background: #286f51; border-color: #286f51; }
.media-dedupe-history-list { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; padding: 12px; }
.media-dedupe-history-list > p { grid-column: 1 / -1; margin: 0; padding: 25px; color: #77827d; text-align: center; }
.media-dedupe-history-item { min-width: 0; padding: 10px; background: #f7f9f8; border: 1px solid #e0e6e3; border-radius: 7px; }
.media-dedupe-history-item > header { display: flex; align-items: center; justify-content: space-between; gap: 6px; }
.media-dedupe-history-item strong { overflow: hidden; color: #25322c; font-size: 12px; text-overflow: ellipsis; white-space: nowrap; }
.media-dedupe-history-item em { flex: 0 0 auto; color: #2c7656; font-size: 10px; font-style: normal; font-weight: 800; }
.media-dedupe-history-risk { flex: 0 0 auto; padding: 2px 5px; border: 1px solid currentColor; border-radius: 4px; font-size: 9px; font-weight: 800; }
.media-dedupe-history-risk--high { color: #b53f47; background: #fff1f2; }
.media-dedupe-history-risk--medium { color: #9b6718; background: #fff8e7; }
.media-dedupe-history-risk--low { color: #287653; background: #edf9f3; }
.media-dedupe-history-item small { display: block; margin-top: 7px; color: #75817b; font-size: 10px; }
.media-dedupe-history-item footer { display: flex; justify-content: space-between; gap: 6px; margin-top: 8px; color: #66736d; font: 10px Consolas, monospace; }
.media-dedupe-history-item button { padding: 3px 6px; color: #9d3d43; background: #fff; border: 1px solid #e7c8ca; border-radius: 4px; cursor: pointer; font-size: 9px; }

/* Match the local media engine to the light workspace tool surfaces. */
.media-dedupe-view.media-dedupe-view {
  --dedupe-panel: #fff;
  --dedupe-line: #dfe4e8;
  --dedupe-text: #17202a;
  --dedupe-muted: #66717e;
  --dedupe-green: #2f8a64;
  --dedupe-cyan: #397f9d;
  --dedupe-amber: #b87522;
  --dedupe-violet: #7357a7;
  color: var(--ws-text);
  background: #f4f6fa;
}
.media-dedupe-view .media-dedupe-heading h1,
.media-dedupe-view .media-dedupe-card > header h2,
.media-dedupe-view .media-dedupe-options b,
.media-dedupe-view .media-dedupe-task b,
.media-dedupe-view .media-dedupe-report-empty strong,
.media-dedupe-view .media-dedupe-quality > div > b {
  color: var(--ws-text);
}
.media-dedupe-view .media-dedupe-heading p { color: var(--ws-primary); }
.media-dedupe-view .media-dedupe-card {
  background: #fff;
  border-color: var(--ws-line);
  box-shadow: var(--ws-shadow);
}
.media-dedupe-view .media-dedupe-card > header { background: #fbfcfd; }
.media-dedupe-view .media-dedupe-card > header > span {
  color: #27677f;
  background: #eaf5f8;
  border-color: #bddbe4;
}
.media-dedupe-view .media-dedupe-engine-state {
  background: #edf7f2;
  border-color: #badbc9;
}
.media-dedupe-view .media-dedupe-engine-state b,
.media-dedupe-view .media-dedupe-guard { color: #236848; }
.media-dedupe-view .media-dedupe-dropzone {
  color: var(--ws-text);
  background: #f8faf9;
  border-color: #b8c8c1;
}
.media-dedupe-view .media-dedupe-options label,
.media-dedupe-view .media-dedupe-summary,
.media-dedupe-view .media-dedupe-task,
.media-dedupe-view .media-dedupe-queue .workspace-empty-state {
  background: #f7f9fa;
  border-color: var(--ws-line);
}
.media-dedupe-view .media-dedupe-guard {
  background: #edf7f2;
  border-color: #badbc9;
}
.media-dedupe-view .media-dedupe-log {
  color: #36564a;
  background: #f7f8fc;
  border-color: var(--ws-line);
}
.media-dedupe-view .media-dedupe-log time { color: #728179; }
.media-dedupe-view .media-dedupe-report-empty,
.media-dedupe-view .media-dedupe-report-group { border-color: var(--ws-line); }
.media-dedupe-view .media-dedupe-report-group header {
  color: var(--ws-text);
  background: #f2f5f4;
}
.media-dedupe-view .media-dedupe-report-group p { border-color: var(--ws-line); }
.media-dedupe-view .media-dedupe-disclaimer {
  color: var(--ws-muted);
  background: #fff;
  border-color: var(--ws-line);
}
.workspace-list-row b { flex: 0 0 auto; color: var(--ws-primary); font-size: 12px; }

.workspace-recent-activity-surface .workspace-section-head > small { color: #68758a; font-size: 12px; font-weight: 700; }
.workspace-recent-activity-filters { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 8px; margin: 14px 0 12px; }
.workspace-recent-activity-filters button { min-width: 0; height: 38px; padding: 0 10px; color: #48556a; background: #f5f7fb; border: 1px solid #e1e6ef; border-radius: 7px; font-size: 13px; font-weight: 800; cursor: pointer; }
.workspace-recent-activity-filters button.is-active { color: #fff; background: #e85c3f; border-color: #e85c3f; box-shadow: 0 5px 12px rgba(220, 77, 48, 0.18); }
.workspace-recent-activity-row b { color: #344156; background: #f2f5f9; border-radius: 999px; padding: 5px 9px; font-size: 12px; }
.workspace-recent-activity-pager { display: flex; align-items: center; justify-content: flex-end; gap: 8px; padding: 12px 14px; border-top: 1px solid var(--ws-line); color: #68758a; font-size: 12px; }
.workspace-recent-activity-pager span { margin-right: auto; }
.workspace-recent-activity-pager button { height: 32px; padding: 0 12px; color: #263248; background: #fff; border: 1px solid #dce2eb; border-radius: 6px; font-weight: 800; cursor: pointer; }
.workspace-recent-activity-pager button:disabled { opacity: 0.42; cursor: not-allowed; }

.workspace-customer-service-layout { display: grid; grid-template-columns: minmax(0, 1.7fr) minmax(250px, .65fr); gap: 14px; }
.workspace-customer-support-page { position: fixed; z-index: 18; inset: 58px 0 60px var(--aurora-sidebar-width, var(--ws-sidebar-width)); padding: 20px 28px 28px; overflow-y: auto; background: var(--ws-bg); }
.workspace-customer-support-page.is-active { display: block; }
.workspace-customer-support-shell { display: grid; gap: 14px; width: min(1180px, 100%); min-height: 100%; margin: 0 auto; padding: 18px; border: 1px solid #cfd8d4; border-radius: 8px; background: #edf2f0; box-shadow: 0 18px 48px rgba(8, 18, 15, .12); }
.workspace-customer-support-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 2px 2px 0; }
.workspace-customer-support-head p { margin: 0 0 3px; color: #16805b; font-size: 10px; font-weight: 900; }
.workspace-customer-support-head h1 { margin: 0; color: #17231f; font-size: 21px; }
.workspace-customer-support-head span { display: block; margin-top: 4px; color: #68766f; font-size: 12px; }
.workspace-customer-support-tabs { display: flex; gap: 6px; padding: 8px 10px; border: 1px solid var(--ws-line); border-radius: 8px; background: #f6f8f8; }
.workspace-customer-support-tabs button { min-width: 112px; padding: 9px 16px; color: #62706d; background: transparent; border: 0; border-radius: 6px; font-size: 12px; font-weight: 800; cursor: pointer; }
.workspace-customer-support-tabs button.is-active { color: #fff; background: #182f2a; box-shadow: 0 5px 14px rgba(24,47,42,.16); }
.workspace-customer-preview { position: relative; min-height: clamp(560px, calc(100vh - 210px), 760px); overflow: hidden; background: #e9edee; border: 1px solid var(--ws-line); border-radius: 8px; box-shadow: var(--ws-shadow); }
.workspace-customer-preview iframe { display: block; width: 100%; height: clamp(560px, calc(100vh - 210px), 760px); border: 0; background: #fff; }
.workspace-shop-control-preview { position: relative; min-height: clamp(620px, calc(100vh - 210px), 860px); overflow: hidden; background: #f4f2fb; border: 1px solid var(--ws-line); border-radius: 8px; box-shadow: var(--ws-shadow); }
.workspace-shop-control-preview iframe { display: block; width: 100%; height: clamp(620px, calc(100vh - 210px), 860px); border: 0; background: #fff; }
.workspace-customer-chat-panel, .workspace-customer-demo-side { border: 1px solid var(--ws-line); border-radius: 8px; background: #fff; }
.workspace-customer-chat-panel { overflow: hidden; }
.workspace-customer-chat-panel > header { display: flex; min-height: 72px; align-items: center; justify-content: space-between; gap: 14px; padding: 13px 16px; border-bottom: 1px solid var(--ws-line); background: #f8fafc; }
.workspace-customer-chat-panel > header > div { display: flex; align-items: center; gap: 11px; }
.workspace-customer-chat-panel > header strong, .workspace-customer-chat-panel > header small { display: block; }
.workspace-customer-chat-panel > header strong { font-size: 14px; }
.workspace-customer-chat-panel > header small { margin-top: 4px; color: var(--ws-muted); font-size: 10px; }
.workspace-customer-avatar { display: grid; width: 38px; height: 38px; place-items: center; color: #fff; background: #111318; border-radius: 8px; font-size: 13px; font-weight: 900; }
.workspace-customer-messages { height: min(52vh, 480px); min-height: 330px; overflow-y: auto; padding: 18px; background: #f5f7fa; }
.workspace-customer-message { display: flex; align-items: flex-end; gap: 8px; margin-bottom: 14px; }
.workspace-customer-message.is-user { justify-content: flex-end; }
.workspace-customer-message > div { max-width: min(74%, 620px); padding: 11px 13px; border: 1px solid #dfe5ed; border-radius: 8px 8px 8px 2px; color: #293548; background: #fff; }
.workspace-customer-message.is-user > div { color: #fff; background: #111318; border-color: #111318; border-radius: 8px 8px 2px 8px; }
.workspace-customer-message p { margin: 0; white-space: pre-wrap; font-size: 12px; line-height: 1.65; }
.workspace-customer-message strong { display: block; margin-bottom: 5px; font-size: 12px; }
.workspace-customer-message small { display: block; margin-top: 7px; opacity: .74; font-size: 10px; }
.workspace-customer-message a { display: inline-flex; margin-top: 8px; color: #d94f31; font-size: 11px; font-weight: 800; }
.workspace-customer-message time { flex: 0 0 auto; color: #98a1af; font-size: 9px; }
.workspace-customer-attachment-preview { display: flex; align-items: center; gap: 10px; margin: 10px 14px 0; padding: 8px 10px; border: 1px solid #dfe5ed; border-radius: 7px; background: #f8fafc; }
.workspace-customer-attachment-preview img { width: 42px; height: 42px; object-fit: cover; border-radius: 5px; }
.workspace-customer-attachment-preview div { min-width: 0; flex: 1; }
.workspace-customer-attachment-preview strong, .workspace-customer-attachment-preview small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.workspace-customer-attachment-preview strong { font-size: 11px; }.workspace-customer-attachment-preview small { margin-top: 3px; color: var(--ws-muted); font-size: 9px; }
.workspace-customer-attachment-preview button { border: 0; color: #7d8795; background: transparent; font-size: 18px; cursor: pointer; }
.workspace-customer-composer { padding: 12px 14px 14px; border-top: 1px solid var(--ws-line); }
.workspace-customer-composer textarea { width: 100%; resize: none; border: 0; outline: 0; color: var(--ws-text); background: transparent; font: inherit; font-size: 12px; line-height: 1.55; }
.workspace-customer-composer > div { display: flex; align-items: center; gap: 7px; margin-top: 8px; }
.workspace-customer-composer > div > span { margin-right: auto; color: var(--ws-muted); font-size: 9px; }
.workspace-customer-tool { display: grid; width: 33px; height: 33px; place-items: center; color: #536174; background: #f2f4f7; border: 1px solid #e0e5ec; border-radius: 6px; cursor: pointer; }
button.workspace-customer-tool { padding: 0; }.workspace-customer-tool svg { width: 15px; height: 15px; }
.workspace-customer-demo-side { display: grid; align-content: start; gap: 12px; padding: 14px; }
.workspace-customer-demo-side section { padding: 13px; border: 1px solid #e2e6ed; border-radius: 7px; background: #f8fafc; }
.workspace-customer-demo-side span, .workspace-customer-demo-side strong { display: block; }
.workspace-customer-demo-side span { color: #758094; font-size: 9px; font-weight: 900; }.workspace-customer-demo-side strong { margin-top: 5px; font-size: 13px; }
.workspace-customer-demo-side p { margin: 7px 0 0; color: #68758a; font-size: 10px; line-height: 1.6; }
.workspace-customer-demo-side section button { width: 100%; margin-top: 7px; padding: 8px 9px; color: #344156; background: #fff; border: 1px solid #e0e5ec; border-radius: 6px; text-align: left; font-size: 10px; cursor: pointer; }
.workspace-customer-suggestion-panel { display: grid; grid-template-columns: minmax(230px, .7fr) minmax(0, 1.3fr); gap: 22px; padding: 24px; border: 1px solid var(--ws-line); border-radius: 8px; background: #fff; }
.workspace-customer-suggestion-panel[hidden] { display: none; }
.workspace-customer-suggestion-intro { padding: 20px; color: #eaf5f1; background: #18342d; border-radius: 8px; }
.workspace-customer-suggestion-intro small { color: #8ed9bf; font-size: 10px; font-weight: 900; }
.workspace-customer-suggestion-intro h3 { margin: 10px 0 8px; font-size: 20px; }
.workspace-customer-suggestion-intro p { margin: 0; color: #c6d8d2; font-size: 12px; line-height: 1.75; }
.workspace-customer-suggestion-panel form { display: grid; gap: 13px; }
.workspace-customer-suggestion-panel label { position: relative; display: grid; gap: 6px; }
.workspace-customer-suggestion-panel label > span { color: #273630; font-size: 11px; font-weight: 850; }
.workspace-customer-suggestion-panel input, .workspace-customer-suggestion-panel textarea { width: 100%; padding: 11px 12px; color: var(--ws-text); background: #f8faf9; border: 1px solid #dce5e1; border-radius: 7px; outline: 0; font: inherit; font-size: 12px; line-height: 1.6; }
.workspace-customer-suggestion-panel input:focus, .workspace-customer-suggestion-panel textarea:focus { border-color: #568d7e; box-shadow: 0 0 0 3px rgba(86,141,126,.12); }
.workspace-customer-suggestion-panel textarea { resize: vertical; min-height: 138px; }
.workspace-customer-suggestion-panel label > small { position: absolute; right: 10px; bottom: 8px; color: #87948f; font-size: 9px; }
.workspace-customer-suggestion-actions { display: flex; align-items: center; justify-content: flex-end; gap: 12px; }
.workspace-customer-suggestion-actions p { margin: 0 auto 0 0; color: #28765f; font-size: 11px; font-weight: 750; }
.workspace-customer-suggestion-actions p.is-error { color: #c53c2d; }

@media (max-width: 760px) {
  .workspace-customer-support-page { left: 0; padding: 14px; }
  .workspace-recent-activity-filters { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .workspace-recent-activity-filters button:last-child { grid-column: 1 / -1; }
  .workspace-recent-activity-surface .workspace-section-head > small { display: none; }
  .workspace-customer-service-layout { grid-template-columns: 1fr; }
  .workspace-customer-suggestion-panel { grid-template-columns: 1fr; padding: 16px; }
  .workspace-customer-messages { min-height: 300px; }
  .workspace-customer-message > div { max-width: 86%; }
  .workspace-customer-composer > div > span { display: none; }
}
.workspace-empty-state { margin: 0; padding: 24px; color: var(--ws-muted); text-align: center; }
.workspace-page-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; min-height: 76px; margin-bottom: 22px; }
.workspace-page-heading p, .workspace-section-head p { margin: 0 0 7px; color: var(--ws-primary); font-size: 10px; font-weight: 800; }
.workspace-page-heading h1 { margin: 0; font-size: 27px; line-height: 1.22; letter-spacing: 0; }
.workspace-page-heading > div > span { display: block; margin-top: 7px; color: var(--ws-muted); }
.workspace-heading-actions { display: flex; gap: 8px; }
.workspace-button { display: inline-flex; align-items: center; justify-content: center; gap: 7px; min-height: 38px; padding: 8px 14px; border: 1px solid transparent; border-radius: 6px; font-weight: 700; cursor: pointer; }
.workspace-button svg { width: 16px; height: 16px; }
.workspace-button.primary { color: #fff; background: var(--ws-primary); border-color: var(--ws-primary); }
.workspace-button.primary:hover { background: var(--ws-primary-strong); }
.workspace-button.secondary { color: var(--ws-text); background: #fff; border-color: var(--ws-line); }
.workspace-button.secondary:hover { border-color: #a5b8b1; }

.generation-capacity-values {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 8px;
  font-size: 20px;
  line-height: 1.2;
}

.generation-capacity-values .capacity-image,
.generation-capacity-values .capacity-video {
  margin: 0;
  font: inherit;
  font-weight: 800;
}

.capacity-image { color: #d92d20; }
.capacity-video { color: #17202a; }
.workspace-button.full { width: 100%; }
.workspace-button:disabled { opacity: .55; cursor: wait; }

.workspace-metrics { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.workspace-metrics article { display: flex; align-items: center; gap: 13px; min-height: 112px; padding: 18px; background: var(--ws-surface); border: 1px solid var(--ws-line); border-radius: 7px; }
.workspace-metrics article div { min-width: 0; }
.workspace-metrics small, .workspace-metrics strong, .workspace-metrics em { display: block; }
.workspace-metrics small { color: var(--ws-muted); font-size: 12px; }
.workspace-metrics strong { margin: 5px 0 2px; font-size: 25px; line-height: 1; }
.workspace-metrics em { color: #89939d; font-size: 10px; font-style: normal; }
.metric-icon, .tool-icon { display: grid; place-items: center; flex: 0 0 auto; border-radius: 6px; }
.metric-icon { width: 42px; height: 42px; }
.metric-icon svg, .tool-icon svg { width: 20px; }
.coral { color: #b84631; background: #fff0ec; }
.amber { color: #9b6a12; background: #fff6db; }
.green { color: #1c6b51; background: #e7f5ef; }
.blue { color: #32649b; background: #eaf2fb; }
.violet { color: #70518d; background: #f2edf8; }
.slate { color: #4f5d69; background: #edf0f2; }

.workspace-section { margin-top: 28px; }
.workspace-section-head { display: flex; align-items: flex-end; justify-content: space-between; margin-bottom: 13px; }
.workspace-section-head h2 { margin: 0; font-size: 18px; }
.workspace-tool-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.workspace-tool-grid > a { display: flex; align-items: center; gap: 12px; min-height: 84px; padding: 14px; background: #fff; border: 1px solid var(--ws-line); border-radius: 7px; transition: border-color 150ms ease, transform 150ms ease, box-shadow 150ms ease; }
.workspace-tool-grid > a:hover { border-color: #aabbb5; transform: translateY(-1px); box-shadow: var(--ws-shadow); }
.workspace-tool-grid > a > div { min-width: 0; flex: 1; }
.workspace-tool-grid strong, .workspace-tool-grid small { display: block; }
.workspace-tool-grid strong { font-size: 13px; }
.workspace-tool-grid small { margin-top: 5px; color: var(--ws-muted); font-size: 11px; }
.workspace-tool-grid > a > svg { width: 15px; color: #8c969f; }
.tool-icon { width: 40px; height: 40px; }
.workspace-workflow { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); margin: 0; padding: 0; list-style: none; background: #fff; border: 1px solid var(--ws-line); border-radius: 7px; overflow: hidden; }
.workspace-workflow li { position: relative; display: flex; align-items: center; gap: 10px; min-height: 68px; padding: 14px 18px; border-right: 1px solid var(--ws-line); }
.workspace-workflow li:last-child { border-right: 0; }
.workspace-workflow li:not(:last-child)::after { content: ""; position: absolute; right: -4px; z-index: 1; width: 7px; height: 7px; background: #fff; border-top: 1px solid var(--ws-line); border-right: 1px solid var(--ws-line); transform: rotate(45deg); }
.workspace-workflow span { color: #9aa3ab; font-size: 10px; font-weight: 800; }
.workspace-workflow strong { font-size: 12px; }

.workspace-form-surface, .workspace-output, .workspace-balance-hero, .workspace-link-panel, .competitor-results { background: #fff; border: 1px solid var(--ws-line); border-radius: 7px; }
.workspace-form-surface { padding: 22px; }
.workspace-account-row { display: flex; align-items: center; gap: 13px; }
.workspace-account-row > div { flex: 1; }
.workspace-account-row strong, .workspace-account-row small { display: block; }
.workspace-account-row small { margin-top: 4px; color: var(--ws-muted); }
.workspace-status { display: inline-flex; align-items: center; min-height: 28px; padding: 4px 9px; border-radius: 5px; font-size: 11px; font-weight: 700; }
.workspace-status.ready { color: #145a45; background: #e5f3ed; }
.workspace-balance-hero { display: flex; align-items: center; justify-content: space-between; min-height: 150px; padding: 26px; color: #fff; background: #173b31; border-color: #173b31; }
.workspace-balance-hero small, .workspace-balance-hero strong, .workspace-balance-hero p { display: block; }
.workspace-balance-hero small { color: #a9c9be; }
.workspace-balance-hero strong { margin-top: 8px; font-size: 30px; }
.workspace-balance-hero p { margin: 7px 0 0; color: #bcd0c9; font-size: 11px; }
.workspace-balance-hero .workspace-button { color: var(--ws-primary); background: #fff; }
.workspace-price-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; margin-top: 12px; }
.workspace-price-grid span { display: flex; align-items: center; gap: 8px; min-height: 54px; padding: 12px 14px; color: var(--ws-muted); background: #fff; border: 1px solid var(--ws-line); border-radius: 7px; }
.workspace-price-grid strong { color: var(--ws-text); font-size: 15px; }
.workspace-check-in-hero { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(300px, .85fr); min-height: 370px; color: #fff; background: #123e32; border: 1px solid #123e32; border-radius: 8px; overflow: hidden; }
.workspace-check-in-copy { display: flex; align-items: flex-start; flex-direction: column; justify-content: center; min-width: 0; padding: 40px 44px; }
.workspace-check-in-status { display: inline-flex; align-items: center; gap: 7px; min-height: 30px; padding: 5px 9px; color: #d7f4e3; background: #205947; border: 1px solid #3a715f; border-radius: 5px; font-size: 11px; font-weight: 800; }
.workspace-check-in-status svg { width: 15px; height: 15px; }
.workspace-check-in-copy h2 { margin: 22px 0 0; font-size: 30px; line-height: 1.25; }
.workspace-check-in-copy > p { max-width: 620px; margin: 12px 0 0; color: #b9d2c9; line-height: 1.75; }
.workspace-check-in-stats { display: flex; width: 100%; margin: 26px 0 24px; padding: 17px 0; border-top: 1px solid #326052; border-bottom: 1px solid #326052; }
.workspace-check-in-stats > span { min-width: 0; padding: 0 24px; border-right: 1px solid #326052; }
.workspace-check-in-stats > span:first-child { padding-left: 0; }
.workspace-check-in-stats > span:last-child { border-right: 0; }
.workspace-check-in-stats small, .workspace-check-in-stats strong { display: block; }
.workspace-check-in-stats small { color: #8eb2a6; font-size: 10px; }
.workspace-check-in-stats strong { margin-top: 5px; font-size: 15px; }
.workspace-check-in-stats b { font-size: 23px; font-weight: 850; }
.workspace-button.check-in-action { min-width: 210px; min-height: 44px; color: #2d291c; background: #f2c864; border-color: #f2c864; }
.workspace-button.check-in-action:hover { background: #ffda7a; border-color: #ffda7a; }
.workspace-button.check-in-action:disabled { color: #d9efe4; background: #2d6955; border-color: #4b7e6d; cursor: default; opacity: 1; }
.workspace-check-in-scene { position: relative; display: grid; place-items: end center; min-width: 0; background: #f0be59; border-left: 1px solid rgba(17, 61, 48, .18); overflow: hidden; }
.workspace-check-in-hero.is-checked .workspace-check-in-scene { background: #a7d6b4; }
.workspace-check-in-scene img { position: relative; z-index: 2; width: min(260px, 84%); height: auto; margin-bottom: -16px; filter: drop-shadow(0 18px 18px rgba(64, 45, 20, .18)); animation: giraffe-breathe 3.6s ease-in-out infinite; }
.workspace-check-in-reward { position: absolute; top: 24px; right: 24px; z-index: 3; display: grid; grid-template-columns: auto auto; align-items: center; gap: 0 6px; min-width: 104px; padding: 10px 12px; color: #144b37; background: rgba(255, 255, 255, .9); border: 1px solid rgba(20, 75, 55, .16); border-radius: 7px; box-shadow: 0 10px 24px rgba(85, 55, 14, .14); }
.workspace-check-in-reward svg { grid-row: 1 / 3; width: 21px; height: 21px; }
.workspace-check-in-reward strong { font-size: 18px; line-height: 1; }
.workspace-check-in-reward small { font-size: 9px; }
.check-in-leaf { position: absolute; z-index: 1; width: 26px; height: 15px; background: #2f7d54; border-radius: 100% 0 100% 0; opacity: .8; animation: leaf-drift 4.8s ease-in-out infinite; }
.leaf-one { top: 24%; left: 12%; transform: rotate(22deg); }
.leaf-two { top: 44%; right: 10%; width: 20px; height: 12px; animation-delay: -1.4s; }
.leaf-three { top: 15%; left: 44%; width: 18px; height: 11px; background: #4b976c; animation-delay: -2.8s; }
.workspace-check-in-scene.is-celebrating .check-in-leaf { animation: leaf-celebrate 900ms ease-out both; }
.workspace-check-in-scene.is-celebrating .workspace-check-in-reward { animation: reward-pop 620ms ease-out both; }
.workspace-check-in-week { margin-top: 26px; }
.workspace-check-in-week .workspace-section-head > span { color: var(--ws-muted); font-size: 11px; }
.workspace-check-in-days { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 9px; }
.workspace-check-in-days article { display: grid; place-items: center; gap: 7px; min-width: 0; min-height: 112px; padding: 12px 8px; background: #fff; border: 1px solid var(--ws-line); border-radius: 7px; }
.workspace-check-in-days article.is-today { border-color: #789d8e; box-shadow: inset 0 -3px 0 #2d7255; }
.workspace-check-in-days article.is-checked { color: #18533d; background: #eaf5ed; border-color: #b9d9c3; }
.workspace-check-in-days small { color: var(--ws-muted); font-size: 10px; }
.workspace-check-in-days span { display: grid; place-items: center; width: 32px; height: 32px; color: #9aa5a0; background: #f0f2f2; border-radius: 50%; }
.workspace-check-in-days .is-checked span { color: #fff; background: #2f7957; }
.workspace-check-in-days svg { width: 16px; height: 16px; }
.workspace-check-in-days strong { font-size: 11px; }
@keyframes giraffe-breathe { 0%, 100% { transform: translateY(0) rotate(-.4deg); } 50% { transform: translateY(-6px) rotate(.4deg); } }
@keyframes leaf-drift { 0%, 100% { transform: translate3d(0, 0, 0) rotate(18deg); } 50% { transform: translate3d(9px, -13px, 0) rotate(46deg); } }
@keyframes leaf-celebrate { 0% { opacity: 0; transform: translate3d(0, -30px, 0) rotate(0); } 70% { opacity: 1; } 100% { opacity: .85; transform: translate3d(18px, 70px, 0) rotate(190deg); } }
@keyframes reward-pop { 0% { opacity: 0; transform: scale(.72); } 65% { opacity: 1; transform: scale(1.08); } 100% { transform: scale(1); } }
.workspace-link-panel { display: flex; align-items: center; gap: 16px; min-height: 88px; margin-bottom: 10px; padding: 16px 18px; }
.workspace-link-panel > svg { width: 23px; color: var(--ws-primary); }
.workspace-link-panel > div { flex: 1; }
.workspace-link-panel strong, .workspace-link-panel span { display: block; }
.workspace-link-panel span { margin-top: 5px; color: var(--ws-muted); }
.workspace-link-panel a { color: var(--ws-primary); font-weight: 800; }
.workspace-embedded-tool-view .workspace-page-heading { margin-bottom: 14px; }
.workspace-embedded-tool { min-height: 520px; }
.workspace-tool-load-state { display: grid; place-items: center; align-content: center; gap: 9px; min-height: 420px; padding: 28px; color: var(--ws-muted); text-align: center; background: #fff; border: 1px solid var(--ws-line); border-radius: 7px; }
.workspace-tool-load-state strong { color: var(--ws-text); font-size: 15px; }
.workspace-tool-load-state.is-error { color: #8b3329; background: #fff6f4; border-color: #edc6c0; }
.workspace-tool-load-state .workspace-button { margin-top: 8px; }
.workspace-tool-loader { width: 28px; height: 28px; border: 3px solid #dce7e2; border-top-color: var(--ws-primary); border-radius: 50%; animation: ws-spin 760ms linear infinite; }
.workspace-embedded-workbench { gap: 14px; }
.workspace-embedded-workbench.video-workbench-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: start; padding-left: 0; }
.workspace-embedded-workbench > .panel { padding: 20px; box-shadow: none; }
.workspace-embedded-workbench .image-workbench-panel,
.workspace-embedded-workbench .video-form-panel { border-color: #d9e1e4; }
.workspace-embedded-workbench .section-head { margin-bottom: 16px; }
.workspace-embedded-workbench .section-head h1,
.workspace-embedded-workbench .section-head h2 { letter-spacing: 0; }
.workspace-embedded-workbench #memberPanel,
.workspace-embedded-workbench #memberCreditsPanel,
.workspace-embedded-workbench #memberPackageBox,
.workspace-embedded-workbench #videoMemberCredits,
.workspace-embedded-workbench #videoPackageBox { display: none !important; }
body.workspace-page[data-embedded-tool] > [data-workspace-tool-portal] { z-index: 100; }

/* Preserve the light workspace palette while reusing the video's compact controls. */
.workspace-embedded-workbench[data-embedded-tool="video"] .video-option-field,
.workspace-embedded-workbench[data-embedded-tool="video"] .production-direction-field { min-width: 0; margin: 0; }
.workspace-embedded-workbench[data-embedded-tool="video"] .video-option-field { padding: 0; border: 0; }
.workspace-embedded-workbench[data-embedded-tool="video"] .video-option-field legend,
.workspace-embedded-workbench[data-embedded-tool="video"] .production-direction-field legend { margin-bottom: 8px; color: #34414d; font-size: 12px; font-weight: 800; }
.workspace-embedded-workbench[data-embedded-tool="video"] .video-segmented { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 4px; min-height: 44px; padding: 4px; background: #edf1f2; border: 1px solid #d7dfe2; border-radius: 7px; }
.workspace-embedded-workbench[data-embedded-tool="video"] .video-duration-segmented { display: flex !important; flex-wrap: nowrap !important; grid-template-columns: none !important; width: 100%; overflow: hidden; }
.workspace-embedded-workbench[data-embedded-tool="video"] .video-duration-segmented label { flex: 1 1 0 !important; width: auto !important; min-width: 0; }
.workspace-embedded-workbench[data-embedded-tool="video"] .video-duration-segmented label > span { width: 100%; white-space: nowrap; }
.workspace-embedded-workbench[data-embedded-tool="video"] .video-segmented label,
.workspace-embedded-workbench[data-embedded-tool="video"] .production-direction-grid label { position: relative; min-width: 0; cursor: pointer; }
.workspace-embedded-workbench[data-embedded-tool="video"] .video-segmented input,
.workspace-embedded-workbench[data-embedded-tool="video"] .production-direction-grid input { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
.workspace-embedded-workbench[data-embedded-tool="video"] .video-segmented span { display: flex; align-items: center; justify-content: center; min-height: 34px; padding: 6px 8px; color: #66727e; text-align: center; background: transparent; border: 1px solid transparent; border-radius: 5px; font-size: 12px; font-weight: 800; }
.workspace-embedded-workbench[data-embedded-tool="video"] .video-segmented input:checked + span { color: #fff; background: var(--ws-primary); border-color: var(--ws-primary); }
.workspace-embedded-workbench[data-embedded-tool="video"] .production-direction-field { padding: 13px; background: #f8faf9; border: 1px solid #d9e1de; border-radius: 7px; }
.workspace-embedded-workbench[data-embedded-tool="video"] .production-direction-field legend { padding: 0 6px; }
.workspace-embedded-workbench[data-embedded-tool="video"] .production-direction-field legend span { margin-left: 6px; color: #a36514; font-size: 10px; }
.workspace-embedded-workbench[data-embedded-tool="video"] .production-direction-field.needs-selection { border-color: #d6a24d; box-shadow: 0 0 0 3px rgba(214, 162, 77, .1); }
.workspace-embedded-workbench[data-embedded-tool="video"] .production-direction-group { display: grid; gap: 6px; }
.workspace-embedded-workbench[data-embedded-tool="video"] .production-direction-group-title { display: flex; align-items: baseline; gap: 8px; padding: 0 2px; }
.workspace-embedded-workbench[data-embedded-tool="video"] .production-direction-group-title strong { color: #26343e; font-size: 11px; }
.workspace-embedded-workbench[data-embedded-tool="video"] .production-direction-group-title span { color: #84908a; font-size: 9px; }
.workspace-embedded-workbench[data-embedded-tool="video"] .production-direction-divider { height: 1px; margin: 10px 0; background: linear-gradient(90deg, transparent, #cfd9d5 8%, #cfd9d5 92%, transparent); }
.workspace-embedded-workbench[data-embedded-tool="video"] .production-direction-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 5px; }
.workspace-embedded-workbench[data-embedded-tool="video"] .production-direction-grid label > span { display: grid; align-content: center; min-height: 50px; padding: 6px 8px; background: #fff; border: 1px solid #dfe5e7; border-radius: 6px; transition: border-color 150ms ease, background 150ms ease; }
.workspace-embedded-workbench[data-embedded-tool="video"] .production-direction-grid strong { color: #26343e; font-size: 11px; line-height: 1.3; overflow-wrap: anywhere; }
.workspace-embedded-workbench[data-embedded-tool="video"] .production-direction-grid small { margin-top: 3px; color: #78848f; font-size: 10px; line-height: 1.3; overflow-wrap: anywhere; }
.workspace-embedded-workbench[data-embedded-tool="video"] .production-direction-grid label:hover > span { border-color: #94b8aa; background: #f4faf7; }
.workspace-embedded-workbench[data-embedded-tool="video"] .production-direction-grid input:checked + span { background: #e7f3ed; border-color: #5d967f; box-shadow: inset 3px 0 0 #286c51; }
.workspace-embedded-workbench[data-embedded-tool="video"] .production-direction-grid input:checked + span strong { color: #174c39; }
.workspace-embedded-workbench[data-embedded-tool="video"] .face-assets-card[hidden],
.workspace-embedded-workbench[data-embedded-tool="video"] .face-mode-controls[hidden],
.workspace-embedded-workbench[data-embedded-tool="video"] #virtualPersonGenderControls[hidden] { display: none; }
.workspace-embedded-workbench[data-embedded-tool="video"] .face-mode-controls { padding: 10px 12px; background: #f7faf9; border: 1px solid #d9e4df; border-radius: 7px; }
.workspace-embedded-workbench[data-embedded-tool="video"] .face-authorization-check { display: flex; align-items: center; gap: 9px; margin-top: 10px; padding: 10px 12px; color: #70410f; background: #fff6e6; border: 1px solid #edcf98; border-left: 3px solid #d88a1d; border-radius: 6px; cursor: pointer; }
.workspace-embedded-workbench[data-embedded-tool="video"] .face-authorization-check input { flex: 0 0 15px; width: 15px; height: 15px; margin: 0; accent-color: #286c51; }
.workspace-embedded-workbench[data-embedded-tool="video"] .face-authorization-check span { min-width: 0; color: #70410f; font-size: 12px; font-weight: 800; line-height: 1.55; }
.workspace-embedded-workbench[data-embedded-tool="video"] .virtual-person-gender { display: grid; grid-template-columns: auto minmax(180px, 260px); align-items: center; gap: 7px 12px; margin-top: 8px; }
.workspace-embedded-workbench[data-embedded-tool="video"] .virtual-person-gender small { grid-column: 2; color: #718078; font-size: 10px; }
.workspace-embedded-workbench[data-embedded-tool="video"] .production-direction-hint { display: block; margin-top: 9px; padding: 8px 10px; color: #8a470d; background: #fff4df; border: 1px solid #f0d19a; border-left: 3px solid #d88716; border-radius: 6px; font-size: 12px; font-weight: 800; line-height: 1.55; }
.workspace-embedded-workbench[data-embedded-tool="video"] .workbench-upload-pair { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; align-items: stretch; }
.workspace-embedded-workbench[data-embedded-tool="video"] .workbench-upload-pair.has-face-upload { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.workspace-embedded-workbench[data-embedded-tool="video"] .workbench-upload-pair > .workbench-upload-card { min-width: 0; height: 100%; margin: 0; }
.workspace-embedded-workbench[data-embedded-tool="video"] .video-spec-strip { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1px; overflow: hidden; background: #dce4e1; border: 1px solid #d5deda; border-radius: 7px; }
.workspace-embedded-workbench[data-embedded-tool="video"] .video-spec-strip > span { display: flex; align-items: center; flex-direction: column; justify-content: center; gap: 4px; min-width: 0; min-height: 68px; padding: 10px 12px; color: #66727d; text-align: center; background: #fff; }
.workspace-embedded-workbench[data-embedded-tool="video"] .video-spec-strip strong { color: #27343e; font-size: 12px; line-height: 1.35; }
.workspace-embedded-workbench[data-embedded-tool="video"] .video-spec-strip small { color: #6f7c86; font-size: 10px; line-height: 1.35; }
.workspace-embedded-workbench[data-embedded-tool="video"] .video-copy-field { padding: 12px; background: #f3faf6; border: 1px solid #cfe4d8; border-radius: 7px; }
.workspace-cost-badge { display: inline-flex; align-items: center; min-height: 30px; padding: 5px 10px; color: #165d47; background: #e4f2ec; border: 1px solid #c4dfd4; border-radius: 5px; font-size: 11px; font-weight: 800; }
.workspace-segmented { display: inline-flex; margin-bottom: 20px; padding: 3px; background: #edf0f2; border-radius: 6px; }
.workspace-segmented button { min-height: 32px; padding: 5px 14px; color: var(--ws-muted); background: transparent; border: 0; border-radius: 4px; cursor: pointer; }
.workspace-segmented button.is-active { color: var(--ws-text); background: #fff; box-shadow: 0 1px 4px rgba(20, 30, 40, .08); font-weight: 700; }
.workspace-field { display: grid; gap: 7px; }
.workspace-field > span { font-size: 12px; font-weight: 700; }
.workspace-field > small { color: var(--ws-muted); font-size: 11px; }
.workspace-field input, .workspace-field textarea, .workspace-field select { width: 100%; color: var(--ws-text); background: #fbfcfc; border: 1px solid #d5dce0; border-radius: 6px; outline: 0; }
.workspace-field input, .workspace-field select { height: 40px; padding: 0 11px; }
.workspace-field select { cursor: pointer; }
.workspace-field textarea { min-height: 150px; padding: 11px; resize: vertical; line-height: 1.65; }
.workspace-field input:focus, .workspace-field textarea:focus, .workspace-field select:focus { background: #fff; border-color: #7fa696; box-shadow: 0 0 0 3px rgba(22, 74, 58, .08); }
.workspace-generator-toolbar { display: flex; align-items: end; justify-content: space-between; gap: 20px; margin-bottom: 20px; }
.workspace-generator-toolbar .workspace-segmented { margin-bottom: 0; }
.workspace-platform-field { width: min(220px, 100%); }
.workspace-ai-fields { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.workspace-ai-fields[hidden] { display: none; }
.workspace-field-wide { grid-column: 1 / -1; }
.workspace-ai-generator .workspace-field textarea { min-height: 118px; }
.workspace-form-actions { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-top: 16px; }
.workspace-form-actions > span { color: var(--ws-muted); font-size: 11px; }
.workspace-output { margin-top: 12px; padding: 18px 20px; }
.workspace-output > div { display: flex; align-items: center; justify-content: space-between; }
.workspace-output pre { margin: 14px 0 0; color: #2c3741; font-family: inherit; line-height: 1.75; white-space: pre-wrap; word-break: break-word; }
.workspace-inline-field { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px; }
.competitor-form-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.competitor-form-grid [hidden] { display: none; }
.competitor-workflow { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0; margin: 0 0 14px; padding: 0; list-style: none; border: 1px solid var(--ws-line); border-radius: 7px; background: #fff; overflow: hidden; }
.competitor-workflow li { position: relative; display: flex; align-items: center; gap: 9px; min-width: 0; padding: 12px 14px; color: var(--ws-muted); border-right: 1px solid var(--ws-line); }
.competitor-workflow li:last-child { border-right: 0; }
.competitor-workflow li::after { content: ""; position: absolute; right: -5px; top: 50%; width: 8px; height: 8px; border-top: 1px solid var(--ws-line); border-right: 1px solid var(--ws-line); background: #fff; transform: translateY(-50%) rotate(45deg); z-index: 1; }
.competitor-workflow li:last-child::after { display: none; }
.competitor-workflow b { display: grid; place-items: center; flex: none; width: 25px; height: 25px; color: #66737b; background: #edf1f2; border-radius: 50%; font-size: 11px; }
.competitor-workflow span, .competitor-workflow strong, .competitor-workflow small { display: block; min-width: 0; }
.competitor-workflow strong { color: var(--ws-text); font-size: 11px; }
.competitor-workflow small { margin-top: 3px; overflow: hidden; color: var(--ws-muted); font-size: 9px; text-overflow: ellipsis; white-space: nowrap; }
.competitor-workflow li.is-active { color: var(--ws-primary); background: #f1f8f5; }
.competitor-workflow li.is-active b, .competitor-workflow li.is-complete b { color: #fff; background: var(--ws-primary); }
.competitor-workflow li.is-complete { color: #3f785f; }
.competitor-local-panel { display: grid; grid-template-columns: minmax(280px, .8fr) minmax(0, 1.2fr); gap: 0; overflow: hidden; background: #fff; border: 1px solid var(--ws-line); border-radius: 7px; }
.competitor-local-primary { padding: 24px; background: #f1f8f5; border-right: 1px solid #cfe0d8; }
.competitor-local-primary > p { margin: 0; color: #4e5f56; font-size: 12px; line-height: 1.75; }
.competitor-local-primary .workspace-button { width: 100%; margin-top: 18px; }
.competitor-local-primary > small { display: block; margin-top: 11px; color: var(--ws-muted); font-size: 10px; line-height: 1.55; }
.competitor-local-primary > small b { font-family: Consolas, monospace; font-weight: 700; }
.competitor-install-details { margin-top: 12px; padding-top: 11px; border-top: 1px solid #cfe0d8; }
.competitor-install-details summary { display: flex; align-items: center; gap: 7px; color: #205d46; cursor: pointer; font-size: 11px; font-weight: 800; list-style: none; }
.competitor-install-details summary::-webkit-details-marker { display: none; }
.competitor-install-details summary svg { width: 15px; height: 15px; }
.competitor-install-details ol { display: grid; gap: 6px; margin: 10px 0 0; padding-left: 18px; color: #526158; font-size: 10px; line-height: 1.55; }
.competitor-install-details b { font-family: Consolas, monospace; font-size: 9px; }
.competitor-local-steps { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
.competitor-local-steps article { display: flex; gap: 11px; min-width: 0; padding: 22px; border-right: 1px solid var(--ws-line); border-bottom: 1px solid var(--ws-line); }
.competitor-local-steps article:nth-child(2n) { border-right: 0; }
.competitor-local-steps article:nth-child(n+3) { border-bottom: 0; }
.competitor-local-steps article > span { display: grid; place-items: center; flex: none; width: 25px; height: 25px; color: var(--ws-primary); background: #e2f0e9; border-radius: 50%; font: 800 10px/1 Consolas, monospace; }
.competitor-local-steps strong, .competitor-local-steps small { display: block; }
.competitor-local-steps strong { font-size: 12px; }
.competitor-local-steps small { margin-top: 5px; color: var(--ws-muted); font-size: 10px; line-height: 1.55; }
.competitor-journey { margin-top: 14px; padding: 20px; border-top: 3px solid #2c7a59; background: #f7faf8; }
.competitor-journey-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 18px; }
.competitor-journey-head p, .competitor-journey-head h2, .competitor-journey-head span { margin: 0; }
.competitor-journey-head p { color: var(--ws-primary); font-size: 9px; font-weight: 900; }
.competitor-journey-head h2 { margin-top: 4px; font-size: 17px; }
.competitor-journey-head > div > span { display: block; max-width: 760px; margin-top: 6px; color: var(--ws-muted); font-size: 11px; line-height: 1.55; }
.competitor-journey-head .workspace-status { flex: none; }
.competitor-journey-head .workspace-status svg { width: 14px; height: 14px; margin-right: 5px; }
.competitor-journey-map { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 16px; margin: 20px 0 0; padding: 0; list-style: none; }
.competitor-journey-map li { position: relative; display: grid; gap: 10px; min-width: 0; padding: 14px 12px; background: #fff; border: 1px solid #dbe5e0; border-radius: 6px; }
.competitor-journey-map li:not(:last-child)::after { content: ""; position: absolute; z-index: 2; top: 30px; left: calc(100% + 1px); width: 15px; height: 2px; background: #8dbba5; }
.competitor-journey-map li:not(:last-child)::before { content: ""; position: absolute; z-index: 3; top: 26px; right: -15px; width: 8px; height: 8px; border-top: 2px solid #4d8d70; border-right: 2px solid #4d8d70; transform: rotate(45deg); }
.competitor-journey-icon { display: grid; width: 34px; height: 34px; place-items: center; color: #176346; background: #e5f3eb; border: 1px solid #c6e3d3; border-radius: 5px; }
.competitor-journey-icon svg { width: 17px; height: 17px; }
.competitor-journey-map b, .competitor-journey-map strong, .competitor-journey-map small { display: block; }
.competitor-journey-map b { color: #6e8679; font: 800 9px/1 Consolas, monospace; }
.competitor-journey-map strong { margin-top: 5px; color: var(--ws-text); font-size: 12px; }
.competitor-journey-map small { margin-top: 5px; color: var(--ws-muted); font-size: 10px; line-height: 1.55; }
.competitor-feature-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; margin-top: 14px; }
.competitor-feature-grid article { display: flex; align-items: flex-start; gap: 10px; min-width: 0; padding: 14px; border: 1px solid var(--ws-line); border-radius: 6px; background: #fff; }
.competitor-feature-grid article > svg { width: 19px; height: 19px; flex: none; color: #257256; }
.competitor-feature-grid article:nth-child(2) > svg { color: #9a6a20; }
.competitor-feature-grid article:nth-child(3) > svg { color: #326da8; }
.competitor-feature-grid strong, .competitor-feature-grid small { display: block; }
.competitor-feature-grid strong { font-size: 12px; }
.competitor-feature-grid small { margin-top: 4px; color: var(--ws-muted); font-size: 10px; line-height: 1.55; }
.competitor-help-strip { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0; margin-top: 14px; border: 1px solid #eadfca; background: #fffdfa; }
.competitor-help-strip > div { display: flex; align-items: flex-start; gap: 10px; min-width: 0; padding: 15px; border-right: 1px solid #eadfca; }
.competitor-help-strip > div:last-child { border-right: 0; }
.competitor-help-strip > div > svg { width: 18px; height: 18px; flex: none; color: #a16a18; }
.competitor-help-strip > div:nth-child(2) > svg { color: #286b9b; }
.competitor-help-strip > div:nth-child(3) > svg { color: #2b7b5a; }
.competitor-help-strip p { margin: 0; }
.competitor-help-strip strong, .competitor-help-strip span { display: block; }
.competitor-help-strip strong { color: #485149; font-size: 11px; }
.competitor-help-strip span { margin-top: 4px; color: var(--ws-muted); font-size: 10px; line-height: 1.55; }
.competitor-full-tutorial { margin-top: 14px; border: 1px solid var(--ws-line); border-radius: 7px; background: #fff; overflow: hidden; }
.competitor-full-tutorial > summary { display: flex; align-items: center; gap: 10px; min-height: 58px; padding: 12px 16px; cursor: pointer; list-style: none; }
.competitor-full-tutorial > summary::-webkit-details-marker { display: none; }
.competitor-full-tutorial > summary > span { display: inline-flex; align-items: center; gap: 8px; color: #1b5d44; font-size: 13px; font-weight: 850; }
.competitor-full-tutorial > summary > span svg { width: 18px; height: 18px; }
.competitor-full-tutorial > summary > small { color: var(--ws-muted); font-size: 10px; }
.competitor-full-tutorial > summary > svg { width: 17px; height: 17px; margin-left: auto; color: #6c7a73; transition: transform 150ms ease; }
.competitor-full-tutorial[open] > summary { border-bottom: 1px solid var(--ws-line); background: #f7faf8; }
.competitor-full-tutorial[open] > summary > svg { transform: rotate(180deg); }
.competitor-tutorial-body { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
.competitor-tutorial-body article { display: flex; align-items: flex-start; gap: 12px; min-width: 0; padding: 16px; border-right: 1px solid var(--ws-line); border-bottom: 1px solid var(--ws-line); }
.competitor-tutorial-body article:nth-child(2n) { border-right: 0; }
.competitor-tutorial-body article:nth-last-child(-n + 2) { border-bottom: 0; }
.competitor-tutorial-body article > span { display: grid; place-items: center; width: 27px; height: 27px; flex: none; color: #176346; border: 1px solid #c6e3d3; border-radius: 5px; background: #e8f4ed; font: 800 10px/1 Consolas, monospace; }
.competitor-tutorial-body strong { display: block; color: var(--ws-text); font-size: 12px; }
.competitor-tutorial-body p { margin: 5px 0 0; color: var(--ws-muted); font-size: 10px; line-height: 1.65; }
.competitor-tutorial-body b { padding: 1px 3px; color: #315a49; background: #edf5f0; border-radius: 3px; font-family: Consolas, monospace; font-size: 9px; }
.competitor-workbench { display: grid; grid-template-columns: minmax(0, 1fr) minmax(230px, .34fr); gap: 14px; align-items: stretch; }
.competitor-analyzer { min-width: 0; padding: 18px; }
.competitor-section-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin-bottom: 13px; }
.competitor-section-head small, .competitor-section-head strong { display: block; }
.competitor-section-head small { color: var(--ws-primary); font-size: 9px; font-weight: 800; }
.competitor-section-head strong { margin-top: 3px; font-size: 15px; }
.competitor-section-head > span { color: var(--ws-muted); font-size: 10px; }
.competitor-section-head > svg { width: 20px; height: 20px; color: var(--ws-primary); }
.competitor-analyzer .workspace-segmented { margin-bottom: 14px; }
.competitor-analyzer .workspace-segmented button { display: inline-flex; align-items: center; justify-content: center; gap: 6px; }
.competitor-analyzer .workspace-segmented svg { width: 14px; height: 14px; }
.competitor-form-grid .workspace-field small { display: block; margin-top: 5px; color: var(--ws-muted); font-size: 9px; line-height: 1.4; }
.competitor-session-panel { display: flex; flex-direction: column; gap: 9px; padding: 18px; background: #f6faf8; border: 1px solid #cfded7; border-radius: 7px; }
.competitor-session-panel > button { display: flex; align-items: center; gap: 9px; min-height: 52px; padding: 8px 10px; color: var(--ws-text); text-align: left; background: #fff; border: 1px solid #d5e2dc; border-radius: 6px; cursor: pointer; }
.competitor-session-panel > button:hover { border-color: var(--ws-primary); }
.competitor-session-panel > button > span:nth-child(2) { min-width: 0; flex: 1; }
.competitor-session-panel button strong, .competitor-session-panel button small { display: block; }
.competitor-session-panel button strong { font-size: 11px; }
.competitor-session-panel button small { margin-top: 3px; color: var(--ws-muted); font-size: 9px; }
.competitor-session-panel button > svg { width: 15px; color: var(--ws-muted); }
.competitor-platform-mark { display: grid; place-items: center; flex: none; width: 28px; height: 28px; color: #fff; border-radius: 5px; font-size: 12px; font-weight: 800; }
.competitor-platform-mark.taobao { background: #ed6b2f; }
.competitor-platform-mark.pdd { background: #d8313b; }
.competitor-session-panel > p { display: flex; gap: 5px; margin: auto 0 0; color: var(--ws-muted); font-size: 9px; line-height: 1.5; }
.competitor-session-panel > p svg { flex: none; width: 13px; height: 13px; margin-top: 1px; color: var(--ws-primary); }
.workspace-option-field { min-width: 0; margin: 0; padding: 9px 11px 10px; border: 1px solid #d5dce0; border-radius: 6px; }
.workspace-option-field legend { padding: 0 5px; color: var(--ws-text); font-size: 12px; font-weight: 700; }
.workspace-option-field label { display: inline-flex; align-items: center; gap: 6px; margin: 2px 14px 2px 0; color: #49545d; font-size: 12px; cursor: pointer; }
.workspace-option-field input { accent-color: var(--ws-primary); }
.competitor-capture-field { align-self: end; min-height: 40px; padding-top: 6px; padding-bottom: 6px; }
.competitor-task-status { display: grid; grid-template-columns: minmax(220px, .65fr) minmax(260px, 1fr); gap: 16px 22px; margin-top: 12px; padding: 16px 18px; background: #f7faf8; border: 1px solid #cfded7; border-radius: 7px; }
.competitor-task-status > div:first-child { display: grid; grid-template-columns: auto 1fr; align-items: center; gap: 3px 9px; }
.competitor-task-status > div:first-child .workspace-status { grid-row: 1 / 3; }
.competitor-task-status strong, .competitor-task-status small { min-width: 0; }
.competitor-task-status small { color: var(--ws-muted); }
.competitor-task-status progress { align-self: center; width: 100%; height: 8px; accent-color: var(--ws-primary); }
#competitorTaskLogs { grid-column: 1 / -1; max-height: 112px; overflow: auto; color: #5c6871; font-family: Consolas, monospace; font-size: 10px; line-height: 1.7; }
#competitorTaskLogs p { margin: 0; }
.automation-batch-toolbar { display: grid; grid-template-columns: minmax(180px, 1fr) minmax(180px, 1fr) auto auto auto; align-items: end; gap: 12px; }
.automation-mode-toggle { display: flex; align-items: center; gap: 9px; min-height: 40px; padding: 7px 10px; border: 1px solid #d5dce0; border-radius: 6px; cursor: pointer; }
.automation-mode-toggle input { accent-color: var(--ws-primary); }
.automation-mode-toggle span, .automation-mode-toggle strong, .automation-mode-toggle small { display: block; }
.automation-mode-toggle strong { font-size: 11px; }
.automation-mode-toggle small { margin-top: 2px; color: var(--ws-muted); font-size: 9px; }
.automation-product-list { display: grid; gap: 10px; margin-top: 12px; }
.automation-product-card { background: #fff; border: 1px solid var(--ws-line); border-radius: 7px; }
.automation-product-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 14px; border-bottom: 1px solid #e4e9ec; }
.automation-product-head > div { min-width: 0; }
.automation-product-head strong, .automation-product-head small { display: block; }
.automation-product-head small { margin-top: 3px; color: var(--ws-muted); font-size: 10px; }
.automation-product-body { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 13px; padding: 14px; }
.automation-product-body .workspace-field textarea { min-height: 92px; }
.automation-sku-table { grid-column: 1 / -1; overflow-x: auto; }
.automation-sku-table table { width: 100%; min-width: 760px; border-collapse: collapse; }
.automation-sku-table th { padding: 7px 8px; color: var(--ws-muted); font-size: 10px; text-align: left; border-bottom: 1px solid #dde3e6; }
.automation-sku-table td { padding: 6px 4px; }
.automation-sku-table input { width: 100%; min-width: 80px; height: 34px; padding: 0 8px; border: 1px solid #d5dce0; border-radius: 5px; }
.automation-sku-actions { display: flex; justify-content: flex-end; margin-top: 7px; }
.automation-history { margin-top: 20px; }
.automation-task-list { display: grid; gap: 8px; }
.automation-task-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 6px 14px; padding: 12px 14px; background: #fff; border: 1px solid var(--ws-line); border-radius: 6px; }
.automation-task-row strong, .automation-task-row small { display: block; }
.automation-task-row small { color: var(--ws-muted); font-size: 10px; }
.automation-task-row progress { grid-column: 1 / -1; width: 100%; height: 6px; accent-color: var(--ws-primary); }
.automation-task-meta { display: flex; align-items: center; justify-content: flex-end; gap: 8px; }
.automation-task-actions { display: inline-flex; gap: 4px; }
.automation-task-actions button { display: inline-grid; place-items: center; width: 28px; height: 28px; padding: 0; color: var(--ws-muted); background: #fff; border: 1px solid var(--ws-line); border-radius: 5px; cursor: pointer; }
.automation-task-actions button:hover { color: var(--ws-primary); border-color: #a9c6bb; }
.automation-task-actions button svg { width: 14px; height: 14px; }
.automation-empty { margin: 0; padding: 22px; color: var(--ws-muted); text-align: center; background: #fff; border: 1px dashed #cfd8dc; border-radius: 6px; }
.workspace-browser-dialog { width: min(1100px, calc(100vw - 32px)); max-width: none; padding: 0; overflow: hidden; color: var(--ws-text); background: #f3f6f7; border: 1px solid #bfcbd0; border-radius: 8px; box-shadow: 0 30px 90px rgba(10, 20, 28, .3); }
.workspace-browser-dialog::backdrop { background: rgba(15, 24, 30, .58); backdrop-filter: blur(5px); }
.workspace-browser-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; padding: 14px 16px; background: #fff; border-bottom: 1px solid #d7e0e3; }
.workspace-browser-head p, .workspace-browser-head h2 { margin: 0; }
.workspace-browser-head p { color: var(--ws-primary); font-size: 9px; font-weight: 800; }
.workspace-browser-head h2 { margin-top: 2px; font-size: 17px; }
.workspace-browser-head span { display: block; margin-top: 3px; color: var(--ws-muted); font-size: 10px; }
.workspace-browser-canvas { display: grid; place-items: center; min-height: 300px; max-height: calc(100vh - 210px); overflow: auto; background: #1c2328; }
.workspace-browser-canvas img { display: block; width: min(100%, 1280px); height: auto; cursor: crosshair; user-select: none; }
.workspace-browser-controls { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; gap: 8px; padding: 10px 12px; background: #fff; border-top: 1px solid #d7e0e3; }
.workspace-browser-controls input { min-width: 0; height: 38px; padding: 0 10px; border: 1px solid #ccd6da; border-radius: 5px; }
.competitor-results { margin-top: 12px; padding: 18px; }
.competitor-results-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 14px; }
.competitor-results-head > div:first-child strong, .competitor-results-head > div:first-child span { display: block; }
.competitor-results-head > div:first-child span { margin-top: 4px; color: var(--ws-muted); font-size: 11px; }
.competitor-results-head > div:last-child { display: flex; align-items: center; gap: 12px; }
.competitor-results-head label { color: var(--ws-muted); font-size: 12px; }
.competitor-image-grid { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 9px; }
.competitor-image { position: relative; aspect-ratio: 1; background: #eef1f2; border: 1px solid var(--ws-line); border-radius: 5px; overflow: hidden; }
.competitor-image img { width: 100%; height: 100%; object-fit: contain; background: #f7f8f9; }
.competitor-image label { position: absolute; inset: 0; cursor: pointer; }
.competitor-image input { position: absolute; top: 8px; left: 8px; width: 18px; height: 18px; accent-color: var(--ws-primary); }
.competitor-image:has(input:checked) { border-color: var(--ws-primary); box-shadow: inset 0 0 0 2px var(--ws-primary); }
.competitor-progress { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 5px 14px; margin-top: 14px; padding: 12px 14px; color: #234e40; background: #eaf4f0; border: 1px solid #c8e0d7; border-radius: 5px; }
.competitor-progress-copy strong, .competitor-progress-copy span { display: block; }
.competitor-progress-copy strong { font-size: 11px; }
.competitor-progress-copy span { margin-top: 2px; color: #60786f; font-size: 9px; }
.competitor-progress > b { color: #1d6b51; font: 800 13px/1 Consolas, monospace; }
.competitor-progress progress { grid-column: 1 / -1; width: 100%; height: 7px; accent-color: var(--ws-primary); }
@keyframes ws-spin { to { transform: rotate(360deg); } }
.roi-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.roi-results { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; margin-top: 12px; }
.roi-results article { padding: 18px; background: #fff; border: 1px solid var(--ws-line); border-radius: 7px; }
.roi-results small, .roi-results strong { display: block; }
.roi-results small { color: var(--ws-muted); }
.roi-results strong { margin-top: 8px; font-size: 20px; }
.workspace-placeholder { position: relative; display: grid; place-items: center; align-content: center; gap: 8px; min-height: 320px; text-align: center; background: #eef1f2; border: 1px dashed #bbc4ca; border-radius: 7px; overflow: hidden; }
.workspace-placeholder::before { content: ""; position: absolute; top: 38px; left: 24px; width: 110px; height: 56px; background: rgba(255,255,255,.76); box-shadow: 132px 0 rgba(255,255,255,.76), 264px 0 rgba(255,255,255,.76), 396px 0 rgba(255,255,255,.76), 0 76px rgba(255,255,255,.76), 132px 76px rgba(255,255,255,.76), 264px 76px rgba(255,255,255,.76), 396px 76px rgba(255,255,255,.76); filter: blur(9px); opacity: .65; }
.workspace-placeholder > * { position: relative; z-index: 1; }
.workspace-placeholder svg { width: 28px; height: 28px; color: var(--ws-primary); }
.workspace-placeholder strong { font-size: 16px; }
.workspace-placeholder span { color: var(--ws-muted); }
.workspace-placeholder.compact { min-height: 150px; margin-top: 20px; }
.workspace-internal-test { padding: 32px; background: linear-gradient(145deg, #f4f8f6, #eef3f1); border-color: #b9ccc4; }
.workspace-internal-test::before { opacity: .34; }
.workspace-internal-test svg { width: 36px; height: 36px; padding: 8px; color: #24634e; background: #dcece5; border-radius: 8px; }
.workspace-internal-test strong { max-width: 680px; color: #173f32; font-size: 19px; line-height: 1.55; }
.workspace-internal-test span { max-width: 720px; color: #51655d; font-size: 14px; line-height: 1.7; }
.referral-summary { display: grid; grid-template-columns: repeat(3, minmax(120px, .7fr)) minmax(390px, 1.7fr); align-items: center; gap: 18px; }
.referral-summary small, .referral-summary strong { display: block; }
.referral-summary small { color: var(--ws-muted); }
.referral-summary strong { margin-top: 6px; font-size: 20px; }
.workspace-referral-copy-group { display: grid; grid-template-columns: auto minmax(245px, 1fr); align-items: stretch; gap: 10px; }
.workspace-referral-copy-group > .workspace-button { align-self: stretch; min-height: 70px; }
.workspace-referral-rate-card { display: flex; flex-direction: column; justify-content: center; min-height: 70px; padding: 11px 15px; border: 1px solid rgba(211, 47, 47, .18); border-radius: 7px; background: linear-gradient(120deg, #fff8f0 0%, #fff0e9 46%, #fff7f3 100%); box-shadow: inset 3px 0 0 #e33d32; }
.workspace-referral-rate-card > span { color: #6d4a42; font-size: 11px; font-weight: 800; }
.workspace-referral-rate-card p { display: flex; align-items: baseline; gap: 7px; margin: 4px 0 2px; color: #262220; font-size: 13px; font-weight: 700; white-space: nowrap; }
.workspace-referral-rate-card p strong { display: inline; margin: 0; color: #d62f2f; font-size: 18px; font-weight: 900; }
.workspace-referral-rate-card p b { color: #c0a39a; font-weight: 700; }
.workspace-referral-rate-card small { max-width: 560px; color: #8a6c64; font-size: 10px; line-height: 1.5; }
.workspace-referral-link-panel { display: grid; grid-template-columns: minmax(0, 1fr) minmax(260px, 340px); gap: 24px; align-items: center; margin-top: 16px; }
.workspace-referral-link-content { min-width: 0; }
.workspace-referral-link-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 10px; margin-top: 18px; }
.workspace-referral-link-row input { min-width: 0; height: 44px; padding: 0 13px; color: #24312d; background: #f7faf9; border: 1px solid var(--ws-line); border-radius: 6px; font: inherit; font-size: 12px; }
.workspace-referral-link-row input:focus { outline: 3px solid rgba(39, 128, 99, .16); border-color: var(--ws-primary); }
.workspace-referral-qr { display: flex; align-items: center; gap: 14px; min-width: 0; padding: 12px; border-left: 1px solid var(--ws-line); }
.workspace-referral-qr-image { display: grid; place-items: center; flex: 0 0 136px; width: 136px; height: 136px; padding: 6px; background: #fff; border: 1px solid var(--ws-line); border-radius: 6px; }
.workspace-referral-qr-image img { display: block; width: 100%; height: 100%; object-fit: contain; }
.workspace-referral-qr > div:last-child { display: grid; gap: 5px; min-width: 0; }
.workspace-referral-qr strong { font-size: 14px; }
.workspace-referral-qr small { color: var(--ws-muted); font-size: 11px; line-height: 1.5; }
.workspace-link-button { display: inline-flex; align-items: center; gap: 5px; width: fit-content; margin-top: 5px; padding: 0; color: var(--ws-primary); background: none; border: 0; cursor: pointer; font: inherit; font-size: 12px; font-weight: 700; }
.workspace-link-button svg { width: 14px; height: 14px; }
.workspace-referral-poster-section { margin-top: 16px; }
.workspace-referral-poster-grid { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 12px; }
.workspace-referral-poster-card { min-width: 0; overflow: hidden; background: #fff; border: 1px solid var(--ws-line); border-radius: 7px; }
.workspace-referral-poster-thumb { display: block; width: 100%; padding: 0; aspect-ratio: 4 / 5; overflow: hidden; background: #eef2f0; border: 0; cursor: zoom-in; }
.workspace-referral-poster-thumb img { display: block; width: 100%; height: 100%; object-fit: cover; }
.workspace-referral-poster-card > div:nth-child(2) { display: grid; gap: 3px; min-height: 62px; padding: 10px 11px; }
.workspace-referral-poster-card strong { font-size: 12px; }
.workspace-referral-poster-card small { color: var(--ws-muted); font-size: 10px; line-height: 1.45; }
.workspace-referral-poster-actions { display: grid; grid-template-columns: repeat(3, 1fr); border-top: 1px solid var(--ws-line); }
.workspace-referral-poster-actions button { display: inline-flex; align-items: center; justify-content: center; gap: 4px; min-width: 0; height: 36px; padding: 0 4px; color: #42524c; background: #fff; border: 0; border-right: 1px solid var(--ws-line); cursor: pointer; font: inherit; font-size: 10px; }
.workspace-referral-poster-actions button:last-child { border-right: 0; }
.workspace-referral-poster-actions button:hover { color: var(--ws-primary); background: #f0f7f4; }
.workspace-referral-poster-actions svg { width: 13px; height: 13px; }
.workspace-referral-poster-preview { width: min(680px, calc(100vw - 28px)); max-height: calc(100vh - 28px); padding: 0; overflow: hidden; border: 0; border-radius: 8px; box-shadow: 0 28px 80px rgba(11, 18, 25, .34); }
.workspace-referral-poster-preview::backdrop { background: rgba(8, 13, 18, .7); backdrop-filter: blur(3px); }
.workspace-referral-poster-preview-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 16px; border-bottom: 1px solid var(--ws-line); }
.workspace-referral-poster-preview-head small, .workspace-referral-poster-preview-head strong { display: block; }
.workspace-referral-poster-preview-head small { color: var(--ws-muted); font-size: 9px; }
.workspace-referral-poster-preview-head strong { margin-top: 2px; font-size: 14px; }
.workspace-referral-poster-preview-stage { display: grid; place-items: center; max-height: calc(100vh - 170px); padding: 16px; overflow: auto; background: #edf1ef; }
.workspace-referral-poster-preview-stage img { display: block; max-width: 100%; max-height: calc(100vh - 205px); object-fit: contain; box-shadow: 0 8px 26px rgba(19, 31, 27, .18); }
.workspace-referral-poster-preview-actions { display: flex; justify-content: flex-end; gap: 10px; padding: 12px 16px; border-top: 1px solid var(--ws-line); }

.workspace-login-dialog { width: min(430px, calc(100vw - 28px)); padding: 0; border: 0; border-radius: 8px; box-shadow: 0 28px 80px rgba(11, 18, 25, .3); }
.workspace-login-dialog::backdrop { background: rgba(8, 13, 18, .58); backdrop-filter: blur(3px); }
.workspace-login-dialog form { display: grid; grid-template-columns: 42px 1fr; gap: 18px 12px; padding: 28px; }
.workspace-login-dialog form > div:nth-child(2) { align-self: center; }
.workspace-login-dialog p, .workspace-login-dialog h2 { margin: 0; }
.workspace-login-dialog p { color: var(--ws-primary); font-size: 10px; font-weight: 800; }
.workspace-login-dialog h2 { margin-top: 3px; font-size: 21px; }
.workspace-login-dialog form > div:nth-child(2) > span { display: block; margin-top: 5px; color: var(--ws-muted); font-size: 11px; }
.workspace-login-dialog .workspace-field, .workspace-login-dialog .workspace-button, .workspace-login-dialog .workspace-form-error, .workspace-login-dialog form > a { grid-column: 1 / -1; }
.workspace-login-dialog form > a { text-align: center; color: var(--ws-primary); font-size: 12px; font-weight: 700; }
.workspace-form-error { margin: -4px 0; padding: 9px 10px; color: #a7392d; background: #fff0ed; border-radius: 5px; font-size: 11px; }
.workspace-toast { position: fixed; right: 24px; bottom: 94px; z-index: 80; max-width: min(380px, calc(100vw - 32px)); padding: 12px 15px; color: #fff; background: #17221e; border-radius: 6px; box-shadow: var(--ws-shadow); }
.workspace-toast.is-error { background: #802f27; }
.workspace-scrim { position: fixed; inset: 0; z-index: 25; background: rgba(10, 16, 21, .48); }
body.workspace-page .referral-fab { right: 20px; bottom: 20px; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}

@media (max-width: 1100px) {
  .workspace-referral-poster-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .workspace-metrics { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .workspace-tool-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .competitor-image-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .roi-results { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .workspace-check-in-hero { grid-template-columns: minmax(0, 1fr) 320px; }
  .workspace-check-in-copy { padding: 34px; }
  .workspace-embedded-workbench.video-workbench-grid { grid-template-columns: 1fr; }
  .workspace-embedded-workbench[data-embedded-tool="video"] .production-direction-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}

@media (max-width: 1100px) {
  .workspace-topbar-slogan { display: none; }
  .workspace-search { width: min(280px, 36vw); }
}

@media (max-width: 820px) {
  .workspace-sidebar { overflow-y: auto; transform: translateX(-100%); transition: transform 180ms ease; box-shadow: 20px 0 50px rgba(0,0,0,.22); }
  .workspace-nav { display: block; }
  .workspace-nav-group { display: block; margin-bottom: 5px; }
  .workspace-sidebar.is-open { transform: none; }
  .workspace-stage { margin-left: 0; }
  .workspace-menu-button { display: inline-grid !important; }
  .workspace-topbar { padding: 9px 14px; gap: 9px; }
  .workspace-visit-tabs-shell { top: 56px; height: 44px; padding: 6px 14px 0; }
  .workspace-visit-back { width: 32px; height: 32px; flex-basis: 32px; margin-bottom: 5px; }
  .workspace-visit-tab { min-width: 116px; max-width: 176px; flex-basis: 150px; }
  .workspace-search { width: auto; flex: 1; }
  .workspace-topbar-actions > a, .workspace-topbar-actions > button:not(.workspace-profile) { display: none; }
  .workspace-topbar-actions > #workspaceNoticeButton { display: inline-grid; }
  .workspace-notice-drawer { top: 58px; right: 8px; max-height: calc(100vh - 72px); }
  .workspace-topbar-actions > .workspace-leaf-chip { display: inline-flex; min-width: 68px; padding: 0 8px; }
  .workspace-profile { min-width: 44px; width: 44px; padding: 4px; }
  .workspace-profile > span:nth-child(2), .workspace-profile > svg { display: none; }
  .workspace-main { padding: 20px 14px 32px; }
  .workspace-tool-subnav { align-items: center; flex-direction: row; gap: 6px; padding: 5px; }
  .workspace-tool-subnav-label { display: grid; gap: 1px; min-width: 112px; padding: 3px 7px; border-right: 1px solid #e6e1f0; }
  .workspace-tool-subnav-label strong { font-size: 12px; }
  .workspace-tool-subnav-link { min-width: 102px; min-height: 34px; padding: 7px 10px; }
  .workspace-page-heading { align-items: flex-start; flex-direction: column; min-height: 0; }
  .workspace-page-heading h1 { font-size: 23px; }
  .workspace-heading-actions { width: 100%; }
  .workspace-heading-actions .workspace-button { flex: 1; }
  .workspace-workflow { grid-template-columns: 1fr; }
  .workspace-workflow li { min-height: 50px; border-right: 0; border-bottom: 1px solid var(--ws-line); }
  .workspace-workflow li:last-child { border-bottom: 0; }
  .workspace-workflow li::after { display: none; }
  .competitor-workbench { grid-template-columns: 1fr; }
  .competitor-workflow { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .competitor-workflow li { min-height: 64px; padding: 11px; border-bottom: 1px solid var(--ws-line); }
  .competitor-workflow li:nth-child(2n) { border-right: 0; }
  .competitor-workflow li:nth-child(n+3) { border-bottom: 0; }
  .competitor-workflow li::after { display: none; }
  .competitor-local-panel { grid-template-columns: 1fr; }
  .competitor-local-primary { border-right: 0; border-bottom: 1px solid #cfe0d8; }
  .competitor-journey { padding: 16px; }
  .competitor-journey-head { align-items: flex-start; flex-direction: column; gap: 9px; }
  .competitor-journey-map { grid-template-columns: 1fr; gap: 8px; margin-top: 15px; }
  .competitor-journey-map li { grid-template-columns: 34px minmax(0, 1fr); gap: 10px; padding: 11px; }
  .competitor-journey-map li:not(:last-child)::after { top: calc(100% + 1px); left: 27px; width: 2px; height: 7px; }
  .competitor-journey-map li:not(:last-child)::before { top: auto; right: auto; bottom: -7px; left: 24px; width: 7px; height: 7px; transform: rotate(135deg); }
  .competitor-feature-grid, .competitor-help-strip { grid-template-columns: 1fr; }
  .competitor-feature-grid { gap: 8px; }
  .competitor-help-strip > div { border-right: 0; border-bottom: 1px solid #eadfca; }
  .competitor-help-strip > div:last-child { border-bottom: 0; }
  .competitor-full-tutorial > summary { align-items: flex-start; flex-wrap: wrap; min-height: 0; padding: 13px; }
  .competitor-full-tutorial > summary > small { flex-basis: calc(100% - 28px); margin-left: 26px; }
  .competitor-full-tutorial > summary > svg { position: absolute; right: 14px; }
  .competitor-full-tutorial { position: relative; }
  .competitor-tutorial-body { grid-template-columns: 1fr; }
  .competitor-tutorial-body article, .competitor-tutorial-body article:nth-child(2n) { border-right: 0; border-bottom: 1px solid var(--ws-line); }
  .competitor-tutorial-body article:last-child { border-bottom: 0; }
  .workspace-price-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .competitor-image-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .workspace-check-in-hero { grid-template-columns: 1fr; }
  .workspace-check-in-copy { padding: 30px; }
  .workspace-check-in-scene { min-height: 300px; border-top: 1px solid rgba(17, 61, 48, .18); border-left: 0; }
  .workspace-check-in-days { grid-template-columns: repeat(7, minmax(76px, 1fr)); overflow-x: auto; padding-bottom: 6px; scroll-snap-type: x proximity; }
  .workspace-check-in-days article { scroll-snap-align: start; }
  .user-workbench-tabs { justify-content: flex-start; }
  .user-workbench-tabs button { flex-basis: 128px; }
  .user-finance-grid, .workspace-form-grid, .workspace-referral-grid, .media-tool-layout, .media-compressor-panel { grid-template-columns: 1fr; }
  .workspace-referral-transfer { grid-template-columns: 1fr; }
  .workspace-referral-transfer .workspace-section-head { grid-column: auto; }
  .media-canvas-stage, .media-compressor-preview { min-height: 420px; }
}

@media (max-width: 560px) {
  .workspace-notice-dialog-body { padding: 22px 18px; }
  .workspace-referral-poster-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
  .workspace-referral-poster-card > div:nth-child(2) { min-height: 58px; padding: 8px; }
  .workspace-referral-poster-actions button { font-size: 0; }
  .workspace-referral-poster-actions svg { width: 15px; height: 15px; }
  .workspace-metrics { grid-template-columns: 1fr 1fr; gap: 8px; }
  .workspace-metrics article { align-items: flex-start; flex-direction: column; min-height: 128px; padding: 14px; }
  .workspace-tool-grid { grid-template-columns: 1fr; }
  .workspace-price-grid, .roi-grid, .roi-results { grid-template-columns: 1fr; }
  .workspace-balance-hero { align-items: flex-start; flex-direction: column; gap: 20px; }
  .workspace-balance-hero .workspace-button { width: 100%; }
  .workspace-form-surface { padding: 16px; }
  .competitor-workflow { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .competitor-workflow li:nth-child(2) { border-right: 0; }
  .competitor-workflow li:nth-child(-n+2) { border-bottom: 1px solid var(--ws-line); }
  .competitor-workflow li::after { display: none; }
  .competitor-local-steps { grid-template-columns: 1fr; }
  .competitor-local-steps article, .competitor-local-steps article:nth-child(2n) { border-right: 0; border-bottom: 1px solid var(--ws-line); }
  .competitor-local-steps article:last-child { border-bottom: 0; }
  .media-control-grid, .media-export-actions { grid-template-columns: 1fr; }
  .workspace-pagination { justify-content: flex-start; flex-wrap: wrap; }
  .workspace-generator-toolbar { align-items: stretch; flex-direction: column; gap: 12px; }
  .workspace-platform-field { width: 100%; }
  .workspace-ai-fields { grid-template-columns: 1fr; }
  .workspace-field-wide { grid-column: auto; }
  .competitor-form-grid { grid-template-columns: 1fr; }
  .competitor-task-status { grid-template-columns: 1fr; }
  #competitorTaskLogs { grid-column: auto; }
  .automation-batch-toolbar, .automation-product-body { grid-template-columns: 1fr; }
  .automation-sku-table { grid-column: auto; }
  .automation-sku-table table, .automation-sku-table tbody { display: block; min-width: 0; }
  .automation-sku-table thead { display: none; }
  .automation-sku-table tr { position: relative; display: grid; grid-template-columns: 1fr 1fr; gap: 8px; padding: 12px 42px 12px 0; border-top: 1px solid #e1e7e9; }
  .automation-sku-table tr:first-child { border-top: 0; }
  .automation-sku-table td { display: grid; gap: 4px; padding: 0; }
  .automation-sku-table td::before { content: attr(data-label); color: var(--ws-muted); font-size: 9px; font-weight: 700; }
  .automation-sku-table td:nth-child(5) { grid-column: 1 / -1; }
  .automation-sku-table td:last-child { position: absolute; top: 31px; right: 0; }
  .automation-sku-table td:last-child::before { display: none; }
  .automation-task-meta .workspace-status { margin-left: 0; }
  .workspace-browser-dialog { width: 100vw; max-height: 100vh; border-radius: 0; }
  .workspace-browser-controls { grid-template-columns: 1fr 1fr; }
  .workspace-browser-controls input { grid-column: 1 / -1; }
  .workspace-main { padding-bottom: 96px; }
  .workspace-form-actions { align-items: stretch; flex-direction: column; }
  .workspace-inline-field { grid-template-columns: 1fr; }
  .competitor-results { padding: 13px; }
  .competitor-results-head { align-items: flex-start; flex-direction: column; }
  .competitor-results-head > div:last-child { width: 100%; justify-content: space-between; }
  .competitor-image-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .referral-summary { grid-template-columns: 1fr; }
  .workspace-referral-copy-group { grid-template-columns: 1fr; }
  .workspace-referral-link-panel { grid-template-columns: 1fr; gap: 16px; }
  .workspace-referral-qr { border-top: 1px solid var(--ws-line); border-left: 0; padding: 16px 0 0; }
  .workspace-referral-copy-group > .workspace-button { min-height: 42px; }
  .workspace-account-row { align-items: flex-start; flex-wrap: wrap; }
  .workspace-status { margin-left: 65px; }
  .workspace-leaf-chip small { display: none; }
  .workspace-check-in-copy { padding: 26px 20px; }
  .workspace-check-in-copy h2 { font-size: 24px; }
  .workspace-check-in-stats > span { padding: 0 12px; }
  .workspace-check-in-stats b { font-size: 20px; }
  .workspace-button.check-in-action { width: 100%; min-width: 0; }
  .workspace-check-in-scene { min-height: 260px; }
  .workspace-check-in-scene img { width: min(220px, 78%); }
  .workspace-check-in-reward { top: 16px; right: 16px; }
  .workspace-toast { right: 12px; bottom: 76px; }
  .workspace-embedded-tool-view .workspace-page-heading { margin-bottom: 10px; }
  .workspace-embedded-workbench > .panel { padding: 14px; }
  .workspace-embedded-workbench .flow-grid { grid-template-columns: 1fr; }
  .workspace-embedded-workbench[data-embedded-tool="video"] .workbench-upload-pair,
  .workspace-embedded-workbench[data-embedded-tool="video"] .workbench-upload-pair.has-face-upload { grid-template-columns: 1fr; }
  .workspace-embedded-workbench[data-embedded-tool="video"] .production-direction-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .workspace-embedded-workbench[data-embedded-tool="video"] .video-spec-strip { grid-template-columns: 1fr; }
  /* The workspace sidebar already exposes referral rewards. A fixed mobile duplicate can cover task form controls. */
  body.workspace-page .referral-fab { display: none; }
}

/* Unified RMB wallet and embedded workbench presentation. */
.workspace-balance-chip,
.workspace-top-recharge {
  height: 38px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border-radius: 6px;
  cursor: pointer;
}

.workspace-balance-chip {
  min-width: 132px;
  padding: 0 12px;
  color: #174f3b;
  background: #edf8f2;
  border: 1px solid #bedfcd;
}

.workspace-balance-chip svg { width: 16px; height: 16px; }
.workspace-balance-chip span { color: #597066; font-size: 11px; }
.workspace-balance-chip strong { margin-left: auto; font-size: 14px; font-variant-numeric: tabular-nums; }
.workspace-top-recharge { padding: 0 12px; color: #fff; background: var(--ws-primary); border: 1px solid var(--ws-primary); font-weight: 800; }
.workspace-top-recharge svg { width: 15px; height: 15px; }

.workspace-embedded-tool-shell { display: grid; gap: 14px; }
.workspace-embedded-tool-shell .workbench-page-announcement { width: 100%; margin: 0; }
.workspace-embedded-tool-shell .workspace-embedded-workbench { grid-template-columns: minmax(0, 64fr) minmax(320px, 36fr); gap: 20px; }

.workspace-recharge-dialog {
  width: min(560px, calc(100vw - 28px));
  max-height: min(760px, calc(100vh - 28px));
  margin: auto;
  padding: 0;
  overflow: auto;
  color: var(--ws-text);
  background: #fff;
  border: 1px solid #d8dde1;
  border-radius: 12px;
  box-shadow: 0 28px 90px rgba(11, 18, 25, .32);
}

.workspace-recharge-dialog::backdrop { background: rgba(8, 13, 18, .58); backdrop-filter: blur(4px); }
.workspace-recharge-head { display: flex; justify-content: space-between; gap: 18px; padding: 20px; border-bottom: 1px solid var(--ws-line); }
.workspace-recharge-head p, .workspace-recharge-head h2 { margin: 0; }
.workspace-recharge-head p { color: var(--ws-primary); font-size: 10px; font-weight: 900; }
.workspace-recharge-head h2 { margin-top: 3px; font-size: 21px; }
.workspace-recharge-head span { display: block; margin-top: 5px; color: var(--ws-muted); font-size: 11px; }
.workspace-recharge-balance { display: flex; align-items: center; justify-content: space-between; margin: 18px 20px 10px; padding: 14px 16px; color: #174f3b; background: #edf8f2; border: 1px solid #c6e1d1; border-radius: 7px; }
.workspace-recharge-balance strong { font-size: 24px; font-variant-numeric: tabular-nums; }
.workspace-recharge-packages { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 9px; padding: 10px 20px 20px; }
.workspace-recharge-packages > p { grid-column: 1 / -1; margin: 0; padding: 20px; color: var(--ws-muted); text-align: center; }
.workspace-recharge-packages button { min-height: 76px; display: grid; place-items: center; gap: 5px; padding: 10px; color: var(--ws-text); background: #fff; border: 1px solid var(--ws-line); border-radius: 7px; cursor: pointer; }
.workspace-recharge-packages button:hover { border-color: var(--ws-primary); background: #f1f8f5; }
.workspace-recharge-packages button strong { font-size: 20px; }
.workspace-recharge-packages button span { color: var(--ws-muted); font-size: 10px; }
.workspace-recharge-dialog.is-paying .workspace-recharge-balance,
.workspace-recharge-dialog.is-paying .workspace-recharge-packages { display: none; }
.workspace-payment-result {
  display: block;
  margin: 0;
  padding: 26px 24px 30px;
  text-align: center;
  background: #fff;
  border: 0;
}
.workspace-payment-result[hidden] { display: none; }
.workspace-payment-checkout { display: grid; justify-items: center; max-width: 360px; margin: 0 auto; }
.workspace-payment-brand { display: inline-flex; align-items: center; gap: 7px; color: #1b7f4c; font-size: 13px; font-weight: 900; }
.workspace-payment-brand .workspace-wechat-logo { width: 28px; height: 28px; object-fit: contain; border: 0; background: transparent; }
.workspace-payment-amount-label { margin-top: 16px; color: #7a838b; font-size: 12px; }
.workspace-payment-amount { margin-top: 2px; color: #16191d; font-size: 34px; line-height: 1.2; font-variant-numeric: tabular-nums; }
.workspace-payment-title { margin-top: 18px; color: #20252a; font-size: 16px; }
.workspace-payment-qr-frame { margin-top: 12px; padding: 12px; border: 1px solid #e1e5e8; border-radius: 10px; background: #fff; box-shadow: 0 8px 24px rgba(20, 31, 37, .08); }
#workspacePaymentQr { display: block; width: 220px; height: 220px; margin: 0 auto; object-fit: contain; background: #fff; }
.workspace-payment-countdown { min-width: 132px; margin-top: 16px; padding: 7px 12px; color: #b54708; border: 1px solid #fed7aa; border-radius: 999px; background: #fff7ed; font-size: 13px; font-weight: 900; font-variant-numeric: tabular-nums; }
.workspace-payment-status { margin-top: 11px; color: #326247; font-size: 12px; line-height: 1.6; }
.workspace-payment-order { max-width: 100%; margin-top: 7px; color: #8a9299; font-size: 10px; word-break: break-all; }

@media (max-width: 1100px) {
  .workspace-embedded-tool-shell .workspace-embedded-workbench { grid-template-columns: 1fr; }
}

@media (max-width: 820px) {
  .workspace-topbar-actions > .workspace-balance-chip { display: inline-flex !important; }
  .workspace-topbar-actions > .workspace-top-recharge { display: inline-flex !important; }
  .workspace-balance-chip { min-width: 86px; padding: 0 8px; }
  .workspace-balance-chip span, .workspace-balance-chip svg, .workspace-top-recharge svg { display: none; }
  .workspace-top-recharge { padding: 0 9px; }
  .workspace-recharge-packages { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .workspace-payment-result { padding: 22px 16px 26px; }
  #workspacePaymentQr { width: min(220px, 68vw); height: min(220px, 68vw); }
}

/* Persisted multi-SKU ROI workbench. */
.commerce-tool-workbench { display: grid; grid-template-columns: minmax(300px, 40%) minmax(0, 1fr); align-items: stretch; gap: 14px; }
.commerce-settings-panel { display: flex; min-width: 0; flex-direction: column; padding: 20px; }
.commerce-panel-title, .commerce-output-head { display: flex; align-items: center; justify-content: space-between; gap: 14px; }
.commerce-panel-title { padding-bottom: 16px; border-bottom: 1px solid var(--ws-line); }
.commerce-panel-title strong, .commerce-panel-title small { display: block; }
.commerce-panel-title strong { color: var(--ws-text); font-size: 15px; }
.commerce-panel-title small { margin-top: 4px; color: var(--ws-muted); font-size: 11px; }
.commerce-tool-icon { display: grid; width: 36px; height: 36px; flex: 0 0 auto; place-items: center; border: 1px solid #d7e3fb; border-radius: 6px; color: #2f68be; background: #edf4ff; }
.commerce-tool-icon.sku { border-color: #d2e7dd; color: #297455; background: #edf8f2; }
.commerce-tool-icon svg { width: 18px; height: 18px; }
.commerce-generator-form { display: grid; gap: 14px; margin-top: 18px; }
.commerce-platform-field { min-width: 0; margin: 0; padding: 0; border: 0; }
.commerce-platform-field legend { margin-bottom: 8px; color: var(--ws-muted); font-size: 11px; font-weight: 800; }
.commerce-platform-chips { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 7px; }
.commerce-platform-chips button { min-height: 34px; padding: 0 8px; border: 1px solid var(--ws-line); border-radius: 5px; color: var(--ws-muted); background: #fff; font: inherit; font-size: 11px; cursor: pointer; }
.commerce-platform-chips button:hover, .commerce-platform-chips button.is-active { border-color: #4c8e73; color: #195c43; background: #edf8f2; font-weight: 800; }
.commerce-form-row { display: grid; grid-template-columns: minmax(0, 1fr) 112px; gap: 10px; }
.commerce-form-row.single-count { grid-template-columns: 112px; }
.commerce-count-field input { font-variant-numeric: tabular-nums; }
.commerce-rule-note { display: flex; align-items: center; gap: 7px; min-height: 34px; padding: 8px 10px; border: 1px solid #d5e7dd; border-radius: 5px; color: #216847; background: #f2faf5; font-size: 10px; }
.commerce-rule-note svg { width: 15px; height: 15px; flex: 0 0 auto; }
.commerce-generate-button { width: 100%; min-height: 42px; }
.commerce-inline-status { min-height: 17px; margin: -4px 0 0; color: var(--ws-muted); font-size: 10px; }
.commerce-inline-status.is-error { color: #b13e33; }.commerce-inline-status.is-success { color: #1f744e; }.commerce-inline-status.is-loading { color: #3569a7; }
.commerce-output-panel { min-width: 0; padding: 20px; border: 1px solid var(--ws-line); border-radius: 7px; background: #fff; }
.commerce-output-head { min-height: 42px; padding-bottom: 15px; border-bottom: 1px solid var(--ws-line); }
.commerce-output-head p, .commerce-output-head h2 { margin: 0; }.commerce-output-head p { color: var(--ws-primary); font-size: 9px; font-weight: 900; }.commerce-output-head h2 { margin-top: 3px; font-size: 17px; }.workspace-button.compact { min-height: 34px; padding: 0 10px; font-size: 11px; }
.commerce-result-list { display: grid; gap: 9px; margin-top: 14px; }.commerce-empty { display: grid; min-height: 235px; place-content: center; gap: 8px; margin: 0; color: var(--ws-muted); text-align: center; }.commerce-empty svg { width: 24px; height: 24px; margin: 0 auto; color: #8aa79a; }.commerce-empty strong, .commerce-empty span { display: block; }.commerce-empty strong { color: var(--ws-text); font-size: 13px; }.commerce-empty span { font-size: 10px; }
.commerce-result-item { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-width: 0; padding: 13px; border: 1px solid #e0e8e4; border-radius: 6px; background: #fbfcfc; }.commerce-result-copy { display: flex; min-width: 0; align-items: flex-start; gap: 10px; }.commerce-result-copy > span { display: grid; width: 25px; height: 25px; flex: 0 0 auto; place-items: center; border-radius: 5px; color: #477a61; background: #e8f4ed; font-size: 10px; font-weight: 800; }.commerce-result-copy strong { display: block; color: var(--ws-text); font-size: 13px; line-height: 1.5; word-break: break-word; }.commerce-result-copy p { margin: 4px 0 0; color: var(--ws-muted); font-size: 10px; }.commerce-result-meta { display: flex; align-items: center; flex: 0 0 auto; gap: 8px; }.commerce-result-meta > span { padding: 4px 6px; border-radius: 4px; font-size: 9px; font-weight: 800; white-space: nowrap; }.commerce-result-meta > span.is-compliant { color: #1d714c; background: #e7f6ed; }.commerce-result-meta > span.is-warning { color: #9a641b; background: #fff5dc; }.commerce-result-meta small { color: var(--ws-muted); font-size: 9px; white-space: nowrap; }
@media (max-width: 900px) { .commerce-tool-workbench { grid-template-columns: 1fr; } .commerce-empty { min-height: 150px; } }
@media (max-width: 560px) { .commerce-settings-panel, .commerce-output-panel { padding: 15px; }.commerce-form-row, .commerce-form-row.single-count { grid-template-columns: 1fr; }.commerce-result-item, .commerce-result-meta { align-items: flex-start; flex-direction: column; }.commerce-result-meta { gap: 6px; } }
.roi-sku-workbench { overflow: hidden; border: 1px solid var(--ws-line); border-radius: 7px; background: #fff; }
.roi-sku-head { display: flex; min-height: 88px; align-items: center; justify-content: space-between; gap: 20px; padding: 18px 22px; border-bottom: 1px solid var(--ws-line); background: #f7faf8; }
.roi-sku-head p, .roi-sku-head h2, .roi-sku-head span { margin: 0; }
.roi-sku-head p, .roi-summary-head p { color: var(--ws-primary); font-size: 9px; font-weight: 800; }
.roi-sku-head h2 { margin-top: 3px; font-size: 18px; }
.roi-sku-head > div > span { display: block; margin-top: 4px; color: var(--ws-muted); font-size: 10px; }
.roi-live-badge { display: inline-flex; align-items: center; gap: 6px; padding: 7px 10px; border: 1px solid #cce2d5; border-radius: 5px; color: #1f674c; background: #e8f4ed; font-size: 10px; font-weight: 800; white-space: nowrap; }
.roi-live-badge svg { width: 14px; height: 14px; }
.roi-table-scroll { width: 100%; overflow-x: auto; scrollbar-width: thin; }
.roi-sku-table { min-width: 900px; padding: 0 18px; }
.roi-table-header, .roi-table-row { display: grid; grid-template-columns: minmax(160px, 1.45fr) repeat(3, minmax(108px, 1fr)) repeat(2, minmax(120px, 1fr)) 38px; align-items: center; gap: 8px; }
.roi-table-header { min-height: 45px; border-bottom: 1px solid #e7ece9; color: #7a8781; font-size: 9px; font-weight: 800; }
.roi-table-row { min-height: 67px; border-bottom: 1px solid #edf1ef; }
.roi-table-row:last-child { border-bottom: 0; }
.roi-table-row label { min-width: 0; }
.roi-table-row label > span, .roi-table-row output > span { display: none; }
.roi-table-row input { width: 100%; min-width: 0; height: 38px; padding: 0 10px; border: 1px solid #d8e0dc; border-radius: 5px; color: var(--ws-text); background: #fbfcfc; font: inherit; font-size: 11px; }
.roi-table-row input:focus { outline: 3px solid rgba(39, 128, 99, 0.13); border-color: #59967f; background: #fff; }
.roi-table-row output { min-width: 0; text-align: center; }
.roi-table-row output strong { color: #1e5d46; font-size: 13px; }
.roi-table-row.is-loss output strong { color: #a23d33; }
.roi-delete-button { display: grid; width: 32px; height: 32px; place-items: center; border: 0; border-radius: 4px; color: #9aa49f; background: transparent; cursor: pointer; }
.roi-delete-button:hover { color: #a23d33; background: #fff0ed; }
.roi-delete-button svg { width: 15px; height: 15px; }
.roi-table-actions { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 16px 18px; border-top: 1px solid var(--ws-line); background: #fbfcfc; }
.roi-table-actions > div { display: flex; flex-wrap: wrap; gap: 8px; }
.roi-table-actions .workspace-button { min-height: 38px; }
.roi-calculate-button { min-width: 150px; }
.roi-submit-status { min-height: 31px; margin: 0; padding: 8px 20px; border-top: 1px solid #edf1ef; color: var(--ws-muted); background: #fbfcfc; text-align: right; font-size: 9px; }
.roi-submit-status.is-success { color: #176044; font-weight: 800; }
.roi-summary-panel { margin-top: 12px; padding: 18px; border: 1px solid var(--ws-line); border-radius: 7px; background: #fff; }
.roi-summary-head { display: flex; align-items: end; justify-content: space-between; gap: 16px; }
.roi-summary-head p, .roi-summary-head h2 { margin: 0; }
.roi-summary-head h2 { margin-top: 3px; font-size: 16px; }
.roi-summary-head > span { color: var(--ws-muted); font-size: 10px; }
.roi-summary-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 9px; margin-top: 14px; }
.roi-summary-grid article { min-height: 104px; padding: 16px; border: 1px solid #e0e8e4; border-radius: 6px; background: #f7faf8; }
.roi-summary-grid span, .roi-summary-grid strong, .roi-summary-grid small { display: block; }
.roi-summary-grid span { color: var(--ws-muted); font-size: 10px; }
.roi-summary-grid strong { margin-top: 7px; color: #174d3a; font-size: 22px; }
.roi-summary-grid small { margin-top: 5px; color: #89948f; font-size: 9px; }

@media (max-width: 760px) {
  .roi-sku-head { align-items: flex-start; flex-direction: column; gap: 10px; padding: 16px; }
  .roi-table-actions { align-items: stretch; flex-direction: column; }
  .roi-table-actions > div { display: grid; grid-template-columns: 1fr 1fr; }
  .roi-table-actions > div .ghost-danger { grid-column: 1 / -1; }
  .roi-calculate-button { width: 100%; }
  .roi-submit-status { text-align: center; }
  .roi-summary-head { align-items: flex-start; flex-direction: column; gap: 5px; }
  .roi-summary-grid { grid-template-columns: 1fr; }
}

.video-remake-layout { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(320px, .65fr); gap: 14px; align-items: start; }
.video-remake-form { display: grid; gap: 14px; padding: 18px; }
.video-remake-task-track { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); margin: 0; padding: 14px 10px; list-style: none; border: 1px solid #b9dce7; border-radius: 7px; background: #f0fbfe; }
.video-remake-task-track li { position: relative; display: grid; place-items: center; gap: 7px; min-width: 0; color: #667585; font-size: 8px; font-weight: 800; text-align: center; }
.video-remake-task-track li:not(:last-child)::after { content: ""; position: absolute; z-index: 0; top: 12px; left: calc(50% + 12px); width: calc(100% - 24px); height: 2px; background: #b9dce7; }
.video-remake-task-track i { position: relative; z-index: 1; display: grid; place-items: center; width: 25px; height: 25px; color: #fff; background: #a6b4c0; border-radius: 7px; font-style: normal; font-size: 9px; }
.video-remake-task-track li.is-complete, .video-remake-task-track li.is-current { color: #087ba2; }
.video-remake-task-track li.is-complete i, .video-remake-task-track li.is-current i { background: #06a4d3; }
.video-remake-task-track li.is-complete:not(:last-child)::after { background: #06a4d3; }
.video-remake-task-track li.is-failed { color: #b42336; }
.video-remake-task-track li.is-failed i { background: #d34a5d; }
.video-remake-current-task { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 3px 10px; align-items: center; padding: 10px 12px; color: #3f4d5c; border: 1px solid #dce4ec; border-radius: 7px; background: #f8fafc; }
.video-remake-current-task > span { grid-row: 1 / 3; padding: 5px 7px; color: #087ba2; background: #e4f7fc; border-radius: 5px; font-size: 8px; font-weight: 800; }
.video-remake-current-task strong { min-width: 0; overflow: hidden; font-size: 10px; text-overflow: ellipsis; white-space: nowrap; }
.video-remake-current-task small { color: var(--ws-muted); font-size: 8px; }
.video-remake-current-task.is-failed > span { color: #a52c3f; background: #fdecef; }
.video-remake-current-task.is-completed > span { color: #17694f; background: #e6f5ef; }
.video-remake-section { display: grid; gap: 10px; }
.video-remake-section + .video-remake-section { padding-top: 14px; border-top: 1px solid var(--ws-line); }
.video-remake-section-title { display: flex; gap: 9px; align-items: center; }
.video-remake-section-title > b { display: grid; place-items: center; width: 30px; height: 30px; color: #fff; background: #24213e; border-radius: 7px; font-size: 10px; }
.video-remake-section-title strong, .video-remake-section-title small { display: block; }
.video-remake-section-title strong { color: var(--ws-text); font-size: 13px; }
.video-remake-section-title small { margin-top: 2px; color: var(--ws-muted); font-size: 9px; }
.video-remake-modes { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.video-remake-modes label { display: grid; grid-template-columns: 35px minmax(0, 1fr); gap: 9px; align-items: center; min-height: 72px; padding: 11px; border: 1px solid #dfe4ef; border-radius: 7px; background: #fbfcff; cursor: pointer; transition: border-color 150ms ease, background 150ms ease, box-shadow 150ms ease; }
.video-remake-modes label.is-active { border-color: #6f63d9; background: #f5f3ff; box-shadow: inset 0 0 0 1px rgba(111, 99, 217, .12); }
.video-remake-modes input, .video-remake-durations input { position: absolute; opacity: 0; pointer-events: none; }
.video-remake-modes svg { width: 22px; height: 22px; color: #6861b8; }
.video-remake-modes strong, .video-remake-modes small { display: block; }
.video-remake-modes strong { color: #25283a; font-size: 11px; }
.video-remake-modes small { margin-top: 4px; color: #7d8394; font-size: 8px; line-height: 1.45; }
.video-remake-built-in-note { display: flex; align-items: center; gap: 7px; margin: 0; padding: 8px 10px; color: #40526a; border: 1px solid #dce5ef; border-radius: 6px; background: #f7fafc; font-size: 9px; line-height: 1.45; }
.video-remake-built-in-note svg { flex: 0 0 auto; width: 15px; height: 15px; color: #27755f; }
.video-remake-uploads { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.video-remake-upload { display: grid; grid-template-columns: 38px minmax(0, 1fr); gap: 10px; align-items: center; min-height: 72px; padding: 12px; border: 1px dashed #c9cfdd; border-radius: 7px; background: #fbfcfe; cursor: pointer; }
.video-remake-upload input { display: none; }
.video-remake-upload svg { width: 24px; color: #5c65aa; }
.video-remake-upload strong, .video-remake-upload small { display: block; }
.video-remake-upload strong { font-size: 11px; }
.video-remake-upload small { margin-top: 4px; overflow-wrap: anywhere; color: var(--ws-muted); font-size: 8px; }
.video-remake-durations { display: flex; flex-wrap: nowrap; gap: 7px; overflow-x: auto; scrollbar-width: none; }
.video-remake-durations label { flex: 1 1 0; min-width: 84px; cursor: pointer; }
.video-remake-durations span { display: grid; place-items: center; min-height: 56px; padding: 8px; border: 1px solid #dce1eb; border-radius: 7px; background: #fbfcfe; }
.video-remake-durations label.is-active span { color: #fff; border-color: #393453; background: #393453; }
.video-remake-durations label.is-disabled { cursor: not-allowed; opacity: .4; }
.video-remake-durations strong { font-size: 13px; }
.video-remake-durations small { margin-top: 3px; font-size: 8px; }
.video-remake-clip-note { margin: 0; padding: 8px 10px; color: #5f6180; background: #f2f2f8; border-radius: 6px; font-size: 9px; text-align: center; }
.video-remake-requirements small { color: var(--ws-muted); }
.video-remake-authorization { display: flex; gap: 9px; align-items: flex-start; padding: 11px; color: #46485c; background: #f7f7fb; border: 1px solid #e1e1eb; border-radius: 7px; }
.video-remake-authorization input { width: 16px; height: 16px; margin: 1px 0 0; accent-color: #5c52be; }
.video-remake-authorization strong, .video-remake-authorization small { display: block; }
.video-remake-authorization strong { font-size: 10px; }
.video-remake-authorization small { margin-top: 4px; color: #7b7d8e; font-size: 8px; line-height: 1.5; }
.video-remake-quote { display: grid; place-items: center; gap: 3px; padding: 13px; color: #25243b; background: linear-gradient(110deg, #f3f0ff, #f4f8ff); border: 1px solid #dcd6f6; border-radius: 7px; text-align: center; }
.video-remake-quote span, .video-remake-quote small { color: #747389; font-size: 8px; }
.video-remake-quote strong { font-size: 14px; }
.video-remake-submit { width: 100%; justify-content: center; }
.video-remake-tasks { min-height: 330px; padding: 16px; border: 1px solid var(--ws-line); border-radius: 7px; background: #fff; }
.video-remake-tasks > header { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding-bottom: 13px; border-bottom: 1px solid var(--ws-line); }
.video-remake-tasks p, .video-remake-tasks h2 { margin: 0; }
.video-remake-tasks h2 { margin-top: 3px; font-size: 14px; }
.video-remake-tasks header p { color: #6660b2; font-size: 8px; font-weight: 800; }
.video-remake-task-group { padding-top: 14px; }
.video-remake-task-group + .video-remake-task-group { margin-top: 14px; border-top: 1px solid var(--ws-line); }
.video-remake-task-group-title { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.video-remake-task-group-title > div { display: flex; align-items: center; gap: 7px; min-width: 0; }
.video-remake-task-group-title svg { width: 15px; height: 15px; color: #5d55ba; }
.video-remake-task-group-title h3 { margin: 0; color: #303244; font-size: 11px; }
.video-remake-task-group-title small { color: var(--ws-muted); font-size: 8px; }
.video-remake-task { display: grid; gap: 10px; margin-top: 13px; padding: 13px; border: 1px solid #e0e3ec; border-radius: 7px; background: #fafbfe; }
.video-remake-task header { display: grid; grid-template-columns: auto 1fr auto; gap: 8px; align-items: center; }
.video-remake-task header span { padding: 4px 6px; color: #514aa6; background: #eeecff; border-radius: 4px; font-size: 8px; font-weight: 800; }
.video-remake-task header b { font-size: 10px; }
.video-remake-task header small { color: #bc3048; font-size: 9px; font-weight: 800; }
.video-remake-task progress { width: 100%; height: 6px; accent-color: #665cd0; }
.video-remake-task > p { color: #686b7a; font-size: 9px; line-height: 1.5; }
.video-remake-task > div { display: flex; align-items: center; justify-content: space-between; gap: 8px; color: #7a7d8b; font-size: 8px; }
.video-remake-retention { margin: 12px 0 0 !important; padding: 9px 10px; color: #b42318; border: 1px solid #f2c6c3; border-radius: 6px; background: #fff8f7; font-size: 9px; font-weight: 700; line-height: 1.5; }
.video-remake-history-date { display: grid; grid-template-columns: minmax(0, .8fr) minmax(150px, 1.2fr); gap: 10px; align-items: end; margin-top: 10px; padding: 10px; border: 1px solid #dfe4eb; border-radius: 7px; background: #fbfcfe; }
.video-remake-history-date span, .video-remake-history-date strong { display: block; }
.video-remake-history-date span { color: #66717e; font-size: 8px; }
.video-remake-history-date strong { margin-top: 3px; font-size: 13px; }
.video-remake-history-date input { width: 100%; min-height: 38px; margin-top: 4px; padding: 0 9px; border: 1px solid #d8dee8; border-radius: 6px; background: #fff; color: #25283a; font-size: 11px; }
.video-remake-history-status-tabs { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 7px; margin-top: 9px; }
.video-remake-history-status-tabs button { display: flex; align-items: center; justify-content: space-between; gap: 5px; min-width: 0; min-height: 44px; padding: 8px; color: #39445a; border: 1px solid #dce2ea; border-radius: 7px; background: #f8fafc; cursor: pointer; font-size: 9px; font-weight: 800; }
.video-remake-history-status-tabs button strong { display: grid; place-items: center; min-width: 24px; height: 24px; padding: 0 5px; background: rgba(255,255,255,.75); border-radius: 12px; }
.video-remake-history-status-tabs button.is-active { border-color: #8ca4ff; box-shadow: inset 0 0 0 1px rgba(91,104,220,.15); }
.video-remake-history-status-tabs .is-submitted { color: #344cb7; background: #f1f4ff; }
.video-remake-history-status-tabs .is-generating { color: #9a5f04; background: #fff8e9; }
.video-remake-history-status-tabs .is-completed { color: #087347; background: #eaf8f1; }
.video-remake-history-actions { display: grid; grid-template-columns: minmax(0, 1.15fr) repeat(3, minmax(76px, 1fr)); gap: 6px; margin-top: 9px; }
.video-remake-history-actions > div { display: grid; gap: 3px; }
.video-remake-history-actions small { padding-left: 5px; color: #5366cc; font-size: 8px; }
.video-remake-history-actions .workspace-button { justify-content: center; min-width: 0; padding-inline: 7px; }
.video-remake-history-actions button:disabled { cursor: not-allowed; opacity: .45; }
.video-remake-history-list { display: grid; gap: 8px; margin-top: 10px; max-height: 620px; overflow-y: auto; overscroll-behavior: contain; scrollbar-width: thin; }
.video-remake-history-item { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px 10px; align-items: center; padding: 11px; border: 1px solid #e4e6ed; border-radius: 7px; background: #fcfcfe; }
.video-remake-history-item.is-failed, .video-remake-history-item.is-partial_failed, .video-remake-history-item.is-refunded, .video-remake-history-item.is-cancelled { border-color: #f1b8b6; background: #fff7f6; }
.video-remake-history-item.is-segment_generating, .video-remake-history-item.is-merging, .video-remake-history-item.is-uploading { border-color: #ebcc8d; background: #fffaf0; }
.video-remake-history-copy { min-width: 0; }
.video-remake-history-copy strong, .video-remake-history-copy small { display: block; }
.video-remake-history-copy strong { overflow: hidden; color: #303244; font-size: 10px; text-overflow: ellipsis; white-space: nowrap; }
.video-remake-history-copy small { margin-top: 4px; color: var(--ws-muted); font-size: 8px; }
.video-remake-history-status { justify-self: end; padding: 4px 6px; color: #514aa6; border-radius: 4px; background: #eeecff; font-size: 8px; font-weight: 800; }
.video-remake-history-status.is-completed { color: #17694f; background: #e6f5ef; }
.video-remake-history-status.is-failed, .video-remake-history-status.is-refunded, .video-remake-history-status.is-cancelled { color: #a63848; background: #fbecef; }
.video-remake-history-meta { display: flex; flex-wrap: wrap; gap: 5px 10px; color: #777a89; font-size: 8px; }
.video-remake-history-detail { grid-column: 1 / -1; margin: 0; padding: 8px; color: #5e6471; border-radius: 5px; background: rgba(255,255,255,.72); font-size: 8px; line-height: 1.5; }
.video-remake-history-card-actions { grid-column: 1 / -1; display: flex; flex-wrap: wrap; gap: 6px; }
.video-remake-history-card-actions button, .video-remake-history-card-actions a { min-height: 30px; padding: 0 8px; border: 1px solid #d8dee7; border-radius: 5px; background: #fff; color: #3f4b5e; cursor: pointer; font-size: 8px; font-weight: 800; }
.video-remake-history-card-actions .danger { color: #b42332; border-color: #f0bbb8; background: #fff4f3; }
.video-remake-history-card-actions .primary { color: #fff; border-color: #4459cb; background: #566bdc; }
.video-remake-history-pager { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: 10px; color: #687386; font-size: 8px; }
.video-remake-history-pager > div { display: flex; gap: 5px; }
.video-remake-history-pager button { min-width: 29px; min-height: 29px; border: 1px solid #dce2ea; border-radius: 5px; background: #fff; color: #465165; cursor: pointer; font-size: 8px; }
.video-remake-history-pager button.is-active { color: #fff; border-color: #5367d2; background: #5367d2; }

@media (max-width: 1180px) {
  .video-remake-layout { grid-template-columns: 1fr; }
  .media-dedupe-layout { grid-template-columns: minmax(280px, .85fr) minmax(420px, 1.15fr); }
  .media-dedupe-report { grid-column: 1 / -1; }
  .media-dedupe-report > div { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
  .media-dedupe-summary-metrics { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .media-dedupe-summary-metrics > span:nth-child(3) { border-right: 0; }
  .media-dedupe-summary-metrics > span:nth-child(-n+3) { border-bottom: 1px solid var(--ws-line); }
  .media-dedupe-history-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .media-dedupe-quality { border-bottom: 0; }
}

@media (max-width: 760px) {
  .video-remake-form { padding: 13px; }
  .video-remake-task-track { padding-inline: 4px; }
  .video-remake-task-track li span { font-size: 7px; }
  .video-remake-task-track li:not(:last-child)::after { left: calc(50% + 10px); width: calc(100% - 20px); }
  .video-remake-modes, .video-remake-uploads { grid-template-columns: 1fr; }
  .video-remake-durations { margin-right: -2px; }
  .video-remake-history-actions { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .video-remake-history-date { grid-template-columns: 1fr; }
  .media-dedupe-view { margin: 0 -14px -18px; padding: 14px 14px 18px; }
  .media-dedupe-summary-metrics { grid-template-columns: repeat(2, minmax(0, 1fr)); margin-top: -5px; }
  .media-dedupe-summary-metrics > span, .media-dedupe-summary-metrics > span:nth-child(3) { border-right: 1px solid var(--ws-line); border-bottom: 1px solid var(--ws-line); }
  .media-dedupe-summary-metrics > span:nth-child(2n) { border-right: 0; }
  .media-dedupe-summary-metrics > span:nth-last-child(-n+2) { border-bottom: 0; }
  .media-dedupe-heading { align-items: flex-start; flex-direction: column; }
  .media-dedupe-engine-state { width: 100%; }
  .media-dedupe-layout { grid-template-columns: 1fr; }
  .media-dedupe-report { grid-column: auto; }
  .media-dedupe-report > div { display: block; }
  .media-dedupe-report > .media-dedupe-compare { display: grid; }
  .media-dedupe-card > header { min-height: 64px; }
  .media-dedupe-log { height: 175px; }
  .media-dedupe-pipeline { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .media-dedupe-history > header { align-items: flex-start; flex-direction: column; }
  .media-dedupe-history-list { grid-template-columns: 1fr; }
}
