/* MDD 5.8 APPROVED WORKSPACE LAYOUT — ORIGINAL COMPONENTS, PRESENTATION ONLY.
   Apply only to the live workspace documents, including original iframe documents.
   This candidate does not mount, clone, remove, disable or relabel any control.
   Source hidden attributes, closed details and role permissions remain authoritative.
   Source: V03 full native DOM; visual vocabulary: dist/aplikacja/app.css.
   Palette stays MDD white / light gray / #0057b8 / navy text.
   No fixed content heights, clipping, ellipsis or text line limits are introduced. */

/* 1 — Shared MAIN vocabulary. Components outside this scope keep their source CSS. */
html[data-mdd-ux58="1"] {
  --mdd4-blue: #0057b8;
  --mdd4-ink: #172b47;
  --mdd4-copy: #334155;
  --mdd4-muted: #64748b;
  --mdd4-line: #dbe5f0;
  --mdd4-canvas: #f3f5f8;
  --mdd4-soft: #eef6ff;
  --mdd4-shadow: 0 3px 16px rgb(23 43 71 / 4%);
  --mdd4-font: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}
html[data-mdd-ux58="1"] #app {
  max-width: 1380px;
  padding: 24px 28px 56px;
}
html[data-mdd-ux58="1"] #mdd-work-panel {
  color: var(--mdd4-ink);
  background: var(--mdd4-canvas);
  border-color: var(--mdd4-line);
  border-radius: 16px;
  font-family: var(--mdd4-font);
  font-size: 14px;
  line-height: 1.55;
  overflow: visible;
}

/* 3 — Home becomes a compact start workspace, followed by every original module. */
html[data-mdd-ux58="1"] #mdd-home-view {
  color: var(--mdd4-ink);
  font: 400 14px/1.55 var(--mdd4-font);
}
html[data-mdd-ux58="1"] #mdd-home-view > .hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 18px;
  padding: 0 0 26px;
}
html[data-mdd-ux58="1"] #mdd-home-view .hero-copy {
  display: grid;
  grid-template-columns: minmax(230px, .85fr) minmax(0, 1.65fr);
  align-items: center;
  gap: 5px 32px;
  padding: 22px 24px;
  border: 1px solid var(--mdd4-line);
  border-radius: 14px;
  background: #fff;
  box-shadow: var(--mdd4-shadow);
}
html[data-mdd-ux58="1"] #mdd-home-view .hero-copy > .eyebrow {
  grid-column: 1;
  color: var(--mdd4-muted);
  letter-spacing: 0;
  text-transform: none;
  font-size: 13px;
}
html[data-mdd-ux58="1"] #mdd-home-view .hero-copy > h1 {
  grid-column: 1;
  grid-row: 2 / 4;
  margin: 0;
  color: var(--mdd4-ink);
  font: 600 18px/1.4 var(--mdd4-font);
  letter-spacing: 0;
}
html[data-mdd-ux58="1"] #mdd-home-view .hero-copy > p {
  grid-column: 2;
  grid-row: 1 / 3;
  max-width: 620px;
  margin: 0;
  color: var(--mdd4-copy);
  font-size: 14px;
  line-height: 1.6;
}
html[data-mdd-ux58="1"] #mdd-home-view .hero-copy > .intro-link {
  grid-column: 2;
  grid-row: 3;
  justify-self: start;
  margin: 3px 0 0;
  font-size: 13px;
}
html[data-mdd-ux58="1"] #mdd-home-view .connect-card {
  display: grid;
  grid-template-columns: minmax(250px, .85fr) minmax(0, 1.65fr);
  align-items: start;
  gap: 10px 28px;
  padding: 20px 24px;
  border: 1px solid var(--mdd4-line);
  border-left: 4px solid var(--mdd4-blue);
  border-radius: 14px;
  background: #fff;
  box-shadow: var(--mdd4-shadow);
}
html[data-mdd-ux58="1"] #mdd-home-view .connect-card > .brand-connection {
  grid-column: 1;
  grid-row: 1 / 3;
  flex-wrap: wrap;
  margin: 0;
}
html[data-mdd-ux58="1"] #mdd-home-view .connect-card > h2 {
  grid-column: 2;
  margin: 0;
  color: var(--mdd4-ink);
  font: 600 18px/1.4 var(--mdd4-font);
  letter-spacing: 0;
}
html[data-mdd-ux58="1"] #mdd-home-view .connect-card > p {
  grid-column: 2;
  margin: 0;
  color: var(--mdd4-muted);
  font-size: 14px;
  line-height: 1.55;
}
html[data-mdd-ux58="1"] #mdd-home-view .connect-card > :is(.flow-line, .connect-actions) {
  grid-column: 1;
  margin: 0;
  font-size: 13px;
}
html[data-mdd-ux58="1"] #mdd-home-view .connect-card > :is(.compact-how, .test-note) {
  grid-column: 2;
  margin: 0;
  font-size: 13px;
}
html[data-mdd-ux58="1"] #mdd-home-view :is(.connection-caption, .compact-how summary, .compact-how ol, .text-link, .test-note, .section-footnote) {
  font-size: 13px;
  line-height: 1.5;
}
html[data-mdd-ux58="1"] #mdd-home-view .section-heading {
  align-items: start;
  gap: 12px 24px;
  margin-bottom: 14px;
}
html[data-mdd-ux58="1"] #mdd-home-view .section-heading h2 {
  margin: 0 0 4px;
  font: 600 18px/1.4 var(--mdd4-font);
  letter-spacing: 0;
}
html[data-mdd-ux58="1"] #mdd-home-view .section-heading p {
  font-size: 14px;
}
html[data-mdd-ux58="1"] #mdd-home-view .module-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}
html[data-mdd-ux58="1"] #mdd-home-view .module-tile {
  min-width: 0;
  min-height: 0;
  padding: 16px;
  border-color: var(--mdd4-line);
  border-radius: 12px;
  background: #fff;
  box-shadow: var(--mdd4-shadow);
}
html[data-mdd-ux58="1"] #mdd-home-view .module-tile.available {
  border-top: 3px solid var(--mdd4-blue);
  background: #fff;
}
html[data-mdd-ux58="1"] #mdd-home-view .module-tile .tile-top {
  gap: 12px;
  margin-bottom: 10px;
}
html[data-mdd-ux58="1"] #mdd-home-view .module-tile h3 {
  margin: 0 0 6px;
  color: var(--mdd4-ink);
  font: 600 14px/1.5 var(--mdd4-font);
  overflow-wrap: anywhere;
}
html[data-mdd-ux58="1"] #mdd-home-view .module-tile p {
  margin: 0 0 12px;
  color: var(--mdd4-muted);
  font-size: 13px;
  line-height: 1.55;
}
html[data-mdd-ux58="1"] #mdd-home-view .module-tile :is(.status, .module-number) {
  font-size: 13px;
  line-height: 1.4;
}

/* 4 — Cases: title/brief left, status right, original management in a full-width footer. */
html[data-mdd-ux58="1"] #sprawy {
  margin-top: 26px;
  padding: 22px;
  border-color: var(--mdd4-line);
  border-radius: 14px;
  background: #fff;
  overflow: visible;
  box-shadow: var(--mdd4-shadow);
}
html[data-mdd-ux58="1"] #sprawy > .section-title {
  align-items: start;
  gap: 16px;
}
html[data-mdd-ux58="1"] #sprawy .section-title h2 {
  font: 600 18px/1.4 var(--mdd4-font);
}
html[data-mdd-ux58="1"] #app .case-list.csl58-list {
  gap: 14px;
}
html[data-mdd-ux58="1"] #app .case-list > .case-result110.csl58-card {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(260px, 1fr);
  grid-template-areas: "select status" "identity status" "preview status" "links status" "footer footer";
  align-items: start;
  gap: 0;
  border: 1px solid var(--mdd4-line);
  border-radius: 12px;
  background: #fff;
  overflow: visible;
  box-shadow: var(--mdd4-shadow);
}
html[data-mdd-ux58="1"] #app .csl58-card > .mdd-bulk-check58 {
  grid-area: select;
  padding: 10px 18px 0;
  font-size: 13px;
}
html[data-mdd-ux58="1"] #app .csl58-card > :is(.case-link, .mdd-case-navigation-row) {
  grid-area: identity;
  min-width: 0;
  padding: 0;
}
html[data-mdd-ux58="1"] #app .csl58-card .case-link[data-action="open"] {
  min-height: 0;
  padding: 14px 18px 0 !important;
  margin: 0 !important;
  border: 0 !important;
  background: transparent !important;
  white-space: normal;
}
html[data-mdd-ux58="1"] #app .csl58-card .case-link strong {
  color: var(--mdd4-ink);
  font: 600 18px/1.4 var(--mdd4-font);
  overflow-wrap: anywhere;
}
html[data-mdd-ux58="1"] #app .csl58-card .case-meta {
  margin-top: 4px;
  color: var(--mdd4-muted);
  font: 400 13px/1.5 var(--mdd4-font);
}
html[data-mdd-ux58="1"] #app .csl58-card > .csl58-identity {
  grid-area: preview;
  padding: 0 18px 14px;
  font: 400 14px/1.55 var(--mdd4-font);
}
html[data-mdd-ux58="1"] #app .csl58-identity p {
  display: block;
  margin: 8px 0 0;
  -webkit-line-clamp: unset;
  overflow: visible;
  white-space: normal;
  overflow-wrap: anywhere;
}
html[data-mdd-ux58="1"] #app .csl58-card > .csl58-progress {
  grid-area: status;
  align-self: stretch;
  min-width: 0;
  margin: 0;
  padding: 16px 18px;
  border-left: 1px solid var(--mdd4-line);
  background: #f8fafc;
  border-radius: 0 12px 0 0;
}
html[data-mdd-ux58="1"] #app .csl58-progress > .co58-toggle {
  position: static;
  margin: 0 0 10px;
  min-height: 34px;
  padding: 6px 10px;
  font: 500 13px/1.5 var(--mdd4-font);
}
html[data-mdd-ux58="1"] #app .csl58-progress :is(.csl58-counts, .co58-summary, .csl58-folder) {
  font-size: 13px;
  line-height: 1.55;
}
html[data-mdd-ux58="1"] #app .csl58-progress .co58-summary {
  gap: 6px 12px;
}
html[data-mdd-ux58="1"] #app .csl58-card > .csl58-footer {
  grid-area: footer;
  padding: 10px 18px;
  gap: 10px 20px;
  border-top-color: var(--mdd4-line);
  border-radius: 0 0 12px 12px;
  background: #fff;
}
html[data-mdd-ux58="1"] #app .csl58-card > .navigator-case-link57 {
  grid-area: links;
  margin: 0 18px 14px;
  font: 500 13px/1.5 var(--mdd4-font);
}
html[data-mdd-ux58="1"] #app .csl58-card :is(.mdd-case-navigation-actions, .case-management-actions) {
  gap: 8px;
  flex-wrap: wrap;
}
html[data-mdd-ux58="1"] #app .csl58-footer .csl58-open {
  min-height: 34px;
  padding: 6px 12px;
  border: 1px solid var(--mdd4-line);
  border-radius: 8px;
  background: var(--mdd4-soft);
  color: var(--mdd4-blue);
  font: 600 13px/1.5 var(--mdd4-font);
}
html[data-mdd-ux58="1"] #mdd-work-panel > .project.co58-heading {
  margin: 18px 20px;
  padding: 18px 20px;
  gap: 8px 16px;
  border: 1px solid var(--mdd4-line);
  border-radius: 12px;
  background: #fff;
  box-shadow: var(--mdd4-shadow);
}
html[data-mdd-ux58="1"] #mdd-work-panel > .project #project-name {
  color: var(--mdd4-ink);
  font: 600 18px/1.4 var(--mdd4-font);
}
html[data-mdd-ux58="1"] #mdd-work-panel > .project :is(#source-ref, .case-management-owner, .co58-summary) {
  font: 400 13px/1.55 var(--mdd4-font);
}
html[data-mdd-ux58="1"] #mdd-work-panel > #selection-tabs {
  flex-wrap: wrap;
  gap: 6px;
  margin: 18px 20px 0;
  padding: 8px;
  border: 1px solid var(--mdd4-line);
  border-radius: 12px;
  background: #fff;
  box-shadow: var(--mdd4-shadow);
}
html[data-mdd-ux58="1"] #mdd-work-panel > #selection-tabs > button {
  flex: 1 1 150px;
  min-height: 36px;
  padding: 7px 12px;
  border: 1px solid transparent;
  border-radius: 8px;
  color: var(--mdd4-copy);
  background: #fff;
  white-space: normal;
  font: 500 13px/1.5 var(--mdd4-font);
}
html[data-mdd-ux58="1"] #mdd-work-panel > #selection-tabs > button[aria-selected="true"] {
  border-color: var(--mdd4-blue);
  color: #fff;
  background: var(--mdd4-blue);
}
html[data-mdd-ux58="1"] #mdd-work-panel > #project-edit-toolbar {
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 20px 18px;
  padding: 12px;
  border: 1px solid var(--mdd4-line);
  border-top: 0;
  border-radius: 0 0 12px 12px;
  background: #f8fafc;
}
html[data-mdd-ux58="1"] #project-edit-toolbar > button,
html[data-mdd-ux58="1"] #project-edit-toolbar > .model-admin-link {
  min-height: 34px;
  padding: 6px 10px;
  border-radius: 8px;
  white-space: normal;
  font: 500 13px/1.5 var(--mdd4-font);
}

/* 6 — Full original progress and selection panels; no stage, detail or button omitted. */
html[data-mdd-ux58="1"] #mdd-work-panel > #mdd-progress67 {
  margin: 18px 20px;
  padding: 18px 20px;
  border: 1px solid var(--mdd4-line);
  border-left: 4px solid var(--mdd4-blue);
  border-radius: 12px;
  background: #fff;
  box-shadow: var(--mdd4-shadow);
}
html[data-mdd-ux58="1"] #mdd-progress67 .mdd67-total {
  align-items: start;
  gap: 10px 24px;
}
html[data-mdd-ux58="1"] #mdd-progress67 .mdd67-mainline,
html[data-mdd-ux58="1"] #mdd-progress67 .mdd67-total strong {
  color: var(--mdd4-ink);
  font: 600 18px/1.4 var(--mdd4-font);
}
html[data-mdd-ux58="1"] #mdd-progress67 :is(.mdd67-metrics, p, .caption, summary) {
  font-size: 13px;
  line-height: 1.55;
}
html[data-mdd-ux58="1"] #mdd-progress67 progress {
  height: 8px;
  margin-block: 14px;
  accent-color: var(--mdd4-blue);
}
html[data-mdd-ux58="1"] #mdd-progress67 details {
  margin-block: 8px 0;
  border-color: var(--mdd4-line);
}
html[data-mdd-ux58="1"] #mdd-progress67 details > summary {
  padding-block: 11px;
  color: var(--mdd4-blue);
  font-weight: 500;
}
html[data-mdd-ux58="1"] #mdd-progress67 .mdd67-ids {
  max-height: none;
  overflow: visible;
  overflow-wrap: anywhere;
}
html[data-mdd-ux58="1"] #mdd-work-panel > [data-selection-settings58] {
  margin: 18px 20px;
  padding: 18px 20px;
  border: 1px solid var(--mdd4-line);
  border-radius: 12px;
  background: #fff;
  box-shadow: var(--mdd4-shadow);
}
html[data-mdd-ux58="1"] [data-selection-settings58] > strong {
  color: var(--mdd4-ink);
  font: 600 18px/1.4 var(--mdd4-font);
}
html[data-mdd-ux58="1"] [data-selection-settings58] > div {
  gap: 12px 20px;
}
html[data-mdd-ux58="1"] [data-selection-settings58] :is(.caption, label, select, summary) {
  font: 400 13px/1.55 var(--mdd4-font);
}
html[data-mdd-ux58="1"] [data-selection-settings58] select {
  min-height: 40px;
  height: auto;
  padding: 9px 12px;
  border-color: var(--mdd4-line);
  border-radius: 8px;
}
html[data-mdd-ux58="1"] [data-selection-settings58] [data-selection-advanced58] {
  border-radius: 8px;
  background: #f8fafc;
}

/* 7 — Specification and products: stronger reference/selection separation, original row DOM. */
html[data-mdd-ux58="1"] #mdd-work-panel :is(.position-card, .source-entry) {
  border-color: var(--mdd4-line);
  border-radius: 12px;
  background: #fff;
  box-shadow: var(--mdd4-shadow);
}
html[data-mdd-ux58="1"] #mdd-work-panel .position-card .position-header {
  padding: 14px 18px;
  border-bottom-color: var(--mdd4-line);
  background: #f8fafc;
}
html[data-mdd-ux58="1"] #mdd-work-panel .position-title h3 {
  font: 600 18px/1.4 var(--mdd4-font);
}
html[data-mdd-ux58="1"] #mdd-work-panel :is(.position-body, .position-footer) {
  padding: 16px 18px;
}
html[data-mdd-ux58="1"] #mdd-work-panel :is(.source-text, .requirements, .position-facts) {
  font: 400 14px/1.6 var(--mdd4-font);
}
html[data-mdd-ux58="1"] #product-list-native .plv-shell {
  margin: 18px 20px;
  padding: 20px;
  border: 1px solid var(--mdd4-line);
  border-radius: 12px;
  background: #fff;
  box-shadow: var(--mdd4-shadow);
}
html[data-mdd-ux58="1"] #product-list-native .plv-heading h3 {
  margin: 0 0 5px;
  color: var(--mdd4-ink);
  font: 600 18px/1.4 var(--mdd4-font);
}
html[data-mdd-ux58="1"] #product-list-native .plv-heading p {
  color: var(--mdd4-muted);
  font: 400 14px/1.55 var(--mdd4-font);
}
html[data-mdd-ux58="1"] #product-list-native .plv-columns {
  padding: 11px 14px;
  border-color: var(--mdd4-line);
  border-radius: 8px;
  color: var(--mdd4-muted);
  background: #f3f5f8;
  font-size: 13px;
}
html[data-mdd-ux58="1"] #product-list-native .plv-list {
  gap: 12px;
  margin-top: 12px;
}
html[data-mdd-ux58="1"] #product-list-native .plv-row {
  min-height: 0;
  padding: 16px 14px;
  border-color: var(--mdd4-line);
  border-radius: 10px;
  background: #fff;
}
html[data-mdd-ux58="1"] #product-list-native .plv-reference {
  padding: 10px 12px;
  border-radius: 8px;
  background: #f8fafc;
}
html[data-mdd-ux58="1"] #product-list-native :is(.plv-position strong, .plv-reference small, .plv-product small, .plv-toggle, .plv-choose, .plv-chosen, .plv-pending, .plv-review-button) {
  font: 400 13px/1.5 var(--mdd4-font);
}
html[data-mdd-ux58="1"] #product-list-native :is(.plv-reference p, .plv-product ul, .plv-product details, .plv-notes72 p) {
  color: var(--mdd4-copy);
  font: 400 14px/1.55 var(--mdd4-font);
}
html[data-mdd-ux58="1"] #product-list-native .plv-product > strong {
  color: var(--mdd4-ink);
  font: 600 14px/1.5 var(--mdd4-font);
}
html[data-mdd-ux58="1"] #product-list-native .plv-review-button {
  min-height: 34px;
  border-radius: 8px;
  background: var(--mdd4-soft);
  color: var(--mdd4-blue);
}

/* 8 — Original external iframe: a white workspace with clear tool and content bands. */
html[data-mdd-ux58="1"] body > .app-header {
  min-height: 60px;
  padding: 12px 24px;
  gap: 12px 20px;
  align-items: center;
  flex-wrap: wrap;
  border-bottom: 1px solid var(--mdd4-line);
  background: #fff;
  box-shadow: var(--mdd4-shadow);
}
html[data-mdd-ux58="1"] .app-header .brand-copy {
  flex: 1;
  min-width: 200px;
}
html[data-mdd-ux58="1"] .app-header .brand-copy h1 {
  color: var(--mdd4-ink);
  font: 600 18px/1.4 var(--mdd4-font);
  letter-spacing: 0;
}
html[data-mdd-ux58="1"] .app-header :is(.brand-copy p, #connection) {
  color: var(--mdd4-muted);
  font: 400 13px/1.5 var(--mdd4-font);
  white-space: normal;
  overflow-wrap: anywhere;
}
html[data-mdd-ux58="1"] .isolation-banner {
  padding: 9px 24px;
  border-color: var(--mdd4-line);
  background: var(--mdd4-soft);
  color: var(--mdd4-copy);
  font: 400 13px/1.5 var(--mdd4-font);
}
html[data-mdd-ux58="1"] .app-main {
  max-width: 1440px;
  margin-inline: auto;
  padding: 20px 24px 44px;
  color: var(--mdd4-ink);
  font: 400 14px/1.55 var(--mdd4-font);
}
html[data-mdd-ux58="1"] .app-main > .lab-toolbar {
  padding: 14px 16px;
  gap: 12px 20px;
  flex-wrap: wrap;
  align-items: start;
  border: 1px solid var(--mdd4-line);
  border-radius: 12px;
  background: #fff;
  box-shadow: var(--mdd4-shadow);
}
html[data-mdd-ux58="1"] .lab-toolbar :is(.lab-picker, #lab-summary) {
  min-width: 0;
  font: 400 13px/1.55 var(--mdd4-font);
}
html[data-mdd-ux58="1"] .app-main > nav.tabs {
  flex-wrap: wrap;
  gap: 6px;
  margin-block: 14px;
  padding: 8px;
  border: 1px solid var(--mdd4-line);
  border-radius: 12px;
  background: #fff;
}
html[data-mdd-ux58="1"] .app-main > nav.tabs > button {
  flex: 1 1 150px;
  padding: 8px 12px;
  min-height: 36px;
  border-radius: 8px;
  white-space: normal;
  font: 500 13px/1.5 var(--mdd4-font);
}
html[data-mdd-ux58="1"] .app-main > nav.tabs > button.active,
html[data-mdd-ux58="1"] .app-main > nav.tabs > button[aria-selected="true"] {
  color: #fff;
  border-color: var(--mdd4-blue);
  background: var(--mdd4-blue);
}
html[data-mdd-ux58="1"] #app-content :is(.panel, .ep117-card) {
  min-width: 0;
  padding: 18px;
  border-color: var(--mdd4-line);
  border-radius: 12px;
  background: #fff;
  box-shadow: var(--mdd4-shadow);
}
html[data-mdd-ux58="1"] #app-content .panel {
  padding: 0;
  overflow: visible;
}
html[data-mdd-ux58="1"] #app-content .panel > .panel-heading {
  margin: 0;
  padding: 16px 18px;
  border-radius: 12px 12px 0 0;
  background: #f8fafc;
}
html[data-mdd-ux58="1"] #app-content .panel > .panel-body {
  padding: 18px;
}
html[data-mdd-ux58="1"] #app-content .workbench {
  grid-template-columns: minmax(260px, .75fr) minmax(0, 1.75fr);
}
html[data-mdd-ux58="1"] #app-content .panel-heading {
  gap: 12px 20px;
  margin-bottom: 16px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--mdd4-line);
}
html[data-mdd-ux58="1"] #app-content .panel-heading :is(h2, h3),
html[data-mdd-ux58="1"] #app-content .ep117-card h3 {
  margin-block: 0 5px;
  color: var(--mdd4-ink);
  font: 600 18px/1.4 var(--mdd4-font);
}
html[data-mdd-ux58="1"] #app-content :is(.bulk-view-toolbar, .panel-actions) {
  gap: 8px 12px;
  flex-wrap: wrap;
  padding-block: 10px;
}
html[data-mdd-ux58="1"] #app-content :is(.workbench, .ep117-grid, .library-workbench, .library-layout) {
  gap: 18px;
}
html[data-mdd-ux58="1"] #app-content :is(.panel-body, .ep117-card) :is(p, label, input, select, textarea) {
  font-family: var(--mdd4-font);
  font-size: 14px;
  line-height: 1.55;
}

/* 9 — Narrow viewports keep every original item in natural flow. */
@media (max-width: 1050px) {
  html[data-mdd-ux58="1"] #mdd-home-view .module-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}
@media (max-width: 760px) {
  html[data-mdd-ux58="1"] #app {
    padding: 18px 14px 40px;
  }
  html[data-mdd-ux58="1"] #mdd-home-view :is(.hero-copy, .connect-card) {
    grid-template-columns: minmax(0, 1fr);
    padding: 18px;
    gap: 12px;
  }
  html[data-mdd-ux58="1"] #mdd-home-view .hero-copy > :is(.eyebrow, h1, p, .intro-link),
  html[data-mdd-ux58="1"] #mdd-home-view .connect-card > :is(.brand-connection, h2, p, .flow-line, .connect-actions, .compact-how, .test-note) {
    grid-column: 1;
    grid-row: auto;
  }
  html[data-mdd-ux58="1"] #mdd-home-view .module-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  html[data-mdd-ux58="1"] #app .case-list > .case-result110.csl58-card {
    grid-template-columns: minmax(0, 1fr);
    grid-template-areas: "select" "identity" "preview" "links" "status" "footer";
  }
  html[data-mdd-ux58="1"] #app .csl58-card > .csl58-progress {
    border-left: 0;
    border-top: 1px solid var(--mdd4-line);
    border-radius: 0;
  }
  html[data-mdd-ux58="1"] #mdd-work-panel > :is(.project.co58-heading, #mdd-progress67, [data-selection-settings58], #selection-tabs),
  html[data-mdd-ux58="1"] #product-list-native .plv-shell {
    margin-inline: 12px;
  }
  html[data-mdd-ux58="1"] #mdd-work-panel > #project-edit-toolbar {
    margin-inline: 12px;
  }
  html[data-mdd-ux58="1"] #mdd-work-panel > :is(.project.co58-heading, #mdd-progress67, [data-selection-settings58]),
  html[data-mdd-ux58="1"] #product-list-native .plv-shell {
    padding: 16px;
  }
  html[data-mdd-ux58="1"] #app-content .workbench {
    grid-template-columns: minmax(0, 1fr);
  }
}
@media (max-width: 480px) {
  html[data-mdd-ux58="1"] #mdd-home-view .module-grid {
    grid-template-columns: minmax(0, 1fr);
  }
  html[data-mdd-ux58="1"] body > .app-header,
  html[data-mdd-ux58="1"] .app-main {
    padding-inline: 12px;
  }
}

/* Pilot refinements: keep HTML state authoritative and utility menus compact. */
html[data-mdd-ux58="1"] [hidden] { display: none !important; }
html[data-mdd-ux58="1"] #mdd-home-view .hero-copy>h1 {font-size:32px;line-height:1.25;letter-spacing:-.65px;}
@media(min-width:1100px){
}

/* The case header keeps project navigation on one row and AI status on a compact band. */
@media(min-width:1100px){
}

/* Narrow headers wrap whole actions; menus expand in flow instead of leaving the viewport. */
@media(max-width:1099px){
}
@media(max-width:760px){
html[data-mdd-ux58="1"] #app .section-title {display:flex;flex-wrap:wrap;gap:10px;}
html[data-mdd-ux58="1"] #app .section-title>div {flex:1 1 100%;min-width:0;}
html[data-mdd-ux58="1"] #app .section-title>button {flex:0 1 auto;max-width:100%;white-space:normal;}
}

/* Keep configuration and progress together above the work tabs on a wide screen. */
@media(min-width:1100px){
html[data-mdd-ux58="1"] #mdd-work-panel:has(>[data-selection-settings58]):has(>#mdd-progress67) {display:grid;grid-template-columns:minmax(0,1.15fr) minmax(0,1fr);align-items:start;}
html[data-mdd-ux58="1"] #mdd-work-panel:has(>[data-selection-settings58]):has(>#mdd-progress67)>* {grid-column:1/-1;min-width:0;}
html[data-mdd-ux58="1"] #mdd-work-panel:has(>[data-selection-settings58]):has(>#mdd-progress67)>[data-selection-settings58] {grid-column:1;margin-right:8px;align-self:stretch;}
html[data-mdd-ux58="1"] #mdd-work-panel:has(>[data-selection-settings58]):has(>#mdd-progress67)>#mdd-progress67 {grid-column:2;margin-left:8px;align-self:stretch;}
html[data-mdd-ux58="1"] #mdd-work-panel:has(>[data-selection-settings58]):has(>#mdd-progress67)>button {justify-self:start;}
}

/* MDD SUPPORT v04 — distinct visual proposal, original source components retained.
   Opt-in only: html[data-mdd-ux58="1"]. No HTML/JS replacement, network assets,
   hiding rules, content injection, fixed control heights, clipping or visual reordering. */

/* Shared design language: Inter, clear content hierarchy, large white work surfaces. */
html[data-mdd-ux58="1"] body:has(#navigator-process),
html[data-mdd-ux58="1"] body:has(#convertWorkspace),
html[data-mdd-ux58="1"] body:has(main.nt58.t3),
html[data-mdd-ux58="1"] body:has(main#admin.admin-center),
html[data-mdd-ux58="1"] body:has(#accounts57),
html[data-mdd-ux58="1"] body:has(main > #content[aria-busy]),
html[data-mdd-ux58="1"] body:has(main #krok-8),
html[data-mdd-ux58="1"] body:has(main #start[href^="mdd-linx58-2:"]),
html[data-mdd-ux58="1"] body:has(main #offerUploadWindowFile),
html[data-mdd-ux58="1"] body:has(main #download) {
  --mdd-v4-ink: #0f172a;
  --mdd-v4-muted: #64748b;
  --mdd-v4-blue: #0057b8;
  --mdd-v4-line: #dbe5f0;
  --mdd-v4-soft: #f4f7fb;
  --mdd-v4-shadow: 0 8px 28px rgba(15,23,42,.055);
  background: var(--mdd-v4-soft);
  color: var(--mdd-v4-ink);
  font-family: Inter,-apple-system,BlinkMacSystemFont,"Segoe UI",Arial,sans-serif;
  font-size: 14px;
  line-height: 1.65;
}
html[data-mdd-ux58="1"] body:has(#navigator-process) :is(main, .admin-center),
html[data-mdd-ux58="1"] body:has(#convertWorkspace) :is(main, .admin-center),
html[data-mdd-ux58="1"] body:has(main.nt58.t3) :is(main, .admin-center),
html[data-mdd-ux58="1"] body:has(main#admin.admin-center) :is(main, .admin-center),
html[data-mdd-ux58="1"] body:has(#accounts57) :is(main, .admin-center),
html[data-mdd-ux58="1"] body:has(main > #content[aria-busy]) :is(main, .admin-center) {
  font-family: inherit;
  color: var(--mdd-v4-ink);
}
html[data-mdd-ux58="1"] body:has(#navigator-process) :is(h1,h2,h3),
html[data-mdd-ux58="1"] body:has(#convertWorkspace) :is(h1,h2,h3),
html[data-mdd-ux58="1"] body:has(main.nt58.t3) :is(h1,h2,h3),
html[data-mdd-ux58="1"] body:has(main#admin.admin-center) :is(h1,h2,h3),
html[data-mdd-ux58="1"] body:has(#accounts57) :is(h1,h2,h3),
html[data-mdd-ux58="1"] body:has(main > #content[aria-busy]) :is(h1,h2,h3) {
  color: var(--mdd-v4-ink);
  font-family: inherit;
  letter-spacing: -.02em;
  font-weight: 600;
}
html[data-mdd-ux58="1"] body:has(#navigator-process) h1,
html[data-mdd-ux58="1"] body:has(#convertWorkspace) h1,
html[data-mdd-ux58="1"] body:has(main.nt58.t3) h1,
html[data-mdd-ux58="1"] body:has(main#admin.admin-center) h1,
html[data-mdd-ux58="1"] body:has(#accounts57) h1,
html[data-mdd-ux58="1"] body:has(main > #content[aria-busy]) h1 {
  font-size: clamp(26px,2.5vw,34px);
  line-height: 1.25;
}
html[data-mdd-ux58="1"] body:has(#navigator-process) :is(.eyebrow,.nt58-eyebrow),
html[data-mdd-ux58="1"] body:has(#convertWorkspace) :is(.eyebrow,.nt58-eyebrow),
html[data-mdd-ux58="1"] body:has(main.nt58.t3) :is(.eyebrow,.nt58-eyebrow),
html[data-mdd-ux58="1"] body:has(main#admin.admin-center) :is(.eyebrow,.nt58-eyebrow),
html[data-mdd-ux58="1"] body:has(#accounts57) :is(.eyebrow,.nt58-eyebrow),
html[data-mdd-ux58="1"] body:has(main > #content[aria-busy]) :is(.eyebrow,.nt58-eyebrow) {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .1em;
  color: var(--mdd-v4-muted);
}
html[data-mdd-ux58="1"] body:has(#navigator-process) .header-inner {
  max-width: 1360px;
  margin-inline: auto;
  gap: 20px;
  flex-wrap: wrap;
}
html[data-mdd-ux58="1"] body:has(main#admin.admin-center) > header,
html[data-mdd-ux58="1"] body:has(#accounts57) > header,
html[data-mdd-ux58="1"] body:has(main > #content[aria-busy]) > header {
  background: #fff;
  border-bottom: 1px solid var(--mdd-v4-line);
  padding: 20px 32px;
  min-height: 82px;
  gap: 20px;
  flex-wrap: wrap;
  font-family: inherit;
}
html[data-mdd-ux58="1"] body:has(main#admin.admin-center) > header a,
html[data-mdd-ux58="1"] body:has(#accounts57) > header a,
html[data-mdd-ux58="1"] body:has(main > #content[aria-busy]) > header a {
  font-size: 13px;
  font-weight: 500;
  color: var(--mdd-v4-blue);
}
html[data-mdd-ux58="1"] body:has(#navigator-process) .button,
html[data-mdd-ux58="1"] body:has(#convertWorkspace) .button {
  min-height: 42px;
  padding: 10px 16px;
  border-radius: 9px;
  border: 1px solid #cbdbee;
  background: #fff;
  color: var(--mdd-v4-blue);
  font-family: inherit;
  font-weight: 600;
  font-size: 13px;
  line-height: 1.55;
  white-space: normal;
}
html[data-mdd-ux58="1"] body:has(#navigator-process) .button.primary,
html[data-mdd-ux58="1"] body:has(#convertWorkspace) .button.primary {
  background: var(--mdd-v4-blue);
  color: #fff;
  border-color: var(--mdd-v4-blue);
}
html[data-mdd-ux58="1"] body:has(#navigator-process) .text-button,
html[data-mdd-ux58="1"] body:has(#convertWorkspace) .text-button {
  font-family: inherit;
  font-size: 13px;
  line-height: 1.6;
}
html[data-mdd-ux58="1"] body:has(main#admin.admin-center) .admin-center :is(button,.button),
html[data-mdd-ux58="1"] body:has(#accounts57) .admin-center :is(button,.button) {
  min-height: 42px;
  padding: 10px 15px;
  border-radius: 9px;
  font-family: inherit;
  font-weight: 600;
  font-size: 13px;
  line-height: 1.55;
  white-space: normal;
}
html[data-mdd-ux58="1"] body:has(#accounts57) .user-manager57 button {
  min-height: 42px;
  padding: 10px 15px;
  border-radius: 9px;
  font-family: inherit;
  font-weight: 600;
  font-size: 13px;
  line-height: 1.55;
  white-space: normal;
}
html[data-mdd-ux58="1"] body:has(main > #content[aria-busy]) #content button {
  min-height: 42px;
  padding: 10px 18px;
  border-radius: 9px;
  font-family: inherit;
  font-weight: 600;
  font-size: 13px;
  line-height: 1.55;
}
html[data-mdd-ux58="1"] body:has(main.nt58.t3) main.nt58.t3 :is(.nt58-actions button,#new-test,#add-files) {
  min-height: 42px;
  padding: 10px 16px;
  border-radius: 9px;
  font-family: inherit;
  font-weight: 600;
  font-size: 13px;
  line-height: 1.55;
  white-space: normal;
}

/* Navigator: two-column workspace, original source order, complete process and controls. */
html[data-mdd-ux58="1"] body:has(#navigator-process) #app {
  max-width: 1360px;
  padding: 32px 28px 72px;
}
html[data-mdd-ux58="1"] body:has(#navigator-process) #home-view:not([hidden]) {
  display: grid;
  grid-template-columns: minmax(0,1.75fr) minmax(300px,1fr);
  gap: 24px;
  align-items: start;
}
html[data-mdd-ux58="1"] body:has(#navigator-process) #home-view > .page-intro {
  grid-column: 1 / -1;
  max-width: none;
  margin: 0;
  padding: 28px 30px;
  background: #fff;
  border: 1px solid var(--mdd-v4-line);
  border-left: 6px solid var(--mdd-v4-blue);
  border-radius: 16px;
  box-shadow: var(--mdd-v4-shadow);
}
html[data-mdd-ux58="1"] body:has(#navigator-process) #home-view > .intake {
  max-width: none;
  width: 100%;
  margin: 0;
}
html[data-mdd-ux58="1"] body:has(#navigator-process) #home-view > .saved-section {
  max-width: none;
  width: 100%;
  margin: 0;
  padding: 24px;
  border: 1px solid var(--mdd-v4-line);
  border-radius: 16px;
  background: #fff;
  box-shadow: var(--mdd-v4-shadow);
}
html[data-mdd-ux58="1"] body:has(#navigator-process) #home-view .lead {
  font-size: 14px;
  line-height: 1.75;
  max-width: 900px;
  margin-top: 12px;
}
html[data-mdd-ux58="1"] body:has(#navigator-process) #case-view:not([hidden]) {
  display: grid;
  grid-template-columns: minmax(0,1.85fr) minmax(300px,1fr);
  gap: 22px;
  align-items: start;
}
html[data-mdd-ux58="1"] body:has(#navigator-process) #case-view > * {
  grid-column: 1 / -1;
  min-width: 0;
}
html[data-mdd-ux58="1"] body:has(#navigator-process) #case-view > .assistant-panel {
  grid-column: 1;
  margin: 0;
}
html[data-mdd-ux58="1"] body:has(#navigator-process) #case-view > #summary {
  grid-column: 2;
  grid-template-columns: 1fr;
  gap: 14px;
  margin: 0;
}
html[data-mdd-ux58="1"] body:has(#navigator-process) #case-view > .case-heading {
  margin: 0;
  padding: 28px 30px;
  background: #fff;
  border: 1px solid var(--mdd-v4-line);
  border-left: 6px solid var(--mdd-v4-blue);
  border-radius: 16px;
  box-shadow: var(--mdd-v4-shadow);
  gap: 20px;
  flex-wrap: wrap;
}
html[data-mdd-ux58="1"] body:has(#navigator-process) #case-view > .case-topline {
  margin: 0;
  padding: 0 2px;
  gap: 14px;
  flex-wrap: wrap;
}
html[data-mdd-ux58="1"] body:has(#navigator-process) #case-view > .navigator-purpose {
  margin: 0;
  padding: 18px 22px;
  border-radius: 12px;
  background: #eaf3ff;
  border: 1px solid #c8ddf6;
}
html[data-mdd-ux58="1"] body:has(#navigator-process) #case-view > #navigator-process:not([hidden]) {
  display: grid;
  grid-template-columns: repeat(auto-fit,minmax(150px,1fr));
  gap: 12px;
  margin: 0;
  padding: 18px;
  background: #fff;
  border: 1px solid var(--mdd-v4-line);
  border-radius: 14px;
}
html[data-mdd-ux58="1"] body:has(#navigator-process) #case-view > #navigator-process button {
  min-height: 58px;
  border-radius: 10px;
  padding: 12px;
  font-size: 13px;
  line-height: 1.5;
  white-space: normal;
}
html[data-mdd-ux58="1"] body:has(#navigator-process) #app .panel {
  padding: 26px;
  border: 1px solid var(--mdd-v4-line);
  border-radius: 16px;
  box-shadow: var(--mdd-v4-shadow);
}
html[data-mdd-ux58="1"] body:has(#navigator-process) #app .section-heading {
  align-items: flex-start;
  gap: 20px;
  flex-wrap: wrap;
  margin-bottom: 22px;
}
html[data-mdd-ux58="1"] body:has(#navigator-process) #app .section-heading p {
  font-size: 13px;
  line-height: 1.65;
}
html[data-mdd-ux58="1"] body:has(#navigator-process) #app .drop-zone {
  padding: 24px;
  min-height: 230px;
  border: 2px dashed #b8cfe9;
  border-radius: 12px;
  background: #f7faff;
}
html[data-mdd-ux58="1"] body:has(#navigator-process) #app .optional-fields :is(input,textarea) {
  padding: 12px 14px;
  border-color: #c9d7e7;
  border-radius: 9px;
  font-size: 14px;
}
html[data-mdd-ux58="1"] body:has(#navigator-process) #app :is(.drop-actions,.workbar,.material-bulk,.assistant-main-action,.assistant-shortcuts) {
  gap: 12px;
  flex-wrap: wrap;
}
html[data-mdd-ux58="1"] body:has(#navigator-process) #app .workbar {
  margin: 0;
  padding: 18px 20px;
  border: 1px solid var(--mdd-v4-line);
  border-radius: 12px;
  background: #fff;
}
html[data-mdd-ux58="1"] body:has(#navigator-process) #case-view > .tabs {
  margin: 0;
  padding: 10px;
  gap: 8px;
  border: 1px solid var(--mdd-v4-line);
  border-radius: 13px;
  background: #fff;
  flex-wrap: wrap;
}
html[data-mdd-ux58="1"] body:has(#navigator-process) #case-view > .tabs > button {
  min-height: 44px;
  padding: 10px 16px;
  border: 1px solid transparent;
  border-radius: 9px;
  font-size: 13px;
  font-weight: 600;
  line-height: 1.5;
  white-space: normal;
}
html[data-mdd-ux58="1"] body:has(#navigator-process) #case-view > .tabs > button[aria-selected="true"] {
  background: var(--mdd-v4-blue);
  border-color: var(--mdd-v4-blue);
  color: #fff;
}
html[data-mdd-ux58="1"] body:has(#navigator-process) #app .summary-card {
  padding: 22px;
  border-radius: 14px;
  border-color: var(--mdd-v4-line);
  box-shadow: var(--mdd-v4-shadow);
  border-top: 4px solid #c8ddf6;
}
html[data-mdd-ux58="1"] body:has(#navigator-process) #app .summary-card h3 {
  font-size: 12px;
  letter-spacing: .02em;
}
html[data-mdd-ux58="1"] body:has(#navigator-process) #app .summary-card p {
  font-size: 13px;
  line-height: 1.7;
}
html[data-mdd-ux58="1"] body:has(#navigator-process) #assistant-progress {
  padding: 18px 20px;
  margin: 18px 0;
  border: 1px solid #c8ddf6;
  border-left: 4px solid var(--mdd-v4-blue);
  border-radius: 12px;
  font-size: 13px;
  line-height: 1.75;
  background: #f3f8ff;
}
html[data-mdd-ux58="1"] body:has(#navigator-process) #assistant-action-status {
  font-size: 13px;
  line-height: 1.7;
  margin: 16px 0;
}
html[data-mdd-ux58="1"] body:has(#navigator-process) #app :is(.material-filters,.package-grid) {
  gap: 18px;
}
html[data-mdd-ux58="1"] body:has(#navigator-process) #app :is(.case-card,.package-card) {
  padding: 22px;
  border-radius: 12px;
  border-color: var(--mdd-v4-line);
}
html[data-mdd-ux58="1"] body:has(#navigator-process) #app :is(.mdd-summary-detail,.compact-detail,#assistant-history-panel) > summary {
  padding-block: 12px;
  font-size: 13px;
  font-weight: 600;
  line-height: 1.65;
}

/* Linx: white task navigation, pale-blue active state and separated conversion/update workspaces. */
html[data-mdd-ux58="1"] body:has(#convertWorkspace) .topbar {
  min-height: 86px;
  height: auto;
  padding: 20px 32px;
  background: #fff;
  border-bottom: 1px solid var(--mdd-v4-line);
  gap: 20px;
  flex-wrap: wrap;
}
html[data-mdd-ux58="1"] body:has(#convertWorkspace) .header-meta {
  gap: 12px;
  flex-wrap: wrap;
  font-size: 13px;
}
html[data-mdd-ux58="1"] body:has(#convertWorkspace) .workspace-tabs {
  max-width: 1360px;
  margin: 24px auto 18px;
  padding: 8px;
  gap: 10px;
  border: 1px solid var(--mdd-v4-line);
  border-radius: 14px;
  background: #fff;
}
html[data-mdd-ux58="1"] body:has(#convertWorkspace) .workspace-tabs > button {
  min-height: 72px;
  padding: 14px 20px;
  border-radius: 10px;
  font-size: 15px;
  line-height: 1.5;
  white-space: normal;
}
html[data-mdd-ux58="1"] body:has(#convertWorkspace) .workspace-tabs > button[aria-selected="true"] {
  background: var(--mdd-v4-blue);
  border-color: var(--mdd-v4-blue);
  color: #fff;
}
html[data-mdd-ux58="1"] body:has(#convertWorkspace) .workspace-tabs > button[aria-selected="true"] small {
  color: #e3efff;
}
html[data-mdd-ux58="1"] body:has(#convertWorkspace) .manual-card {
  max-width: 1360px;
  margin: 0 auto 24px;
  padding: 20px 24px;
  border: 1px solid #c8ddf6;
  border-radius: 13px;
  background: #edf5ff;
  gap: 20px;
  flex-wrap: wrap;
}
html[data-mdd-ux58="1"] body:has(#convertWorkspace) #convertWorkspace {
  max-width: 1360px;
  margin: 0 auto 48px;
  grid-template-columns: 232px minmax(0,1fr);
  gap: 24px;
  align-items: start;
}
html[data-mdd-ux58="1"] body:has(#convertWorkspace) #convertWorkspace > .sidebar {
  background: #fff;
  color: var(--mdd-v4-ink);
  border: 1px solid var(--mdd-v4-line);
  border-radius: 16px;
  padding: 24px 16px;
  box-shadow: var(--mdd-v4-shadow);
}
html[data-mdd-ux58="1"] body:has(#convertWorkspace) .sidebar :is(.nav-label,.sidebar-note,.sidebar-footer) {
  color: var(--mdd-v4-muted);
  font-size: 12px;
  line-height: 1.75;
}
html[data-mdd-ux58="1"] body:has(#convertWorkspace) .sidebar .nav-link {
  padding: 15px 12px;
  margin-bottom: 8px;
  border-radius: 10px;
  color: #334155;
  gap: 12px;
  font-size: 13px;
}
html[data-mdd-ux58="1"] body:has(#convertWorkspace) .sidebar .nav-link small {
  color: var(--mdd-v4-muted);
  font-size: 12px;
  line-height: 1.6;
}
html[data-mdd-ux58="1"] body:has(#convertWorkspace) .sidebar .nav-link.current {
  background: #eaf3ff;
  color: var(--mdd-v4-blue);
  box-shadow: inset 3px 0 0 var(--mdd-v4-blue);
}
html[data-mdd-ux58="1"] body:has(#convertWorkspace) .sidebar .nav-link.current small {
  color: #526b88;
}
html[data-mdd-ux58="1"] body:has(#convertWorkspace) #main {
  min-width: 0;
  padding: 0;
}
html[data-mdd-ux58="1"] body:has(#convertWorkspace) #main .hero {
  padding: 28px;
  margin-bottom: 26px;
  border: 1px solid var(--mdd-v4-line);
  border-radius: 16px;
  background: #fff;
  box-shadow: var(--mdd-v4-shadow);
  grid-template-columns: minmax(0,1fr) minmax(230px,.65fr);
  gap: 24px;
}
html[data-mdd-ux58="1"] body:has(#convertWorkspace) #main .hero h1 {
  font-size: clamp(28px,2.7vw,36px);
  line-height: 1.25;
  letter-spacing: -.03em;
}
html[data-mdd-ux58="1"] body:has(#convertWorkspace) #main .hero-copy {
  font-size: 14px;
  line-height: 1.75;
}
html[data-mdd-ux58="1"] body:has(#convertWorkspace) :is(#main,#updateWorkspace) .card {
  padding: 26px;
  border: 1px solid var(--mdd-v4-line);
  border-radius: 16px;
  box-shadow: var(--mdd-v4-shadow);
  background: #fff;
}
html[data-mdd-ux58="1"] body:has(#convertWorkspace) :is(#main,#updateWorkspace) .section-heading {
  gap: 20px;
  flex-wrap: wrap;
  align-items: flex-start;
  margin-bottom: 20px;
}
html[data-mdd-ux58="1"] body:has(#convertWorkspace) :is(#main,#updateWorkspace) .section-heading h2 {
  font-size: 23px;
  line-height: 1.35;
}
html[data-mdd-ux58="1"] body:has(#convertWorkspace) :is(#main,#updateWorkspace) .section-block {
  margin-block: 30px;
}
html[data-mdd-ux58="1"] body:has(#convertWorkspace) #offerDropZone {
  padding: 26px;
  border-radius: 13px;
  border: 2px dashed #b8cfe9;
  background: #f7faff;
  gap: 20px;
}
html[data-mdd-ux58="1"] body:has(#convertWorkspace) :is(#main,#updateWorkspace) .field :is(input,select,textarea) {
  padding: 12px 14px;
  border-radius: 9px;
  border-color: #c9d7e7;
  font-family: inherit;
  font-size: 14px;
  line-height: 1.6;
}
html[data-mdd-ux58="1"] body:has(#convertWorkspace) :is(#main,#updateWorkspace) :is(.case-fields,.update-files) {
  gap: 20px;
}
html[data-mdd-ux58="1"] body:has(#convertWorkspace) :is(#main,#updateWorkspace) :is(.table-toolbar,.reference-toolbar,.actions) {
  gap: 12px;
  flex-wrap: wrap;
}
html[data-mdd-ux58="1"] body:has(#convertWorkspace) #updateWorkspace {
  max-width: 1360px;
  padding: 0 24px 48px;
  margin-inline: auto;
}
html[data-mdd-ux58="1"] body:has(#convertWorkspace) #updateWorkspace > .update-heading {
  padding: 28px 30px;
  background: #fff;
  border: 1px solid var(--mdd-v4-line);
  border-left: 6px solid var(--mdd-v4-blue);
  border-radius: 16px;
  margin-bottom: 24px;
}
html[data-mdd-ux58="1"] body:has(#convertWorkspace) #updateWorkspace .update-file-card {
  min-height: 260px;
  border-top: 4px solid #b8d3f4;
}
html[data-mdd-ux58="1"] body:has(#convertWorkspace) :is(#assistantProgress,#runnerStatus,#packageStatus,#updateMessage,#updateTransferSummary,#updateExportStatus) {
  font-size: 14px;
  line-height: 1.75;
  padding: 16px 18px;
  border-radius: 10px;
  margin-block: 16px;
}

/* Test 3: full process divided into strong, numbered work sections. */
html[data-mdd-ux58="1"] body:has(main.nt58.t3) main.nt58.t3 {
  max-width: 1320px;
  padding: 0 28px 64px;
  margin: 28px auto;
  color: var(--mdd-v4-ink);
}
html[data-mdd-ux58="1"] body:has(main.nt58.t3) .nt58-card {
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
}
html[data-mdd-ux58="1"] body:has(main.nt58.t3) .nt58-heading {
  padding: 28px 30px;
  border: 1px solid var(--mdd-v4-line);
  border-left: 6px solid var(--mdd-v4-blue);
  border-radius: 16px;
  background: #fff;
  box-shadow: var(--mdd-v4-shadow);
  gap: 22px;
  flex-wrap: wrap;
}
html[data-mdd-ux58="1"] body:has(main.nt58.t3) .nt58-heading p {
  font-size: 14px;
  line-height: 1.75;
}
html[data-mdd-ux58="1"] body:has(main.nt58.t3) #test-form {
  padding: 4px 0 24px;
}
html[data-mdd-ux58="1"] body:has(main.nt58.t3) .t3-step {
  padding: 20px 22px;
  margin: 30px 0 18px;
  border: 1px solid var(--mdd-v4-line);
  border-radius: 13px;
  background: #fff;
  gap: 16px;
  box-shadow: var(--mdd-v4-shadow);
}
html[data-mdd-ux58="1"] body:has(main.nt58.t3) .t3-step > span {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  background: var(--mdd-v4-blue);
  font-size: 15px;
}
html[data-mdd-ux58="1"] body:has(main.nt58.t3) .t3-step h2 {
  font-size: 20px;
  line-height: 1.4;
}
html[data-mdd-ux58="1"] body:has(main.nt58.t3) .t3-step p {
  font-size: 13px;
  line-height: 1.7;
}
html[data-mdd-ux58="1"] body:has(main.nt58.t3) .t3-choice-grid {
  grid-template-columns: repeat(auto-fit,minmax(240px,1fr));
  gap: 18px;
}
html[data-mdd-ux58="1"] body:has(main.nt58.t3) .t3-choice {
  padding: 22px;
  border: 1px solid var(--mdd-v4-line);
  border-radius: 14px;
  background: #fff;
  box-shadow: var(--mdd-v4-shadow);
  min-height: 160px;
}
html[data-mdd-ux58="1"] body:has(main.nt58.t3) .t3-choice:has(input:checked) {
  padding: 21px;
  border: 2px solid var(--mdd-v4-blue);
  background: #edf5ff;
}
html[data-mdd-ux58="1"] body:has(main.nt58.t3) .t3-choice strong {
  font-size: 14px;
  line-height: 1.5;
}
html[data-mdd-ux58="1"] body:has(main.nt58.t3) .t3-choice :is(p,small) {
  font-size: 13px;
  line-height: 1.7;
}
html[data-mdd-ux58="1"] body:has(main.nt58.t3) :is(#topic,#request) {
  padding: 13px 15px;
  border: 1px solid #c9d7e7;
  border-radius: 10px;
  font-size: 14px;
  line-height: 1.65;
}
html[data-mdd-ux58="1"] body:has(main.nt58.t3) .nt58-drop {
  padding: 28px;
  border: 2px dashed #b8cfe9;
  border-radius: 14px;
  background: #fff;
  margin-top: 24px;
}
html[data-mdd-ux58="1"] body:has(main.nt58.t3) .t3-engine-matrix {
  gap: 24px;
}
html[data-mdd-ux58="1"] body:has(main.nt58.t3) :is(.t3-engine-section,.t3-preview) {
  padding: 24px;
  border: 1px solid var(--mdd-v4-line);
  border-radius: 16px;
  background: #fff;
  box-shadow: var(--mdd-v4-shadow);
}
html[data-mdd-ux58="1"] body:has(main.nt58.t3) .nt58-engines {
  grid-template-columns: repeat(2,minmax(0,1fr));
  gap: 18px;
}
html[data-mdd-ux58="1"] body:has(main.nt58.t3) .t3-engine {
  padding: 20px;
  border-radius: 12px;
  background: #f8fafd;
}
html[data-mdd-ux58="1"] body:has(main.nt58.t3) .t3-engine:has(input:checked) {
  border-color: var(--mdd-v4-blue);
  background: #edf5ff;
}
html[data-mdd-ux58="1"] body:has(main.nt58.t3) :is(.t3-guidance,.t3-switch,.nt58-settings) {
  padding: 22px;
  border: 1px solid #c8ddf6;
  border-radius: 13px;
  background: #f0f6ff;
  gap: 16px;
}
html[data-mdd-ux58="1"] body:has(main.nt58.t3) :is(.nt58-actions,.nt58-result-heading,.t3-preview-header) {
  gap: 14px;
  flex-wrap: wrap;
}
html[data-mdd-ux58="1"] body:has(main.nt58.t3) :is(#batch-status,#matrix-summary,.t3-progress) {
  font-size: 14px;
  line-height: 1.75;
  padding: 14px 18px;
  border-left: 4px solid var(--mdd-v4-blue);
  border-radius: 9px;
  margin-block: 16px;
}

/* Models: model and reasoning settings remain complete in stage cards. */
html[data-mdd-ux58="1"] body:has(main > #content[aria-busy]) main {
  max-width: 1320px;
  margin: 32px auto;
  padding: 0 28px 64px;
}
html[data-mdd-ux58="1"] body:has(main > #content[aria-busy]) main > h1 {
  font-size: 32px;
  margin: 10px 0 12px;
}
html[data-mdd-ux58="1"] body:has(main > #content[aria-busy]) main > .intro {
  font-size: 14px;
  line-height: 1.75;
  max-width: 900px;
  margin-bottom: 26px;
}
html[data-mdd-ux58="1"] body:has(main > #content[aria-busy]) #content .rule {
  padding: 20px 24px;
  border: 1px solid #c8ddf6;
  border-left: 5px solid var(--mdd-v4-blue);
  border-radius: 13px;
  background: #edf5ff;
  font-size: 14px;
}
html[data-mdd-ux58="1"] body:has(main > #content[aria-busy]) #content .status {
  padding: 18px 22px;
  border: 1px solid var(--mdd-v4-line);
  border-radius: 12px;
  background: #fff;
  gap: 16px;
  flex-wrap: wrap;
  font-size: 13px;
}
html[data-mdd-ux58="1"] body:has(main > #content[aria-busy]) #content .stages {
  grid-template-columns: repeat(2,minmax(0,1fr));
  gap: 24px;
  align-items: start;
}
html[data-mdd-ux58="1"] body:has(main > #content[aria-busy]) #content .stage {
  grid-template-columns: minmax(0,1fr);
  gap: 20px;
  padding: 26px;
  border: 1px solid var(--mdd-v4-line);
  border-top: 5px solid #b8d3f4;
  border-radius: 16px;
  background: #fff;
  box-shadow: var(--mdd-v4-shadow);
}
html[data-mdd-ux58="1"] body:has(main > #content[aria-busy]) #content .stage > div:first-child {
  padding-bottom: 18px;
  border-bottom: 1px solid var(--mdd-v4-line);
}
html[data-mdd-ux58="1"] body:has(main > #content[aria-busy]) #content .stage h2 {
  font-size: 19px;
  line-height: 1.4;
}
html[data-mdd-ux58="1"] body:has(main > #content[aria-busy]) #content .stage p {
  font-size: 13px;
  line-height: 1.75;
}
html[data-mdd-ux58="1"] body:has(main > #content[aria-busy]) #content .stage :is(select,input[type="password"]) {
  padding: 12px 14px;
  border: 1px solid #c9d7e7;
  border-radius: 9px;
  font-family: inherit;
  font-size: 14px;
}
html[data-mdd-ux58="1"] body:has(main > #content[aria-busy]) #content .stage .effort-detail {
  min-height: 0;
  font-size: 13px;
  line-height: 1.7;
  padding: 12px 14px;
  border-radius: 9px;
  background: #f4f7fb;
}
html[data-mdd-ux58="1"] body:has(main > #content[aria-busy]) #content .savebar {
  padding: 20px 22px;
  margin-top: 24px;
  background: #fff;
  border: 1px solid var(--mdd-v4-line);
  border-radius: 13px;
  box-shadow: var(--mdd-v4-shadow);
  gap: 16px;
}
html[data-mdd-ux58="1"] body:has(main > #content[aria-busy]) #content .login {
  padding: 30px;
  border-radius: 16px;
  border: 1px solid var(--mdd-v4-line);
  box-shadow: var(--mdd-v4-shadow);
}

/* Administration and accounts: full lists, filters, forms and dialogs with a clearer hierarchy. */
html[data-mdd-ux58="1"] body:has(main#admin.admin-center) main.admin-center,
html[data-mdd-ux58="1"] body:has(#accounts57) main.admin-center {
  max-width: 1360px;
  padding: 32px 28px 64px;
  font-family: inherit;
}
html[data-mdd-ux58="1"] body:has(main#admin.admin-center) .admin-heading,
html[data-mdd-ux58="1"] body:has(#accounts57) .admin-heading {
  padding: 28px 30px;
  border: 1px solid var(--mdd-v4-line);
  border-left: 6px solid var(--mdd-v4-blue);
  border-radius: 16px;
  background: #fff;
  box-shadow: var(--mdd-v4-shadow);
  gap: 22px;
  flex-wrap: wrap;
}
html[data-mdd-ux58="1"] body:has(main#admin.admin-center) .admin-tabs,
html[data-mdd-ux58="1"] body:has(#accounts57) .admin-tabs {
  gap: 10px;
  flex-wrap: wrap;
  margin: 22px 0;
  padding: 8px;
  border: 1px solid var(--mdd-v4-line);
  border-radius: 13px;
  background: #fff;
}
html[data-mdd-ux58="1"] body:has(main#admin.admin-center) .admin-tabs > :is(button,a),
html[data-mdd-ux58="1"] body:has(#accounts57) .admin-tabs > :is(button,a) {
  min-height: 44px;
  padding: 11px 16px;
  border: 1px solid transparent;
  border-radius: 9px;
  font-size: 13px;
  line-height: 1.55;
  white-space: normal;
}
html[data-mdd-ux58="1"] body:has(main#admin.admin-center) .admin-tabs > :is(button,a)[aria-current="page"],
html[data-mdd-ux58="1"] body:has(#accounts57) .admin-tabs > :is(button,a)[aria-current="page"] {
  background: var(--mdd-v4-blue);
  border-color: var(--mdd-v4-blue);
  color: #fff;
}
html[data-mdd-ux58="1"] body:has(main#admin.admin-center) .admin-stats {
  gap: 20px;
  margin-block: 24px;
}
html[data-mdd-ux58="1"] body:has(main#admin.admin-center) .admin-stats > div {
  padding: 24px;
  border: 1px solid var(--mdd-v4-line);
  border-top: 4px solid #b8d3f4;
  border-radius: 14px;
  background: #fff;
  box-shadow: var(--mdd-v4-shadow);
}
html[data-mdd-ux58="1"] body:has(main#admin.admin-center) .admin-stats strong {
  font-size: 34px;
  font-weight: 600;
  line-height: 1.35;
}
html[data-mdd-ux58="1"] body:has(main#admin.admin-center) .admin-card {
  padding: 26px;
  border: 1px solid var(--mdd-v4-line);
  border-radius: 16px;
  box-shadow: var(--mdd-v4-shadow);
  margin-block: 24px;
}
html[data-mdd-ux58="1"] body:has(main#admin.admin-center) :is(.admin-toolbar,.user-toolbar,.admin-detail-heading,.admin-actions,.case-management-actions,.user-buttons),
html[data-mdd-ux58="1"] body:has(#accounts57) :is(.admin-toolbar,.user-toolbar,.admin-detail-heading,.admin-actions,.case-management-actions,.user-buttons) {
  gap: 12px;
  flex-wrap: wrap;
}
html[data-mdd-ux58="1"] body:has(main#admin.admin-center) .admin-toolbar form {
  gap: 10px;
  flex-wrap: wrap;
}
html[data-mdd-ux58="1"] body:has(main#admin.admin-center) .admin-case {
  padding: 22px;
  border: 1px solid var(--mdd-v4-line);
  border-radius: 13px;
  gap: 22px;
  background: #fff;
}
html[data-mdd-ux58="1"] body:has(main#admin.admin-center) .admin-audit-filter {
  grid-template-columns: repeat(3,minmax(0,1fr));
  gap: 18px;
  padding: 22px;
  border: 1px solid var(--mdd-v4-line);
  border-radius: 13px;
  background: #f8fafd;
}
html[data-mdd-ux58="1"] body:has(main#admin.admin-center) .admin-center :is(input:not([type="checkbox"]):not([type="radio"]):not([type="hidden"]),select,textarea),
html[data-mdd-ux58="1"] body:has(#accounts57) .admin-center :is(input:not([type="checkbox"]):not([type="radio"]):not([type="hidden"]),select,textarea) {
  padding: 12px 14px;
  border-color: #c9d7e7;
  border-radius: 9px;
  font-family: inherit;
  font-size: 14px;
  line-height: 1.6;
}
html[data-mdd-ux58="1"] body:has(#accounts57) .user-manager57 {
  font-family: inherit;
  color: var(--mdd-v4-ink);
}
html[data-mdd-ux58="1"] body:has(#accounts57) .user-toolbar {
  padding: 20px 22px;
  border: 1px solid var(--mdd-v4-line);
  border-radius: 13px;
  background: #fff;
}
html[data-mdd-ux58="1"] body:has(#accounts57) .user-stats {
  padding: 16px 20px;
  border: 1px solid #c8ddf6;
  border-radius: 12px;
  background: #edf5ff;
  gap: 20px;
  flex-wrap: wrap;
  font-size: 13px;
}
html[data-mdd-ux58="1"] body:has(#accounts57) .user-list {
  grid-template-columns: repeat(2,minmax(0,1fr));
  gap: 24px;
}
html[data-mdd-ux58="1"] body:has(#accounts57) .user-manager57 .user-row {
  grid-template-columns: minmax(0,1fr);
  gap: 18px;
  padding: 26px;
  border: 1px solid var(--mdd-v4-line);
  border-top: 4px solid #b8d3f4;
  border-radius: 16px;
  background: #fff;
  box-shadow: var(--mdd-v4-shadow);
}
html[data-mdd-ux58="1"] body:has(#accounts57) .user-row h3 {
  font-size: 20px;
  line-height: 1.4;
  overflow-wrap: anywhere;
}
html[data-mdd-ux58="1"] body:has(#accounts57) .user-row .user-buttons {
  padding-top: 18px;
  border-top: 1px solid var(--mdd-v4-line);
}
html[data-mdd-ux58="1"] body:has(#accounts57) .user-dialog57 {
  padding: 30px;
  border: 1px solid var(--mdd-v4-line);
  border-radius: 18px;
  font-family: inherit;
  box-shadow: 0 24px 80px rgba(15,23,42,.2);
}
html[data-mdd-ux58="1"] body:has(main#admin.admin-center) :is(.admin-confirm,.admin-login) {
  padding: 30px;
  border: 1px solid var(--mdd-v4-line);
  border-radius: 16px;
  background: #fff;
  box-shadow: var(--mdd-v4-shadow);
}

/* Original converter support documents: full content with a distinct document/card layout. */
html[data-mdd-ux58="1"] body:has(main #krok-8) main,
html[data-mdd-ux58="1"] body:has(main #start[href^="mdd-linx58-2:"]) main,
html[data-mdd-ux58="1"] body:has(main #offerUploadWindowFile) main,
html[data-mdd-ux58="1"] body:has(main #download) main {
  max-width: 1000px;
  margin: 40px auto 64px;
  padding: 34px 38px;
  border: 1px solid var(--mdd-v4-line);
  border-top: 6px solid var(--mdd-v4-blue);
  border-radius: 18px;
  background: #fff;
  box-shadow: var(--mdd-v4-shadow);
  font-family: inherit;
  color: var(--mdd-v4-ink);
}
html[data-mdd-ux58="1"] body:has(main #krok-8) main h1,
html[data-mdd-ux58="1"] body:has(main #start[href^="mdd-linx58-2:"]) main h1,
html[data-mdd-ux58="1"] body:has(main #offerUploadWindowFile) main h1,
html[data-mdd-ux58="1"] body:has(main #download) main h1 {
  font-size: clamp(27px,2.5vw,34px);
  line-height: 1.3;
  letter-spacing: -.025em;
  margin-bottom: 20px;
}
html[data-mdd-ux58="1"] body:has(main #krok-8) main p,
html[data-mdd-ux58="1"] body:has(main #start[href^="mdd-linx58-2:"]) main p,
html[data-mdd-ux58="1"] body:has(main #offerUploadWindowFile) main p,
html[data-mdd-ux58="1"] body:has(main #download) main p {
  font-size: 14px;
  line-height: 1.8;
}
html[data-mdd-ux58="1"] body:has(main #start[href^="mdd-linx58-2:"]) :is(#status,#offerUploadWindowStatus),
html[data-mdd-ux58="1"] body:has(main #offerUploadWindowFile) :is(#status,#offerUploadWindowStatus),
html[data-mdd-ux58="1"] body:has(main #download) :is(#status,#offerUploadWindowStatus) {
  padding: 20px;
  margin-block: 22px;
  border: 1px solid #c8ddf6;
  border-left: 4px solid var(--mdd-v4-blue);
  border-radius: 12px;
  background: #edf5ff;
  font-size: 14px;
  line-height: 1.8;
}
html[data-mdd-ux58="1"] body:has(main #start[href^="mdd-linx58-2:"]) main :is(a.button,#download),
html[data-mdd-ux58="1"] body:has(main #download) main :is(a.button,#download) {
  padding: 13px 20px;
  border: 1px solid var(--mdd-v4-blue);
  border-radius: 10px;
  background: var(--mdd-v4-blue);
  color: #fff;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.6;
}
html[data-mdd-ux58="1"] body:has(main #offerUploadWindowFile) #offerUploadWindowFile {
  padding: 18px;
  margin-block: 12px;
  border: 2px dashed #b8cfe9;
  border-radius: 12px;
  background: #f7faff;
  font-family: inherit;
  font-size: 14px;
  max-width: 100%;
  box-sizing: border-box;
}
html[data-mdd-ux58="1"] body:has(main #krok-8) main:not([hidden]) {
  max-width: 1320px;
  padding: 32px;
  display: grid;
  grid-template-columns: repeat(2,minmax(0,1fr));
  gap: 22px;
}
html[data-mdd-ux58="1"] body:has(main #krok-8) main > :not(.step) {
  grid-column: 1 / -1;
}
html[data-mdd-ux58="1"] body:has(main #krok-8) main > .step {
  padding: 24px;
  margin: 0;
  border: 1px solid var(--mdd-v4-line);
  border-radius: 14px;
  background: #f8fafd;
  gap: 18px;
  align-items: start;
}
html[data-mdd-ux58="1"] body:has(main #krok-8) main .step h2 {
  font-size: 19px;
  line-height: 1.45;
}
html[data-mdd-ux58="1"] body:has(main #krok-8) main .number {
  border-radius: 10px;
  background: var(--mdd-v4-blue);
  color: #fff;
}

/* Responsive layout: same source order, all fields and controls retained. */
@media (max-width: 1050px) {
  html[data-mdd-ux58="1"] body:has(#navigator-process) #home-view:not([hidden]) {
    grid-template-columns: minmax(0,1fr);
  }
}
@media (max-width: 1050px) {
  html[data-mdd-ux58="1"] body:has(#navigator-process) #case-view:not([hidden]) {
    grid-template-columns: minmax(0,1fr);
  }
}
@media (max-width: 1050px) {
  html[data-mdd-ux58="1"] body:has(#navigator-process) #case-view > :is(.assistant-panel,#summary) {
    grid-column: 1 / -1;
  }
}
@media (max-width: 1050px) {
  html[data-mdd-ux58="1"] body:has(#navigator-process) #case-view > #summary {
    grid-template-columns: repeat(2,minmax(0,1fr));
  }
}
@media (max-width: 1050px) {
  html[data-mdd-ux58="1"] body:has(#convertWorkspace) #convertWorkspace {
    grid-template-columns: minmax(0,1fr);
    padding-inline: 20px;
  }
}
@media (max-width: 1050px) {
  html[data-mdd-ux58="1"] body:has(#convertWorkspace) .sidebar nav:not([hidden]) {
    display: grid;
    grid-template-columns: repeat(2,minmax(0,1fr));
    gap: 10px;
  }
}
@media (max-width: 1050px) {
  html[data-mdd-ux58="1"] body:has(#convertWorkspace) #main .hero {
    grid-template-columns: minmax(0,1fr);
  }
}
@media (max-width: 1050px) {
  html[data-mdd-ux58="1"] body:has(main#admin.admin-center) .admin-audit-filter {
    grid-template-columns: repeat(2,minmax(0,1fr));
  }
}
@media (max-width: 700px) {
  html[data-mdd-ux58="1"] body:has(#navigator-process) main,
  html[data-mdd-ux58="1"] body:has(main > #content[aria-busy]) main {
    padding-inline: 16px;
  }
}
@media (max-width: 700px) {
  html[data-mdd-ux58="1"] body:has(main#admin.admin-center) main.admin-center,
  html[data-mdd-ux58="1"] body:has(#accounts57) main.admin-center {
    padding-inline: 16px;
  }
}
@media (max-width: 700px) {
  html[data-mdd-ux58="1"] body:has(#navigator-process) #case-view > #summary {
    grid-template-columns: minmax(0,1fr);
  }
}
@media (max-width: 700px) {
  html[data-mdd-ux58="1"] body:has(main > #content[aria-busy]) #content .stages {
    grid-template-columns: minmax(0,1fr);
  }
}
@media (max-width: 700px) {
  html[data-mdd-ux58="1"] body:has(#accounts57) .user-list {
    grid-template-columns: minmax(0,1fr);
  }
}
@media (max-width: 700px) {
  html[data-mdd-ux58="1"] body:has(main#admin.admin-center) .admin-audit-filter {
    grid-template-columns: minmax(0,1fr);
  }
}
@media (max-width: 700px) {
  html[data-mdd-ux58="1"] body:has(main.nt58.t3) .nt58-engines {
    grid-template-columns: minmax(0,1fr);
  }
}
@media (max-width: 700px) {
  html[data-mdd-ux58="1"] body:has(main.nt58.t3) .t3-choice-grid {
    grid-template-columns: minmax(0,1fr);
  }
}
@media (max-width: 700px) {
  html[data-mdd-ux58="1"] body:has(main.nt58.t3) main.nt58.t3 {
    padding-inline: 16px;
  }
}
@media (max-width: 700px) {
  html[data-mdd-ux58="1"] body:has(main #krok-8) main:not([hidden]) {
    grid-template-columns: minmax(0,1fr);
    margin: 24px 16px;
    padding: 22px;
  }
}
@media (max-width: 700px) {
  html[data-mdd-ux58="1"] body:has(main #start[href^="mdd-linx58-2:"]) main,
  html[data-mdd-ux58="1"] body:has(main #offerUploadWindowFile) main,
  html[data-mdd-ux58="1"] body:has(main #download) main {
    margin: 24px 16px;
    padding: 24px;
  }
}
@media (max-width: 700px) {
  html[data-mdd-ux58="1"] body:has(#navigator-process) .section-heading,
  html[data-mdd-ux58="1"] body:has(#convertWorkspace) .section-heading {
    gap: 14px;
  }
}

/* Sidebar note follows the white, light-gray and blue MDD/Linx palette. */
html[data-mdd-ux58="1"] body:has(#convertWorkspace) .sidebar .sidebar-note {
  background: #f4f7fb;
  border: 1px solid var(--mdd-v4-line);
  color: #334155;
}
html[data-mdd-ux58="1"] body:has(#convertWorkspace) .sidebar .sidebar-note p {
  color: var(--mdd-v4-muted);
}

/* HOME VISUAL REFERENCE ONLY: accepted root Sites proposal.
   Apply after v04 body layer, gated by data-mdd-ux=1.
   Keeps native DOM/content/handlers/module and test tiles.
   Deliberately excludes root demo renderer and header/account visibility rules. */
html[data-mdd-ux58="1"] {--linx-ink:#0f172a;--linx-muted:#64748b;--linx-blue:#0057b8;--linx-card-bg:#fff;--linx-card-line:#dbe5f0;--linx-card-radius:14px;--linx-card-shadow:0 2px 8px rgba(15,23,42,.035);--linx-icon-bg:#eef6ff;--linx-icon-line:#d4e8ff;--linx-row-line:#e7ecf2;--linx-row-radius:11px;--linx-control-height:40px;--linx-control-radius:8px;--linx-control-font:13px;--linx-control-gap:8px;--linx-control-border:#e2e8f0;--linx-control-bg:#f7f8fa;--linx-control-ink:#334155;--linx-control-blue:#0057b8;}

/* Reference source: assets/refinement.css */
html[data-mdd-ux58="1"] #mdd-home-view{margin-bottom:0}
html[data-mdd-ux58="1"] #mdd-home-view .hero{padding:36px 0 38px;gap:68px;grid-template-columns:minmax(0,1fr) 435px}
html[data-mdd-ux58="1"] #mdd-home-view .hero h1{font-size:calc(clamp(40px,4.3vw,56px) * var(--font-scale,1));font-weight:700;line-height:1.09;letter-spacing:-1.6px;margin:18px 0 21px}
html[data-mdd-ux58="1"] #mdd-home-view .hero-copy>p{font-size:calc(17px * var(--font-scale,1));line-height:1.65;max-width:490px;margin-bottom:20px}
html[data-mdd-ux58="1"] #mdd-home-view .hero-copy>.eyebrow{font-size:calc(11px * var(--font-scale,1));letter-spacing:1.3px}
html[data-mdd-ux58="1"] #mdd-home-view .hero-copy .intro-link{font-size:calc(13px * var(--font-scale,1));font-weight:500;min-height:32px}
html[data-mdd-ux58="1"] #mdd-home-view .connect-card{border-radius:14px;padding:24px 26px;border-color:#b7d1f2;background:linear-gradient(115deg,#eaf3ff,#fff);box-shadow:0 5px 20px #0759bf05}
html[data-mdd-ux58="1"] #mdd-home-view .brand-connection{margin-bottom:18px}
html[data-mdd-ux58="1"] #mdd-home-view .connection-brand{width:85px;height:53px;border-radius:10px}
html[data-mdd-ux58="1"] #mdd-home-view .connection-brand.chatgpt{width:53px}
html[data-mdd-ux58="1"] #mdd-home-view .connection-caption{font-size:calc(12px * var(--font-scale,1));line-height:1.5}
html[data-mdd-ux58="1"] #mdd-home-view .connect-card h2{font-size:calc(22px * var(--font-scale,1));line-height:1.3;font-weight:600;letter-spacing:-.5px;margin-bottom:10px}
html[data-mdd-ux58="1"] #mdd-home-view .connect-card>p{font-size:calc(13px * var(--font-scale,1));line-height:1.7}
html[data-mdd-ux58="1"] #mdd-home-view .flow-line{font-size:calc(12px * var(--font-scale,1));line-height:1.8;margin:13px 0}
html[data-mdd-ux58="1"] #mdd-home-view .compact-how{font-size:calc(13px * var(--font-scale,1));line-height:1.65}
html[data-mdd-ux58="1"] #mdd-home-view .compact-how summary{font-size:calc(13px * var(--font-scale,1));min-height:36px;display:flex;align-items:center;padding:8px 11px;border-color:#cfdef2;border-radius:7px;cursor:pointer}
html[data-mdd-ux58="1"] #mdd-home-view .compact-how summary:after{content:'⌄';margin-left:auto;color:#0057b8}
html[data-mdd-ux58="1"] #mdd-home-view .compact-how p,
html[data-mdd-ux58="1"] #mdd-home-view .compact-how li{font-size:calc(13px * var(--font-scale,1))}
html[data-mdd-ux58="1"] #mdd-home-view .connect-actions{gap:15px;margin-top:14px}
html[data-mdd-ux58="1"] #mdd-home-view .button{min-height:42px;font-size:calc(13px * var(--font-scale,1));padding:10px 15px;font-weight:600}
html[data-mdd-ux58="1"] #mdd-home-view .connect-actions .text-link{font-size:calc(12px * var(--font-scale,1));line-height:1.6}
html[data-mdd-ux58="1"] #mdd-home-view .test-note{display:block;font-size:calc(11px * var(--font-scale,1));line-height:1.6;margin-top:12px;color:#64748b}
html[data-mdd-ux58="1"] #mdd-home-view .section-heading{margin:0 0 18px;align-items:center}
html[data-mdd-ux58="1"] #mdd-home-view .section-heading h2{font-size:calc(20px * var(--font-scale,1));line-height:1.4;font-weight:600;letter-spacing:-.35px;margin-bottom:5px}
html[data-mdd-ux58="1"] #mdd-home-view .section-heading p{font-size:calc(13px * var(--font-scale,1));line-height:1.6;color:#5e738e;margin:0}
html[data-mdd-ux58="1"] #mdd-home-view .section-heading>.text-link{font-size:calc(12px * var(--font-scale,1));flex:none;margin-left:18px}
html[data-mdd-ux58="1"] #mdd-home-view .module-grid{grid-template-columns:repeat(4,minmax(0,1fr));gap:15px;margin-bottom:13px}
html[data-mdd-ux58="1"] #mdd-home-view .module-tile{min-height:220px;display:flex;flex-direction:column;padding:21px 21px 19px;border-radius:12px;text-decoration:none;box-shadow:none;transition:background .16s,border-color .16s,box-shadow .16s;position:relative}
html[data-mdd-ux58="1"] #mdd-home-view .module-tile:hover{transform:none}
html[data-mdd-ux58="1"] #mdd-home-view .module-tile.available{background:#eff6ff;border:1px solid #b7d1f2;color:#283247}
html[data-mdd-ux58="1"] #mdd-home-view .module-tile.available:hover{background:#e8f2ff;border-color:#6d9edb;box-shadow:0 4px 16px #0c58b109}
html[data-mdd-ux58="1"] #mdd-home-view .module-tile.unavailable{background:#edf0f4;border:1px solid #dce3eb;opacity:1;color:#5f6e7f}
html[data-mdd-ux58="1"] #mdd-home-view .module-tile .tile-top{display:flex;justify-content:space-between;align-items:center;width:100%;margin-bottom:22px}
html[data-mdd-ux58="1"] #mdd-home-view .module-icon{height:25px;width:25px;margin:0;color:#245a8b}
html[data-mdd-ux58="1"] #mdd-home-view .module-icon svg{height:25px;width:25px}
html[data-mdd-ux58="1"] #mdd-home-view .module-number{font-size:calc(11px * var(--font-scale,1));font-weight:400;color:#6d819c}
html[data-mdd-ux58="1"] #mdd-home-view .module-tile h3{font-size:calc(16px * var(--font-scale,1));line-height:1.4;font-weight:600;letter-spacing:-.15px;min-height:23px;margin:0 0 9px;color:inherit}
html[data-mdd-ux58="1"] #mdd-home-view .module-tile p{font-size:calc(13px * var(--font-scale,1));line-height:1.65;margin:0 0 18px;max-width:none;color:#526b86}
html[data-mdd-ux58="1"] #mdd-home-view .unavailable p,
html[data-mdd-ux58="1"] #mdd-home-view .unavailable .module-icon,
html[data-mdd-ux58="1"] #mdd-home-view .unavailable .module-number{color:#64748b}
html[data-mdd-ux58="1"] #mdd-home-view .tile-footer{margin-top:auto;padding-top:4px;display:flex;justify-content:space-between;align-items:center;width:100%}
html[data-mdd-ux58="1"] #mdd-home-view .module-tile .status{font-size:calc(11px * var(--font-scale,1));line-height:1.45;padding:4px 7px;border-radius:5px;font-weight:500;white-space:nowrap}
html[data-mdd-ux58="1"] #mdd-home-view .module-tile.available .status{background:#d8efe5;color:#206a49}
html[data-mdd-ux58="1"] #mdd-home-view .module-tile.unavailable .status{background:#e0e5ec;color:#566879}
html[data-mdd-ux58="1"] #mdd-home-view .tile-arrow{font-size:calc(17px * var(--font-scale,1));font-weight:400;color:#537d9e}
html[data-mdd-ux58="1"] #mdd-home-view .section-footnote{font-size:calc(12px * var(--font-scale,1));line-height:1.6;margin:13px 0 0;color:#5e738e}
html[data-mdd-ux58="1"] .current-mode #mdd-home-view .module-tile h3{font-size:calc(15px * var(--font-scale,1))}
html[data-mdd-ux58="1"] .current-mode #mdd-home-view .module-tile p{font-size:calc(12px * var(--font-scale,1))}
html[data-mdd-ux58="1"] .current-mode #mdd-home-view .module-tile .status{font-size:calc(10px * var(--font-scale,1))}
html[data-mdd-ux58="1"] .current-mode #mdd-home-view .module-tile{min-height:236px}
@media(max-width:1100px){
html[data-mdd-ux58="1"] #mdd-home-view .hero{grid-template-columns:minmax(0,1fr) 400px;gap:35px}
html[data-mdd-ux58="1"] #mdd-home-view .hero h1{font-size:calc(46px * var(--font-scale,1))}
html[data-mdd-ux58="1"] #mdd-home-view .module-tile{padding:19px 17px;min-height:225px}
html[data-mdd-ux58="1"] #mdd-home-view .module-tile h3{font-size:calc(15px * var(--font-scale,1))}
}
@media(max-width:850px){
html[data-mdd-ux58="1"] #mdd-home-view .hero{grid-template-columns:1fr 360px;gap:26px}
html[data-mdd-ux58="1"] #mdd-home-view .hero h1{font-size:calc(40px * var(--font-scale,1))}
html[data-mdd-ux58="1"] #mdd-home-view .hero-copy>p{font-size:calc(15px * var(--font-scale,1))}
html[data-mdd-ux58="1"] #mdd-home-view .connect-card{padding:22px}
html[data-mdd-ux58="1"] #mdd-home-view .connection-caption{font-size:calc(11px * var(--font-scale,1))}
html[data-mdd-ux58="1"] #mdd-home-view .module-grid{grid-template-columns:1fr 1fr}
html[data-mdd-ux58="1"] #mdd-home-view .module-tile{min-height:210px;padding:21px}
html[data-mdd-ux58="1"] #mdd-home-view .module-tile h3{font-size:calc(16px * var(--font-scale,1))}
html[data-mdd-ux58="1"] #mdd-home-view .module-tile p{font-size:calc(13px * var(--font-scale,1))}
html[data-mdd-ux58="1"] #mdd-home-view .section-heading{align-items:flex-start;gap:8px}
html[data-mdd-ux58="1"] #mdd-home-view .section-heading>.text-link{margin-left:0}
}
@media(max-width:650px){
html[data-mdd-ux58="1"] #mdd-home-view .hero{grid-template-columns:1fr;gap:27px;padding:20px 0 28px}
html[data-mdd-ux58="1"] #mdd-home-view .hero h1{font-size:calc(42px * var(--font-scale,1));letter-spacing:-1.3px;margin:16px 0 19px}
html[data-mdd-ux58="1"] #mdd-home-view .hero-copy>p{font-size:calc(16px * var(--font-scale,1));max-width:460px}
html[data-mdd-ux58="1"] #mdd-home-view .hero-copy>.eyebrow{font-size:calc(10px * var(--font-scale,1));letter-spacing:1px}
html[data-mdd-ux58="1"] #mdd-home-view .connect-card{max-width:none;padding:22px}
html[data-mdd-ux58="1"] #mdd-home-view .connect-card>p{font-size:calc(13px * var(--font-scale,1))}
html[data-mdd-ux58="1"] #mdd-home-view .connect-card h2{font-size:calc(22px * var(--font-scale,1))}
html[data-mdd-ux58="1"] #mdd-home-view .connection-caption{display:block;font-size:calc(11px * var(--font-scale,1))}
html[data-mdd-ux58="1"] #mdd-home-view .connect-actions{flex-direction:row;align-items:center}
html[data-mdd-ux58="1"] #mdd-home-view .section-heading{flex-direction:column;margin-bottom:16px}
html[data-mdd-ux58="1"] #mdd-home-view .section-heading h2{font-size:calc(19px * var(--font-scale,1))}
html[data-mdd-ux58="1"] #mdd-home-view .section-heading p{font-size:calc(12px * var(--font-scale,1))}
html[data-mdd-ux58="1"] #mdd-home-view .module-grid{grid-template-columns:1fr 1fr;gap:12px}
html[data-mdd-ux58="1"] #mdd-home-view .module-tile{min-height:231px;padding:18px 16px}
html[data-mdd-ux58="1"] #mdd-home-view .module-tile .tile-top{margin-bottom:20px}
html[data-mdd-ux58="1"] #mdd-home-view .module-tile h3{font-size:calc(15px * var(--font-scale,1))}
html[data-mdd-ux58="1"] #mdd-home-view .module-tile p{font-size:calc(12px * var(--font-scale,1));line-height:1.7}
html[data-mdd-ux58="1"] #mdd-home-view .module-tile .status{font-size:calc(10px * var(--font-scale,1));padding:4px 6px}
html[data-mdd-ux58="1"] #mdd-home-view .module-number{font-size:calc(10px * var(--font-scale,1))}
html[data-mdd-ux58="1"] #mdd-home-view .section-footnote{font-size:calc(11px * var(--font-scale,1));line-height:1.7}
}
@media(max-width:370px){
html[data-mdd-ux58="1"] #mdd-home-view .module-grid{grid-template-columns:1fr}
html[data-mdd-ux58="1"] #mdd-home-view .module-tile{min-height:204px}
html[data-mdd-ux58="1"] #mdd-home-view .module-tile p{font-size:calc(13px * var(--font-scale,1))}
}
html[data-mdd-ux58="1"] #mdd-home-view{font-size:calc(14px * var(--font-scale,1))}

/* Reference source: assets/linx-controls.css */
html[data-mdd-ux58="1"] #mdd-home-view .connect-actions .button:not([hidden]){

 display:inline-flex!important;align-items:center!important;justify-content:center!important;gap:var(--linx-control-gap)!important;

 height:var(--linx-control-height)!important;min-height:var(--linx-control-height)!important;padding:0 14px!important;

 border:1px solid var(--linx-control-border)!important;border-radius:var(--linx-control-radius)!important;

 background:var(--linx-control-bg)!important;color:var(--linx-control-ink)!important;

 font-family:Inter,-apple-system,BlinkMacSystemFont,'Segoe UI',sans-serif!important;

 font-size:calc(var(--linx-control-font) * var(--font-scale,1))!important;font-weight:500!important;line-height:20px!important;letter-spacing:0!important;

 text-decoration:none!important;white-space:nowrap;box-sizing:border-box;cursor:pointer;

 transition:background .12s ease,border-color .12s ease,color .12s ease,transform .08s ease!important;

}
html[data-mdd-ux58="1"] #mdd-home-view .connect-actions .button.primary{

 padding:0 18px!important;background:#0057b8!important;border-color:#0057b8!important;color:white!important;

}
html[data-mdd-ux58="1"] #mdd-home-view .connect-actions .button.primary:hover{background:#004a9e!important;border-color:#004a9e!important;color:white!important}

/* Reference source: assets/linx-surfaces.css */
html[data-mdd-ux58="1"] #mdd-home-view .module-grid{gap:16px}
html[data-mdd-ux58="1"] #mdd-home-view .module-tile{

 padding:22px;border-radius:var(--linx-card-radius);border:1px solid var(--linx-card-line);

 background:var(--linx-card-bg);box-shadow:var(--linx-card-shadow);color:var(--linx-ink);

 transition:transform .16s ease,border-color .16s ease,box-shadow .16s ease,background-color .16s ease;

}
html[data-mdd-ux58="1"] #mdd-home-view .module-tile.available{background:#fff;border-color:var(--linx-card-line);color:var(--linx-ink)}
html[data-mdd-ux58="1"] #mdd-home-view .module-tile.available:hover{background:#fff;border-color:#93c5fd;box-shadow:0 12px 28px rgba(15,23,42,.09);transform:translateY(-2px)}
html[data-mdd-ux58="1"] #mdd-home-view .module-tile .tile-top{align-items:flex-start;margin-bottom:16px}
html[data-mdd-ux58="1"] #mdd-home-view .module-icon{

 display:flex;align-items:center;justify-content:center;flex:0 0 64px;width:64px;height:64px;

 border:1px solid var(--linx-icon-line);border-radius:14px;background:var(--linx-icon-bg);color:var(--linx-blue);

}
html[data-mdd-ux58="1"] #mdd-home-view .module-icon svg{display:block;width:32px;height:32px}
html[data-mdd-ux58="1"] #mdd-home-view .module-number{font-size:calc(11px * var(--font-scale,1));color:var(--linx-muted);padding-top:3px}
html[data-mdd-ux58="1"] #mdd-home-view .module-tile h3{font-size:calc(16px * var(--font-scale,1));font-weight:600;line-height:1.3;letter-spacing:0;color:var(--linx-ink);margin:0 0 7px}
html[data-mdd-ux58="1"] #mdd-home-view .module-tile p{font-size:calc(13px * var(--font-scale,1));font-weight:400;line-height:1.55;color:var(--linx-muted);margin-bottom:18px}
html[data-mdd-ux58="1"] #mdd-home-view .module-tile.unavailable{background:#fff;border-color:var(--linx-card-line);color:var(--linx-muted);opacity:1}
html[data-mdd-ux58="1"] #mdd-home-view .module-tile.unavailable .module-icon{background:#f4f5f6;border-color:#e2e8f0;color:var(--linx-muted)}
html[data-mdd-ux58="1"] #mdd-home-view .module-tile.unavailable h3{color:#475569}
html[data-mdd-ux58="1"] #mdd-home-view .module-tile.unavailable p{color:var(--linx-muted)}
html[data-mdd-ux58="1"] #mdd-home-view .module-tile.unavailable .status{background:#f4f5f6;color:#64748b}
html[data-mdd-ux58="1"] #mdd-home-view .connect-card{

 background:#fff;border:1px solid var(--linx-card-line);border-radius:var(--linx-card-radius);box-shadow:var(--linx-card-shadow);

}
html[data-mdd-ux58="1"] #mdd-home-view .connect-card h2{color:var(--linx-ink)}
html[data-mdd-ux58="1"] #mdd-home-view .connect-card>p{color:var(--linx-muted)}
html[data-mdd-ux58="1"] #mdd-home-view .connection-brand{border-color:var(--linx-icon-line);background:var(--linx-icon-bg);border-radius:14px;box-shadow:none}
@media(max-width:650px){
html[data-mdd-ux58="1"] #mdd-home-view .module-tile{padding:18px}
html[data-mdd-ux58="1"] #mdd-home-view .module-icon{width:56px;height:56px;flex-basis:56px}
html[data-mdd-ux58="1"] #mdd-home-view .module-tile h3{font-size:calc(16px * var(--font-scale,1))}
html[data-mdd-ux58="1"] #mdd-home-view .module-tile p{font-size:calc(13px * var(--font-scale,1))}
}
@media(prefers-reduced-motion:reduce){
html[data-mdd-ux58="1"] #mdd-home-view .module-tile.available:hover{transform:none}
}

/* Required bridge over v04: root screenshot keeps the full two-column hero. */
html[data-mdd-ux58="1"] #mdd-home-view .hero {display:grid;grid-template-columns:minmax(0,1fr) 435px;align-items:center;gap:68px;padding:36px 0 38px;border:0;background:transparent;box-shadow:none;}
html[data-mdd-ux58="1"] #mdd-home-view .hero-copy {display:block;grid-column:auto;grid-row:auto;padding:0;border:0;background:transparent;box-shadow:none;}
html[data-mdd-ux58="1"] #mdd-home-view .hero-copy>h1 {font-size:calc(clamp(40px,4.3vw,56px) * var(--font-scale,1));font-weight:700;line-height:1.09;letter-spacing:-1.6px;margin:18px 0 21px;}
html[data-mdd-ux58="1"] #mdd-home-view .connect-card {display:block;grid-column:auto;grid-row:auto;width:auto;max-width:none;margin:0;}
html[data-mdd-ux58="1"] #mdd-home-view .module-grid {display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:16px;}
@media(max-width:1150px){html[data-mdd-ux58="1"] #mdd-home-view .hero {grid-template-columns:minmax(0,1fr) 400px;gap:35px;}}
@media(max-width:850px){html[data-mdd-ux58="1"] #mdd-home-view .hero {grid-template-columns:1fr 360px;gap:26px;}html[data-mdd-ux58="1"] #mdd-home-view .module-grid {grid-template-columns:1fr 1fr;}}
@media(max-width:650px){html[data-mdd-ux58="1"] #mdd-home-view .hero {grid-template-columns:1fr;gap:27px;padding:20px 0 28px;}html[data-mdd-ux58="1"] #mdd-home-view .hero-copy>h1 {font-size:42px;letter-spacing:-1.3px;margin:16px 0 19px;}}
@media(max-width:370px){html[data-mdd-ux58="1"] #mdd-home-view .module-grid {grid-template-columns:1fr;}}

/* Keep the accepted connection card spacing above former compact-workspace rules. */
html[data-mdd-ux58="1"] #mdd-home-view .connect-card>.brand-connection{margin:0 0 18px;}
html[data-mdd-ux58="1"] #mdd-home-view .connect-card>.flow-line{margin:13px 0;font-size:calc(12px * var(--font-scale,1));line-height:1.8;}
html[data-mdd-ux58="1"] #mdd-home-view .connect-card>.connect-actions{margin-top:14px;gap:15px;}
html[data-mdd-ux58="1"] #mdd-home-view .connect-card>.test-note{margin-top:12px;font-size:calc(11px * var(--font-scale,1));line-height:1.6;}
html[data-mdd-ux58="1"] #mdd-home-view .connect-card>.compact-how{font-size:calc(13px * var(--font-scale,1));line-height:1.65;}

/* Shared MDD 5.8 shell. Loaded after page styles. No business state is synthesized. */
[data-mdd-ui-shell58] {
 --mdd-shell-blue:#0057b8; --mdd-shell-ink:#283247; --mdd-shell-muted:#6c7e96;
 --mdd-shell-line:#dfe7f2; --mdd-shell-soft:#f5f8fc;
 box-sizing:border-box; position:relative; isolation:isolate; z-index:110;
 background:#fff; color:var(--mdd-shell-ink); border:0; border-bottom:1px solid var(--mdd-shell-line);
 font:400 13px/1.5 Inter,-apple-system,BlinkMacSystemFont,"Segoe UI",Arial,sans-serif;
}
[data-mdd-ui-shell58]:not([hidden]) { display:flex; align-items:center; justify-content:space-between; flex-wrap:wrap; gap:12px 20px; min-height:0; padding:14px max(24px,calc((100vw - 1280px)/2)); }
[data-mdd-ui-shell58][hidden],[data-mdd-ui-shell58] [hidden] { display:none!important; }
body.legacy-case > .site-header[data-mdd-ui-shell58] { display:none; }
[data-mdd-ui-shell58="navigator"],[data-mdd-ui-shell58="help"] { padding:0; }
[data-mdd-ui-shell58] > .header-inner { display:flex; flex-wrap:wrap; align-items:center; gap:12px 20px; width:100%; max-width:1328px; margin:0 auto; padding:14px 24px; }
[data-mdd-ui-shell58="panel"]:not([hidden]) { padding:14px 20px; border-radius:0; box-shadow:none; }
#mdd-work-panel > .panel-header[data-mdd-ui-shell58]:not([hidden]) { display:flex; align-items:center; flex-wrap:wrap; gap:12px 20px; padding:14px 20px; }
#mdd-work-panel > .panel-header[data-mdd-ui-shell58] > :is(.brand-logo,.header-title,[data-case-status],.local-return,#mdd58-executor-selector) { grid-area:auto; margin:0; }
#mdd-work-panel > .panel-header[data-mdd-ui-shell58] > #mdd58-executor-selector:not([hidden]) { display:contents; width:auto; flex-basis:auto; padding:0; border:0; }
#mdd-work-panel > .panel-header[data-mdd-ui-shell58] .mdd-ui-shell58-menu > .mdd58-executor-line { display:flex; flex-wrap:wrap; gap:10px; }
#mdd-work-panel > .panel-header[data-mdd-ui-shell58] .mdd-ui-shell58-menu .mdd58-executor-help { grid-area:auto; position:static; width:100%; margin:0; padding:0; }
#mdd-work-panel > .panel-header[data-mdd-ui-shell58] .mdd-ui-shell58-menu .mdd58-executor-help-panel { position:static; width:auto; max-width:100%; max-height:none; overflow:visible; }
[data-mdd-ui-shell58] :is(.brand,.site-brand) { display:flex; align-items:center; gap:16px; flex:0 1 310px; min-width:0; margin:0; font:600 13px/1.4 Inter,-apple-system,BlinkMacSystemFont,"Segoe UI",Arial,sans-serif; letter-spacing:0; }
[data-mdd-ui-shell58] :is(.brand,.site-brand) > span:last-child { max-width:180px; }
[data-mdd-ui-shell58] .brand :is(.logo,img),[data-mdd-ui-shell58] .site-brand img { flex:none; }
[data-mdd-ui-shell58] .brand .logo { width:80px; height:auto; min-height:30px; flex-basis:80px; overflow:visible; }
[data-mdd-ui-shell58] .brand .logo img { width:80px!important; height:auto!important; max-width:100%; clip-path:none; }
[data-mdd-ui-shell58] .divider { align-self:center; height:30px; border-left:1px solid var(--mdd-shell-line); }
[data-mdd-ui-shell58] :is(.header-right,.header-meta) { display:flex; align-items:center; justify-content:flex-end; flex-wrap:wrap; gap:8px; min-width:0; margin:0 0 0 auto; padding:0; }
[data-mdd-ui-shell58] > :is(img,.brand-logo) { width:74px; max-width:100%; height:auto; max-height:34px; object-fit:contain; flex:none; grid-area:auto; order:0; }
[data-mdd-ui-shell58] > .header-title { min-width:140px; flex:1 1 190px; margin:0; padding:0 0 0 16px; border-left:1px solid var(--mdd-shell-line); grid-area:auto; order:0; }
[data-mdd-ui-shell58] > .header-title h1 { font-size:15px; line-height:1.4; font-weight:600; margin:0; }
[data-mdd-ui-shell58] > .header-title p { margin:3px 0 0; font-size:11px; line-height:1.45; font-weight:400; color:var(--mdd-shell-muted); }
[data-mdd-ui-shell58] > :is(span,div) { min-width:0; }
[data-mdd-ui-shell58] :is(.header-caption,.version-tag) { font-size:12px; font-weight:400; line-height:1.5; }
[data-mdd-ui-shell58] :is(button,a.button,a.quiet,.model-admin-link,#back,.local-return,#mdd-chatgpt-account58,#mdd-ui-help) {
 box-sizing:border-box; min-height:38px; height:auto; padding:8px 12px; margin:0; border:1px solid #ccdcf0; border-radius:7px;
 background:#fff; color:var(--mdd-shell-blue); font:500 13px/20px Inter,-apple-system,BlinkMacSystemFont,"Segoe UI",Arial,sans-serif;
 text-decoration:none; white-space:normal; overflow-wrap:anywhere; cursor:pointer; grid-area:auto;
}
[data-mdd-ui-shell58] :is(a.button,#back,.local-return,#mdd-ui-help,.model-admin-link) { display:inline-flex; align-items:center; justify-content:center; }
[data-mdd-ui-shell58] :is(button,a):focus-visible { outline:3px solid #8abbf4; outline-offset:3px; }
[data-mdd-ui-shell58] :is(button,a):hover:not(:disabled) { border-color:#90b8ed; background:#f0f6fd; }
[data-mdd-ui-shell58] button:disabled { cursor:default; opacity:.55; }
[data-mdd-ui-shell58] .environment { margin:0; padding:7px 9px; font-size:11px; line-height:1.5; color:var(--mdd-shell-muted); background:var(--mdd-shell-soft); }
[data-mdd-ui-shell58] .mdd58-executor-selector:not([hidden]) { display:contents; margin:0; min-width:0; max-width:none; font:inherit; }
[data-mdd-ui-shell58] .mdd58-executor-selector > .mdd58-executor-status { order:1; flex:0 1 260px; min-width:0; max-width:290px; margin:0; padding:7px 10px; border-radius:7px; background:var(--mdd-shell-soft); color:var(--mdd-shell-muted); font:400 11px/1.4 Inter,-apple-system,BlinkMacSystemFont,"Segoe UI",Arial,sans-serif; overflow-wrap:anywhere; }
[data-mdd-ui-shell58] #mdd-chatgpt-account58 { order:2; }
[data-mdd-ui-shell58] :is([data-action="home"],.local-return,#back) { order:3; }
[data-mdd-ui-shell58] #mdd-ui-help { order:4; }
[data-mdd-ui-shell58] :is(.mdd58-connection,#mdd58-ai-availability-badge) { order:1; max-width:280px; min-width:0; }
[data-mdd-ui-shell58] #mdd58-ai-availability-badge { height:auto; min-height:30px; max-height:none; white-space:normal; font-family:inherit; }
[data-mdd-ui-shell58] .mdd58-connection :is(summary,.mdd58-connection-label) { font-family:inherit; font-size:11px; }
[data-mdd-ui-shell58] > [data-case-status] { order:1; grid-area:auto; max-width:240px; padding:6px 9px; margin:0; text-align:left; white-space:normal; font:400 12px/1.45 Inter,-apple-system,BlinkMacSystemFont,"Segoe UI",Arial,sans-serif; }
[data-mdd-ui-shell58] .mdd-ui-shell58-overflow { order:10; flex:none; display:block; position:relative; margin:0; z-index:120; }
[data-mdd-ui-shell58] .mdd-ui-shell58-toggle { display:flex; align-items:center; justify-content:center; width:38px; min-height:38px; padding:4px 8px; font-size:23px; line-height:28px; letter-spacing:1px; font-weight:600; }
[data-mdd-ui-shell58] .mdd-ui-shell58-menu:not([hidden]) { display:flex; flex-direction:column; align-items:stretch; gap:12px; position:absolute; top:calc(100% + 8px); right:0; width:min(420px,calc(100vw - 32px)); max-height:calc(100dvh - 130px); overflow:auto; overscroll-behavior:contain; box-sizing:border-box; padding:16px; background:#fff; border:1px solid #ccdcf0; border-radius:10px; box-shadow:0 14px 38px #15355024; color:var(--mdd-shell-ink); font:400 13px/1.5 Inter,-apple-system,BlinkMacSystemFont,"Segoe UI",Arial,sans-serif; }
[data-mdd-ui-shell58] .mdd-ui-shell58-menu > .mdd58-executor-line { display:flex; flex-wrap:wrap; align-items:center; gap:10px; max-width:100%; width:100%; }
[data-mdd-ui-shell58] .mdd-ui-shell58-menu .mdd58-executor-label { display:block; flex-basis:100%; margin:0; font:500 12px/1.4 Inter,-apple-system,BlinkMacSystemFont,"Segoe UI",Arial,sans-serif; color:var(--mdd-shell-muted); }
[data-mdd-ui-shell58] .mdd-ui-shell58-menu .mdd58-executor-options:not([hidden]) { display:flex; flex-wrap:wrap; width:100%; max-width:100%; overflow:visible; background:#fff; border:1px solid #ccdcf0; border-radius:7px; grid-area:auto; }
[data-mdd-ui-shell58] .mdd-ui-shell58-menu .mdd58-executor-options button { flex:1 1 45%; min-width:0; border:0; margin:0; border-radius:4px; padding:8px; font-size:12px; line-height:1.45; }
[data-mdd-ui-shell58] .mdd-ui-shell58-menu .mdd58-executor-options button[aria-pressed="true"] { background:var(--mdd-shell-blue); color:#fff; font-weight:600; }
[data-mdd-ui-shell58] .mdd-ui-shell58-menu .mdd58-executor-power[aria-checked="true"] { background:var(--mdd-shell-blue); border-color:var(--mdd-shell-blue); color:#fff; }
[data-mdd-ui-shell58] .mdd-ui-shell58-menu .mdd58-executor-readonly { font:500 13px/1.5 Inter,-apple-system,BlinkMacSystemFont,"Segoe UI",Arial,sans-serif; padding:8px 10px; max-width:100%; grid-area:auto; }
[data-mdd-ui-shell58] .mdd-ui-shell58-menu .mdd58-executor-help { display:block; position:static; margin:0; padding:0; border:0; min-height:0; width:100%; border-radius:0; box-shadow:none; background:transparent; grid-area:auto; }
[data-mdd-ui-shell58] .mdd-ui-shell58-menu .mdd58-executor-help > summary { display:flex; align-items:center; width:38px; height:auto; min-height:38px; padding:8px; border:1px solid #ccdcf0; border-radius:7px; font:500 13px/20px Inter,-apple-system,BlinkMacSystemFont,"Segoe UI",Arial,sans-serif; }
[data-mdd-ui-shell58] .mdd-ui-shell58-menu .mdd58-executor-help-panel { position:static; width:auto; max-width:100%; max-height:none; overflow:visible; margin:10px 0 0; padding:12px; border-radius:7px; box-shadow:none; background:var(--mdd-shell-soft); color:var(--mdd-shell-muted); font:400 12px/1.6 Inter,-apple-system,BlinkMacSystemFont,"Segoe UI",Arial,sans-serif; }
[data-mdd-ui-shell58] .mdd-ui-shell58-menu .model-admin-link { display:flex; justify-content:flex-start; width:100%; font-weight:500; }
[data-mdd-ui-shell58] .mdd-ui-shell58-menu [hidden] { display:none!important; }
[data-mdd-ui-shell58] .mdd-ui-shell58-menu[hidden] { display:none!important; }
@media(max-width:1000px) {
 [data-mdd-ui-shell58]:not([hidden]) { gap:10px 16px; padding:12px 20px; }
 [data-mdd-ui-shell58="navigator"],[data-mdd-ui-shell58="help"] { padding:0; }
 [data-mdd-ui-shell58] > .header-inner { padding:12px 20px; gap:10px 16px; }
 [data-mdd-ui-shell58] :is(.brand,.site-brand) { flex-basis:270px; }
 [data-mdd-ui-shell58] :is(.header-right,.header-meta) { flex:1 1 490px; justify-content:flex-end; }
 [data-mdd-ui-shell58] .mdd58-executor-selector > .mdd58-executor-status { flex-basis:220px; max-width:260px; }
}
@media(max-width:600px) {
 [data-mdd-ui-shell58]:not([hidden]) { padding:12px 16px; gap:10px 12px; }
 [data-mdd-ui-shell58="navigator"],[data-mdd-ui-shell58="help"] { padding:0; }
 [data-mdd-ui-shell58] > .header-inner { padding:12px 16px; gap:10px 12px; }
 [data-mdd-ui-shell58] :is(.brand,.site-brand) { flex-basis:100%; gap:14px; }
 [data-mdd-ui-shell58] :is(.header-right,.header-meta) { flex-basis:100%; width:100%; margin:0; justify-content:flex-start; gap:7px; }
 [data-mdd-ui-shell58] .mdd58-executor-selector > .mdd58-executor-status { flex-basis:100%; max-width:none; width:100%; }
 [data-mdd-ui-shell58] :is(.mdd58-connection,#mdd58-ai-availability-badge) { max-width:100%; }
 [data-mdd-ui-shell58] .mdd-ui-shell58-overflow { margin-left:auto; }
 [data-mdd-ui-shell58] > .header-title { flex-basis:calc(100% - 108px); min-width:0; }
 [data-mdd-ui-shell58] > [data-case-status] { max-width:100%; }
 [data-mdd-ui-shell58] .mdd-ui-shell58-menu:not([hidden]) { width:min(390px,calc(100vw - 32px)); max-height:65dvh; }
}
@media print {
 [data-mdd-ui-shell58] .mdd-ui-shell58-overflow { display:none; }
}
/* Layout precedence over historical page-specific grid header rules. Source [hidden] wins. */
html[data-mdd-ux58="1"] header[data-mdd-ui-shell58]:not([hidden]) {
 display:flex!important; flex-wrap:wrap!important; align-items:center!important;
 grid-template-columns:none!important; grid-template-rows:none!important;
 height:auto!important; min-height:0!important; max-height:none!important;
}
html[data-mdd-ux58="1"] header[data-mdd-ui-shell58] > .header-right,
html[data-mdd-ux58="1"] header[data-mdd-ui-shell58] > .header-meta,
html[data-mdd-ux58="1"] header[data-mdd-ui-shell58] > .header-inner {
 display:flex!important; flex-wrap:wrap!important; grid-template-columns:none!important;
 grid-column:auto!important; grid-row:auto!important; align-items:center!important;
 height:auto!important; min-height:0!important; max-height:none!important;
}
html[data-mdd-ux58="1"] header[data-mdd-ui-shell58] > *,
html[data-mdd-ux58="1"] header[data-mdd-ui-shell58] > .header-right > *,
html[data-mdd-ux58="1"] header[data-mdd-ui-shell58] > .header-inner > * {
 grid-column:auto!important; grid-row:auto!important;
}
html[data-mdd-ux58="1"] header[data-mdd-ui-shell58] .mdd58-executor-selector:not([hidden]) {
 display:contents!important; margin:0!important; padding:0!important; border:0!important;
}
html[data-mdd-ux58="1"] header[data-mdd-ui-shell58] .mdd58-executor-status {
 width:auto!important; max-width:290px!important; margin:0!important; font-size:11px!important; line-height:1.4!important;
}
html[data-mdd-ux58="1"] header[data-mdd-ui-shell58] .mdd-ui-shell58-menu > .mdd58-executor-line {
 display:flex!important; flex-wrap:wrap!important; gap:10px!important; width:100%!important;
}
html[data-mdd-ux58="1"] header[data-mdd-ui-shell58] .mdd-ui-shell58-menu .mdd58-executor-help-panel {
 position:static!important; width:auto!important; max-width:100%!important; max-height:none!important; overflow:visible!important;
}
html[data-mdd-ux58="1"] header[data-mdd-ui-shell58][hidden],
html[data-mdd-ux58="1"] header[data-mdd-ui-shell58] [hidden],
html[data-mdd-ux58="1"] body.legacy-case > .site-header[data-mdd-ui-shell58] { display:none!important; }
@media(max-width:600px) {
 html[data-mdd-ux58="1"] header[data-mdd-ui-shell58] .mdd58-executor-status { width:100%!important; max-width:none!important; }
 html[data-mdd-ux58="1"] header[data-mdd-ui-shell58] .mdd-ui-shell58-menu:not([hidden]) {
  width:calc(100vw - 64px)!important; max-width:calc(100vw - 64px)!important;
 }
 html[data-mdd-ux58="1"] header[data-mdd-ui-shell58] .mdd-ui-shell58-menu .mdd58-executor-options:not([hidden]) {
  display:flex!important; flex-wrap:wrap!important; width:100%!important; max-width:100%!important;
 }
 html[data-mdd-ux58="1"] header[data-mdd-ui-shell58] .mdd-ui-shell58-menu .mdd58-executor-options button {
  flex:1 1 130px!important; width:auto!important; min-width:0!important; max-width:none!important;
  min-height:38px!important; padding:8px 10px!important; white-space:normal!important;
  font-size:12px!important; line-height:18px!important;
 }
}
html[data-mdd-ux58="1"] header[data-mdd-ui-shell58] .mdd-ui-shell58-toggle {
 width:38px!important; min-width:38px!important; height:38px!important; min-height:38px!important;
 padding:0!important; white-space:nowrap!important; overflow-wrap:normal!important;
 font-size:18px!important; line-height:38px!important; letter-spacing:1px!important;
}


/* MDD58_LAYOUT_RATIO_BEGIN 20261021-v01
   Local CSS-only adjustment: full progress first, settings second.
   Scope: the original case workspace when both native panels and tabs exist.
   Source nodes, values, labels, fonts, hidden states and handlers remain intact. */
html[data-mdd-ux58="1"] #mdd-work-panel:where(:not([hidden])):has(>#mdd-progress67:not([hidden])):has(>[data-selection-settings58]:not([hidden])):has(>#selection-tabs) {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  align-items: start;
}
html[data-mdd-ux58="1"] #mdd-work-panel:has(>#mdd-progress67:not([hidden])):has(>[data-selection-settings58]:not([hidden])):has(>#selection-tabs)>* {
  grid-column: 1 / -1;
  min-width: 0;
}
/* Leave header, project and notices in their original relative order before this pair.
   Original tab bar and all following rows retain their mutual source order after it. */
html[data-mdd-ux58="1"] #mdd-work-panel:has(>#mdd-progress67:not([hidden])):has(>[data-selection-settings58]:not([hidden])):has(>#selection-tabs)>#mdd-progress67 {
  order: 1;
  grid-column: 1;
  align-self: start;
  min-height: 0;
  height: auto;
  margin: 12px 20px 8px;
  padding: 14px 16px;
}
html[data-mdd-ux58="1"] #mdd-work-panel:has(>#mdd-progress67:not([hidden])):has(>[data-selection-settings58]:not([hidden])):has(>#selection-tabs)>[data-selection-settings58]:where(:not([hidden])) {
  order: 2;
  grid-column: 1;
  align-self: start;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 8px;
  min-width: 0;
  min-height: 0;
  height: auto;
  margin: 8px 20px 12px;
  padding: 14px 16px;
}
html[data-mdd-ux58="1"] #mdd-work-panel:has(>#mdd-progress67:not([hidden])):has(>[data-selection-settings58]:not([hidden])):has(>#selection-tabs)>#selection-tabs,
html[data-mdd-ux58="1"] #mdd-work-panel:has(>#mdd-progress67:not([hidden])):has(>[data-selection-settings58]:not([hidden])):has(>#selection-tabs)>#selection-tabs~* {
  order: 3;
}
/* Flatten only the original generic field wrapper, so both native descriptions
   can sit directly below the selector and above the original advanced details. */
html[data-mdd-ux58="1"] #mdd-work-panel:has(>#mdd-progress67:not([hidden])):has(>[data-selection-settings58]:not([hidden])):has(>#selection-tabs)>[data-selection-settings58]>div:not([hidden]) {
  display: contents !important;
}
html[data-mdd-ux58="1"] #mdd-work-panel:has(>#mdd-progress67:not([hidden])):has(>[data-selection-settings58]:not([hidden])):has(>#selection-tabs)>[data-selection-settings58]>strong {
  order: 0;
  min-width: 0;
  margin: 0;
}
html[data-mdd-ux58="1"] #mdd-work-panel:has(>#mdd-progress67:not([hidden])):has(>[data-selection-settings58]:not([hidden])):has(>#selection-tabs)>[data-selection-settings58]>div>.field {
  order: 1;
  width: 100%;
  min-width: 0 !important;
  margin: 0;
}
html[data-mdd-ux58="1"] #mdd-work-panel:has(>#mdd-progress67:not([hidden])):has(>[data-selection-settings58]:not([hidden])):has(>#selection-tabs)>[data-selection-settings58]>.caption {
  order: 2;
  min-width: 0;
  margin: 0;
  white-space: normal;
  overflow-wrap: anywhere;
}
html[data-mdd-ux58="1"] #mdd-work-panel:has(>#mdd-progress67:not([hidden])):has(>[data-selection-settings58]:not([hidden])):has(>#selection-tabs)>[data-selection-settings58]>div>[data-selection-advanced58] {
  order: 3;
  width: 100%;
  min-width: 0 !important;
  margin: 2px 0 0;
}
html[data-mdd-ux58="1"] #mdd-work-panel:has(>#mdd-progress67:not([hidden])):has(>[data-selection-settings58]:not([hidden])):has(>#selection-tabs)>[data-selection-settings58]>[data-save-selection-settings58] {
  order: 4;
  justify-self: start;
  min-width: 0;
  max-width: 100%;
  margin: 0;
  white-space: normal;
  overflow-wrap: anywhere;
}
html[data-mdd-ux58="1"] #mdd-work-panel:has(>#mdd-progress67:not([hidden])):has(>[data-selection-settings58]:not([hidden])):has(>#selection-tabs)>[data-selection-settings58] :is(label, select, summary) {
  min-width: 0;
  max-width: 100%;
  box-sizing: border-box;
  white-space: normal;
  overflow-wrap: anywhere;
}
html[data-mdd-ux58="1"] #mdd-work-panel:has(>#mdd-progress67:not([hidden])):has(>[data-selection-settings58]:not([hidden])):has(>#selection-tabs)>[data-selection-settings58] select {
  width: 100%;
}
html[data-mdd-ux58="1"] #mdd-work-panel:has(>#mdd-progress67:not([hidden])):has(>[data-selection-settings58]:not([hidden])):has(>#selection-tabs)>[data-selection-settings58] [data-selection-advanced58]>summary {
  min-height: 36px;
  padding: 8px 10px;
}
@media (min-width: 1100px) {
  html[data-mdd-ux58="1"] #mdd-work-panel:has(>#mdd-progress67:not([hidden])):has(>[data-selection-settings58]:not([hidden])):has(>#selection-tabs) {
    grid-template-columns: minmax(0, 3fr) minmax(0, 1fr);
  }
  html[data-mdd-ux58="1"] #mdd-work-panel:has(>#mdd-progress67:not([hidden])):has(>[data-selection-settings58]:not([hidden])):has(>#selection-tabs)>#mdd-progress67 {
    grid-column: 1;
    margin: 12px 8px 12px 20px;
  }
  html[data-mdd-ux58="1"] #mdd-work-panel:has(>#mdd-progress67:not([hidden])):has(>[data-selection-settings58]:not([hidden])):has(>#selection-tabs)>[data-selection-settings58] {
    grid-column: 2;
    margin: 12px 20px 12px 8px;
  }
}
@media (max-width: 600px) {
  html[data-mdd-ux58="1"] #mdd-work-panel:has(>#mdd-progress67:not([hidden])):has(>[data-selection-settings58]:not([hidden])):has(>#selection-tabs)>#mdd-progress67 {
    margin-inline: 12px;
  }
  html[data-mdd-ux58="1"] #mdd-work-panel:has(>#mdd-progress67:not([hidden])):has(>[data-selection-settings58]:not([hidden])):has(>#selection-tabs)>[data-selection-settings58] {
    margin-inline: 12px;
  }
}
/* MDD58_LAYOUT_RATIO_END 20261021-v01 */


/* MDD58_CATEGORY_TOOLBAR_BEGIN 20261021-v02
   Native category badges/actions only. Preserve text, fonts, hidden/disabled,
   source controls and handlers; no global button or product-row redesign. */
html[data-mdd-ux58="1"] .product-bottom:has(>[data-offer-category-badge58]):has(>[data-offer-category-open58]):not([hidden]) {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-start;
  gap: 8px;
}
html[data-mdd-ux58="1"] .product-bottom:has(>[data-offer-category-badge58]):has(>[data-offer-category-open58])>.exclude {
  margin-inline-start: 0;
}
html[data-mdd-ux58="1"] .product-bottom:has(>[data-offer-category-badge58]):has(>[data-offer-category-open58])>.selection-state:where(:not([hidden])),
html[data-mdd-ux58="1"] :is(.product-bottom,.product-heading)>[data-offer-category-badge58]:not([hidden]),
html[data-mdd-ux58="1"] :is(.product-bottom,.product-heading)>[data-offer-category-open58]:not([hidden]) {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  min-width: 0;
  max-width: 100%;
  min-height: 32px;
  height: auto;
  margin-block: 0;
  padding: 4px 9px;
  vertical-align: middle;
  white-space: normal;
  overflow-wrap: anywhere;
}
/* Heading fallbacks occur in commercial table cells; keep the title/price DOM
   as block content and align only the appended native category pair inline. */
html[data-mdd-ux58="1"] .product-heading>[data-offer-category-badge58],
html[data-mdd-ux58="1"] .product-heading>[data-offer-category-open58] {
  margin-block: 6px 0;
}
html[data-mdd-ux58="1"] .product-heading>[data-offer-category-open58] {
  margin-inline-start: 8px;
}
/* The native wide owner toolbar contains its own button/badge group plus an
   optional summary and receipt action. All remain available in one compact band. */
html[data-mdd-ux58="1"] .offer-categories-owner58:not([hidden]) {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  flex-wrap: wrap;
  gap: 8px 12px;
  box-sizing: border-box;
  width: 100%;
  min-width: 0;
  max-width: 100%;
  margin-block: 8px;
  padding: 8px 10px;
  border: 1px solid var(--mdd4-line, #dbe5f0);
  border-radius: 8px;
  background: var(--mdd4-soft, #eef6ff);
}
html[data-mdd-ux58="1"] .offer-categories-owner58>.offer-categories-toolbar58:not([hidden]) {
  display: inline-flex;
  align-items: center;
  justify-content: flex-start;
  flex-wrap: wrap;
  gap: 8px;
  min-width: 0;
  max-width: 100%;
  margin: 0;
  padding: 0;
}
html[data-mdd-ux58="1"] .offer-categories-owner58>.offer-categories-toolbar58>:is(button,.selection-state):not([hidden]),
html[data-mdd-ux58="1"] .offer-categories-owner58>button:not([hidden]),
html[data-mdd-ux58="1"] .offer-categories-owner58>[data-offer-category-summary58]>summary:where(:not([hidden])) {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  min-width: 0;
  max-width: 100%;
  min-height: 32px;
  height: auto;
  margin: 0;
  padding: 4px 9px;
  white-space: normal;
  overflow-wrap: anywhere;
}
html[data-mdd-ux58="1"] .offer-categories-owner58>[data-offer-category-summary58] {
  min-width: 0;
  max-width: 100%;
  margin: 0;
}
html[data-mdd-ux58="1"] .offer-categories-owner58>[data-offer-category-summary58]>summary:where(:not([hidden])) {
  display: list-item;
  list-style-position: inside;
}
/* Product-list actions keep their existing column and delegated category event. */
html[data-mdd-ux58="1"] #product-list-native .plv-heading>[data-offer-category-all58],
html[data-mdd-ux58="1"] #product-list-native .plv-state>[data-offer-category-position58] {
  align-self: center;
  box-sizing: border-box;
  width: auto;
  min-width: 0;
  max-width: 100%;
  min-height: 32px;
  height: auto;
  margin: 0;
  padding: 4px 9px;
  white-space: normal;
  overflow-wrap: anywhere;
}
html[data-mdd-ux58="1"] #product-list-native .plv-state>[data-offer-category-position58] {
  align-self: flex-start;
}
/* MDD58_CATEGORY_TOOLBAR_END 20261021-v02 */

/* MDD58_SETTINGS_GRID_RESET_BEGIN 20261021-v03
   Reset native two-column placements after flattening only the field wrapper.
   Keep the source label as one grid item, then descriptions, then advanced.
   No source DOM, values, labels, fonts, events or hidden states are changed. */
html[data-mdd-ux58="1"] #mdd-work-panel:has(>#mdd-progress67:not([hidden])):has(>[data-selection-settings58]:not([hidden])):has(>#selection-tabs)>[data-selection-settings58] {
  grid-template-columns: minmax(0, 1fr);
  grid-template-rows: none;
  grid-auto-columns: minmax(0, 1fr);
  grid-auto-rows: auto;
  grid-auto-flow: row;
}
html[data-mdd-ux58="1"] #mdd-work-panel:has(>#mdd-progress67:not([hidden])):has(>[data-selection-settings58]:not([hidden])):has(>#selection-tabs)>[data-selection-settings58]>:is(strong, .caption, [data-save-selection-settings58]),
html[data-mdd-ux58="1"] #mdd-work-panel:has(>#mdd-progress67:not([hidden])):has(>[data-selection-settings58]:not([hidden])):has(>#selection-tabs)>[data-selection-settings58]>div>:is(label.field, [data-selection-advanced58]) {
  grid-area: auto;
  grid-column: 1 / -1;
  grid-row: auto;
  min-width: 0;
}
html[data-mdd-ux58="1"] #mdd-work-panel:has(>#mdd-progress67:not([hidden])):has(>[data-selection-settings58]:not([hidden])):has(>#selection-tabs)>[data-selection-settings58]>div>label.field:not([hidden]) {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  grid-template-rows: none;
  grid-auto-flow: row;
  gap: 6px;
}
html[data-mdd-ux58="1"] #mdd-work-panel:has(>#mdd-progress67:not([hidden])):has(>[data-selection-settings58]:not([hidden])):has(>#selection-tabs)>[data-selection-settings58]>div>label.field>:is(span, select) {
  grid-area: auto;
  grid-column: 1 / -1;
  grid-row: auto;
  min-width: 0;
}
/* MDD58_SETTINGS_GRID_RESET_END 20261021-v03 */

/* MDD58_CATEGORY_INLINE_GAP_BEGIN 20261021-v04
   Space preceding native inline chips, so a wrapped action has no left indent.
   Only the owner category fallback inside an existing product heading. */
html[data-mdd-ux58="1"] .product-heading:has(>[data-offer-category-badge58]):has(>[data-offer-category-open58])>.product-brand,
html[data-mdd-ux58="1"] .product-heading:has(>[data-offer-category-badge58]):has(>[data-offer-category-open58])>[data-offer-category-badge58] {
  margin-inline-end: 8px;
}
html[data-mdd-ux58="1"] .product-heading:has(>[data-offer-category-badge58]):has(>[data-offer-category-open58])>[data-offer-category-open58] {
  margin-inline-start: 0;
}
/* MDD58_CATEGORY_INLINE_GAP_END 20261021-v04 */

/* MDD58_OWNED_WRAPPER_HIDDEN_BEGIN 20261021-v06
   Native settings wrapper only: override its pre-existing important display:grid
   when its own hidden attribute is present. Visible layout is unchanged. */
html[data-mdd-ux58="1"] #mdd-work-panel:has(>#mdd-progress67:not([hidden])):has(>[data-selection-settings58]:not([hidden])):has(>#selection-tabs)>[data-selection-settings58]>div[hidden]:has(>label.field>[data-proposal-count58]):has(>[data-selection-advanced58]) {
  display: none !important;
}
/* MDD58_OWNED_WRAPPER_HIDDEN_END 20261021-v06 */
