/*
 * Krankheitsbilder-Widget — Akkordeon-Liste der Indikationen. Aufklapp-Muster und
 * Kartenoptik entsprechen dem Bürgerinitiative-Archiv-Widget (weiße Karte, 10px-
 * Radius, Chevron rotiert beim Öffnen); neu sind die Evidenz-Badges und die
 * Cannabinoid-Hexagone, die dieselbe clip-path-Form und dieselben Markenfarben
 * verwenden wie das Cannabinoide-Widget selbst.
 */

.ac-kr-root {
	font-family: 'Amiko', sans-serif;
}

.ac-kr-intro {
	font-size: 0.98rem;
	line-height: 1.7;
	color: #555;
	margin: 0 0 25px;
}

/* Sortierleiste */

.ac-kr-sort {
	display: flex;
	align-items: center;
	flex-wrap: wrap;
	gap: 10px;
	margin-bottom: 18px;
}

.ac-kr-sort-label {
	font-family: 'Montserrat', sans-serif;
	font-size: 0.82rem;
	font-weight: 700;
	color: #666;
	text-transform: uppercase;
	letter-spacing: 0.5px;
}

.ac-kr-sort-btn {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 6px 14px;
	background-color: #fff;
	border: 1px solid #ddd;
	border-radius: 50px;
	font-family: 'Montserrat', sans-serif;
	font-size: 0.82rem;
	font-weight: 600;
	color: #444;
	cursor: pointer;
	outline: none;
	transition: all 0.2s ease;
}

.ac-kr-sort-btn:hover {
	background-color: #f7f9fc;
	border-color: var( --ac-accent, #2e6741 );
	color: var( --ac-accent, #2e6741 );
}

.ac-kr-sort-btn.ac-active {
	background-color: var( --ac-accent, #2e6741 );
	border-color: var( --ac-accent, #2e6741 );
	color: #fff;
}

.ac-kr-sort-btn i {
	font-size: 14px;
	transition: transform 0.2s ease;
}

.ac-kr-list {
	display: flex;
	flex-direction: column;
	gap: 12px;
}

.ac-kr-item {
	background-color: #fff;
	border: 1px solid #eee;
	border-radius: 10px;
	overflow: hidden;
	transition: box-shadow 0.3s;
	/* Jeder Eintrag ist per Anker direkt verlinkbar (siehe anchor_id() bzw.
	   ac-krankheiten.js). Der Abstand verhindert, dass der angesprungene Eintrag
	   unter dem überlagernden Theme-Header verschwindet. */
	scroll-margin-top: 110px;
}

.ac-kr-item.ac-active {
	box-shadow: 0 4px 14px rgba( 0, 0, 0, 0.08 );
}

.ac-kr-toggle {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 15px;
	width: 100%;
	padding: 18px 22px;
	background: none !important;
	border: none !important;
	text-align: left;
	cursor: pointer;
	appearance: none;
	outline: none;
	transition: background-color 0.3s;
}

.ac-kr-toggle:hover,
.ac-kr-toggle:focus {
	background-color: #f7f9fc !important;
}

.ac-kr-toggle-main {
	display: flex;
	align-items: center;
	flex-wrap: wrap;
	gap: 12px;
	min-width: 0;
}

.ac-kr-toggle-aside {
	display: flex;
	align-items: center;
	gap: 12px;
	flex-shrink: 0;
}

.ac-kr-name {
	font-family: 'Montserrat', sans-serif;
	font-size: 1.02rem;
	font-weight: 700;
	line-height: 1.35;
	color: #111;
}

/* Evidenz-Badge — die Farbe kommt pro Eintrag als Custom Property aus dem PHP
   (evidence_levels()), damit die Abstufung ohne eigene Klasse je Stufe auskommt.
   Bewusst nur Textfarbe + Rahmen in der Stufenfarbe (kein color-mix() für eine
   getönte Fläche): color-mix() ist erst ab neueren Browserversionen verfügbar und
   würde in älteren Browsern ersatzlos ausfallen. */
.ac-kr-evidence {
	display: inline-flex;
	align-items: center;
	flex-shrink: 0;
	font-family: 'Montserrat', sans-serif;
	font-size: 0.68rem;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.5px;
	line-height: 1;
	padding: 5px 11px;
	border-radius: 50px;
	color: var( --ac-kr-evidence-color, #2e6741 );
	background-color: #fff;
	border: 1.5px solid var( --ac-kr-evidence-color, #2e6741 );
}

.ac-kr-chevron {
	flex-shrink: 0;
	display: inline-flex;
	align-items: center;
	color: var( --ac-accent, #2e6741 );
	font-size: 18px;
	line-height: 1;
	transition: transform 0.3s;
}

.ac-kr-item.ac-active .ac-kr-chevron {
	transform: rotate( 180deg );
}

.ac-kr-body {
	display: none;
	padding: 0 22px 22px;
	border-top: 1px solid #eee;
}

.ac-kr-item.ac-active .ac-kr-body {
	display: block;
}

.ac-kr-summary {
	font-size: 0.94rem;
	line-height: 1.75;
	color: #444;
	margin: 18px 0 0;
}

.ac-kr-block {
	margin-top: 22px;
}

.ac-kr-block-heading {
	font-family: 'Montserrat', sans-serif;
	font-size: 0.75rem;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 1px;
	color: #888;
	margin: 0 0 12px;
}

/* Cannabinoid-Hexagone — gleiche clip-path-Form wie im Cannabinoide-Widget. Das
   äußere Element trägt den Link, die innere .ac-kr-hex-shape die Form, damit der
   Hover-Effekt nicht am beschnittenen Element selbst hängt. */

.ac-kr-hexes {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
}

.ac-kr-hex {
	display: inline-block;
	text-decoration: none;
	transition: transform 0.3s;
}

.ac-kr-hex:hover,
.ac-kr-hex:focus {
	transform: scale( 1.06 );
}

.ac-kr-hex--static {
	cursor: default;
}

.ac-kr-hex--static:hover,
.ac-kr-hex--static:focus {
	transform: none;
}

.ac-kr-hex-shape {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 74px;
	height: 85px;
	clip-path: polygon( 50% 0%, 100% 25%, 100% 75%, 50% 100%, 0% 75%, 0% 25% );
	background-color: var( --ac-kr-hex-color, #2e6741 );
	filter: drop-shadow( 0 2px 4px rgba( 0, 0, 0, 0.18 ) );
}

.ac-kr-hex-label {
	font-family: 'Montserrat', sans-serif;
	font-size: 0.70rem;
	font-weight: 700;
	color: #fff;
	line-height: 1.15;
	text-align: center;
	padding: 0 6px;
	max-width: 92%;
	word-break: normal;
	overflow-wrap: break-word;
	hyphens: auto;
	-webkit-hyphens: auto;
}

/* Studien */

.ac-kr-studies {
	list-style: none;
	margin: 0;
	padding: 0;
	display: flex;
	flex-direction: column;
	gap: 10px;
}

.ac-kr-study {
	display: flex;
	align-items: flex-start;
	gap: 10px;
	font-size: 0.88rem;
	line-height: 1.6;
	color: #444;
}

.ac-kr-study i {
	flex-shrink: 0;
	color: var( --ac-accent, #2e6741 );
	font-size: 16px;
	line-height: 1.6;
}

.ac-kr-study-text a {
	color: #333;
	text-decoration: none;
	transition: color 0.2s ease;
}

.ac-kr-study-text a:hover,
.ac-kr-study-text a:focus {
	color: var( --ac-accent, #2e6741 );
	text-decoration: underline;
}

.ac-kr-study-source {
	display: block;
	font-size: 0.8rem;
	color: #888;
	margin-top: 2px;
}

/* Hinweis */

.ac-kr-disclaimer {
	display: flex;
	align-items: center;
	gap: 10px;
	margin: 25px 0 0;
	padding: 14px 18px;
	background-color: #f7f9fc;
	border-radius: 10px;
	font-size: 0.85rem;
	line-height: 1.6;
	color: #666;
}

.ac-kr-disclaimer i {
	flex-shrink: 0;
	font-size: 18px;
	line-height: 1;
	color: #999;
}

.ac-kr-name {
	font-family: 'Montserrat', sans-serif;
	font-size: 1.02rem;
	font-weight: 700;
	line-height: 1.35;
	color: #111;
	word-break: break-word;
	overflow-wrap: break-word;
	hyphens: auto;
	-webkit-hyphens: auto;
}

@media ( max-width: 600px ) {
	.ac-kr-toggle {
		padding: 14px 16px;
		flex-wrap: wrap;
		align-items: flex-start;
		position: relative;
	}

	.ac-kr-toggle-main {
		flex: 1 1 100%;
		padding-right: 28px;
		min-width: 0;
	}

	.ac-kr-name {
		font-size: 0.96rem;
		line-height: 1.4;
		word-break: break-word;
		overflow-wrap: break-word;
		hyphens: auto;
		-webkit-hyphens: auto;
		white-space: normal;
		display: block;
		width: 100%;
	}

	.ac-kr-toggle-aside {
		flex: 1 1 100%;
		margin-top: 8px;
		justify-content: flex-start;
	}

	.ac-kr-chevron {
		position: absolute;
		top: 16px;
		right: 16px;
	}

	.ac-kr-body {
		padding: 0 16px 18px;
	}

	.ac-kr-hex-shape {
		width: 66px;
		height: 76px;
	}

	.ac-kr-hex-label {
		font-size: 0.66rem;
	}
}
