/**
 * CodeMirror 6 base layout.
 *
 * CM6 injects its own structural and highlighting styles via JS
 * (EditorView.theme / oneDark). This file provides the handful of
 * host-level rules that WordPress themes sometimes interfere with.
 */

/* Ensure the editor root takes full width inside its wrapper. */
.cm-editor {
	position: relative;
	width: 100%;
}

/* Prevent WordPress themes from clobbering CM content styles. */
.cm-editor .cm-scroller {
	font-family: var(--tfl-font-mono, 'IBM Plex Mono', 'Consolas', monospace);
	font-size: 0.875rem;
	line-height: 1.6;
	overflow: auto;
}

/* Make sure the editor is at least a few lines tall. */
.cm-editor .cm-content {
	min-height: 120px;
}

/* Prevent WP from adding box-shadow / outline on focus. */
.cm-editor.cm-focused {
	outline: none !important;
	box-shadow: none !important;
}
