/* Volley Schepdaal – Wedstrijden & uitslagen
   Huisstijl volleyschepdaal.be: Roboto, clubrood #FF0000, wit, zwart. */

.vsw {
	--vsw-red: #ff0000;
	--vsw-red-dark: #d40000;
	--vsw-red-soft: #fff1f1;
	--vsw-ink: #111;
	--vsw-text: #222;
	--vsw-muted: #7a7a7a;
	--vsw-line: #ececec;
	--vsw-zebra: #f6f6f6;
	--vsw-win: #1f8f45;
	--vsw-win-soft: #e6f4eb;
	--vsw-radius: 8px;

	font-family: "Roboto", -apple-system, "Segoe UI", Helvetica, Arial, sans-serif;
	color: var(--vsw-text);
	font-size: 15px;
	line-height: 1.4;
	margin: 0 auto;
}

.vsw *,
.vsw *::before,
.vsw *::after { box-sizing: border-box; }

/* ---------- Sectiekoppen (zoals de paginatitels op de site) ---------- */
.vsw-section + .vsw-section { margin-top: 48px; }

.vsw-head {
	text-align: center;
	margin-bottom: 18px;
}
.vsw .vsw-title {
	font-family: "Roboto", sans-serif;
	font-weight: 600;
	font-size: 25px;
	line-height: 1.2;
	color: var(--vsw-red);
	margin: 0;
	padding: 0;
}
.vsw-range {
	margin: 6px 0 0;
	font-size: 14px;
	color: var(--vsw-muted);
}
.vsw-range::before,
.vsw-range::after {
	content: "";
	display: inline-block;
	width: 28px;
	height: 2px;
	background: var(--vsw-ink);
	vertical-align: middle;
	margin: 0 10px;
}

/* ---------- Tabel ---------- */
.vsw-table-wrap {
	overflow-x: auto;
	-webkit-overflow-scrolling: touch;
	border-radius: var(--vsw-radius);
	border: 1px solid var(--vsw-red);
}

.vsw .vsw-table {
	width: 100%;
	border-collapse: collapse;
	border-spacing: 0;
	margin: 0;
	border: 0;
	background: #fff;
	font-size: 14px;
}

/* Scorebord: zwarte koppen, rode ploegkolom */
.vsw .vsw-table thead th {
	background: var(--vsw-red);
	color: #fff;
	font-family: "Roboto", sans-serif;
	font-weight: 700;
	font-size: 12px;
	letter-spacing: .08em;
	text-transform: uppercase;
	text-align: left;
	padding: 13px 14px;
	border: 0;
	white-space: nowrap;
}

.vsw .vsw-table thead th.vsw-th-score { text-align: center; }
.vsw .vsw-table thead th.vsw-th-vs { padding: 0; width: 1px; }

.vsw .vsw-table tbody td {
	padding: 12px 10px;
	border: 0;
	border-top: 1px solid var(--vsw-line);
	vertical-align: middle;
	background: transparent;
}

/* Linkerkolom: de ploeg */
.vsw .vsw-table td.vsw-team {
	min-width: 170px;
}
.vsw-team__name {
	display: block;
	font-weight: 700;
	color: var(--vsw-ink);
	font-size: 14.5px;
}
.vsw-team__sub {
	display: block;
	font-size: 12px;
	color: var(--vsw-muted);
	margin-top: 2px;
	white-space: nowrap;
}

.vsw-date { white-space: nowrap; }
.vsw-date__day {
	text-transform: capitalize;
	color: var(--vsw-muted);
}
.vsw-date__date { font-weight: 400; color: var(--vsw-text); }

.vsw-time {
	font-weight: 400;
	color: var(--vsw-text);
	white-space: nowrap;
	font-variant-numeric: tabular-nums;
}

.vsw-club { min-width: 120px; }
.vsw-ours { color: var(--vsw-ink); font-weight: 700; white-space: nowrap; }
.vsw-vs { color: var(--vsw-muted); text-align: center; padding-left: 0 !important; padding-right: 0 !important; }


/* Labels */
.vsw-tag {
	display: inline-block;
	font-size: 11px;
	font-weight: 700;
	letter-spacing: .06em;
	text-transform: uppercase;
	padding: 3px 7px;
	border-radius: 3px;
	line-height: 1.2;
	vertical-align: 1px;
	margin-right: 4px;
	white-space: nowrap;
}
.vsw-tag--home { background: transparent; color: var(--vsw-red); padding-left: 0; }
.vsw-tag--away { background: transparent; color: var(--vsw-muted); padding-left: 0; }
.vsw-tag--muted { background: #f0f0f0; color: #555; margin-left: 4px; }

/* Uitslag */
.vsw-score { text-align: center; white-space: nowrap; }
.vsw-score__badge {
	display: inline-block;
	min-width: 52px;
	padding: 2px 8px;
	border-radius: 3px;
	font-weight: 700;
	font-size: 14px;
	line-height: 1.5;
	font-variant-numeric: tabular-nums;
	background: #e9e9e9;
	color: var(--vsw-ink);
}
/* Gewonnen = groen, verloren = transparant */
.vsw-score__badge--win { background: var(--vsw-win-soft); color: var(--vsw-win); }
.vsw-score__badge--loss { background: transparent; color: var(--vsw-ink); box-shadow: inset 0 0 0 1.5px #d0d0d0; }

/* Setstanden */
.vsw-setlist {
	display: inline-flex;
	flex-wrap: nowrap;
	gap: 4px;
}
.vsw-sets,
.vsw-res { white-space: nowrap; }
.vsw-set {
	display: inline-block;
	padding: 3px 6px;
	border-radius: 4px;
	font-size: 12.5px;
	font-variant-numeric: tabular-nums;
	/* Alle sets neutraal en transparant; enkel de uitslag kleurt groen bij winst. */
	background: transparent;
	color: #555;
	box-shadow: inset 0 0 0 1px #e2e2e2;
	white-space: nowrap;
}

.vsw-res__score {
	font-weight: 700;
	color: var(--vsw-ink);
	font-variant-numeric: tabular-nums;
}

.vsw-muted { color: var(--vsw-muted); }

.vsw-empty {
	text-align: center;
	color: var(--vsw-muted);
	padding: 24px;
	background: var(--vsw-zebra);
	border-radius: var(--vsw-radius);
	margin: 0;
}

.vsw-updated {
	text-align: center;
	font-size: 12px;
	color: var(--vsw-muted);
	margin: 22px 0 0;
}
.vsw-updated a { color: var(--vsw-muted); text-decoration: underline; }

/* Brede schermen: clubnamen op één regel → lagere rijen */
@media (min-width: 1100px) {
	.vsw .vsw-table td.vsw-club { white-space: nowrap; }
	.vsw .vsw-table td.vsw-team { min-width: 0; }
}

@media (min-width: 961px) and (max-width: 1099px) {
	.vsw .vsw-table tbody td,
	.vsw .vsw-table thead th { padding-left: 8px; padding-right: 8px; }
}

/* ---------- Mobiel: rustige witte kaart per wedstrijd ---------- */
@media (max-width: 960px) {
	.vsw { font-size: 14px; }
	.vsw-section + .vsw-section { margin-top: 32px; }
	.vsw-head { margin-bottom: 12px; }
	.vsw .vsw-title { font-size: 20px; }
	.vsw-range { font-size: 12.5px; margin-top: 4px; }
	.vsw-range::before,
	.vsw-range::after { width: 18px; margin: 0 8px; }

	.vsw-table-wrap { overflow: visible; box-shadow: none; border-radius: 0; border: 0; }

	.vsw .vsw-table,
	.vsw .vsw-table tbody { display: block; width: 100%; background: transparent; }

	.vsw .vsw-table thead {
		position: absolute;
		width: 1px; height: 1px;
		overflow: hidden;
		clip: rect(0 0 0 0);
	}

	.vsw .vsw-table tbody tr {
		display: grid;
		grid-template-columns: 1fr auto;
		column-gap: 10px;
		background: #fff;
		border: 1px solid #e6e6e6;
		border-radius: 6px;
		margin-bottom: 8px;
		padding: 9px 0 9px;
	}
	.vsw .vsw-table--upcoming tbody tr {
		grid-template-areas:
			"team team"
			"home time"
			"away date";
	}
	.vsw .vsw-table--results tbody tr {
		grid-template-areas:
			"team team"
			"home score"
			"away score";
	}

	.vsw .vsw-table tbody td {
		display: block;
		width: auto;
		min-width: 0;
		border: 0;
		padding: 0 11px;
		background: transparent;
		text-align: left;
		white-space: normal;
		line-height: 1.35;
	}

	/* Titel van de kaart = reeks (de ploeg staat al in de wedstrijd zelf) */
	.vsw .vsw-table td.vsw-team { grid-area: team; padding-bottom: 7px; margin-bottom: 7px; padding-right: 90px; border-bottom: 1px solid var(--vsw-line) !important; }
	.vsw-team .vsw-team__name {
		margin: 0;
		font-size: 11px;
		font-weight: 700;
		letter-spacing: .05em;
		text-transform: uppercase;
		color: var(--vsw-ink);
		white-space: nowrap;
		overflow: hidden;
		text-overflow: ellipsis;
	}

	.vsw .vsw-table td.vsw-club--home { grid-area: home; }
	.vsw .vsw-table td.vsw-club--away { grid-area: away; }
	.vsw .vsw-table td.vsw-club { font-size: 14.5px; }
	.vsw .vsw-table td.vsw-time  { grid-area: time; text-align: right; font-size: 14.5px; }
	.vsw .vsw-table td.vsw-date  { grid-area: date; text-align: right; font-size: 12.5px; }
	.vsw .vsw-table td.vsw-score { grid-area: score; align-self: center; }
	.vsw .vsw-table td.vsw-sets  { grid-area: sets; padding-top: 7px; }
	.vsw .vsw-table td.vsw-vs { display: none; }

	/* Uitslagen: datum rechts op de titelregel */
	.vsw .vsw-table--results td.vsw-date {
		grid-area: team;
		justify-self: end;
		font-size: 12px;
		padding-bottom: 7px;
		color: var(--vsw-muted);
	}

	.vsw-score__badge { min-width: 52px; font-size: 15px; padding: 4px 8px; }
	.vsw-set { font-size: 11.5px; padding: 1px 5px; }
	.vsw-setlist { flex-wrap: wrap; gap: 3px; }
	.vsw-tag { font-size: 10px; padding: 2px 5px; }
	.vsw-updated { margin-top: 14px; font-size: 11px; }
}

/* ---------- Ploegpagina: kalender van één ploeg ---------- */
.vsw-actions { margin: 14px 0 0; }
.vsw .vsw-btn,
.vsw .vsw-btn:visited {
	/* Zelfde knop als op volleyschepdaal.be (Elementor-knop) */
	display: inline-block;
	background-color: #ff0000;
	color: #fff;
	font-family: "Roboto", sans-serif;
	font-weight: 500;
	font-size: 15px;
	line-height: 1.65;
	letter-spacing: normal;
	text-transform: none;
	text-decoration: none;
	padding: 12px 24px;
	border: 0;
	border-radius: 3px;
	box-shadow: none;
	transition: all .3s;
}
.vsw .vsw-btn:hover,
.vsw .vsw-btn:focus {
	background-color: #47a72b;
	color: #fff;
}
.vsw .vsw-btn:focus-visible { outline: 2px solid var(--vsw-ink); outline-offset: 2px; }

/* Volgende match */
.vsw-next {
	display: flex;
	align-items: stretch;
	max-width: 640px;
	margin: 0 auto 22px;
	border: 1px solid var(--vsw-red);
	border-radius: var(--vsw-radius);
	overflow: hidden;
	background: #fff;
}
.vsw-next__date {
	flex: 0 0 76px;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	background: var(--vsw-red);
	color: #fff;
	padding: 10px 6px;
	text-transform: uppercase;
	line-height: 1.1;
}
.vsw-next__day,
.vsw-next__month { font-size: 11px; font-weight: 700; letter-spacing: .08em; }
.vsw-next__num { font-size: 28px; font-weight: 700; margin: 2px 0; }
.vsw-next__body { padding: 12px 16px; min-width: 0; }
.vsw .vsw-next p { margin: 0; }
.vsw .vsw-next__label {
	font-size: 11px;
	font-weight: 700;
	letter-spacing: .08em;
	text-transform: uppercase;
	color: var(--vsw-red);
}
.vsw-next__time { color: var(--vsw-ink); margin-left: 6px; }
.vsw .vsw-next__match { font-size: 16px; color: var(--vsw-text); margin: 4px 0; }
.vsw-next__vs { color: var(--vsw-muted); margin: 0 4px; }
.vsw .vsw-next__venue { font-size: 13px; color: var(--vsw-muted); }

@media (max-width: 960px) {
	.vsw-actions { margin-top: 10px; }
	.vsw .vsw-btn { font-size: 14px; }
	.vsw-next { margin-bottom: 14px; }
	.vsw-next__date { flex-basis: 62px; }
	.vsw-next__num { font-size: 24px; }
	.vsw-next__body { padding: 10px 12px; }
	.vsw .vsw-next__match { font-size: 14.5px; margin: 3px 0 4px; }
	.vsw-next__team { display: block; }
	.vsw-next__vs { display: none; }
	.vsw .vsw-next__venue { font-size: 12px; }

	.vsw .vsw-table--team tbody tr {
		column-gap: 0;
		grid-template-areas:
			"date time"
			"home score"
			"away score";
	}
	.vsw .vsw-table--team td.vsw-date {
		grid-area: date;
		text-align: left;
		font-size: 12px;
		padding-bottom: 7px;
		margin-bottom: 7px;
		border-bottom: 1px solid var(--vsw-line) !important;
	}
	.vsw .vsw-table--team td.vsw-time {
		grid-area: time;
		font-size: 12px;
		padding-bottom: 7px;
		margin-bottom: 7px;
		border-bottom: 1px solid var(--vsw-line) !important;
	}
}

/* Ploegpagina: nog niet gespeeld → geen lege set-rij op mobiel */
@media (max-width: 960px) {
	.vsw .vsw-table--team td.vsw-sets--empty { display: none; }
	.vsw .vsw-table--team td.vsw-score .vsw-muted { display: none; }
}

/* ---------- Uitlijning links: [volley_schepdaal_wedstrijden uitlijning="links"] ---------- */
.vsw--left .vsw-head,
.vsw--left .vsw-empty,
.vsw--left .vsw-updated { text-align: left; }
.vsw--left .vsw-range::before { display: none; }
.vsw--left .vsw-range::after { margin-right: 0; }
.vsw--left .vsw-range { display: flex; align-items: center; flex-direction: row-reverse; justify-content: flex-end; gap: 0; }
.vsw--left .vsw-range::after { margin: 0 10px 0 0; }
.vsw--left .vsw-next { margin-left: 0; margin-right: 0; }
.vsw .vsw-next .vsw-tag { padding-left: 0; padding-right: 0; margin-right: 0; }

/* Ploegpagina: rij van de volgende match in lichtrood */
.vsw .vsw-table--team tbody tr.is-next td { background: var(--vsw-red-soft); }
@media (max-width: 960px) {
	.vsw .vsw-table--team tbody tr.is-next { background: var(--vsw-red-soft); border-color: #ffc9c9; }
	.vsw .vsw-table--team tbody tr.is-next td { background: transparent; }
}

/* Ploegpagina: afgelopen wedstrijden iets doorschijnend */
.vsw .vsw-table--team tbody tr.is-played td { opacity: .55; }
@media (max-width: 960px) {
	.vsw .vsw-table--team tbody tr.is-played { opacity: .55; }
	.vsw .vsw-table--team tbody tr.is-played td { opacity: 1; }
}

/* ---------- Kolomverdeling desktop ----------
   Vaste breedtes; thuisploeg rechts tegen het midden, bezoekers links.
   Op de homepage lopen Thuisploeg / midden / Bezoekers in beide tabellen gelijk. */
@media (min-width: 961px) {
	.vsw .vsw-table { table-layout: fixed; }

	.vsw .vsw-table th,
	.vsw .vsw-table td { overflow: hidden; text-overflow: ellipsis; }

	/* Komende wedstrijden: Ploeg | Datum | Uur | Thuisploeg | – | Bezoekers */
	.vsw .vsw-table--upcoming th:nth-child(1) { width: 24%; }
	.vsw .vsw-table--upcoming th:nth-child(2) { width: 10%; }
	.vsw .vsw-table--upcoming th:nth-child(3) { width: 8%; }
	.vsw .vsw-table--upcoming th:nth-child(4) { width: 25%; }
	.vsw .vsw-table--upcoming th:nth-child(5) { width: 8%; }
	.vsw .vsw-table--upcoming th:nth-child(6) { width: 25%; }

	/* Uitslagen: Ploeg | Datum | Thuisploeg | Uitslag | Bezoekers */
	.vsw .vsw-table--results th:nth-child(1) { width: 24%; }
	.vsw .vsw-table--results th:nth-child(2) { width: 18%; }
	.vsw .vsw-table--results th:nth-child(3) { width: 25%; }
	.vsw .vsw-table--results th:nth-child(4) { width: 8%; }
	.vsw .vsw-table--results th:nth-child(5) { width: 25%; }

	/* Ploegpagina: Datum | Uur | Thuisploeg | Uitslag | Bezoekers */
	.vsw .vsw-table--team th:nth-child(1) { width: 17%; }
	.vsw .vsw-table--team th:nth-child(2) { width: 9%; }
	.vsw .vsw-table--team th:nth-child(3) { width: 31%; }
	.vsw .vsw-table--team th:nth-child(4) { width: 12%; }
	.vsw .vsw-table--team th:nth-child(5) { width: 31%; }

	/* Uitlijning: thuis rechts, midden gecentreerd, bezoekers links */
	.vsw .vsw-table .vsw-club--home,
	.vsw .vsw-table thead th.vsw-th-home { text-align: right; }
	.vsw .vsw-table .vsw-score,
	.vsw .vsw-table .vsw-vs,
	.vsw .vsw-table thead th.vsw-th-score,
	.vsw .vsw-table thead th.vsw-th-vs { text-align: center; }
	.vsw .vsw-table thead th.vsw-th-vs { padding: 13px 0; width: 8%; }
	.vsw .vsw-table td.vsw-vs { padding-left: 0; padding-right: 0; }
	.vsw .vsw-table td.vsw-team { min-width: 0; }
	.vsw .vsw-table td.vsw-club { white-space: nowrap; min-width: 0; }
	.vsw-team__name { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
}

/* ---------- Ploegpagina: rangschikking ---------- */
.vsw-standings { margin-top: 40px; }
.vsw .vsw-subtitle {
	font-family: "Roboto", sans-serif;
	font-weight: 600;
	font-size: 21px;
	line-height: 1.2;
	color: var(--vsw-red);
	text-align: center;
	margin: 0 0 14px;
	padding: 0;
}
.vsw--left .vsw-subtitle { text-align: left; }

.vsw .vsw-rank {
	width: 100%;
	border-collapse: collapse;
	border: 0;
	margin: 0;
	background: #fff;
	font-size: 14px;
}
.vsw .vsw-rank thead th {
	background: var(--vsw-red);
	color: #fff;
	font-family: "Roboto", sans-serif;
	font-weight: 700;
	font-size: 12px;
	letter-spacing: .08em;
	text-transform: uppercase;
	text-align: left;
	padding: 12px 12px;
	border: 0;
	white-space: nowrap;
}
.vsw .vsw-rank tbody td {
	padding: 10px 12px;
	border: 0;
	border-top: 1px solid var(--vsw-line);
	background: transparent;
	color: var(--vsw-text);
	vertical-align: middle;
}
.vsw .vsw-rank .vsw-rank__pos { width: 48px; text-align: center; font-variant-numeric: tabular-nums; }
.vsw .vsw-rank .vsw-rank__num { width: 80px; text-align: center; font-variant-numeric: tabular-nums; }
.vsw .vsw-rank td.vsw-rank__pts { font-weight: 700; color: var(--vsw-ink); }
/* Eigen ploeg in lichtgrijs */
.vsw .vsw-rank tbody tr.is-ours td { background: #f0f0f0; font-weight: 700; color: var(--vsw-ink); }

@media (max-width: 960px) {
	.vsw-standings { margin-top: 28px; }
	.vsw .vsw-subtitle { font-size: 18px; margin-bottom: 10px; }
	.vsw-standings .vsw-table-wrap { border: 1px solid #e6e6e6; border-radius: 6px; overflow: hidden; }
	.vsw .vsw-rank { font-size: 13.5px; }
	.vsw .vsw-rank thead th { font-size: 10.5px; padding: 9px 8px; }
	.vsw .vsw-rank tbody td { padding: 8px 8px; }
	.vsw .vsw-rank .vsw-rank__pos { width: 34px; }
	.vsw .vsw-rank .vsw-rank__num { width: 56px; }
	.vsw .vsw-rank .vsw-rank__opt { display: none; }
}

/* Homepage – deze week: gespeelde match toont meteen de uitslag (mobiel) */
@media (max-width: 960px) {
	.vsw .vsw-table--upcoming tbody tr.is-played {
		grid-template-areas:
			"team team"
			"home score"
			"away score";
	}
	.vsw .vsw-table--upcoming tbody tr.is-played td.vsw-time { display: none; }
	.vsw .vsw-table--upcoming tbody tr.is-played td.vsw-date {
		grid-area: team;
		justify-self: end;
		font-size: 12px;
		padding-bottom: 7px;
		color: var(--vsw-muted);
	}
	.vsw .vsw-table--upcoming tbody tr.is-played td.vsw-vs.vsw-score {
		display: block;
		grid-area: score;
		align-self: center;
	}
}
