@use "@automattic/jetpack-base-styles/gutenberg-base-styles" as gb;

.wp-block-jetpack-repeat-visitor {

	.components-notice {
		margin: 1em 0 0;
		color: gb.$gray-900;
	}

	.components-radio-control__option {
		text-align: left;
	}

	.components-notice__content {
		margin: 0.5em 0;
		font-size: 1em;

		.components-base-control {
			display: inline-block;
			max-width: 8em;
			vertical-align: middle;

			.components-base-control__field {
				margin-bottom: 0;
			}
		}
	}
}

.wp-block-jetpack-repeat-visitor-placeholder {
	min-height: inherit;

	.components-placeholder__label svg {
		margin-right: 0.5ch;
	}

	.components-placeholder__fieldset {
		flex-wrap: nowrap;

		.components-base-control {
			flex-basis: 100%;
			margin-bottom: 0;
		}
	}

	.components-base-control__help {
		color: gb.$alert-red;
		font-size: 13px;
	}
}

.wp-block-jetpack-repeat-visitor--is-unselected .wp-block-jetpack-repeat-visitor-placeholder {
	display: none;
}

.wp-block-jetpack-repeat-visitor-threshold {
	margin-right: 20px;

	.components-text-control__input {
		margin-left: 12px;
		text-align: center;
		width: 5em;
	}

}

// Overrides to make the preview look good
.block-editor-inserter__preview {

	.wp-block-jetpack-repeat-visitor {
		padding: 16px;

		> .block-editor-inner-blocks > .block-editor-block-list__layout {
			margin: 0;
		}
	}
}
