@import url("https://fonts.googleapis.com/css2?family=Parkinsans:wght@300..800&display=swap");

@layer reset {
	*,
	*::before,
	*::after {
		box-sizing: border-box;
	}

	* {
		margin: 0;
		padding: 0;
	}

	@media (prefers-reduced-motion: no-preference) {
		html {
			interpolate-size: allow-keywords;
		}
	}

	body {
		/* 4. Add accessible line-height */
		line-height: 1.5;
		/* 5. Improve text rendering */
		-webkit-font-smoothing: antialiased;
	}

	img,
	picture,
	video,
	canvas,
	svg {
		display: block;
		max-width: 100%;
	}

	input,
	button,
	textarea,
	select {
		font: inherit;
	}

	p,
	h1,
	h2,
	h3,
	h4,
	h5,
	h6 {
		overflow-wrap: break-word;
	}

	p {
		text-wrap: pretty;
	}
	h1,
	h2,
	h3,
	h4,
	h5,
	h6 {
		text-wrap: balance;
	}
}

body {
	font-family: "Parkinsans", sans-serif;
	font-size: 1rem;
	display: flex;
	flex-direction: column;
	justify-content: center;
	align-items: center;
	min-height: 100svh;
	padding-inline: 1rem;
}

.joke-container {
	background-color: rgb(220, 220, 220);
	padding-block: 0rem 2.5rem;
	border-radius: 1rem;
	display: grid;
	gap: 2rem;
	overflow: hidden;
	width: 400px;
}

.joke-container img {
	width: 100%;
	filter: saturate(0) contrast(1.5);
}

.container-text {
	display: grid;
	gap: 2rem;
	padding-inline: 1rem;
}

.joke-container h1 {
	text-transform: uppercase;
	text-align: center;
	line-height: 1.7;
}

.joke-container p {
	text-align: center;
	font-size: 0.875rem;
	padding-inline: 1rem;
	color: rgb(89, 89, 89);
}

.joke-container button {
	background-color: black;
	color: white;
	border: none;
	border-radius: 0.5rem;
	padding-block: 1rem;
	text-transform: uppercase;
	letter-spacing: 2px;
	font-weight: 600;
	cursor: pointer;
	transition: background-color 0.15s ease;
}

.joke-container button:hover,
.joke-container button:focus-visible {
	background-color: rgb(57, 57, 57);
}
