
/* dialog box for message and confirmation */

::backdrop
{
	background: rgba(0, 0, 0, 0.5);
}

dialog /* fullscreen element that prevents interaction with background */
{
	height: 100vh; /* required to make the flex box work as intended */
	overflow: hidden; /* avoid scrollbar in case of extreme small viewport */
	background-color: unset; /* remove default style */
	border: unset;
	
	&>div /* container that vertically centers the visible box */
	{
		width: 100%;
		height: 100%;
		display: flex;
		align-items: center;
		
		&>div /* visible box */
		{
			max-height: 100%;
			display: flex;
			flex-direction: column;
			align-items: center;
			justify-content: center;
			row-gap: 12px; /* between article and footer */
			padding: 8px; /* to have something around an article scrollbar */
			background-color: rgb(230, 230, 230);
			border-radius: 10px;
			
			article /* container for message with verctical scrollbar if needed */
			{
				flex: 0 1 auto;
				overflow: auto;
				max-width: 20em;
				user-select: none;
				padding: 10px;
				word-break: break-word;
				
				strong
				{
					font-weight: bold;
				}
				cite
				{
					font-style: italic;
				}
			}
			
			footer /* container for buttons */
			{
				flex: 0 0 auto;
				display: flex;
				flex-direction: row;
				justify-content: center;
				column-gap: 24px;
				padding: 12px 0px;
			
				button
				{
					width: 96px;
					font-size: 24px;
				}
			}
		}
	}
}
