/* Chaos Eventi – «Next events» in the homes. Fonts, colours and sizes are set on the Bricks elements;
 * here only what Bricks cannot do inside a loop: the run grid borders and the underline of the links. */

/* Run grid: every cell has a left and bottom border from Bricks, here the right edge closes the row. */
.cl-ne-wrap--dark {
	--cl-ne-line: var(--white, #fffcec);
}
.cl-ne-wrap--light {
	--cl-ne-line: var(--dark-gray, #1b1b1b);
}
.cl-ne__run:last-child,
.cl-ne__run:nth-child(4n) {
	border-right: 2px solid var(--cl-ne-line, currentColor) !important;
}
@media (max-width: 478px) {
	.cl-ne__run:nth-child(2n) {
		border-right: 2px solid var(--cl-ne-line, currentColor) !important;
	}
}
.cl-ne__run-state:empty {
	display: none;
}

/* Underline of the event name: appears on hover, from the left (like the old «side to side»). */
.cl-ne__name a,
.cl-ne__link a,
a.cl-ne__link {
	position: relative;
	display: inline-block;
	color: inherit;
	text-decoration: none;
}
.cl-ne__name a::before,
.cl-ne__link a::before,
.cl-ne__link a::after,
a.cl-ne__link::before,
a.cl-ne__link::after {
	content: "";
	position: absolute;
	left: 0;
	right: 0;
	bottom: 0;
	height: 2px;
	background: currentColor;
	transition: transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}
.cl-ne__name a::before {
	transform: scaleX(0);
	transform-origin: right center;
}
.cl-ne__name a:hover::before,
.cl-ne__name a:focus-visible::before {
	transform: scaleX(1);
	transform-origin: left center;
}

/* «info» and the button: underline always there, on hover it runs out to the right and comes back from the left. */
.cl-ne__link a::before,
a.cl-ne__link::before {
	transform: scaleX(0);
	transform-origin: left center;
}
.cl-ne__link a::after,
a.cl-ne__link::after {
	transform: scaleX(1);
	transform-origin: right center;
}
.cl-ne__link a:hover::before,
a.cl-ne__link:hover::before {
	transform: scaleX(1);
	transition-delay: 0.25s;
}
.cl-ne__link a:hover::after,
a.cl-ne__link:hover::after {
	transform: scaleX(0);
}

/* Empty list: the fallback text from the loop's «No results». */
.cl-ne-wrap > .bricks-posts-nothing-found {
	width: 100% !important;
}
.cl-ne-empty {
	width: 100%;
	border: 2px solid currentColor;
	padding: var(--space-s, 1.5rem);
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: var(--space-s, 1.5rem);
}
.cl-ne-wrap--dark .cl-ne-empty {
	color: var(--white, #fffcec);
}
.cl-ne-wrap--light .cl-ne-empty {
	color: var(--dark-gray, #1b1b1b);
}
.cl-ne-empty__text {
	margin: 0;
	font-family: "Bogart Italic", serif;
	font-size: var(--text-2xl, 2.4rem);
	line-height: 1.1;
	max-width: 32ch;
}
.cl-ne-wrap--light .cl-ne-empty__text {
	font-family: "BurgelaRegularChaosExt", serif;
}
.cl-ne-empty__btn {
	font-family: "Barlow Condensed Light", sans-serif;
	font-size: var(--text-2xl, 2.4rem);
	text-transform: uppercase;
	padding: var(--space-2xs, 0.8rem) var(--space-s, 1.5rem);
	background: currentColor;
}
.cl-ne-empty__btn span {
	color: var(--dark-gray, #1b1b1b);
}
.cl-ne-wrap--light .cl-ne-empty__btn span {
	color: var(--white, #fffcec);
}
