/* ==========================================================================
   Mediathek Widget – modernes Streaming-Karten-Layout (Apple TV / Hulu Look)
   ========================================================================== */

.mw-wrapper {
	width: 100%;
	box-sizing: border-box;
	background: linear-gradient(160deg, #14161c 0%, #0b0c10 100%);
	border-radius: 24px;
	padding: 48px 40px 52px;
}

.mw-wrapper * {
	box-sizing: border-box;
}

.mw-header {
	text-align: left;
}

.mw-topbar {
	display: flex;
	flex-direction: column;
	gap: 20px;
	margin-bottom: 32px;
}

.mw-topbar .mw-header {
	padding-bottom: 20px;
	border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.mw-controls {
	display: flex;
	align-items: center;
	justify-content: flex-end;
}

.mw-theme-switch {
	flex: 0 0 auto;
	display: flex;
	align-items: center;
	gap: 8px;
	margin: 0;
}

.mw-theme-switch-label {
	font-size: 12px;
	font-weight: 600;
	letter-spacing: 0.4px;
	text-transform: uppercase;
	color: #8b8f97;
	margin-right: 2px;
}

.mw-theme-switch-btn {
	font: 600 13px/1 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
	padding: 7px 14px;
	border-radius: 999px;
	border: 1px solid rgba(255, 255, 255, 0.14);
	background: transparent;
	color: #9a9ea6;
	cursor: pointer;
	transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.mw-theme-switch-btn:hover {
	border-color: rgba(255, 255, 255, 0.3);
	color: #d8dae0;
}

.mw-theme-switch-btn[aria-pressed="true"] {
	border-color: transparent;
}

.mw-theme-switch-btn[data-theme="light"][aria-pressed="true"] {
	background: #f4f4f5;
	color: #16181d;
	box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.06);
}

.mw-theme-switch-btn[data-theme="dark"][aria-pressed="true"] {
	background: #1c1e24;
	color: #f4f4f5;
	box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.35);
}

.mw-theme-light .mw-theme-switch-label {
	color: #7a7e87;
}

.mw-theme-light .mw-theme-switch-btn {
	border-color: rgba(0, 0, 0, 0.14);
	color: #6b6f78;
}

.mw-theme-light .mw-theme-switch-btn:hover {
	border-color: rgba(0, 0, 0, 0.3);
	color: #2a2c31;
}

.mw-theme-light .mw-theme-switch-btn[data-theme="dark"][aria-pressed="true"] {
	box-shadow: none;
}

@media (max-width: 480px) {
	.mw-topbar {
		flex-wrap: wrap;
	}
}

.mw-header-title {
	font-size: 28px;
	font-weight: 800;
	letter-spacing: 2px;
	color: #ffffff !important;
	margin: 0 0 8px;
}

.mw-header-subtitle {
	font-size: 15px;
	color: #9a9ea6 !important;
	margin: 0;
	max-width: 640px;
	line-height: 1.5;
}

.mw-grid {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 28px;
}

.mw-card {
	display: flex;
	flex-direction: column;
	text-decoration: none;
	color: inherit;
	outline: none;
	-webkit-tap-highlight-color: transparent;
}

a.mw-card {
	cursor: pointer;
}

.mw-card-media {
	position: relative;
	display: block;
	width: 100%;
	aspect-ratio: 16 / 9;
	overflow: hidden;
	border-radius: 14px;
	background-color: #1c1f26;
	box-shadow: 0 1px 0 rgba(255, 255, 255, 0.04) inset, 0 8px 20px rgba(0, 0, 0, 0.35);
	transition: transform 0.35s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.35s ease;
}

.mw-card-media img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
	object-position: center 25%;
	transition: transform 0.6s cubic-bezier(0.22, 1, 0.36, 1);
}

.mw-card-media::after {
	content: "";
	position: absolute;
	inset: 0;
	background: linear-gradient(180deg, rgba(0, 0, 0, 0) 55%, rgba(0, 0, 0, 0.55) 100%);
	opacity: 0;
	transition: opacity 0.35s ease;
}

.mw-card-media--empty {
	display: flex;
	align-items: center;
	justify-content: center;
	position: relative;
}

.mw-card-media--empty::before {
	content: "";
	position: absolute;
	inset: 0;
	background-image:
		radial-gradient(circle at 20% 15%, rgba(255, 255, 255, 0.14), transparent 45%),
		radial-gradient(circle at 85% 90%, rgba(255, 255, 255, 0.08), transparent 55%);
}

.mw-card-media--empty::after {
	background: linear-gradient(180deg, rgba(0, 0, 0, 0) 40%, rgba(0, 0, 0, 0.45) 100%);
	opacity: 1;
}

.mw-card-monogram {
	position: relative;
	z-index: 1;
	font-size: 44px;
	font-weight: 800;
	color: rgba(255, 255, 255, 0.92);
	letter-spacing: 1px;
	text-shadow: 0 4px 18px rgba(0, 0, 0, 0.25);
	transition: transform 0.6s cubic-bezier(0.22, 1, 0.36, 1);
}

.mw-variant-1 { background: linear-gradient(135deg, #2b5876 0%, #4e4376 100%); }
.mw-variant-2 { background: linear-gradient(135deg, #614385 0%, #516395 100%); }
.mw-variant-3 { background: linear-gradient(135deg, #1e3c72 0%, #2a5298 100%); }
.mw-variant-4 { background: linear-gradient(135deg, #232526 0%, #3a3d40 100%); }
.mw-variant-5 { background: linear-gradient(135deg, #3a1c71 0%, #5a3f8c 60%, #4568dc 100%); }
.mw-variant-6 { background: linear-gradient(135deg, #0f2027 0%, #203a43 50%, #2c5364 100%); }

a.mw-card:hover .mw-card-monogram,
a.mw-card:focus-visible .mw-card-monogram {
	transform: scale(1.08);
}

.mw-card-play {
	position: absolute;
	top: 50%;
	left: 50%;
	width: 52px;
	height: 52px;
	display: flex;
	align-items: center;
	justify-content: center;
	border-radius: 50%;
	background: rgba(20, 20, 24, 0.55);
	backdrop-filter: blur(6px);
	border: 1px solid rgba(255, 255, 255, 0.25);
	transform: translate(-50%, -50%) scale(0.85);
	opacity: 0;
	transition: opacity 0.3s ease, transform 0.3s ease;
	pointer-events: none;
}

.mw-card-play svg {
	width: 18px;
	height: 18px;
	fill: #ffffff;
	margin-left: 2px;
}

a.mw-card:hover .mw-card-media,
a.mw-card:focus-visible .mw-card-media {
	transform: translateY(-4px);
	box-shadow: 0 1px 0 rgba(255, 255, 255, 0.06) inset, 0 18px 34px rgba(0, 0, 0, 0.5);
}

a.mw-card:hover .mw-card-media img,
a.mw-card:focus-visible .mw-card-media img {
	transform: scale(1.06);
}

a.mw-card:hover .mw-card-media::after,
a.mw-card:focus-visible .mw-card-media::after {
	opacity: 1;
}

a.mw-card:hover .mw-card-play,
a.mw-card:focus-visible .mw-card-play {
	opacity: 1;
	transform: translate(-50%, -50%) scale(1);
}

.mw-card-body {
	display: flex;
	flex-direction: column;
	padding: 14px 2px 0;
}

.mw-card-title-row {
	display: flex;
	align-items: center;
	gap: 8px;
}

.mw-card-icon {
	flex: 0 0 auto;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 22px;
	height: 22px;
	border-radius: 6px;
	background: rgba(255, 255, 255, 0.08);
}

.mw-card-icon i,
.mw-card-icon svg {
	color: #ffffff;
	font-size: 11px;
	width: 11px;
	height: 11px;
}

.mw-card-title {
	display: block;
	font-size: 16px;
	font-weight: 700;
	color: #f4f4f5;
	line-height: 1.3;
	letter-spacing: 0.1px;
}

.mw-card-subtitle {
	display: block;
	font-size: 13px;
	color: #8b8f97;
	margin-top: 4px;
}

@media (max-width: 1024px) {
	.mw-wrapper {
		padding: 36px 24px 40px;
	}
	.mw-grid {
		grid-template-columns: repeat(2, 1fr);
		gap: 20px;
	}
}

@media (max-width: 600px) {
	.mw-wrapper {
		padding: 28px 16px 32px;
		border-radius: 18px;
	}
	.mw-grid {
		grid-template-columns: 1fr;
		gap: 18px;
	}
	.mw-header-title {
		font-size: 22px;
	}
}

/* ==========================================================================
   Helles Design (für Einbettung auf hellen Seiten)
   ========================================================================== */

.mw-wrapper.mw-theme-light {
	background: linear-gradient(160deg, #f7f8fa 0%, #edeff2 100%);
	box-shadow: 0 1px 0 rgba(0, 0, 0, 0.03) inset, 0 1px 3px rgba(20, 20, 30, 0.04);
}

.mw-wrapper.mw-theme-light .mw-topbar .mw-header {
	border-bottom-color: rgba(0, 0, 0, 0.08);
}

.mw-wrapper.mw-theme-light .mw-header-title {
	color: #16181d !important;
}

.mw-wrapper.mw-theme-light .mw-header-subtitle {
	color: #62666f !important;
}

.mw-wrapper.mw-theme-light .mw-card-media {
	background-color: #e4e6ea;
	box-shadow: 0 1px 0 rgba(255, 255, 255, 0.7) inset, 0 6px 16px rgba(20, 20, 30, 0.10);
}

.mw-wrapper.mw-theme-light a.mw-card:hover .mw-card-media,
.mw-wrapper.mw-theme-light a.mw-card:focus-visible .mw-card-media {
	box-shadow: 0 1px 0 rgba(255, 255, 255, 0.8) inset, 0 16px 28px rgba(20, 20, 30, 0.16);
}

.mw-wrapper.mw-theme-light .mw-card-icon {
	background: rgba(0, 0, 0, 0.06);
}

.mw-wrapper.mw-theme-light .mw-card-icon i,
.mw-wrapper.mw-theme-light .mw-card-icon svg {
	color: #16181d;
}

.mw-wrapper.mw-theme-light .mw-card-title {
	color: #16181d;
}

.mw-wrapper.mw-theme-light .mw-card-subtitle {
	color: #6b6f78;
}

.mw-wrapper.mw-theme-light .mw-card-play {
	background: rgba(255, 255, 255, 0.6);
	border-color: rgba(0, 0, 0, 0.12);
}

.mw-wrapper.mw-theme-light .mw-card-play svg {
	fill: #16181d;
}
