/* Mobil-Titel im Kopfbild: am Desktop unsichtbar */
.m-title { display: none; }

/*
	Responsive Ergaenzung fuer Via Intolleranza II
	Wird NACH style.css geladen. Oberhalb von 920px aendert sich nichts
	(Desktop-Layout bleibt exakt wie bisher). Die !important-Angaben
	sind noetig, weil das Layout viele feste Inline-Styles verwendet.
*/

@media (max-width: 920px) {

	html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
	body { overflow-x: hidden; }

	img, iframe, object, embed, video { max-width: 100%; }
	img { height: auto; }

	/* ---------- Logo + Navigation (kompakt: Logo links, Sprache/Social rechts, Menue einzeilig) ---------- */
	div.nav, div.navfr, div.naven {
		position: relative !important; left: 0 !important; margin: 10px 10px 0 !important;
		width: auto !important; height: auto !important; box-sizing: border-box;
		padding: 0 0 6px; border-bottom: 3px solid #3d6e39;
	}
	div.logo {
		position: relative; left: 0; margin: 0; width: calc(100% - 112px); max-width: 280px; height: auto;
		box-sizing: border-box; padding: 6px 7px 3px; border-width: 4px; text-align: center;
	}
	div.logo img { width: 100%; height: auto; vertical-align: top; }
	div.nav ul.mainNav, div.navfr ul.mainNav, div.naven ul.mainNav {
		position: static !important; top: 0 !important; height: auto !important; width: 100% !important;
		display: flex; flex-wrap: nowrap; justify-content: space-between; align-items: center;
		text-align: center; line-height: 1.1; margin: 8px 0 0 !important; padding: 0;
	}
	div.nav ul.mainNav li, div.navfr ul.mainNav li, div.naven ul.mainNav li {
		float: none !important; display: block; height: auto !important; padding: 4px 0 !important;
	}
	div.nav ul.mainNav li a, div.navfr ul.mainNav li a, div.naven ul.mainNav li a {
		font-size: clamp(13px, 4.3vw, 21px); white-space: nowrap;
	}
	div.nav ul.mainNav li#metanav, div.navfr ul.mainNav li#metanav, div.naven ul.mainNav li#metanav {
		position: absolute; top: 0; right: 0; width: 100px; padding: 0 !important; text-align: right;
	}
	#metanav #sb { font-size: 18px; padding: 0 0 0 7px; }
	#metanav span { display: block; padding: 6px 0 0 !important; }
	#metanav span img { width: 20px; height: 20px; margin-left: 4px; }

	/* ---------- Container-Breiten ---------- */
	.content1, .content2, .content3, .content5,
	div.footer, div.footerlinks, #wrapper, #galeriebox {
		position: relative !important; left: 0 !important; top: 0 !important;
		margin-left: auto !important; margin-right: auto !important;
		width: auto !important; max-width: 880px;
		height: auto !important; min-height: 0 !important;
		box-sizing: border-box; padding-left: 14px !important; padding-right: 14px !important;
	}
	.content1, .content3 { margin-top: 24px !important; }
	div.footer, div.footerlinks { margin-top: 36px !important; float: none !important; }
	div.footer img { width: 100%; max-width: 880px; }
	#wrapper { padding-top: 0 !important; border-bottom: 0; }
	#wrapper_sp { display: none; }

	/* Spalten untereinander */
	.content1 div, .content2 div, .content3 div, .content5 div {
		float: none !important; width: auto !important; max-width: 100%;
	}
	#links1, #rechts1, #links2, #rechts2, #links3 {
		float: none !important; width: auto !important;
		padding-left: 0 !important; padding-right: 0 !important;
		height: auto !important; min-height: 0 !important; border-right: 0 !important;
	}
	#links2, #rechts2 { padding-bottom: 20px !important; border-bottom: 2px solid #3d6e39; margin-bottom: 24px; }
	#rechts2:last-child, .content2 #rechts2 { border-bottom: 0; }
	.content1 > div[style*="margin-left"], .content3 > div[style*="margin-left"] {
		margin-left: 0 !important; text-align: center;
	}

	/* ---------- Typografie ---------- */
	h1 { font-size: 4.4em; line-height: 0.85em; }
	h2 { font-size: 2.6em; line-height: 0.95em; }
	div.content5 h2 { font-size: 24px; }
	p, span, fieldset.terms label { font-size: 16px; }
	p, a, li, h1, h2, h3, b { overflow-wrap: anywhere; word-wrap: break-word; }
	div.content1 h1 { padding-bottom: 12px; }

	/* ---------- Hero-Bilder (Kopfbild jeder Seite) ---------- */
	.content1[style*="background"] {
		background-size: cover !important; background-position: center !important;
		background-repeat: no-repeat !important;
		aspect-ratio: 880 / 390;
		padding-left: 0 !important; padding-right: 0 !important;
		margin-top: 16px !important; max-width: none;
	}
	.content1[style*="background"] > #rechts1 { display: none; }
	/* Plakatives Kopfbild: hoch, Verlauf, dicke gruene Kante, grosser Titel unten */
	.content1[style*="background"]:not(.hero-text) {
		aspect-ratio: auto; min-height: 62vw !important; position: relative !important; overflow: hidden;
		border-bottom: 8px solid #3d6e39; margin-bottom: 8px;
	}
	.content1[style*="background"]:not(.hero-text)::after {
		content: ""; position: absolute; left: 0; right: 0; bottom: 0; top: 25%;
		background: linear-gradient(to top, rgba(0,20,8,0.88) 0%, rgba(0,20,8,0.45) 55%, rgba(0,20,8,0) 100%);
	}
	.content1[style*="background"]:not(.hero-text) > #links1 {
		position: absolute; left: 16px; right: 16px; bottom: 14px; top: auto; z-index: 2; text-align: left;
	}
	.m-title {
		display: block; font-family: 'Ketchupa', Arial, Helvetica; text-transform: uppercase; color: #fff;
		font-size: 4em; line-height: 0.88em; letter-spacing: -1px; text-shadow: 0 2px 8px rgba(0,0,0,0.5);
	}
	.content1[style*="background"] > #links1 .platzhalter { display: block; height: auto; }
	.content1[style*="background"] > #links1 h1 { font-size: 4.2em; padding: 0; margin: 0 !important; text-shadow: 0 2px 8px rgba(0,0,0,0.5); }
	/* Abstand zwischen Kopfbild und erstem Inhalt */
	.content1[style*="background"] + .content2, .content1[style*="background"] + .content3,
	.content1[style*="background"] + .content5, .content1[style*="background"] + div { margin-top: 26px !important; }

	/* Startseite: Kopfbild mit Text */
	.content1.hero-text {
		aspect-ratio: auto; position: relative !important; overflow: hidden;
		padding: 28px 18px 26px !important; border-bottom: 8px solid #3d6e39;
	}
	.content1.hero-text::before {
		content: ""; position: absolute; left: 0; top: 0; right: 0; bottom: 0;
		background: linear-gradient(to bottom, rgba(0,20,8,0.55), rgba(0,20,8,0.8)); z-index: 0;
	}
	.content1.hero-text > #links1 { display: none; }
	.content1.hero-text > #rechts1 { display: block; position: relative; z-index: 1; }
	.content1.hero-text h1 { font-size: 3.8em; margin-top: 0 !important; }
	.content1.hero-text p { font-size: 16px; margin-bottom: 0; }

	/* Bilder in Spalten */
	.content1 img[width], .content2 img[width] { max-width: 100%; height: auto; }

	/* ---------- Medienfeed (iframe auf der Startseite) ---------- */
	iframe[name="mediafeed"] { display: block; height: 380px !important; width: 100% !important; max-width: 424px; margin: 10px auto 0; }

	/* ---------- Video-Seite ---------- */
	.content5 iframe[src*="youtube"] { width: 100% !important; height: auto !important; aspect-ratio: 16 / 9; display: block; }
	.content5 div[style*="width:210px"] {
		display: inline-block; vertical-align: top;
		width: calc(50% - 6px) !important; box-sizing: border-box;
		padding: 18px 4px 0 !important; min-height: 0 !important; border-bottom: 0 !important;
	}
	.content5 div[style*="width:210px"] img { width: 100% !important; height: auto; }
	.content5 div[style*="width:210px"] h2 { font-size: 20px; }
	.content5 div[style*="width:130px"], .content5 div[style*="width:150px"],
	.content5 div[style*="width:630px"], .content5 div[style*="width:610px"],
	.content1 div[style*="width:130px"], .content1 div[style*="width:150px"],
	.content1 div[style*="width:630px"], .content1 div[style*="width:610px"] {
		height: auto !important; padding: 6px 0 !important; text-align: center;
	}
	.content5 h2, .content1 h2 { margin-top: 0 !important; }

	/* Teilen-Links */
	div[style*="width:420px"] {
		float: none !important; width: auto !important; padding-left: 0 !important;
		text-align: center !important; clear: both;
	}

	/* ---------- Foto-Galerie / Slider ---------- */
	#galeriebox { padding-left: 0 !important; padding-right: 0 !important; margin-top: 16px !important; }
	#slideshow #slidesContainer {
		width: 100% !important; height: auto !important; overflow: hidden !important;
	}
	#slideshow #slidesContainer .slide { height: auto !important; max-width: none; }
	#slideshow #slidesContainer .slide img { width: 100% !important; height: auto; }
	.control { height: 100% !important; width: 36px !important; }
	#leftControl { background-position: 0 center !important; }
	#rightControl { background-position: 0 center !important; }
}

@media (max-width: 520px) {
	h1 { font-size: 3.8em; }
	.content1[style*="background"] > #links1 h1, .m-title { font-size: 2.8em; }
	.content1.hero-text h1 { font-size: 2.8em; }
	h2 { font-size: 2.3em; }
}
