:root {
	--carnival-red: #d64045;
	--carnival-gold: #e9b44c;
	--carnival-cream: #f6ecdb;
	--carnival-blue: #1d3354;
	--carnival-sky: #9ed8db;
	--font-header: 'Sancreek', cursive;
	--font-sub: 'Rye', serif;
	--font-body: 'Courier Prime', monospace;
}

* {
	margin: 0;
	padding: 0;
	box-sizing: border-box;
}

body {
	font-family: var(--font-body);
	color: #333;
	/* Pinwheel background */
	background: repeating-conic-gradient(from 0deg,
			#ff6b6b 0deg 30deg,
			#f8f9fa 30deg 60deg);
	min-height: 100vh;
	display: flex;
	justify-content: center;
	align-items: center;
	padding: 2rem;
	overflow-x: hidden;
}

.billboard-container {
	background-color: var(--carnival-cream);
	max-width: 900px;
	width: 100%;
	border: 15px solid var(--carnival-red);
	border-radius: 20px;
	box-shadow:
		0 0 0 10px var(--carnival-gold),
		0 20px 50px rgba(0, 0, 0, 0.5);
	position: relative;
	overflow: hidden;
}

/* Flashing lights effect around the border could be done with pseudo-elements or just static for now */
.bulb-border {
	border: 4px dashed var(--carnival-gold);
	margin: 10px;
	padding: 2rem;
	border-radius: 10px;
	background: radial-gradient(circle, #fffdf5 0%, #f0e6d2 100%);
}

.hero {
	text-align: center;
	margin-bottom: 2rem;
}

.carnival-header {
	display: flex;
	justify-content: center;
	align-items: center;
	gap: 1rem;
	margin-bottom: 0.5rem;
}

.carnival-header h1 {
	font-family: var(--font-header);
	font-size: 4rem;
	color: var(--carnival-red);
	text-transform: uppercase;
	letter-spacing: 2px;
	text-shadow: 3px 3px 0px var(--carnival-gold);
	transform: rotate(-2deg);
}

.star {
	font-size: 3rem;
	color: var(--carnival-gold);
	animation: twirl 4s linear infinite;
}

.sub-header {
	font-family: var(--font-sub);
	font-size: 1.5rem;
	color: var(--carnival-blue);
	margin-bottom: 2rem;
	border-top: 2px solid var(--carnival-blue);
	border-bottom: 2px solid var(--carnival-blue);
	display: inline-block;
	padding: 0.5rem 2rem;
}

.poster-image {
	margin: 0 auto 2rem;
	width: 250px;
	height: 250px;
	border-radius: 50%;
	border: 8px solid var(--carnival-gold);
	box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
	overflow: hidden;
	background: white;
	display: flex;
	justify-content: center;
	align-items: center;
}

.poster-image img {
	width: 125%;
	height: 125%;
	object-fit: contain;
	/* Default oscillation */
	animation: oscillate 3s linear infinite;
	cursor: pointer;
	flex-shrink: 0;
}

/* Class to apply spin animation */
.spinning {
	animation: spin 0.8s ease-out !important;
}

.oscillating {
	animation: oscillate 3s linear infinite;
}

.poster-image img {
	position: relative;
	z-index: 1;
}

@keyframes oscillate {
	0% {
		transform: rotate(0deg);
		animation-timing-function: ease-out;
	}

	25% {
		transform: rotate(20deg);
		animation-timing-function: ease-in;
	}

	50% {
		transform: rotate(0deg);
		animation-timing-function: ease-out;
	}

	75% {
		transform: rotate(-20deg);
		animation-timing-function: ease-in;
	}

	100% {
		transform: rotate(0deg);
	}
}

@keyframes spin {
	from {
		transform: rotate(0deg);
	}

	to {
		transform: rotate(360deg);
	}
}

.challenge-text h3 {
	font-family: var(--font-header);
	font-size: 2.5rem;
	line-height: 1.2;
	color: var(--carnival-blue);
	margin-bottom: 1rem;
}

.highlight {
	color: var(--carnival-red);
	font-size: 3.5rem;
	text-shadow: 2px 2px 0 var(--carnival-gold);
}

.tagline {
	font-family: var(--font-sub);
	font-size: 1.2rem;
	font-style: italic;
	color: #555;
}

.main-stage {
	background: #333;
	border: 10px solid var(--carnival-gold);
	border-radius: 10px;
	margin: 2rem auto;
	max-width: 640px;
	position: relative;
	box-shadow: inset 0 0 50px rgba(0, 0, 0, 0.8);
}

.camera-frame {
	background: #000;
	min-height: 360px;
	display: flex;
	align-items: center;
	justify-content: center;
}

.camera-feed-placeholder {
	text-align: center;
	color: #666;
}

.feed-icon {
	font-size: 3rem;
	margin-bottom: 1rem;
}

/* Ticket Booth Footer */
.ticket-booth {
	margin-top: 3rem;
	display: flex;
	justify-content: center;
}

.ticket {
	background-color: var(--carnival-gold);
	color: var(--carnival-red);
	display: flex;
	align-items: center;
	padding: 0;
	border: 2px dashed var(--carnival-red);
	position: relative;
	mask-image: radial-gradient(circle at 10px 50%, transparent 10px, black 11px);
	mask-position: -10px;
	mask-size: 100% 100%;
}

.admit-one {
	writing-mode: vertical-rl;
	text-orientation: mixed;
	font-weight: bold;
	padding: 1rem 0.5rem;
	border-right: 2px dashed var(--carnival-red);
	border-left: 2px dashed var(--carnival-red);
	font-family: var(--font-header);
	letter-spacing: 2px;
}

.ticket-content {
	padding: 1rem 2rem;
	text-align: center;
	font-family: var(--font-sub);
}

.ticket-content a {
	color: var(--carnival-blue);
	font-weight: bold;
	text-decoration: none;
}

.ticket-content a:hover {
	text-decoration: underline;
}

.browse-link {
	display: inline-block;
	margin-top: 0.5rem;
	background: var(--carnival-red);
	color: var(--carnival-gold) !important;
	padding: 0.5rem 1rem;
	border-radius: 5px;
	text-decoration: none !important;
	transition: transform 0.2s;
}

.browse-link:hover {
	transform: scale(1.05);
}

@keyframes twirl {
	from {
		transform: rotate(0deg);
	}

	to {
		transform: rotate(360deg);
	}
}

@media (max-width: 768px) {
	.carnival-header h1 {
		font-size: 2.5rem;
	}

	.highlight {
		font-size: 2.5rem;
	}

	.billboard-container {
		border-width: 5px;
		box-shadow: none;
	}

	body {
		padding: 1rem;
	}
}