/* The document inspector is a fixed right rail with its own scroll. */
@media (min-width: 901px) {
  body:has(#edit-field-doc-category) .layout-region--secondary {
    position: fixed !important;
    top: calc(var(--evx-topbar-height, 64px) + 24px) !important;
    right: 24px !important;
    bottom: 24px !important;
    width: 340px !important;
    max-width: 340px !important;
    height: auto !important;
    max-height: none !important;
    margin: 0 !important;
    overflow-x: hidden !important;
    overflow-y: auto !important;
    z-index: 20;
    scrollbar-width: thin;
  }
}

@media (max-width: 1200px) and (min-width: 901px) {
  body:has(#edit-field-doc-category) .layout-region--secondary {
    width: 300px !important;
    max-width: 300px !important;
  }
}

@media (max-width: 900px) {
  body:has(#edit-field-doc-category) .layout-region--secondary {
    position: static !important;
    right: auto !important;
    bottom: auto !important;
    width: 100% !important;
    max-width: none !important;
  }
}
