/* EsportHub Events – Standard-Design passend zu esennstal.at.
   Farben und Schrift über Variablen anpassen, z. B. in Elementor → Benutzerdefiniertes CSS:
   .ehe { --ehe-accent: #a4cc39; --ehe-font: "Open Sans", sans-serif; } */

.ehe {
	--ehe-accent: #a4cc39;
	--ehe-accent-strong: #3db54a;
	--ehe-surface: #161616;
	--ehe-surface-2: #1f1f1f;
	--ehe-border: #2c2c2c;
	--ehe-text: #ececec;
	--ehe-muted: #9b9b9b;
	--ehe-on-accent: #0b0b0b;
	--ehe-live: #ff3b4e;
	--ehe-radius: 10px;
	color: var(--ehe-text);
	/* Eigene Schrift festlegen, damit Stile umgebender Widgets (z. B. Überschrift, Code) nicht durchschlagen. */
	font-family: var(--ehe-font, "Open Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif);
	font-size: 15px;
	font-weight: 400;
	font-style: normal;
	line-height: 1.5;
	letter-spacing: normal;
	text-transform: none;
	text-align: left;
	white-space: normal;
	word-spacing: normal;
}
.ehe *, .ehe *::before, .ehe *::after { box-sizing: border-box; }
.ehe h3, .ehe h4 { font-family: inherit; letter-spacing: normal; text-transform: none; }
.ehe [hidden] { display: none !important; }
.ehe-visually-hidden {
	position: absolute !important;
	width: 1px; height: 1px;
	margin: -1px; padding: 0;
	overflow: hidden;
	clip: rect(0 0 0 0);
	white-space: nowrap;
	border: 0;
}

/* Typfarben (Termin-Art) und daraus abgeleitete Akzentfarbe; ein Spiel hat Vorrang. */
.ehe-type-lan        { --ehe-type: #f5a623; }
.ehe-type-tournament { --ehe-type: #ff6b81; }
.ehe-type-league     { --ehe-type: #4aa8ff; }
.ehe-type-training   { --ehe-type: #a88bff; }
.ehe-type-meeting    { --ehe-type: #9b9b9b; }
.ehe-card, .ehe-event, .ehe-cal-event, .ehe-detail, .ehe-chip {
	--ehe-c: var(--ehe-game, var(--ehe-type, var(--ehe-accent)));
}

/* Gemeinsame Bausteine */
.ehe-badge {
	display: inline-block;
	font-size: 11px;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: .06em;
	line-height: 1.6;
	padding: 0 8px;
	border-radius: 999px;
	border: 1px solid currentColor;
	color: var(--ehe-type, var(--ehe-accent));
}
.ehe-card-tags { display: flex; flex-wrap: wrap; gap: 6px; }
.ehe .ehe-game-tag { line-height: 1.6; padding: 0 8px; }

.ehe .ehe-btn {
	display: inline-block;
	padding: 8px 14px;
	border: 1px solid transparent;
	border-radius: 6px;
	background: var(--ehe-accent);
	color: var(--ehe-on-accent);
	font-weight: 700;
	font-size: 14px;
	line-height: 1.3;
	letter-spacing: normal;
	text-transform: none;
	text-decoration: none;
	transition: background .15s ease, border-color .15s ease, color .15s ease;
}
.ehe .ehe-btn:hover, .ehe .ehe-btn:focus-visible { background: var(--ehe-accent-strong); color: var(--ehe-on-accent); }
.ehe .ehe-btn-ghost { background: transparent; color: var(--ehe-text); border-color: var(--ehe-border); }
.ehe .ehe-btn-ghost:hover, .ehe .ehe-btn-ghost:focus-visible { background: var(--ehe-surface-2); color: var(--ehe-accent); border-color: var(--ehe-accent); }
.ehe .ehe-btn-live { background: var(--ehe-live); color: #fff; }
.ehe .ehe-btn-live:hover, .ehe .ehe-btn-live:focus-visible { background: #e02a3c; color: #fff; }

.ehe .ehe-reg { margin: 0; font-size: 13px; color: var(--ehe-muted); }
.ehe .ehe-reg.is-open { color: var(--ehe-accent); font-weight: 600; }
.ehe .ehe-reg.is-full { color: #f5a623; font-weight: 600; }
.ehe-reg-bar { display: block; height: 4px; margin-top: 6px; border-radius: 4px; background: var(--ehe-surface-2); overflow: hidden; }
.ehe-reg-bar span { display: block; height: 100%; background: currentColor; border-radius: 4px; }

.ehe .ehe-chip {
	appearance: none;
	display: inline-flex;
	align-items: center;
	gap: 6px;
	border: 1px solid var(--ehe-border);
	border-radius: 999px;
	padding: 6px 14px;
	background: var(--ehe-surface);
	color: var(--ehe-text);
	font: inherit;
	font-size: 13px;
	font-weight: 600;
	line-height: 1.2;
	letter-spacing: normal;
	text-transform: none;
	box-shadow: none;
	cursor: pointer;
}
.ehe .ehe-chip:hover, .ehe .ehe-chip:focus-visible { border-color: var(--ehe-c); background: var(--ehe-surface); color: var(--ehe-text); }
.ehe .ehe-chip[aria-pressed="true"] { border-color: var(--ehe-c); background: var(--ehe-c); color: var(--ehe-on-accent); }
.ehe-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--ehe-c); }
.ehe .ehe-chip[aria-pressed="true"] .ehe-dot { background: var(--ehe-on-accent); }

.ehe-vs-row { display: flex; align-items: center; gap: 10px; min-width: 0; }
.ehe-vs-team { display: inline-flex; align-items: center; gap: 8px; min-width: 0; font-weight: 700; }
.ehe-vs-team .ehe-team-logo { flex: 0 0 32px; width: 32px; height: 32px; font-size: 11px; }

.ehe .ehe-empty {
	margin: 0;
	padding: 16px;
	border: 1px dashed var(--ehe-border);
	border-radius: var(--ehe-radius);
	color: var(--ehe-muted);
}
.ehe .ehe-error {
	margin: 0;
	padding: 12px 16px;
	border: 1px solid #b94a48;
	border-radius: var(--ehe-radius);
	background: rgba(185, 74, 72, .12);
	color: var(--ehe-text);
}
.ehe-admin-note { font-size: 12px; color: var(--ehe-muted); margin: 8px 0 0; }

/* ==================================================================
   Karten [esporthub_events]
   ================================================================== */

.ehe-cards {
	--ehe-gap: 18px;
	display: grid;
	/* So viele Spalten wie eingestellt, aber nie schmaler als 250px – darunter automatisch weniger. */
	grid-template-columns: repeat(auto-fit, minmax(max(250px, calc((100% - (var(--ehe-cols, 3) - 1) * var(--ehe-gap)) / var(--ehe-cols, 3))), 1fr));
	gap: var(--ehe-gap);
}
.ehe-card {
	position: relative;
	display: flex;
	flex-direction: column;
	min-width: 0;
	background: var(--ehe-surface);
	border: 1px solid var(--ehe-border);
	border-radius: 12px;
	overflow: hidden;
	transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease;
}
.ehe-card::before { content: ""; display: block; height: 4px; background: var(--ehe-c); }
.ehe-card:hover {
	transform: translateY(-3px);
	border-color: color-mix(in srgb, var(--ehe-c) 45%, var(--ehe-border));
	box-shadow: 0 10px 28px rgba(0, 0, 0, .35);
}
.ehe-card.is-live { border-color: rgba(255, 59, 78, .55); }
.ehe-card.is-live::before { background: var(--ehe-live); }
@media (prefers-reduced-motion: reduce) { .ehe-card, .ehe-card:hover { transition: none; transform: none; } }

.ehe-card-image img { display: block; width: 100%; aspect-ratio: 16 / 9; object-fit: cover; }

.ehe-card-head { display: flex; align-items: center; gap: 12px; padding: 16px 18px 0; }
.ehe-card-date {
	flex: 0 0 auto;
	min-width: 56px;
	padding: 7px 8px 6px;
	border-radius: 10px;
	text-align: center;
	background: color-mix(in srgb, var(--ehe-c) 14%, var(--ehe-surface-2));
	border: 1px solid color-mix(in srgb, var(--ehe-c) 30%, transparent);
}
.ehe-card-day { display: block; font-size: 24px; font-weight: 800; line-height: 1; color: var(--ehe-c); font-variant-numeric: tabular-nums; }
.ehe-card-day.is-range { font-size: 18px; }
.ehe-card-month { display: block; margin-top: 4px; font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; color: var(--ehe-muted); }
.ehe-card-when { display: flex; flex-direction: column; min-width: 0; }
.ehe-card-weekday { font-weight: 700; color: var(--ehe-text); }
.ehe-card-time { font-size: 13px; color: var(--ehe-muted); font-variant-numeric: tabular-nums; }
.ehe-card-rel {
	margin-left: auto;
	align-self: flex-start;
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 2px 10px;
	border-radius: 999px;
	background: color-mix(in srgb, var(--ehe-accent) 16%, transparent);
	color: var(--ehe-accent);
	font-size: 12px;
	font-weight: 700;
	white-space: nowrap;
}
.ehe-card-rel.is-live { background: rgba(255, 59, 78, .14); color: var(--ehe-live); }

.ehe-card-body { flex: 1; display: flex; flex-direction: column; gap: 8px; padding: 14px 18px 16px; }
.ehe .ehe-card .ehe-title { margin: 0; font-size: 18px; font-weight: 700; line-height: 1.3; color: var(--ehe-text); overflow-wrap: anywhere; }
.ehe .ehe-card-sub, .ehe .ehe-card-place, .ehe .ehe-card-desc { margin: 0; font-size: 13px; color: var(--ehe-muted); }
.ehe .ehe-card-desc {
	color: var(--ehe-text);
	opacity: .8;
	display: -webkit-box;
	-webkit-line-clamp: 3;
	-webkit-box-orient: vertical;
	overflow: hidden;
}
.ehe-card-place { display: flex; align-items: flex-start; gap: 6px; }
.ehe-icon-pin {
	flex: 0 0 12px;
	width: 12px;
	height: 15px;
	margin-top: 2px;
	background: currentColor;
	-webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 30'%3E%3Cpath d='M12 0C5.4 0 0 5.3 0 11.9 0 20.8 12 30 12 30s12-9.2 12-18.1C24 5.3 18.6 0 12 0zm0 16.5a4.6 4.6 0 1 1 0-9.2 4.6 4.6 0 0 1 0 9.2z'/%3E%3C/svg%3E") center / contain no-repeat;
	mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 30'%3E%3Cpath d='M12 0C5.4 0 0 5.3 0 11.9 0 20.8 12 30 12 30s12-9.2 12-18.1C24 5.3 18.6 0 12 0zm0 16.5a4.6 4.6 0 1 1 0-9.2 4.6 4.6 0 0 1 0 9.2z'/%3E%3C/svg%3E") center / contain no-repeat;
}
.ehe-card-vs { padding: 4px 0; font-size: 15px; }
.ehe-card-vs .ehe-vs-team { flex: 1 1 0; }
.ehe-card-vs .ehe-vs-team.is-away { justify-content: flex-end; text-align: right; }
.ehe-card-vs .ehe-vs-team.is-away .ehe-team-logo { order: 2; }
.ehe-card-vs .ehe-team-name {
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
	line-height: 1.25;
	overflow-wrap: break-word;
	-webkit-hyphens: auto;
	hyphens: auto;
}

.ehe-card-foot { display: flex; flex-wrap: wrap; gap: 8px; padding: 0 18px 18px; }
.ehe .ehe-card-foot .ehe-btn { flex: 1 1 auto; text-align: center; }

/* ==================================================================
   Liste (layout="list" und Handy-Ansicht des Kalenders)
   ================================================================== */

.ehe-list, .ehe-cal-list { display: flex; flex-direction: column; gap: 12px; }
.ehe-event {
	display: flex;
	gap: 16px;
	align-items: flex-start;
	padding: 14px 16px;
	background: var(--ehe-surface);
	border: 1px solid var(--ehe-border);
	border-left: 4px solid var(--ehe-c);
	border-radius: var(--ehe-radius);
}
.ehe-date {
	flex: 0 0 58px;
	text-align: center;
	background: color-mix(in srgb, var(--ehe-c) 12%, var(--ehe-surface-2));
	border-radius: 8px;
	padding: 8px 4px;
}
.ehe-date-day { display: block; font-size: 24px; font-weight: 800; line-height: 1; color: var(--ehe-c); }
.ehe-date-month { display: block; margin-top: 4px; font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--ehe-muted); }
.ehe-body { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 6px; }
.ehe .ehe-event .ehe-title { margin: 0; font-size: 17px; font-weight: 700; line-height: 1.3; color: var(--ehe-text); }
.ehe .ehe-title a { color: inherit; text-decoration: none; }
.ehe .ehe-title a:hover { color: var(--ehe-accent); }
.ehe .ehe-meta, .ehe .ehe-desc { margin: 0; font-size: 14px; color: var(--ehe-muted); }
.ehe .ehe-desc { color: var(--ehe-text); opacity: .85; }
.ehe-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 2px; }
.ehe-image { flex: 0 0 160px; }
.ehe-image img { display: block; width: 100%; height: auto; border-radius: 8px; }

/* ==================================================================
   Kalender [esporthub_calendar]
   ================================================================== */

.ehe-cal { container-type: inline-size; display: flex; flex-direction: column; gap: 14px; }
.ehe-cal-head { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 12px; }
.ehe .ehe-cal-title { margin: 0; font-size: 26px; font-weight: 700; line-height: 1.2; color: var(--ehe-text); }
.ehe-cal-nav { display: flex; gap: 6px; }
.ehe .ehe-cal-nav a {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 38px;
	height: 38px;
	padding: 0 14px;
	border: 1px solid var(--ehe-border);
	border-radius: 8px;
	background: var(--ehe-surface);
	color: var(--ehe-text);
	text-decoration: none;
	font-size: 14px;
	font-weight: 700;
	line-height: 1;
}
.ehe .ehe-cal-nav a:hover, .ehe .ehe-cal-nav a:focus-visible { border-color: var(--ehe-accent); color: var(--ehe-accent); }
.ehe .ehe-cal-nav a[aria-current] { border-color: var(--ehe-accent); color: var(--ehe-accent); }

.ehe-cal-legend { display: none; flex-wrap: wrap; gap: 8px; }
.ehe-cal.is-ready .ehe-cal-legend { display: flex; }

.ehe-cal-grid {
	display: grid;
	grid-template-columns: repeat(7, minmax(0, 1fr));
	gap: 1px;
	background: var(--ehe-border);
	border: 1px solid var(--ehe-border);
	border-radius: 12px;
	overflow: hidden;
}
.ehe-cal-wd {
	background: var(--ehe-surface-2);
	padding: 10px 8px;
	text-align: center;
	font-size: 12px;
	font-weight: 700;
	letter-spacing: .08em;
	text-transform: uppercase;
	color: var(--ehe-muted);
}
.ehe-cal-day {
	position: relative;
	background: var(--ehe-surface);
	min-height: 122px;
	padding: 6px;
	display: flex;
	flex-direction: column;
	gap: 4px;
	min-width: 0;
}
.ehe-cal-day.is-weekend { background: #191919; }
.ehe-cal-day.is-outside { background: #121212; }
.ehe-cal-day.is-outside > * { opacity: .45; }
.ehe-cal-day.is-past .ehe-cal-event { opacity: .55; }
.ehe-cal-day.is-today { box-shadow: inset 0 0 0 2px var(--ehe-accent); }
.ehe-cal-num {
	align-self: flex-end;
	min-width: 26px;
	height: 26px;
	padding: 0 6px;
	line-height: 26px;
	text-align: center;
	border-radius: 999px;
	font-size: 13px;
	font-weight: 700;
	color: var(--ehe-muted);
	font-variant-numeric: tabular-nums;
}
.ehe-cal-day.is-today .ehe-cal-num { background: var(--ehe-accent); color: var(--ehe-on-accent); }

.ehe .ehe-cal-event {
	appearance: none;
	display: flex;
	flex-direction: column;
	gap: 1px;
	width: 100%;
	min-height: 0;
	height: auto;
	margin: 0;
	padding: 4px 7px 5px;
	border: 0;
	border-left: 3px solid var(--ehe-c);
	border-radius: 5px;
	background: color-mix(in srgb, var(--ehe-c) 13%, var(--ehe-surface-2));
	box-shadow: none;
	color: var(--ehe-text);
	font: inherit;
	font-size: 12px;
	font-weight: 600;
	line-height: 1.3;
	letter-spacing: normal;
	text-align: left;
	text-transform: none;
	cursor: pointer;
	transition: background .15s ease;
}
.ehe .ehe-cal-event:hover, .ehe .ehe-cal-event:focus-visible {
	background: color-mix(in srgb, var(--ehe-c) 26%, var(--ehe-surface-2));
	color: var(--ehe-text);
	outline: none;
}
.ehe .ehe-cal-event:focus-visible { box-shadow: 0 0 0 2px var(--ehe-c); }
.ehe-cal-time { font-size: 11px; font-weight: 700; color: var(--ehe-c); font-variant-numeric: tabular-nums; }
.ehe-cal-label {
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
	overflow-wrap: break-word;
	-webkit-hyphens: auto;
	hyphens: auto;
}
.ehe-cal-event.is-continued { opacity: .75; }
.ehe-cal-event.is-continued .ehe-cal-time { font-weight: 600; }
.ehe-cal.is-ready .ehe-cal-event.is-over,
.ehe-cal.is-ready .ehe-cal-event.is-filtered { display: none; }

.ehe .ehe-cal-more {
	appearance: none;
	align-self: flex-start;
	margin: 0;
	padding: 2px 6px;
	border: 0;
	border-radius: 4px;
	background: transparent;
	box-shadow: none;
	color: var(--ehe-muted);
	font: inherit;
	font-size: 12px;
	font-weight: 700;
	letter-spacing: normal;
	text-transform: none;
	cursor: pointer;
}
.ehe .ehe-cal-more:hover, .ehe .ehe-cal-more:focus-visible { background: var(--ehe-surface-2); color: var(--ehe-accent); }

.ehe-cal-list { display: none; }
.ehe-cal-past { border: 1px dashed var(--ehe-border); border-radius: var(--ehe-radius); }
.ehe-cal-past > summary {
	padding: 10px 14px;
	color: var(--ehe-muted);
	font-size: 13px;
	font-weight: 700;
	cursor: pointer;
	list-style-position: inside;
}
.ehe-cal-past > summary:hover { color: var(--ehe-accent); }
.ehe-cal-past[open] > summary { border-bottom: 1px dashed var(--ehe-border); }
.ehe-cal-past-list { display: flex; flex-direction: column; gap: 12px; padding: 12px; }
.ehe-cal-past .ehe-event { opacity: .7; }

/* Detailfenster */
.ehe-dialog {
	width: min(560px, calc(100vw - 32px));
	max-height: calc(100vh - 48px);
	padding: 0;
	border: 1px solid var(--ehe-border);
	border-radius: 14px;
	background: var(--ehe-surface);
	color: var(--ehe-text);
	box-shadow: 0 24px 60px rgba(0, 0, 0, .55);
}
.ehe-dialog::backdrop { background: rgba(0, 0, 0, .65); backdrop-filter: blur(2px); }
.ehe-dialog-inner { position: relative; padding: 22px 22px 20px; }
.ehe .ehe-dialog-close {
	appearance: none;
	position: absolute;
	top: 10px;
	right: 10px;
	width: 36px;
	height: 36px;
	padding: 0;
	border: 1px solid var(--ehe-border);
	border-radius: 50%;
	background: var(--ehe-surface-2);
	box-shadow: none;
	color: var(--ehe-text);
	font-size: 22px;
	line-height: 1;
	cursor: pointer;
}
.ehe .ehe-dialog-close:hover, .ehe .ehe-dialog-close:focus-visible { border-color: var(--ehe-accent); color: var(--ehe-accent); background: var(--ehe-surface-2); }

.ehe-detail { display: flex; flex-direction: column; gap: 12px; }
.ehe-detail + .ehe-detail { margin-top: 16px; padding-top: 16px; border-top: 1px solid var(--ehe-border); }
.ehe .ehe-detail-title { margin: 0; padding-right: 40px; font-size: 22px; font-weight: 700; line-height: 1.25; color: var(--ehe-text); }
.ehe-detail.is-compact .ehe-detail-title { font-size: 18px; padding-right: 0; }
.ehe .ehe-detail-dayhead { margin: 0 0 14px; padding-right: 40px; font-size: 13px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--ehe-muted); }
.ehe-detail-vs { padding: 10px 12px; border-radius: 10px; background: var(--ehe-surface-2); }
.ehe-detail-vs .ehe-vs-team { flex: 1 1 0; }
.ehe-detail-vs .ehe-vs-team.is-away { justify-content: flex-end; }
.ehe-detail-vs .ehe-vs-team.is-away .ehe-team-logo { order: 2; }
.ehe-detail-facts { display: grid; gap: 8px; margin: 0; }
.ehe-detail-facts > div { display: grid; grid-template-columns: 80px 1fr; gap: 12px; }
.ehe-detail-facts dt { margin: 0; font-size: 12px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--ehe-muted); padding-top: 2px; }
.ehe-detail-facts dd { margin: 0; font-size: 15px; color: var(--ehe-text); }
.ehe-detail-score { font-weight: 800; font-variant-numeric: tabular-nums; }
.ehe .ehe-detail-desc { margin: 0; font-size: 14px; color: var(--ehe-text); opacity: .85; }
.ehe-detail-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 4px; }

/* iCal */
.ehe-ics { display: flex; align-items: center; flex-wrap: wrap; gap: 8px 16px; }
.ehe .ehe-ics-raw { font-size: 13px; color: var(--ehe-muted); text-decoration: underline; text-underline-offset: 3px; }
.ehe .ehe-ics-raw:hover { color: var(--ehe-accent); }

/* Schmaler Container: Kalender als Liste */
@container (max-width: 700px) {
	.ehe-cal-grid { display: none; }
	.ehe-cal-list { display: flex; }
	.ehe .ehe-cal-title { font-size: 22px; }
}
@media (max-width: 760px) {
	.ehe-event { flex-wrap: wrap; }
	.ehe-image { flex-basis: 100%; order: -1; }
	.ehe-detail-facts > div { grid-template-columns: 1fr; gap: 2px; }
}

/* ==================================================================
   Match-Center [esporthub_matches]
   ================================================================== */

.ehe-mc {
	--ehe-win: #a4cc39;
	--ehe-loss: #e0566a;
	container-type: inline-size;
	display: flex;
	flex-direction: column;
	gap: 20px;
}
.ehe-game-cs2      { --ehe-game: #f5a623; }
.ehe-game-r6s      { --ehe-game: #4aa8ff; }
.ehe-game-lol      { --ehe-game: #b98cff; }
.ehe-game-valorant { --ehe-game: #ff6b7a; }
.ehe-game-rl       { --ehe-game: #36c6f4; }
.ehe-game-other    { --ehe-game: var(--ehe-accent); }
.ehe-mc .ehe-chip { --ehe-c: var(--ehe-game, var(--ehe-accent)); }

/* Bedienleiste */
.ehe-mc-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 16px; }
.ehe-mc-tabs, .ehe-mc-filters, .ehe-mc-spoiler { display: none; }
.ehe-mc.is-ready .ehe-mc-tabs,
.ehe-mc.is-ready .ehe-mc-filters { display: flex; }
.ehe-mc.is-ready .ehe-mc-spoiler { display: inline-flex; }

.ehe-mc-tabs {
	padding: 4px;
	gap: 4px;
	background: var(--ehe-surface);
	border: 1px solid var(--ehe-border);
	border-radius: 999px;
}
.ehe .ehe-mc-tab {
	appearance: none;
	border: 0;
	border-radius: 999px;
	padding: 8px 18px;
	background: transparent;
	color: var(--ehe-muted);
	font: inherit;
	font-weight: 700;
	font-size: 14px;
	line-height: 1.2;
	cursor: pointer;
	transition: background .15s ease, color .15s ease;
}
.ehe .ehe-mc-tab:hover { color: var(--ehe-text); background: transparent; }
.ehe .ehe-mc-tab[aria-selected="true"] { background: var(--ehe-accent); color: var(--ehe-on-accent); }
.ehe-mc-count {
	display: inline-block;
	min-width: 22px;
	margin-left: 4px;
	padding: 0 6px;
	border-radius: 999px;
	background: rgba(255, 255, 255, .08);
	font-size: 12px;
	text-align: center;
}
.ehe-mc-tab[aria-selected="true"] .ehe-mc-count { background: rgba(0, 0, 0, .15); }

.ehe-mc-filters { flex-wrap: wrap; gap: 8px; }

.ehe .ehe-mc-spoiler {
	margin-left: auto;
	appearance: none;
	border: 1px dashed var(--ehe-border);
	border-radius: 999px;
	padding: 6px 14px;
	background: transparent;
	color: var(--ehe-muted);
	font: inherit;
	font-size: 13px;
	cursor: pointer;
}
.ehe .ehe-mc-spoiler:hover { color: var(--ehe-text); border-color: var(--ehe-muted); background: transparent; }

/* Bereiche */
.ehe .ehe-mc-heading {
	display: flex;
	align-items: center;
	gap: 10px;
	margin: 0 0 12px;
	font-size: 20px;
	color: var(--ehe-text);
}
.ehe-mc.is-ready .ehe-mc-panel { display: none; }
.ehe-mc.is-ready .ehe-mc-panel.is-active { display: block; }
.ehe-mc.is-ready .ehe-mc-panel-title { display: none; }
.ehe-mc-panel + .ehe-mc-panel { margin-top: 28px; }
.ehe-mc.is-ready .ehe-mc-panel + .ehe-mc-panel { margin-top: 0; }

.ehe-mc-day + .ehe-mc-day { margin-top: 22px; }
.ehe .ehe-mc-date {
	margin: 0 0 10px;
	font-size: 13px;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: .06em;
	color: var(--ehe-muted);
}
.ehe-mc-day-list { display: flex; flex-direction: column; gap: 10px; }
.ehe-match.is-filtered, .ehe-match.is-over, .ehe-mc [hidden] { display: none !important; }
.ehe .ehe-mc-more { display: block; margin: 18px auto 0; }

/* Match-Karte */
.ehe-match {
	display: grid;
	grid-template-columns: 92px minmax(0, 1fr) minmax(150px, 230px) 150px;
	grid-template-areas: "when teams info actions";
	align-items: center;
	gap: 16px;
	padding: 14px 18px;
	background: var(--ehe-surface);
	border: 1px solid var(--ehe-border);
	border-left: 4px solid var(--ehe-game, var(--ehe-accent));
	border-radius: var(--ehe-radius);
	transition: border-color .15s ease, transform .15s ease;
}
.ehe-match:hover { border-color: #3a3a3a; border-left-color: var(--ehe-game, var(--ehe-accent)); }
.ehe-match.is-win  { border-left-color: var(--ehe-win); }
.ehe-match.is-loss { border-left-color: var(--ehe-loss); }
.ehe-match.is-cancelled { opacity: .55; }

.ehe-match-when { grid-area: when; display: flex; flex-direction: column; gap: 2px; }
.ehe-match-when time { font-size: 18px; font-weight: 700; color: var(--ehe-text); font-variant-numeric: tabular-nums; }
.ehe-match-outcome, .ehe-match-state { font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; color: var(--ehe-muted); }
.ehe-match.is-win  .ehe-match-outcome { color: var(--ehe-win); }
.ehe-match.is-loss .ehe-match-outcome { color: var(--ehe-loss); }

.ehe-match-teams {
	grid-area: teams;
	display: grid;
	grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
	align-items: center;
	gap: 14px;
}
.ehe-team { display: flex; align-items: center; gap: 10px; min-width: 0; }
.ehe-team.is-home { justify-content: flex-end; text-align: right; }
.ehe-team-name { font-weight: 700; font-size: 15px; color: var(--ehe-text); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ehe-team-logo {
	flex: 0 0 40px;
	width: 40px;
	height: 40px;
	border-radius: 50%;
	object-fit: contain;
	background: var(--ehe-surface-2);
}
.ehe-team-logo.is-initials {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	border: 1px solid var(--ehe-border);
	font-size: 13px;
	font-weight: 800;
	color: var(--ehe-muted);
}
.ehe-team.is-home .ehe-team-logo.is-initials { color: var(--ehe-accent); border-color: rgba(164, 204, 57, .4); }
.ehe-team-logo.is-image {
	border-radius: 8px;
	padding: 3px;
	background: var(--ehe-surface-2);
	border: 1px solid var(--ehe-border);
}

.ehe-match-center { display: flex; flex-direction: column; align-items: center; gap: 2px; min-width: 64px; }
.ehe-score { display: inline-flex; align-items: baseline; gap: 6px; font-size: 26px; font-weight: 800; line-height: 1; font-variant-numeric: tabular-nums; color: var(--ehe-text); transition: filter .2s ease; }
.ehe-score-sep { color: var(--ehe-muted); font-weight: 600; }
.ehe-match.is-win  .ehe-score-n:first-child { color: var(--ehe-win); }
.ehe-match.is-loss .ehe-score-n:last-child  { color: var(--ehe-loss); }
.ehe-vs { font-size: 14px; font-weight: 800; text-transform: uppercase; letter-spacing: .1em; color: var(--ehe-muted); }
.ehe-format { font-size: 11px; font-weight: 700; color: var(--ehe-muted); letter-spacing: .04em; }

.ehe-match-info { grid-area: info; display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.ehe-game-tag {
	align-self: flex-start;
	padding: 1px 8px;
	border-radius: 999px;
	border: 1px solid currentColor;
	color: var(--ehe-game, var(--ehe-accent));
	font-size: 11px;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: .05em;
}
.ehe-comp { font-size: 13px; color: var(--ehe-muted); line-height: 1.35; }

.ehe-match-actions { grid-area: actions; display: flex; gap: 8px; justify-content: flex-end; }
.ehe .ehe-match-actions .ehe-btn { margin-top: 0; padding: 7px 12px; font-size: 13px; white-space: nowrap; }

/* Live */
.ehe-live-dot {
	display: inline-block;
	width: 9px;
	height: 9px;
	border-radius: 50%;
	background: var(--ehe-live);
	box-shadow: 0 0 0 0 rgba(255, 59, 78, .6);
	animation: ehe-pulse 1.6s ease-out infinite;
}
@keyframes ehe-pulse {
	0%   { box-shadow: 0 0 0 0 rgba(255, 59, 78, .55); }
	100% { box-shadow: 0 0 0 10px rgba(255, 59, 78, 0); }
}
@media (prefers-reduced-motion: reduce) { .ehe-live-dot { animation: none; } }
.ehe-live-badge { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 800; letter-spacing: .08em; color: var(--ehe-live); }
.ehe-mc-live .ehe-match { border-color: rgba(255, 59, 78, .45); border-left-color: var(--ehe-live); background: linear-gradient(90deg, rgba(255, 59, 78, .08), var(--ehe-surface) 45%); }
.ehe-mc-live .ehe-match + .ehe-match { margin-top: 10px; }

/* Spoiler verbergen */
.ehe-mc.is-ready.hide-spoilers .ehe-match.is-finished .ehe-score { filter: blur(7px); user-select: none; }
.ehe-mc.is-ready.hide-spoilers .ehe-match.is-finished .ehe-match-outcome { display: none; }
.ehe-mc.is-ready.hide-spoilers .ehe-match.is-finished { border-left-color: var(--ehe-game, var(--ehe-accent)); }
.ehe-mc.is-ready.hide-spoilers .ehe-match.is-finished .ehe-score-n { color: var(--ehe-text); }

/* Schmaler Container (Elementor-Spalte, Tablet, Handy) */
@container (max-width: 760px) {
	.ehe-match {
		grid-template-columns: minmax(0, 1fr) auto;
		grid-template-areas:
			"info when"
			"teams teams"
			"actions actions";
		gap: 12px;
		padding: 14px;
	}
	.ehe-match-when { flex-direction: row; align-items: center; gap: 8px; justify-self: end; }
	.ehe-match-when time { font-size: 15px; }
	.ehe-match-info { flex-direction: row; flex-wrap: wrap; align-items: center; gap: 6px 8px; }
	.ehe-match-actions { justify-content: stretch; }
	.ehe .ehe-match-actions .ehe-btn { flex: 1; text-align: center; }
	.ehe-match-actions:empty { display: none; }
	.ehe-mc-spoiler { margin-left: 0; }
}
@container (max-width: 440px) {
	.ehe-match-teams { gap: 8px; }
	.ehe-team { flex-direction: column; gap: 6px; text-align: center; }
	.ehe-team.is-home { flex-direction: column; text-align: center; justify-content: center; }
	.ehe-team.is-away .ehe-team-logo { order: -1; }
	.ehe-team-name { font-size: 13px; white-space: normal; }
	.ehe-team-logo { flex-basis: 36px; width: 36px; height: 36px; }
	.ehe-score { font-size: 22px; }
	.ehe-mc-tabs { width: 100%; }
	.ehe .ehe-mc-tab { flex: 1; padding: 8px 10px; }
}
