.wp-block-site-logo {
	// This block has customizable padding, border-box makes that more predictable.
	box-sizing: border-box;
	line-height: 0;

	a {
		display: inline-block;
		line-height: 0;
	}

	// Provide a sane starting point for the size.
	&.is-default-size img {
		width: 120px;
		height: auto;
	}

	// Constrain the image to its container.
	img {
		height: auto;
		max-width: 100%;
	}

	// Inherit border radius from style variations.
	a,
	img {
		border-radius: inherit;
	}

	&.aligncenter {
		margin-left: auto;
		margin-right: auto;
		text-align: center;
	}
}

// Style variations
:root :where(.wp-block-site-logo.is-style-rounded) {
	// We use an absolute pixel to prevent the oval shape that a value of 50% would give
	// to rectangular images. A pill-shape is better than otherwise.
	border-radius: 9999px;
}
