/* Web-only presentation. Android assets and the mobile/flat layouts stay intact. */
@media screen and (min-width: 851px) {
  body[data-editor-view="3d"] .workspace {
    grid-template-columns: clamp(350px, 28vw, 400px) minmax(0, 1fr);
  }

  body[data-editor-view="3d"] .editor-scroll {
    min-width: 0;
    scrollbar-gutter: stable;
  }

  body[data-editor-view="3d"] .editor-scroll .sidebar {
    padding: 24px 20px 32px;
  }

  body[data-editor-view="3d"] .sidebar .form-pair {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
  }

  body[data-editor-view="3d"] .sidebar :is(label, input, select, .section-item > span) {
    min-width: 0;
  }

  body[data-editor-view="3d"] .sidebar :is(label, .section-item, .field-help, .gore-measures, .panel-heading, .pattern-footer) {
    overflow-wrap: anywhere;
    line-height: 1.5;
  }

  body[data-editor-view="3d"] .sidebar :is(.editor-actions, .section-heading, .panel-heading, .pattern-footer) {
    flex-wrap: wrap;
    gap: 12px;
  }

  body[data-editor-view="3d"] .sidebar .btn {
    white-space: normal;
  }

  body[data-editor-view="3d"] .sidebar .gore-editor {
    margin-top: 24px;
    padding: 16px;
  }

  body[data-editor-view="3d"] .sidebar .gore-editor-heading {
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
  }

  body[data-editor-view="3d"] .sidebar .gore-editor-heading .eyebrow {
    display: block;
    line-height: 1.6;
  }

  body[data-editor-view="3d"] .sidebar .gore-stepper {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
  }

  body[data-editor-view="3d"] .sidebar .gore-chips {
    flex-wrap: wrap;
    overflow: visible;
    gap: 8px;
    padding-block: 16px 4px;
  }

  body[data-editor-view="3d"] .sidebar .gore-fields {
    grid-template-columns: minmax(0, 1fr);
    gap: 18px;
    margin-top: 18px;
  }

  body[data-editor-view="3d"] .sidebar .gore-fields > label {
    grid-column: auto;
  }

  body[data-editor-view="3d"] .sidebar .gore-fields > label > span {
    float: right;
    margin-left: 8px;
  }

  body[data-editor-view="3d"] .sidebar .gore-fields > label:last-child input {
    display: block;
    max-width: none;
  }

  body[data-editor-view="3d"] .sidebar .range-pair {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 88px;
    gap: 12px;
  }

  body[data-editor-view="3d"] .sidebar .range-pair input {
    width: 100%;
    min-width: 0;
  }

  body[data-editor-view="3d"] .sidebar .gore-measures {
    margin-top: 20px;
    padding-top: 16px;
    border-top: 1px solid #435244;
    line-height: 1.8;
  }

  body[data-editor-view="3d"] .sidebar .metrics {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px 12px;
  }

  body[data-editor-view="3d"] .sidebar .metrics > div {
    min-width: 0;
    padding: 0;
    border: 0;
  }

  body[data-editor-view="3d"] .sidebar .metrics span {
    font-size: 10px;
    line-height: 1.5;
    letter-spacing: .5px;
  }

  body[data-editor-view="3d"] .sidebar .metrics strong {
    font-size: 22px;
    white-space: normal;
    overflow-wrap: anywhere;
  }

  body[data-editor-view="3d"] .sidebar .bottom-grid {
    grid-template-columns: minmax(0, 1fr);
    gap: 20px;
  }

  body[data-editor-view="3d"] .sidebar .pattern-panel {
    order: 0;
  }

  /* Keep every table value and the existing selection buttons, without a nested scroll. */
  body[data-editor-view="3d"] .sidebar .table-scroll {
    max-height: none;
    overflow: visible;
  }

  body[data-editor-view="3d"] .sidebar table {
    white-space: normal;
  }

  body[data-editor-view="3d"] .sidebar thead {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    overflow: hidden;
    clip-path: inset(50%);
  }

  body[data-editor-view="3d"] .sidebar tbody {
    display: block;
  }

  body[data-editor-view="3d"] .sidebar tbody tr {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    padding: 12px;
    gap: 10px 12px;
    border-top: 1px solid var(--border);
  }

  body[data-editor-view="3d"] .sidebar tbody tr.active {
    background: #303c29;
    box-shadow: inset 3px 0 var(--lime);
  }

  body[data-editor-view="3d"] .sidebar tbody tr:hover {
    background: #2d383b;
  }

  body[data-editor-view="3d"] .sidebar td {
    min-width: 0;
    padding: 0;
    border: 0;
    background: transparent;
    font-size: 13px;
    line-height: 1.5;
    overflow-wrap: anywhere;
  }

  body[data-editor-view="3d"] .sidebar td::before {
    display: block;
    color: var(--muted);
    font: 11px/1.5 Inter, ui-sans-serif, sans-serif;
    margin-bottom: 4px;
  }

  body[data-editor-view="3d"] .sidebar td:nth-child(1)::before { content: "Gomo"; }
  body[data-editor-view="3d"] .sidebar td:nth-child(2)::before { content: "Secção"; }
  body[data-editor-view="3d"] .sidebar td:nth-child(3)::before { content: "D1 / D2 · mm"; }
  body[data-editor-view="3d"] .sidebar td:nth-child(4)::before { content: "Comprimento · mm"; }
  body[data-editor-view="3d"] .sidebar td:nth-child(5)::before { content: "Cortes · °"; }
  body[data-editor-view="3d"] .sidebar td:nth-child(5) { grid-column: 1 / -1; }

  body[data-editor-view="3d"] .sidebar .gore-select {
    min-width: 44px;
    min-height: 36px;
    border: 1px solid #4b5b55;
    border-radius: 5px;
  }

  body[data-editor-view="3d"] .sidebar #pattern-preview {
    height: 280px;
    padding: 16px;
  }

  body[data-editor-view="3d"] .sidebar .pattern-footer > span {
    font-size: 12px;
  }
}
