/**
 * WOG Events – frontend panels
 * Matched to live Elementor styles on https://wogkickboxing.co.za/
 * (post-297 events, post-23 home highlight, kit-9 globals)
 */

:root {
	/* Elementor kit-9 */
	--wog-color-primary: #ffd60a;
	--wog-color-primary-soft: #ffe16a;
	--wog-color-primary-hover: #f5b700;
	--wog-color-bg: #070707;
	--wog-color-surface: #161616;
	--wog-color-text: #f4f4f4;
	--wog-color-muted: #b8b8b8;
	--wog-color-ink: #101010;

	/* Panel chrome – same as Elementor event containers */
	--wog-panel-border: #ffd60a5c;
	--wog-panel-grad-start: #ffd60a2e;
	--wog-panel-grad-end: #ffd60a5c;
	--wog-panel-radius: 28px;
	--wog-panel-pad: 1rem;
	--wog-thumb-radius: 10px;
	--wog-thumb-max: 200px;
	--wog-thumb-height: 200px;

	--wog-font-body: "Manrope", system-ui, sans-serif;
	--wog-font-display: "Barlow Condensed", "Arial Narrow", sans-serif;
}

.wog-events,
.wog-event-panel,
.wog-events-lightbox {
	box-sizing: border-box;
	font-family: var(--wog-font-body);
}

.wog-events *,
.wog-events *::before,
.wog-events *::after,
.wog-event-panel *,
.wog-event-panel *::before,
.wog-event-panel *::after,
.wog-events-lightbox *,
.wog-events-lightbox *::before,
.wog-events-lightbox *::after {
	box-sizing: inherit;
}

/* -------------------------------------------------------------------------
   List wrapper
   ------------------------------------------------------------------------- */

.wog-events-list {
	display: flex;
	flex-direction: column;
	gap: 0; /* site stacks panels with ~15px outer padding each */
	width: 100%;
}

.wog-events-list > .wog-event-panel {
	margin: 15px 0;
}

/* -------------------------------------------------------------------------
   Empty state
   ------------------------------------------------------------------------- */

.wog-events-empty {
	padding: 1.25rem 1.5rem;
	min-height: 4rem;
	border: 1px solid var(--wog-panel-border);
	border-radius: var(--wog-panel-radius);
	background-image: linear-gradient(135deg, var(--wog-panel-grad-start) 0%, var(--wog-panel-grad-end) 100%);
	color: var(--wog-color-text);
}

.wog-events-empty__message {
	margin: 0;
	color: var(--wog-color-text) !important;
	font-size: 1rem;
	line-height: 1.5;
	opacity: 1;
}

/* -------------------------------------------------------------------------
   Event panel – matches Elementor containers (1b6fd732 / 1bb27ca etc.)
   ------------------------------------------------------------------------- */

.wog-event-panel {
	display: flex;
	flex-direction: column;
	align-items: stretch;
	gap: 0;
	width: 100%;
	padding: var(--wog-panel-pad);
	border: 1px solid var(--wog-panel-border);
	border-radius: var(--wog-panel-radius);
	/* Transparent base + gold wash – page bg (#070707) shows through */
	background-color: transparent;
	background-image: linear-gradient(135deg, var(--wog-panel-grad-start) 0%, var(--wog-panel-grad-end) 100%);
	color: var(--wog-color-muted);
}

.wog-event-panel__content {
	display: flex;
	flex-direction: column;
	gap: 0.35rem;
	flex: 1 1 220px;
	min-width: 0;
	text-align: start;
}

/* Eyebrow – site global .eyebrow */
.wog-event-panel__eyebrow {
	display: inline-flex;
	align-items: center;
	gap: 0.55rem;
	margin: 0 0 0.25rem;
	font-size: 0.78rem;
	font-weight: 800;
	letter-spacing: 0.2em;
	text-transform: uppercase;
	color: var(--wog-color-primary);
	line-height: 1.3;
}

.wog-event-panel__eyebrow::before {
	content: "";
	width: 2.5rem;
	height: 1px;
	background: currentColor;
	flex-shrink: 0;
}

/* Hide separate rule span if still present from older markup */
.wog-event-panel__eyebrow-rule {
	display: none;
}

/* Title – kit h3: Barlow Condensed, #F4F4F4, uppercase */
.wog-event-panel__title {
	margin: 0;
	font-family: var(--wog-font-display);
	font-size: 1.8rem;
	font-weight: 700;
	line-height: 1.15;
	letter-spacing: 0.01em;
	text-transform: uppercase;
	color: var(--wog-color-text);
}

.wog-event-panel__title-link {
	color: inherit;
	text-decoration: none;
}

.wog-event-panel__title-link:hover,
.wog-event-panel__title-link:focus-visible {
	color: var(--wog-color-primary);
}

/* Body copy */
.wog-event-panel__date,
.wog-event-panel__excerpt {
	margin: 0;
	font-family: var(--wog-font-body);
	font-size: 1rem;
	font-weight: 400;
	line-height: 1.5;
	color: var(--wog-color-muted);
}

/* Location links use kit link colour #FFD60A */
.wog-event-panel__location {
	margin: 0.15rem 0 0;
	font-size: 1rem;
	line-height: 1.45;
	font-weight: 400;
	color: var(--wog-color-primary);
}

.wog-event-panel__host {
	margin: 0.25rem 0 0;
	font-size: 0.95rem;
	line-height: 1.4;
	color: var(--wog-color-muted);
}

.wog-event-panel__host-label {
	font-weight: 600;
}

.wog-event-panel__location-link {
	color: var(--wog-color-primary);
	text-decoration: none;
}

.wog-event-panel__location-link:hover,
.wog-event-panel__location-link:focus-visible {
	color: var(--wog-color-primary-hover);
	text-decoration: underline;
	text-underline-offset: 2px;
}

/* Top row (next event): eyebrow left + See All right */
.wog-event-panel__top {
	display: flex !important;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 0.75rem 1.25rem;
	width: 100%;
	margin: 0 0 0.85rem;
	visibility: visible !important;
	opacity: 1 !important;
	position: relative;
	z-index: 2;
}

.wog-event-panel__top .wog-event-panel__eyebrow {
	display: inline-flex !important;
	margin: 0;
	flex: 1 1 auto;
	min-width: 0;
	visibility: visible !important;
	opacity: 1 !important;
	color: var(--wog-color-primary) !important;
}

.wog-event-panel__actions {
	display: flex;
	justify-content: flex-end;
	align-items: center;
	flex: 0 0 auto;
	margin-left: auto;
	padding: 0;
}

.wog-event-panel__see-all {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-height: 44px;
	padding: 0.7rem 1.35rem;
	border-radius: 999px;
	background: linear-gradient(135deg, var(--wog-color-primary) 0%, var(--wog-color-primary-soft) 100%);
	color: var(--wog-color-ink) !important;
	font-family: var(--wog-font-body);
	font-size: 0.85rem;
	font-weight: 800;
	letter-spacing: 0.04em;
	text-transform: uppercase;
	text-decoration: none;
	line-height: 1.2;
	white-space: nowrap;
	border: 0;
	transition: filter 0.15s ease, transform 0.15s ease;
}

.wog-event-panel__see-all:hover,
.wog-event-panel__see-all:focus-visible {
	filter: brightness(1.05);
	transform: translateY(-1px);
	color: var(--wog-color-ink) !important;
}

/* Event body: text + thumbnail */
.wog-event-panel__main {
	display: flex;
	flex-wrap: wrap;
	align-items: flex-start;
	justify-content: space-between;
	gap: 1rem 1.5rem;
	width: 100%;
}

.wog-event-panel__main .wog-event-panel__content {
	flex: 1 1 220px;
	min-width: 0;
}

/* Thumbnail – site image ~212×300, radius 10px, end-aligned */
.wog-event-panel__media {
	display: flex;
	justify-content: flex-end;
	align-items: center;
	flex: 0 0 auto;
	text-align: end;
}

.wog-event-panel__thumb {
	position: relative;
	display: block;
	margin: 0;
	padding: 0;
	border: 0;
	border-radius: var(--wog-thumb-radius);
	background: transparent;
	cursor: zoom-in;
	overflow: hidden;
	max-width: var(--wog-thumb-max);
	width: 100%;
	line-height: 0;
	transition: outline 0.15s ease, transform 0.15s ease;
}

.wog-event-panel__thumb:hover,
.wog-event-panel__thumb:focus-visible {
	transform: scale(1.02);
	/* Charcoal behind transparent PNGs + focus ring (was gold/red-looking). */
	background-color: #2a2a2a;
	outline: 2px solid #3a3a3a;
	outline-offset: 3px;
}

.wog-event-panel__image {
	display: block;
	width: auto;
	height: var(--wog-thumb-height);
	max-width: var(--wog-thumb-max);
	max-height: var(--wog-thumb-height);
	border-radius: var(--wog-thumb-radius);
	object-fit: cover;
}

.wog-event-panel__description {
	color: var(--wog-color-muted);
	font-size: 1rem;
	line-height: 1.5;
}

.wog-event-panel__description p {
	margin: 0 0 0.5rem;
	color: inherit;
}

.wog-event-panel__description p:last-child {
	margin-bottom: 0;
}

.wog-event-panel__thumb-hint {
	position: absolute;
	right: 0.35rem;
	bottom: 0.35rem;
	padding: 0.2rem 0.4rem;
	border-radius: 4px;
	background: rgba(0, 0, 0, 0.7);
	color: #fff;
	font-size: 0.65rem;
	font-weight: 800;
	letter-spacing: 0.06em;
	text-transform: uppercase;
	line-height: 1.2;
	pointer-events: none;
	opacity: 0;
	transition: opacity 0.15s ease;
}

.wog-event-panel__thumb:hover .wog-event-panel__thumb-hint,
.wog-event-panel__thumb:focus-visible .wog-event-panel__thumb-hint {
	opacity: 1;
}

/* Next event: stacked top bar + main row */
.wog-event-panel--next {
	display: flex;
	flex-direction: column;
	align-items: stretch;
	gap: 0;
}

@media (min-width: 768px) {
	.wog-event-panel__main {
		flex-wrap: nowrap;
		align-items: center;
	}

	.wog-event-panel__media {
		flex: 0 0 auto;
		margin-left: auto;
	}
}

@media (max-width: 767px) {
	.wog-event-panel {
		flex-direction: column;
	}

	.wog-event-panel__top {
		flex-direction: column;
		align-items: flex-start;
	}

	.wog-event-panel__actions {
		margin-left: 0;
		width: 100%;
		justify-content: flex-start;
	}

	.wog-event-panel--has-image .wog-event-panel__media {
		justify-content: flex-start;
		text-align: start;
	}

	.wog-event-panel__thumb {
		max-width: 160px;
	}

	.wog-event-panel__image {
		max-width: 160px;
		height: 160px;
		max-height: 160px;
	}

	.wog-event-panel__title {
		font-size: 1.5rem;
	}
}

/* -------------------------------------------------------------------------
   Lightbox
   ------------------------------------------------------------------------- */

.wog-events-lightbox {
	position: fixed;
	inset: 0;
	z-index: 100000;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 1.5rem;
	background: rgba(0, 0, 0, 0.9);
	opacity: 0;
	visibility: hidden;
	pointer-events: none;
	transition: opacity 0.2s ease, visibility 0.2s ease;
}

.wog-events-lightbox.is-open {
	opacity: 1;
	visibility: visible;
	pointer-events: auto;
}

.wog-events-lightbox__dialog {
	position: relative;
	max-width: min(96vw, 1100px);
	max-height: 92vh;
	outline: none;
}

.wog-events-lightbox__img {
	display: block;
	max-width: 96vw;
	max-height: 88vh;
	width: auto;
	height: auto;
	margin: 0 auto;
	border-radius: 8px;
	box-shadow: 0 12px 40px rgba(0, 0, 0, 0.5);
	object-fit: contain;
}

.wog-events-lightbox__close {
	position: absolute;
	top: -0.35rem;
	right: -0.35rem;
	z-index: 2;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 2.5rem;
	height: 2.5rem;
	margin: 0;
	padding: 0;
	border: 2px solid #fff;
	border-radius: 999px;
	background: #111;
	color: #fff;
	font-size: 1.5rem;
	font-weight: 400;
	line-height: 1;
	cursor: pointer;
	transform: translate(40%, -40%);
	transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.wog-events-lightbox__close:hover,
.wog-events-lightbox__close:focus-visible {
	background: var(--wog-color-primary);
	color: var(--wog-color-ink);
	border-color: var(--wog-color-primary);
	outline: none;
}

body.wog-events-lightbox-open {
	overflow: hidden;
}
