/* spezifische Definitionen für Backend */
html[data-backend] {
	.rte_wrapper table {
		margin-top: 1.500rem;
	}
	.external table {
		margin-top: 0px;
	}
}
.rte_wrapper table {
	border: none; /* Legacy - es gibt Tabellen die Rahmen haben */
	border-collapse: separate !important;
	border-spacing: 1px;
	background-color: var(--white-100);
	color: var(--text-color);
	font-variation-settings: var(--fsu-font-variation-text-condensed);

	/* geschachtelte Tabellen ausblenden */
	& table {
		display: none;
	}
	& :where(td, th) {
		padding: 15px;
		box-sizing: border-box;
		vertical-align: top;
		border: 1px solid rgba(51, 57, 57, 0.3); /* #333939 - 30% */

		&.no_break  { /* kein Zeilenumbruch */
			white-space: nowrap;
		}
		/* Spalten-Breiten */
		&.w_10 {
			width: 10%;
		}
		&.w_20 {
			width: 20%;
		}
		&.w_30 {
			width: 30%;
		}
		&.w_40 {
			width: 40%;
		}
		&.w_50 {
			width: 50%;
		}
		& :is(a, p, ol, ul) { /* Eigenschaften von Zelle erben - :is() für Spezifität */
			color: inherit;
			font-size: inherit;
			line-height: inherit;
		}
		& :where(p, ol, ul):first-child { /* keinen zusätzlichen Abstand oben */
			margin-top: 0px;
		}
		& :where(ol, ul)  {
			text-align: left; /* Listen immer linksbündig */
		}
		& strong { /* Fett */
			font-weight: 600;
			font-variation-settings: var(--fsu-font-variation-text-condensed-bold);
		}
		& em { /* Kursiv */
			font-style: italic;
			font-synthesis: none; /* Vermischung von slnt und Italic verhindern */
			font-variation-settings: var(--fsu-font-variation-text-condensed-italic);
		}
	}
	/* Kopf-Zelle */
	& th {
		--icon-font-fill: 1; /* Sonderfall */
		border-color: var(--fsu-blue);
		background-color: var(--fsu-blue);
		text-align: left;
		color: var(--white-100);
		font-weight: normal;
		font-size: 1.125rem;
		line-height: 1.500rem;

		& > ul > li::before {
			color: var(--white-100);
		}
		& > a:focus-visible {
			outline-color: var(--white-100);
		}
		@media (hover: hover) {
			& > a:hover {
				text-decoration-thickness: 2px;
			}
		}
	}
	/* Kopf-Zelle - Matrix-Tabelle */
	&.matrix {
		/* Kopf-Zelle - erst Spalte */
		& th:first-child:not(.reset) { /* .reset - siehe skin/_global/_js/backend.functions.js - tinymceCleanUpTable() */
			--icon-font-fill: 0; /* Sonderfall */
			padding-left: 20px;
			border-color: var(--copyright-color);
			background: linear-gradient(
				90deg,
				var(--skin-color, var(--fsu-gold)) 10px,
				var(--bg-gradient, var(--white-100)) 11px /* --bg-gradient wird in fsuTable() definiert */
			);
			background-origin: border-box;
			color: var(--fsu-blue);

			& > ul > li::before {
				color: var(--skin-color, var(--fsu-gold));
			}
		}
		/* Kopf-Zelle - erste Zeile und erste Spalte */
		& tr:first-of-type:not(thead + tbody tr, tbody + tfoot tr) th:first-child {
			background: var(--white-100);
			border-color: var(--white-100);
			color: var(--fsu-blue);

			& > a:focus-visible {
				outline-color: var(--hover-color-dark);
			}
		}
	}
}
/* Tabellen-Definition */
.rte_wrapper :is(table + p.table_definition, .fsu-table-wrapper + p.table_definition, .fsu-table-wrapper + button + p.table_definition) {
	margin-top: 1.000rem;
	color: var(--copyright-color);
	font-variation-settings: var(--fsu-font-variation-text-condensed);
	font-size: 0.750rem;
	line-height: 1.000rem;
}