/*
 * The plugin's active class isolates this appearance from unrelated drop-cap
 * implementations while retaining WordPress's standard has-drop-cap marker.
 */
@supports (initial-letter: 3 3) or (-webkit-initial-letter: 3 3) {
	.wp-block-post-content p.wgow-drop-cap-active::first-letter,
	.editor-styles-wrapper p.wgow-drop-cap-active::first-letter,
	.editor-styles-wrapper .wp-block-paragraph.wgow-drop-cap-active::first-letter,
	.editor-styles-wrapper .wgow-drop-cap-active > p::first-letter,
	.editor-styles-wrapper
		.wgow-drop-cap-active
		.block-editor-rich-text__editable::first-letter {
		float: none !important;
		font-size: inherit !important;
		line-height: inherit !important;
		margin-inline-end: 0.3em !important;
		-webkit-initial-letter: 3 3;
		initial-letter: 3 3;
		initial-letter-wrap: none;
	}
}

.wp-block-post-content
p.wgow-drop-cap-active.has-italic-drop-cap::first-letter,
.editor-styles-wrapper
p.wgow-drop-cap-active.has-italic-drop-cap::first-letter,
.editor-styles-wrapper
.wp-block-paragraph.wgow-drop-cap-active.has-italic-drop-cap::first-letter,
.editor-styles-wrapper
.wgow-drop-cap-active.has-italic-drop-cap > p::first-letter,
.editor-styles-wrapper
.wgow-drop-cap-active.has-italic-drop-cap
.block-editor-rich-text__editable::first-letter {
	font-style: italic !important;
}

/*
 * A short drop-cap paragraph can leave an exclusion area extending into the
 * next block. Giving an immediately following list its own formatting context
 * makes the list clear that area, keeping its markers and text aligned.
 */
.wp-block-post-content
p.wgow-drop-cap-active + :is(ul, ol) {
	display: flow-root;
}

.editor-styles-wrapper
.wgow-drop-cap-active + :is(ul, ol, [data-type="core/list"]) {
	display: flow-root;
}
