/*
 * Special Events Manager - event page.
 *
 * Colors come from the same CSS variables as the grid (Special Events > Settings); each var() has a
 * fallback so the page also looks right if the settings stylesheet is missing.
 */

/* The full-width hero breaks out of the theme's content column, so hide the scrollbar-width overflow. */
body.sem-single-event {
	overflow-x: hidden;
}

@supports (overflow-x: clip) {
	body.sem-single-event {
		overflow-x: clip; /* "clip" (unlike "hidden") keeps the sticky ticket panel working. */
	}
}

/* The whole page is as wide as the window, whatever width the theme's content column has. */
.sem-single {
	position: relative;
	display: block;
	width: 100vw;
	max-width: 100vw;
	margin-left: calc(50% - 50vw);
	color: var(--sem-text, #222);
	font-size: 16px;
	line-height: 1.6;
}

.sem-single *,
.sem-single *::before,
.sem-single *::after {
	box-sizing: border-box;
}

.sem-single img {
	max-width: 100%;
	height: auto;
}

.sem-single .sem-icon {
	flex: 0 0 auto;
	color: var(--sem-accent, #b92025);
}

.sem-single__wrap {
	width: 100%;
	max-width: 1120px;
	margin: 0 auto;
	padding: 0 20px;
}

/* ------------------------------------------------------------------ Hero */

.sem-hero {
	position: relative;
	isolation: isolate;
	display: flex;
	justify-content: center;
	width: 100%;
	padding: clamp(18px, 3.2vw, 44px) clamp(12px, 3vw, 32px);
	overflow: hidden;
	background: var(--sem-title-bg, #000);
}

/* A soft dark veil so the picture stands out from its own blurred backdrop. */
.sem-hero::after {
	content: "";
	position: absolute;
	inset: 0;
	z-index: -1;
	background: linear-gradient(180deg, rgba(0, 0, 0, 0.25), rgba(0, 0, 0, 0.55));
}

.sem-single .sem-hero__bg {
	position: absolute;
	top: -60px;
	left: -60px;
	z-index: -2;
	width: calc(100% + 120px);
	max-width: none;
	height: calc(100% + 120px);
	object-fit: cover;
	filter: blur(32px) saturate(1.25);
	transform: translateZ(0);
}

.sem-hero__frame {
	position: relative;
	display: flex;
	justify-content: center;
	width: 100%;
	max-width: 1200px;
	margin: 0;
	padding: 0;
}

/* The whole picture is shown (never cropped), as large as the screen allows. */
.sem-single .sem-hero__img {
	display: block;
	width: auto;
	max-width: 100%;
	height: auto;
	max-height: min(72vh, 680px);
	border-radius: 12px;
	box-shadow: 0 22px 60px rgba(0, 0, 0, 0.5);
}

.sem-hero--none {
	min-height: clamp(110px, 16vw, 190px);
	border-bottom: 5px solid var(--sem-accent, #b92025);
	background: linear-gradient(135deg, var(--sem-title-bg, #000), #2b2b2b);
}

/* ------------------------------------------------------------ Title block */

.sem-head {
	padding: clamp(26px, 4vw, 46px) 0 6px;
}

.sem-single .sem-back {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	margin: 0 0 16px;
	color: var(--sem-dark, #3c3c3c);
	font-size: 14px;
	font-weight: 600;
	text-decoration: none;
}

.sem-single .sem-back:hover,
.sem-single .sem-back:focus-visible {
	color: var(--sem-accent, #b92025);
}

.sem-single .sem-head__title {
	margin: 0 0 12px;
	padding: 0;
	color: var(--sem-text, #222);
	font-size: clamp(30px, 4.6vw, 52px);
	font-weight: 800;
	line-height: 1.1;
	letter-spacing: -0.015em;
	text-transform: none;
	overflow-wrap: anywhere;
}

.sem-badge {
	display: inline-block;
	margin: 0 0 14px;
	padding: 5px 12px;
	border-radius: 999px;
	font-size: 12px;
	font-weight: 700;
	letter-spacing: 0.08em;
	text-transform: uppercase;
}

.sem-badge--ended {
	background: #ececec;
	color: #666;
}

.sem-head__summary {
	max-width: 780px;
	margin: 0 0 22px;
	color: #555;
	font-size: clamp(17px, 1.7vw, 20px);
	line-height: 1.55;
}

.sem-facts {
	display: flex;
	flex-wrap: wrap;
	gap: 14px 40px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.sem-facts li {
	display: flex;
	align-items: flex-start;
	gap: 12px;
	margin: 0;
	padding: 0;
}

.sem-facts li::before,
.sem-good li::before {
	content: none;
}

.sem-facts .sem-icon {
	margin-top: 2px;
}

.sem-facts strong {
	display: block;
	font-size: 17px;
	font-weight: 700;
	line-height: 1.35;
}

.sem-facts small {
	display: block;
	color: #666;
	font-size: 14px;
	line-height: 1.45;
}

.sem-chips {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	margin: 20px 0 0;
	padding: 0;
	list-style: none;
}

.sem-chip {
	margin: 0;
	padding: 5px 13px;
	border-radius: 999px;
	background: #f0f0f0;
	color: #444;
	font-size: 13px;
	font-weight: 600;
}

/* ------------------------------------------------------------------ Layout */

.sem-layout {
	display: grid;
	grid-template-columns: minmax(0, 1fr) 360px;
	grid-template-areas: "main aside";
	gap: clamp(26px, 4vw, 60px);
	align-items: start;
	padding: 30px 0 56px;
}

.sem-layout--solo {
	grid-template-columns: minmax(0, 1fr);
	grid-template-areas: "main";
}

.sem-main {
	grid-area: main;
	min-width: 0;
}

.sem-aside {
	grid-area: aside;
	position: sticky;
	top: 24px;
	min-width: 0;
}

/* ------------------------------------------------------------ Ticket panel */

.sem-ticket {
	padding: 24px;
	border: 1px solid #e2e2e2;
	border-top: 5px solid var(--sem-accent, #b92025);
	border-radius: 14px;
	background: #fff;
	box-shadow: 0 14px 38px rgba(0, 0, 0, 0.1);
}

.sem-ticket__label {
	margin: 0 0 6px;
	color: #777;
	font-size: 12px;
	font-weight: 700;
	letter-spacing: 0.12em;
	text-transform: uppercase;
}

.sem-ticket__price {
	margin: 0;
	color: var(--sem-text, #222);
	font-size: 30px;
	font-weight: 800;
	line-height: 1.2;
	overflow-wrap: anywhere;
}

.sem-ticket__note {
	margin: 0 0 16px;
	color: #666;
}

.sem-ticket__actions {
	display: grid;
	gap: 12px;
	margin-top: 20px;
}

.sem-ticket .sem-btn,
.sem-ticket .sem-btn:visited {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	min-height: 54px;
	margin: 0;
	padding: 14px 18px;
	border: 2px solid var(--sem-dark, #3c3c3c);
	border-radius: 10px;
	background: var(--sem-dark, #3c3c3c);
	color: #fff;
	font-size: 15px;
	font-weight: 700;
	letter-spacing: 0.05em;
	line-height: 1.2;
	text-align: center;
	text-decoration: none;
	text-transform: uppercase;
	cursor: pointer;
	transition: transform 0.15s, box-shadow 0.15s, filter 0.15s;
}

.sem-ticket .sem-btn--1,
.sem-ticket .sem-btn--1:visited {
	border-color: var(--sem-accent, #b92025);
	background: var(--sem-accent, #b92025);
}

.sem-ticket .sem-btn:hover,
.sem-ticket .sem-btn:focus-visible {
	color: #fff;
	filter: brightness(1.12);
	box-shadow: 0 10px 22px rgba(0, 0, 0, 0.22);
	transform: translateY(-1px);
}

.sem-ticket .sem-btn:focus-visible {
	outline: 3px solid var(--sem-text, #222);
	outline-offset: 2px;
}

.sem-single .sem-ticket__cal {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	margin-top: 16px;
	color: var(--sem-dark, #3c3c3c);
	font-size: 14px;
	font-weight: 600;
	text-decoration: none;
}

.sem-single .sem-ticket__cal:hover,
.sem-single .sem-ticket__cal:focus-visible {
	color: var(--sem-accent, #b92025);
	text-decoration: underline;
}

/* ------------------------------------------------------------ Main column */

.sem-section {
	margin: 0 0 44px;
}

.sem-single .sem-section__title {
	position: relative;
	margin: 0 0 20px;
	padding: 0 0 12px;
	color: var(--sem-text, #222);
	font-size: clamp(21px, 2.4vw, 26px);
	font-weight: 800;
	line-height: 1.25;
	letter-spacing: 0;
	text-transform: none;
}

.sem-single .sem-section__title::after {
	content: "";
	position: absolute;
	bottom: 0;
	left: 0;
	width: 48px;
	height: 4px;
	border-radius: 2px;
	background: var(--sem-accent, #b92025);
}

.sem-content {
	/* Keeps whatever an editor puts in the description (even absolutely / fixed positioned markup)
	   inside this box, so it can never cover the ticket buttons or the rest of the page. */
	position: relative;
	isolation: isolate;
	contain: paint;
	font-size: 17px;
	line-height: 1.8;
	overflow-wrap: anywhere;
}

.sem-content > :first-child {
	margin-top: 0;
}

.sem-content p {
	margin: 0 0 1.15em;
}

.sem-content h2,
.sem-content h3,
.sem-content h4 {
	margin: 1.6em 0 0.6em;
	line-height: 1.3;
}

.sem-content ul,
.sem-content ol {
	margin: 0 0 1.2em;
	padding-left: 1.4em;
}

.sem-content li {
	margin: 0 0 0.4em;
}

.sem-content a {
	color: var(--sem-accent, #b92025);
}

.sem-content img,
.sem-content iframe,
.sem-content video {
	max-width: 100%;
	border-radius: 10px;
}

.sem-content blockquote {
	margin: 1.4em 0;
	padding: 4px 0 4px 20px;
	border-left: 4px solid var(--sem-accent, #b92025);
	color: #555;
	font-style: italic;
}

/* Good to know */

.sem-good {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
	gap: 14px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.sem-good li {
	display: flex;
	align-items: flex-start;
	gap: 12px;
	margin: 0;
	padding: 16px 18px;
	border-radius: 12px;
	background: #f6f6f6;
	line-height: 1.5;
}

.sem-good .sem-icon {
	margin-top: 2px;
}

.sem-good strong {
	font-weight: 700;
}

/* Photos */

.sem-photos {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
	gap: 14px;
}

.sem-photos__item {
	margin: 0;
	padding: 0;
	line-height: 0;
}

.sem-single .sem-photos__item img {
	display: block;
	width: 100%;
	aspect-ratio: 4 / 3;
	border-radius: 12px;
	object-fit: cover;
}

/* Pictures open in the photo viewer: show that they are clickable. */

.sem-single .sem-hero__link {
	display: flex;
	justify-content: center;
	max-width: 100%;
	cursor: zoom-in;
}

.sem-single .sem-hero__link:focus-visible {
	outline: 3px solid #fff;
	outline-offset: 4px;
	border-radius: 12px;
}

.sem-single .sem-photos__link {
	position: relative;
	display: block;
	overflow: hidden;
	border-radius: 12px;
	line-height: 0;
	cursor: zoom-in;
}

.sem-single .sem-photos__link img {
	transition: transform 0.3s;
}

.sem-single .sem-photos__link:hover img,
.sem-single .sem-photos__link:focus-visible img {
	transform: scale(1.05);
}

.sem-single .sem-photos__link::after {
	content: "+";
	position: absolute;
	inset: 0;
	display: flex;
	align-items: center;
	justify-content: center;
	background: rgba(0, 0, 0, 0.3);
	color: #fff;
	font: 300 46px/1 Arial, Helvetica, sans-serif;
	opacity: 0;
	transition: opacity 0.2s;
}

.sem-single .sem-photos__link:hover::after,
.sem-single .sem-photos__link:focus-visible::after {
	opacity: 1;
}

.sem-single .sem-photos__link:focus-visible {
	outline: 3px solid var(--sem-accent, #b92025);
	outline-offset: 2px;
}

/* Location */

.sem-place {
	display: grid;
	gap: 22px;
	padding: 24px;
	border: 1px solid #e2e2e2;
	border-radius: 14px;
}

.sem-place__text {
	display: grid;
	gap: 2px;
	line-height: 1.5;
}

.sem-place__name {
	font-size: 19px;
	font-weight: 800;
}

.sem-dirs__label {
	margin: 0 0 10px;
	font-weight: 700;
}

.sem-dirs ul {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.sem-dirs li {
	margin: 0;
}

.sem-single .sem-dirs a {
	display: inline-flex;
	align-items: center;
	gap: 7px;
	padding: 9px 16px;
	border: 1px solid #d6d6d6;
	border-radius: 999px;
	background: #fff;
	color: var(--sem-text, #222);
	font-size: 14px;
	font-weight: 600;
	text-decoration: none;
	transition: border-color 0.15s, background-color 0.15s;
}

.sem-single .sem-dirs a:hover,
.sem-single .sem-dirs a:focus-visible {
	border-color: var(--sem-accent, #b92025);
	background: #fff6f6;
}

/* Hosted by */

.sem-host {
	display: flex;
	align-items: center;
	gap: 20px;
	padding: 22px 24px;
	border-radius: 14px;
	background: #f6f6f6;
}

.sem-host__logo {
	flex: 0 0 auto;
	line-height: 0;
}

.sem-single .sem-host__logo img {
	display: block;
	width: auto;
	max-width: 120px;
	height: auto;
	max-height: 70px;
	object-fit: contain;
}

.sem-host__text {
	display: grid;
	gap: 6px;
}

.sem-host__name {
	font-size: 18px;
	font-weight: 800;
}

.sem-single .sem-host__phone {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	color: var(--sem-text, #222);
	font-weight: 600;
	text-decoration: none;
	white-space: nowrap;
}

.sem-single .sem-host__phone:hover,
.sem-single .sem-host__phone:focus-visible {
	color: var(--sem-accent, #b92025);
	text-decoration: underline;
}

/* Share */

.sem-share {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
}

.sem-single .sem-share__btn {
	appearance: none;
	margin: 0;
	padding: 10px 18px;
	border: 1px solid #d6d6d6;
	border-radius: 999px;
	background: #fff;
	color: var(--sem-text, #222);
	font: inherit;
	font-size: 14px;
	font-weight: 600;
	line-height: 1.2;
	text-decoration: none;
	cursor: pointer;
	transition: border-color 0.15s, background-color 0.15s;
}

.sem-single .sem-share__btn:hover,
.sem-single .sem-share__btn:focus-visible {
	border-color: var(--sem-accent, #b92025);
	background: #fff6f6;
	color: var(--sem-text, #222);
}

/* ------------------------------------------------------------- More events */

.sem-more {
	width: 100%;
	padding: clamp(36px, 5vw, 64px) 0 clamp(40px, 6vw, 72px);
	border-top: 1px solid #e6e6e6;
	background: #f7f7f7;
}

.sem-protected {
	padding-top: 60px;
	padding-bottom: 60px;
}

/* ------------------------------------------------------------ Photo viewer */

/* The viewer is added to <body> by frontend.js, outside the page wrapper, so it styles itself. */

html.sem-lightbox-open {
	overflow: hidden;
}

.sem-lightbox {
	position: fixed;
	inset: 0;
	z-index: 999999;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 60px 84px 64px;
	background: rgba(8, 8, 10, 0.96);
	box-sizing: border-box;
	/* Fully visible by default; the fade-in is only a decoration that plays when the viewer is un-hidden. */
	animation: sem-lightbox-in 0.2s ease-out;
}

.sem-lightbox[hidden] {
	display: none;
}

@keyframes sem-lightbox-in {
	from {
		opacity: 0;
	}
}

.sem-lightbox *,
.sem-lightbox *::before,
.sem-lightbox *::after {
	box-sizing: border-box;
}

.sem-lightbox__figure {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 14px;
	max-width: 100%;
	max-height: 100%;
	margin: 0;
	padding: 0;
}

.sem-lightbox .sem-lightbox__img {
	display: block;
	width: auto;
	max-width: 100%;
	height: auto;
	max-height: calc(100vh - 160px);
	border-radius: 6px;
	background: #111;
	box-shadow: 0 20px 60px rgba(0, 0, 0, 0.6);
	object-fit: contain;
	transition: opacity 0.2s;
}

.sem-lightbox.is-loading .sem-lightbox__img {
	opacity: 0.25;
}

.sem-lightbox.is-loading::after {
	content: "";
	position: absolute;
	top: 50%;
	left: 50%;
	width: 38px;
	height: 38px;
	margin: -19px 0 0 -19px;
	border: 3px solid rgba(255, 255, 255, 0.25);
	border-top-color: #fff;
	border-radius: 50%;
	animation: sem-lightbox-spin 0.8s linear infinite;
}

@keyframes sem-lightbox-spin {
	to {
		transform: rotate(360deg);
	}
}

.sem-lightbox__caption {
	max-width: 70ch;
	margin: 0;
	color: #e6e6e6;
	font-size: 15px;
	line-height: 1.5;
	text-align: center;
}

.sem-lightbox__caption[hidden],
.sem-lightbox__count[hidden],
.sem-lightbox__nav[hidden] {
	display: none;
}

.sem-lightbox__count {
	position: absolute;
	bottom: 20px;
	left: 50%;
	color: #cfcfcf;
	font-size: 14px;
	letter-spacing: 0.08em;
	transform: translateX(-50%);
}

.sem-lightbox .sem-lightbox__close,
.sem-lightbox .sem-lightbox__nav {
	appearance: none;
	display: flex;
	align-items: center;
	justify-content: center;
	margin: 0;
	padding: 0;
	border: 0;
	border-radius: 50%;
	background: rgba(255, 255, 255, 0.14);
	box-shadow: none;
	color: #fff;
	font-family: Arial, Helvetica, sans-serif;
	line-height: 1;
	text-shadow: none;
	cursor: pointer;
	transition: background-color 0.15s;
}

.sem-lightbox .sem-lightbox__close:hover,
.sem-lightbox .sem-lightbox__nav:hover {
	background: rgba(255, 255, 255, 0.28);
}

.sem-lightbox .sem-lightbox__close:focus-visible,
.sem-lightbox .sem-lightbox__nav:focus-visible {
	outline: 3px solid #fff;
	outline-offset: 2px;
}

.sem-lightbox .sem-lightbox__close {
	position: absolute;
	top: 14px;
	right: 14px;
	width: 46px;
	height: 46px;
	font-size: 32px;
}

.sem-lightbox .sem-lightbox__nav {
	position: absolute;
	top: 50%;
	width: 52px;
	height: 52px;
	font-size: 40px;
	transform: translateY(-50%);
}

.sem-lightbox .sem-lightbox__nav--prev {
	inset-inline-start: 16px;
}

.sem-lightbox .sem-lightbox__nav--next {
	inset-inline-end: 16px;
}

[dir="rtl"] .sem-lightbox .sem-lightbox__nav {
	transform: translateY(-50%) scaleX(-1);
}

@media (max-width: 700px) {
	.sem-lightbox {
		padding: 64px 10px 56px;
	}

	.sem-lightbox .sem-lightbox__nav {
		top: auto;
		bottom: 8px;
		width: 44px;
		height: 44px;
		font-size: 32px;
		transform: none;
	}

	[dir="rtl"] .sem-lightbox .sem-lightbox__nav {
		transform: scaleX(-1);
	}

	.sem-lightbox .sem-lightbox__nav--prev {
		inset-inline-start: 14px;
	}

	.sem-lightbox .sem-lightbox__nav--next {
		inset-inline-end: 14px;
	}

	.sem-lightbox .sem-lightbox__img {
		max-height: calc(100vh - 150px);
	}
}

/* -------------------------------------------------------------- Small screens */

@media (max-width: 900px) {
	/* The ticket panel moves up, right under the title. */
	.sem-layout {
		grid-template-columns: minmax(0, 1fr);
		grid-template-areas:
			"aside"
			"main";
		padding-top: 22px;
	}

	.sem-layout--solo {
		grid-template-areas: "main";
	}

	.sem-aside {
		position: static;
	}

	.sem-facts {
		gap: 14px 28px;
	}
}

@media (max-width: 520px) {
	.sem-single__wrap {
		padding: 0 16px;
	}

	.sem-ticket {
		padding: 20px;
	}

	.sem-place,
	.sem-host {
		padding: 18px;
	}

	.sem-host {
		align-items: flex-start;
		flex-direction: column;
		gap: 14px;
	}
}

@media (prefers-reduced-motion: reduce) {
	.sem-ticket .sem-btn,
	.sem-single .sem-dirs a,
	.sem-single .sem-share__btn,
	.sem-single .sem-photos__link img,
	.sem-single .sem-photos__link::after,
	.sem-lightbox .sem-lightbox__img {
		transition: none;
	}

	.sem-lightbox {
		animation: none;
	}

	.sem-lightbox.is-loading::after {
		animation: none;
	}

	.sem-single .sem-photos__link:hover img,
	.sem-single .sem-photos__link:focus-visible img {
		transform: none;
	}

	.sem-ticket .sem-btn:hover,
	.sem-ticket .sem-btn:focus-visible {
		transform: none;
	}
}
