/* Madbox NZS Tekme */
.mbnzs {
	--mbnzs-accent: #0b5d3b;
	--mbnzs-bg: #ffffff;
	--mbnzs-text: #1a1a1a;
	--mbnzs-muted: #6b6b6b;
	--mbnzs-border: rgba(0, 0, 0, .1);
	--mbnzs-radius: 10px;
	--mbnzs-logo: 40px;
	--mbnzs-box: #f0f5fa;
	display: grid;
	gap: 12px;
	color: var(--mbnzs-text);
}

.mbnzs--empty {
	padding: 16px;
	color: var(--mbnzs-muted);
}

.mbnzs__item {
	display: grid;
	grid-template-columns: 96px 1fr;
	grid-template-areas: "when teams" "when meta";
	align-items: center;
	gap: 4px 16px;
	padding: 14px 18px;
	background: var(--mbnzs-bg);
	border: 1px solid var(--mbnzs-border);
	border-radius: var(--mbnzs-radius);
	color: inherit;
	text-decoration: none;
	transition: border-color .2s, box-shadow .2s;
}

a.mbnzs__item:hover {
	border-color: var(--mbnzs-accent);
	box-shadow: 0 4px 16px rgba(0, 0, 0, .06);
	color: inherit;
}

.mbnzs__when {
	grid-area: when;
	display: flex;
	flex-direction: column;
	align-items: center;
	text-align: center;
	line-height: 1.2;
	padding-right: 16px;
	border-right: 2px solid var(--mbnzs-accent);
}

.mbnzs__day {
	text-transform: uppercase;
	font-size: .75em;
	letter-spacing: .08em;
	color: var(--mbnzs-muted);
}

.mbnzs__date {
	font-size: 1.05em;
	font-weight: 700;
}

.mbnzs__time {
	font-weight: 600;
	color: var(--mbnzs-accent);
}

.mbnzs__time.is-tbd {
	font-size: .7em;
	font-weight: 400;
	color: var(--mbnzs-muted);
}

.mbnzs__teams {
	grid-area: teams;
	display: grid;
	grid-template-columns: 1fr auto 1fr;
	align-items: center;
	gap: 12px;
}

.mbnzs__team {
	display: flex;
	align-items: center;
	gap: 10px;
	min-width: 0;
}

.mbnzs__team--home {
	flex-direction: row-reverse;
	text-align: right;
}

.mbnzs__logo {
	width: var(--mbnzs-logo);
	height: var(--mbnzs-logo);
	object-fit: contain;
	flex: none;
}

.mbnzs__name {
	font-weight: 600;
	overflow-wrap: normal;
	word-break: normal;
	hyphens: manual;
}

.mbnzs__vs {
	color: var(--mbnzs-muted);
}

.mbnzs__score {
	font-size: 1.3em;
	font-weight: 700;
	white-space: nowrap;
	text-align: center;
}

.mbnzs__score small {
	display: block;
	font-size: .55em;
	font-weight: 400;
	color: var(--mbnzs-muted);
}

.mbnzs__meta {
	grid-area: meta;
	font-size: .8em;
	color: var(--mbnzs-muted);
	text-align: center;
}

.mbnzs__sep {
	margin: 0 6px;
}

.mbnzs__label {
	color: var(--mbnzs-accent);
	font-weight: 600;
}

/* Kartice – za naslovnico (naslednja tekma) */
.mbnzs--cards {
	grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
	gap: 16px;
}

.mbnzs--cards .mbnzs__item {
	grid-template-columns: 1fr;
	grid-template-areas: "when" "teams" "meta";
	gap: 14px;
	padding: 24px 20px;
	text-align: center;
}

.mbnzs--cards .mbnzs__when {
	flex-direction: row;
	justify-content: center;
	gap: 8px;
	padding: 0 0 12px;
	border-right: 0;
	border-bottom: 2px solid var(--mbnzs-accent);
}

.mbnzs--cards .mbnzs__team,
.mbnzs--cards .mbnzs__team--home {
	flex-direction: column;
	justify-content: flex-start;
	text-align: center;
}

.mbnzs--cards {
	--mbnzs-logo: 64px;
}

@media (max-width: 600px) {
	.mbnzs__item {
		grid-template-columns: 1fr;
		grid-template-areas: "when" "teams" "meta";
		padding: 14px;
	}

	.mbnzs__when {
		flex-direction: row;
		justify-content: center;
		gap: 8px;
		padding: 0 0 8px;
		border-right: 0;
		border-bottom: 2px solid var(--mbnzs-accent);
	}

	.mbnzs__team {
		flex-direction: column;
		text-align: center;
	}

	.mbnzs__team--home {
		flex-direction: column;
	}
}

/* Lestvica */
.mbnzs-table {
	display: block;
	overflow-x: auto;
}

.mbnzs-table table {
	width: 100%;
	border-collapse: collapse;
	background: var(--mbnzs-bg);
	border: 1px solid var(--mbnzs-border);
	border-radius: var(--mbnzs-radius);
	overflow: hidden;
	font-variant-numeric: tabular-nums;
	margin: 0;
}

.mbnzs-table th,
.mbnzs-table td {
	padding: 9px 8px;
	text-align: center;
	border: 0;
	border-bottom: 1px solid var(--mbnzs-border);
	white-space: nowrap;
}

.mbnzs-table th {
	font-size: .75em;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: .04em;
	color: var(--mbnzs-muted);
	background: transparent;
}

.mbnzs-table tbody tr:last-child td {
	border-bottom: 0;
}

.mbnzs-table .c-pos {
	width: 2.5em;
	color: var(--mbnzs-muted);
}

.mbnzs-table .c-club {
	text-align: left;
	width: 100%;
	white-space: normal;
}

.mbnzs-table__club {
	display: flex;
	align-items: center;
	gap: 8px;
}

.mbnzs-table__club img {
	width: 24px;
	height: 24px;
	object-fit: contain;
	flex: none;
}

.mbnzs-table .c-pts {
	font-weight: 700;
}

.mbnzs-table tr.is-club td {
	background: color-mix(in srgb, var(--mbnzs-accent) 12%, transparent);
	font-weight: 600;
}

.mbnzs-table tr.is-club .c-pos {
	color: var(--mbnzs-accent);
	box-shadow: inset 3px 0 0 var(--mbnzs-accent);
}

.mbnzs-table__more {
	display: inline-block;
	margin-top: 8px;
	font-size: .85em;
	color: var(--mbnzs-accent);
}

/* Lestvica na telefonu: vsi stolpci, vodoravni drsnik, mesto in klub ostaneta pripeta. */
@media (max-width: 600px) {
	.mbnzs.mbnzs-table:not(.is-short) {
		-webkit-overflow-scrolling: touch;
	}

	.mbnzs.mbnzs-table:not(.is-short) table {
		min-width: 560px;
		overflow: visible; /* sicer pripeti stolpci ne delujejo */
	}

	.mbnzs.mbnzs-table:not(.is-short) .c-pos,
	.mbnzs.mbnzs-table:not(.is-short) .c-club {
		position: sticky;
		z-index: 1;
		background: var(--mbnzs-bg);
	}

	.mbnzs.mbnzs-table:not(.is-short) .c-pos {
		left: 0;
		min-width: 2.5em;
	}

	.mbnzs.mbnzs-table:not(.is-short) .c-club {
		left: 2.5em;
		width: 150px;
		min-width: 150px;
		max-width: 150px;
		white-space: normal;
		box-shadow: 4px 0 6px -4px rgba(0, 0, 0, .15);
	}

	.mbnzs.mbnzs-table:not(.is-short) .mbnzs-table__club span {
		white-space: normal;
		line-height: 1.2;
	}

	.mbnzs.mbnzs-table:not(.is-short) tr.is-club .c-pos,
	.mbnzs.mbnzs-table:not(.is-short) tr.is-club .c-club {
		background: color-mix(in srgb, var(--mbnzs-accent) 12%, var(--mbnzs-bg));
	}
}

/* Kompaktno */
.mbnzs--compact {
	gap: 0;
	--mbnzs-logo: 20px;
}

.mbnzs__row {
	display: flex;
	align-items: center;
	gap: 12px;
	padding: 8px 0;
	border-bottom: 1px solid var(--mbnzs-border);
	color: inherit;
	text-decoration: none;
	font-size: .9em;
}

.mbnzs__row:last-child {
	border-bottom: 0;
}

a.mbnzs__row:hover {
	color: var(--mbnzs-accent);
}

.mbnzs__row-when {
	display: flex;
	flex-direction: column;
	min-width: 72px;
	line-height: 1.25;
}

.mbnzs__row-when .mbnzs__date {
	font-size: .9em;
}

.mbnzs__row-when .mbnzs__day {
	font-size: .7em;
}

.mbnzs__row-when .mbnzs__time {
	font-size: .9em;
}

.mbnzs__row-teams {
	flex: 1;
	min-width: 0;
	display: grid;
	grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
	align-items: center;
	gap: 8px;
}

.mbnzs__row-teams .mbnzs__team {
	gap: 6px;
}

.mbnzs__row-teams .mbnzs__score {
	font-size: 1em;
}

/* Izpostavljeno */
.mbnzs--featured {
	--mbnzs-logo: 110px;
}

.mbnzs__hero {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 18px;
	padding: 32px 24px;
	background: var(--mbnzs-bg);
	border: 1px solid var(--mbnzs-border);
	border-radius: var(--mbnzs-radius);
	color: inherit;
	text-decoration: none;
	text-align: center;
}

.mbnzs__hero-board {
	display: grid;
	grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
	align-items: center;
	gap: 24px;
	width: 100%;
}

.mbnzs__hero .mbnzs__team,
.mbnzs__hero .mbnzs__team--home {
	flex-direction: column;
	text-align: center;
	gap: 12px;
}

.mbnzs__hero .mbnzs__name {
	font-size: 1.25em;
}

.mbnzs__hero-center {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 4px;
}

.mbnzs__hero-center .mbnzs__day {
	font-size: .8em;
}

.mbnzs__hero-year {
	font-size: 1.1em;
	font-weight: 600;
	line-height: 1.1;
	color: var(--mbnzs-muted);
}

.mbnzs__hero-date {
	font-size: 2.2em;
	font-weight: 700;
	line-height: 1.1;
	white-space: nowrap;
}

.mbnzs__hero-center .mbnzs__time {
	font-size: 1.3em;
	font-weight: 600;
	line-height: 1.2;
}

.mbnzs__hero-center .mbnzs__time.is-tbd {
	font-size: .85em;
}

.mbnzs__hero-center .mbnzs__score {
	font-size: 2.4em;
	line-height: 1;
}

.mbnzs__hero-when {
	display: flex;
	align-items: baseline;
	gap: 6px;
	color: var(--mbnzs-muted);
}

.mbnzs__hero-when .mbnzs__date {
	font-size: .95em;
	font-weight: 600;
}

.mbnzs__hero-venue {
	color: var(--mbnzs-muted);
	font-size: .9em;
}

.mbnzs__countdown {
	display: flex;
	gap: 10px;
}

.mbnzs__countdown span {
	display: flex;
	flex-direction: column;
	align-items: center;
	min-width: 58px;
	padding: 8px 6px;
	background: var(--mbnzs-box);
	border: 0;
	border-radius: calc(var(--mbnzs-radius) * .6);
}

.mbnzs__countdown b {
	font-size: 1.5em;
	font-variant-numeric: tabular-nums;
	color: var(--mbnzs-accent);
}

.mbnzs__countdown small {
	font-size: .7em;
	text-transform: uppercase;
	letter-spacing: .06em;
	color: var(--mbnzs-muted);
}

/* Tabela tekem */
.mbnzs--table .mbnzs-table td a {
	color: inherit;
	text-decoration: none;
}

.mbnzs--table .mbnzs-table td a:hover {
	color: var(--mbnzs-accent);
}

.mbnzs--table tr.is-home .c-club {
	font-weight: 600;
}

@media (max-width: 600px) {
	.mbnzs--featured {
		--mbnzs-logo: 64px;
	}

	.mbnzs__hero {
		padding: 22px 14px;
	}

	.mbnzs__hero-board {
		gap: 10px;
	}

	.mbnzs__hero .mbnzs__name {
		font-size: 1em;
	}

	.mbnzs__hero-date,
	.mbnzs__hero-center .mbnzs__score {
		font-size: 1.6em;
	}

	.mbnzs__hero-center .mbnzs__time {
		font-size: 1.05em;
	}

	.mbnzs__countdown span {
		min-width: 48px;
	}

	.mbnzs-table .c-hide-sm {
		display: none;
	}

	.mbnzs__row .mbnzs__team,
	.mbnzs__row .mbnzs__team--home {
		flex-direction: row;
	}

	.mbnzs__row .mbnzs__team--home {
		flex-direction: row-reverse;
	}
}

.mbnzs-table .c-date .mbnzs__day {
	display: inline-block;
	min-width: 2.4em;
	font-size: .75em;
	text-transform: uppercase;
	letter-spacing: .06em;
	color: var(--mbnzs-muted);
}

.mbnzs-table .c-date .mbnzs__date {
	font-size: .95em;
	font-weight: 600;
}

/* Logotipi: vedno celi, brez obrezovanja (zaščita pred slogi teme/Elementorja). */
.mbnzs img.mbnzs__logo,
.mbnzs .mbnzs-table__club img {
	object-fit: contain !important;
	border-radius: 0 !important;
	clip-path: none !important;
	max-width: none !important;
	box-shadow: none !important;
	background: none !important;
	padding: 0 !important;
}

.mbnzs img.mbnzs__logo {
	width: var(--mbnzs-logo) !important;
	height: var(--mbnzs-logo) !important;
}

.mbnzs .mbnzs-table__club img {
	width: 24px !important;
	height: 24px !important;
	flex: none;
}
