/* Approved Explore quick-adjustments composition. Canonical chart/export sizes
   and the legacy rollback surface retain their existing owners. */
#editor-workspace-root [hidden] { display: none !important; }
/* Compact controls share the same order in Explore and Create post. */
#editor-workspace-root .sp-editor-status-quiet { position: absolute; width: 1px; height: 1px; padding: 0; overflow: hidden; clip-path: inset(50%); }
#editor-workspace-root .sp-editor-status-error { padding: 8px 0; color: var(--sp-text); }
#editor-workspace-root :is(#editor-edit-data, #editor-data-link) { display: none !important; }
body:where([data-sp-has~="explore-enter"]):not(#sp-s) #editor-workspace-root[data-chrome='explore'] .sp-editor-entry-actions { display: none; }
body:where([data-sp-has~="explore-filters"]):not(#sp-s) #editor-workspace-root[data-origin='explore'] #editor-open-data { display: none; }
#editor-workspace-root .sp-editor-view-toolbar { flex: none; display: flex; flex-direction: column; align-items: stretch; gap: 8px; padding: 0; margin: 0 0 12px; background: none; border: 0; }
#editor-workspace-root .sp-editor-edit-tools { order: 2; display: flex; align-items: center; flex-wrap: nowrap; gap: 4px; padding: 0; margin: 0; }
#editor-workspace-root[data-mode='browse'] .sp-editor-edit-tools { display: none; }
#editor-workspace-root[data-mode='browse'] .sp-editor-columns { grid-template-columns: minmax(0,1fr); }
#editor-workspace-root .sp-editor-edit-tools > button { height: 44px; min-height: 44px; border-radius: 8px; }
#editor-workspace-root :is(#editor-undo,#editor-redo,#editor-save,#editor-open-data) { position: relative; width: 44px; padding: 0; flex: 0 0 44px; margin: 0; background: transparent; border-color: transparent; color: var(--sp-text); font-size: 0; }
#editor-workspace-root :is(#editor-undo,#editor-redo,#editor-save,#editor-open-data):hover:not(:disabled) { background: var(--sp-surface); }
#editor-workspace-root #editor-save[data-unsaved='true']::after { content: ''; position: absolute; width: 5px; height: 5px; border-radius: 50%; right: 7px; top: 8px; background: var(--sp-accent); }
#editor-workspace-root #editor-open-export { margin-left: auto; padding: 8px 16px; background: var(--sp-accent); border-color: var(--sp-accent); color: var(--sp-on-accent); font: 500 13px/20px var(--sp-font-ui); }
#editor-workspace-root #editor-open-export::before { display: none; }
#editor-workspace-root #editor-open-export:hover { background: var(--sp-accent-hover); }
.sp-editor-history-label { display: none; }
#editor-workspace-root .sp-editor-format-tools { order: 1; display: grid; grid-template-columns: minmax(0,1.1fr) minmax(0,.8fr) minmax(0,1.2fr); gap: 8px; min-width: 0; }
#editor-workspace-root #editor-open-filters { display: none; }
.sp-editor-format-tools > div, .sp-editor-format-tools [class*='Input-wrapper'] { width: 100%; min-width: 0; }
.sp-editor-format-tools label:not(.mantine-SegmentedControl-label) { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
#editor-workspace-root .sp-editor-format-tools input:not([type='radio']) { height: 40px; min-height: 40px; font: 400 13px/20px var(--sp-font-ui); padding-left: 10px; padding-right: 26px; background: var(--sp-surface); border-color: var(--sp-border-strong); border-radius: 8px; text-overflow: ellipsis; }
#editor-workspace-root .sp-editor-orientation { display: none; }
#editor-workspace-root[data-chrome='explore'] .sp-editor-format-select { display: none; }
#editor-workspace-root[data-chrome='explore'] .sp-editor-orientation {
  display: flex; height: 44px; padding: 3px; gap: 2px; box-sizing: border-box;
  border: 1px solid var(--sp-border-strong) !important; border-radius: 8px !important; background: var(--sp-surface) !important;
}
#editor-workspace-root .sp-editor-orientation .mantine-SegmentedControl-control { flex: 1; border: 0; }
#editor-workspace-root .sp-editor-orientation .mantine-SegmentedControl-label {
  display: flex; align-items: center; justify-content: center; height: 100%; padding: 0 10px;
  border-radius: 5px; color: var(--sp-text-2) !important; font: 500 13px/20px var(--sp-font-ui) !important;
}
/* Override the legacy Studio lime selection with Explore's neutral selection. */
#editor-workspace-root .sp-editor-orientation .mantine-SegmentedControl-indicator { background: var(--sp-selected-bg) !important; box-shadow: none !important; border-radius: 5px !important; }
#editor-workspace-root .sp-editor-orientation .mantine-SegmentedControl-control[data-active] .mantine-SegmentedControl-label { color: var(--sp-selected-text) !important; }
#editor-workspace-root .sp-editor-orientation .mantine-SegmentedControl-label:hover:not([data-active]):not([data-disabled]) { color: var(--sp-text) !important; }
#editor-workspace-root .sp-editor-orientation .mantine-SegmentedControl-label[data-disabled] { opacity: .5; cursor: default; }
#editor-workspace-root .sp-editor-orientation input:focus-visible + label { outline: 2px solid var(--sp-accent); outline-offset: -2px; }
.sp-orientation-option { display: inline-flex; align-items: center; justify-content: center; gap: 8px; }
.sp-orientation-icon { display: block; flex: none; box-sizing: border-box; border: 1.5px solid currentColor; border-radius: 2px; }
.sp-orientation-icon--desktop { width: 22px; height: 14px; }
.sp-orientation-icon--story { width: 14px; height: 22px; }
.sp-editor-format-tools [class*='Input-section'][data-position='right'] { width: 25px; color: var(--sp-text-2); }
.sp-editor-values-control { position: relative; min-width: 0; }
.sp-editor-values-control > summary { list-style: none; display: flex; align-items: center; justify-content: space-between; gap: 5px; height: 40px; box-sizing: border-box; padding: 0 10px; border: 1px solid var(--sp-border-strong); border-radius: 8px; background: var(--sp-surface); font: 400 13px/20px var(--sp-font-ui); cursor: pointer; }
.sp-editor-values-control > summary::-webkit-details-marker { display: none; }
.sp-editor-values-control > summary::after { content: ''; width: 5px; height: 5px; border-right: 1.5px solid var(--sp-text-2); border-bottom: 1.5px solid var(--sp-text-2); transform: rotate(45deg); flex-shrink: 0; margin: -3px 1px 0; }
.sp-editor-values-options { position: absolute; z-index: 30; right: 0; top: calc(100% + 6px); width: 160px; display: grid; gap: 4px; padding: 5px; border: 1px solid var(--sp-border-strong); border-radius: 8px; background: var(--sp-surface); }
#editor-workspace-root .sp-editor-values-options button { min-height: 44px; padding: 8px 10px; border: 0; background: transparent; color: var(--sp-text-2); font: 400 13px var(--sp-font-ui); text-align: left; cursor: pointer; }
#editor-workspace-root .sp-editor-values-options button[aria-pressed='true'] { background: var(--sp-selected-bg); color: var(--sp-selected-text); }
#editor-workspace-root .sp-editor-values-options button:hover:not(:disabled) { background: var(--sp-chip); color: var(--sp-text); }
.sp-editor-grid-menu { position: relative; flex: 0 0 44px; }
.sp-editor-grid-menu > summary { display: flex; align-items: center; justify-content: center; width: 44px; height: 44px; padding: 0; font-size: 0; cursor: pointer; border-radius: 8px; list-style: none; }
.sp-editor-grid-menu > summary::-webkit-details-marker { display: none; }
.sp-editor-grid-menu[open] > summary, .sp-editor-grid-menu > summary:hover { background: var(--sp-surface); }
.sp-editor-grid-options { display: grid; gap: 12px; position: absolute; top: calc(100% + 8px); left: 0; z-index: 25; width: 200px; padding: 18px; border: 1px solid var(--sp-border-strong); background: var(--sp-surface); border-radius: 10px; box-shadow: 0 12px 30px rgb(0 0 0 / .2); }
.sp-editor-grid-options > label { font-size: 12px; }
#editor-workspace-root[data-mode='design'] .sp-editor-columns { grid-template-columns: minmax(0,1fr) var(--editor-panel-width); gap: 16px; }
#editor-workspace-root[data-mode='design'] #editor-tools { width: 100%; padding: 0; border: 1px solid var(--sp-border); border-radius: 10px; background: var(--sp-chrome); animation: none; }
#editor-workspace-root #editor-tool-content { padding: 0 12px 12px; scrollbar-width: thin; scrollbar-color: var(--sp-border-strong) transparent; }
#editor-workspace-root #editor-tool-content > :not(#editor-panel-text) { padding-top: 16px; }
#editor-workspace-root .sp-editor-tool-group { gap: 0; grid-template-columns: minmax(0,1fr); }
.sp-quick-group { border-bottom: 1px solid var(--sp-border); min-width: 0; scroll-margin-top: 140px; }
.sp-quick-group > summary { display: flex; align-items: center; gap: 8px; list-style: none; box-sizing: border-box; padding: 6px 0; min-height: 48px; cursor: pointer; }
.sp-quick-group > summary::-webkit-details-marker { display: none; }
.sp-quick-copy { display: flex; flex-direction: column; gap: 2px; flex: 1; min-width: 0; }
.sp-quick-label { font-size: 14px; font-weight: 600; line-height: 1.25; }
.sp-quick-summary { display: block; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; font-size: 12px; font-weight: 400; line-height: 16px; color: var(--sp-text-2); }
.sp-quick-chevron { width: 7px; height: 7px; border-right: 1.5px solid currentColor; border-bottom: 1.5px solid currentColor; transform: rotate(-45deg); margin: 0 3px; color: var(--sp-text-2); }
.sp-quick-group[open] > summary > .sp-quick-chevron { transform: rotate(45deg); }
.sp-quick-body { display: grid; grid-template-columns: minmax(0,1fr); gap: 8px; padding-bottom: 12px; }
#editor-workspace-root .sp-quick-body :is(input,textarea) { font-size: 14px; }
#editor-workspace-root .sp-quick-body input:not([type=checkbox]):not([type=radio]),
#editor-workspace-root .sp-quick-body textarea { min-height: 40px; background: var(--sp-bg); border-color: var(--sp-border-strong); }
#editor-workspace-root .sp-quick-body .sp-text-style { margin-top: 0; }
#editor-workspace-root .sp-quick-body .sp-text-style > summary { position: static; padding: 6px 0; min-height: 36px; box-sizing: border-box; color: var(--sp-text-2); font-size: 13px; }
#editor-workspace-root .sp-quick-body .sp-text-style-grid { display: grid; grid-template-columns: minmax(0,1fr) minmax(0,1fr); gap: 8px; padding-top: 8px; }
#editor-workspace-root .sp-quick-body .sp-text-style-field { min-width: 0; background: transparent; border: 0; }
.sp-quick-body .sp-text-style-field--family, .sp-quick-body .sp-text-style-field--align { grid-column: 1/-1; }
#editor-workspace-root .sp-quick-body .sp-inspector-option-title { font-size: 12px; font-weight: 400; color: var(--sp-text-2); }
#editor-workspace-root .sp-quick-body .sp-studio-row { padding: 0; display: grid; gap: 9px; border: 0; }
#editor-workspace-root .sp-quick-body .sp-ft-row--toggle { display: flex; justify-content: space-between; align-items: center; }
#editor-workspace-root .sp-quick-body .sp-studio-row-label { font-size: 13px; font-weight: 400; }
.sp-quick-axis { display: grid; gap: 8px; }
.sp-quick-axis + .sp-quick-axis { padding-top: 12px; border-top: 1px solid var(--sp-border); }
.sp-quick-axis h3 { margin: 0; font-size: 13px; font-weight: 600; }
#editor-workspace-root .sp-quick-body .sp-look-palette-swatches { display: flex; flex-wrap: wrap; height: auto; gap: 5px; background: transparent; }
#editor-workspace-root .sp-quick-body .sp-look-palette-swatches [class*='SegmentedControl-control'] { flex: 0 0 calc(25% - 5px); }
#editor-workspace-root .sp-quick-body .sp-look-palette-swatches [class*='SegmentedControl-label'] { padding: 9px 5px; font-size: 12px; }
#editor-workspace-root .sp-editor-settings-actions { padding: 12px 18px 16px; }
#editor-workspace-root #editor-back-settings { margin: 12px 18px; flex: none; }
#editor-workspace-root #editor-btn-apply-filters { margin: 8px 18px; flex: none; }
#editor-workspace-root #editor-btn-apply-filters:disabled { display: none; }
#editor-workspace-root :is(summary,button,input,textarea):focus-visible { outline: 2px solid var(--sp-accent); outline-offset: 3px; }
/* Original context stays visible. Duplicate pickers yield to the editor
   toolbar; Ranking restores the original view controls. */
.sp-data-return-post { display: none; }
.sp-data-view-stats { display: none; }
body:where([data-sp-has~="editor-design-visible"]):not(#sp-s):not(.sp-s):not(.sp-s) .sp-data-view-stats { display: block; padding: 8px 0; margin-bottom: 14px; color: var(--sp-text-2); background: transparent; border: 0; text-decoration: underline; text-underline-offset: 3px; font: inherit; cursor: pointer; }
body:where([data-sp-has~="editor-design-visible"]):not(#sp-s):not(.sp-s):not(.sp-s) .sp-data-return-post { display: block; width: 100%; min-height: 44px; padding: 10px 14px; margin-bottom: 16px; border: 1px solid var(--sp-border-strong); border-radius: 8px; color: var(--sp-text); background: var(--sp-surface); cursor: pointer; font: 600 14px var(--sp-font-ui); }
@media (max-width: 599px), (max-width: 767px) and (max-aspect-ratio: 10/13) {
  #editor-workspace-root[data-mode='design'] .sp-editor-columns { display: flex; flex-direction: column; gap: 12px; }
  #editor-workspace-root[data-mode='design'] #editor-tools { overflow: visible; }
  #editor-workspace-root #editor-tool-content { overflow: visible; }
  #editor-workspace-root .sp-quick-body :is(input,textarea) { font-size: 16px; }
  .sp-quick-label { font-size: 14px; }
  body:where([data-sp-has~="editor-design-visible"]):not(#sp-s):not(.sp-s):not(.sp-s) .sp-data-shell[data-panel-collapsed='true'] .sp-data-panel { display: none; }
  #editor-data-panel { scroll-margin-top: calc(var(--sp-header-h,58px) + 12px); }
  body:where([data-sp-has~="editor-design-visible"]):not(#sp-s):not(.sp-s):not(.sp-s) .sp-data-return-post { position: sticky; top: var(--sp-header-h,58px); z-index: 20; }
}
@media (prefers-reduced-motion:reduce) {
  #editor-workspace-root .sp-preview-workbench { transition: none; will-change: auto; }
}

/* Local stroke icons match the existing geometric controls and need no network request. */
#editor-workspace-root :is(#editor-undo,#editor-redo,#editor-open-data,#editor-save,#editor-open-export) { display: inline-flex; align-items: center; justify-content: center; gap: 7px; }
#editor-workspace-root :is(#editor-undo,#editor-redo,#editor-open-data,#editor-save,#editor-open-export)::before,
.sp-editor-grid-menu > summary::before { content: ''; width: 20px; height: 20px; flex: 0 0 20px; background: currentColor; mask: var(--editor-action-icon) center/contain no-repeat; }
#editor-undo { --editor-action-icon: url("data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20viewBox%3D%220%200%2024%2024%22%20fill%3D%22none%22%20stroke%3D%22black%22%20stroke-width%3D%221.7%22%20stroke-linecap%3D%22round%22%20stroke-linejoin%3D%22round%22%3E%3Cpath%20d%3D%22M9%2010%204%205m0%200%205-4M4%205h9a7%207%200%200%201%200%2014h-3%22%2F%3E%3C%2Fsvg%3E"); }
#editor-redo { --editor-action-icon: url("data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20viewBox%3D%220%200%2024%2024%22%20fill%3D%22none%22%20stroke%3D%22black%22%20stroke-width%3D%221.7%22%20stroke-linecap%3D%22round%22%20stroke-linejoin%3D%22round%22%3E%3Cpath%20d%3D%22m15%2010%205-5m0%200-5-4m5%204h-9a7%207%200%200%200%200%2014h3%22%2F%3E%3C%2Fsvg%3E"); }
#editor-open-data { --editor-action-icon: url("data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20viewBox%3D%220%200%2024%2024%22%20fill%3D%22none%22%20stroke%3D%22black%22%20stroke-width%3D%221.7%22%20stroke-linecap%3D%22round%22%20stroke-linejoin%3D%22round%22%3E%3Cpath%20d%3D%22M4%205h16v14H4zM4%2010h16M10%205v14%22%2F%3E%3C%2Fsvg%3E"); }
#editor-save, #cmp-workspace-save { --editor-action-icon: url("data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20viewBox%3D%220%200%2024%2024%22%20fill%3D%22none%22%20stroke%3D%22black%22%20stroke-width%3D%221.7%22%20stroke-linecap%3D%22round%22%20stroke-linejoin%3D%22round%22%3E%3Cpath%20d%3D%22M5%203h12l4%204v14H3V3h2Zm2%200v6h10V3M7%2021v-8h10v8%22%2F%3E%3C%2Fsvg%3E"); }
#editor-open-export, #cmp-workspace-export { --editor-action-icon: url("data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20viewBox%3D%220%200%2024%2024%22%20fill%3D%22none%22%20stroke%3D%22black%22%20stroke-width%3D%221.7%22%20stroke-linecap%3D%22round%22%20stroke-linejoin%3D%22round%22%3E%3Cpath%20d%3D%22M12%2015V3m-4%204%204-4%204%204M5%2012v8h14v-8%22%2F%3E%3C%2Fsvg%3E"); }
.sp-editor-grid-menu > summary { --editor-action-icon: url("data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20viewBox%3D%220%200%2024%2024%22%20fill%3D%22none%22%20stroke%3D%22black%22%20stroke-width%3D%221.7%22%20stroke-linecap%3D%22round%22%20stroke-linejoin%3D%22round%22%3E%3Cpath%20d%3D%22M4%204h16v16H4zM4%2012h16M12%204v16%22%2F%3E%3C%2Fsvg%3E"); }

/* One comparison entry point, in the same place in both modes. Ranking
   keeps its original controls when the timeline host is hidden. */
#compare-shell.sp-data-shell .cmp-filters-button .cmp-chart-icon { width: 24px; height: 24px; }
/* The retained chart workspace owns the quick-controls row. Its Filters
   button invokes cmp-filters, which still owns the comparison draft.
   Keep the header clear while that workspace is loading, too. */
#compare-shell.sp-data-shell:has(#editor-preview-loading:is([data-state='loading'], [data-state='error'])) .cmp-filters-button { display: none; }
#compare-shell.sp-data-shell:has(#editor-preview-loading:is([data-state='loading'], [data-state='error'])) :is(.cmp-title, .cmp-filter-summary),
body:where([data-sp-has~="editor-explore-visible"]):not(#sp-s):not(.sp-s):not(.sp-s) #compare-shell.sp-data-shell .cmp-title,
body:where([data-sp-has~="editor-explore-visible"]):not(#sp-s):not(.sp-s):not(.sp-s) #compare-shell.sp-data-shell .cmp-filter-summary { grid-column: 2 / -1; }
body:where([data-sp-has~="explore-filters"]):not(#sp-s) #editor-workspace-root[data-chrome='explore'] .sp-editor-format-tools { width: max-content; max-width: 100%; grid-template-columns: max-content 96px 248px max-content; align-items: center; }
body:where([data-sp-has~="explore-filters"]):not(#sp-s) #editor-workspace-root[data-chrome='explore'] #editor-open-filters {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  height: 44px; min-height: 44px; padding: 0 12px; margin: 0;
  border: 1px solid var(--sp-accent); border-radius: 8px;
  background: var(--sp-accent); color: var(--sp-on-accent);
  font: 600 13px/20px var(--sp-font-ui); white-space: nowrap; cursor: pointer;
}
body:where([data-sp-has~="explore-filters"]):not(#sp-s) #editor-workspace-root[data-chrome='explore'] #editor-open-filters:hover { background: var(--sp-accent-hover); border-color: var(--sp-accent-hover); }
.sp-editor-filter-icon { width: 16px; height: 16px; flex: 0 0 16px; background: currentColor; mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 6h16M4 12h16M4 18h16M8 3v6m8 0v6m-6 0v6'/%3E%3C/svg%3E") center/contain no-repeat; }
body:where([data-sp-has~="explore-filters"]):not(#sp-s) #editor-workspace-root[data-chrome='explore'] .sp-editor-format-tools input:not([type='radio']),
body:where([data-sp-has~="explore-filters"]):not(#sp-s) #editor-workspace-root[data-chrome='explore'] .sp-editor-values-control > summary { height: 44px; min-height: 44px; }
@media (max-width: 599px), (max-width: 767px) and (max-aspect-ratio: 10/13) {
  body:where([data-sp-has~="explore-filters"]):not(#sp-s) #editor-workspace-root[data-chrome='explore'] .sp-editor-format-tools { width: 100%; grid-template-columns: minmax(max-content,1fr) minmax(96px,1fr) 96px max-content; }
  .sp-orientation-text { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
  #editor-workspace-root .sp-editor-orientation .mantine-SegmentedControl-label { padding-inline: 0; }
}
@media (max-width: 479px) {
  body:where([data-sp-has~="explore-filters"]):not(#sp-s) #editor-workspace-root[data-chrome='explore'] .sp-editor-format-tools { gap: 6px; grid-template-columns: minmax(max-content,1fr) 64px 96px max-content; }
  body:where([data-sp-has~="explore-filters"]):not(#sp-s) #editor-workspace-root[data-chrome='explore'] #editor-open-filters { gap: 4px; padding-inline: 8px; font-size: 12px; }
  #editor-workspace-root[data-chrome='explore'] .sp-editor-format-tools input:not([type='radio']) { padding-left: 8px; padding-right: 20px; font-size: 12px; }
  #editor-workspace-root[data-chrome='explore'] .sp-editor-format-tools [class*='Input-section'][data-position='right'] { width: 18px; }
  #editor-workspace-root[data-chrome='explore'] .sp-editor-format-tools [class*='Input-section'][data-position='left'] { display: none; }
  #editor-workspace-root[data-chrome='explore'] #editor-cfg-chart-kind { padding-left: 8px; }
  #editor-workspace-root[data-chrome='explore'] .sp-editor-values-control > summary { padding-inline: 8px; font-size: 12px; }
}
@media (max-width: 359px) {
  body:where([data-sp-has~="explore-filters"]):not(#sp-s) #editor-workspace-root[data-chrome='explore'] .sp-editor-format-tools { width: 100%; grid-template-columns: repeat(2,minmax(0,1fr)); }
  #editor-workspace-root .sp-editor-edit-tools { flex-wrap: wrap; }
}
#compare-shell.sp-data-shell .cmp-cta-wrap { position: relative; z-index: 6; flex-wrap: wrap; padding-right: 0; }
#compare-shell.sp-data-shell .cmp-cta-wrap:has(#editor-explore-enter) {
  box-sizing: border-box;
  width: min(100%, var(--editor-canvas-width, 100%));
  margin-inline: auto;
  padding: 12px 0 0;
  flex-wrap: nowrap;
  justify-content: center;
  align-items: center;
  gap: 8px;
}
#compare-shell.sp-data-shell #editor-explore-enter { width: auto; min-width: 160px; height: 44px; min-height: 44px; border: 0; border-radius: 8px; cursor: pointer; font: 600 14px/20px var(--sp-font-ui); }
#compare-shell.sp-data-shell .cmp-cta-wrap:has(#editor-explore-enter) .cmp-more-actions { flex: 0 0 44px; margin-left: 0; }
#compare-shell.sp-data-shell .cmp-cta-wrap:has(#editor-explore-enter) .cmp-more-actions > summary { box-sizing: border-box; border: 1px solid var(--sp-border-strong); background: var(--sp-chrome); }
#compare-shell.sp-data-shell .cmp-cta-wrap:has(#editor-explore-enter) .cmp-more-actions > summary:hover,
#compare-shell.sp-data-shell .cmp-cta-wrap:has(#editor-explore-enter) .cmp-more-actions[open] > summary { background: var(--sp-surface); color: var(--sp-text); }
.cmp-more-actions { position: relative; margin-left: auto; }
.cmp-more-actions > summary { display: grid; place-items: center; width: 44px; height: 44px; font-size: 0; line-height: 0; list-style: none; border-radius: 8px; cursor: pointer; color: var(--sp-text-2); }
.cmp-more-actions > summary::-webkit-details-marker { display: none; }
.cmp-more-actions > summary::before { content: ''; width: 18px; height: 18px; background: currentColor; mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='black'%3E%3Ccircle cx='12' cy='5' r='1.8'/%3E%3Ccircle cx='12' cy='12' r='1.8'/%3E%3Ccircle cx='12' cy='19' r='1.8'/%3E%3C/svg%3E") center/contain no-repeat; }
.cmp-more-actions > summary:hover { background: var(--sp-surface); }
.cmp-more-actions > summary:focus-visible { outline: 2px solid var(--sp-accent); outline-offset: 2px; }
.cmp-more-options { position: absolute; right: 0; bottom: calc(100% + 4px); width: max-content; max-width: calc(100vw - 32px); padding: 5px; border: 1px solid var(--sp-border-strong); border-radius: 8px; background: var(--sp-surface); z-index: 30; }
@media (min-width: 768px), (min-width: 600px) and (min-aspect-ratio: 10/13) {
  #editor-workspace-root .sp-editor-view-toolbar { flex-direction: row; flex-wrap: wrap; align-items: center; justify-content: space-between; }
  #editor-workspace-root .sp-editor-format-tools { width: 390px; max-width: 100%; }
  #editor-workspace-root .sp-editor-edit-tools { margin-left: auto; }
}
@media (max-width: 599px), (max-width: 767px) and (max-aspect-ratio: 10/13) {
  #compare-shell.sp-data-shell #editor-explore-enter { flex: 1 1 auto; min-width: 0; }
  #editor-workspace-root .sp-editor-format-tools input:not([type='radio']), .sp-editor-values-control > summary { height: 44px; min-height: 44px; }
  .sp-editor-grid-options { left: auto; right: 0; }
}

#editor-workspace-root #editor-cfg-chart-kind { padding-left: 30px; }
.sp-editor-chart-icon { display: block; width: 17px; height: 17px; background: currentColor; mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.7' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 3v17h17M7 14l4-5 4 3 6-7m-5 0h5v5'/%3E%3C/svg%3E") center/contain no-repeat; }
/* Follow the scaled canvas, including the full-bleed mobile preview. */
#editor-workspace-root .sp-transport-bar {
  box-sizing: border-box;
  width: var(--editor-canvas-width, 100%);
  margin-inline: calc((100% - var(--editor-canvas-width, 100%)) / 2);
}

.sp-editor-select-chevron { width: 5px; height: 5px; border-right: 1.5px solid currentColor; border-bottom: 1.5px solid currentColor; transform: rotate(45deg); margin-top: -3px; }
#compare-shell.sp-data-shell #editor-explore-enter:focus-visible { outline: 2px solid var(--sp-accent); outline-offset: 3px; }
#compare-shell.sp-data-shell #editor-explore-enter:disabled { opacity: .5; cursor: wait; }
#compare-shell.sp-data-shell:not(:has(.cmp-preview--ranking,.cmp-views--table)) .cmp-back svg { display: none; }
#compare-shell.sp-data-shell:not(:has(.cmp-preview--ranking,.cmp-views--table)) .cmp-back::before { content: ''; width: 18px; height: 18px; background: currentColor; mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.7' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m12 5-7 7 7 7M5 12h14'/%3E%3C/svg%3E") center/contain no-repeat; }

#compare-shell.sp-data-shell:not(:has(.cmp-preview--ranking,.cmp-views--table)) :is(#cmp-views,.cmp-visual-actions) { display: none; }
#compare-shell.sp-data-shell:not(:has(.cmp-preview--ranking,.cmp-views--table)) .cmp-preview { gap: 0; }

/* Desktop has persistent comparison filters and a bounded post inspector. */
@media (min-width: 768px), (min-width: 600px) and (min-aspect-ratio: 10/13) {
  body:where([data-sp-has~="explore-panel-comparison"]):not(#sp-s):not(.sp-s):not(.sp-s):not(.sp-s) #editor-workspace-root[data-chrome='explore'] #editor-open-filters,
  #compare-shell.sp-data-shell[data-panel-page='comparison'] .cmp-filters-button { display: none; }
  body:where([data-sp-has~="explore-panel-comparison"]):not(#sp-s):not(.sp-s):not(.sp-s):not(.sp-s) #editor-workspace-root[data-chrome='explore'] .sp-editor-format-tools {
    grid-template-columns: 96px 248px max-content;
  }
}
