/* Scoped to articles and the editor canvas: catalog/album layouts are untouched. */
:is(.v-art-content, .editor-styles-wrapper) .wp-block-gallery.has-nested-images {
	--v-gallery-columns: 3;
	display: grid !important;
	grid-template-columns: repeat(var(--v-gallery-columns), minmax(0, 1fr));
	gap: 16px !important;
	align-items: start;
}
:is(.v-art-content, .editor-styles-wrapper) .wp-block-gallery.columns-1 { --v-gallery-columns: 1; }
:is(.v-art-content, .editor-styles-wrapper) .wp-block-gallery.columns-2 { --v-gallery-columns: 2; }
:is(.v-art-content, .editor-styles-wrapper) .wp-block-gallery.columns-3 { --v-gallery-columns: 3; }
:is(.v-art-content, .editor-styles-wrapper) .wp-block-gallery.columns-4 { --v-gallery-columns: 4; }
:is(.v-art-content, .editor-styles-wrapper) .wp-block-gallery.columns-5 { --v-gallery-columns: 5; }
:is(.v-art-content, .editor-styles-wrapper) .wp-block-gallery.columns-6 { --v-gallery-columns: 6; }
:is(.v-art-content, .editor-styles-wrapper) .wp-block-gallery.columns-7 { --v-gallery-columns: 7; }
:is(.v-art-content, .editor-styles-wrapper) .wp-block-gallery.columns-8 { --v-gallery-columns: 8; }
:is(.v-art-content, .editor-styles-wrapper) .wp-block-gallery.has-nested-images > figure.wp-block-image {
	display: flex; flex-direction: column; align-self: start;
	width: 100% !important; max-width: none; min-width: 0;
	margin: 0 !important; aspect-ratio: auto; overflow: visible; background: transparent;
}
:is(.v-art-content, .editor-styles-wrapper) .wp-block-gallery.has-nested-images > figure.wp-block-image img {
	display: block; width: 100%; height: auto; aspect-ratio: auto; object-fit: contain;
}
:is(.v-art-content, .editor-styles-wrapper) .wp-block-gallery.is-cropped > figure.wp-block-image img { aspect-ratio: 4 / 3; object-fit: cover; }
:is(.v-art-content, .editor-styles-wrapper) .wp-block-gallery.is-style-vossen-natural > figure.wp-block-image img { aspect-ratio: auto; height: auto; object-fit: contain; }
:is(.v-art-content, .editor-styles-wrapper) .wp-block-gallery.is-style-vossen-portrait > figure.wp-block-image img { aspect-ratio: 2 / 3; object-fit: contain; background: #f5f5f5; }
:is(.v-art-content, .editor-styles-wrapper) .wp-block-gallery.is-style-vossen-landscape > figure.wp-block-image img { aspect-ratio: 3 / 2; object-fit: contain; background: #f5f5f5; }
:is(.v-art-content, .editor-styles-wrapper) .wp-block-gallery figure.wp-block-image figcaption {
	position: static; margin: 8px 0 0; padding: 0; background: none; color: #777;
	font-size: 12px; line-height: 1.5; text-align: center; overflow-wrap: anywhere;
}
/* The collapsed preset hides frames only on the frontend, so all remain editable. */
.v-art-content .wp-block-gallery.has-nested-images > figure.wp-block-image.is-extra { display: none !important; }
.editor-styles-wrapper .wp-block-gallery .is-extra { display: flex !important; }
.v-article-video { margin: 32px 0; }
.v-article-video-frame { width: 100%; aspect-ratio: 16 / 9; background: #111; }
.v-article-video-frame iframe, .v-article-video-frame video {
	display: block; width: 100%; height: 100%; border: 0; object-fit: contain;
}
.v-article-video figcaption { margin: 10px 0 0; color: #777; font-size: 13px; line-height: 1.5; overflow-wrap: anywhere; }
.v-art-content > .alignfull { width: 100vw; max-width: none; margin-left: calc(50% - 50vw - 82px); }
@media (max-width: 1020px) { .v-art-content > .alignfull { margin-left: calc(50% - 50vw); } }
/* Uploaded standard Video blocks also keep the poster and native controls visible. */
:is(.v-art-content, .editor-styles-wrapper) .wp-block-video video { display: block; width: 100%; max-height: 80vh; object-fit: contain; background: #111; }
.editor-styles-wrapper .v-article-video-frame iframe { pointer-events: none; }
@media (max-width: 900px) {
	:is(.v-art-content, .editor-styles-wrapper) .wp-block-gallery:is(.columns-4,.columns-5,.columns-6,.columns-7,.columns-8) { --v-gallery-columns: 3; }
}
@media (max-width: 600px) {
	:is(.v-art-content, .editor-styles-wrapper) .wp-block-gallery.has-nested-images { --v-gallery-columns: 2; gap: 10px !important; }
	:is(.v-art-content, .editor-styles-wrapper) .wp-block-gallery.columns-1 { --v-gallery-columns: 1; }
	.v-art-content .alignwide { width: 100%; max-width: 100%; margin-left: 0; }
}
