:root {
  color-scheme: light dark;
  --desktop-bg: #edf3fa;
  --desktop-surface: rgba(255, 255, 255, 0.78);
  --desktop-surface-strong: rgba(255, 255, 255, 0.92);
  --desktop-surface-soft: rgba(246, 249, 253, 0.78);
  --desktop-border: rgba(130, 152, 179, 0.24);
  --desktop-border-strong: rgba(104, 126, 155, 0.34);
  --desktop-text: #0b1220;
  --desktop-muted: #60708a;
  --desktop-primary: #0a84ff;
  --desktop-primary-strong: #0066d6;
  --desktop-primary-soft: rgba(10, 132, 255, 0.12);
  --desktop-danger: #ff3b30;
  --desktop-warn: #ff9f0a;
  --desktop-ok: #30a46c;
  --desktop-new-analysis-bg: linear-gradient(90deg, rgba(10, 132, 255, 0.10), rgba(10, 132, 255, 0.035) 52%, rgba(10, 132, 255, 0) 100%);
  --desktop-new-analysis-bg-hover: linear-gradient(90deg, rgba(10, 132, 255, 0.135), rgba(10, 132, 255, 0.045) 54%, rgba(10, 132, 255, 0) 100%);
  --desktop-new-analysis-text: #075a9f;
  --desktop-new-analysis-border: rgba(10, 132, 255, 0.24);
  --desktop-new-analysis-pill-bg: linear-gradient(180deg, rgba(255, 255, 255, 0.94), rgba(238, 247, 255, 0.82));
  --desktop-new-analysis-glow: rgba(10, 132, 255, 0.18);
  --desktop-shadow: 0 18px 48px rgba(28, 42, 60, 0.12), 0 1px 0 rgba(255, 255, 255, 0.72) inset;
  --desktop-shadow-soft: 0 8px 24px rgba(28, 42, 60, 0.08);
  --desktop-blur: saturate(180%) blur(22px);
  --desktop-sidebar-handle-bg: rgba(238, 245, 253, 0.94);
}

* {
  box-sizing: border-box;
}

html,
body {
  width: 100%;
  height: 100%;
  margin: 0;
}

body.desktop-page {
  overflow: hidden;
  background:
    radial-gradient(circle at 18% 0%, rgba(255, 255, 255, 0.92), transparent 31%),
    linear-gradient(135deg, #f8fbff 0%, #edf4fb 38%, #f5f1ff 100%);
  color: var(--desktop-text);
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "SF Pro Display", "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
  font-size: 14px;
  -webkit-font-smoothing: antialiased;
  text-rendering: geometricPrecision;
}

body.desktop-page.modal-open,
body.review-modal-open,
body.journey-modal-open,
body.drill-modal-open {
  overflow: hidden;
}

button,
input,
select,
textarea {
  font: inherit;
}

button,
a,
select {
  touch-action: manipulation;
}

.hidden {
  display: none !important;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
}

.desktop-shell {
  --desktop-sidebar-width: 176px;
  position: relative;
  width: 100%;
  height: 100vh;
  display: grid;
  grid-template-columns: var(--desktop-sidebar-width) minmax(0, 1fr);
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.48), rgba(242, 247, 253, 0.78) 36%, rgba(248, 246, 255, 0.68)),
    var(--desktop-bg);
  transition: grid-template-columns 0.2s ease-out;
}

.desktop-navigation-pending {
  cursor: progress;
}

.desktop-navigation-pending .desktop-shell::after {
  content: "";
  position: absolute;
  z-index: 300;
  top: 0;
  right: 0;
  left: var(--desktop-sidebar-width);
  height: 2px;
  background: #0a84ff;
  pointer-events: none;
  transform-origin: left center;
  animation: desktop-navigation-progress 0.8s ease-in-out infinite;
}

@keyframes desktop-navigation-progress {
  0% { transform: scaleX(0.08); opacity: 0.55; }
  65% { transform: scaleX(0.72); opacity: 1; }
  100% { transform: scaleX(0.98); opacity: 0.35; }
}

.desktop-window-drag-region {
  display: none;
}

:root[data-desktop-shell="electron"] .desktop-window-drag-region {
  position: fixed;
  top: 0;
  right: 0;
  left: 72px;
  z-index: 80;
  display: block;
  height: 42px;
  -webkit-app-region: drag;
}

:root[data-desktop-shell="electron"] .desktop-header {
  -webkit-app-region: drag;
}

:root[data-desktop-shell="electron"] a,
:root[data-desktop-shell="electron"] button,
:root[data-desktop-shell="electron"] input,
:root[data-desktop-shell="electron"] select,
:root[data-desktop-shell="electron"] textarea,
:root[data-desktop-shell="electron"] summary,
:root[data-desktop-shell="electron"] [role="button"],
:root[data-desktop-shell="electron"] .desktop-sidebar,
:root[data-desktop-shell="electron"] .header-status {
  -webkit-app-region: no-drag;
}

.desktop-sidebar {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 11px;
  overflow-y: auto;
  border-right: 1px solid rgba(116, 139, 166, 0.24);
  padding: 12px 10px 12px 11px;
  background: rgba(238, 245, 253, 0.66);
  backdrop-filter: var(--desktop-blur);
  scrollbar-color: rgba(100, 116, 139, 0.22) transparent;
  scrollbar-width: thin;
}

:root[data-desktop-shell="electron"][data-desktop-platform="darwin"] .desktop-sidebar {
  padding-top: 58px;
}

.desktop-sidebar::-webkit-scrollbar {
  width: 7px;
}

.desktop-sidebar::-webkit-scrollbar-track {
  background: transparent;
}

.desktop-sidebar::-webkit-scrollbar-thumb {
  border: 2px solid transparent;
  border-radius: 999px;
  background: rgba(100, 116, 139, 0.22);
  background-clip: content-box;
}

.desktop-brand {
  min-height: 50px;
  display: flex;
  align-items: center;
  gap: 9px;
  color: inherit;
  text-decoration: none;
}

.desktop-sidebar-toggle {
  position: absolute;
  top: 50%;
  left: calc(var(--desktop-sidebar-width) - 22px);
  z-index: 35;
  width: 44px;
  height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 0;
  padding: 0;
  background: transparent;
  color: #6b7b90;
  cursor: pointer;
  box-shadow: none;
  transform: translateY(-50%);
  transition: left 0.2s ease-out, color 0.18s ease;
}

.desktop-sidebar-toggle::before {
  position: absolute;
  top: 6px;
  left: 21px;
  width: 24px;
  height: 32px;
  border: 0;
  border-radius: 0 8px 8px 0;
  background: var(--desktop-sidebar-handle-bg);
  content: "";
  opacity: 0.84;
  -webkit-mask-image: linear-gradient(90deg, #000 0%, #000 22%, rgba(0, 0, 0, 0.5) 42%, rgba(0, 0, 0, 0.08) 60%, transparent 72%);
  mask-image: linear-gradient(90deg, #000 0%, #000 22%, rgba(0, 0, 0, 0.5) 42%, rgba(0, 0, 0, 0.08) 60%, transparent 72%);
  transition: opacity 0.18s ease, filter 0.18s ease;
}

.desktop-sidebar-toggle:hover {
  background: transparent;
  color: var(--desktop-primary-strong);
  box-shadow: none;
}

.desktop-sidebar-toggle:hover::before {
  opacity: 1;
}

.desktop-sidebar-toggle:focus-visible {
  outline: none;
}

.desktop-sidebar-toggle:focus-visible::before {
  opacity: 1;
  filter: drop-shadow(0 0 2px rgba(10, 132, 255, 0.52));
}

.desktop-sidebar-toggle .sidebar-icon {
  position: relative;
  left: 4px;
  z-index: 1;
  width: 13px;
  height: 13px;
  flex-basis: 13px;
  color: currentColor;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-desktop-theme="light"]) {
    --desktop-sidebar-handle-bg: rgba(13, 20, 29, 0.96);
    --desktop-new-analysis-bg: linear-gradient(90deg, rgba(94, 176, 255, 0.18), rgba(94, 176, 255, 0.06) 52%, rgba(94, 176, 255, 0) 100%);
    --desktop-new-analysis-bg-hover: linear-gradient(90deg, rgba(94, 176, 255, 0.23), rgba(94, 176, 255, 0.08) 54%, rgba(94, 176, 255, 0) 100%);
    --desktop-new-analysis-text: #91cdff;
    --desktop-new-analysis-border: rgba(94, 176, 255, 0.34);
    --desktop-new-analysis-pill-bg: linear-gradient(180deg, rgba(17, 30, 45, 0.92), rgba(11, 22, 34, 0.78));
    --desktop-new-analysis-glow: rgba(94, 176, 255, 0.26);
  }
}

:root[data-desktop-theme="dark"] {
  --desktop-sidebar-handle-bg: rgba(13, 20, 29, 0.96);
  --desktop-new-analysis-bg: linear-gradient(90deg, rgba(94, 176, 255, 0.18), rgba(94, 176, 255, 0.06) 52%, rgba(94, 176, 255, 0) 100%);
  --desktop-new-analysis-bg-hover: linear-gradient(90deg, rgba(94, 176, 255, 0.23), rgba(94, 176, 255, 0.08) 54%, rgba(94, 176, 255, 0) 100%);
  --desktop-new-analysis-text: #91cdff;
  --desktop-new-analysis-border: rgba(94, 176, 255, 0.34);
  --desktop-new-analysis-pill-bg: linear-gradient(180deg, rgba(17, 30, 45, 0.92), rgba(11, 22, 34, 0.78));
  --desktop-new-analysis-glow: rgba(94, 176, 255, 0.26);
}

.desktop-brand img {
  width: 31px;
  height: 31px;
  filter: drop-shadow(0 7px 16px rgba(10, 132, 255, 0.20));
}

.desktop-brand span {
  min-width: 0;
  display: grid;
  gap: 1px;
}

.desktop-brand strong {
  font-size: 13.5px;
  font-weight: 790;
  line-height: 1.16;
}

.desktop-brand small,
.sidebar-foot span {
  color: var(--desktop-muted);
  font-size: 10.5px;
  font-weight: 690;
}

.desktop-brand-domain {
  overflow: hidden;
  color: #718096;
  font-size: 10px;
  font-weight: 640;
  line-height: 1.15;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.queue-section {
  min-width: 0;
  display: grid;
  align-content: start;
  gap: 5px;
}

.queue-section + .queue-section {
  margin-top: 0;
}

.queue-section h2 {
  margin: 0 0 3px;
  padding: 0;
}

.section-toggle {
  width: 100%;
  min-height: 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  border: 0;
  border-radius: 7px;
  padding: 5px 6px;
  background: transparent;
  color: #334155;
  cursor: pointer;
  font-size: 12.5px;
  font-weight: 760;
  line-height: 1.2;
  text-align: left;
}

.section-toggle:hover {
  background: rgba(255, 255, 255, 0.48);
  color: #0b1220;
}

.section-toggle:focus {
  outline: none;
}

.section-toggle:focus-visible {
  outline: 2px solid rgba(10, 132, 255, 0.28);
  outline-offset: 1px;
}

.section-label,
.side-label {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 7px;
  overflow: hidden;
}

.section-label span,
.side-text {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.sidebar-icon {
  width: 15px;
  height: 15px;
  flex: 0 0 15px;
  color: #475569;
  display: inline-block;
  background-color: currentColor;
  -webkit-mask: var(--sidebar-icon, var(--sidebar-icon-route)) center / contain no-repeat;
  mask: var(--sidebar-icon, var(--sidebar-icon-route)) center / contain no-repeat;
}

.section-toggle .sidebar-icon {
  width: 14px;
  height: 14px;
  flex-basis: 14px;
  color: #526276;
}

.sidebar-icon use {
  display: none;
}

.sidebar-icon {
  --sidebar-icon-eye: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M2.5 12s3.5-6 9.5-6 9.5 6 9.5 6-3.5 6-9.5 6-9.5-6-9.5-6Z'/%3E%3Ccircle cx='12' cy='12' r='2.8'/%3E%3C/svg%3E");
  --sidebar-icon-briefcase: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M9 7V5.8C9 4.8 9.8 4 10.8 4h2.4C14.2 4 15 4.8 15 5.8V7'/%3E%3Crect x='3.5' y='7' width='17' height='12.5' rx='3'/%3E%3Cpath d='M3.5 11.5h17M10 12.5h4'/%3E%3C/svg%3E");
  --sidebar-icon-list: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M8 6h12M8 12h12M8 18h12M4.2 6h.1M4.2 12h.1M4.2 18h.1'/%3E%3C/svg%3E");
  --sidebar-icon-route: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='6' cy='6' r='2.4'/%3E%3Ccircle cx='18' cy='18' r='2.4'/%3E%3Cpath d='M8.4 6h4.1a3.5 3.5 0 0 1 0 7H11a3.5 3.5 0 0 0 0 7h4.6'/%3E%3C/svg%3E");
  --sidebar-icon-dashboard: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3.5' y='4' width='7' height='7' rx='2'/%3E%3Crect x='13.5' y='4' width='7' height='4.5' rx='2'/%3E%3Crect x='13.5' y='11.5' width='7' height='8.5' rx='2'/%3E%3Crect x='3.5' y='14' width='7' height='6' rx='2'/%3E%3C/svg%3E");
  --sidebar-icon-workbench: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M7.5 18.5v-1.3c0-1.8 2.1-3.2 4.5-3.2s4.5 1.4 4.5 3.2v1.3M9 9a3 3 0 1 0 6 0 3 3 0 0 0-6 0Z'/%3E%3Crect x='3.5' y='4' width='17' height='16' rx='3'/%3E%3C/svg%3E");
  --sidebar-icon-plug: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M9 7V3.8M15 7V3.8M7.5 7h9v4.2a4.5 4.5 0 0 1-9 0V7ZM12 15.8v4.4M8.5 20.2h7'/%3E%3C/svg%3E");
  --sidebar-icon-globe: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='8.5'/%3E%3Cpath d='M3.8 12h16.4M12 3.5c2.3 2.4 3.4 5.2 3.4 8.5S14.3 18.1 12 20.5M12 3.5C9.7 5.9 8.6 8.7 8.6 12s1.1 6.1 3.4 8.5'/%3E%3C/svg%3E");
  --sidebar-icon-settings: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='3.2'/%3E%3Cpath d='M12 3.8v2.4M12 17.8v2.4M5.2 5.2l1.7 1.7M17.1 17.1l1.7 1.7M3.8 12h2.4M17.8 12h2.4M5.2 18.8l1.7-1.7M17.1 6.9l1.7-1.7'/%3E%3C/svg%3E");
  --sidebar-icon-info: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='8.5'/%3E%3Cpath d='M12 11v5M12 7.4h.1'/%3E%3C/svg%3E");
  --sidebar-icon-calendar-check: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='4' y='5' width='16' height='15' rx='3'/%3E%3Cpath d='M8 3.5v3M16 3.5v3M4 9h16M8.3 14l2.2 2.2 5-5'/%3E%3C/svg%3E");
  --sidebar-icon-alert: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M12 4 21 19H3L12 4ZM12 9v4.3M12 17h.1'/%3E%3C/svg%3E");
  --sidebar-icon-team: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='9' cy='8.5' r='2.8'/%3E%3Cpath d='M4.5 18c.5-2.5 2.2-4 4.5-4s4 1.5 4.5 4'/%3E%3Ccircle cx='16.7' cy='9.5' r='2.2'/%3E%3Cpath d='M14.5 14.2c2.1.2 3.6 1.5 4 3.8'/%3E%3C/svg%3E");
  --sidebar-icon-star: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m12 3.8 2.5 5.1 5.6.8-4 3.9.9 5.5-5-2.6-5 2.6.9-5.5-4-3.9 5.6-.8L12 3.8Z'/%3E%3C/svg%3E");
  --sidebar-icon-users: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='9.5' cy='8.2' r='3'/%3E%3Cpath d='M4.2 19c.5-3 2.6-4.7 5.3-4.7s4.8 1.7 5.3 4.7M15.4 6.4a2.6 2.6 0 0 1 0 5.1M17.3 14.2c1.5.7 2.4 2.1 2.7 4.1'/%3E%3C/svg%3E");
  --sidebar-icon-zap: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M13 2.8 5.5 13h5.6L10 21.2 18.5 10h-5.8L13 2.8Z'/%3E%3C/svg%3E");
  --sidebar-icon-clock: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='8.5'/%3E%3Cpath d='M12 7.5v5l3.4 2'/%3E%3C/svg%3E");
  --sidebar-icon-target: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='8.5'/%3E%3Ccircle cx='12' cy='12' r='4.8'/%3E%3Ccircle cx='12' cy='12' r='1.4'/%3E%3C/svg%3E");
  --sidebar-icon-wallet: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 7.2h13.5A2.5 2.5 0 0 1 21 9.7v7a2.5 2.5 0 0 1-2.5 2.5H5a2.5 2.5 0 0 1-2.5-2.5V7.8A2.8 2.8 0 0 1 5.3 5h11.2'/%3E%3Cpath d='M16.8 12H21v3.5h-4.2a1.8 1.8 0 0 1 0-3.5Z'/%3E%3C/svg%3E");
  --sidebar-icon-message: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5.2 17.5 4 20.5l3.4-1.1a8.7 8.7 0 0 0 4.6 1.1c4.9 0 8.8-3.4 8.8-7.6S16.9 5.3 12 5.3 3.2 8.7 3.2 12.9c0 1.7.7 3.3 2 4.6Z'/%3E%3C/svg%3E");
  --sidebar-icon-sliders: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 7h5M15 7h5M4 17h8M18 17h2'/%3E%3Ccircle cx='12' cy='7' r='2.5'/%3E%3Ccircle cx='15' cy='17' r='2.5'/%3E%3C/svg%3E");
  --sidebar-icon-sun: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='4'/%3E%3Cpath d='M12 3v2.2M12 18.8V21M3 12h2.2M18.8 12H21M5.6 5.6l1.6 1.6M16.8 16.8l1.6 1.6M18.4 5.6l-1.6 1.6M7.2 16.8l-1.6 1.6'/%3E%3C/svg%3E");
  --sidebar-icon-moon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M19.2 14.8A7.5 7.5 0 0 1 9.2 4.8 8 8 0 1 0 19.2 14.8Z'/%3E%3C/svg%3E");
  --sidebar-icon-monitor: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3.5' y='5' width='17' height='11' rx='2.4'/%3E%3Cpath d='M9 20h6M12 16v4'/%3E%3C/svg%3E");
  --sidebar-icon-flask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M9 3.8h6M10 3.8v5.1L5.8 17.2A2.5 2.5 0 0 0 8 21h8a2.5 2.5 0 0 0 2.2-3.8L14 8.9V3.8M8 16h8'/%3E%3C/svg%3E");
  --sidebar-icon-package: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 8.2 12 4l8 4.2v7.6L12 20l-8-4.2V8.2ZM4.4 8.5l7.6 4 7.6-4M12 12.5V20'/%3E%3C/svg%3E");
  --sidebar-icon-coins: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cellipse cx='9' cy='7' rx='5' ry='2.8'/%3E%3Cpath d='M4 7v4.5c0 1.5 2.2 2.8 5 2.8s5-1.3 5-2.8V7M10 16.8c.9.7 2.4 1.2 4 1.2 2.8 0 5-1.3 5-2.8v-4.5M14 10.7c2.8 0 5 1.3 5 2.8'/%3E%3C/svg%3E");
  --sidebar-icon-shield: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M12 3.5 19 6v5.4c0 4.3-2.7 7.4-7 9.1-4.3-1.7-7-4.8-7-9.1V6l7-2.5ZM8.7 12l2.2 2.2 4.6-4.7'/%3E%3C/svg%3E");
  --sidebar-icon-clipboard: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M9 5.5h6M9.5 4h5A1.5 1.5 0 0 1 16 5.5V7H8V5.5A1.5 1.5 0 0 1 9.5 4Z'/%3E%3Crect x='5' y='6' width='14' height='15' rx='3'/%3E%3Cpath d='m8.5 14 2 2 5-5'/%3E%3C/svg%3E");
  --sidebar-icon-factory: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 20V9.5l5 3V9.5l5 3V7l6-2v15H4ZM8 17h.1M12 17h.1M16 17h.1'/%3E%3C/svg%3E");
  --sidebar-icon-repeat: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M17 3.8 20.2 7 17 10.2M4 11V9a2 2 0 0 1 2-2h14M7 20.2 3.8 17 7 13.8M20 13v2a2 2 0 0 1-2 2H4'/%3E%3C/svg%3E");
  --sidebar-icon-help: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='8.5'/%3E%3Cpath d='M9.7 9.2A2.4 2.4 0 0 1 12 7.8c1.5 0 2.6.9 2.6 2.2 0 1.7-1.8 2.1-2.4 3.2-.2.3-.2.7-.2 1.2M12 17.5h.1'/%3E%3C/svg%3E");
  --sidebar-icon-logout: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M10 5H6.8A2.8 2.8 0 0 0 4 7.8v8.4A2.8 2.8 0 0 0 6.8 19H10M14.5 8l4 4-4 4M18.5 12H9'/%3E%3C/svg%3E");
  --sidebar-icon-chevron-left: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m15 18-6-6 6-6'/%3E%3C/svg%3E");
  --sidebar-icon-chevron-right: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m9 18 6-6-6-6'/%3E%3C/svg%3E");
}

.sidebar-icon:has(use[href$="#eye"]) { --sidebar-icon: var(--sidebar-icon-eye); }
.sidebar-icon:has(use[href$="#briefcase"]) { --sidebar-icon: var(--sidebar-icon-briefcase); }
.sidebar-icon:has(use[href$="#list"]) { --sidebar-icon: var(--sidebar-icon-list); }
.sidebar-icon:has(use[href$="#route"]) { --sidebar-icon: var(--sidebar-icon-route); }
.sidebar-icon:has(use[href$="#dashboard"]) { --sidebar-icon: var(--sidebar-icon-dashboard); }
.sidebar-icon:has(use[href$="#workbench"]) { --sidebar-icon: var(--sidebar-icon-workbench); }
.sidebar-icon:has(use[href$="#plug"]) { --sidebar-icon: var(--sidebar-icon-plug); }
.sidebar-icon:has(use[href$="#globe"]) { --sidebar-icon: var(--sidebar-icon-globe); }
.sidebar-icon:has(use[href$="#settings"]) { --sidebar-icon: var(--sidebar-icon-settings); }
.sidebar-icon:has(use[href$="#info"]) { --sidebar-icon: var(--sidebar-icon-info); }
.sidebar-icon:has(use[href$="#calendar-check"]) { --sidebar-icon: var(--sidebar-icon-calendar-check); }
.sidebar-icon:has(use[href$="#alert"]) { --sidebar-icon: var(--sidebar-icon-alert); }
.sidebar-icon:has(use[href$="#team"]) { --sidebar-icon: var(--sidebar-icon-team); }
.sidebar-icon:has(use[href$="#star"]) { --sidebar-icon: var(--sidebar-icon-star); }
.sidebar-icon:has(use[href$="#users"]) { --sidebar-icon: var(--sidebar-icon-users); }
.sidebar-icon:has(use[href$="#zap"]) { --sidebar-icon: var(--sidebar-icon-zap); }
.sidebar-icon:has(use[href$="#clock"]) { --sidebar-icon: var(--sidebar-icon-clock); }
.sidebar-icon:has(use[href$="#target"]) { --sidebar-icon: var(--sidebar-icon-target); }
.sidebar-icon:has(use[href$="#wallet"]) { --sidebar-icon: var(--sidebar-icon-wallet); }
.sidebar-icon:has(use[href$="#message"]) { --sidebar-icon: var(--sidebar-icon-message); }
.sidebar-icon:has(use[href$="#sliders"]) { --sidebar-icon: var(--sidebar-icon-sliders); }
.sidebar-icon:has(use[href$="#sun"]) { --sidebar-icon: var(--sidebar-icon-sun); }
.sidebar-icon:has(use[href$="#moon"]) { --sidebar-icon: var(--sidebar-icon-moon); }
.sidebar-icon:has(use[href$="#monitor"]) { --sidebar-icon: var(--sidebar-icon-monitor); }
.sidebar-icon:has(use[href$="#flask"]) { --sidebar-icon: var(--sidebar-icon-flask); }
.sidebar-icon:has(use[href$="#package"]) { --sidebar-icon: var(--sidebar-icon-package); }
.sidebar-icon:has(use[href$="#coins"]) { --sidebar-icon: var(--sidebar-icon-coins); }
.sidebar-icon:has(use[href$="#shield"]) { --sidebar-icon: var(--sidebar-icon-shield); }
.sidebar-icon:has(use[href$="#clipboard"]) { --sidebar-icon: var(--sidebar-icon-clipboard); }
.sidebar-icon:has(use[href$="#factory"]) { --sidebar-icon: var(--sidebar-icon-factory); }
.sidebar-icon:has(use[href$="#repeat"]) { --sidebar-icon: var(--sidebar-icon-repeat); }
.sidebar-icon:has(use[href$="#help"]) { --sidebar-icon: var(--sidebar-icon-help); }
.sidebar-icon:has(use[href$="#logout"]) { --sidebar-icon: var(--sidebar-icon-logout); }
.sidebar-icon:has(use[href$="#chevron-left"]) { --sidebar-icon: var(--sidebar-icon-chevron-left); }
.sidebar-icon:has(use[href$="#chevron-right"]) { --sidebar-icon: var(--sidebar-icon-chevron-right); }

.section-toggle i {
  width: 7px;
  height: 7px;
  flex: 0 0 auto;
  border-right: 1.5px solid currentColor;
  border-bottom: 1.5px solid currentColor;
  transform: rotate(45deg);
  transition: transform 0.16s ease;
}

.queue-section.collapsed .section-toggle i {
  transform: rotate(-45deg);
}

.section-body {
  min-width: 0;
  display: grid;
  gap: 4px;
}

.queue-section.collapsed .section-body {
  display: none;
}

.queue-item,
.side-link {
  min-height: 34px;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  border: 1px solid transparent;
  border-radius: 9px;
  padding: 6px 8px;
  background: transparent;
  color: #334155;
  cursor: pointer;
  text-align: left;
  text-decoration: none;
  transition: background 0.18s ease, border-color 0.18s ease, color 0.18s ease, transform 0.18s ease, box-shadow 0.18s ease;
}

.queue-item:hover,
.side-link:hover {
  border-color: rgba(10, 132, 255, 0.14);
  background: rgba(255, 255, 255, 0.52);
  color: #0a66c2;
  text-decoration: none;
}

.queue-item:hover .sidebar-icon,
.side-link:hover .sidebar-icon {
  color: #0a66c2;
}

.queue-item.active,
.side-link.active {
  border-color: rgba(10, 132, 255, 0.18);
  background: rgba(10, 132, 255, 0.075);
  color: #0057c2;
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.70) inset;
}

.queue-item.active::before,
.side-link.active::before {
  position: absolute;
  top: 8px;
  bottom: 8px;
  left: 4px;
  width: 2px;
  border-radius: 999px;
  background: #0a84ff;
  content: "";
}

.queue-item.active .sidebar-icon,
.side-link.active .sidebar-icon {
  color: var(--desktop-primary);
}

.queue-item:focus,
.queue-item:focus-visible,
.side-link:focus,
.side-link:focus-visible {
  text-decoration: none;
}

.queue-item .side-text,
.side-link .side-text {
  font-size: 12.8px;
  font-weight: 710;
}

/* Keep the management-only knowledge entry inert until the signed-in role is known. */
.desktop-page .sales-hidden {
  display: none !important;
}

.desktop-page .sales-hidden.is-role-visible {
  display: flex !important;
}

.desktop-page .desktop-btn.sales-hidden.is-role-visible {
  display: inline-flex !important;
}

.collector-nav-status {
  min-width: 0;
  max-width: 62px;
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  gap: 5px;
  overflow: hidden;
  color: #52647d;
  font-size: 10.5px;
  font-weight: 760;
  font-variant-numeric: tabular-nums;
  line-height: 1;
  white-space: nowrap;
}

.collector-nav-status[hidden] {
  display: none;
}

.collector-nav-status-dot {
  width: 6px;
  height: 6px;
  flex: 0 0 6px;
  border-radius: 50%;
  background: currentColor;
}

.collector-nav-status.is-running {
  color: #0066d6;
}

.collector-nav-status.is-completed {
  color: #137a4b;
}

.collector-nav-status.is-attention {
  color: #925600;
}

.collector-nav-status.is-failed {
  color: #b42318;
}

.collector-nav-status.is-stopped {
  color: #64748b;
}

.collector-nav-status.is-running .collector-nav-status-dot {
  animation: collectorNavStatusPulse 1.5s ease-in-out infinite;
}

@keyframes collectorNavStatusPulse {
  0%, 100% { opacity: 0.48; transform: scale(0.82); }
  50% { opacity: 1; transform: scale(1); }
}

@media (prefers-color-scheme: dark) {
  :root:not([data-desktop-theme="light"]) .collector-nav-status.is-running { color: #7cc4ff; }
  :root:not([data-desktop-theme="light"]) .collector-nav-status.is-completed { color: #70dba4; }
  :root:not([data-desktop-theme="light"]) .collector-nav-status.is-attention { color: #ffc66b; }
  :root:not([data-desktop-theme="light"]) .collector-nav-status.is-failed { color: #ff8b83; }
  :root:not([data-desktop-theme="light"]) .collector-nav-status.is-stopped { color: #a9b7c8; }
}

:root[data-desktop-theme="dark"] .collector-nav-status.is-running { color: #7cc4ff; }
:root[data-desktop-theme="dark"] .collector-nav-status.is-completed { color: #70dba4; }
:root[data-desktop-theme="dark"] .collector-nav-status.is-attention { color: #ffc66b; }
:root[data-desktop-theme="dark"] .collector-nav-status.is-failed { color: #ff8b83; }
:root[data-desktop-theme="dark"] .collector-nav-status.is-stopped { color: #a9b7c8; }

.queue-item strong {
  min-width: 24px;
  flex: 0 0 auto;
  color: #26344a;
  font-size: 12.8px;
  font-weight: 720;
  font-variant-numeric: tabular-nums;
  line-height: 1;
  text-align: right;
}

.stage-queue-section {
  gap: 4px;
}

.stage-queue-list {
  display: grid;
  gap: 3px;
}

.stage-queue-item {
  min-height: 32px;
  border-radius: 8px;
  padding: 5px 7px;
}

.stage-queue-item .side-label {
  gap: 6px;
}

.stage-queue-item .sidebar-icon {
  width: 14px;
  height: 14px;
  flex-basis: 14px;
}

.stage-queue-item .side-text {
  font-size: 12.3px;
  font-weight: 690;
  white-space: normal;
  line-height: 1.24;
}

.stage-queue-item strong {
  font-size: 12px;
}

.sidebar-foot {
  margin-top: auto;
  display: grid;
  gap: 8px;
}

.sidebar-foot button {
  min-height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  border: 1px solid rgba(104, 126, 155, 0.28);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.76);
  color: #334155;
  cursor: pointer;
  font-weight: 720;
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.82) inset;
}

.sidebar-foot button:hover .sidebar-icon {
  color: #0a66c2;
}

.desktop-theme-switcher {
  position: relative;
  display: grid;
  min-width: 0;
}

.sidebar-foot .desktop-theme-trigger {
  width: 100%;
  justify-content: flex-start;
  padding: 0 9px;
  text-align: left;
}

.desktop-theme-trigger b {
  margin-left: auto;
  color: var(--desktop-muted);
  font-size: 11px;
  font-weight: 740;
}

.desktop-theme-menu {
  position: absolute;
  right: 0;
  bottom: calc(100% + 7px);
  left: 0;
  z-index: 20;
  display: grid;
  gap: 3px;
  border: 1px solid var(--desktop-border);
  border-radius: 12px;
  padding: 5px;
  background: var(--desktop-surface-strong);
  box-shadow: var(--desktop-shadow-soft);
  backdrop-filter: var(--desktop-blur);
}

.desktop-theme-menu[hidden] {
  display: none;
}

.desktop-theme-menu button,
.desktop-theme-choice {
  min-width: 0;
  min-height: 32px;
  display: inline-flex;
  align-items: center;
  justify-content: flex-start;
  gap: 7px;
  border: 1px solid transparent;
  border-radius: 9px;
  padding: 0 9px;
  background: transparent;
  color: var(--desktop-text);
  cursor: pointer;
  font-size: 12px;
  font-weight: 760;
  line-height: 1.2;
}

.desktop-theme-menu button:hover,
.desktop-theme-choice:hover {
  border-color: rgba(10, 132, 255, 0.18);
  background: var(--desktop-primary-soft);
  color: var(--desktop-primary-strong);
}

.desktop-theme-menu button.is-active,
.desktop-theme-choice.is-active {
  border-color: rgba(10, 132, 255, 0.24);
  background: var(--desktop-primary-soft);
  color: var(--desktop-primary-strong);
}

.desktop-theme-menu .sidebar-icon,
.desktop-theme-choice .sidebar-icon {
  color: currentColor;
}

.desktop-sidebar-tooltip {
  position: fixed;
  z-index: 200;
  max-width: 240px;
  border: 1px solid var(--desktop-border-strong);
  border-radius: 6px;
  padding: 7px 9px;
  background: var(--desktop-surface-strong);
  color: var(--desktop-text);
  box-shadow: var(--desktop-shadow-soft);
  backdrop-filter: var(--desktop-blur);
  font-size: 12px;
  font-weight: 720;
  line-height: 1.35;
  pointer-events: none;
  white-space: nowrap;
}

.desktop-sidebar-tooltip[hidden] {
  display: none;
}

@media (min-width: 1181px) {
  :root[data-desktop-sidebar="collapsed"] .desktop-shell {
    --desktop-sidebar-width: 64px;
  }

  :root[data-desktop-sidebar="collapsed"] .desktop-sidebar {
    gap: 7px;
    overflow-x: hidden;
    padding-right: 10px;
    padding-left: 10px;
    scrollbar-width: none;
  }

  :root[data-desktop-sidebar="collapsed"] .desktop-sidebar::-webkit-scrollbar {
    width: 0;
    height: 0;
  }

  :root[data-desktop-sidebar="collapsed"] .desktop-brand {
    min-height: 40px;
    justify-content: center;
    padding: 0;
  }

  :root[data-desktop-sidebar="collapsed"] .desktop-brand > span,
  :root[data-desktop-sidebar="collapsed"] .section-label > span:last-child,
  :root[data-desktop-sidebar="collapsed"] .side-text,
  :root[data-desktop-sidebar="collapsed"] .queue-item > strong,
  :root[data-desktop-sidebar="collapsed"] .collector-nav-status,
  :root[data-desktop-sidebar="collapsed"] .sidebar-foot > span,
  :root[data-desktop-sidebar="collapsed"] .desktop-theme-trigger > span,
  :root[data-desktop-sidebar="collapsed"] .desktop-theme-trigger > b,
  :root[data-desktop-sidebar="collapsed"] #logoutBtn > span {
    display: none;
  }

  :root[data-desktop-sidebar="collapsed"] .queue-section {
    gap: 3px;
  }

  :root[data-desktop-sidebar="collapsed"] .queue-section h2 {
    margin: 0;
  }

  :root[data-desktop-sidebar="collapsed"] .section-toggle,
  :root[data-desktop-sidebar="collapsed"] .queue-item,
  :root[data-desktop-sidebar="collapsed"] .side-link,
  :root[data-desktop-sidebar="collapsed"] .sidebar-foot button {
    width: 44px;
    min-width: 44px;
    min-height: 44px;
    justify-content: center;
    margin-right: auto;
    margin-left: auto;
    padding: 0;
  }

  :root[data-desktop-sidebar="collapsed"] .section-toggle {
    color: #68788d;
  }

  :root[data-desktop-sidebar="collapsed"] .section-toggle i {
    display: none;
  }

  :root[data-desktop-sidebar="collapsed"] .section-body,
  :root[data-desktop-sidebar="collapsed"] .queue-section.collapsed .section-body {
    width: 44px;
    display: grid;
    gap: 3px;
    margin: 0 auto;
  }

  :root[data-desktop-sidebar="collapsed"] .stage-queue-list {
    width: 44px;
    gap: 3px;
  }

  :root[data-desktop-sidebar="collapsed"] .side-label,
  :root[data-desktop-sidebar="collapsed"] .section-label {
    width: 100%;
    justify-content: center;
    gap: 0;
  }

  :root[data-desktop-sidebar="collapsed"] .queue-item .sidebar-icon,
  :root[data-desktop-sidebar="collapsed"] .side-link .sidebar-icon,
  :root[data-desktop-sidebar="collapsed"] .stage-queue-item .sidebar-icon {
    width: 18px;
    height: 18px;
    flex-basis: 18px;
  }

  :root[data-desktop-sidebar="collapsed"] .queue-item.active::before,
  :root[data-desktop-sidebar="collapsed"] .side-link.active::before {
    top: 10px;
    bottom: 10px;
    left: 3px;
  }

  :root[data-desktop-sidebar="collapsed"] .desktop-theme-menu {
    right: auto;
    bottom: 0;
    left: calc(100% + 10px);
    width: 142px;
  }
}

.desktop-main {
  min-width: 0;
  min-height: 0;
  display: grid;
  grid-template-rows: auto auto auto auto minmax(0, 1fr);
  gap: 8px;
  padding: 14px 16px 12px;
}

.customer-workbench-page .desktop-main {
  grid-template-rows: auto auto minmax(0, 1fr);
}

.desktop-header {
  min-height: 64px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  border: 1px solid rgba(255, 255, 255, 0.76);
  border-radius: 18px;
  padding: 10px 18px;
  background:
    linear-gradient(110deg, rgba(255, 255, 255, 0.86), rgba(239, 247, 255, 0.78) 52%, rgba(248, 245, 255, 0.74)),
    var(--desktop-surface);
  box-shadow: var(--desktop-shadow-soft);
  backdrop-filter: var(--desktop-blur);
}

.desktop-header p,
.desktop-header h1,
.desktop-header span {
  margin: 0;
}

.desktop-header p {
  display: none;
}

.desktop-header h1 {
  color: #071426;
  font-size: 25px;
  font-weight: 820;
  line-height: 1.12;
}

.desktop-header span {
  display: block;
  margin-top: 3px;
  color: #526276;
  font-size: 13px;
  font-weight: 650;
}

.header-status {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  gap: 8px;
}

#currentUserBadge {
  min-height: 34px;
  display: inline-flex;
  align-items: center;
  border: 1px solid rgba(104, 126, 155, 0.26);
  border-radius: 999px;
  padding: 7px 12px;
  background: rgba(255, 255, 255, 0.62);
  color: #334155;
  font-size: 12px;
  font-weight: 760;
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.82) inset;
}

.desktop-btn {
  min-height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(104, 126, 155, 0.28);
  border-radius: 12px;
  padding: 7px 12px;
  background: rgba(255, 255, 255, 0.74);
  color: #334155;
  cursor: pointer;
  font-weight: 760;
  text-decoration: none;
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.76) inset;
  transition: background 0.18s ease, border-color 0.18s ease, color 0.18s ease, transform 0.18s ease, box-shadow 0.18s ease;
}

.desktop-btn:hover {
  border-color: rgba(10, 132, 255, 0.34);
  background: rgba(255, 255, 255, 0.92);
  color: #0057c2;
  text-decoration: none;
  box-shadow: 0 0 0 3px rgba(10, 132, 255, 0.08);
}

.desktop-btn:focus,
.desktop-btn:focus-visible {
  text-decoration: none;
}

.desktop-btn.primary {
  border-color: transparent;
  background: #007aff;
  color: #ffffff;
  box-shadow: none;
}

.desktop-btn.primary:hover {
  background: #006edb;
  color: #ffffff;
  box-shadow: none;
}

.desktop-btn.primary .sidebar-icon {
  color: #ffffff;
  opacity: 1;
}

.desktop-btn.primary span {
  color: #ffffff;
  font-size: 13px;
  font-weight: 780;
  line-height: 1;
  letter-spacing: 0;
}

.desktop-btn.ghost {
  background: rgba(255, 255, 255, 0.46);
}

.desktop-btn.danger {
  border-color: rgba(255, 59, 48, 0.22);
  background: rgba(255, 255, 255, 0.76);
  color: #b42318;
}

.desktop-btn.danger:hover {
  border-color: rgba(255, 59, 48, 0.34);
  background: rgba(255, 255, 255, 0.94);
  color: #981b12;
  box-shadow: 0 0 0 3px rgba(255, 59, 48, 0.08);
}

.desktop-btn:disabled {
  cursor: not-allowed;
  opacity: 0.54;
}

.desktop-btn .sidebar-icon {
  color: currentColor;
}

.desktop-btn span {
  color: inherit;
  font-size: inherit;
  font-weight: inherit;
}

.desktop-header .desktop-btn span,
.collector-progress-actions .desktop-btn span,
.collector-detail-actions .desktop-btn span {
  color: inherit;
  font-size: inherit;
  font-weight: inherit;
}

.desktop-toolbar,
.metric-strip,
.customer-list-panel,
.customer-detail-panel {
  border: 1px solid var(--desktop-border);
  border-radius: 16px;
  background: var(--desktop-surface);
  box-shadow: var(--desktop-shadow-soft);
  backdrop-filter: var(--desktop-blur);
}

.desktop-toolbar {
  min-height: 48px;
  display: grid;
  grid-template-columns: minmax(240px, 0.8fr) minmax(560px, 1.6fr) auto;
  align-items: center;
  gap: 8px;
  padding: 6px 8px;
}

.toolbar-filter-group {
  min-width: 0;
  display: grid;
  grid-template-columns: repeat(4, minmax(120px, 1fr));
  gap: 8px;
}

.search-box,
.select-box {
  min-width: 0;
  display: block;
  position: relative;
}

.toolbar-check {
  min-width: 0;
  min-height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  border: 1px solid rgba(104, 126, 155, 0.28);
  border-radius: 11px;
  padding: 7px 9px;
  background: rgba(255, 255, 255, 0.86);
  color: #334155;
  cursor: pointer;
  font-size: 12px;
  font-weight: 760;
  white-space: nowrap;
  user-select: none;
}

.toolbar-check input {
  width: 15px;
  height: 15px;
  margin: 0;
  accent-color: var(--desktop-primary-strong);
  cursor: pointer;
}

.toolbar-check:focus-within {
  border-color: rgba(10, 132, 255, 0.64);
  box-shadow: 0 0 0 4px rgba(10, 132, 255, 0.12);
}

.quick-form label {
  display: grid;
  gap: 5px;
}

.search-box span,
.quick-form label span {
  color: #64748b;
  font-size: 11px;
  font-weight: 800;
}

.search-box span,
.select-box span {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
}

.search-box input,
.select-box input,
.select-box select,
.panel-head select,
.quick-form select,
.quick-form input,
.quick-form textarea {
  width: 100%;
  min-height: 36px;
  border: 1px solid rgba(104, 126, 155, 0.28);
  border-radius: 11px;
  padding: 8px 10px;
  background: rgba(255, 255, 255, 0.86);
  color: #0f172a;
  outline: none;
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.86) inset;
}

.search-box input:focus,
.select-box input:focus,
.select-box select:focus,
.panel-head select:focus,
.quick-form select:focus,
.quick-form input:focus,
.quick-form textarea:focus {
  border-color: rgba(10, 132, 255, 0.64);
  box-shadow: 0 0 0 4px rgba(10, 132, 255, 0.12);
}

.panel-head span,
.detail-head span,
.detail-grid span,
.detail-insight-card span,
.detail-context-line span,
.detail-block h3,
.form-head span {
  color: #64748b;
  font-size: 12px;
}

.metric-strip {
  min-height: 128px;
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  grid-template-rows: repeat(2, minmax(56px, auto));
  gap: 8px;
  padding: 6px;
}

.metric-card {
  min-width: 0;
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-content: center;
  align-items: center;
  gap: 2px 8px;
  border: 1px solid rgba(104, 126, 155, 0.22);
  border-radius: 14px;
  padding: 8px 10px;
  background: rgba(255, 255, 255, 0.78);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.86) inset;
  appearance: none;
  color: inherit;
  cursor: pointer;
  text-align: left;
  transition: transform 0.18s ease, border-color 0.18s ease, background 0.18s ease, box-shadow 0.18s ease;
}

.metric-card:hover {
  z-index: 20;
  transform: translateY(-1px);
  border-color: rgba(10, 132, 255, 0.34);
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 8px 18px rgba(10, 86, 170, 0.08), 0 1px 0 rgba(255, 255, 255, 0.9) inset;
}

.metric-card.active,
.metric-card[aria-pressed="true"] {
  border-color: rgba(10, 132, 255, 0.58);
  background: rgba(235, 245, 255, 0.96);
  box-shadow: 0 0 0 2px rgba(10, 132, 255, 0.12), 0 7px 16px rgba(10, 86, 170, 0.08);
}

.metric-card:focus-visible {
  outline: 3px solid rgba(10, 132, 255, 0.24);
  outline-offset: 2px;
}

.metric-card:active {
  transform: translateY(0);
}

.metric-card::after {
  content: "";
  position: absolute;
  top: 50%;
  right: 8px;
  width: 4px;
  height: 28px;
  transform: translateY(-50%);
  border-radius: 999px;
  background: var(--desktop-primary);
  box-shadow: 0 0 18px rgba(10, 132, 255, 0.28);
}

.metric-card.danger::after {
  background: var(--desktop-danger);
}

.metric-card.warn::after {
  background: var(--desktop-warn);
}

.metric-card.ok::after {
  background: var(--desktop-ok);
}

.metric-card.segment::after {
  background: #6c7cf5;
}

.metric-card.segment.sample::after {
  background: #12a8a0;
}

.metric-card.segment.won::after,
.metric-card.segment.repeat::after {
  background: var(--desktop-ok);
}

.metric-card.segment.big-won::after {
  background: #8b5cf6;
}

.metric-card span,
.metric-card small {
  color: #60708a;
  font-size: 11px;
  font-weight: 720;
}

.metric-card-label {
  min-width: 0;
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.metric-card .metric-help {
  position: relative;
  display: inline-flex;
  flex: 0 0 auto;
  width: 20px;
  height: 20px;
  align-items: center;
  justify-content: center;
  color: #8492a6;
  cursor: help;
}

.metric-help-icon {
  width: 14px;
  height: 14px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  transition: color 0.16s ease, transform 0.16s ease;
}

.metric-card .metric-help-bubble {
  position: absolute;
  top: calc(100% + 7px);
  left: 0;
  z-index: 80;
  width: 220px;
  padding: 9px 10px;
  border: 1px solid rgba(104, 126, 155, 0.28);
  border-radius: 9px;
  background: rgba(255, 255, 255, 0.98);
  box-shadow: 0 10px 24px rgba(28, 42, 60, 0.16);
  color: #334155;
  font-size: 12px;
  font-weight: 560;
  line-height: 1.55;
  opacity: 0;
  pointer-events: none;
  transform: translateY(-3px);
  transition: opacity 0.16s ease, transform 0.16s ease;
}

.metric-card:nth-child(5n) .metric-help-bubble {
  right: 0;
  left: auto;
}

.metric-card:nth-child(n + 6) .metric-help-bubble {
  top: auto;
  bottom: calc(100% + 7px);
  transform: translateY(3px);
}

.metric-help:hover,
.metric-help:focus-visible {
  color: var(--desktop-primary-strong);
}

.metric-help:hover .metric-help-icon,
.metric-help:focus-visible .metric-help-icon {
  transform: scale(1.08);
}

.metric-help:hover .metric-help-bubble,
.metric-help:focus-visible .metric-help-bubble,
.metric-card:focus-visible .metric-help-bubble {
  opacity: 1;
  transform: translateY(0);
}

@media (prefers-color-scheme: dark) {
  :root:not([data-desktop-theme="light"]) .metric-card .metric-help {
    color: #94a3b8;
  }

  :root:not([data-desktop-theme="light"]) .metric-card .metric-help-bubble {
    border-color: rgba(148, 163, 184, 0.28);
    background: rgba(18, 27, 40, 0.98);
    color: #e2e8f0;
    box-shadow: 0 12px 28px rgba(0, 0, 0, 0.32);
  }
}

:root[data-desktop-theme="dark"] .metric-card .metric-help {
  color: #94a3b8;
}

:root[data-desktop-theme="dark"] .metric-card .metric-help-bubble {
  border-color: rgba(148, 163, 184, 0.28);
  background: rgba(18, 27, 40, 0.98);
  color: #e2e8f0;
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.32);
}

.metric-card strong {
  grid-column: 2;
  grid-row: 1 / span 2;
  padding-right: 10px;
  color: #071426;
  font-size: 24px;
  font-weight: 820;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}

.metric-card.data-quality {
  --metric-analyzed-color: #071426;
  --metric-insufficient-color: #9a5b00;
  --metric-total-color: #334155;
  --metric-quality-divider: rgba(104, 126, 155, 0.22);
  grid-template-columns: minmax(0, 1fr);
  grid-template-rows: auto minmax(30px, 1fr);
  align-content: stretch;
  gap: 4px;
  padding-right: 20px;
}

.metric-card.data-quality .metric-quality-head {
  min-width: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
}

.metric-card.data-quality .metric-quality-head > span {
  color: #60708a;
  font-size: 11px;
  font-weight: 760;
}

.metric-card.data-quality .metric-quality-head > small {
  color: #60708a;
  font-size: 10px;
  font-weight: 680;
  white-space: nowrap;
}

.metric-card.data-quality .metric-quality-head b {
  color: var(--metric-total-color);
  font-size: 11px;
  font-variant-numeric: tabular-nums;
}

.metric-card.data-quality .metric-quality-values {
  min-width: 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-items: end;
}

.metric-card.data-quality .metric-quality-stat {
  min-width: 0;
  display: grid;
  align-content: end;
  gap: 1px;
}

.metric-card.data-quality .metric-quality-stat + .metric-quality-stat {
  margin-left: 8px;
  border-left: 1px solid var(--metric-quality-divider);
  padding-left: 8px;
}

.metric-card.data-quality .metric-quality-stat > strong {
  grid-column: auto;
  grid-row: auto;
  padding: 0;
  color: var(--metric-analyzed-color);
  font-size: 20px;
  line-height: 1;
}

.metric-card.data-quality .metric-quality-stat.insufficient > strong {
  color: var(--metric-insufficient-color);
}

.metric-card.data-quality .metric-quality-stat > small {
  overflow: hidden;
  color: #60708a;
  font-size: 10px;
  font-weight: 680;
  line-height: 1.2;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.workbench-grid {
  min-height: 0;
  display: grid;
  grid-template-columns: minmax(670px, 1fr) minmax(350px, 390px);
  grid-template-rows: auto minmax(0, 1fr);
  column-gap: 10px;
  row-gap: 8px;
  overflow: hidden;
}

.customer-workbench-layout > .metric-strip {
  grid-column: 1;
  grid-row: 1;
}

.customer-workbench-layout > .customer-list-panel {
  grid-column: 1;
  grid-row: 2;
}

.customer-workbench-layout > .customer-detail-panel {
  grid-column: 2;
  grid-row: 1 / span 2;
}

.customer-list-panel,
.customer-detail-panel {
  min-height: 0;
  min-width: 0;
  overflow: hidden;
}

.customer-list-panel {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
}

.panel-head {
  min-height: 48px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border-bottom: 1px solid rgba(116, 139, 166, 0.18);
  padding: 8px 12px;
}

.panel-tools {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  gap: 6px;
}

.new-analysis-filter-chip {
  min-height: 34px;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  border: 1px solid rgba(10, 132, 255, 0.22);
  border-radius: 999px;
  padding: 0 9px 0 10px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.90), rgba(241, 248, 255, 0.78)),
    radial-gradient(circle at 22% 0%, rgba(10, 132, 255, 0.10), transparent 54%);
  color: #135f9e;
  box-shadow:
    0 6px 16px rgba(15, 23, 42, 0.045),
    0 0 0 1px rgba(255, 255, 255, 0.56) inset;
  cursor: pointer;
  font-size: 12px;
  font-weight: 840;
  line-height: 1;
  white-space: nowrap;
  transition: border-color 0.18s ease, box-shadow 0.18s ease, color 0.18s ease, transform 0.18s ease, background 0.18s ease, opacity 0.18s ease;
}

.new-analysis-filter-chip:hover:not(:disabled),
.new-analysis-filter-chip.active,
.new-analysis-filter-chip[aria-pressed="true"] {
  border-color: rgba(10, 132, 255, 0.40);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(230, 244, 255, 0.88)),
    radial-gradient(circle at 20% 0%, rgba(10, 132, 255, 0.18), transparent 58%);
  color: #075a9f;
  box-shadow:
    0 8px 20px rgba(10, 132, 255, 0.11),
    0 0 0 1px rgba(255, 255, 255, 0.70) inset;
  transform: translateY(-1px);
}

.new-analysis-filter-chip:focus-visible {
  outline: 3px solid rgba(10, 132, 255, 0.22);
  outline-offset: 2px;
}

.new-analysis-filter-chip:disabled {
  cursor: not-allowed;
}

.new-analysis-filter-chip.is-empty:not(.active) {
  border-color: rgba(104, 126, 155, 0.20);
  background: rgba(255, 255, 255, 0.58);
  color: #8b9bb1;
  box-shadow: none;
  opacity: 0.72;
}

.new-analysis-filter-dot {
  width: 7px;
  height: 7px;
  flex: 0 0 auto;
  border-radius: 999px;
  background:
    radial-gradient(circle at 35% 32%, rgba(255, 255, 255, 0.96) 0 18%, transparent 19%),
    linear-gradient(180deg, #7cc4ff, #0a84ff);
  box-shadow: 0 0 0 3px rgba(10, 132, 255, 0.14);
}

.new-analysis-filter-chip.is-empty:not(.active) .new-analysis-filter-dot {
  background: #aab7c7;
  box-shadow: none;
}

.new-analysis-filter-chip b {
  min-width: 22px;
  height: 20px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  padding: 0 7px;
  background: rgba(10, 132, 255, 0.10);
  color: inherit;
  font-size: 11px;
  font-weight: 900;
  font-variant-numeric: tabular-nums;
}

.panel-head .new-analysis-filter-chip > span:not(.new-analysis-filter-dot),
:root:not([data-desktop-theme="light"]) .panel-head .new-analysis-filter-chip > span:not(.new-analysis-filter-dot),
:root[data-desktop-theme="dark"] .panel-head .new-analysis-filter-chip > span:not(.new-analysis-filter-dot) {
  color: inherit;
  font-size: inherit;
}

.new-analysis-filter-chip.active b,
.new-analysis-filter-chip[aria-pressed="true"] b {
  background: rgba(10, 132, 255, 0.14);
}

@media (prefers-color-scheme: dark) {
  :root:not([data-desktop-theme="light"]) .new-analysis-filter-chip {
    border-color: rgba(94, 176, 255, 0.28);
    background:
      linear-gradient(180deg, rgba(20, 32, 46, 0.92), rgba(12, 23, 35, 0.76)),
      radial-gradient(circle at 20% 0%, rgba(94, 176, 255, 0.16), transparent 58%);
    color: #9bd2ff;
    box-shadow:
      0 8px 20px rgba(0, 0, 0, 0.20),
      0 0 0 1px rgba(255, 255, 255, 0.06) inset;
  }

  :root:not([data-desktop-theme="light"]) .new-analysis-filter-chip:hover:not(:disabled),
  :root:not([data-desktop-theme="light"]) .new-analysis-filter-chip.active,
  :root:not([data-desktop-theme="light"]) .new-analysis-filter-chip[aria-pressed="true"] {
    border-color: rgba(94, 176, 255, 0.44);
    background:
      linear-gradient(180deg, rgba(24, 40, 58, 0.96), rgba(13, 28, 44, 0.86)),
      radial-gradient(circle at 20% 0%, rgba(94, 176, 255, 0.22), transparent 58%);
    color: #c5e8ff;
  }

  :root:not([data-desktop-theme="light"]) .new-analysis-filter-chip.is-empty:not(.active) {
    border-color: rgba(148, 163, 184, 0.18);
    background: rgba(15, 23, 42, 0.52);
    color: #738399;
  }
}

:root[data-desktop-theme="dark"] .new-analysis-filter-chip {
  border-color: rgba(94, 176, 255, 0.28);
  background:
    linear-gradient(180deg, rgba(20, 32, 46, 0.92), rgba(12, 23, 35, 0.76)),
    radial-gradient(circle at 20% 0%, rgba(94, 176, 255, 0.16), transparent 58%);
  color: #9bd2ff;
  box-shadow:
    0 8px 20px rgba(0, 0, 0, 0.20),
    0 0 0 1px rgba(255, 255, 255, 0.06) inset;
}

:root[data-desktop-theme="dark"] .new-analysis-filter-chip:hover:not(:disabled),
:root[data-desktop-theme="dark"] .new-analysis-filter-chip.active,
:root[data-desktop-theme="dark"] .new-analysis-filter-chip[aria-pressed="true"] {
  border-color: rgba(94, 176, 255, 0.44);
  background:
    linear-gradient(180deg, rgba(24, 40, 58, 0.96), rgba(13, 28, 44, 0.86)),
    radial-gradient(circle at 20% 0%, rgba(94, 176, 255, 0.22), transparent 58%);
  color: #c5e8ff;
}

:root[data-desktop-theme="dark"] .new-analysis-filter-chip.is-empty:not(.active) {
  border-color: rgba(148, 163, 184, 0.18);
  background: rgba(15, 23, 42, 0.52);
  color: #738399;
}

.panel-head h2 {
  margin: 0;
  color: #071426;
  font-size: 16px;
  font-weight: 820;
}

.panel-head select {
  width: 112px;
  min-height: 34px;
}

#pageSizeSelect {
  width: 82px;
}

.pager-btn {
  width: 32px;
  min-height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(104, 126, 155, 0.26);
  border-radius: 11px;
  background: rgba(255, 255, 255, 0.78);
  color: #334155;
  cursor: pointer;
  font-size: 18px;
  font-weight: 860;
}

.pager-btn:disabled {
  cursor: not-allowed;
  opacity: 0.45;
}

.page-info {
  min-width: 36px;
  color: #64748b;
  font-size: 12px;
  font-weight: 820;
  text-align: center;
  font-variant-numeric: tabular-nums;
}

.desktop-table-scroll {
  min-height: 0;
  overflow-y: auto;
  overflow-x: hidden;
}

.desktop-table {
  width: 100%;
  min-width: 0;
  border-collapse: collapse;
  table-layout: fixed;
}

.desktop-table th,
.desktop-table td {
  border-bottom: 1px solid rgba(135, 153, 177, 0.18);
  padding: 7px 10px;
  text-align: left;
  vertical-align: top;
}

.desktop-table th {
  position: sticky;
  top: 0;
  z-index: 2;
  background: rgba(246, 249, 253, 0.88);
  color: #66758c;
  font-size: 11px;
  font-weight: 860;
}

.desktop-table td {
  color: #334155;
  font-size: 12px;
  line-height: 1.3;
}

.desktop-table tbody tr {
  cursor: pointer;
  transition: background 0.16s ease;
}

.desktop-table tbody tr:hover td,
.desktop-table tbody tr.active td {
  background: rgba(10, 132, 255, 0.08);
}

.desktop-table tbody tr.active td:first-child {
  box-shadow: inset 3px 0 0 var(--desktop-primary);
}

.desktop-table tbody tr.is-new-analysis:not(:hover):not(.active) td {
  background: transparent;
}

.desktop-table tbody tr.is-new-analysis td:first-child {
  position: relative;
  overflow: hidden;
}

.desktop-table tbody tr.is-new-analysis:not(:hover):not(.active) td:first-child {
  background:
    radial-gradient(circle at 30px 22px, rgba(255, 255, 255, 0.64), transparent 34px),
    var(--desktop-new-analysis-bg);
}

.desktop-table tbody tr.is-new-analysis:hover td:first-child {
  background:
    radial-gradient(circle at 30px 22px, rgba(255, 255, 255, 0.68), transparent 34px),
    var(--desktop-new-analysis-bg-hover);
}

.desktop-table tbody tr.is-new-analysis td:first-child::before {
  content: "";
  position: absolute;
  left: 0;
  top: 11px;
  bottom: 11px;
  width: 3px;
  border-radius: 0 999px 999px 0;
  background: linear-gradient(180deg, #7cc4ff 0%, #0a84ff 58%, #9ad7ff 100%);
  box-shadow: 0 0 16px var(--desktop-new-analysis-glow);
  pointer-events: none;
}

.desktop-table tbody tr.is-new-analysis.active td:first-child {
  box-shadow: inset 3px 0 0 var(--desktop-primary);
}

.desktop-table th:nth-child(1),
.desktop-table td:nth-child(1) {
  width: 23%;
}

.desktop-table th:nth-child(2),
.desktop-table td:nth-child(2) {
  width: 14%;
}

.desktop-table th:nth-child(3),
.desktop-table td:nth-child(3) {
  width: 13%;
  text-align: center;
}

.desktop-table td:nth-child(3) {
  vertical-align: middle;
}

.desktop-table th:nth-child(4),
.desktop-table td:nth-child(4) {
  width: 34%;
}

.desktop-table th:nth-child(5),
.desktop-table td:nth-child(5) {
  width: 16%;
}

.customer-cell,
.action-cell,
.project-cell,
.quality-cell {
  display: grid;
  gap: 3px;
}

.customer-title-line {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 5px;
}

.customer-title-line > strong {
  min-width: 0;
  overflow-wrap: anywhere;
}

.new-analysis-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  flex: 0 0 auto;
  border: 1px solid var(--desktop-new-analysis-border);
  border-radius: 999px;
  padding: 1px 7px 1px 6px;
  background: var(--desktop-new-analysis-pill-bg);
  color: var(--desktop-new-analysis-text);
  font-size: 10px;
  font-weight: 850;
  line-height: 1.35;
  letter-spacing: 0.01em;
  white-space: nowrap;
  box-shadow:
    0 1px 2px rgba(15, 23, 42, 0.04),
    0 0 0 1px rgba(255, 255, 255, 0.56) inset;
  backdrop-filter: blur(10px);
  transform: translateZ(0);
  transition: border-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
}

.new-analysis-badge::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 999px;
  background:
    radial-gradient(circle at 35% 32%, rgba(255, 255, 255, 0.95) 0 18%, transparent 19%),
    linear-gradient(180deg, #63b3ff, #0a84ff);
  box-shadow: 0 0 0 3px var(--desktop-new-analysis-glow);
}

.desktop-table tbody tr:hover .new-analysis-badge {
  border-color: rgba(10, 132, 255, 0.34);
  box-shadow:
    0 4px 12px rgba(10, 132, 255, 0.10),
    0 0 0 1px rgba(255, 255, 255, 0.66) inset;
  transform: translateY(-1px);
}

.new-analysis-delta-line {
  max-width: 250px;
  display: block;
  overflow: hidden;
  margin-top: 4px;
  border-left: 2px solid rgba(10, 132, 255, 0.36);
  padding-left: 7px;
  color: #2563a7;
  font-size: 11px;
  font-weight: 720;
  line-height: 1.35;
  text-overflow: ellipsis;
  white-space: nowrap;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-desktop-theme="light"]) .desktop-table tbody tr.is-new-analysis:not(:hover):not(.active) td:first-child {
    background:
      radial-gradient(circle at 30px 22px, rgba(94, 176, 255, 0.10), transparent 34px),
      var(--desktop-new-analysis-bg);
  }

  :root:not([data-desktop-theme="light"]) .desktop-table tbody tr.is-new-analysis:hover td:first-child {
    background:
      radial-gradient(circle at 30px 22px, rgba(94, 176, 255, 0.14), transparent 34px),
      var(--desktop-new-analysis-bg-hover);
  }

  :root:not([data-desktop-theme="light"]) .new-analysis-badge {
    box-shadow:
      0 1px 2px rgba(0, 0, 0, 0.22),
      0 0 0 1px rgba(255, 255, 255, 0.06) inset;
  }

  :root:not([data-desktop-theme="light"]) .new-analysis-delta-line {
    border-left-color: rgba(94, 176, 255, 0.42);
    color: #9bd2ff;
  }
}

:root[data-desktop-theme="dark"] .desktop-table tbody tr.is-new-analysis:not(:hover):not(.active) td:first-child {
  background:
    radial-gradient(circle at 30px 22px, rgba(94, 176, 255, 0.10), transparent 34px),
    var(--desktop-new-analysis-bg);
}

:root[data-desktop-theme="dark"] .desktop-table tbody tr.is-new-analysis:hover td:first-child {
  background:
    radial-gradient(circle at 30px 22px, rgba(94, 176, 255, 0.14), transparent 34px),
    var(--desktop-new-analysis-bg-hover);
}

:root[data-desktop-theme="dark"] .new-analysis-badge {
  box-shadow:
    0 1px 2px rgba(0, 0, 0, 0.22),
    0 0 0 1px rgba(255, 255, 255, 0.06) inset;
}

:root[data-desktop-theme="dark"] .new-analysis-delta-line {
  border-left-color: rgba(94, 176, 255, 0.42);
  color: #9bd2ff;
}

@media (prefers-reduced-motion: no-preference) {
  .new-analysis-badge {
    animation: desktop-new-analysis-arrive 0.28s cubic-bezier(0.2, 0.8, 0.2, 1) both;
  }
}

@keyframes desktop-new-analysis-arrive {
  0% {
    opacity: 0;
    transform: translateY(2px) scale(0.96);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.customer-star-btn {
  width: 28px;
  height: 28px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 28px;
  margin: -4px 0 -4px -5px;
  border: 0;
  border-radius: 7px;
  padding: 0;
  background: transparent;
  color: #94a3b8;
  cursor: pointer;
  transition: color 0.18s ease, background 0.18s ease, box-shadow 0.18s ease;
}

.customer-star-btn svg {
  width: 17px;
  height: 17px;
  fill: transparent;
  stroke: currentColor;
}

.customer-star-btn:hover {
  background: rgba(245, 158, 11, 0.12);
  color: #d97706;
}

.customer-star-btn:focus-visible {
  outline: none;
  box-shadow: 0 0 0 3px rgba(245, 158, 11, 0.22);
}

.customer-star-btn.is-starred {
  color: #d97706;
}

.customer-star-btn.is-starred svg {
  fill: currentColor;
}

.customer-star-btn:disabled {
  cursor: wait;
  opacity: 0.55;
}

.customer-cell strong,
.action-cell strong,
.project-cell strong {
  color: #0b1220;
  font-size: 13px;
  font-weight: 760;
}

.customer-cell span,
.action-cell span,
.project-cell span,
.quality-cell small,
.cell-muted {
  color: #60708a;
  font-size: 11px;
}

.customer-cell .level-badge-wrap,
.overdue-customer-cell .level-badge-wrap {
  justify-self: start;
  min-height: 22px;
  gap: 0;
  border-color: rgba(100, 116, 139, 0.14);
  padding: 1px 4px;
  background: rgba(248, 250, 252, 0.88);
}

.customer-cell .level-badge-img,
.overdue-customer-cell .level-badge-img {
  width: 28px;
  border-radius: 3px;
}

.customer-cell .level-badge-text,
.overdue-customer-cell .level-badge-text {
  display: none;
}

.customer-cell .level-text-fallback,
.overdue-customer-cell .level-text-fallback {
  justify-self: start;
  min-height: 22px;
  padding: 2px 7px;
  border: 1px solid rgba(100, 116, 139, 0.14);
  background: rgba(248, 250, 252, 0.88);
  color: #334155 !important;
  font-size: 11px !important;
  font-weight: 740;
}

.quality-cell {
  align-content: center;
  justify-items: center;
  gap: 5px;
}

.quality-evidence-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  min-height: 32px;
  max-width: 100%;
  padding: 3px 4px;
  border: 0;
  border-radius: 6px;
  color: var(--desktop-text);
  background: transparent;
  cursor: pointer;
}

.quality-evidence-button:hover { background: var(--desktop-primary-soft); }
.quality-evidence-button:focus-visible { outline: 2px solid var(--desktop-primary); outline-offset: 2px; }
.quality-evidence-button svg { width: 14px; height: 14px; flex: 0 0 14px; fill: none; stroke: currentColor; stroke-width: 1.8; color: var(--desktop-muted); }
.quality-evidence-button .quality-score { font-size: 11px; font-weight: 650; font-variant-numeric: tabular-nums; white-space: nowrap; }
.quality-cell .quality-summary { color: var(--desktop-muted); font-size: 11px; line-height: 1.5; text-align: center; overflow-wrap: anywhere; }

.inquiry-quality-dialog {
  width: min(480px, calc(100vw - 32px));
  max-height: calc(100dvh - 48px);
  margin: auto;
  padding: 24px;
  overflow: auto;
  border: 1px solid var(--desktop-border-strong);
  border-radius: 8px;
  background: var(--desktop-bg);
  color: var(--desktop-text);
  box-shadow: var(--desktop-shadow);
}

.inquiry-quality-dialog::backdrop { background: rgba(0, 0, 0, .45); }
.inquiry-quality-dialog header { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; }
.inquiry-quality-dialog h2 { margin: 0; font-size: 18px; line-height: 1.5; }
.inquiry-quality-dialog header p { margin: 4px 0 0; color: var(--desktop-muted); overflow-wrap: anywhere; }
.inquiry-quality-dialog .quality-close { width: 32px; height: 32px; border: 1px solid var(--desktop-border); border-radius: 6px; background: var(--desktop-surface-soft); color: var(--desktop-text); font-size: 22px; cursor: pointer; }
.quality-dialog-rating { display: flex; align-items: center; gap: 10px; margin: 20px 0 12px; }
.inquiry-quality-dialog ul { margin: 0; padding-left: 18px; font-size: 13px; line-height: 1.8; overflow-wrap: anywhere; }
.inquiry-quality-dialog li + li { margin-top: 8px; }
.inquiry-quality-dialog .quality-as-of { margin: 20px 0 0; padding-top: 12px; border-top: 1px solid var(--desktop-border); color: var(--desktop-muted); font-size: 12px; }

@media (max-width: 600px) {
  .inquiry-quality-dialog { padding: 18px; }
}

.quality-grade {
  width: fit-content;
  min-width: 28px;
  border-radius: 999px;
  padding: 2px 7px;
  background: rgba(255, 159, 10, 0.12);
  color: #9a5b00;
  font-size: 11px;
  font-weight: 840;
  line-height: 1.4;
  text-align: center;
}

.quality-grade.ok {
  background: rgba(48, 164, 108, 0.12);
  color: #167a4a;
}

.quality-grade.danger {
  background: rgba(255, 59, 48, 0.11);
  color: #d70015;
}

.quality-grade.muted {
  background: rgba(100, 116, 139, 0.12);
  color: #526276;
}

.quality-cell strong {
  color: #334155;
  font-size: 11px;
  font-weight: 760;
  font-variant-numeric: tabular-nums;
}

.level-badge-wrap {
  width: fit-content;
  max-width: 100%;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  border: 1px solid rgba(76, 150, 236, 0.28);
  border-radius: 999px;
  padding: 1px 6px;
  background: rgba(238, 246, 255, 0.92);
  vertical-align: middle;
}

.level-badge-img {
  width: 32px;
  height: auto;
  display: block;
  border-radius: 4px;
  background: #ffffff;
}

.level-badge-text {
  color: #32608f;
  font-size: 11px;
  font-weight: 720;
  line-height: 1.2;
  white-space: nowrap;
}

.level-text-fallback {
  width: fit-content;
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 2px 7px;
  background: rgba(238, 242, 247, 0.92);
  color: #526276 !important;
  font-size: 11px !important;
  font-weight: 720;
}

.line-clamp-2,
.line-clamp-3,
.line-clamp-1 {
  display: -webkit-box;
  overflow: hidden;
  -webkit-box-orient: vertical;
}

.line-clamp-1 {
  -webkit-line-clamp: 1;
}

.line-clamp-2 {
  -webkit-line-clamp: 2;
}

.line-clamp-3 {
  -webkit-line-clamp: 3;
}

.pill-row {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}

.tag {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 3px 7px;
  background: rgba(10, 132, 255, 0.10);
  color: #0057c2;
  font-size: 11px;
  font-weight: 820;
}

.tag.danger {
  background: rgba(255, 59, 48, 0.11);
  color: #d70015;
}

.tag.warn {
  background: rgba(255, 159, 10, 0.13);
  color: #9a5b00;
}

.tag.ok {
  background: rgba(48, 164, 108, 0.12);
  color: #167a4a;
}

.tag.repeat {
  background: rgba(13, 148, 136, 0.13);
  color: #0f766e;
}

.tag.cultivate {
  background: rgba(100, 116, 139, 0.13);
  color: #475569;
}

.tag.customer-brand {
  background: #f3e8ff;
  color: #6b21a8;
}

.tag.customer-importer {
  background: #eef2ff;
  color: #3730a3;
}

.tag.customer-retail {
  background: #ecfeff;
  color: #155e75;
}

.tag.customer-contractor {
  background: #fff7ed;
  color: #9a3412;
}

.tag.customer-soho {
  background: #fdf4ff;
  color: #86198f;
}

.tag.customer-amazon {
  background: #fffbeb;
  color: #92400e;
}

.tag.customer-small-b {
  background: #fdf2f8;
  color: #9d174d;
}

.tag.customer-independent {
  background: #f0fdfa;
  color: #115e59;
}

.tag.customer-offline-wholesale {
  background: #f0fdf4;
  color: #166534;
}

.tag.customer-prospect {
  background: #f0f9ff;
  color: #075985;
}

.tag.customer-other {
  background: #f1f5f9;
  color: #475569;
}

.customer-detail-panel {
  display: grid;
  grid-template-rows: minmax(0, 1fr);
  max-height: 100%;
  background: rgba(246, 249, 253, 0.72);
}

.detail-empty {
  place-self: center;
  max-width: 250px;
  display: grid;
  gap: 8px;
  color: #64748b;
  text-align: center;
}

.detail-empty strong {
  color: #0f172a;
  font-size: 18px;
}

.detail-content {
  height: 100%;
  min-height: 0;
  overflow: auto;
  overscroll-behavior: contain;
  padding: 0 14px 14px;
  scrollbar-gutter: stable;
}

.detail-sticky {
  position: sticky;
  top: 0;
  z-index: 3;
  padding-top: 14px;
  background: rgba(246, 249, 253, 0.88);
  backdrop-filter: var(--desktop-blur);
}

.detail-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  border-bottom: 1px solid rgba(116, 139, 166, 0.18);
  padding-bottom: 11px;
}

.detail-head strong {
  display: block;
  color: #0f172a;
  font-size: 17px;
  line-height: 1.25;
}

#detailCustomerMeta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 5px;
  margin-top: 3px;
}

#detailCustomerMeta .level-badge-wrap {
  min-height: 22px;
  gap: 0;
  border-color: rgba(100, 116, 139, 0.14);
  padding: 1px 4px;
  background: rgba(248, 250, 252, 0.88);
}

#detailCustomerMeta .level-badge-img {
  width: 28px;
  border-radius: 3px;
}

#detailCustomerMeta .level-badge-text {
  display: none;
}

#detailAiBadge {
  min-height: 28px;
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 5px 9px;
  background: rgba(48, 164, 108, 0.12);
  color: #167a4a;
  font-size: 12px;
  font-weight: 860;
}

.detail-grid {
  margin-top: 10px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.detail-grid div {
  min-width: 0;
  min-height: 60px;
  display: grid;
  align-content: center;
  gap: 6px;
  border: 1px solid rgba(104, 126, 155, 0.20);
  border-radius: 13px;
  padding: 8px 10px;
  background: rgba(255, 255, 255, 0.78);
}

.detail-grid strong {
  overflow-wrap: anywhere;
  color: #0f172a;
  font-size: 13px;
}

.analysis-delta-card {
  margin-top: 10px;
  border: 1px solid rgba(10, 132, 255, 0.22);
  border-radius: 16px;
  padding: 11px;
  background:
    linear-gradient(180deg, rgba(247, 251, 255, 0.94), rgba(255, 255, 255, 0.82)),
    radial-gradient(circle at 12% 0%, rgba(10, 132, 255, 0.11), transparent 60%);
  box-shadow:
    0 12px 28px rgba(15, 23, 42, 0.08),
    0 1px 0 rgba(255, 255, 255, 0.88) inset;
}

.analysis-delta-card.is-urgent {
  border-color: rgba(220, 38, 38, 0.22);
  background:
    linear-gradient(180deg, rgba(255, 248, 248, 0.96), rgba(255, 255, 255, 0.82)),
    radial-gradient(circle at 12% 0%, rgba(220, 38, 38, 0.10), transparent 60%);
}

.analysis-delta-card.is-warning {
  border-color: rgba(255, 159, 10, 0.26);
  background:
    linear-gradient(180deg, rgba(255, 251, 242, 0.96), rgba(255, 255, 255, 0.82)),
    radial-gradient(circle at 12% 0%, rgba(255, 159, 10, 0.12), transparent 60%);
}

.analysis-delta-card.is-positive {
  border-color: rgba(27, 138, 89, 0.22);
  background:
    linear-gradient(180deg, rgba(244, 253, 249, 0.96), rgba(255, 255, 255, 0.82)),
    radial-gradient(circle at 12% 0%, rgba(27, 138, 89, 0.11), transparent 60%);
}

.analysis-delta-card[hidden] {
  display: none;
}

.analysis-delta-card-head {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: start;
  gap: 9px;
}

.analysis-delta-card-mark {
  width: 25px;
  height: 25px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: linear-gradient(180deg, #78c6ff, #0a84ff);
  color: #ffffff;
  font-size: 11px;
  font-weight: 900;
  box-shadow: 0 0 0 4px rgba(10, 132, 255, 0.11);
}

.analysis-delta-card.is-urgent .analysis-delta-card-mark {
  background: linear-gradient(180deg, #ff8f8f, #dc2626);
  box-shadow: 0 0 0 4px rgba(220, 38, 38, 0.10);
}

.analysis-delta-card.is-warning .analysis-delta-card-mark {
  background: linear-gradient(180deg, #ffc978, #f59e0b);
  box-shadow: 0 0 0 4px rgba(245, 158, 11, 0.12);
}

.analysis-delta-card.is-positive .analysis-delta-card-mark {
  background: linear-gradient(180deg, #6ee7a7, #168a54);
  box-shadow: 0 0 0 4px rgba(22, 138, 84, 0.12);
}

.analysis-delta-card-head strong {
  display: block;
  color: #0f172a;
  font-size: 13px;
  font-weight: 880;
  line-height: 1.35;
}

.analysis-delta-card-head small {
  display: block;
  margin-top: 2px;
  color: #52647a;
  font-size: 11px;
  font-weight: 650;
  line-height: 1.5;
}

.analysis-delta-card-body {
  display: grid;
  gap: 8px;
  margin-top: 10px;
}

.analysis-delta-action {
  display: grid;
  gap: 5px;
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 13px;
  padding: 8px 9px;
  background: rgba(255, 255, 255, 0.74);
  box-shadow: inset 3px 0 0 rgba(10, 132, 255, 0.32);
}

.analysis-delta-action span,
.analysis-delta-evidence > span {
  color: #64748b;
  font-size: 11px;
  font-weight: 780;
}

.analysis-delta-action strong {
  color: #0f172a;
  font-size: 12px;
  font-weight: 780;
  line-height: 1.55;
}

.analysis-delta-evidence {
  display: grid;
  gap: 5px;
  border-top: 1px dashed rgba(104, 126, 155, 0.22);
  padding-top: 8px;
}

.analysis-delta-evidence ul {
  display: grid;
  gap: 4px;
  margin: 0;
  padding-left: 16px;
}

.analysis-delta-evidence li {
  color: #42526a;
  font-size: 11px;
  font-weight: 650;
  line-height: 1.45;
}

.analysis-delta-change-list {
  display: grid;
  gap: 6px;
}

.analysis-delta-change {
  min-width: 0;
  display: grid;
  grid-template-columns: 54px minmax(0, 1fr) auto minmax(0, 1fr);
  align-items: center;
  gap: 6px;
  border: 1px solid rgba(104, 126, 155, 0.16);
  border-radius: 12px;
  padding: 7px 8px;
  background: rgba(255, 255, 255, 0.72);
}

.analysis-delta-change span {
  color: #64748b;
  font-size: 11px;
  font-weight: 760;
}

.analysis-delta-change strong {
  overflow: hidden;
  color: #0f172a;
  font-size: 12px;
  font-weight: 830;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.analysis-delta-change b {
  color: #7c8da3;
  font-size: 12px;
}

.analysis-delta-change.is-positive {
  border-color: rgba(27, 138, 89, 0.20);
  background: rgba(241, 252, 247, 0.78);
}

.analysis-delta-change.is-warning {
  border-color: rgba(255, 159, 10, 0.24);
  background: rgba(255, 250, 238, 0.82);
}

.analysis-delta-chip-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
}

.analysis-delta-chip-row > span {
  color: #64748b;
  font-size: 11px;
  font-weight: 780;
}

.analysis-delta-chip {
  border-radius: 999px;
  padding: 4px 8px;
  font-size: 11px;
  font-weight: 820;
  line-height: 1;
}

.analysis-delta-chip.signal {
  background: rgba(27, 138, 89, 0.12);
  color: #167a4a;
}

.analysis-delta-chip.blocker {
  background: rgba(255, 159, 10, 0.14);
  color: #9a5a00;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-desktop-theme="light"]) .analysis-delta-card {
    border-color: rgba(94, 176, 255, 0.24);
    background:
      linear-gradient(180deg, rgba(20, 32, 46, 0.92), rgba(12, 23, 35, 0.82)),
      radial-gradient(circle at 12% 0%, rgba(94, 176, 255, 0.14), transparent 60%);
    box-shadow:
      0 16px 32px rgba(0, 0, 0, 0.26),
      0 1px 0 rgba(255, 255, 255, 0.06) inset;
  }

  :root:not([data-desktop-theme="light"]) .analysis-delta-card.is-urgent {
    border-color: rgba(255, 129, 129, 0.28);
    background:
      linear-gradient(180deg, rgba(46, 22, 26, 0.92), rgba(24, 17, 22, 0.84)),
      radial-gradient(circle at 12% 0%, rgba(255, 129, 129, 0.14), transparent 60%);
  }

  :root:not([data-desktop-theme="light"]) .analysis-delta-card.is-warning {
    border-color: rgba(255, 191, 92, 0.30);
    background:
      linear-gradient(180deg, rgba(48, 36, 18, 0.92), rgba(25, 21, 15, 0.84)),
      radial-gradient(circle at 12% 0%, rgba(255, 179, 64, 0.14), transparent 60%);
  }

  :root:not([data-desktop-theme="light"]) .analysis-delta-card.is-positive {
    border-color: rgba(78, 214, 134, 0.26);
    background:
      linear-gradient(180deg, rgba(18, 41, 31, 0.92), rgba(13, 24, 22, 0.84)),
      radial-gradient(circle at 12% 0%, rgba(69, 196, 125, 0.14), transparent 60%);
  }

  :root:not([data-desktop-theme="light"]) .analysis-delta-card-head strong,
  :root:not([data-desktop-theme="light"]) .analysis-delta-change strong,
  :root:not([data-desktop-theme="light"]) .analysis-delta-action strong {
    color: #f5fbff;
  }

  :root:not([data-desktop-theme="light"]) .analysis-delta-card-head small,
  :root:not([data-desktop-theme="light"]) .analysis-delta-change span,
  :root:not([data-desktop-theme="light"]) .analysis-delta-chip-row > span,
  :root:not([data-desktop-theme="light"]) .analysis-delta-action span,
  :root:not([data-desktop-theme="light"]) .analysis-delta-evidence > span {
    color: #9eb3c9;
  }

  :root:not([data-desktop-theme="light"]) .analysis-delta-action {
    border-color: rgba(148, 163, 184, 0.14);
    background: rgba(15, 23, 42, 0.42);
    box-shadow: inset 3px 0 0 rgba(94, 176, 255, 0.34);
  }

  :root:not([data-desktop-theme="light"]) .analysis-delta-evidence {
    border-top-color: rgba(148, 163, 184, 0.18);
  }

  :root:not([data-desktop-theme="light"]) .analysis-delta-evidence li {
    color: #c5d3e2;
  }

  :root:not([data-desktop-theme="light"]) .analysis-delta-change {
    border-color: rgba(148, 163, 184, 0.16);
    background: rgba(15, 23, 42, 0.46);
  }

  :root:not([data-desktop-theme="light"]) .analysis-delta-change.is-positive {
    border-color: rgba(78, 214, 134, 0.28);
    background: rgba(69, 196, 125, 0.12);
  }

  :root:not([data-desktop-theme="light"]) .analysis-delta-change.is-warning {
    border-color: rgba(255, 191, 92, 0.30);
    background: rgba(255, 179, 64, 0.12);
  }

  :root:not([data-desktop-theme="light"]) .analysis-delta-chip.signal {
    background: rgba(69, 196, 125, 0.16);
    color: #a4edc2;
  }

  :root:not([data-desktop-theme="light"]) .analysis-delta-chip.blocker {
    background: rgba(255, 179, 64, 0.16);
    color: #ffd08a;
  }
}

:root[data-desktop-theme="dark"] .analysis-delta-card {
  border-color: rgba(94, 176, 255, 0.24);
  background:
    linear-gradient(180deg, rgba(20, 32, 46, 0.92), rgba(12, 23, 35, 0.82)),
    radial-gradient(circle at 12% 0%, rgba(94, 176, 255, 0.14), transparent 60%);
  box-shadow:
    0 16px 32px rgba(0, 0, 0, 0.26),
    0 1px 0 rgba(255, 255, 255, 0.06) inset;
}

:root[data-desktop-theme="dark"] .analysis-delta-card.is-urgent {
  border-color: rgba(255, 129, 129, 0.28);
  background:
    linear-gradient(180deg, rgba(46, 22, 26, 0.92), rgba(24, 17, 22, 0.84)),
    radial-gradient(circle at 12% 0%, rgba(255, 129, 129, 0.14), transparent 60%);
}

:root[data-desktop-theme="dark"] .analysis-delta-card.is-warning {
  border-color: rgba(255, 191, 92, 0.30);
  background:
    linear-gradient(180deg, rgba(48, 36, 18, 0.92), rgba(25, 21, 15, 0.84)),
    radial-gradient(circle at 12% 0%, rgba(255, 179, 64, 0.14), transparent 60%);
}

:root[data-desktop-theme="dark"] .analysis-delta-card.is-positive {
  border-color: rgba(78, 214, 134, 0.26);
  background:
    linear-gradient(180deg, rgba(18, 41, 31, 0.92), rgba(13, 24, 22, 0.84)),
    radial-gradient(circle at 12% 0%, rgba(69, 196, 125, 0.14), transparent 60%);
}

:root[data-desktop-theme="dark"] .analysis-delta-card-head strong,
:root[data-desktop-theme="dark"] .analysis-delta-change strong,
:root[data-desktop-theme="dark"] .analysis-delta-action strong {
  color: #f5fbff;
}

:root[data-desktop-theme="dark"] .analysis-delta-card-head small,
:root[data-desktop-theme="dark"] .analysis-delta-change span,
:root[data-desktop-theme="dark"] .analysis-delta-chip-row > span,
:root[data-desktop-theme="dark"] .analysis-delta-action span,
:root[data-desktop-theme="dark"] .analysis-delta-evidence > span {
  color: #9eb3c9;
}

:root[data-desktop-theme="dark"] .analysis-delta-action {
  border-color: rgba(148, 163, 184, 0.14);
  background: rgba(15, 23, 42, 0.42);
  box-shadow: inset 3px 0 0 rgba(94, 176, 255, 0.34);
}

:root[data-desktop-theme="dark"] .analysis-delta-evidence {
  border-top-color: rgba(148, 163, 184, 0.18);
}

:root[data-desktop-theme="dark"] .analysis-delta-evidence li {
  color: #c5d3e2;
}

:root[data-desktop-theme="dark"] .analysis-delta-change {
  border-color: rgba(148, 163, 184, 0.16);
  background: rgba(15, 23, 42, 0.46);
}

:root[data-desktop-theme="dark"] .analysis-delta-change.is-positive {
  border-color: rgba(78, 214, 134, 0.28);
  background: rgba(69, 196, 125, 0.12);
}

:root[data-desktop-theme="dark"] .analysis-delta-change.is-warning {
  border-color: rgba(255, 191, 92, 0.30);
  background: rgba(255, 179, 64, 0.12);
}

:root[data-desktop-theme="dark"] .analysis-delta-chip.signal {
  background: rgba(69, 196, 125, 0.16);
  color: #a4edc2;
}

:root[data-desktop-theme="dark"] .analysis-delta-chip.blocker {
  background: rgba(255, 179, 64, 0.16);
  color: #ffd08a;
}

.detail-insight-grid {
  margin-top: 10px;
  display: grid;
  gap: 8px;
}

.detail-insight-card {
  min-width: 0;
  display: grid;
  gap: 6px;
  border: 1px solid rgba(104, 126, 155, 0.20);
  border-radius: 13px;
  padding: 10px 11px;
  background: rgba(255, 255, 255, 0.78);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.84) inset;
}

.detail-insight-card[hidden] {
  display: none !important;
}

.detail-insight-card.demand {
  border-color: rgba(27, 138, 89, 0.24);
  background: linear-gradient(180deg, rgba(241, 252, 247, 0.94), rgba(255, 255, 255, 0.78));
  box-shadow: inset 3px 0 0 rgba(27, 138, 89, 0.40);
}

.detail-insight-card.blocker {
  border-color: rgba(255, 159, 10, 0.26);
  background: linear-gradient(180deg, rgba(255, 250, 238, 0.94), rgba(255, 255, 255, 0.78));
  box-shadow: inset 3px 0 0 rgba(255, 159, 10, 0.38);
}

.detail-insight-card.pain {
  border-color: rgba(10, 132, 255, 0.22);
  background: linear-gradient(180deg, rgba(242, 248, 255, 0.92), rgba(255, 255, 255, 0.78));
  box-shadow: inset 3px 0 0 rgba(10, 132, 255, 0.34);
}

.detail-insight-card.mistake {
  border-color: rgba(255, 59, 48, 0.20);
  background: linear-gradient(180deg, rgba(255, 245, 244, 0.92), rgba(255, 255, 255, 0.78));
  box-shadow: inset 3px 0 0 rgba(255, 59, 48, 0.28);
}

.detail-insight-card strong {
  display: block;
  max-height: none;
  overflow: visible;
  overflow-wrap: anywhere;
  white-space: normal;
  color: #0f172a;
  font-size: 13px;
  line-height: 1.48;
}

.detail-insight-card small {
  display: block;
  overflow-wrap: anywhere;
  color: var(--desktop-muted);
  font-size: 11px;
  line-height: 1.55;
}

.detail-snapshot {
  margin-top: 8px;
  display: grid;
  gap: 4px;
  border: 1px solid rgba(104, 126, 155, 0.20);
  border-radius: 13px;
  padding: 8px 10px;
  background: rgba(255, 255, 255, 0.78);
}

.detail-snapshot span {
  overflow: hidden;
  color: #64748b;
  font-size: 12px;
  line-height: 1.35;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.detail-context-line {
  margin-top: 8px;
  display: block;
  min-height: 30px;
  border: 1px solid rgba(104, 126, 155, 0.14);
  border-radius: 11px;
  padding: 6px 10px;
  background: rgba(248, 250, 253, 0.62);
}

.detail-context-line span {
  display: block;
  overflow: visible;
  overflow-wrap: anywhere;
  line-height: 1.35;
  white-space: normal;
}

.detail-context-line .detail-value-line {
  margin-top: 4px;
  color: #334155;
  font-weight: 760;
}

.detail-block {
  margin-top: 10px;
  border: 1px solid rgba(104, 126, 155, 0.20);
  border-radius: 13px;
  padding: 10px;
  background: rgba(255, 255, 255, 0.78);
}

.detail-block h3 {
  margin: 0 0 7px;
  font-weight: 860;
}

.detail-block p {
  margin: 0;
  color: #0f172a;
  font-size: 13px;
  line-height: 1.55;
}

.detail-actions {
  margin: 0 -2px;
  padding: 10px 2px 8px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.detail-actions .desktop-btn {
  min-height: 36px;
}

.detail-actions .desktop-btn.primary {
  border-color: rgba(0, 122, 255, 0.18);
  background: rgba(0, 122, 255, 0.11);
  color: #0066cc;
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.82) inset;
}

.detail-actions .desktop-btn.primary:hover {
  background: rgba(0, 122, 255, 0.16);
  color: #0057b8;
}

.quick-form .desktop-btn.primary {
  background: #007aff;
  color: #ffffff;
  box-shadow: none;
}

.quick-form {
  margin-top: 10px;
  display: grid;
  gap: 8px;
  border: 1px solid rgba(10, 132, 255, 0.20);
  border-radius: 14px;
  padding: 10px;
  background: linear-gradient(180deg, rgba(247, 251, 255, 0.92), rgba(255, 255, 255, 0.72));
}

.form-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 8px;
}

.form-head strong {
  color: #0f172a;
}

.form-head span {
  text-align: right;
}

.quick-form textarea {
  min-height: 70px;
  resize: vertical;
}

.desktop-toast {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 20;
  max-width: 360px;
  transform: translateY(18px);
  border: 1px solid rgba(15, 23, 42, 0.12);
  border-radius: 10px;
  padding: 10px 12px;
  background: rgba(15, 23, 42, 0.94);
  color: #ffffff;
  font-size: 13px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.18s ease, transform 0.18s ease;
}

.desktop-toast.show {
  transform: translateY(0);
  opacity: 1;
}

.new-analysis-arrival-notice {
  position: fixed;
  right: 18px;
  bottom: 68px;
  z-index: 21;
  width: min(390px, calc(100vw - 36px));
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 10px;
  border: 1px solid rgba(10, 132, 255, 0.22);
  border-radius: 18px;
  padding: 11px 10px 11px 12px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.94), rgba(239, 247, 255, 0.88)),
    radial-gradient(circle at 16% 0%, rgba(10, 132, 255, 0.14), transparent 56%);
  color: #0f2742;
  box-shadow:
    0 18px 44px rgba(15, 23, 42, 0.14),
    0 0 0 1px rgba(255, 255, 255, 0.62) inset;
  opacity: 0;
  pointer-events: none;
  transform: translateY(14px) scale(0.98);
  backdrop-filter: blur(18px);
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.new-analysis-arrival-notice.show {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0) scale(1);
}

.new-analysis-arrival-notice[hidden] {
  display: none;
}

.new-analysis-arrival-dot {
  width: 10px;
  height: 10px;
  border-radius: 999px;
  background:
    radial-gradient(circle at 35% 32%, rgba(255, 255, 255, 0.96) 0 18%, transparent 19%),
    linear-gradient(180deg, #78c6ff, #0a84ff);
  box-shadow: 0 0 0 4px rgba(10, 132, 255, 0.14), 0 0 18px rgba(10, 132, 255, 0.24);
}

.new-analysis-arrival-copy {
  min-width: 0;
  display: grid;
  gap: 3px;
}

.new-analysis-arrival-copy strong {
  overflow: hidden;
  color: #071426;
  font-size: 13px;
  font-weight: 880;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.new-analysis-arrival-copy small {
  overflow: hidden;
  color: #52647a;
  font-size: 12px;
  font-weight: 650;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.new-analysis-arrival-action,
.new-analysis-arrival-close {
  min-height: 34px;
  border: 1px solid rgba(10, 132, 255, 0.22);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.76);
  color: #075a9f;
  cursor: pointer;
  font-size: 12px;
  font-weight: 840;
  white-space: nowrap;
  transition: border-color 0.18s ease, background 0.18s ease, color 0.18s ease, transform 0.18s ease;
}

.new-analysis-arrival-action {
  padding: 0 12px;
}

.new-analysis-arrival-close {
  width: 34px;
  padding: 0;
  color: #718096;
  font-size: 17px;
  line-height: 1;
}

.new-analysis-arrival-action:hover,
.new-analysis-arrival-close:hover {
  border-color: rgba(10, 132, 255, 0.36);
  background: rgba(230, 244, 255, 0.92);
  color: #075a9f;
  transform: translateY(-1px);
}

.new-analysis-arrival-action:focus-visible,
.new-analysis-arrival-close:focus-visible {
  outline: 3px solid rgba(10, 132, 255, 0.20);
  outline-offset: 2px;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-desktop-theme="light"]) .new-analysis-arrival-notice {
    border-color: rgba(94, 176, 255, 0.28);
    background:
      linear-gradient(180deg, rgba(22, 35, 52, 0.94), rgba(12, 23, 35, 0.88)),
      radial-gradient(circle at 16% 0%, rgba(94, 176, 255, 0.18), transparent 56%);
    color: #dceeff;
    box-shadow:
      0 22px 50px rgba(0, 0, 0, 0.34),
      0 0 0 1px rgba(255, 255, 255, 0.06) inset;
  }

  :root:not([data-desktop-theme="light"]) .new-analysis-arrival-copy strong {
    color: #f5fbff;
  }

  :root:not([data-desktop-theme="light"]) .new-analysis-arrival-copy small {
    color: #9eb3c9;
  }

  :root:not([data-desktop-theme="light"]) .new-analysis-arrival-action,
  :root:not([data-desktop-theme="light"]) .new-analysis-arrival-close {
    border-color: rgba(94, 176, 255, 0.26);
    background: rgba(15, 31, 48, 0.78);
    color: #a9dcff;
  }

  :root:not([data-desktop-theme="light"]) .new-analysis-arrival-action:hover,
  :root:not([data-desktop-theme="light"]) .new-analysis-arrival-close:hover {
    border-color: rgba(94, 176, 255, 0.42);
    background: rgba(22, 48, 74, 0.92);
    color: #d7efff;
  }
}

:root[data-desktop-theme="dark"] .new-analysis-arrival-notice {
  border-color: rgba(94, 176, 255, 0.28);
  background:
    linear-gradient(180deg, rgba(22, 35, 52, 0.94), rgba(12, 23, 35, 0.88)),
    radial-gradient(circle at 16% 0%, rgba(94, 176, 255, 0.18), transparent 56%);
  color: #dceeff;
  box-shadow:
    0 22px 50px rgba(0, 0, 0, 0.34),
    0 0 0 1px rgba(255, 255, 255, 0.06) inset;
}

:root[data-desktop-theme="dark"] .new-analysis-arrival-copy strong {
  color: #f5fbff;
}

:root[data-desktop-theme="dark"] .new-analysis-arrival-copy small {
  color: #9eb3c9;
}

:root[data-desktop-theme="dark"] .new-analysis-arrival-action,
:root[data-desktop-theme="dark"] .new-analysis-arrival-close {
  border-color: rgba(94, 176, 255, 0.26);
  background: rgba(15, 31, 48, 0.78);
  color: #a9dcff;
}

:root[data-desktop-theme="dark"] .new-analysis-arrival-action:hover,
:root[data-desktop-theme="dark"] .new-analysis-arrival-close:hover {
  border-color: rgba(94, 176, 255, 0.42);
  background: rgba(22, 48, 74, 0.92);
  color: #d7efff;
}

.desktop-offline-banner {
  display: none;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  border: 1px solid rgba(255, 159, 10, 0.26);
  border-radius: 14px;
  padding: 8px 10px;
  background: rgba(255, 250, 238, 0.94);
  color: #7c3d00;
  box-shadow: 0 10px 28px rgba(146, 64, 14, 0.08);
}

.desktop-offline-banner.show {
  display: flex;
}

.desktop-offline-icon {
  width: 28px;
  height: 28px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  border-radius: 999px;
  background: rgba(255, 159, 10, 0.14);
  color: #b45309;
}

.desktop-offline-copy {
  min-width: 0;
  display: grid;
  gap: 1px;
  flex: 1 1 auto;
}

.desktop-offline-copy strong {
  font-size: 13px;
  line-height: 1.25;
  color: #7c2d12;
}

.desktop-offline-copy small {
  font-size: 12px;
  line-height: 1.35;
  color: #9a3412;
}

.desktop-offline-retry {
  flex: 0 0 auto;
  min-height: 30px;
  padding-inline: 12px;
}

.desktop-offline-retry:disabled {
  opacity: 0.62;
  cursor: wait;
}

body.is-loading .desktop-main {
  cursor: progress;
}

.desktop-settings-main {
  grid-template-rows: auto minmax(0, 1fr);
}

.settings-layout {
  min-height: 0;
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(330px, 0.85fr);
  gap: 10px;
  overflow: hidden;
}

.settings-column {
  min-width: 0;
  min-height: 0;
  display: grid;
  align-content: start;
  gap: 10px;
  overflow: auto;
  padding-bottom: 2px;
}

.settings-panel {
  min-width: 0;
  border: 1px solid var(--desktop-border);
  border-radius: 16px;
  background: var(--desktop-surface);
  box-shadow: var(--desktop-shadow-soft);
  backdrop-filter: var(--desktop-blur);
}

.settings-panel-head {
  min-height: 66px;
  display: flex;
  align-items: center;
  gap: 12px;
  border-bottom: 1px solid rgba(116, 139, 166, 0.16);
  padding: 14px;
}

.settings-card-icon {
  width: 36px;
  height: 36px;
  flex: 0 0 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(10, 132, 255, 0.18);
  border-radius: 12px;
  background: rgba(10, 132, 255, 0.1);
  color: var(--desktop-primary);
}

.settings-card-icon.ok {
  border-color: rgba(48, 164, 108, 0.2);
  background: rgba(48, 164, 108, 0.1);
  color: var(--desktop-ok);
}

.settings-card-icon .sidebar-icon {
  width: 18px;
  height: 18px;
  flex-basis: 18px;
  color: currentColor;
}

.settings-panel-head h2,
.settings-panel-head p {
  margin: 0;
}

.settings-panel-head h2 {
  color: #071426;
  font-size: 16px;
  font-weight: 820;
}

.settings-panel-head p {
  margin-top: 3px;
  color: #60708a;
  font-size: 12px;
  font-weight: 680;
}

.settings-list {
  display: grid;
  gap: 0;
  margin: 0;
  padding: 2px 14px 14px;
}

.settings-list div {
  min-height: 46px;
  display: grid;
  grid-template-columns: minmax(92px, 0.35fr) minmax(0, 1fr);
  align-items: center;
  gap: 12px;
  border-bottom: 1px solid rgba(116, 139, 166, 0.13);
}

.settings-list div:last-child {
  border-bottom: 0;
}

.settings-list dt,
.settings-status-item span {
  color: #60708a;
  font-size: 12px;
  font-weight: 740;
}

.settings-list dd {
  min-width: 0;
  margin: 0;
  color: #0b1220;
  font-size: 13px;
  font-weight: 760;
  line-height: 1.35;
  overflow-wrap: anywhere;
}

.settings-list a {
  min-height: 32px;
  display: inline-flex;
  align-items: center;
  width: fit-content;
  max-width: 100%;
  border-radius: 7px;
  padding: 0 8px;
  color: #0066d6;
  text-decoration: none;
}

.settings-list a:hover {
  background: rgba(10, 132, 255, 0.08);
  text-decoration: underline;
}

.settings-list .desktop-site-row {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  width: 100%;
}

.settings-list .desktop-site-row span {
  min-width: 0;
  color: #0a66d1;
  font-weight: 800;
}

.desktop-inline-btn {
  min-height: 28px;
  appearance: none;
  border: 1px solid rgba(108, 124, 147, 0.18);
  border-radius: 9px;
  padding: 0 10px;
  background: rgba(248, 250, 252, 0.86);
  color: #334155;
  font-size: 12px;
  font-weight: 760;
  cursor: pointer;
  transition: background 0.16s ease, border-color 0.16s ease, color 0.16s ease;
}

.desktop-inline-btn:hover {
  border-color: rgba(10, 132, 255, 0.30);
  background: rgba(232, 242, 255, 0.92);
  color: #0a66d1;
}

.settings-list.compact {
  padding-top: 0;
}

.settings-status-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  padding: 14px;
}

.settings-status-item {
  min-width: 0;
  min-height: 76px;
  display: grid;
  align-content: center;
  gap: 6px;
  border: 1px solid rgba(104, 126, 155, 0.2);
  border-radius: 14px;
  padding: 12px;
  background: rgba(255, 255, 255, 0.66);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.82) inset;
}

.settings-status-item strong {
  min-width: 0;
  color: #071426;
  font-size: 18px;
  font-weight: 820;
  line-height: 1.16;
  overflow-wrap: anywhere;
}

.desktop-model-form {
  display: grid;
  gap: 12px;
  padding: 14px;
}

.desktop-model-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.desktop-field-control {
  min-width: 0;
  display: grid;
  gap: 6px;
}

.desktop-model-key-field {
  grid-column: 1 / -1;
}

.desktop-field-control span {
  color: #60708a;
  font-size: 12px;
  font-weight: 760;
}

.desktop-input {
  width: 100%;
  min-width: 0;
  height: 38px;
  border: 1px solid rgba(104, 126, 155, 0.24);
  border-radius: 12px;
  padding: 0 11px;
  background: rgba(255, 255, 255, 0.74);
  color: #0b1220;
  font: inherit;
  font-size: 13px;
  font-weight: 720;
  outline: none;
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.8) inset;
  transition: border-color 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
}

.desktop-input:focus {
  border-color: rgba(10, 132, 255, 0.42);
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 0 0 3px rgba(10, 132, 255, 0.1);
}

.desktop-input:disabled,
.desktop-input:read-only {
  color: #64748b;
  background: rgba(248, 250, 252, 0.72);
}

.desktop-settings-summary {
  min-height: 34px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  color: #4b5f7a;
  font-size: 12px;
  font-weight: 720;
}

.desktop-settings-summary:empty {
  display: none;
}

.desktop-settings-summary .settings-pill {
  min-height: 26px;
  display: inline-flex;
  align-items: center;
  border: 1px solid rgba(104, 126, 155, 0.2);
  border-radius: 999px;
  padding: 4px 9px;
  background: rgba(255, 255, 255, 0.68);
  color: #41546d;
}

.desktop-settings-summary .settings-pill.ok {
  border-color: rgba(48, 164, 108, 0.22);
  background: rgba(48, 164, 108, 0.1);
  color: #157347;
}

.desktop-settings-summary .settings-pill.warn {
  border-color: rgba(255, 149, 0, 0.28);
  background: rgba(255, 149, 0, 0.1);
  color: #9a5b00;
}

.desktop-settings-summary .settings-pill.fail {
  border-color: rgba(255, 59, 48, 0.22);
  background: rgba(255, 59, 48, 0.1);
  color: #b42318;
}

.settings-appearance-panel {
  gap: 14px;
}

.desktop-theme-segment {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 6px;
  border: 1px solid var(--desktop-border);
  border-radius: 13px;
  padding: 5px;
  background: var(--desktop-surface-soft);
}

.desktop-theme-segment .desktop-theme-choice {
  justify-content: center;
  min-height: 34px;
  white-space: nowrap;
}

.desktop-model-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
}

.about-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 14px 4px;
}

.about-brand img {
  width: 46px;
  height: 46px;
  filter: drop-shadow(0 10px 20px rgba(10, 132, 255, 0.18));
}

.about-brand div {
  display: grid;
  gap: 2px;
}

.about-brand strong {
  color: #071426;
  font-size: 18px;
  font-weight: 840;
}

.about-brand span {
  color: #60708a;
  font-size: 12px;
  font-weight: 700;
}

.desktop-update-box {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: 0 14px 14px;
  border: 1px solid rgba(104, 126, 155, 0.18);
  border-radius: 13px;
  padding: 12px;
  background: rgba(248, 250, 252, 0.68);
}

.desktop-update-box > div:first-child {
  min-width: 0;
  display: grid;
  gap: 4px;
}

.desktop-update-box strong {
  color: #071426;
  font-size: 13px;
  font-weight: 820;
}

.desktop-update-box span {
  color: #60708a;
  font-size: 12px;
  font-weight: 680;
  line-height: 1.45;
}

.desktop-update-actions {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  gap: 8px;
}

:root[data-desktop-theme="dark"] .desktop-update-box {
  border-color: rgba(148, 163, 184, 0.18);
  background: rgba(23, 31, 43, 0.64);
}

:root[data-desktop-theme="dark"] .desktop-update-box strong {
  color: #f4f8fd;
}

:root[data-desktop-theme="dark"] .desktop-update-box span {
  color: #a9b7c8;
}

@media (prefers-color-scheme: dark) {
  :root[data-desktop-theme="system"] .desktop-update-box {
    border-color: rgba(148, 163, 184, 0.18);
    background: rgba(23, 31, 43, 0.64);
  }

  :root[data-desktop-theme="system"] .desktop-update-box strong {
    color: #f4f8fd;
  }

  :root[data-desktop-theme="system"] .desktop-update-box span {
    color: #a9b7c8;
  }
}

.settings-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  padding: 14px;
}

.settings-actions .desktop-btn {
  min-height: 40px;
}

.desktop-dashboard-main {
  grid-template-rows: auto auto auto minmax(0, 1fr);
}

.global-kpi-grid {
  min-height: 92px;
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 8px;
}

.global-kpi-card,
.global-panel,
.desktop-money-panel {
  border: 1px solid var(--desktop-border);
  border-radius: 16px;
  background: var(--desktop-surface);
  box-shadow: var(--desktop-shadow-soft);
  backdrop-filter: var(--desktop-blur);
}

.global-kpi-card {
  min-width: 0;
  width: 100%;
  appearance: none;
  display: grid;
  align-content: center;
  gap: 4px;
  padding: 12px;
  position: relative;
  overflow: hidden;
  border-left: 0;
  color: inherit;
  cursor: pointer;
  text-align: left;
  transition: background 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
}

.global-kpi-card::before {
  content: "";
  position: absolute;
  left: 0;
  top: 12px;
  bottom: 12px;
  width: 4px;
  border-radius: 999px;
  background: var(--desktop-primary);
  box-shadow: 0 0 18px rgba(10, 132, 255, 0.28);
}

.global-kpi-card.danger::before {
  background: var(--desktop-danger);
  box-shadow: 0 0 18px rgba(255, 59, 48, 0.24);
}

.global-kpi-card.warn::before {
  background: var(--desktop-warn);
  box-shadow: 0 0 18px rgba(255, 159, 10, 0.24);
}

.global-kpi-card.ok::before {
  background: var(--desktop-ok);
  box-shadow: 0 0 18px rgba(48, 164, 108, 0.22);
}

.global-kpi-card:hover {
  transform: translateY(-1px);
  border-color: rgba(10, 132, 255, 0.28);
  background: rgba(255, 255, 255, 0.88);
  box-shadow: 0 10px 22px rgba(10, 86, 170, 0.08), 0 1px 0 rgba(255, 255, 255, 0.86) inset;
}

.global-kpi-card:focus-visible {
  outline: 3px solid rgba(10, 132, 255, 0.20);
  outline-offset: 2px;
}

.global-kpi-card span,
.global-kpi-card small,
.command-card span,
.command-card small,
.global-panel-head span,
.opportunity-item span,
.opportunity-item small {
  overflow: hidden;
  color: #60708a;
  font-size: 12px;
  font-weight: 720;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.global-kpi-card strong {
  color: #071426;
  font-size: 30px;
  font-weight: 830;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}

.global-dashboard-grid {
  min-height: 0;
  display: grid;
  grid-template-columns: minmax(440px, 0.9fr) minmax(560px, 1.1fr);
  grid-template-rows: minmax(190px, 0.48fr) minmax(0, 1fr);
  gap: 10px;
}

.desktop-money-panel {
  min-height: 112px;
  overflow: hidden;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
}

.money-review-grid {
  min-height: 0;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  padding: 7px 10px 9px;
}

.money-review-card {
  min-width: 0;
  width: 100%;
  appearance: none;
  position: relative;
  display: grid;
  align-content: center;
  gap: 4px;
  border: 1px solid rgba(104, 126, 155, 0.15);
  border-radius: 12px;
  padding: 8px 10px;
  background: rgba(255, 255, 255, 0.58);
  color: inherit;
  cursor: pointer;
  text-align: left;
  box-shadow: none;
  transition: background 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
}

.money-review-card span,
.money-review-card small,
.money-review-card p {
  overflow: hidden;
  margin: 0;
  color: #60708a;
  font-size: 11px;
  font-weight: 720;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.money-review-card strong {
  overflow: hidden;
  color: #071426;
  font-size: 20px;
  font-weight: 830;
  line-height: 1.05;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}

.money-review-card strong.unknown {
  color: #64748b;
  font-size: 18px;
}

.money-review-card p {
  display: none;
}

.money-review-card.ok {
  border-color: rgba(48, 164, 108, 0.20);
  background: rgba(250, 253, 251, 0.72);
}

.money-review-card.warn {
  border-color: rgba(255, 159, 10, 0.20);
  background: rgba(255, 252, 246, 0.74);
}

.money-review-card.sample {
  border-color: rgba(10, 132, 255, 0.18);
  background: rgba(248, 251, 255, 0.76);
}

.money-review-card:hover,
.command-card.is-clickable:hover {
  transform: translateY(-1px);
  border-color: rgba(10, 132, 255, 0.30);
  background: rgba(255, 255, 255, 0.88);
  box-shadow: 0 8px 18px rgba(10, 86, 170, 0.07);
}

.money-review-card:focus-visible,
.command-card.is-clickable:focus-visible,
.dist-row.dist-clickable:focus-visible,
.table-drill-btn:focus-visible,
.drill-customer-row:focus-visible {
  outline: 3px solid rgba(10, 132, 255, 0.20);
  outline-offset: 2px;
}

.global-panel {
  min-width: 0;
  min-height: 0;
  overflow: hidden;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
}

.global-panel-head {
  min-height: 46px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  border-bottom: 1px solid rgba(116, 139, 166, 0.18);
  padding: 8px 12px;
}

.global-panel-head h2,
.distribution-grid h3 {
  margin: 0;
  color: #071426;
  font-size: 16px;
  font-weight: 820;
}

.global-panel-head h2 {
  margin-bottom: 2px;
}

.panel-head-action {
  min-height: 30px;
  border-radius: 10px;
  padding: 5px 10px;
  font-size: 12px;
  font-weight: 760;
}

.command-grid {
  min-height: 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  padding: 9px 10px 10px;
}

.command-card {
  min-width: 0;
  display: grid;
  align-content: center;
  gap: 3px;
  border: 1px solid rgba(104, 126, 155, 0.15);
  border-radius: 12px;
  min-height: 56px;
  padding: 7px 9px;
  background: rgba(255, 255, 255, 0.58);
  box-shadow: none;
}

.command-card.is-clickable {
  width: 100%;
  appearance: none;
  color: inherit;
  cursor: pointer;
  text-align: left;
  transition: background 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
}

.command-card strong {
  color: #071426;
  font-size: 23px;
  font-weight: 830;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}

.command-card small {
  display: none;
}

.command-card.danger strong {
  color: var(--desktop-danger);
}

.command-card.warn strong {
  color: var(--desktop-warn);
}

.command-card.ok strong {
  color: var(--desktop-ok);
}

.global-table-scroll,
.opportunity-list {
  min-height: 0;
  overflow: auto;
}

.global-table {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
}

.global-table th,
.global-table td {
  border-bottom: 1px solid rgba(135, 153, 177, 0.18);
  padding: 8px 10px;
  color: #334155;
  font-size: 12px;
  text-align: left;
}

.global-table th {
  position: sticky;
  top: 0;
  z-index: 2;
  background: rgba(246, 249, 253, 0.88);
  color: #66758c;
  font-size: 11px;
  font-weight: 860;
}

.global-table td strong {
  color: #0f172a;
}

.cell-danger {
  color: var(--desktop-danger) !important;
  font-weight: 860;
}

.table-drill-btn {
  min-width: 44px;
  min-height: 28px;
  appearance: none;
  border: 1px solid transparent;
  border-radius: 8px;
  padding: 4px 8px;
  background: transparent;
  color: #334155;
  cursor: pointer;
  font-weight: 820;
  font-variant-numeric: tabular-nums;
  transition: background 0.18s ease, border-color 0.18s ease, color 0.18s ease;
}

.table-drill-btn:hover {
  border-color: rgba(10, 132, 255, 0.16);
  background: rgba(10, 132, 255, 0.08);
  color: #0057c2;
}

.table-drill-btn.danger {
  color: var(--desktop-danger);
}

.distribution-grid {
  min-height: 0;
  overflow: auto;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  padding: 10px;
}

.distribution-grid > div {
  min-width: 0;
  display: grid;
  align-content: start;
  gap: 8px;
  border: 1px solid rgba(104, 126, 155, 0.14);
  border-radius: 12px;
  padding: 10px;
  background: rgba(255, 255, 255, 0.50);
  box-shadow: none;
}

.distribution-grid h3 {
  font-size: 13px;
}

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

.dist-row {
  display: grid;
  gap: 5px;
}

.dist-row.dist-clickable {
  width: 100%;
  appearance: none;
  border: 1px solid transparent;
  border-radius: 9px;
  padding: 5px 6px;
  background: transparent;
  cursor: pointer;
  text-align: left;
  transition: background 0.18s ease, border-color 0.18s ease;
}

.dist-row.dist-clickable:hover {
  border-color: rgba(10, 132, 255, 0.12);
  background: rgba(255, 255, 255, 0.72);
}

.dist-row > div {
  min-width: 0;
  display: flex;
  justify-content: space-between;
  gap: 8px;
}

.dist-row strong,
.dist-row span {
  overflow: hidden;
  color: #334155;
  font-size: 12px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.dist-row span {
  flex: 0 0 auto;
  color: #64748b;
  font-variant-numeric: tabular-nums;
}

.dist-row i {
  height: 6px;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(135, 153, 177, 0.20);
}

.dist-row b {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #0a84ff, #32d0c6);
}

.dist-empty {
  padding: 14px;
  color: #64748b;
  font-size: 12px;
}

.opportunity-list {
  display: grid;
  align-content: start;
  gap: 7px;
  padding: 10px;
}

.opportunity-item {
  min-width: 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(110px, auto);
  gap: 10px;
  width: 100%;
  text-align: left;
  border: 1px solid rgba(104, 126, 155, 0.20);
  border-radius: 14px;
  padding: 9px 10px;
  background: rgba(255, 255, 255, 0.76);
  color: inherit;
  text-decoration: none;
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.86) inset;
  transition: border-color 0.18s ease, background 0.18s ease, transform 0.18s ease, box-shadow 0.18s ease;
}

.opportunity-item:hover {
  transform: translateY(-1px);
  border-color: rgba(10, 132, 255, 0.28);
  background: rgba(239, 247, 255, 0.86);
  box-shadow: 0 12px 24px rgba(10, 86, 170, 0.09), 0 1px 0 rgba(255, 255, 255, 0.92) inset;
}

.opportunity-item:focus-visible {
  outline: 3px solid rgba(10, 132, 255, 0.22);
  outline-offset: 2px;
}

.opportunity-item div {
  min-width: 0;
  display: grid;
  gap: 4px;
}

.opportunity-item strong,
.opportunity-item b {
  overflow: hidden;
  color: #0b1220;
  font-size: 13px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.opportunity-item b,
.opportunity-item small {
  text-align: right;
}

.desktop-drill-modal {
  position: fixed;
  inset: 0;
  z-index: 70;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 18px;
  background: rgba(20, 28, 40, 0.28);
  backdrop-filter: blur(12px);
}

.desktop-drill-panel {
  width: min(1080px, calc(100vw - 36px));
  height: min(760px, calc(100vh - 36px));
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  overflow: hidden;
  border: 1px solid rgba(134, 154, 180, 0.30);
  border-radius: 16px;
  background: rgba(248, 250, 253, 0.97);
  box-shadow: 0 26px 70px rgba(15, 23, 42, 0.22), 0 1px 0 rgba(255, 255, 255, 0.86) inset;
}

.desktop-drill-head {
  min-height: 58px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border-bottom: 1px solid rgba(134, 154, 180, 0.22);
  padding: 10px 12px 10px 16px;
  background: rgba(255, 255, 255, 0.84);
  backdrop-filter: var(--desktop-blur);
}

.desktop-drill-head > div:first-child {
  min-width: 0;
  display: grid;
  gap: 2px;
}

.desktop-drill-head span {
  color: #66758c;
  font-size: 11px;
  font-weight: 780;
}

.desktop-drill-head strong {
  overflow: hidden;
  color: #0b1220;
  font-size: 16px;
  font-weight: 850;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.desktop-drill-head small {
  overflow: hidden;
  color: #64748b;
  font-size: 12px;
  font-weight: 650;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.desktop-drill-body {
  min-height: 0;
  overflow: auto;
  padding: 10px 12px 14px;
  background: rgba(246, 248, 251, 0.76);
}

.overdue-modal-panel {
  grid-template-rows: auto auto minmax(0, 1fr) auto;
}

.overdue-modal-actions {
  min-height: 56px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border-bottom: 1px solid var(--desktop-border);
  padding: 8px 12px 8px 16px;
  background: var(--desktop-surface-strong);
}

.overdue-modal-actions > div {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}

.overdue-select-all {
  min-height: 40px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--desktop-text);
  cursor: pointer;
  font-size: 13px;
  font-weight: 760;
}

.overdue-select-all input,
.overdue-customer-table input[type="checkbox"] {
  width: 18px;
  height: 18px;
  accent-color: var(--desktop-primary);
  cursor: pointer;
}

.overdue-modal-body {
  padding: 0;
}

.overdue-modal-pagination {
  min-height: 52px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border-top: 1px solid var(--desktop-border);
  padding: 8px 12px 8px 16px;
  background: var(--desktop-surface-strong);
}

.overdue-modal-pagination > span {
  color: var(--desktop-muted);
  font-size: 12px;
  font-weight: 680;
  font-variant-numeric: tabular-nums;
}

.overdue-modal-pagination > div {
  display: inline-flex;
  align-items: center;
  gap: 7px;
}

.overdue-modal-pagination .pager-btn {
  min-height: 34px;
}

.overdue-modal-pagination .page-info {
  min-width: 52px;
}

.overdue-customer-table {
  width: 100%;
  min-width: 820px;
  border-collapse: collapse;
  table-layout: fixed;
}

.overdue-customer-table th,
.overdue-customer-table td {
  border-bottom: 1px solid var(--desktop-border);
  padding: 11px 12px;
  color: var(--desktop-text);
  font-size: 12px;
  line-height: 1.4;
  text-align: left;
  vertical-align: middle;
}

.overdue-customer-table th {
  position: sticky;
  top: 0;
  z-index: 2;
  background: var(--desktop-surface-strong);
  color: var(--desktop-muted);
  font-size: 11px;
  font-weight: 820;
}

.overdue-customer-table th:first-child,
.overdue-customer-table td:first-child {
  width: 48px;
  text-align: center;
}

.overdue-customer-table th:nth-child(2) {
  width: 25%;
}

.overdue-customer-table th:nth-child(3) {
  width: 15%;
}

.overdue-customer-table th:nth-child(4) {
  width: 19%;
}

.overdue-customer-table th:nth-child(5) {
  width: 20%;
}

.overdue-customer-table tbody tr:hover td {
  background: var(--desktop-primary-soft);
}

.overdue-customer-cell {
  min-width: 0;
  display: grid;
  gap: 3px;
  justify-items: start;
}

.overdue-customer-country {
  color: var(--desktop-muted);
  font-size: 11px;
  line-height: 1.35;
}

.overdue-customer-table td small,
.overdue-customer-table time {
  color: var(--desktop-muted);
  font-size: 11px;
  font-variant-numeric: tabular-nums;
}

.overdue-customer-link {
  width: fit-content;
  max-width: 100%;
  overflow: hidden;
  border: 0;
  padding: 0;
  background: transparent;
  color: var(--desktop-text);
  cursor: pointer;
  font-size: 13px;
  font-weight: 760;
  line-height: 1.35;
  text-align: left;
  text-overflow: ellipsis;
  transition: color 0.18s ease;
  white-space: nowrap;
}

.overdue-customer-link:hover {
  color: var(--desktop-primary-strong);
  text-decoration: underline;
}

.overdue-customer-link:focus-visible {
  outline: 3px solid rgba(10, 132, 255, 0.24);
  outline-offset: 3px;
  border-radius: 3px;
}

.drill-list {
  display: grid;
  gap: 7px;
}

.drill-customer-row {
  min-width: 0;
  width: 100%;
  min-height: 62px;
  appearance: none;
  display: grid;
  grid-template-columns: minmax(220px, 1fr) minmax(170px, 0.62fr) minmax(260px, 1.1fr) minmax(116px, auto);
  align-items: center;
  gap: 10px;
  border: 1px solid rgba(104, 126, 155, 0.16);
  border-radius: 12px;
  padding: 10px;
  background: rgba(255, 255, 255, 0.78);
  color: inherit;
  cursor: pointer;
  text-align: left;
  box-shadow: none;
  transition: background 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
}

.drill-customer-row:hover {
  transform: translateY(-1px);
  border-color: rgba(10, 132, 255, 0.26);
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 10px 22px rgba(10, 86, 170, 0.08);
}

.drill-customer-row > div {
  min-width: 0;
  display: grid;
  gap: 4px;
}

.drill-customer-row strong,
.drill-customer-row b,
.drill-customer-row span,
.drill-customer-row p,
.drill-customer-row small {
  overflow: hidden;
  margin: 0;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.drill-customer-row strong,
.drill-customer-row b {
  color: #0f172a;
  font-size: 13px;
  font-weight: 820;
}

.drill-customer-row span,
.drill-customer-row small {
  color: #60708a;
  font-size: 12px;
  font-weight: 680;
}

.drill-customer-row p {
  color: #334155;
  font-size: 12px;
  line-height: 1.45;
}

.drill-customer-row small {
  text-align: right;
  font-variant-numeric: tabular-nums;
}

.desktop-review-modal {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 18px;
  background: rgba(20, 28, 40, 0.34);
  backdrop-filter: blur(14px);
}

.desktop-review-modal:not(.hidden) {
  animation: desktopModalFadeIn 0.18s ease-out both;
}

.desktop-review-panel {
  width: min(1320px, calc(100vw - 36px));
  height: min(920px, calc(100vh - 36px));
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  overflow: hidden;
  border: 1px solid rgba(134, 154, 180, 0.34);
  border-radius: 16px;
  background: rgba(246, 249, 253, 0.96);
  box-shadow: 0 32px 80px rgba(15, 23, 42, 0.26), 0 1px 0 rgba(255, 255, 255, 0.86) inset;
}

.desktop-review-modal:not(.hidden) .desktop-review-panel {
  animation: desktopReviewPanelIn 0.24s cubic-bezier(0.2, 0.8, 0.2, 1) both;
}

@keyframes desktopModalFadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

@keyframes desktopReviewPanelIn {
  from {
    opacity: 0;
    transform: translateY(10px) scale(0.985);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes desktopReviewCardIn {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.desktop-review-head {
  min-height: 58px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border-bottom: 1px solid rgba(134, 154, 180, 0.24);
  padding: 10px 12px 10px 16px;
  background: rgba(255, 255, 255, 0.82);
  backdrop-filter: var(--desktop-blur);
}

.desktop-review-head > div:first-child {
  min-width: 0;
  display: grid;
  gap: 2px;
}

.desktop-review-head span {
  color: #66758c;
  font-size: 11px;
  font-weight: 780;
}

.desktop-review-head strong {
  overflow: hidden;
  color: #0b1220;
  font-size: 16px;
  font-weight: 850;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.desktop-review-head small {
  overflow: hidden;
  color: #64748b;
  font-size: 12px;
  font-weight: 650;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.desktop-review-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.desktop-review-body {
  width: 100%;
  height: 100%;
  min-height: 0;
  overflow: auto;
  padding: 12px;
  background: #f6f8fb;
}

.desktop-local-panel {
  width: min(760px, calc(100vw - 36px));
  height: auto;
  max-height: min(760px, calc(100vh - 36px));
}

.desktop-local-body {
  padding: 14px;
}

.desktop-local-form {
  display: grid;
  gap: 12px;
}

.desktop-local-file .desktop-input {
  height: auto;
  min-height: 42px;
  padding: 9px 11px;
}

.desktop-local-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.desktop-local-summary {
  min-height: 44px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  border: 1px solid rgba(104, 126, 155, 0.18);
  border-radius: 14px;
  padding: 9px;
  background: rgba(255, 255, 255, 0.68);
  color: #4b5f7a;
  font-size: 12px;
  font-weight: 720;
}

.desktop-local-summary:empty {
  display: none;
}

.desktop-local-pill {
  min-height: 26px;
  display: inline-flex;
  align-items: center;
  border: 1px solid rgba(104, 126, 155, 0.2);
  border-radius: 999px;
  padding: 4px 9px;
  background: rgba(255, 255, 255, 0.74);
  color: #41546d;
}

.desktop-local-pill.ok {
  border-color: rgba(48, 164, 108, 0.22);
  background: rgba(48, 164, 108, 0.1);
  color: #157347;
}

.desktop-local-pill.warn {
  border-color: rgba(255, 149, 0, 0.28);
  background: rgba(255, 149, 0, 0.1);
  color: #9a5b00;
}

.desktop-local-pill.fail {
  border-color: rgba(255, 59, 48, 0.22);
  background: rgba(255, 59, 48, 0.1);
  color: #b42318;
}

.desktop-local-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
}

.desktop-collector-main {
  grid-template-rows: auto auto auto auto minmax(0, 1fr);
}

.collector-folder-btn {
  gap: 6px;
  cursor: pointer;
}

.collector-folder-btn,
#runBatchAnalysisBtn {
  min-height: 44px;
  gap: 8px;
  border-radius: 13px;
  padding: 0 15px;
  font-size: 13px;
  font-weight: 780;
  line-height: 1;
}

.collector-folder-btn .sidebar-icon,
#runBatchAnalysisBtn .sidebar-icon {
  width: 15px;
  height: 15px;
  flex-basis: 15px;
}

.collector-folder-btn span,
#runBatchAnalysisBtn span {
  color: #ffffff;
  font-size: 13px;
  font-weight: 780;
  line-height: 1;
}

.collector-toolbar {
  grid-template-columns: minmax(260px, 1fr) minmax(160px, 220px) minmax(110px, 140px) auto auto;
}

.collector-metrics {
  min-height: 82px;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  grid-template-rows: minmax(68px, auto);
}

.collector-fallback-metric {
  border-color: rgba(255, 59, 48, 0.34);
}

.collector-filter-metric {
  cursor: default;
}

.collector-filter-metric:hover {
  transform: none;
  border-color: rgba(104, 126, 155, 0.22);
  background: rgba(255, 255, 255, 0.78);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.86) inset;
}

#collectorListPanel {
  scroll-margin-top: 12px;
}

.collector-progress-panel {
  min-height: 54px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  border: 1px solid var(--desktop-border);
  border-radius: 16px;
  padding: 8px 10px 8px 12px;
  background: var(--desktop-surface);
  box-shadow: var(--desktop-shadow-soft);
  backdrop-filter: var(--desktop-blur);
}

.collector-progress-panel > div:first-child {
  min-width: 0;
  display: grid;
  gap: 3px;
}

.collector-progress-panel strong {
  overflow: hidden;
  color: #071426;
  font-size: 13px;
  font-weight: 830;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.collector-progress-panel span {
  overflow: hidden;
  color: #60708a;
  font-size: 12px;
  font-weight: 680;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.collector-progress-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
}

.collector-progress-actions .desktop-btn {
  gap: 6px;
}

.collector-grid {
  min-height: 0;
  display: grid;
  grid-template-columns: minmax(720px, 1fr) minmax(330px, 380px);
  gap: 10px;
  overflow: hidden;
}

.collector-list-panel,
.collector-detail-panel {
  min-width: 0;
  min-height: 0;
  overflow: hidden;
}

.collector-list-panel {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
}

.collector-detail-panel {
  display: grid;
  grid-template-rows: minmax(0, 1fr);
}

.collector-table-scroll {
  overflow-x: hidden;
}

.collector-table th,
.collector-table td {
  vertical-align: middle;
}

.collector-sort-button {
  width: 100%;
  min-height: 28px;
  display: inline-flex;
  align-items: center;
  justify-content: flex-start;
  gap: 5px;
  border: 0;
  padding: 0;
  background: transparent;
  color: inherit;
  cursor: pointer;
  font: inherit;
  font-weight: inherit;
  text-align: inherit;
  white-space: nowrap;
}

.collector-table th:nth-child(3) .collector-sort-button {
  justify-content: center;
}

.collector-sort-button:hover,
.collector-sort-button.active {
  color: #007aff;
}

.collector-sort-button:focus-visible {
  border-radius: 4px;
  outline: 2px solid rgba(0, 122, 255, 0.55);
  outline-offset: 2px;
}

.collector-sort-indicator {
  width: 12px;
  flex: 0 0 12px;
  color: #8a99ad;
  font-size: 11px;
  line-height: 1;
  text-align: center;
}

.collector-sort-button.active .collector-sort-indicator {
  color: currentColor;
}

.collector-table td {
  min-width: 0;
}

.collector-table td > * {
  max-width: 100%;
}

.collector-table th:nth-child(1),
.collector-table td:nth-child(1) {
  width: 22%;
}

.collector-table th:nth-child(2),
.collector-table td:nth-child(2) {
  width: 12%;
  text-align: left;
}

.collector-table th:nth-child(3),
.collector-table td:nth-child(3) {
  width: 7%;
  text-align: center;
}

.collector-table th:nth-child(4),
.collector-table td:nth-child(4) {
  width: 10%;
  text-align: left;
}

.collector-table th:nth-child(5),
.collector-table td:nth-child(5) {
  width: 28%;
}

.collector-table th:nth-child(6),
.collector-table td:nth-child(6) {
  width: 10%;
  white-space: nowrap;
}

.collector-table th:nth-child(7),
.collector-table td:nth-child(7) {
  width: 11%;
  text-align: right;
}

.collector-country-cell {
  min-width: 0;
  display: grid;
  align-content: center;
  justify-items: start;
  gap: 5px;
}

.collector-country-cell strong,
.collector-file-name {
  display: block;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.collector-table .customer-cell {
  min-width: 0;
}

.collector-table .customer-cell strong,
.collector-table .customer-cell span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.collector-table .desktop-local-pill {
  max-width: 100%;
  overflow: hidden;
  border-radius: 9px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.collector-level-line {
  min-width: 0;
  display: inline-flex;
  align-items: center;
  justify-content: flex-start;
}

.collector-country-cell .level-badge-wrap {
  min-height: 20px;
  gap: 0;
  border-color: rgba(100, 116, 139, 0.14);
  padding: 1px 4px;
  background: rgba(248, 250, 252, 0.9);
}

.collector-country-cell .level-badge-img {
  width: 28px;
  border-radius: 3px;
}

.collector-country-cell .level-badge-text {
  display: none;
}

.collector-country-cell .level-text-fallback {
  min-height: 20px;
  padding: 2px 7px;
  border: 1px solid rgba(100, 116, 139, 0.14);
  background: rgba(248, 250, 252, 0.9);
  color: #334155 !important;
  font-size: 11px !important;
}

.collector-count {
  font-variant-numeric: tabular-nums;
  font-weight: 830;
}

.collector-row-action {
  inline-size: 78px;
  min-inline-size: 78px;
  min-height: 30px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 5px 9px;
  border-radius: 10px;
  font-size: 12px;
  line-height: 1;
  white-space: nowrap;
}

.collector-detail-empty {
  min-height: 100%;
  display: grid;
  place-content: center;
  gap: 8px;
  padding: 18px;
  color: #64748b;
  text-align: center;
}

.collector-detail-empty strong {
  color: #0f172a;
  font-size: 15px;
  font-weight: 820;
}

.collector-detail-form {
  min-height: 0;
  display: grid;
  grid-template-rows: auto auto auto minmax(0, 1fr) auto;
  overflow: hidden;
}

.collector-detail-head {
  border-bottom-color: rgba(116, 139, 166, 0.13);
}

.collector-detail-fields {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  padding: 14px 14px 0;
}

.collector-detail-form .desktop-local-summary {
  margin: 12px 14px 0;
}

.collector-result-summary {
  min-height: 0;
  display: grid;
  align-content: start;
  gap: 8px;
  overflow: auto;
  padding: 12px 14px;
}

.collector-result-card {
  min-width: 0;
  border: 1px solid rgba(104, 126, 155, 0.18);
  border-radius: 14px;
  padding: 10px;
  background: rgba(255, 255, 255, 0.68);
}

.collector-result-card.danger {
  border-color: rgba(255, 59, 48, 0.2);
  background: rgba(255, 59, 48, 0.08);
}

.collector-fallback-card {
  border-left: 3px solid #ff3b30;
}

.collector-result-card span {
  display: block;
  color: #60708a;
  font-size: 11px;
  font-weight: 760;
}

.collector-result-card strong {
  display: block;
  margin-top: 5px;
  color: #0f172a;
  font-size: 13px;
  font-weight: 760;
  line-height: 1.45;
  white-space: pre-wrap;
}

.collector-detail-actions {
  display: flex;
  gap: 8px;
  justify-content: flex-end;
  border-top: 1px solid rgba(116, 139, 166, 0.13);
  padding: 12px 14px;
}

.collector-detail-actions .desktop-btn {
  gap: 6px;
}

.collector-folder-loading .collector-folder-btn {
  opacity: 0.66;
  pointer-events: none;
}

.desktop-review-empty,
.desktop-review-loading {
  min-height: 260px;
  display: grid;
  place-content: center;
  gap: 8px;
  color: #64748b;
  text-align: center;
}

.desktop-review-empty strong,
.desktop-review-loading strong {
  color: #0f172a;
  font-size: 18px;
}

.desktop-review-empty span,
.desktop-review-loading span {
  max-width: 360px;
  font-size: 13px;
  line-height: 1.5;
}

.review-hero,
.review-money-strip,
.review-text-block,
.review-native-panel {
  border: 1px solid rgba(104, 126, 155, 0.20);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.78);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.88) inset;
  transition: background 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
}

.review-hero {
  display: grid;
  gap: 12px;
  padding: 14px;
}

.review-customer-title {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.review-customer-title > div:first-child {
  min-width: 0;
}

.review-customer-title span,
.review-info-card span,
.review-text-block h3,
.review-native-head span,
.review-line span,
.review-script-row span,
.review-history-row time,
.review-history-row small {
  color: #64748b;
  font-size: 12px;
  font-weight: 760;
}

.review-customer-title h2 {
  overflow-wrap: anywhere;
  margin: 2px 0 4px;
  color: #071426;
  font-size: 24px;
  line-height: 1.15;
}

.review-customer-title p {
  margin: 0;
  color: #526276;
  font-size: 13px;
  line-height: 1.45;
}

.review-customer-badges {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 5px;
  max-width: 46%;
}

.review-customer-badges strong,
.review-customer-badges > span:not(.level-badge-wrap):not(.level-text-fallback) {
  min-height: 22px;
  display: inline-flex;
  align-items: center;
  border: 1px solid rgba(100, 116, 139, 0.16);
  border-radius: 999px;
  padding: 2px 7px;
  background: rgba(248, 250, 252, 0.88);
  color: #334155;
  font-size: 11px;
  font-weight: 740;
  line-height: 1.25;
  white-space: nowrap;
}

.review-customer-badges .level-badge-wrap {
  min-height: 22px;
  gap: 0;
  border-color: rgba(100, 116, 139, 0.14);
  padding: 1px 4px;
  background: rgba(248, 250, 252, 0.88);
}

.review-customer-badges .level-badge-img {
  width: 28px;
  border-radius: 3px;
}

.review-customer-badges .level-badge-text {
  display: none;
}

.review-customer-badges .level-text-fallback {
  min-height: 22px;
  padding: 2px 7px;
  border: 1px solid rgba(100, 116, 139, 0.14);
  background: rgba(248, 250, 252, 0.88);
  color: #334155 !important;
  font-size: 11px !important;
  font-weight: 740;
}

.review-info-grid,
.review-money-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.review-info-card {
  min-width: 0;
  display: grid;
  align-content: center;
  gap: 5px;
  border: 1px solid rgba(104, 126, 155, 0.16);
  border-radius: 12px;
  padding: 9px 10px;
  background: rgba(246, 249, 253, 0.78);
}

.review-info-card strong {
  overflow-wrap: anywhere;
  color: #0f172a;
  font-size: 13px;
  line-height: 1.3;
}

.review-info-card.money strong {
  font-size: 18px;
  font-variant-numeric: tabular-nums;
}

.review-info-card.danger strong {
  color: #d70015;
}

.review-info-card.warn strong {
  color: #9a5b00;
}

.review-money-strip {
  margin-top: 10px;
  padding: 10px;
}

.review-two-col {
  margin-top: 10px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.review-text-block {
  min-width: 0;
  padding: 12px;
}

.review-text-block h3,
.review-native-head h3 {
  margin: 0;
  color: #071426;
  font-size: 14px;
  font-weight: 850;
}

.review-text-block p {
  margin: 8px 0 0;
  color: #172033;
  font-size: 13px;
  line-height: 1.65;
  white-space: pre-wrap;
}

.review-text-block.strong,
.review-text-block.action {
  border-color: rgba(10, 132, 255, 0.22);
  background: linear-gradient(180deg, rgba(239, 247, 255, 0.92), rgba(255, 255, 255, 0.82));
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.88) inset, inset 3px 0 0 rgba(10, 132, 255, 0.34);
}

.review-text-block.action {
  border-color: rgba(48, 164, 108, 0.22);
  background: linear-gradient(180deg, rgba(241, 253, 247, 0.92), rgba(255, 255, 255, 0.82));
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.88) inset, inset 3px 0 0 rgba(48, 164, 108, 0.34);
}

.review-text-block.danger {
  border-color: rgba(255, 159, 10, 0.26);
  background: linear-gradient(180deg, rgba(255, 250, 238, 0.94), rgba(255, 255, 255, 0.82));
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.88) inset, inset 3px 0 0 rgba(255, 159, 10, 0.36);
}

.review-native-grid {
  margin-top: 10px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.review-native-panel {
  min-width: 0;
  overflow: hidden;
}

.review-native-panel.wide {
  grid-column: 1 / -1;
}

.review-native-head {
  min-height: 46px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  border-bottom: 1px solid rgba(116, 139, 166, 0.16);
  padding: 9px 11px;
}

.review-line-list,
.review-script-list,
.review-history-list {
  display: grid;
  gap: 0;
  padding: 4px 10px 10px;
}

.review-line,
.review-script-row,
.review-history-row {
  min-width: 0;
  display: grid;
  gap: 5px;
  border-bottom: 1px solid rgba(135, 153, 177, 0.14);
  padding: 9px 0;
}

.review-line:last-child,
.review-script-row:last-child,
.review-history-row:last-child {
  border-bottom: 0;
}

.review-line strong,
.review-script-row p,
.review-history-row span {
  margin: 0;
  color: #172033;
  font-size: 13px;
  line-height: 1.55;
  white-space: pre-wrap;
}

.review-history-row {
  grid-template-columns: 130px 92px minmax(0, 1fr) 150px;
  align-items: start;
  gap: 10px;
}

.review-history-row strong {
  color: #0f172a;
  font-size: 13px;
}

.review-history-empty {
  padding: 14px 0 6px;
  color: #64748b;
  font-size: 12px;
}

.desktop-full-review {
  display: grid;
  gap: 10px;
  margin-top: 10px;
}

.desktop-review-body > .desktop-full-review {
  margin-top: 0;
}

.full-review-section {
  min-width: 0;
  overflow: hidden;
  border: 1px solid rgba(104, 126, 155, 0.20);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.80);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.88) inset;
}

.full-review-section-head {
  min-height: 46px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border-bottom: 1px solid rgba(116, 139, 166, 0.14);
  padding: 9px 11px;
  background: rgba(255, 255, 255, 0.54);
}

summary.full-review-section-head {
  cursor: pointer;
  list-style: none;
}

summary.full-review-section-head::-webkit-details-marker {
  display: none;
}

.full-review-section.is-collapsible > .full-review-section-head {
  user-select: none;
  transition: background 0.18s ease, border-color 0.18s ease;
}

.full-review-section.is-collapsible > .full-review-section-head:hover {
  background: rgba(246, 249, 253, 0.82);
}

.full-review-section.is-collapsible > .full-review-section-head::after {
  content: "";
  flex: 0 0 auto;
  width: 7px;
  height: 7px;
  margin-left: 2px;
  border-right: 1.7px solid #64748b;
  border-bottom: 1.7px solid #64748b;
  transform: rotate(45deg);
  transition: transform 0.18s ease, border-color 0.18s ease;
}

.full-review-section.is-collapsible[open] > .full-review-section-head::after {
  transform: rotate(225deg) translate(-1px, -1px);
}

.full-review-section-body {
  min-width: 0;
}

.full-review-section-head h3 {
  margin: 0;
  color: #071426;
  font-size: 14px;
  font-weight: 850;
}

.full-review-section-head span {
  color: #64748b;
  font-size: 12px;
  font-weight: 680;
  text-align: right;
}

.full-review-card-grid,
.full-next-grid,
.full-script-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  align-items: start;
  gap: 8px;
  padding: 10px;
}

.full-review-card-grid.compact {
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
}

.customer-analysis-layout {
  display: grid;
  gap: 10px;
  padding: 10px;
}

.customer-analysis-summary,
.customer-analysis-detail {
  display: grid;
  min-width: 0;
  align-items: stretch;
  gap: 8px;
}

.customer-analysis-summary {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.customer-analysis-detail {
  grid-template-columns: minmax(0, 2fr) minmax(260px, 0.8fr);
}

.customer-analysis-layout .full-review-card {
  height: 100%;
}

.customer-analysis-layout .full-review-line {
  grid-template-columns: 64px minmax(0, 1fr);
}

.customer-analysis-detail .full-review-card.critical .full-review-value {
  font-weight: 650;
  line-height: 1.68;
}

.full-review-section.evidence .full-review-card-grid.compact {
  grid-template-columns: 1fr;
}

.full-review-two-col {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-items: start;
  gap: 10px;
}

.full-review-card,
.full-script-card {
  min-width: 0;
  overflow: hidden;
  border: 1px solid rgba(130, 152, 179, 0.18);
  border-radius: 12px;
  background: rgba(248, 250, 253, 0.78);
  transition: background 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
}

.full-review-card h4,
.full-script-card h4 {
  margin: 0;
  border-bottom: 1px solid rgba(130, 152, 179, 0.12);
  padding: 9px 10px 8px;
  color: #0f172a;
  font-size: 13px;
  font-weight: 820;
}

.full-review-card-body {
  display: grid;
  gap: 0;
  padding: 3px 10px 10px;
}

.full-review-card.signal {
  border-color: rgba(48, 164, 108, 0.24);
  background: rgba(247, 252, 249, 0.86);
}

.full-review-card.action,
.full-script-card.primary {
  border-color: rgba(10, 132, 255, 0.24);
  background: rgba(244, 249, 255, 0.88);
}

.full-review-card.critical {
  border-color: rgba(255, 159, 10, 0.28);
  background: rgba(255, 251, 242, 0.88);
}

.full-review-card.profile,
.full-review-card.intent,
.full-review-card.persona,
.full-review-card.featured {
  border-color: rgba(10, 132, 255, 0.24);
  background: linear-gradient(180deg, rgba(242, 248, 255, 0.92), rgba(255, 255, 255, 0.86));
  box-shadow: inset 3px 0 0 rgba(10, 132, 255, 0.34);
}

.full-review-card.profile h4 {
  color: #075da8;
}

.full-review-card.intent {
  border-color: rgba(48, 164, 108, 0.26);
  background: linear-gradient(180deg, rgba(241, 253, 247, 0.92), rgba(255, 255, 255, 0.86));
  box-shadow: inset 3px 0 0 rgba(48, 164, 108, 0.36);
}

.full-review-card.intent h4 {
  color: #167145;
}

.full-review-card.persona {
  border-color: rgba(88, 86, 214, 0.24);
  background: linear-gradient(180deg, rgba(246, 245, 255, 0.92), rgba(255, 255, 255, 0.86));
  box-shadow: inset 3px 0 0 rgba(88, 86, 214, 0.34);
}

.full-review-card.persona h4 {
  color: #4641b6;
}

.full-review-card.featured {
  border-color: rgba(255, 159, 10, 0.30);
  background: linear-gradient(180deg, rgba(255, 249, 236, 0.94), rgba(255, 255, 255, 0.86));
  box-shadow: inset 3px 0 0 rgba(255, 159, 10, 0.38);
}

.full-review-card.featured h4 {
  color: #9a5b00;
}

.commitment-board {
  display: grid;
  gap: 10px;
  padding: 10px;
}

.commitment-metrics {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.commitment-metric {
  min-width: 0;
  border: 1px solid rgba(112, 137, 166, 0.2);
  border-radius: 8px;
  padding: 9px 10px;
  background: rgba(248, 250, 253, 0.84);
}

.commitment-metric span,
.commitment-next-times span {
  display: block;
  color: #64748b;
  font-size: 11px;
  font-weight: 680;
}

.commitment-metric strong {
  display: block;
  margin-top: 4px;
  color: #172033;
  font-size: 15px;
  font-variant-numeric: tabular-nums;
}

.commitment-metric.danger {
  border-color: rgba(205, 72, 72, 0.3);
  background: rgba(255, 247, 247, 0.9);
}

.commitment-metric.danger strong {
  color: #b42318;
}

.commitment-next {
  display: grid;
  gap: 10px;
  border: 1px solid rgba(35, 103, 223, 0.26);
  border-left: 3px solid #2367df;
  border-radius: 8px;
  padding: 12px;
  background: rgba(246, 249, 255, 0.92);
}

.commitment-next.overdue {
  border-color: rgba(205, 72, 72, 0.3);
  border-left-color: #cd4848;
  background: rgba(255, 248, 247, 0.92);
}

.commitment-next-head,
.commitment-event-head,
.commitment-event-meta {
  display: flex;
  align-items: center;
  gap: 8px;
}

.commitment-next-head {
  justify-content: space-between;
}

.commitment-next-head > div {
  min-width: 0;
  display: grid;
  gap: 3px;
}

.commitment-next-head span {
  color: #64748b;
  font-size: 11px;
  font-weight: 700;
}

.commitment-next-head strong {
  color: #172033;
  font-size: 14px;
}

.commitment-next-head b {
  flex: 0 0 auto;
  border-radius: 5px;
  padding: 4px 8px;
  background: #e6efff;
  color: #155eef;
  font-size: 11px;
}

.commitment-next-times {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.commitment-next-times > div {
  min-width: 0;
  border-top: 1px solid rgba(112, 137, 166, 0.18);
  padding-top: 8px;
}

.commitment-next-times strong {
  display: block;
  margin-top: 3px;
  overflow-wrap: anywhere;
  color: #24324a;
  font-size: 12px;
  font-variant-numeric: tabular-nums;
}

.commitment-next-action,
.commitment-next blockquote,
.commitment-event p {
  margin: 0;
  color: #475467;
  font-size: 12px;
  line-height: 1.55;
  overflow-wrap: anywhere;
}

.commitment-next-action span {
  margin-right: 8px;
  color: #155eef;
  font-weight: 800;
}

.commitment-next blockquote {
  border-left: 2px solid rgba(35, 103, 223, 0.26);
  padding-left: 9px;
  color: #667085;
}

.commitment-event-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.commitment-event {
  min-width: 0;
  display: grid;
  gap: 7px;
  border: 1px solid rgba(112, 137, 166, 0.18);
  border-radius: 8px;
  padding: 10px;
  background: rgba(255, 255, 255, 0.78);
}

.commitment-event.overdue {
  border-color: rgba(205, 72, 72, 0.28);
}

.commitment-event.conditional {
  border-color: rgba(210, 138, 36, 0.3);
}

.commitment-event.completed,
.commitment-event.cancelled,
.commitment-event.superseded {
  opacity: 0.72;
}

.commitment-event-head strong {
  min-width: 0;
  flex: 1 1 auto;
  color: #24324a;
  font-size: 12px;
}

.commitment-event-head time {
  flex: 0 0 auto;
  color: #667085;
  font-size: 11px;
  font-variant-numeric: tabular-nums;
}

.commitment-status {
  flex: 0 0 auto;
  border-radius: 4px;
  padding: 3px 6px;
  background: #edf2f8;
  color: #526174;
  font-size: 10px;
  font-weight: 800;
}

.commitment-event.overdue .commitment-status {
  background: #fff0ee;
  color: #b42318;
}

.commitment-event.conditional .commitment-status {
  background: #fff5e6;
  color: #9a5b00;
}

.commitment-event-meta {
  flex-wrap: wrap;
  color: #667085;
  font-size: 11px;
}

.transaction-ledger-board {
  display: grid;
  gap: 10px;
  padding: 10px;
}

.ledger-empty-state {
  display: grid;
  gap: 6px;
  min-height: 92px;
  align-content: center;
  border: 1px dashed rgba(112, 137, 166, 0.3);
  border-radius: 8px;
  padding: 18px;
  background: rgba(248, 250, 252, 0.76);
}

.ledger-empty-state strong {
  color: #172033;
  font-size: 13px;
}

.ledger-empty-state span {
  color: #64748b;
  font-size: 12px;
  line-height: 1.6;
}

.ledger-metric-strip {
  display: grid;
  grid-template-columns: repeat(6, minmax(120px, 1fr));
  gap: 8px;
}

.ledger-metric-strip > div {
  min-width: 0;
  border: 1px solid rgba(112, 137, 166, 0.18);
  border-radius: 10px;
  padding: 10px;
  background: rgba(248, 250, 253, 0.82);
}

.ledger-metric-strip span,
.ledger-panel-head span,
.ledger-timeline summary span,
.ledger-order-row span,
.ledger-scope-note,
.ledger-off-platform > div:first-child span {
  color: #64748b;
  font-size: 11px;
  font-weight: 650;
}

.ledger-metric-strip strong {
  display: block;
  margin-top: 5px;
  overflow-wrap: anywhere;
  color: #0f172a;
  font-size: 15px;
  font-variant-numeric: tabular-nums;
}

.ledger-repurchase-panel {
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.35fr);
  gap: 8px;
}

.ledger-repurchase-facts,
.ledger-ai-advice {
  min-width: 0;
  border: 1px solid rgba(112, 137, 166, 0.18);
  border-radius: 10px;
  padding: 10px;
  background: rgba(248, 250, 253, 0.82);
}

.ledger-ai-advice {
  border-color: rgba(48, 164, 108, 0.22);
  background: rgba(244, 251, 247, 0.82);
}

.ledger-repurchase-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 8px;
}

.ledger-repurchase-title span {
  border-radius: 4px;
  padding: 3px 6px;
  background: rgba(100, 116, 139, 0.1);
  color: #64748b;
  font-size: 10px;
  font-weight: 760;
}

.ledger-ai-advice .ledger-repurchase-title span {
  background: rgba(48, 164, 108, 0.11);
  color: #18794e;
}

.ledger-repurchase-title strong {
  color: #172033;
  font-size: 13px;
}

.ledger-cycle-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px;
}

.ledger-cycle-grid > div {
  min-width: 0;
  border-radius: 7px;
  padding: 7px 8px;
  background: rgba(255, 255, 255, 0.78);
}

.ledger-cycle-grid span,
.ledger-ai-advice-lines span {
  display: block;
  color: #64748b;
  font-size: 10px;
  font-weight: 720;
}

.ledger-cycle-grid strong {
  display: block;
  margin-top: 3px;
  overflow-wrap: anywhere;
  color: #172033;
  font-size: 12px;
  font-variant-numeric: tabular-nums;
}

.ledger-repurchase-facts > p {
  margin: 8px 0 0;
  color: #64748b;
  font-size: 10px;
  line-height: 1.5;
}

.ledger-ai-advice-lines {
  display: grid;
  gap: 0;
}

.ledger-ai-advice-lines > div {
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr);
  gap: 8px;
  border-top: 1px solid rgba(48, 164, 108, 0.11);
  padding: 6px 0;
}

.ledger-ai-advice-lines > div:first-child {
  border-top: 0;
}

.ledger-ai-advice-lines p {
  margin: 0;
  overflow-wrap: anywhere;
  color: #334155;
  font-size: 11px;
  line-height: 1.5;
}

.ledger-ai-script p {
  color: #176844;
}

.ledger-content-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.55fr) minmax(280px, 0.85fr);
  align-items: start;
  gap: 10px;
}

.ledger-product-panel,
.ledger-timeline,
.ledger-off-platform {
  min-width: 0;
  border: 1px solid rgba(112, 137, 166, 0.18);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.72);
}

.ledger-panel-head,
.ledger-timeline summary,
.ledger-off-platform > div:first-child {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-height: 42px;
  border-bottom: 1px solid rgba(112, 137, 166, 0.14);
  padding: 8px 10px;
}

.ledger-panel-head strong,
.ledger-timeline summary strong,
.ledger-off-platform > div:first-child strong {
  color: #172033;
  font-size: 13px;
}

.ledger-timeline summary {
  cursor: pointer;
  list-style: none;
}

.ledger-timeline summary::-webkit-details-marker {
  display: none;
}

.ledger-table-wrap {
  max-width: 100%;
  overflow-x: auto;
}

.ledger-table-wrap table {
  width: 100%;
  min-width: 860px;
  border-collapse: collapse;
  table-layout: fixed;
}

.ledger-table-wrap th,
.ledger-table-wrap td {
  border-bottom: 1px solid rgba(112, 137, 166, 0.12);
  padding: 9px 10px;
  text-align: left;
  vertical-align: top;
  color: #334155;
  font-size: 12px;
  font-variant-numeric: tabular-nums;
}

.ledger-table-wrap th:first-child,
.ledger-table-wrap td:first-child {
  width: 32%;
}

.ledger-table-wrap th {
  color: #64748b;
  font-weight: 760;
  white-space: nowrap;
}

.ledger-table-wrap td strong,
.ledger-table-wrap td small {
  display: block;
  overflow-wrap: anywhere;
}

.ledger-table-wrap td small {
  margin-top: 4px;
  color: #94a3b8;
  font-size: 10px;
}

.ledger-auxiliary {
  display: grid;
  gap: 7px;
  padding: 10px;
}

.ledger-auxiliary > strong {
  color: #475569;
  font-size: 11px;
}

.ledger-auxiliary > div {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.ledger-auxiliary span,
.ledger-source-row {
  border: 1px solid rgba(112, 137, 166, 0.16);
  border-radius: 8px;
  padding: 6px 8px;
  background: rgba(248, 250, 252, 0.86);
  color: #475569;
  font-size: 11px;
}

.ledger-timeline > div {
  display: grid;
}

.ledger-order-row {
  display: grid;
  gap: 5px;
  border-bottom: 1px solid rgba(112, 137, 166, 0.12);
  padding: 10px;
  box-shadow: inset 3px 0 0 rgba(100, 116, 139, 0.22);
}

.ledger-order-row:last-child {
  border-bottom: 0;
}

.ledger-order-row.state-paid {
  box-shadow: inset 3px 0 0 rgba(48, 164, 108, 0.48);
}

.ledger-order-row.state-partial {
  box-shadow: inset 3px 0 0 rgba(255, 159, 10, 0.55);
}

.ledger-order-row.state-excluded {
  opacity: 0.72;
}

.ledger-order-row > div,
.ledger-source-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.ledger-order-row strong,
.ledger-order-row b,
.ledger-source-row strong {
  color: #172033;
  font-size: 12px;
  font-variant-numeric: tabular-nums;
}

.ledger-order-row p {
  margin: 0;
  overflow-wrap: anywhere;
  color: #475569;
  font-size: 11px;
  line-height: 1.5;
}

.ledger-order-items {
  display: grid;
  gap: 4px;
  border-top: 1px dashed rgba(112, 137, 166, 0.16);
  padding-top: 6px;
}

.ledger-order-item {
  display: grid;
  grid-template-columns: 54px minmax(0, 1fr);
  align-items: start;
  gap: 6px;
}

.ledger-order-item > span {
  border-radius: 4px;
  padding: 2px 4px;
  background: rgba(100, 116, 139, 0.09);
  text-align: center;
  font-size: 9px;
}

.ledger-order-item p,
.ledger-order-item strong,
.ledger-order-item small {
  display: block;
  min-width: 0;
}

.ledger-order-item strong {
  color: #334155;
  font-size: 10px;
  font-weight: 720;
}

.ledger-order-item small {
  margin-top: 2px;
  color: #64748b;
  font-size: 9px;
  line-height: 1.45;
}

.ledger-off-platform {
  display: grid;
  gap: 0;
}

.ledger-source-row {
  margin: 8px 10px 0;
}

.ledger-source-row:last-child {
  margin-bottom: 10px;
}

.ledger-scope-note {
  margin: 0;
  padding: 0 2px;
  line-height: 1.5;
}

.full-review-line {
  min-width: 0;
  display: grid;
  grid-template-columns: minmax(72px, 0.34fr) minmax(0, 1fr);
  gap: 10px;
  border-bottom: 1px solid rgba(135, 153, 177, 0.12);
  padding: 8px 0;
}

.full-review-line:last-child {
  border-bottom: 0;
}

.full-review-line > span,
.full-review-meta-grid span,
.review-followup-form label span {
  color: #64748b;
  font-size: 12px;
  font-weight: 760;
}

.full-review-value,
.full-review-meta-value {
  min-width: 0;
  overflow-wrap: anywhere;
  color: #172033;
  font-size: 13px;
  font-weight: 680;
  line-height: 1.55;
  white-space: pre-wrap;
}

.desktop-review-list {
  margin: 0;
  padding-left: 17px;
  white-space: normal;
}

.desktop-review-list li + li {
  margin-top: 4px;
}

.full-review-meta-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(138px, 1fr));
  gap: 8px;
  padding-top: 10px;
}

.full-review-meta-grid > div {
  min-width: 0;
  display: grid;
  gap: 4px;
  border: 1px solid rgba(130, 152, 179, 0.15);
  border-radius: 10px;
  padding: 8px;
  background: rgba(248, 250, 253, 0.74);
}

.full-battle-card {
  display: grid;
  gap: 10px;
  padding: 10px;
}

.full-battle-main {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  border: 1px solid rgba(130, 152, 179, 0.15);
  border-radius: 12px;
  padding: 12px;
  background: rgba(255, 255, 255, 0.78);
}

.full-battle-main span {
  color: #64748b;
  font-size: 12px;
  font-weight: 760;
}

.full-battle-main > div:first-child > strong {
  display: block;
  overflow-wrap: anywhere;
  margin-top: 2px;
  color: #071426;
  font-size: 20px;
  line-height: 1.15;
}

.full-battle-main p {
  margin: 5px 0 0;
  color: #526276;
  font-size: 13px;
  line-height: 1.45;
}

.full-battle-summary {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.battle-platform-card {
  display: grid;
  gap: 10px;
  padding: 10px 10px 12px;
}

.battle-platform-row {
  min-width: 0;
  display: grid;
  grid-template-columns: 58px minmax(0, 1fr);
  align-items: start;
  gap: 10px;
}

.battle-platform-metrics {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(118px, 1fr));
  gap: 8px;
}

.battle-platform-metric {
  min-width: 0;
  display: grid;
  gap: 4px;
  border: 1px solid rgba(130, 152, 179, 0.15);
  border-radius: 10px;
  padding: 8px;
  background: rgba(248, 250, 253, 0.78);
}

.battle-platform-metric span,
.battle-platform-row > span {
  color: #64748b;
  font-size: 12px;
  font-weight: 760;
}

.battle-platform-metric strong {
  min-width: 0;
  overflow-wrap: anywhere;
  color: #172033;
  font-size: 13px;
  font-weight: 820;
  line-height: 1.35;
}

.battle-platform-row {
  padding: 0;
}

.battle-platform-row > div {
  min-width: 0;
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-start;
  gap: 6px;
}

.battle-platform-chip {
  max-width: 100%;
  min-height: 22px;
  display: inline-flex;
  align-items: center;
  border: 1px solid rgba(10, 132, 255, 0.16);
  border-radius: 999px;
  padding: 2px 8px;
  background: rgba(242, 248, 255, 0.82);
  color: #1d4f91;
  font-size: 12px;
  font-weight: 730;
  line-height: 1.25;
}

.battle-platform-text {
  min-width: 0;
  overflow-wrap: anywhere;
  color: #172033;
  font-size: 13px;
  font-weight: 680;
  line-height: 1.5;
  text-align: left;
}

.full-script-card {
  padding-bottom: 10px;
}

.full-script-card p {
  margin: 0;
  padding: 10px;
  color: #172033;
  font-size: 13px;
  line-height: 1.58;
  white-space: pre-wrap;
}

.full-event-list {
  display: grid;
  gap: 8px;
  padding: 10px;
}

.full-event-item {
  min-width: 0;
  display: grid;
  grid-template-columns: 18px minmax(0, 1fr);
  gap: 10px;
  border: 1px solid rgba(130, 152, 179, 0.16);
  border-radius: 12px;
  padding: 10px;
  background: rgba(248, 250, 253, 0.78);
}

.full-event-item i {
  width: 10px;
  height: 10px;
  margin-top: 5px;
  border-radius: 999px;
  background: #8e9bad;
  box-shadow: 0 0 0 4px rgba(142, 155, 173, 0.14);
}

.full-event-item.quote i,
.full-event-item.action i,
.full-event-item.system i {
  background: #0a84ff;
  box-shadow: 0 0 0 4px rgba(10, 132, 255, 0.12);
}

.full-event-item.deal i,
.full-event-item.customer i {
  background: #30a46c;
  box-shadow: 0 0 0 4px rgba(48, 164, 108, 0.12);
}

.full-event-item.risk i {
  background: #ff9f0a;
  box-shadow: 0 0 0 4px rgba(255, 159, 10, 0.15);
}

.full-event-head {
  min-width: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.full-event-head strong {
  overflow: hidden;
  color: #0f172a;
  font-size: 13px;
  font-weight: 820;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.full-event-head time {
  flex: 0 0 auto;
  color: #64748b;
  font-size: 12px;
  font-variant-numeric: tabular-nums;
}

.full-event-item p,
.full-event-action {
  margin: 5px 0 0;
  color: #334155;
  font-size: 13px;
  line-height: 1.55;
  white-space: pre-wrap;
}

.full-event-action {
  display: grid;
  gap: 3px;
  border-radius: 10px;
  padding: 8px;
  background: rgba(10, 132, 255, 0.08);
}

.full-event-action span,
.full-event-meta span {
  color: #64748b;
  font-size: 11px;
  font-weight: 760;
}

.full-event-action b {
  color: #0f172a;
  font-weight: 760;
}

.full-event-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 7px;
}

.full-event-meta span {
  border: 1px solid rgba(130, 152, 179, 0.18);
  border-radius: 999px;
  padding: 4px 7px;
  background: rgba(255, 255, 255, 0.72);
}

.review-followup-form {
  display: grid;
  gap: 10px;
  padding: 10px;
}

.review-followup-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.review-followup-form label {
  min-width: 0;
  display: grid;
  gap: 6px;
}

.review-followup-form input,
.review-followup-form select,
.review-followup-form textarea {
  width: 100%;
  min-height: 36px;
  border: 1px solid rgba(104, 126, 155, 0.24);
  border-radius: 10px;
  padding: 8px 10px;
  background: rgba(255, 255, 255, 0.86);
  color: #0f172a;
  outline: none;
  transition: border-color 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
}

.review-followup-form textarea {
  min-height: 78px;
  resize: vertical;
  line-height: 1.5;
}

.review-followup-form input:focus,
.review-followup-form select:focus,
.review-followup-form textarea:focus {
  border-color: rgba(10, 132, 255, 0.46);
  background: #ffffff;
  box-shadow: 0 0 0 3px rgba(10, 132, 255, 0.10);
}

.review-followup-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.review-followup-actions span {
  color: #64748b;
  font-size: 12px;
  font-weight: 680;
}

.desktop-journey-panel {
  width: min(1240px, calc(100vw - 36px));
}

.desktop-journey-body {
  background: #f7f9fc;
}

.journey-hero,
.journey-stage,
.journey-fact,
.journey-event {
  border: 1px solid rgba(104, 126, 155, 0.20);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.80);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.88) inset;
  transition: background 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
}

.journey-hero {
  display: grid;
  gap: 12px;
  padding: 14px;
}

.journey-fact-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.journey-fact {
  min-width: 0;
  display: grid;
  gap: 5px;
  padding: 9px 10px;
  background: rgba(246, 249, 253, 0.78);
}

.journey-fact span,
.journey-stage-head span,
.journey-stage-head b,
.journey-stage small,
.journey-event-head span {
  color: #64748b;
  font-size: 12px;
  font-weight: 760;
}

.journey-fact strong {
  overflow-wrap: anywhere;
  color: #0f172a;
  font-size: 13px;
  line-height: 1.35;
}

.journey-fact.warn strong,
.review-text-block.danger p {
  color: #9a5b00;
}

.journey-stage-grid {
  margin-top: 10px;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.journey-stage {
  min-width: 0;
  min-height: 154px;
  display: grid;
  align-content: start;
  gap: 7px;
  padding: 11px;
  background: rgba(255, 255, 255, 0.78);
}

.journey-stage.done {
  border-color: rgba(52, 199, 89, 0.28);
  background: rgba(245, 253, 248, 0.86);
}

.journey-stage.active {
  border-color: rgba(10, 132, 255, 0.36);
  background: rgba(242, 248, 255, 0.92);
  box-shadow: 0 0 0 3px rgba(10, 132, 255, 0.08);
}

.journey-stage.attention {
  border-color: rgba(255, 159, 10, 0.34);
  background: rgba(255, 250, 238, 0.88);
}

.journey-stage.skipped {
  opacity: 0.64;
}

.journey-stage-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.journey-stage-head span {
  color: #0a84ff;
  font-variant-numeric: tabular-nums;
}

.journey-stage strong {
  color: #071426;
  font-size: 14px;
  font-weight: 850;
}

.journey-stage p {
  overflow: hidden;
  margin: 0;
  color: #334155;
  display: -webkit-box;
  font-size: 12px;
  line-height: 1.45;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
}

.journey-stage small {
  margin-top: auto;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.journey-detail-grid {
  margin-top: 10px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.journey-panels {
  margin-top: 10px;
}

.journey-event-list {
  display: grid;
  gap: 8px;
  padding: 10px;
}

.journey-event {
  position: relative;
  display: grid;
  grid-template-columns: 18px minmax(0, 1fr);
  gap: 10px;
  padding: 10px;
  background: rgba(255, 255, 255, 0.74);
}

.journey-event i {
  width: 10px;
  height: 10px;
  margin-top: 5px;
  border-radius: 999px;
  background: #94a3b8;
  box-shadow: 0 0 0 4px rgba(148, 163, 184, 0.14);
}

.journey-event.done i {
  background: #34c759;
  box-shadow: 0 0 0 4px rgba(52, 199, 89, 0.14);
}

.journey-event.warn i {
  background: #ff9f0a;
  box-shadow: 0 0 0 4px rgba(255, 159, 10, 0.16);
}

.journey-event-head {
  min-width: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.journey-event-head strong {
  overflow: hidden;
  color: #0f172a;
  font-size: 13px;
  font-weight: 820;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.journey-event p {
  margin: 5px 0 0;
  color: #334155;
  font-size: 13px;
  line-height: 1.55;
  white-space: pre-wrap;
}

.desktop-review-modal:not(.hidden) .desktop-full-review > .full-review-section,
.desktop-review-modal:not(.hidden) .journey-hero,
.desktop-review-modal:not(.hidden) .journey-stage,
.desktop-review-modal:not(.hidden) .journey-detail-grid > .review-text-block,
.desktop-review-modal:not(.hidden) .journey-event {
  animation: desktopReviewCardIn 0.26s ease-out both;
}

.desktop-review-modal:not(.hidden) .desktop-full-review > .full-review-section:nth-child(2),
.desktop-review-modal:not(.hidden) .journey-stage:nth-child(2),
.desktop-review-modal:not(.hidden) .journey-detail-grid > .review-text-block:nth-child(2),
.desktop-review-modal:not(.hidden) .journey-event:nth-child(2) {
  animation-delay: 0.03s;
}

.desktop-review-modal:not(.hidden) .desktop-full-review > .full-review-section:nth-child(3),
.desktop-review-modal:not(.hidden) .journey-stage:nth-child(3),
.desktop-review-modal:not(.hidden) .journey-detail-grid > .review-text-block:nth-child(3),
.desktop-review-modal:not(.hidden) .journey-event:nth-child(3) {
  animation-delay: 0.06s;
}

.desktop-review-modal:not(.hidden) .desktop-full-review > .full-review-section:nth-child(4),
.desktop-review-modal:not(.hidden) .journey-stage:nth-child(4),
.desktop-review-modal:not(.hidden) .journey-detail-grid > .review-text-block:nth-child(4),
.desktop-review-modal:not(.hidden) .journey-event:nth-child(4) {
  animation-delay: 0.09s;
}

@media (hover: hover) and (pointer: fine) {
  .review-text-block:hover,
  .full-review-card:hover,
  .full-script-card:hover,
  .journey-stage:hover,
  .journey-event:hover {
    transform: translateY(-1px);
    border-color: rgba(10, 132, 255, 0.30);
    box-shadow: 0 10px 24px rgba(28, 42, 60, 0.10), 0 1px 0 rgba(255, 255, 255, 0.88) inset;
  }
}

:root[data-desktop-theme="light"] {
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
:root:not([data-desktop-theme="light"]) {
    color-scheme: dark;
    --desktop-bg: #0b1118;
    --desktop-surface: rgba(18, 24, 34, 0.82);
    --desktop-surface-strong: rgba(24, 31, 43, 0.94);
    --desktop-surface-soft: rgba(15, 22, 32, 0.78);
    --desktop-border: rgba(148, 163, 184, 0.18);
    --desktop-border-strong: rgba(148, 163, 184, 0.28);
    --desktop-text: #eef4fb;
    --desktop-muted: #9aa8ba;
    --desktop-primary: #0a84ff;
    --desktop-primary-strong: #5eb0ff;
    --desktop-primary-soft: rgba(10, 132, 255, 0.18);
    --desktop-danger: #ff6b63;
    --desktop-warn: #ffb340;
    --desktop-ok: #45c47d;
    --desktop-shadow: 0 22px 58px rgba(0, 0, 0, 0.36), 0 1px 0 rgba(255, 255, 255, 0.06) inset;
    --desktop-shadow-soft: 0 12px 28px rgba(0, 0, 0, 0.28);
}

:root:not([data-desktop-theme="light"]) body.desktop-page {
    background:
      radial-gradient(circle at 18% 0%, rgba(20, 34, 52, 0.62), transparent 32%),
      linear-gradient(135deg, #090f16 0%, #101822 46%, #0b1118 100%);
    color: var(--desktop-text);
}

:root:not([data-desktop-theme="light"]) .desktop-shell {
    background:
      linear-gradient(135deg, rgba(18, 27, 39, 0.72), rgba(11, 17, 24, 0.88)),
      var(--desktop-bg);
}

:root:not([data-desktop-theme="light"]) .desktop-sidebar {
    border-right-color: rgba(148, 163, 184, 0.16);
    background: rgba(13, 20, 29, 0.74);
}

:root:not([data-desktop-theme="light"]) .desktop-brand img {
    filter: drop-shadow(0 8px 18px rgba(10, 132, 255, 0.34));
}

:root:not([data-desktop-theme="light"]) .desktop-brand small,
  :root:not([data-desktop-theme="light"]) .desktop-brand-domain,
  :root:not([data-desktop-theme="light"]) .sidebar-foot span,
  :root:not([data-desktop-theme="light"]) .header-status,
  :root:not([data-desktop-theme="light"]) .desktop-header p,
  :root:not([data-desktop-theme="light"]) .desktop-header span,
  :root:not([data-desktop-theme="light"]) .search-box span,
  :root:not([data-desktop-theme="light"]) .select-box span,
  :root:not([data-desktop-theme="light"]) .quick-form label span,
  :root:not([data-desktop-theme="light"]) .panel-head span,
  :root:not([data-desktop-theme="light"]) .detail-head span,
  :root:not([data-desktop-theme="light"]) .detail-grid span,
  :root:not([data-desktop-theme="light"]) .detail-insight-card span,
  :root:not([data-desktop-theme="light"]) .detail-context-line span,
  :root:not([data-desktop-theme="light"]) .detail-block h3,
  :root:not([data-desktop-theme="light"]) .form-head span,
  :root:not([data-desktop-theme="light"]) .metric-card span,
  :root:not([data-desktop-theme="light"]) .metric-card small,
  :root:not([data-desktop-theme="light"]) .customer-cell span,
  :root:not([data-desktop-theme="light"]) .action-cell span,
  :root:not([data-desktop-theme="light"]) .project-cell span,
  :root:not([data-desktop-theme="light"]) .quality-cell small,
  :root:not([data-desktop-theme="light"]) .cell-muted,
  :root:not([data-desktop-theme="light"]) .page-info,
  :root:not([data-desktop-theme="light"]) .settings-panel-head p,
  :root:not([data-desktop-theme="light"]) .settings-list dt,
  :root:not([data-desktop-theme="light"]) .settings-status-item span,
  :root:not([data-desktop-theme="light"]) .desktop-field-control span,
  :root:not([data-desktop-theme="light"]) .desktop-settings-summary,
  :root:not([data-desktop-theme="light"]) .about-brand span,
  :root:not([data-desktop-theme="light"]) .global-kpi-card span,
  :root:not([data-desktop-theme="light"]) .global-kpi-card small,
  :root:not([data-desktop-theme="light"]) .command-card span,
  :root:not([data-desktop-theme="light"]) .command-card small,
  :root:not([data-desktop-theme="light"]) .global-panel-head span,
  :root:not([data-desktop-theme="light"]) .opportunity-item span,
  :root:not([data-desktop-theme="light"]) .opportunity-item small,
  :root:not([data-desktop-theme="light"]) .money-review-card span,
  :root:not([data-desktop-theme="light"]) .money-review-card small,
  :root:not([data-desktop-theme="light"]) .money-review-card p,
  :root:not([data-desktop-theme="light"]) .dist-row span,
  :root:not([data-desktop-theme="light"]) .dist-empty,
  :root:not([data-desktop-theme="light"]) .desktop-drill-head span,
  :root:not([data-desktop-theme="light"]) .desktop-drill-head small,
  :root:not([data-desktop-theme="light"]) .desktop-review-head span,
  :root:not([data-desktop-theme="light"]) .desktop-review-head small,
  :root:not([data-desktop-theme="light"]) .desktop-local-summary,
  :root:not([data-desktop-theme="light"]) .desktop-review-empty,
  :root:not([data-desktop-theme="light"]) .desktop-review-loading,
  :root:not([data-desktop-theme="light"]) .desktop-review-empty span,
  :root:not([data-desktop-theme="light"]) .desktop-review-loading span,
  :root:not([data-desktop-theme="light"]) .collector-progress-panel span,
  :root:not([data-desktop-theme="light"]) .collector-detail-empty,
  :root:not([data-desktop-theme="light"]) .collector-result-card span,
  :root:not([data-desktop-theme="light"]) .review-customer-title span,
  :root:not([data-desktop-theme="light"]) .review-info-card span,
  :root:not([data-desktop-theme="light"]) .review-text-block h3,
  :root:not([data-desktop-theme="light"]) .review-native-head span,
  :root:not([data-desktop-theme="light"]) .review-line span,
  :root:not([data-desktop-theme="light"]) .review-script-row span,
  :root:not([data-desktop-theme="light"]) .review-history-row time,
  :root:not([data-desktop-theme="light"]) .review-history-row small,
  :root:not([data-desktop-theme="light"]) .review-customer-title p,
  :root:not([data-desktop-theme="light"]) .full-review-section-head span,
  :root:not([data-desktop-theme="light"]) .full-review-line > span,
  :root:not([data-desktop-theme="light"]) .full-review-meta-grid span,
  :root:not([data-desktop-theme="light"]) .review-followup-form label span,
  :root:not([data-desktop-theme="light"]) .full-battle-main span,
  :root:not([data-desktop-theme="light"]) .full-battle-main p,
  :root:not([data-desktop-theme="light"]) .battle-platform-metric span,
  :root:not([data-desktop-theme="light"]) .battle-platform-row > span,
  :root:not([data-desktop-theme="light"]) .full-event-head time,
  :root:not([data-desktop-theme="light"]) .full-event-action span,
  :root:not([data-desktop-theme="light"]) .full-event-meta span,
  :root:not([data-desktop-theme="light"]) .review-followup-actions span,
  :root:not([data-desktop-theme="light"]) .journey-fact span,
  :root:not([data-desktop-theme="light"]) .journey-stage-head span,
  :root:not([data-desktop-theme="light"]) .journey-stage-head b,
  :root:not([data-desktop-theme="light"]) .journey-stage small,
  :root:not([data-desktop-theme="light"]) .journey-event-head span {
    color: var(--desktop-muted);
  }

  :root:not([data-desktop-theme="light"]) .metric-card.data-quality {
    --metric-analyzed-color: #f4f8fd;
    --metric-insufficient-color: #ffd08a;
    --metric-total-color: #cbd5e1;
    --metric-quality-divider: rgba(148, 163, 184, 0.22);
  }

:root:not([data-desktop-theme="light"]) .settings-list .desktop-site-row span {
    color: #7cc4ff;
}

:root:not([data-desktop-theme="light"]) .desktop-inline-btn {
    border-color: rgba(148, 163, 184, 0.18);
    background: rgba(255, 255, 255, 0.07);
    color: #d9e5f2;
}

:root:not([data-desktop-theme="light"]) .desktop-inline-btn:hover {
    border-color: rgba(124, 196, 255, 0.32);
    background: rgba(10, 132, 255, 0.12);
    color: #b8ddff;
}

:root:not([data-desktop-theme="light"]) .section-toggle,
  :root:not([data-desktop-theme="light"]) .queue-item,
  :root:not([data-desktop-theme="light"]) .side-link,
  :root:not([data-desktop-theme="light"]) .sidebar-foot button,
  :root:not([data-desktop-theme="light"]) .desktop-btn,
  :root:not([data-desktop-theme="light"]) .pager-btn,
  :root:not([data-desktop-theme="light"]) .table-drill-btn,
  :root:not([data-desktop-theme="light"]) .dist-row strong,
  :root:not([data-desktop-theme="light"]) .dist-row span {
    color: #cbd6e4;
}

:root:not([data-desktop-theme="light"]) .section-toggle .sidebar-icon,
  :root:not([data-desktop-theme="light"]) .sidebar-icon {
    color: #a9b7c8;
}

:root:not([data-desktop-theme="light"]) .section-toggle:hover,
  :root:not([data-desktop-theme="light"]) .queue-item:hover,
  :root:not([data-desktop-theme="light"]) .side-link:hover,
  :root:not([data-desktop-theme="light"]) .sidebar-foot button:hover,
  :root:not([data-desktop-theme="light"]) .desktop-btn:hover,
  :root:not([data-desktop-theme="light"]) .pager-btn:hover,
  :root:not([data-desktop-theme="light"]) .global-kpi-card:hover,
  :root:not([data-desktop-theme="light"]) .table-drill-btn:hover,
  :root:not([data-desktop-theme="light"]) .dist-row.dist-clickable:hover {
    border-color: rgba(10, 132, 255, 0.26);
    background: rgba(42, 56, 74, 0.62);
    color: #f4f8fd;
}

:root:not([data-desktop-theme="light"]) .queue-item:hover .sidebar-icon,
  :root:not([data-desktop-theme="light"]) .side-link:hover .sidebar-icon,
  :root:not([data-desktop-theme="light"]) .sidebar-foot button:hover .sidebar-icon {
    color: #8fc7ff;
}

:root:not([data-desktop-theme="light"]) .queue-item.active,
  :root:not([data-desktop-theme="light"]) .side-link.active {
    border-color: rgba(10, 132, 255, 0.36);
    background: rgba(10, 132, 255, 0.16);
    color: #f4f8fd;
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.18), 0 1px 0 rgba(255, 255, 255, 0.06) inset;
}

:root:not([data-desktop-theme="light"]) .queue-item strong,
  :root:not([data-desktop-theme="light"]) .desktop-header h1,
  :root:not([data-desktop-theme="light"]) .panel-head h2,
  :root:not([data-desktop-theme="light"]) .metric-card strong,
  :root:not([data-desktop-theme="light"]) .customer-cell strong,
  :root:not([data-desktop-theme="light"]) .action-cell strong,
  :root:not([data-desktop-theme="light"]) .project-cell strong,
  :root:not([data-desktop-theme="light"]) .quality-cell strong,
  :root:not([data-desktop-theme="light"]) .detail-empty strong,
  :root:not([data-desktop-theme="light"]) .detail-head strong,
  :root:not([data-desktop-theme="light"]) .detail-grid strong,
  :root:not([data-desktop-theme="light"]) .detail-insight-card strong,
  :root:not([data-desktop-theme="light"]) .detail-block p,
  :root:not([data-desktop-theme="light"]) .form-head strong,
  :root:not([data-desktop-theme="light"]) .settings-panel-head h2,
  :root:not([data-desktop-theme="light"]) .settings-list dd,
  :root:not([data-desktop-theme="light"]) .settings-status-item strong,
  :root:not([data-desktop-theme="light"]) .about-brand strong,
  :root:not([data-desktop-theme="light"]) .global-kpi-card strong,
  :root:not([data-desktop-theme="light"]) .global-panel-head h2,
  :root:not([data-desktop-theme="light"]) .distribution-grid h3,
  :root:not([data-desktop-theme="light"]) .money-review-card strong,
  :root:not([data-desktop-theme="light"]) .command-card strong,
  :root:not([data-desktop-theme="light"]) .global-table td strong,
  :root:not([data-desktop-theme="light"]) .opportunity-item strong,
  :root:not([data-desktop-theme="light"]) .opportunity-item b,
  :root:not([data-desktop-theme="light"]) .desktop-drill-head strong,
  :root:not([data-desktop-theme="light"]) .drill-customer-row strong,
  :root:not([data-desktop-theme="light"]) .drill-customer-row b,
  :root:not([data-desktop-theme="light"]) .desktop-review-head strong,
  :root:not([data-desktop-theme="light"]) .desktop-review-empty strong,
  :root:not([data-desktop-theme="light"]) .desktop-review-loading strong,
  :root:not([data-desktop-theme="light"]) .collector-progress-panel strong,
  :root:not([data-desktop-theme="light"]) .collector-detail-empty strong,
  :root:not([data-desktop-theme="light"]) .collector-result-card strong,
  :root:not([data-desktop-theme="light"]) .review-customer-title h2,
  :root:not([data-desktop-theme="light"]) .review-info-card strong,
  :root:not([data-desktop-theme="light"]) .review-text-block h3,
  :root:not([data-desktop-theme="light"]) .review-native-head h3,
  :root:not([data-desktop-theme="light"]) .review-line strong,
  :root:not([data-desktop-theme="light"]) .review-script-row p,
  :root:not([data-desktop-theme="light"]) .review-history-row span,
  :root:not([data-desktop-theme="light"]) .review-history-row strong,
  :root:not([data-desktop-theme="light"]) .full-review-section-head h3,
  :root:not([data-desktop-theme="light"]) .full-review-card h4,
  :root:not([data-desktop-theme="light"]) .full-script-card h4,
  :root:not([data-desktop-theme="light"]) .full-review-value,
  :root:not([data-desktop-theme="light"]) .full-review-meta-value,
  :root:not([data-desktop-theme="light"]) .full-battle-main > div:first-child > strong,
  :root:not([data-desktop-theme="light"]) .battle-platform-metric strong,
  :root:not([data-desktop-theme="light"]) .battle-platform-text,
  :root:not([data-desktop-theme="light"]) .full-script-card p,
  :root:not([data-desktop-theme="light"]) .full-event-head strong,
  :root:not([data-desktop-theme="light"]) .full-event-item p,
  :root:not([data-desktop-theme="light"]) .full-event-action,
  :root:not([data-desktop-theme="light"]) .full-event-action b,
  :root:not([data-desktop-theme="light"]) .journey-fact strong,
  :root:not([data-desktop-theme="light"]) .journey-stage strong,
  :root:not([data-desktop-theme="light"]) .journey-stage p,
  :root:not([data-desktop-theme="light"]) .journey-event-head strong,
  :root:not([data-desktop-theme="light"]) .journey-event p {
    color: var(--desktop-text);
}

:root:not([data-desktop-theme="light"]) .desktop-header,
  :root:not([data-desktop-theme="light"]) .desktop-toolbar,
  :root:not([data-desktop-theme="light"]) .metric-strip,
  :root:not([data-desktop-theme="light"]) .customer-list-panel,
  :root:not([data-desktop-theme="light"]) .customer-detail-panel,
  :root:not([data-desktop-theme="light"]) .settings-panel,
  :root:not([data-desktop-theme="light"]) .global-kpi-card,
  :root:not([data-desktop-theme="light"]) .global-panel,
  :root:not([data-desktop-theme="light"]) .desktop-money-panel,
  :root:not([data-desktop-theme="light"]) .collector-progress-panel,
  :root:not([data-desktop-theme="light"]) .collector-list-panel,
  :root:not([data-desktop-theme="light"]) .collector-detail-panel,
  :root:not([data-desktop-theme="light"]) .review-hero,
  :root:not([data-desktop-theme="light"]) .review-money-strip,
  :root:not([data-desktop-theme="light"]) .review-text-block,
  :root:not([data-desktop-theme="light"]) .review-native-panel,
  :root:not([data-desktop-theme="light"]) .full-review-section,
  :root:not([data-desktop-theme="light"]) .journey-hero,
  :root:not([data-desktop-theme="light"]) .journey-stage,
  :root:not([data-desktop-theme="light"]) .journey-fact,
  :root:not([data-desktop-theme="light"]) .journey-event {
    border-color: var(--desktop-border);
    background: var(--desktop-surface);
    box-shadow: var(--desktop-shadow-soft);
}

:root:not([data-desktop-theme="light"]) .desktop-header {
    background:
      linear-gradient(180deg, rgba(24, 31, 43, 0.92), rgba(18, 24, 34, 0.74)),
      var(--desktop-surface);
}

:root:not([data-desktop-theme="light"]) .header-status,
  :root:not([data-desktop-theme="light"]) .sidebar-foot button,
  :root:not([data-desktop-theme="light"]) .desktop-btn,
  :root:not([data-desktop-theme="light"]) .pager-btn {
    border-color: rgba(148, 163, 184, 0.24);
    background: rgba(25, 33, 45, 0.78);
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.06) inset;
}

:root:not([data-desktop-theme="light"]) .desktop-btn.primary,
  :root:not([data-desktop-theme="light"]) .quick-form .desktop-btn.primary {
    background: #0a84ff;
    color: #ffffff;
}

:root:not([data-desktop-theme="light"]) .desktop-btn.primary:hover,
  :root:not([data-desktop-theme="light"]) .quick-form .desktop-btn.primary:hover {
    background: #2f9bff;
    color: #ffffff;
}

:root:not([data-desktop-theme="light"]) .desktop-btn.ghost {
    background: rgba(25, 33, 45, 0.48);
}

:root:not([data-desktop-theme="light"]) .desktop-btn.danger {
    border-color: rgba(255, 107, 99, 0.28);
    background: rgba(255, 107, 99, 0.10);
    color: #ffb4ad;
}

:root:not([data-desktop-theme="light"]) .desktop-btn.danger:hover {
    border-color: rgba(255, 107, 99, 0.40);
    background: rgba(255, 107, 99, 0.16);
    color: #ffd7d3;
}

:root:not([data-desktop-theme="light"]) .search-box input,
  :root:not([data-desktop-theme="light"]) .select-box input,
  :root:not([data-desktop-theme="light"]) .select-box select,
  :root:not([data-desktop-theme="light"]) .toolbar-check,
  :root:not([data-desktop-theme="light"]) .panel-head select,
  :root:not([data-desktop-theme="light"]) .quick-form select,
  :root:not([data-desktop-theme="light"]) .quick-form input,
  :root:not([data-desktop-theme="light"]) .quick-form textarea,
  :root:not([data-desktop-theme="light"]) .desktop-input,
  :root:not([data-desktop-theme="light"]) .review-followup-form input,
  :root:not([data-desktop-theme="light"]) .review-followup-form select,
  :root:not([data-desktop-theme="light"]) .review-followup-form textarea {
    border-color: rgba(148, 163, 184, 0.24);
    background: rgba(10, 16, 24, 0.68);
    color: var(--desktop-text);
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.05) inset;
}

:root:not([data-desktop-theme="light"]) .search-box input::placeholder,
  :root:not([data-desktop-theme="light"]) .quick-form textarea::placeholder,
  :root:not([data-desktop-theme="light"]) .desktop-input::placeholder,
  :root:not([data-desktop-theme="light"]) .review-followup-form textarea::placeholder {
    color: rgba(154, 168, 186, 0.70);
}

:root:not([data-desktop-theme="light"]) .search-box input:focus,
  :root:not([data-desktop-theme="light"]) .select-box input:focus,
  :root:not([data-desktop-theme="light"]) .select-box select:focus,
  :root:not([data-desktop-theme="light"]) .panel-head select:focus,
  :root:not([data-desktop-theme="light"]) .quick-form select:focus,
  :root:not([data-desktop-theme="light"]) .quick-form input:focus,
  :root:not([data-desktop-theme="light"]) .quick-form textarea:focus,
  :root:not([data-desktop-theme="light"]) .desktop-input:focus,
  :root:not([data-desktop-theme="light"]) .review-followup-form input:focus,
  :root:not([data-desktop-theme="light"]) .review-followup-form select:focus,
  :root:not([data-desktop-theme="light"]) .review-followup-form textarea:focus {
    border-color: rgba(10, 132, 255, 0.68);
    background: rgba(12, 18, 27, 0.92);
    box-shadow: 0 0 0 4px rgba(10, 132, 255, 0.18);
}

:root:not([data-desktop-theme="light"]) .desktop-input:disabled,
  :root:not([data-desktop-theme="light"]) .desktop-input:read-only {
    color: rgba(154, 168, 186, 0.82);
    background: rgba(18, 24, 34, 0.62);
}

  :root:not([data-desktop-theme="light"]) .metric-card,
  :root:not([data-desktop-theme="light"]) .detail-grid div,
  :root:not([data-desktop-theme="light"]) .detail-insight-card,
  :root:not([data-desktop-theme="light"]) .detail-context-line,
  :root:not([data-desktop-theme="light"]) .detail-snapshot,
  :root:not([data-desktop-theme="light"]) .detail-block,
  :root:not([data-desktop-theme="light"]) .quick-form,
  :root:not([data-desktop-theme="light"]) .settings-status-item,
  :root:not([data-desktop-theme="light"]) .desktop-settings-summary .settings-pill,
  :root:not([data-desktop-theme="light"]) .money-review-card,
  :root:not([data-desktop-theme="light"]) .command-card,
  :root:not([data-desktop-theme="light"]) .distribution-grid > div,
  :root:not([data-desktop-theme="light"]) .opportunity-item,
  :root:not([data-desktop-theme="light"]) .desktop-local-summary,
  :root:not([data-desktop-theme="light"]) .desktop-local-pill,
  :root:not([data-desktop-theme="light"]) .collector-result-card,
  :root:not([data-desktop-theme="light"]) .review-info-card,
  :root:not([data-desktop-theme="light"]) .review-customer-badges strong,
  :root:not([data-desktop-theme="light"]) .review-customer-badges > span:not(.level-badge-wrap):not(.level-text-fallback),
  :root:not([data-desktop-theme="light"]) .full-review-card,
  :root:not([data-desktop-theme="light"]) .full-script-card,
  :root:not([data-desktop-theme="light"]) .full-review-meta-grid > div,
  :root:not([data-desktop-theme="light"]) .full-battle-main,
  :root:not([data-desktop-theme="light"]) .battle-platform-metric,
  :root:not([data-desktop-theme="light"]) .battle-platform-chip,
  :root:not([data-desktop-theme="light"]) .full-event-item,
  :root:not([data-desktop-theme="light"]) .full-event-meta span {
    border-color: rgba(148, 163, 184, 0.16);
    background: rgba(19, 27, 38, 0.70);
    box-shadow: none;
}

  :root:not([data-desktop-theme="light"]) .metric-card,
  :root:not([data-desktop-theme="light"]) .detail-grid div,
  :root:not([data-desktop-theme="light"]) .detail-insight-card,
  :root:not([data-desktop-theme="light"]) .detail-context-line,
  :root:not([data-desktop-theme="light"]) .detail-snapshot,
  :root:not([data-desktop-theme="light"]) .detail-block,
  :root:not([data-desktop-theme="light"]) .quick-form,
  :root:not([data-desktop-theme="light"]) .settings-status-item,
  :root:not([data-desktop-theme="light"]) .opportunity-item,
  :root:not([data-desktop-theme="light"]) .review-hero,
  :root:not([data-desktop-theme="light"]) .review-money-strip,
  :root:not([data-desktop-theme="light"]) .review-text-block,
  :root:not([data-desktop-theme="light"]) .review-native-panel,
  :root:not([data-desktop-theme="light"]) .full-review-section,
  :root:not([data-desktop-theme="light"]) .journey-hero,
  :root:not([data-desktop-theme="light"]) .journey-stage,
  :root:not([data-desktop-theme="light"]) .journey-fact,
  :root:not([data-desktop-theme="light"]) .journey-event {
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.05) inset;
}

:root:not([data-desktop-theme="light"]) .detail-sticky,
  :root:not([data-desktop-theme="light"]) .desktop-drill-head,
  :root:not([data-desktop-theme="light"]) .desktop-review-head,
  :root:not([data-desktop-theme="light"]) .full-review-section-head {
    background: rgba(16, 23, 33, 0.92);
}

:root:not([data-desktop-theme="light"]) .desktop-table th,
  :root:not([data-desktop-theme="light"]) .global-table th {
    background: rgba(15, 22, 32, 0.94);
    color: #a8b5c6;
}

:root:not([data-desktop-theme="light"]) .desktop-table td,
  :root:not([data-desktop-theme="light"]) .global-table th,
  :root:not([data-desktop-theme="light"]) .global-table td,
  :root:not([data-desktop-theme="light"]) .drill-customer-row p {
    color: #cbd6e4;
}

:root:not([data-desktop-theme="light"]) .desktop-table tbody tr:hover td,
  :root:not([data-desktop-theme="light"]) .desktop-table tbody tr.active td {
    background: rgba(10, 132, 255, 0.14);
}

:root:not([data-desktop-theme="light"]) .level-badge-wrap,
  :root:not([data-desktop-theme="light"]) .customer-cell .level-badge-wrap,
  :root:not([data-desktop-theme="light"]) .review-customer-badges .level-badge-wrap,
  :root:not([data-desktop-theme="light"]) .collector-country-cell .level-badge-wrap,
  :root:not([data-desktop-theme="light"]) .level-text-fallback,
  :root:not([data-desktop-theme="light"]) .customer-cell .level-text-fallback,
  :root:not([data-desktop-theme="light"]) .review-customer-badges .level-text-fallback,
  :root:not([data-desktop-theme="light"]) .collector-country-cell .level-text-fallback {
    border-color: rgba(148, 163, 184, 0.18);
    background: rgba(248, 250, 252, 0.92);
    color: #334155 !important;
}

:root:not([data-desktop-theme="light"]) .level-badge-text,
  :root:not([data-desktop-theme="light"]) .customer-cell .level-badge-text,
  :root:not([data-desktop-theme="light"]) .review-customer-badges .level-badge-text,
  :root:not([data-desktop-theme="light"]) .collector-country-cell .level-badge-text {
    color: #32608f;
}

:root:not([data-desktop-theme="light"]) .tag,
  :root:not([data-desktop-theme="light"]) .quality-grade,
  :root:not([data-desktop-theme="light"]) .table-drill-btn:hover,
  :root:not([data-desktop-theme="light"]) .full-event-action {
    background: rgba(10, 132, 255, 0.16);
    color: #8fc7ff;
}

:root:not([data-desktop-theme="light"]) .tag.ok,
  :root:not([data-desktop-theme="light"]) .quality-grade.ok,
  :root:not([data-desktop-theme="light"]) .desktop-settings-summary .settings-pill.ok,
  :root:not([data-desktop-theme="light"]) .desktop-local-pill.ok {
    background: rgba(69, 196, 125, 0.14);
    color: #8ee0b0;
}

:root:not([data-desktop-theme="light"]) .tag.warn,
  :root:not([data-desktop-theme="light"]) .quality-grade,
  :root:not([data-desktop-theme="light"]) .desktop-settings-summary .settings-pill.warn,
  :root:not([data-desktop-theme="light"]) .desktop-local-pill.warn,
  :root:not([data-desktop-theme="light"]) .money-review-card.warn,
  :root:not([data-desktop-theme="light"]) .full-review-card.critical,
  :root:not([data-desktop-theme="light"]) .journey-stage.attention {
    background: rgba(255, 179, 64, 0.13);
    color: #ffd08a;
}

:root:not([data-desktop-theme="light"]) .tag.danger,
  :root:not([data-desktop-theme="light"]) .quality-grade.danger,
  :root:not([data-desktop-theme="light"]) .desktop-settings-summary .settings-pill.fail,
  :root:not([data-desktop-theme="light"]) .desktop-local-pill.fail,
  :root:not([data-desktop-theme="light"]) .collector-result-card.danger {
    background: rgba(255, 107, 99, 0.13);
    color: #ffb4ad;
}

:root:not([data-desktop-theme="light"]) .tag.repeat {
    background: rgba(45, 212, 191, 0.15);
    color: #99f6e4;
}

  :root:not([data-desktop-theme="light"]) .tag.cultivate {
    background: rgba(148, 163, 184, 0.16);
    color: #cbd5e1;
  }

  :root:not([data-desktop-theme="light"]) .tag.customer-brand {
    background: rgba(168, 85, 247, 0.17);
    color: #e9d5ff;
  }

  :root:not([data-desktop-theme="light"]) .tag.customer-importer {
    background: rgba(99, 102, 241, 0.17);
    color: #c7d2fe;
  }

  :root:not([data-desktop-theme="light"]) .tag.customer-retail {
    background: rgba(6, 182, 212, 0.16);
    color: #a5f3fc;
  }

  :root:not([data-desktop-theme="light"]) .tag.customer-contractor {
    background: rgba(249, 115, 22, 0.16);
    color: #fed7aa;
  }

  :root:not([data-desktop-theme="light"]) .tag.customer-soho {
    background: rgba(217, 70, 239, 0.16);
    color: #f5d0fe;
  }

  :root:not([data-desktop-theme="light"]) .tag.customer-amazon {
    background: rgba(245, 158, 11, 0.16);
    color: #fde68a;
  }

  :root:not([data-desktop-theme="light"]) .tag.customer-small-b {
    background: rgba(236, 72, 153, 0.16);
    color: #fbcfe8;
  }

  :root:not([data-desktop-theme="light"]) .tag.customer-independent {
    background: rgba(20, 184, 166, 0.16);
    color: #99f6e4;
  }

  :root:not([data-desktop-theme="light"]) .tag.customer-offline-wholesale {
    background: rgba(34, 197, 94, 0.16);
    color: #bbf7d0;
  }

  :root:not([data-desktop-theme="light"]) .tag.customer-prospect {
    background: rgba(14, 165, 233, 0.16);
    color: #bae6fd;
  }

  :root:not([data-desktop-theme="light"]) .tag.customer-other {
    background: rgba(148, 163, 184, 0.16);
    color: #cbd5e1;
  }

:root:not([data-desktop-theme="light"]) .quality-grade.muted {
    background: rgba(148, 163, 184, 0.14);
    color: #bcc8d7;
}

:root:not([data-desktop-theme="light"]) .money-review-card.ok,
  :root:not([data-desktop-theme="light"]) .full-review-card.signal,
  :root:not([data-desktop-theme="light"]) .journey-stage.done {
    border-color: rgba(69, 196, 125, 0.26);
    background: rgba(69, 196, 125, 0.10);
}

:root:not([data-desktop-theme="light"]) .money-review-card.sample,
  :root:not([data-desktop-theme="light"]) .full-review-card.action,
  :root:not([data-desktop-theme="light"]) .full-script-card.primary,
  :root:not([data-desktop-theme="light"]) .review-text-block.strong,
  :root:not([data-desktop-theme="light"]) .review-text-block.action,
  :root:not([data-desktop-theme="light"]) .journey-stage.active {
    border-color: rgba(10, 132, 255, 0.28);
    background: rgba(10, 132, 255, 0.13);
}

:root:not([data-desktop-theme="light"]) .desktop-drill-modal,
  :root:not([data-desktop-theme="light"]) .desktop-review-modal {
    background: rgba(2, 6, 12, 0.64);
}

:root:not([data-desktop-theme="light"]) .desktop-drill-panel,
  :root:not([data-desktop-theme="light"]) .desktop-review-panel {
    border-color: rgba(148, 163, 184, 0.24);
    background: rgba(13, 20, 29, 0.98);
    box-shadow: 0 34px 86px rgba(0, 0, 0, 0.52), 0 1px 0 rgba(255, 255, 255, 0.06) inset;
}

:root:not([data-desktop-theme="light"]) .metric-card:hover {
    border-color: rgba(87, 166, 255, 0.34);
    background: rgba(25, 36, 51, 0.90);
    box-shadow: 0 10px 22px rgba(0, 0, 0, 0.18);
}

:root:not([data-desktop-theme="light"]) .metric-card.active,
:root:not([data-desktop-theme="light"]) .metric-card[aria-pressed="true"] {
    border-color: rgba(87, 166, 255, 0.62);
    background: rgba(10, 132, 255, 0.16);
    box-shadow: 0 0 0 2px rgba(10, 132, 255, 0.13);
}

:root:not([data-desktop-theme="light"]) .customer-star-btn {
    color: #8391a4;
}

:root:not([data-desktop-theme="light"]) .customer-star-btn:hover,
:root:not([data-desktop-theme="light"]) .customer-star-btn.is-starred {
    background: rgba(245, 158, 11, 0.12);
    color: #f8c15c;
}

:root:not([data-desktop-theme="light"]) .desktop-drill-body,
  :root:not([data-desktop-theme="light"]) .desktop-review-body,
  :root:not([data-desktop-theme="light"]) .desktop-journey-body {
    background: rgba(9, 15, 22, 0.96);
}

:root:not([data-desktop-theme="light"]) .drill-customer-row {
    border-color: rgba(148, 163, 184, 0.16);
    background: rgba(19, 27, 38, 0.74);
}

:root:not([data-desktop-theme="light"]) .drill-customer-row:hover,
  :root:not([data-desktop-theme="light"]) .opportunity-item:hover,
  :root:not([data-desktop-theme="light"]) .money-review-card:hover,
  :root:not([data-desktop-theme="light"]) .command-card.is-clickable:hover {
    border-color: rgba(10, 132, 255, 0.32);
    background: rgba(26, 38, 54, 0.86);
    box-shadow: 0 12px 26px rgba(0, 0, 0, 0.24);
}

:root:not([data-desktop-theme="light"]) .full-event-item i {
    background: #8391a4;
    box-shadow: 0 0 0 4px rgba(131, 145, 164, 0.16);
}

:root:not([data-desktop-theme="light"]) .desktop-offline-banner {
    border-color: rgba(255, 179, 64, 0.32);
    background: rgba(61, 41, 14, 0.94);
    color: #ffd08a;
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.28);
}

:root:not([data-desktop-theme="light"]) .desktop-offline-icon {
    background: rgba(255, 179, 64, 0.16);
    color: #ffd08a;
}

:root:not([data-desktop-theme="light"]) .desktop-offline-copy strong {
    color: #ffe0ad;
}

:root:not([data-desktop-theme="light"]) .desktop-offline-copy small {
    color: #ffc56f;
}

:root:not([data-desktop-theme="light"]) .desktop-toast {
    border-color: rgba(148, 163, 184, 0.24);
    background: rgba(238, 244, 251, 0.94);
    color: #0b1220;
}
}

:root[data-desktop-theme="dark"] {
    color-scheme: dark;
    --desktop-bg: #0b1118;
    --desktop-surface: rgba(18, 24, 34, 0.82);
    --desktop-surface-strong: rgba(24, 31, 43, 0.94);
    --desktop-surface-soft: rgba(15, 22, 32, 0.78);
    --desktop-border: rgba(148, 163, 184, 0.18);
    --desktop-border-strong: rgba(148, 163, 184, 0.28);
    --desktop-text: #eef4fb;
    --desktop-muted: #9aa8ba;
    --desktop-primary: #0a84ff;
    --desktop-primary-strong: #5eb0ff;
    --desktop-primary-soft: rgba(10, 132, 255, 0.18);
    --desktop-danger: #ff6b63;
    --desktop-warn: #ffb340;
    --desktop-ok: #45c47d;
    --desktop-shadow: 0 22px 58px rgba(0, 0, 0, 0.36), 0 1px 0 rgba(255, 255, 255, 0.06) inset;
    --desktop-shadow-soft: 0 12px 28px rgba(0, 0, 0, 0.28);
}

:root[data-desktop-theme="dark"] body.desktop-page {
    background:
      radial-gradient(circle at 18% 0%, rgba(20, 34, 52, 0.62), transparent 32%),
      linear-gradient(135deg, #090f16 0%, #101822 46%, #0b1118 100%);
    color: var(--desktop-text);
}

:root[data-desktop-theme="dark"] .desktop-shell {
    background:
      linear-gradient(135deg, rgba(18, 27, 39, 0.72), rgba(11, 17, 24, 0.88)),
      var(--desktop-bg);
}

:root[data-desktop-theme="dark"] .desktop-sidebar {
    border-right-color: rgba(148, 163, 184, 0.16);
    background: rgba(13, 20, 29, 0.74);
}

:root[data-desktop-theme="dark"] .desktop-brand img {
    filter: drop-shadow(0 8px 18px rgba(10, 132, 255, 0.34));
}

:root[data-desktop-theme="dark"] .desktop-brand small,
  :root[data-desktop-theme="dark"] .desktop-brand-domain,
  :root[data-desktop-theme="dark"] .sidebar-foot span,
  :root[data-desktop-theme="dark"] .header-status,
  :root[data-desktop-theme="dark"] .desktop-header p,
  :root[data-desktop-theme="dark"] .desktop-header span,
  :root[data-desktop-theme="dark"] .search-box span,
  :root[data-desktop-theme="dark"] .select-box span,
  :root[data-desktop-theme="dark"] .quick-form label span,
  :root[data-desktop-theme="dark"] .panel-head span,
  :root[data-desktop-theme="dark"] .detail-head span,
  :root[data-desktop-theme="dark"] .detail-grid span,
  :root[data-desktop-theme="dark"] .detail-insight-card span,
  :root[data-desktop-theme="dark"] .detail-context-line span,
  :root[data-desktop-theme="dark"] .detail-block h3,
  :root[data-desktop-theme="dark"] .form-head span,
  :root[data-desktop-theme="dark"] .metric-card span,
  :root[data-desktop-theme="dark"] .metric-card small,
  :root[data-desktop-theme="dark"] .customer-cell span,
  :root[data-desktop-theme="dark"] .action-cell span,
  :root[data-desktop-theme="dark"] .project-cell span,
  :root[data-desktop-theme="dark"] .quality-cell small,
  :root[data-desktop-theme="dark"] .cell-muted,
  :root[data-desktop-theme="dark"] .page-info,
  :root[data-desktop-theme="dark"] .settings-panel-head p,
  :root[data-desktop-theme="dark"] .settings-list dt,
  :root[data-desktop-theme="dark"] .settings-status-item span,
  :root[data-desktop-theme="dark"] .desktop-field-control span,
  :root[data-desktop-theme="dark"] .desktop-settings-summary,
  :root[data-desktop-theme="dark"] .about-brand span,
  :root[data-desktop-theme="dark"] .global-kpi-card span,
  :root[data-desktop-theme="dark"] .global-kpi-card small,
  :root[data-desktop-theme="dark"] .command-card span,
  :root[data-desktop-theme="dark"] .command-card small,
  :root[data-desktop-theme="dark"] .global-panel-head span,
  :root[data-desktop-theme="dark"] .opportunity-item span,
  :root[data-desktop-theme="dark"] .opportunity-item small,
  :root[data-desktop-theme="dark"] .money-review-card span,
  :root[data-desktop-theme="dark"] .money-review-card small,
  :root[data-desktop-theme="dark"] .money-review-card p,
  :root[data-desktop-theme="dark"] .dist-row span,
  :root[data-desktop-theme="dark"] .dist-empty,
  :root[data-desktop-theme="dark"] .desktop-drill-head span,
  :root[data-desktop-theme="dark"] .desktop-drill-head small,
  :root[data-desktop-theme="dark"] .desktop-review-head span,
  :root[data-desktop-theme="dark"] .desktop-review-head small,
  :root[data-desktop-theme="dark"] .desktop-local-summary,
  :root[data-desktop-theme="dark"] .desktop-review-empty,
  :root[data-desktop-theme="dark"] .desktop-review-loading,
  :root[data-desktop-theme="dark"] .desktop-review-empty span,
  :root[data-desktop-theme="dark"] .desktop-review-loading span,
  :root[data-desktop-theme="dark"] .collector-progress-panel span,
  :root[data-desktop-theme="dark"] .collector-detail-empty,
  :root[data-desktop-theme="dark"] .collector-result-card span,
  :root[data-desktop-theme="dark"] .review-customer-title span,
  :root[data-desktop-theme="dark"] .review-info-card span,
  :root[data-desktop-theme="dark"] .review-text-block h3,
  :root[data-desktop-theme="dark"] .review-native-head span,
  :root[data-desktop-theme="dark"] .review-line span,
  :root[data-desktop-theme="dark"] .review-script-row span,
  :root[data-desktop-theme="dark"] .review-history-row time,
  :root[data-desktop-theme="dark"] .review-history-row small,
  :root[data-desktop-theme="dark"] .review-customer-title p,
  :root[data-desktop-theme="dark"] .full-review-section-head span,
  :root[data-desktop-theme="dark"] .full-review-line > span,
  :root[data-desktop-theme="dark"] .full-review-meta-grid span,
  :root[data-desktop-theme="dark"] .review-followup-form label span,
  :root[data-desktop-theme="dark"] .full-battle-main span,
  :root[data-desktop-theme="dark"] .full-battle-main p,
  :root[data-desktop-theme="dark"] .battle-platform-metric span,
  :root[data-desktop-theme="dark"] .battle-platform-row > span,
  :root[data-desktop-theme="dark"] .full-event-head time,
  :root[data-desktop-theme="dark"] .full-event-action span,
  :root[data-desktop-theme="dark"] .full-event-meta span,
  :root[data-desktop-theme="dark"] .review-followup-actions span,
  :root[data-desktop-theme="dark"] .journey-fact span,
  :root[data-desktop-theme="dark"] .journey-stage-head span,
  :root[data-desktop-theme="dark"] .journey-stage-head b,
  :root[data-desktop-theme="dark"] .journey-stage small,
  :root[data-desktop-theme="dark"] .journey-event-head span {
    color: var(--desktop-muted);
  }

  :root[data-desktop-theme="dark"] .metric-card.data-quality {
    --metric-analyzed-color: #f4f8fd;
    --metric-insufficient-color: #ffd08a;
    --metric-total-color: #cbd5e1;
    --metric-quality-divider: rgba(148, 163, 184, 0.22);
  }

:root[data-desktop-theme="dark"] .settings-list .desktop-site-row span {
    color: #7cc4ff;
}

:root[data-desktop-theme="dark"] .desktop-inline-btn {
    border-color: rgba(148, 163, 184, 0.18);
    background: rgba(255, 255, 255, 0.07);
    color: #d9e5f2;
}

:root[data-desktop-theme="dark"] .desktop-inline-btn:hover {
    border-color: rgba(124, 196, 255, 0.32);
    background: rgba(10, 132, 255, 0.12);
    color: #b8ddff;
}

:root[data-desktop-theme="dark"] .section-toggle,
  :root[data-desktop-theme="dark"] .queue-item,
  :root[data-desktop-theme="dark"] .side-link,
  :root[data-desktop-theme="dark"] .sidebar-foot button,
  :root[data-desktop-theme="dark"] .desktop-btn,
  :root[data-desktop-theme="dark"] .pager-btn,
  :root[data-desktop-theme="dark"] .table-drill-btn,
  :root[data-desktop-theme="dark"] .dist-row strong,
  :root[data-desktop-theme="dark"] .dist-row span {
    color: #cbd6e4;
}

:root[data-desktop-theme="dark"] .section-toggle .sidebar-icon,
  :root[data-desktop-theme="dark"] .sidebar-icon {
    color: #a9b7c8;
}

:root[data-desktop-theme="dark"] .section-toggle:hover,
  :root[data-desktop-theme="dark"] .queue-item:hover,
  :root[data-desktop-theme="dark"] .side-link:hover,
  :root[data-desktop-theme="dark"] .sidebar-foot button:hover,
  :root[data-desktop-theme="dark"] .desktop-btn:hover,
  :root[data-desktop-theme="dark"] .pager-btn:hover,
  :root[data-desktop-theme="dark"] .global-kpi-card:hover,
  :root[data-desktop-theme="dark"] .table-drill-btn:hover,
  :root[data-desktop-theme="dark"] .dist-row.dist-clickable:hover {
    border-color: rgba(10, 132, 255, 0.26);
    background: rgba(42, 56, 74, 0.62);
    color: #f4f8fd;
}

:root[data-desktop-theme="dark"] .queue-item:hover .sidebar-icon,
  :root[data-desktop-theme="dark"] .side-link:hover .sidebar-icon,
  :root[data-desktop-theme="dark"] .sidebar-foot button:hover .sidebar-icon {
    color: #8fc7ff;
}

:root[data-desktop-theme="dark"] .queue-item.active,
  :root[data-desktop-theme="dark"] .side-link.active {
    border-color: rgba(10, 132, 255, 0.36);
    background: rgba(10, 132, 255, 0.16);
    color: #f4f8fd;
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.18), 0 1px 0 rgba(255, 255, 255, 0.06) inset;
}

:root[data-desktop-theme="dark"] .queue-item strong,
  :root[data-desktop-theme="dark"] .desktop-header h1,
  :root[data-desktop-theme="dark"] .panel-head h2,
  :root[data-desktop-theme="dark"] .metric-card strong,
  :root[data-desktop-theme="dark"] .customer-cell strong,
  :root[data-desktop-theme="dark"] .action-cell strong,
  :root[data-desktop-theme="dark"] .project-cell strong,
  :root[data-desktop-theme="dark"] .quality-cell strong,
  :root[data-desktop-theme="dark"] .detail-empty strong,
  :root[data-desktop-theme="dark"] .detail-head strong,
  :root[data-desktop-theme="dark"] .detail-grid strong,
  :root[data-desktop-theme="dark"] .detail-insight-card strong,
  :root[data-desktop-theme="dark"] .detail-block p,
  :root[data-desktop-theme="dark"] .form-head strong,
  :root[data-desktop-theme="dark"] .settings-panel-head h2,
  :root[data-desktop-theme="dark"] .settings-list dd,
  :root[data-desktop-theme="dark"] .settings-status-item strong,
  :root[data-desktop-theme="dark"] .about-brand strong,
  :root[data-desktop-theme="dark"] .global-kpi-card strong,
  :root[data-desktop-theme="dark"] .global-panel-head h2,
  :root[data-desktop-theme="dark"] .distribution-grid h3,
  :root[data-desktop-theme="dark"] .money-review-card strong,
  :root[data-desktop-theme="dark"] .command-card strong,
  :root[data-desktop-theme="dark"] .global-table td strong,
  :root[data-desktop-theme="dark"] .opportunity-item strong,
  :root[data-desktop-theme="dark"] .opportunity-item b,
  :root[data-desktop-theme="dark"] .desktop-drill-head strong,
  :root[data-desktop-theme="dark"] .drill-customer-row strong,
  :root[data-desktop-theme="dark"] .drill-customer-row b,
  :root[data-desktop-theme="dark"] .desktop-review-head strong,
  :root[data-desktop-theme="dark"] .desktop-review-empty strong,
  :root[data-desktop-theme="dark"] .desktop-review-loading strong,
  :root[data-desktop-theme="dark"] .collector-progress-panel strong,
  :root[data-desktop-theme="dark"] .collector-detail-empty strong,
  :root[data-desktop-theme="dark"] .collector-result-card strong,
  :root[data-desktop-theme="dark"] .review-customer-title h2,
  :root[data-desktop-theme="dark"] .review-info-card strong,
  :root[data-desktop-theme="dark"] .review-text-block h3,
  :root[data-desktop-theme="dark"] .review-native-head h3,
  :root[data-desktop-theme="dark"] .review-line strong,
  :root[data-desktop-theme="dark"] .review-script-row p,
  :root[data-desktop-theme="dark"] .review-history-row span,
  :root[data-desktop-theme="dark"] .review-history-row strong,
  :root[data-desktop-theme="dark"] .full-review-section-head h3,
  :root[data-desktop-theme="dark"] .full-review-card h4,
  :root[data-desktop-theme="dark"] .full-script-card h4,
  :root[data-desktop-theme="dark"] .full-review-value,
  :root[data-desktop-theme="dark"] .full-review-meta-value,
  :root[data-desktop-theme="dark"] .full-battle-main > div:first-child > strong,
  :root[data-desktop-theme="dark"] .battle-platform-metric strong,
  :root[data-desktop-theme="dark"] .battle-platform-text,
  :root[data-desktop-theme="dark"] .full-script-card p,
  :root[data-desktop-theme="dark"] .full-event-head strong,
  :root[data-desktop-theme="dark"] .full-event-item p,
  :root[data-desktop-theme="dark"] .full-event-action,
  :root[data-desktop-theme="dark"] .full-event-action b,
  :root[data-desktop-theme="dark"] .journey-fact strong,
  :root[data-desktop-theme="dark"] .journey-stage strong,
  :root[data-desktop-theme="dark"] .journey-stage p,
  :root[data-desktop-theme="dark"] .journey-event-head strong,
  :root[data-desktop-theme="dark"] .journey-event p {
    color: var(--desktop-text);
}

:root[data-desktop-theme="dark"] .desktop-header,
  :root[data-desktop-theme="dark"] .desktop-toolbar,
  :root[data-desktop-theme="dark"] .metric-strip,
  :root[data-desktop-theme="dark"] .customer-list-panel,
  :root[data-desktop-theme="dark"] .customer-detail-panel,
  :root[data-desktop-theme="dark"] .settings-panel,
  :root[data-desktop-theme="dark"] .global-kpi-card,
  :root[data-desktop-theme="dark"] .global-panel,
  :root[data-desktop-theme="dark"] .desktop-money-panel,
  :root[data-desktop-theme="dark"] .collector-progress-panel,
  :root[data-desktop-theme="dark"] .collector-list-panel,
  :root[data-desktop-theme="dark"] .collector-detail-panel,
  :root[data-desktop-theme="dark"] .review-hero,
  :root[data-desktop-theme="dark"] .review-money-strip,
  :root[data-desktop-theme="dark"] .review-text-block,
  :root[data-desktop-theme="dark"] .review-native-panel,
  :root[data-desktop-theme="dark"] .full-review-section,
  :root[data-desktop-theme="dark"] .journey-hero,
  :root[data-desktop-theme="dark"] .journey-stage,
  :root[data-desktop-theme="dark"] .journey-fact,
  :root[data-desktop-theme="dark"] .journey-event {
    border-color: var(--desktop-border);
    background: var(--desktop-surface);
    box-shadow: var(--desktop-shadow-soft);
}

:root[data-desktop-theme="dark"] .desktop-header {
    background:
      linear-gradient(180deg, rgba(24, 31, 43, 0.92), rgba(18, 24, 34, 0.74)),
      var(--desktop-surface);
}

:root[data-desktop-theme="dark"] .header-status,
  :root[data-desktop-theme="dark"] .sidebar-foot button,
  :root[data-desktop-theme="dark"] .desktop-btn,
  :root[data-desktop-theme="dark"] .pager-btn {
    border-color: rgba(148, 163, 184, 0.24);
    background: rgba(25, 33, 45, 0.78);
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.06) inset;
}

:root[data-desktop-theme="dark"] .desktop-btn.primary,
  :root[data-desktop-theme="dark"] .quick-form .desktop-btn.primary {
    background: #0a84ff;
    color: #ffffff;
}

:root[data-desktop-theme="dark"] .desktop-btn.primary:hover,
  :root[data-desktop-theme="dark"] .quick-form .desktop-btn.primary:hover {
    background: #2f9bff;
    color: #ffffff;
}

:root[data-desktop-theme="dark"] .desktop-btn.primary .sidebar-icon,
  :root[data-desktop-theme="dark"] .desktop-btn.primary span,
  :root:not([data-desktop-theme="light"]) .desktop-btn.primary .sidebar-icon,
  :root:not([data-desktop-theme="light"]) .desktop-btn.primary span {
    color: #ffffff;
}

:root[data-desktop-theme="dark"] .desktop-btn.ghost {
    background: rgba(25, 33, 45, 0.48);
}

:root[data-desktop-theme="dark"] .desktop-btn.danger {
    border-color: rgba(255, 107, 99, 0.28);
    background: rgba(255, 107, 99, 0.10);
    color: #ffb4ad;
}

:root[data-desktop-theme="dark"] .desktop-btn.danger:hover {
    border-color: rgba(255, 107, 99, 0.40);
    background: rgba(255, 107, 99, 0.16);
    color: #ffd7d3;
}

:root[data-desktop-theme="dark"] .search-box input,
  :root[data-desktop-theme="dark"] .select-box input,
  :root[data-desktop-theme="dark"] .select-box select,
  :root[data-desktop-theme="dark"] .toolbar-check,
  :root[data-desktop-theme="dark"] .panel-head select,
  :root[data-desktop-theme="dark"] .quick-form select,
  :root[data-desktop-theme="dark"] .quick-form input,
  :root[data-desktop-theme="dark"] .quick-form textarea,
  :root[data-desktop-theme="dark"] .desktop-input,
  :root[data-desktop-theme="dark"] .review-followup-form input,
  :root[data-desktop-theme="dark"] .review-followup-form select,
  :root[data-desktop-theme="dark"] .review-followup-form textarea {
    border-color: rgba(148, 163, 184, 0.24);
    background: rgba(10, 16, 24, 0.68);
    color: var(--desktop-text);
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.05) inset;
}

:root[data-desktop-theme="dark"] .search-box input::placeholder,
  :root[data-desktop-theme="dark"] .quick-form textarea::placeholder,
  :root[data-desktop-theme="dark"] .desktop-input::placeholder,
  :root[data-desktop-theme="dark"] .review-followup-form textarea::placeholder {
    color: rgba(154, 168, 186, 0.70);
}

:root[data-desktop-theme="dark"] .search-box input:focus,
  :root[data-desktop-theme="dark"] .select-box input:focus,
  :root[data-desktop-theme="dark"] .select-box select:focus,
  :root[data-desktop-theme="dark"] .panel-head select:focus,
  :root[data-desktop-theme="dark"] .quick-form select:focus,
  :root[data-desktop-theme="dark"] .quick-form input:focus,
  :root[data-desktop-theme="dark"] .quick-form textarea:focus,
  :root[data-desktop-theme="dark"] .desktop-input:focus,
  :root[data-desktop-theme="dark"] .review-followup-form input:focus,
  :root[data-desktop-theme="dark"] .review-followup-form select:focus,
  :root[data-desktop-theme="dark"] .review-followup-form textarea:focus {
    border-color: rgba(10, 132, 255, 0.68);
    background: rgba(12, 18, 27, 0.92);
    box-shadow: 0 0 0 4px rgba(10, 132, 255, 0.18);
}

:root[data-desktop-theme="dark"] .desktop-input:disabled,
  :root[data-desktop-theme="dark"] .desktop-input:read-only {
    color: rgba(154, 168, 186, 0.82);
    background: rgba(18, 24, 34, 0.62);
}

  :root[data-desktop-theme="dark"] .metric-card,
  :root[data-desktop-theme="dark"] .detail-grid div,
  :root[data-desktop-theme="dark"] .detail-insight-card,
  :root[data-desktop-theme="dark"] .detail-context-line,
  :root[data-desktop-theme="dark"] .detail-snapshot,
  :root[data-desktop-theme="dark"] .detail-block,
  :root[data-desktop-theme="dark"] .quick-form,
  :root[data-desktop-theme="dark"] .settings-status-item,
  :root[data-desktop-theme="dark"] .desktop-settings-summary .settings-pill,
  :root[data-desktop-theme="dark"] .money-review-card,
  :root[data-desktop-theme="dark"] .command-card,
  :root[data-desktop-theme="dark"] .distribution-grid > div,
  :root[data-desktop-theme="dark"] .opportunity-item,
  :root[data-desktop-theme="dark"] .desktop-local-summary,
  :root[data-desktop-theme="dark"] .desktop-local-pill,
  :root[data-desktop-theme="dark"] .collector-result-card,
  :root[data-desktop-theme="dark"] .review-info-card,
  :root[data-desktop-theme="dark"] .review-customer-badges strong,
  :root[data-desktop-theme="dark"] .review-customer-badges > span:not(.level-badge-wrap):not(.level-text-fallback),
  :root[data-desktop-theme="dark"] .full-review-card,
  :root[data-desktop-theme="dark"] .full-script-card,
  :root[data-desktop-theme="dark"] .full-review-meta-grid > div,
  :root[data-desktop-theme="dark"] .full-battle-main,
  :root[data-desktop-theme="dark"] .battle-platform-metric,
  :root[data-desktop-theme="dark"] .battle-platform-chip,
  :root[data-desktop-theme="dark"] .full-event-item,
  :root[data-desktop-theme="dark"] .full-event-meta span {
    border-color: rgba(148, 163, 184, 0.16);
    background: rgba(19, 27, 38, 0.70);
    box-shadow: none;
}

  :root[data-desktop-theme="dark"] .metric-card,
  :root[data-desktop-theme="dark"] .detail-grid div,
  :root[data-desktop-theme="dark"] .detail-insight-card,
  :root[data-desktop-theme="dark"] .detail-context-line,
  :root[data-desktop-theme="dark"] .detail-snapshot,
  :root[data-desktop-theme="dark"] .detail-block,
  :root[data-desktop-theme="dark"] .quick-form,
  :root[data-desktop-theme="dark"] .settings-status-item,
  :root[data-desktop-theme="dark"] .opportunity-item,
  :root[data-desktop-theme="dark"] .review-hero,
  :root[data-desktop-theme="dark"] .review-money-strip,
  :root[data-desktop-theme="dark"] .review-text-block,
  :root[data-desktop-theme="dark"] .review-native-panel,
  :root[data-desktop-theme="dark"] .full-review-section,
  :root[data-desktop-theme="dark"] .journey-hero,
  :root[data-desktop-theme="dark"] .journey-stage,
  :root[data-desktop-theme="dark"] .journey-fact,
  :root[data-desktop-theme="dark"] .journey-event {
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.05) inset;
}

:root[data-desktop-theme="dark"] .detail-sticky,
  :root[data-desktop-theme="dark"] .desktop-drill-head,
  :root[data-desktop-theme="dark"] .desktop-review-head,
  :root[data-desktop-theme="dark"] .full-review-section-head {
    background: rgba(16, 23, 33, 0.92);
}

:root[data-desktop-theme="dark"] .desktop-table th,
  :root[data-desktop-theme="dark"] .global-table th {
    background: rgba(15, 22, 32, 0.94);
    color: #a8b5c6;
}

:root[data-desktop-theme="dark"] .desktop-table td,
  :root[data-desktop-theme="dark"] .global-table th,
  :root[data-desktop-theme="dark"] .global-table td,
  :root[data-desktop-theme="dark"] .drill-customer-row p {
    color: #cbd6e4;
}

:root[data-desktop-theme="dark"] .desktop-table tbody tr:hover td,
  :root[data-desktop-theme="dark"] .desktop-table tbody tr.active td {
    background: rgba(10, 132, 255, 0.14);
}

:root[data-desktop-theme="dark"] .level-badge-wrap,
  :root[data-desktop-theme="dark"] .customer-cell .level-badge-wrap,
  :root[data-desktop-theme="dark"] .review-customer-badges .level-badge-wrap,
  :root[data-desktop-theme="dark"] .collector-country-cell .level-badge-wrap,
  :root[data-desktop-theme="dark"] .level-text-fallback,
  :root[data-desktop-theme="dark"] .customer-cell .level-text-fallback,
  :root[data-desktop-theme="dark"] .review-customer-badges .level-text-fallback,
  :root[data-desktop-theme="dark"] .collector-country-cell .level-text-fallback {
    border-color: rgba(148, 163, 184, 0.18);
    background: rgba(248, 250, 252, 0.92);
    color: #334155 !important;
}

:root[data-desktop-theme="dark"] .level-badge-text,
  :root[data-desktop-theme="dark"] .customer-cell .level-badge-text,
  :root[data-desktop-theme="dark"] .review-customer-badges .level-badge-text,
  :root[data-desktop-theme="dark"] .collector-country-cell .level-badge-text {
    color: #32608f;
}

:root[data-desktop-theme="dark"] .tag,
  :root[data-desktop-theme="dark"] .quality-grade,
  :root[data-desktop-theme="dark"] .table-drill-btn:hover,
  :root[data-desktop-theme="dark"] .full-event-action {
    background: rgba(10, 132, 255, 0.16);
    color: #8fc7ff;
}

:root[data-desktop-theme="dark"] .tag.ok,
  :root[data-desktop-theme="dark"] .quality-grade.ok,
  :root[data-desktop-theme="dark"] .desktop-settings-summary .settings-pill.ok,
  :root[data-desktop-theme="dark"] .desktop-local-pill.ok {
    background: rgba(69, 196, 125, 0.14);
    color: #8ee0b0;
}

:root[data-desktop-theme="dark"] .tag.warn,
  :root[data-desktop-theme="dark"] .quality-grade,
  :root[data-desktop-theme="dark"] .desktop-settings-summary .settings-pill.warn,
  :root[data-desktop-theme="dark"] .desktop-local-pill.warn,
  :root[data-desktop-theme="dark"] .money-review-card.warn,
  :root[data-desktop-theme="dark"] .full-review-card.critical,
  :root[data-desktop-theme="dark"] .journey-stage.attention {
    background: rgba(255, 179, 64, 0.13);
    color: #ffd08a;
}

:root[data-desktop-theme="dark"] .tag.danger,
  :root[data-desktop-theme="dark"] .quality-grade.danger,
  :root[data-desktop-theme="dark"] .desktop-settings-summary .settings-pill.fail,
  :root[data-desktop-theme="dark"] .desktop-local-pill.fail,
  :root[data-desktop-theme="dark"] .collector-result-card.danger {
    background: rgba(255, 107, 99, 0.13);
    color: #ffb4ad;
}

:root[data-desktop-theme="dark"] .tag.repeat {
    background: rgba(45, 212, 191, 0.15);
    color: #99f6e4;
}

:root[data-desktop-theme="dark"] .tag.cultivate {
  background: rgba(148, 163, 184, 0.16);
  color: #cbd5e1;
}

:root[data-desktop-theme="dark"] .tag.customer-brand {
  background: rgba(168, 85, 247, 0.17);
  color: #e9d5ff;
}

:root[data-desktop-theme="dark"] .tag.customer-importer {
  background: rgba(99, 102, 241, 0.17);
  color: #c7d2fe;
}

:root[data-desktop-theme="dark"] .tag.customer-retail {
  background: rgba(6, 182, 212, 0.16);
  color: #a5f3fc;
}

:root[data-desktop-theme="dark"] .tag.customer-contractor {
  background: rgba(249, 115, 22, 0.16);
  color: #fed7aa;
}

:root[data-desktop-theme="dark"] .tag.customer-soho {
  background: rgba(217, 70, 239, 0.16);
  color: #f5d0fe;
}

:root[data-desktop-theme="dark"] .tag.customer-amazon {
  background: rgba(245, 158, 11, 0.16);
  color: #fde68a;
}

:root[data-desktop-theme="dark"] .tag.customer-small-b {
  background: rgba(236, 72, 153, 0.16);
  color: #fbcfe8;
}

:root[data-desktop-theme="dark"] .tag.customer-independent {
  background: rgba(20, 184, 166, 0.16);
  color: #99f6e4;
}

:root[data-desktop-theme="dark"] .tag.customer-offline-wholesale {
  background: rgba(34, 197, 94, 0.16);
  color: #bbf7d0;
}

:root[data-desktop-theme="dark"] .tag.customer-prospect {
  background: rgba(14, 165, 233, 0.16);
  color: #bae6fd;
}

:root[data-desktop-theme="dark"] .tag.customer-other {
  background: rgba(148, 163, 184, 0.16);
  color: #cbd5e1;
}

:root[data-desktop-theme="dark"] .quality-grade.muted {
    background: rgba(148, 163, 184, 0.14);
    color: #bcc8d7;
}

:root[data-desktop-theme="dark"] .money-review-card.ok,
  :root[data-desktop-theme="dark"] .full-review-card.signal,
  :root[data-desktop-theme="dark"] .journey-stage.done {
    border-color: rgba(69, 196, 125, 0.26);
    background: rgba(69, 196, 125, 0.10);
}

:root[data-desktop-theme="dark"] .money-review-card.sample,
  :root[data-desktop-theme="dark"] .full-review-card.action,
  :root[data-desktop-theme="dark"] .full-script-card.primary,
  :root[data-desktop-theme="dark"] .review-text-block.strong,
  :root[data-desktop-theme="dark"] .review-text-block.action,
  :root[data-desktop-theme="dark"] .journey-stage.active {
    border-color: rgba(10, 132, 255, 0.28);
    background: rgba(10, 132, 255, 0.13);
}

:root[data-desktop-theme="dark"] .desktop-drill-modal,
  :root[data-desktop-theme="dark"] .desktop-review-modal {
    background: rgba(2, 6, 12, 0.64);
}

:root[data-desktop-theme="dark"] .desktop-drill-panel,
  :root[data-desktop-theme="dark"] .desktop-review-panel {
    border-color: rgba(148, 163, 184, 0.24);
    background: rgba(13, 20, 29, 0.98);
    box-shadow: 0 34px 86px rgba(0, 0, 0, 0.52), 0 1px 0 rgba(255, 255, 255, 0.06) inset;
}

:root[data-desktop-theme="dark"] .metric-card:hover {
    border-color: rgba(87, 166, 255, 0.34);
    background: rgba(25, 36, 51, 0.90);
    box-shadow: 0 10px 22px rgba(0, 0, 0, 0.18);
}

:root[data-desktop-theme="dark"] .metric-card.active,
:root[data-desktop-theme="dark"] .metric-card[aria-pressed="true"] {
    border-color: rgba(87, 166, 255, 0.62);
    background: rgba(10, 132, 255, 0.16);
    box-shadow: 0 0 0 2px rgba(10, 132, 255, 0.13);
}

:root[data-desktop-theme="dark"] .customer-star-btn {
    color: #8391a4;
}

:root[data-desktop-theme="dark"] .customer-star-btn:hover,
:root[data-desktop-theme="dark"] .customer-star-btn.is-starred {
    background: rgba(245, 158, 11, 0.12);
    color: #f8c15c;
}

:root[data-desktop-theme="dark"] .desktop-drill-body,
  :root[data-desktop-theme="dark"] .desktop-review-body,
  :root[data-desktop-theme="dark"] .desktop-journey-body {
    background: rgba(9, 15, 22, 0.96);
}

:root[data-desktop-theme="dark"] .drill-customer-row {
    border-color: rgba(148, 163, 184, 0.16);
    background: rgba(19, 27, 38, 0.74);
}

:root[data-desktop-theme="dark"] .drill-customer-row:hover,
  :root[data-desktop-theme="dark"] .opportunity-item:hover,
  :root[data-desktop-theme="dark"] .money-review-card:hover,
  :root[data-desktop-theme="dark"] .command-card.is-clickable:hover {
    border-color: rgba(10, 132, 255, 0.32);
    background: rgba(26, 38, 54, 0.86);
    box-shadow: 0 12px 26px rgba(0, 0, 0, 0.24);
}

:root[data-desktop-theme="dark"] .full-event-item i {
    background: #8391a4;
    box-shadow: 0 0 0 4px rgba(131, 145, 164, 0.16);
}

:root[data-desktop-theme="dark"] .desktop-offline-banner {
    border-color: rgba(255, 179, 64, 0.32);
    background: rgba(61, 41, 14, 0.94);
    color: #ffd08a;
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.28);
}

:root[data-desktop-theme="dark"] .desktop-offline-icon {
    background: rgba(255, 179, 64, 0.16);
    color: #ffd08a;
}

:root[data-desktop-theme="dark"] .desktop-offline-copy strong {
    color: #ffe0ad;
}

:root[data-desktop-theme="dark"] .desktop-offline-copy small {
    color: #ffc56f;
}

:root[data-desktop-theme="dark"] .desktop-toast {
    border-color: rgba(148, 163, 184, 0.24);
    background: rgba(238, 244, 251, 0.94);
    color: #0b1220;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-desktop-theme="light"]) .review-text-block p {
    color: #cbd6e4;
  }

  :root:not([data-desktop-theme="light"]) .review-customer-badges strong,
  :root:not([data-desktop-theme="light"]) .review-customer-badges > span:not(.level-badge-wrap):not(.level-text-fallback),
  :root:not([data-desktop-theme="light"]) .battle-platform-chip {
    border-color: rgba(87, 166, 255, 0.26);
    background: rgba(10, 132, 255, 0.14);
    color: #9fd3ff;
  }

  :root:not([data-desktop-theme="light"]) .review-text-block.strong,
  :root:not([data-desktop-theme="light"]) .review-text-block.action {
    border-color: rgba(87, 166, 255, 0.36);
    background: linear-gradient(180deg, rgba(10, 132, 255, 0.18), rgba(19, 27, 38, 0.78));
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.06) inset, inset 3px 0 0 rgba(87, 166, 255, 0.58);
  }

  :root:not([data-desktop-theme="light"]) .review-text-block.action {
    border-color: rgba(78, 214, 134, 0.34);
    background: linear-gradient(180deg, rgba(69, 196, 125, 0.16), rgba(19, 27, 38, 0.78));
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.06) inset, inset 3px 0 0 rgba(78, 214, 134, 0.54);
  }

  :root:not([data-desktop-theme="light"]) .review-text-block.danger {
    border-color: rgba(255, 191, 92, 0.34);
    background: linear-gradient(180deg, rgba(255, 179, 64, 0.15), rgba(19, 27, 38, 0.78));
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.06) inset, inset 3px 0 0 rgba(255, 191, 92, 0.56);
  }

  :root:not([data-desktop-theme="light"]) .review-text-block.strong h3,
  :root:not([data-desktop-theme="light"]) .review-text-block.strong p {
    color: #eaf4ff;
  }

  :root:not([data-desktop-theme="light"]) .review-text-block.action h3,
  :root:not([data-desktop-theme="light"]) .review-text-block.action p {
    color: #e7fff1;
  }

  :root:not([data-desktop-theme="light"]) .review-text-block.danger h3,
  :root:not([data-desktop-theme="light"]) .review-text-block.danger p {
    color: #ffe3ad;
  }

  :root:not([data-desktop-theme="light"]) .full-review-card.profile {
    border-color: rgba(87, 166, 255, 0.38);
    background: linear-gradient(180deg, rgba(10, 132, 255, 0.17), rgba(19, 27, 38, 0.74));
    box-shadow: inset 3px 0 0 rgba(87, 166, 255, 0.60);
  }

  :root:not([data-desktop-theme="light"]) .full-review-card.profile h4 {
    color: #9fd3ff;
  }

  :root:not([data-desktop-theme="light"]) .full-review-card.intent {
    border-color: rgba(78, 214, 134, 0.36);
    background: linear-gradient(180deg, rgba(69, 196, 125, 0.16), rgba(19, 27, 38, 0.74));
    box-shadow: inset 3px 0 0 rgba(78, 214, 134, 0.58);
  }

  :root:not([data-desktop-theme="light"]) .full-review-card.intent h4 {
    color: #a4edc2;
  }

  :root:not([data-desktop-theme="light"]) .full-review-card.persona {
    border-color: rgba(154, 153, 255, 0.34);
    background: linear-gradient(180deg, rgba(123, 122, 255, 0.15), rgba(19, 27, 38, 0.74));
    box-shadow: inset 3px 0 0 rgba(154, 153, 255, 0.56);
  }

  :root:not([data-desktop-theme="light"]) .full-review-card.persona h4 {
    color: #c6c5ff;
  }

  :root:not([data-desktop-theme="light"]) .full-review-card.featured {
    border-color: rgba(255, 191, 92, 0.40);
    background: linear-gradient(180deg, rgba(255, 179, 64, 0.17), rgba(19, 27, 38, 0.74));
    box-shadow: inset 3px 0 0 rgba(255, 191, 92, 0.62);
  }

  :root:not([data-desktop-theme="light"]) .full-review-card.featured h4 {
    color: #ffd994;
  }

  :root:not([data-desktop-theme="light"]) .journey-stage.done {
    border-color: rgba(78, 214, 134, 0.36);
    background: rgba(69, 196, 125, 0.12);
    box-shadow: inset 3px 0 0 rgba(78, 214, 134, 0.48);
  }

  :root:not([data-desktop-theme="light"]) .journey-stage.active {
    border-color: rgba(87, 166, 255, 0.40);
    background: rgba(10, 132, 255, 0.16);
    box-shadow: 0 0 0 3px rgba(10, 132, 255, 0.12), inset 3px 0 0 rgba(87, 166, 255, 0.52);
  }

  :root:not([data-desktop-theme="light"]) .journey-stage.attention {
    border-color: rgba(255, 191, 92, 0.40);
    background: rgba(255, 179, 64, 0.15);
    box-shadow: inset 3px 0 0 rgba(255, 191, 92, 0.56);
  }
}

:root[data-desktop-theme="dark"] .review-text-block p {
  color: #cbd6e4;
}

:root[data-desktop-theme="dark"] .review-customer-badges strong,
:root[data-desktop-theme="dark"] .review-customer-badges > span:not(.level-badge-wrap):not(.level-text-fallback),
:root[data-desktop-theme="dark"] .battle-platform-chip {
  border-color: rgba(87, 166, 255, 0.26);
  background: rgba(10, 132, 255, 0.14);
  color: #9fd3ff;
}

:root[data-desktop-theme="dark"] .review-text-block.strong,
:root[data-desktop-theme="dark"] .review-text-block.action {
  border-color: rgba(87, 166, 255, 0.36);
  background: linear-gradient(180deg, rgba(10, 132, 255, 0.18), rgba(19, 27, 38, 0.78));
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.06) inset, inset 3px 0 0 rgba(87, 166, 255, 0.58);
}

:root[data-desktop-theme="dark"] .review-text-block.action {
  border-color: rgba(78, 214, 134, 0.34);
  background: linear-gradient(180deg, rgba(69, 196, 125, 0.16), rgba(19, 27, 38, 0.78));
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.06) inset, inset 3px 0 0 rgba(78, 214, 134, 0.54);
}

:root[data-desktop-theme="dark"] .review-text-block.danger {
  border-color: rgba(255, 191, 92, 0.34);
  background: linear-gradient(180deg, rgba(255, 179, 64, 0.15), rgba(19, 27, 38, 0.78));
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.06) inset, inset 3px 0 0 rgba(255, 191, 92, 0.56);
}

:root[data-desktop-theme="dark"] .review-text-block.strong h3,
:root[data-desktop-theme="dark"] .review-text-block.strong p {
  color: #eaf4ff;
}

:root[data-desktop-theme="dark"] .review-text-block.action h3,
:root[data-desktop-theme="dark"] .review-text-block.action p {
  color: #e7fff1;
}

:root[data-desktop-theme="dark"] .review-text-block.danger h3,
:root[data-desktop-theme="dark"] .review-text-block.danger p {
  color: #ffe3ad;
}

:root[data-desktop-theme="dark"] .full-review-card.profile {
  border-color: rgba(87, 166, 255, 0.38);
  background: linear-gradient(180deg, rgba(10, 132, 255, 0.17), rgba(19, 27, 38, 0.74));
  box-shadow: inset 3px 0 0 rgba(87, 166, 255, 0.60);
}

:root[data-desktop-theme="dark"] .full-review-card.profile h4 {
  color: #9fd3ff;
}

:root[data-desktop-theme="dark"] .full-review-card.intent {
  border-color: rgba(78, 214, 134, 0.36);
  background: linear-gradient(180deg, rgba(69, 196, 125, 0.16), rgba(19, 27, 38, 0.74));
  box-shadow: inset 3px 0 0 rgba(78, 214, 134, 0.58);
}

:root[data-desktop-theme="dark"] .full-review-card.intent h4 {
  color: #a4edc2;
}

:root[data-desktop-theme="dark"] .full-review-card.persona {
  border-color: rgba(154, 153, 255, 0.34);
  background: linear-gradient(180deg, rgba(123, 122, 255, 0.15), rgba(19, 27, 38, 0.74));
  box-shadow: inset 3px 0 0 rgba(154, 153, 255, 0.56);
}

:root[data-desktop-theme="dark"] .full-review-card.persona h4 {
  color: #c6c5ff;
}

:root[data-desktop-theme="dark"] .full-review-card.featured {
  border-color: rgba(255, 191, 92, 0.40);
  background: linear-gradient(180deg, rgba(255, 179, 64, 0.17), rgba(19, 27, 38, 0.74));
  box-shadow: inset 3px 0 0 rgba(255, 191, 92, 0.62);
}

:root[data-desktop-theme="dark"] .full-review-card.featured h4 {
  color: #ffd994;
}

:root[data-desktop-theme="dark"] .journey-stage.done {
  border-color: rgba(78, 214, 134, 0.36);
  background: rgba(69, 196, 125, 0.12);
  box-shadow: inset 3px 0 0 rgba(78, 214, 134, 0.48);
}

:root[data-desktop-theme="dark"] .journey-stage.active {
  border-color: rgba(87, 166, 255, 0.40);
  background: rgba(10, 132, 255, 0.16);
  box-shadow: 0 0 0 3px rgba(10, 132, 255, 0.12), inset 3px 0 0 rgba(87, 166, 255, 0.52);
}

:root[data-desktop-theme="dark"] .journey-stage.attention {
  border-color: rgba(255, 191, 92, 0.40);
  background: rgba(255, 179, 64, 0.15);
  box-shadow: inset 3px 0 0 rgba(255, 191, 92, 0.56);
}

@media (prefers-color-scheme: dark) {
  :root:not([data-desktop-theme="light"]) .detail-insight-card.demand {
    border-color: rgba(74, 222, 128, 0.30);
    background: rgba(34, 197, 94, 0.10);
    box-shadow: inset 3px 0 0 rgba(74, 222, 128, 0.44);
  }

  :root:not([data-desktop-theme="light"]) .detail-insight-card.blocker {
    border-color: rgba(255, 191, 92, 0.34);
    background: rgba(255, 179, 64, 0.12);
    box-shadow: inset 3px 0 0 rgba(255, 191, 92, 0.50);
  }

  :root:not([data-desktop-theme="light"]) .detail-insight-card.pain {
    border-color: rgba(94, 176, 255, 0.34);
    background: rgba(10, 132, 255, 0.12);
    box-shadow: inset 3px 0 0 rgba(94, 176, 255, 0.48);
  }

  :root:not([data-desktop-theme="light"]) .detail-insight-card.mistake {
    border-color: rgba(255, 107, 99, 0.32);
    background: rgba(255, 69, 58, 0.10);
    box-shadow: inset 3px 0 0 rgba(255, 107, 99, 0.44);
  }
}

:root[data-desktop-theme="dark"] .detail-insight-card.demand {
  border-color: rgba(74, 222, 128, 0.30);
  background: rgba(34, 197, 94, 0.10);
  box-shadow: inset 3px 0 0 rgba(74, 222, 128, 0.44);
}

:root[data-desktop-theme="dark"] .detail-insight-card.blocker {
  border-color: rgba(255, 191, 92, 0.34);
  background: rgba(255, 179, 64, 0.12);
  box-shadow: inset 3px 0 0 rgba(255, 191, 92, 0.50);
}

:root[data-desktop-theme="dark"] .detail-insight-card.pain {
  border-color: rgba(94, 176, 255, 0.34);
  background: rgba(10, 132, 255, 0.12);
  box-shadow: inset 3px 0 0 rgba(94, 176, 255, 0.48);
}

:root[data-desktop-theme="dark"] .detail-insight-card.mistake {
  border-color: rgba(255, 107, 99, 0.32);
  background: rgba(255, 69, 58, 0.10);
  box-shadow: inset 3px 0 0 rgba(255, 107, 99, 0.44);
}

@media (prefers-color-scheme: dark) {
  :root:not([data-desktop-theme="light"]) .full-review-section.is-collapsible > .full-review-section-head:hover {
    background: rgba(30, 40, 55, 0.72);
  }

  :root:not([data-desktop-theme="light"]) .full-review-section.is-collapsible > .full-review-section-head::after {
    border-color: #a9b7c8;
  }
}

:root[data-desktop-theme="dark"] .full-review-section.is-collapsible > .full-review-section-head:hover {
  background: rgba(30, 40, 55, 0.72);
}

:root[data-desktop-theme="dark"] .full-review-section.is-collapsible > .full-review-section-head::after {
  border-color: #a9b7c8;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-desktop-theme="light"]) .desktop-sidebar {
    scrollbar-color: rgba(169, 183, 200, 0.22) transparent;
  }

  :root:not([data-desktop-theme="light"]) .desktop-sidebar::-webkit-scrollbar-thumb {
    background: rgba(169, 183, 200, 0.22);
    background-clip: content-box;
  }

  :root:not([data-desktop-theme="light"]) .section-toggle:hover,
  :root:not([data-desktop-theme="light"]) .queue-item:hover,
  :root:not([data-desktop-theme="light"]) .side-link:hover {
    border-color: rgba(87, 166, 255, 0.20);
    background: rgba(42, 56, 74, 0.42);
    color: #eaf4ff;
  }

  :root:not([data-desktop-theme="light"]) .queue-item.active,
  :root:not([data-desktop-theme="light"]) .side-link.active {
    border-color: rgba(87, 166, 255, 0.24);
    background: rgba(10, 132, 255, 0.13);
    color: #eaf4ff;
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.05) inset;
  }

  :root:not([data-desktop-theme="light"]) .queue-item.active::before,
  :root:not([data-desktop-theme="light"]) .side-link.active::before {
    background: #5eb0ff;
  }

  :root:not([data-desktop-theme="light"]) .queue-item strong {
    color: #d7e3f2;
  }

  :root:not([data-desktop-theme="light"]) .queue-item.active strong,
  :root:not([data-desktop-theme="light"]) .side-link.active .sidebar-icon,
  :root:not([data-desktop-theme="light"]) .queue-item.active .sidebar-icon {
    color: #8fc7ff;
  }
}

:root[data-desktop-theme="dark"] .desktop-sidebar {
  scrollbar-color: rgba(169, 183, 200, 0.22) transparent;
}

:root[data-desktop-theme="dark"] .desktop-sidebar::-webkit-scrollbar-thumb {
  background: rgba(169, 183, 200, 0.22);
  background-clip: content-box;
}

:root[data-desktop-theme="dark"] .section-toggle:hover,
:root[data-desktop-theme="dark"] .queue-item:hover,
:root[data-desktop-theme="dark"] .side-link:hover {
  border-color: rgba(87, 166, 255, 0.20);
  background: rgba(42, 56, 74, 0.42);
  color: #eaf4ff;
}

:root[data-desktop-theme="dark"] .queue-item.active,
:root[data-desktop-theme="dark"] .side-link.active {
  border-color: rgba(87, 166, 255, 0.24);
  background: rgba(10, 132, 255, 0.13);
  color: #eaf4ff;
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.05) inset;
}

:root[data-desktop-theme="dark"] .queue-item.active::before,
:root[data-desktop-theme="dark"] .side-link.active::before {
  background: #5eb0ff;
}

:root[data-desktop-theme="dark"] .queue-item strong {
  color: #d7e3f2;
}

:root[data-desktop-theme="dark"] .queue-item.active strong,
:root[data-desktop-theme="dark"] .side-link.active .sidebar-icon,
:root[data-desktop-theme="dark"] .queue-item.active .sidebar-icon {
  color: #8fc7ff;
}

@media (prefers-color-scheme: dark) and (hover: hover) and (pointer: fine) {
  :root:not([data-desktop-theme="light"]) .review-text-block:hover,
  :root:not([data-desktop-theme="light"]) .full-review-card:hover,
  :root:not([data-desktop-theme="light"]) .full-script-card:hover,
  :root:not([data-desktop-theme="light"]) .journey-stage:hover,
  :root:not([data-desktop-theme="light"]) .journey-event:hover {
    border-color: rgba(87, 166, 255, 0.34);
    background-color: rgba(25, 36, 51, 0.90);
    box-shadow: 0 12px 26px rgba(0, 0, 0, 0.24), 0 1px 0 rgba(255, 255, 255, 0.07) inset;
  }
}

@media (hover: hover) and (pointer: fine) {
  :root[data-desktop-theme="dark"] .review-text-block:hover,
  :root[data-desktop-theme="dark"] .full-review-card:hover,
  :root[data-desktop-theme="dark"] .full-script-card:hover,
  :root[data-desktop-theme="dark"] .journey-stage:hover,
  :root[data-desktop-theme="dark"] .journey-event:hover {
    border-color: rgba(87, 166, 255, 0.34);
    background-color: rgba(25, 36, 51, 0.90);
    box-shadow: 0 12px 26px rgba(0, 0, 0, 0.24), 0 1px 0 rgba(255, 255, 255, 0.07) inset;
  }
}

@media (prefers-color-scheme: dark) {
  :root:not([data-desktop-theme="light"]) .commitment-metric,
  :root:not([data-desktop-theme="light"]) .commitment-event {
    border-color: rgba(141, 164, 194, 0.22);
    background: rgba(20, 29, 41, 0.78);
  }

  :root:not([data-desktop-theme="light"]) .commitment-next {
    border-color: rgba(87, 166, 255, 0.34);
    border-left-color: #57a6ff;
    background: rgba(21, 43, 69, 0.74);
  }

  :root:not([data-desktop-theme="light"]) .commitment-next.overdue {
    border-color: rgba(255, 124, 112, 0.36);
    border-left-color: #ff7c70;
    background: rgba(67, 31, 32, 0.66);
  }

  :root:not([data-desktop-theme="light"]) .commitment-metric strong,
  :root:not([data-desktop-theme="light"]) .commitment-next-head strong,
  :root:not([data-desktop-theme="light"]) .commitment-next-times strong,
  :root:not([data-desktop-theme="light"]) .commitment-event-head strong {
    color: #e4edf8;
  }

  :root:not([data-desktop-theme="light"]) .commitment-next-action,
  :root:not([data-desktop-theme="light"]) .commitment-next blockquote,
  :root:not([data-desktop-theme="light"]) .commitment-event p,
  :root:not([data-desktop-theme="light"]) .commitment-event-meta {
    color: #b5c3d4;
  }
}

:root[data-desktop-theme="dark"] .commitment-metric,
:root[data-desktop-theme="dark"] .commitment-event {
  border-color: rgba(141, 164, 194, 0.22);
  background: rgba(20, 29, 41, 0.78);
}

:root[data-desktop-theme="dark"] .commitment-next {
  border-color: rgba(87, 166, 255, 0.34);
  border-left-color: #57a6ff;
  background: rgba(21, 43, 69, 0.74);
}

:root[data-desktop-theme="dark"] .commitment-next.overdue {
  border-color: rgba(255, 124, 112, 0.36);
  border-left-color: #ff7c70;
  background: rgba(67, 31, 32, 0.66);
}

:root[data-desktop-theme="dark"] .commitment-metric strong,
:root[data-desktop-theme="dark"] .commitment-next-head strong,
:root[data-desktop-theme="dark"] .commitment-next-times strong,
:root[data-desktop-theme="dark"] .commitment-event-head strong {
  color: #e4edf8;
}

:root[data-desktop-theme="dark"] .commitment-next-action,
:root[data-desktop-theme="dark"] .commitment-next blockquote,
:root[data-desktop-theme="dark"] .commitment-event p,
:root[data-desktop-theme="dark"] .commitment-event-meta {
  color: #b5c3d4;
}

@media (prefers-reduced-motion: reduce) {
  .collector-nav-status.is-running .collector-nav-status-dot {
    animation: none !important;
  }

  .desktop-navigation-pending .desktop-shell::after {
    animation: none !important;
    transform: scaleX(0.45);
  }

  .desktop-shell,
  .desktop-sidebar-toggle,
  .new-analysis-arrival-notice,
  .new-analysis-arrival-action,
  .new-analysis-arrival-close {
    transition: none !important;
  }

  .desktop-review-modal:not(.hidden),
  .desktop-review-modal:not(.hidden) .desktop-review-panel,
  .desktop-review-modal:not(.hidden) .desktop-full-review > .full-review-section,
  .desktop-review-modal:not(.hidden) .journey-hero,
  .desktop-review-modal:not(.hidden) .journey-stage,
  .desktop-review-modal:not(.hidden) .journey-detail-grid > .review-text-block,
  .desktop-review-modal:not(.hidden) .journey-event {
    animation: none !important;
  }

  .review-hero,
  .review-money-strip,
  .review-text-block,
  .metric-card,
  .review-native-panel,
  .full-review-card,
  .full-script-card,
  .journey-hero,
  .journey-stage,
  .journey-fact,
  .journey-event {
    transition: none !important;
  }

  .review-text-block:hover,
  .metric-card:hover,
  .full-review-card:hover,
  .full-script-card:hover,
  .journey-stage:hover,
  .journey-event:hover {
    transform: none !important;
  }
}

@media (max-width: 1180px) {
  body.desktop-page {
    overflow: auto;
  }

  .desktop-navigation-pending .desktop-shell::after {
    left: 0;
  }

  .desktop-shell {
    min-height: 100vh;
    height: auto;
    grid-template-columns: 1fr;
  }

  .desktop-sidebar-toggle {
    display: none;
  }

  .desktop-sidebar {
    grid-template-rows: auto;
    grid-template-columns: auto minmax(0, 1fr) auto;
    align-items: start;
  }

  .desktop-model-grid {
    grid-template-columns: 1fr;
  }

  .desktop-model-actions {
    justify-content: stretch;
    flex-wrap: wrap;
  }

  .desktop-model-actions .desktop-btn {
    flex: 1 1 120px;
  }

  .desktop-local-grid {
    grid-template-columns: 1fr;
  }

  .desktop-local-actions {
    justify-content: stretch;
    flex-wrap: wrap;
  }

  .desktop-local-actions .desktop-btn {
    flex: 1 1 140px;
  }

  .collector-toolbar {
    grid-template-columns: 1fr 1fr;
  }

  .collector-progress-panel,
  .collector-grid {
    grid-template-columns: 1fr;
  }

  .collector-detail-panel {
    min-height: 420px;
  }

  .collector-table {
    min-width: 900px;
  }

  .collector-table-scroll {
    overflow-x: auto;
  }

  .desktop-drill-modal,
  .desktop-review-modal {
    padding: 10px;
  }

  .desktop-drill-panel,
  .desktop-review-panel {
    width: calc(100vw - 20px);
    height: calc(100vh - 20px);
    border-radius: 14px;
  }

  .desktop-drill-head,
  .desktop-review-head {
    align-items: stretch;
    flex-direction: column;
  }

  .toolbar-filter-group {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .overdue-modal-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .overdue-modal-actions > div {
    justify-content: stretch;
  }

  .overdue-modal-actions .desktop-btn {
    flex: 1 1 210px;
  }

  .drill-customer-row {
    grid-template-columns: 1fr;
    align-items: start;
  }

  .drill-customer-row small {
    text-align: left;
  }

  .desktop-review-actions {
    justify-content: flex-end;
  }

  .queue-section {
    display: flex;
    flex-wrap: wrap;
  }

  .queue-section h2 {
    width: 100%;
  }

  .section-body {
    width: 100%;
  }

  .stage-queue-list {
    width: 100%;
  }

  .workbench-grid,
  .desktop-toolbar,
  .global-kpi-grid,
  .money-review-grid,
  .global-dashboard-grid,
  .distribution-grid,
  .review-two-col,
  .review-native-grid,
  .full-review-two-col,
  .full-battle-summary,
  .review-followup-grid {
    grid-template-columns: 1fr;
  }

  .customer-workbench-page .workbench-grid {
    grid-template-rows: auto auto auto;
    overflow: visible;
  }

  .customer-workbench-layout > .metric-strip,
  .customer-workbench-layout > .customer-list-panel,
  .customer-workbench-layout > .customer-detail-panel {
    grid-column: 1;
  }

  .customer-workbench-layout > .metric-strip {
    grid-row: 1;
  }

  .customer-workbench-layout > .customer-list-panel {
    grid-row: 2;
  }

  .customer-workbench-layout > .customer-detail-panel {
    grid-row: 3;
  }

  .review-info-grid,
  .review-money-strip,
  .journey-fact-grid,
  .journey-stage-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .journey-detail-grid {
    grid-template-columns: 1fr;
  }

  .full-review-card-grid,
  .full-next-grid,
  .full-script-grid {
    grid-template-columns: 1fr;
  }

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

  .commitment-event-list {
    grid-template-columns: 1fr;
  }

  .ledger-metric-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .ledger-content-grid {
    grid-template-columns: 1fr;
  }

  .ledger-repurchase-panel {
    grid-template-columns: 1fr;
  }

  .full-battle-main,
  .battle-platform-row,
  .full-review-section-head,
  .review-followup-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .battle-platform-row > div {
    justify-content: flex-start;
  }

  .battle-platform-text {
    text-align: left;
  }

  .full-review-section-head span {
    text-align: left;
  }

  .review-customer-title {
    display: grid;
  }

  .review-customer-badges {
    justify-content: flex-start;
    max-width: none;
  }

  .review-history-row {
    grid-template-columns: 1fr;
    gap: 4px;
  }

  .desktop-dashboard-main,
  .global-dashboard-grid,
  .settings-layout {
    grid-template-rows: auto;
  }

  .settings-layout {
    grid-template-columns: 1fr;
    overflow: auto;
  }

  .settings-column {
    overflow: visible;
  }

  .customer-detail-panel {
    min-height: 520px;
  }
}

@media (min-width: 1140px) and (max-width: 1180px) {
  body.customer-workbench-page {
    overflow: hidden;
  }

  .customer-workbench-page .desktop-shell {
    min-height: 0;
    height: 100vh;
    grid-template-columns: 176px minmax(0, 1fr);
  }

  .customer-workbench-page .desktop-sidebar {
    align-items: stretch;
    overflow-y: auto;
  }

  .customer-workbench-page .workbench-grid {
    grid-template-columns: minmax(620px, 1fr) minmax(300px, 330px);
    grid-template-rows: auto minmax(0, 1fr);
    overflow: hidden;
  }

  .customer-workbench-page .customer-workbench-layout > .metric-strip {
    grid-column: 1;
    grid-row: 1;
  }

  .customer-workbench-page .customer-workbench-layout > .customer-list-panel {
    grid-column: 1;
    grid-row: 2;
  }

  .customer-workbench-page .customer-workbench-layout > .customer-detail-panel {
    grid-column: 2;
    grid-row: 1 / span 2;
    min-height: 0;
  }
}

/* Desktop enterprise knowledge base */
:root[data-desktop-knowledge-embedded="true"] .desktop-window-drag-region,
:root[data-desktop-knowledge-embedded="true"] .desktop-sidebar,
:root[data-desktop-knowledge-embedded="true"] [data-sidebar-toggle] {
  display: none !important;
}

:root[data-desktop-knowledge-embedded="true"] .desktop-shell {
  grid-template-columns: minmax(0, 1fr);
}

:root[data-desktop-knowledge-embedded="true"] .desktop-main {
  padding-left: 20px;
}

.desktop-knowledge-compat-page .desktop-settings-main {
  display: block;
  min-height: 0;
  overflow: hidden;
  padding: 0;
}

.desktop-knowledge-compat-page .desktop-main {
  position: relative;
}

.desktop-knowledge-compat-host {
  position: absolute;
  z-index: 10;
  inset: 0;
  overflow: hidden;
  background: var(--desktop-bg);
}

.desktop-knowledge-compat-frame {
  display: block;
  width: 100%;
  height: 100%;
  border: 0;
  background: var(--desktop-bg);
}

.desktop-knowledge-main {
  grid-template-rows: auto minmax(0, 1fr);
  overflow: hidden;
}

.desktop-knowledge-workspace {
  min-width: 0;
  min-height: 0;
  display: grid;
  grid-auto-rows: max-content;
  align-content: start;
  gap: 12px;
  overflow-y: auto;
  padding: 2px 3px 12px 0;
  scrollbar-color: rgba(100, 116, 139, 0.3) transparent;
  scrollbar-width: thin;
}

.desktop-knowledge-workspace::-webkit-scrollbar {
  width: 8px;
}

.desktop-knowledge-workspace::-webkit-scrollbar-thumb {
  border: 2px solid transparent;
  border-radius: 999px;
  background: rgba(100, 116, 139, 0.28);
  background-clip: content-box;
}

.knowledge-panel {
  min-width: 0;
  overflow: hidden;
  border: 1px solid var(--desktop-border);
  border-radius: 14px;
  background: var(--desktop-surface);
  box-shadow: var(--desktop-shadow-soft);
  backdrop-filter: var(--desktop-blur);
}

.knowledge-panel-head {
  min-height: 62px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border-bottom: 1px solid var(--desktop-border);
  padding: 10px 12px;
}

.knowledge-panel-head > div:first-child {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 10px;
}

.knowledge-panel-icon {
  width: 34px;
  height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  border: 1px solid rgba(10, 132, 255, 0.18);
  border-radius: 9px;
  background: var(--desktop-primary-soft);
  color: var(--desktop-primary-strong);
}

.knowledge-panel-icon .sidebar-icon {
  width: 17px;
  height: 17px;
  color: currentColor;
}

.knowledge-panel-head h2,
.knowledge-panel-head p {
  margin: 0;
}

.knowledge-panel-head h2 {
  color: var(--desktop-text);
  font-size: 15px;
  font-weight: 820;
  line-height: 1.3;
}

.knowledge-panel-head p {
  margin-top: 2px;
  color: var(--desktop-muted);
  font-size: 11.5px;
  font-weight: 650;
  line-height: 1.45;
}

.knowledge-toolbar,
.desktop-knowledge-page .inline-actions {
  min-width: 0;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 7px;
}

.knowledge-toolbar .compact-input {
  width: auto;
  min-width: 116px;
}

.knowledge-search-box {
  min-width: 220px;
  display: flex;
  align-items: center;
  gap: 6px;
  border: 1px solid rgba(104, 126, 155, 0.24);
  border-radius: 12px;
  padding: 0 10px;
  background: rgba(255, 255, 255, 0.74);
  transition: border-color 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
}

.knowledge-search-box:focus-within {
  border-color: rgba(10, 132, 255, 0.42);
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 0 0 3px rgba(10, 132, 255, 0.1);
}

.knowledge-search-box .sidebar-icon {
  width: 15px;
  height: 15px;
  color: var(--desktop-muted);
}

.knowledge-search-box .desktop-input {
  height: 36px;
  border: 0;
  padding: 0;
  background: transparent;
  box-shadow: none;
}

.knowledge-search-box .desktop-input:focus {
  background: transparent;
  box-shadow: none;
}

.knowledge-summary,
.desktop-knowledge-page .summary {
  min-height: 0;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  padding: 8px 12px 0;
  color: var(--desktop-muted);
  font-size: 12px;
  font-weight: 700;
}

.desktop-knowledge-page .summary:empty {
  display: none;
}

.desktop-knowledge-page .pill,
.desktop-knowledge-page .badge {
  min-height: 25px;
  display: inline-flex;
  align-items: center;
  border: 1px solid rgba(104, 126, 155, 0.2);
  border-radius: 999px;
  padding: 4px 8px;
  background: rgba(255, 255, 255, 0.68);
  color: #41546d;
  font-size: 11px;
  font-weight: 780;
  white-space: nowrap;
}

.desktop-knowledge-page .header-status .badge {
  min-height: 34px;
  padding: 7px 11px;
}

.desktop-knowledge-page .pill.ok,
.desktop-knowledge-page .badge.ok {
  border-color: rgba(48, 164, 108, 0.24);
  background: rgba(48, 164, 108, 0.1);
  color: #157347;
}

.desktop-knowledge-page .pill.warn,
.desktop-knowledge-page .badge.warn {
  border-color: rgba(255, 159, 10, 0.28);
  background: rgba(255, 159, 10, 0.1);
  color: #8a5100;
}

.desktop-knowledge-page .pill.fail,
.desktop-knowledge-page .badge.fail {
  border-color: rgba(255, 59, 48, 0.22);
  background: rgba(255, 59, 48, 0.1);
  color: #b42318;
}

.desktop-knowledge-page .pill.engine {
  border-color: rgba(10, 132, 255, 0.2);
  background: rgba(10, 132, 255, 0.1);
  color: #0057b8;
}

.desktop-knowledge-table-scroll {
  min-width: 0;
  overflow: auto;
  max-height: 390px;
  margin-top: 8px;
  border-top: 1px solid var(--desktop-border);
}

.knowledge-suggestion-scroll {
  max-height: 340px;
}

.desktop-knowledge-table {
  width: 100%;
  min-width: 980px;
  border-collapse: separate;
  border-spacing: 0;
  table-layout: fixed;
}

.desktop-knowledge-table th,
.desktop-knowledge-table td {
  border-bottom: 1px solid rgba(130, 152, 179, 0.16);
  padding: 10px 11px;
  text-align: left;
  vertical-align: top;
}

.desktop-knowledge-table th {
  position: sticky;
  top: 0;
  z-index: 2;
  background: rgba(245, 249, 253, 0.96);
  color: #5a6b82;
  font-size: 10.5px;
  font-weight: 820;
  text-transform: uppercase;
}

.desktop-knowledge-table td {
  color: #2a3a50;
  font-size: 12px;
  line-height: 1.5;
}

.desktop-knowledge-table tbody tr:last-child td {
  border-bottom: 0;
}

.desktop-knowledge-table tbody tr:hover td {
  background: rgba(10, 132, 255, 0.035);
}

.desktop-knowledge-table th:nth-child(1),
.desktop-knowledge-table td:nth-child(1) {
  width: 30%;
}

.desktop-knowledge-table th:nth-child(2),
.desktop-knowledge-table td:nth-child(2) {
  width: 18%;
}

.desktop-knowledge-table th:nth-child(3),
.desktop-knowledge-table td:nth-child(3) {
  width: 12%;
}

.desktop-knowledge-table th:nth-child(4),
.desktop-knowledge-table td:nth-child(4) {
  width: 10%;
}

.desktop-knowledge-table th:nth-child(5),
.desktop-knowledge-table td:nth-child(5) {
  width: 13%;
}

.desktop-knowledge-table th:nth-child(6),
.desktop-knowledge-table td:nth-child(6) {
  width: 17%;
}

.platform-cell-main,
.platform-cell-data,
.platform-cell-center,
.platform-cell-time {
  min-width: 0;
}

.platform-cell-main strong,
.platform-cell-main span,
.platform-cell-data span,
.platform-cell-center span,
.platform-cell-time span {
  display: block;
}

.platform-cell-main strong {
  margin-bottom: 4px;
  color: var(--desktop-text);
  font-size: 12.5px;
  font-weight: 800;
}

.platform-cell-main .hint-text {
  display: -webkit-box;
  overflow: hidden;
  color: var(--desktop-muted);
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
}

.platform-cell-data > * + *,
.platform-cell-center > * + *,
.platform-cell-time > * + * {
  margin-top: 4px;
}

.platform-cell-actions .platform-actions {
  justify-content: flex-start;
  flex-wrap: wrap;
}

.knowledge-loading-cell {
  height: 82px;
  color: var(--desktop-muted) !important;
  text-align: center !important;
  vertical-align: middle !important;
}

.desktop-knowledge-page .btn:not(.desktop-btn) {
  min-height: 30px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(104, 126, 155, 0.26);
  border-radius: 9px;
  padding: 5px 9px;
  background: rgba(255, 255, 255, 0.7);
  color: #334155;
  cursor: pointer;
  font-size: 11.5px;
  font-weight: 760;
}

.desktop-knowledge-page .btn.primary:not(.desktop-btn) {
  border-color: transparent;
  background: var(--desktop-primary);
  color: #ffffff;
}

.desktop-knowledge-page .btn.danger-ghost:not(.desktop-btn) {
  border-color: rgba(255, 59, 48, 0.2);
  color: #b42318;
}

.desktop-knowledge-page .btn:disabled {
  cursor: not-allowed;
  opacity: 0.48;
}

.knowledge-editor-panel,
.knowledge-taxonomy-panel {
  overflow: visible;
}

.knowledge-writing-guide {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 12px 12px 0;
  border: 1px solid rgba(10, 132, 255, 0.16);
  border-radius: 10px;
  padding: 9px 11px;
  background: rgba(10, 132, 255, 0.055);
  color: #31506f;
  font-size: 11.5px;
  font-weight: 700;
}

.knowledge-writing-guide strong {
  color: #0057b8;
}

.knowledge-writing-guide i {
  width: 14px;
  height: 1px;
  background: rgba(10, 132, 255, 0.3);
}

.knowledge-form,
.knowledge-suggestion-edit-form {
  display: grid;
  gap: 12px;
  padding: 12px;
}

.knowledge-quick-grid,
.knowledge-advanced-grid,
.knowledge-suggestion-edit-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 11px;
}

.desktop-knowledge-page .field-control {
  min-width: 0;
  display: grid;
  align-content: start;
  gap: 5px;
}

.desktop-knowledge-page .field-control > span {
  color: #40536b;
  font-size: 11.5px;
  font-weight: 790;
}

.desktop-knowledge-page .field-control > small {
  color: var(--desktop-muted);
  font-size: 10.5px;
  font-weight: 620;
  line-height: 1.45;
}

.knowledge-content-control,
.knowledge-wide-control {
  grid-column: 1 / -1;
}

.desktop-knowledge-page textarea.desktop-input {
  height: auto;
  min-height: 94px;
  padding: 10px 11px;
  line-height: 1.6;
  resize: vertical;
}

.desktop-knowledge-page .manual-details {
  overflow: hidden;
  border: 1px solid var(--desktop-border);
  border-radius: 11px;
  background: var(--desktop-surface-soft);
}

.desktop-knowledge-page .manual-details > summary {
  min-height: 40px;
  display: flex;
  align-items: center;
  padding: 8px 11px;
  color: #40536b;
  cursor: pointer;
  font-size: 12px;
  font-weight: 780;
}

.desktop-knowledge-page .manual-details > summary:focus-visible {
  outline: 3px solid rgba(10, 132, 255, 0.18);
  outline-offset: -3px;
}

.desktop-knowledge-page .manual-body {
  border-top: 1px solid var(--desktop-border);
  padding: 11px;
}

#knowledgeFormSummary {
  padding: 0 12px 12px;
}

.knowledge-taxonomy-manager {
  display: grid;
  gap: 12px;
  padding: 12px;
}

.taxonomy-manager-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.taxonomy-manager-heading > div {
  min-width: 0;
  display: grid;
  gap: 2px;
}

.taxonomy-manager-heading strong {
  color: var(--desktop-text);
  font-size: 13px;
  font-weight: 820;
}

.taxonomy-manager-heading span,
.taxonomy-editor-footer p {
  margin: 0;
  color: var(--desktop-muted);
  font-size: 11px;
  font-weight: 650;
  line-height: 1.5;
}

.taxonomy-count-text,
.taxonomy-save-state {
  min-height: 28px;
  display: inline-flex;
  align-items: center;
  flex: 0 0 auto;
  border: 1px solid var(--desktop-border);
  border-radius: 999px;
  padding: 4px 9px;
  background: var(--desktop-surface-soft);
  color: var(--desktop-muted);
  font-size: 10.5px;
  font-weight: 780;
  white-space: nowrap;
}

.taxonomy-save-state[data-state="saved"] {
  border-color: rgba(48, 164, 108, 0.24);
  background: rgba(48, 164, 108, 0.1);
  color: #157347;
}

.taxonomy-save-state[data-state="dirty"] {
  border-color: rgba(255, 159, 10, 0.28);
  background: rgba(255, 159, 10, 0.1);
  color: #8a5100;
}

.taxonomy-header-actions {
  flex-wrap: wrap;
}

.taxonomy-chip-list {
  min-height: 44px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}

.taxonomy-chip {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: 1px solid var(--desktop-border);
  border-radius: 8px;
  padding: 7px 10px;
  background: var(--desktop-surface-strong);
  color: var(--desktop-text);
  cursor: pointer;
  font: inherit;
  text-align: left;
  transition: border-color 0.18s ease, background 0.18s ease, box-shadow 0.18s ease;
}

.taxonomy-chip:hover {
  border-color: rgba(10, 132, 255, 0.36);
  background: var(--desktop-primary-soft);
}

.taxonomy-chip:focus-visible {
  outline: 3px solid rgba(10, 132, 255, 0.2);
  outline-offset: 2px;
}

.taxonomy-chip.is-selected {
  border-color: rgba(10, 132, 255, 0.44);
  background: var(--desktop-primary-soft);
  box-shadow: 0 0 0 1px rgba(10, 132, 255, 0.08) inset;
}

.taxonomy-chip-name,
.taxonomy-chip-meta {
  display: block;
  white-space: nowrap;
}

.taxonomy-chip-name {
  color: inherit;
  font-size: 11.5px;
  font-weight: 800;
}

.taxonomy-chip.is-selected .taxonomy-chip-name,
.taxonomy-more-chip {
  color: var(--desktop-primary-strong);
}

.taxonomy-chip-meta {
  color: var(--desktop-muted);
  font-size: 10px;
  font-weight: 680;
}

.taxonomy-more-chip {
  justify-content: center;
  min-width: 82px;
  font-size: 11.5px;
  font-weight: 800;
}

.taxonomy-empty-state {
  width: 100%;
  min-height: 72px;
  display: grid;
  place-content: center;
  gap: 4px;
  border: 1px dashed var(--desktop-border-strong);
  border-radius: 8px;
  color: var(--desktop-muted);
  text-align: center;
}

.taxonomy-empty-state strong {
  color: var(--desktop-text);
  font-size: 12px;
}

.taxonomy-empty-state span {
  font-size: 11px;
}

.taxonomy-editor {
  display: grid;
  gap: 11px;
  border: 1px solid var(--desktop-border);
  border-radius: 8px;
  padding: 12px;
  background: var(--desktop-surface-soft);
}

.taxonomy-editor-fields {
  display: grid;
  grid-template-columns: minmax(180px, 0.36fr) minmax(0, 1fr);
  gap: 11px;
}

.taxonomy-editor-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.taxonomy-editor-footer p {
  max-width: 680px;
}

.taxonomy-editor-actions,
.taxonomy-bulk-actions {
  flex: 0 0 auto;
}

.taxonomy-delete-btn:not(:disabled) {
  border-color: rgba(255, 59, 48, 0.22);
  color: #b42318;
}

.taxonomy-bulk-body {
  display: grid;
  gap: 11px;
}

.taxonomy-bulk-body .knowledge-taxonomy-format {
  margin: 0;
}

.taxonomy-bulk-actions {
  justify-content: flex-start !important;
}

.knowledge-taxonomy-format {
  display: grid;
  grid-template-columns: minmax(320px, auto) minmax(0, 1fr);
  align-items: center;
  gap: 12px;
  margin: 12px;
  border: 1px solid var(--desktop-border);
  border-radius: 10px;
  padding: 10px 11px;
  background: var(--desktop-surface-soft);
}

.knowledge-taxonomy-format code {
  overflow: hidden;
  color: #0057b8;
  font-size: 11.5px;
  font-weight: 760;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.knowledge-taxonomy-format span {
  color: var(--desktop-muted);
  font-size: 11px;
  line-height: 1.5;
}

.knowledge-taxonomy-details {
  margin: 0 12px 12px;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-desktop-theme="light"]) .taxonomy-save-state[data-state="saved"] {
    color: #71d7a5;
  }

  :root:not([data-desktop-theme="light"]) .taxonomy-save-state[data-state="dirty"] {
    color: #ffc264;
  }

  :root:not([data-desktop-theme="light"]) .taxonomy-delete-btn:not(:disabled) {
    color: #ff8a82;
  }
}

:root[data-desktop-theme="dark"] .taxonomy-save-state[data-state="saved"] {
  color: #71d7a5;
}

:root[data-desktop-theme="dark"] .taxonomy-save-state[data-state="dirty"] {
  color: #ffc264;
}

:root[data-desktop-theme="dark"] .taxonomy-delete-btn:not(:disabled) {
  color: #ff8a82;
}

.desktop-knowledge-page .modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 120;
  display: grid;
  place-items: center;
  padding: 18px;
  background: rgba(15, 23, 42, 0.52);
  backdrop-filter: blur(10px);
}

.knowledge-suggestion-modal-panel {
  width: min(920px, calc(100vw - 36px));
  max-height: calc(100vh - 36px);
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  overflow: hidden;
  border: 1px solid var(--desktop-border-strong);
  border-radius: 14px;
  background: var(--desktop-surface-strong);
  box-shadow: 0 24px 70px rgba(15, 23, 42, 0.28);
}

.desktop-knowledge-page .modal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border-bottom: 1px solid var(--desktop-border);
  padding: 12px 14px;
}

.modal-head-left p,
.modal-head-left h2,
.modal-head-left span {
  margin: 0;
}

.modal-head-left p {
  color: var(--desktop-primary-strong);
  font-size: 10px;
  font-weight: 820;
  text-transform: uppercase;
}

.modal-head-left h2 {
  margin-top: 2px;
  color: var(--desktop-text);
  font-size: 17px;
  font-weight: 820;
}

.modal-head-left span {
  display: block;
  margin-top: 3px;
  color: var(--desktop-muted);
  font-size: 11px;
}

.knowledge-suggestion-edit-form {
  overflow-y: auto;
  padding: 14px;
}

.knowledge-suggestion-modal-actions {
  position: sticky;
  bottom: -14px;
  margin: 0 -14px -14px;
  border-top: 1px solid var(--desktop-border);
  padding: 10px 14px;
  background: var(--desktop-surface-strong);
}

.desktop-knowledge-page .plan-lock-card {
  min-height: 260px;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 18px;
  border: 1px solid var(--desktop-border);
  border-radius: 14px;
  padding: 22px;
  background: var(--desktop-surface);
  box-shadow: var(--desktop-shadow-soft);
}

.desktop-knowledge-page .plan-lock-mark {
  border-radius: 8px;
  padding: 8px 10px;
  background: var(--desktop-primary-soft);
  color: var(--desktop-primary-strong);
  font-size: 12px;
  font-weight: 850;
}

.desktop-knowledge-page .plan-lock-copy h3,
.desktop-knowledge-page .plan-lock-copy p,
.desktop-knowledge-page .plan-lock-copy span {
  margin: 0;
}

.desktop-knowledge-page .plan-lock-copy h3 {
  margin: 5px 0;
  color: var(--desktop-text);
  font-size: 19px;
}

.desktop-knowledge-page .plan-lock-copy p,
.desktop-knowledge-page .plan-lock-copy span {
  color: var(--desktop-muted);
  line-height: 1.6;
}

.desktop-knowledge-page .plan-lock-actions {
  display: flex;
  gap: 8px;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-desktop-theme="light"]) .knowledge-panel,
  :root:not([data-desktop-theme="light"]) .knowledge-suggestion-modal-panel,
  :root:not([data-desktop-theme="light"]) .desktop-knowledge-page .plan-lock-card {
    border-color: var(--desktop-border);
    background: var(--desktop-surface);
    box-shadow: var(--desktop-shadow-soft);
  }

  :root:not([data-desktop-theme="light"]) .desktop-knowledge-table th,
  :root:not([data-desktop-theme="light"]) .knowledge-suggestion-modal-actions {
    background: rgba(22, 30, 42, 0.96);
  }

  :root:not([data-desktop-theme="light"]) .knowledge-search-box,
  :root:not([data-desktop-theme="light"]) .desktop-knowledge-page .btn:not(.desktop-btn),
  :root:not([data-desktop-theme="light"]) .desktop-knowledge-page .pill,
  :root:not([data-desktop-theme="light"]) .desktop-knowledge-page .badge {
    border-color: rgba(148, 163, 184, 0.2);
    background: rgba(255, 255, 255, 0.06);
    color: #d8e2ef;
  }

  :root:not([data-desktop-theme="light"]) .knowledge-panel-head h2,
  :root:not([data-desktop-theme="light"]) .platform-cell-main strong,
  :root:not([data-desktop-theme="light"]) .modal-head-left h2,
  :root:not([data-desktop-theme="light"]) .desktop-knowledge-page .plan-lock-copy h3 {
    color: var(--desktop-text);
  }

  :root:not([data-desktop-theme="light"]) .knowledge-panel-head p,
  :root:not([data-desktop-theme="light"]) .desktop-knowledge-table td,
  :root:not([data-desktop-theme="light"]) .platform-cell-main .hint-text,
  :root:not([data-desktop-theme="light"]) .desktop-knowledge-page .field-control > span,
  :root:not([data-desktop-theme="light"]) .desktop-knowledge-page .field-control > small,
  :root:not([data-desktop-theme="light"]) .knowledge-taxonomy-format span {
    color: var(--desktop-muted);
  }

  :root:not([data-desktop-theme="light"]) .desktop-knowledge-table tbody tr:hover td {
    background: rgba(10, 132, 255, 0.08);
  }
}

:root[data-desktop-theme="dark"] .knowledge-panel,
:root[data-desktop-theme="dark"] .knowledge-suggestion-modal-panel,
:root[data-desktop-theme="dark"] .desktop-knowledge-page .plan-lock-card {
  border-color: var(--desktop-border);
  background: var(--desktop-surface);
  box-shadow: var(--desktop-shadow-soft);
}

:root[data-desktop-theme="dark"] .desktop-knowledge-table th,
:root[data-desktop-theme="dark"] .knowledge-suggestion-modal-actions {
  background: rgba(22, 30, 42, 0.96);
}

:root[data-desktop-theme="dark"] .knowledge-search-box,
:root[data-desktop-theme="dark"] .desktop-knowledge-page .btn:not(.desktop-btn),
:root[data-desktop-theme="dark"] .desktop-knowledge-page .pill,
:root[data-desktop-theme="dark"] .desktop-knowledge-page .badge {
  border-color: rgba(148, 163, 184, 0.2);
  background: rgba(255, 255, 255, 0.06);
  color: #d8e2ef;
}

:root[data-desktop-theme="dark"] .knowledge-panel-head h2,
:root[data-desktop-theme="dark"] .platform-cell-main strong,
:root[data-desktop-theme="dark"] .modal-head-left h2,
:root[data-desktop-theme="dark"] .desktop-knowledge-page .plan-lock-copy h3 {
  color: var(--desktop-text);
}

:root[data-desktop-theme="dark"] .knowledge-panel-head p,
:root[data-desktop-theme="dark"] .desktop-knowledge-table td,
:root[data-desktop-theme="dark"] .platform-cell-main .hint-text,
:root[data-desktop-theme="dark"] .desktop-knowledge-page .field-control > span,
:root[data-desktop-theme="dark"] .desktop-knowledge-page .field-control > small,
:root[data-desktop-theme="dark"] .knowledge-taxonomy-format span {
  color: var(--desktop-muted);
}

@media (max-width: 1280px) {
  .knowledge-panel-head {
    align-items: flex-start;
    flex-direction: column;
  }

  .knowledge-toolbar {
    width: 100%;
    justify-content: flex-start;
  }

  .knowledge-search-box {
    flex: 1 1 260px;
  }
}

@media (max-width: 1180px) {
  .desktop-knowledge-main {
    overflow: visible;
  }

  .desktop-knowledge-workspace {
    overflow: visible;
  }

  .knowledge-quick-grid,
  .knowledge-advanced-grid,
  .knowledge-suggestion-edit-grid,
  .taxonomy-editor-fields {
    grid-template-columns: 1fr;
  }

  .knowledge-content-control,
  .knowledge-wide-control {
    grid-column: auto;
  }

  .knowledge-taxonomy-format,
  .desktop-knowledge-page .plan-lock-card {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 760px) {
  .customer-analysis-summary,
  .customer-analysis-detail {
    grid-template-columns: 1fr;
  }

  .metric-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-template-rows: none;
  }

  .metric-card:nth-child(even) .metric-help-bubble {
    right: 0;
    left: auto;
  }

  .taxonomy-manager-heading,
  .taxonomy-editor-footer {
    align-items: stretch;
    flex-direction: column;
  }

  .knowledge-toolbar,
  .desktop-knowledge-page .inline-actions,
  .desktop-knowledge-page .plan-lock-actions {
    width: 100%;
    align-items: stretch;
    flex-direction: column;
  }

  .knowledge-toolbar .compact-input,
  .knowledge-search-box,
  .knowledge-toolbar .desktop-btn,
  .desktop-knowledge-page .inline-actions .desktop-btn {
    width: 100%;
  }

  .knowledge-writing-guide {
    align-items: flex-start;
    flex-direction: column;
  }

  .knowledge-writing-guide i {
    width: 1px;
    height: 8px;
  }

  .desktop-knowledge-page .modal-overlay {
    padding: 8px;
  }

  .knowledge-suggestion-modal-panel {
    width: calc(100vw - 16px);
    max-height: calc(100vh - 16px);
  }
}
