/**
 * Styles for the Labrisa Core "Regular Events" Elementor widget.
 * Registered as the 'labrisa-core-regular-events' handle and loaded on
 * demand via the widget's get_style_depends().
 *
 * Structurally identical to labrisa-core-all-events.css (same shared
 * .labrisa-marquee/.labrisa-event-slide* component classes) — kept as a
 * separate file/handle per widget, matching this plugin's existing
 * convention, so each widget's assets stay self-contained.
 */

.labrisa-regular-events {
	position: relative;
}

.labrisa-marquee {
	--labrisa-marquee-gap: 24px;
	--labrisa-marquee-columns: 4;
	--labrisa-marquee-ratio: 1.33;
	--labrisa-marquee-peek: 0;
	position: relative;
}

.labrisa-marquee__swiper {
	width: 100%;
	overflow: hidden;
}

.labrisa-marquee__swiper .swiper-wrapper {
	align-items: stretch;
}

.labrisa-marquee__swiper .swiper-slide {
	/* --labrisa-marquee-columns slides fit per view, evenly sized, with
	   --labrisa-marquee-gap between them (Swiper adds that gap itself via
	   spaceBetween, so it only needs subtracting here once per gap). When
	   --labrisa-marquee-peek is > 0 ("Enable Offset" control), the divisor
	   grows by that fraction so an extra sliver of the next card shows at
	   the right edge only — the left edge is never touched, since this is
	   plain narrower sizing, not a scroll/slide offset. */
	width: calc( ( 100% - ( var(--labrisa-marquee-columns) - 1 + var(--labrisa-marquee-peek) ) * var(--labrisa-marquee-gap) ) / ( var(--labrisa-marquee-columns) + var(--labrisa-marquee-peek) ) );
	height: auto;
	/* .swiper-wrapper's align-items: stretch already equalizes every slide
	   in a row to the tallest one's natural height; making the slide itself
	   a flex column (with __media pinned to its aspect-ratio height and
	   __body filling what's left, see below) is what makes each card
	   actually use that equal height instead of just reserving empty space
	   at the bottom of the shorter ones. */
	display: flex;
	flex-direction: column;
}

/* Nav sits below the carousel, right-aligned, instead of overlaying the
   slide images. */
.labrisa-marquee__nav {
	display: flex;
	justify-content: flex-end;
	gap: 8px;
	margin-top: 16px;
}

.labrisa-marquee__nav-btn {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 40px;
	height: 40px;
	padding: 0;
	background-color: #ffffff;
	color: #111111;
	border: 1px solid rgba(0, 0, 0, 0.15);
	border-radius: 50%;
	cursor: pointer;
	transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.labrisa-marquee__nav-btn.swiper-button-disabled {
	opacity: 0.35;
	cursor: default;
	pointer-events: none;
}

.labrisa-event-slide__media {
	position: relative;
	display: block;
	overflow: hidden;
	border-radius: 4px;
	aspect-ratio: var(--labrisa-marquee-ratio, 1.33);
	background-color: rgba(0, 0, 0, 0.05);
	flex-shrink: 0;
}

.labrisa-event-slide__image {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
	transition: transform 0.35s ease;
}

.labrisa-event-slide__overlay {
	position: absolute;
	inset: 0;
	background-color: rgba(0, 0, 0, 0);
	transition: background-color 0.35s ease;
	pointer-events: none;
}

.labrisa-event-slide__body {
	display: flex;
	flex-direction: column;
	flex: 1 1 auto;
	gap: 6px;
	padding: 16px;
}

.labrisa-event-slide__title {
	color: #ffffff;
	font-weight: 600;
	line-height: 1.3;
	transition: color 0.2s ease;
}

.labrisa-event-slide__meta {
	display: flex;
	flex-direction: column;
	gap: 4px;
	color: rgba(255, 255, 255, 0.8);
	font-size: 13px;
	transition: color 0.2s ease;
}

.labrisa-event-slide__meta-row {
	display: flex;
	align-items: center;
}

.labrisa-event-slide__meta-icon {
	width: 14px;
	height: 14px;
	margin-right: 4px;
	flex-shrink: 0;
}

.labrisa-event-slide__actions {
	display: flex;
	flex-wrap: nowrap;
	gap: 8px;
	margin-top: auto;
	padding-top: 8px;
	justify-content: space-between;
}

.labrisa-event-slide__btn {
	display: inline-flex;
	flex: 0 0 50%;
	box-sizing: border-box;
	align-items: center;
	justify-content: center;
	padding: 8px 16px;
	font-size: 13px;
	font-weight: 600;
	border-radius: 4px;
	text-decoration: none;
	cursor: pointer;
	border: 1px solid transparent;
	background-color: transparent;
	transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.labrisa-event-slide__btn--primary {
	background-color: #111111;
	color: #ffffff;
}

.labrisa-event-slide__btn--secondary {
	color: #ffffff;
	border-color: rgba(255, 255, 255, 0.6);
}

/* Explore popup */

.labrisa-event-modal {
	position: fixed;
	inset: 0;
	z-index: 100000;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 24px;
}

.labrisa-event-modal[hidden] {
	display: none;
}

.labrisa-event-modal__backdrop {
	position: absolute;
	inset: 0;
	background-color: rgba(0, 0, 0, 0.1);
	backdrop-filter: blur(50px);
}

.labrisa-event-modal__dialog {
	position: relative;
	z-index: 1;
	width: 100%;
	max-width: 720px;
	max-height: 90vh;
	overflow-y: auto;
	background-color: #ffffff;
	border-radius: 8px;
}

.labrisa-event-modal__close {
	position: absolute;
	top: 12px;
	right: 12px;
	z-index: 2;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 32px;
	height: 32px;
	padding: 0;
	background-color: rgba(0, 0, 0, 0.5);
	color: #ffffff;
	border: 0;
	border-radius: 50%;
	font-size: 20px;
	line-height: 1;
	cursor: pointer;
}

.labrisa-event-modal__media img {
	display: block;
	width: 100%;
	height: auto;
}

.labrisa-event-modal__body {
	padding: 24px;
}

.labrisa-event-modal__title {
	margin: 0 0 8px;
}

.labrisa-event-modal__meta {
	margin-bottom: 16px;
	color: #666666;
	font-size: 14px;
}

.labrisa-event-modal__terms {
	margin-bottom: 24px;
	line-height: 1.6;
}

.labrisa-event-modal__cta {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	padding: 10px 24px;
	background-color: #111111;
	color: #ffffff;
	text-decoration: none;
	border-radius: 4px;
	font-weight: 600;
}

body.labrisa-event-modal-open {
	overflow: hidden;
}
