/*
 *
 * Selectors must be nested in `.jp-ThemedContainer` to have a higher
 * specificity than selectors in rules provided by JupyterLab.
 *
 * See: https://jupyterlab.readthedocs.io/en/latest/extension/extension_migration.html#css-styling
 * See also: https://github.com/jupyterlab/jupyter-ai/issues/1090
 */

.jp-ThemedContainer .jp-ai-rendermime-markdown .jp-RenderedHTMLCommon {
  padding-right: 0;
}

.jp-ThemedContainer .jp-ai-rendermime-markdown pre {
  background-color: var(--jp-cell-editor-background);
  overflow-x: auto;
  white-space: pre;
  margin: 0;
  padding: 4px 2px 0 6px;
  border: var(--jp-border-width) solid var(--jp-cell-editor-border-color);
}

.jp-ThemedContainer .jp-ai-rendermime-markdown pre > code {
  background-color: inherit;
  overflow-x: inherit;
  white-space: inherit;
}

.jp-ThemedContainer .jp-ai-rendermime-markdown mjx-container {
  font-size: 119%;
}
