/* Kategorie-Dropdown auf der Startseite */

.cat-dropdown {
	display: flex;
	justify-content: center;
	margin: 3rem auto -3rem;
	padding: 0 2rem;
	position: relative;
	z-index: 10;
	font-family: 'Open Sans', sans-serif;
}

.cat-dropdown-field {
	position: relative;
	display: inline-flex;
	align-items: center;
	max-width: 100%;
}

.cat-dropdown-label {
	position: absolute;
	left: -10000px;
	width: 1px;
	height: 1px;
	overflow: hidden;
}

.cat-dropdown select {
	appearance: none;
	-webkit-appearance: none;
	-moz-appearance: none;
	min-width: 280px;
	max-width: 90vw;
	padding: 12px 46px 12px 20px;
	background: #141414;
	color: #fff;
	border: 2px solid #141414;
	border-radius: 2px;
	font-family: 'Kalam', 'Open Sans', sans-serif;
	font-size: 18px;
	font-weight: 600;
	letter-spacing: 0.3px;
	text-transform: none;
	cursor: pointer;
	box-shadow: 0 4px 14px rgba(0, 0, 0, 0.25);
	transition: border-color 180ms ease, box-shadow 180ms ease, background 180ms ease;
}

.cat-dropdown select:hover {
	border-color: #d81e5b;
	background: #000;
	box-shadow: 0 6px 20px rgba(216, 30, 91, 0.3);
}

.cat-dropdown select:focus {
	outline: none;
	border-color: #d81e5b;
	box-shadow: 0 0 0 3px rgba(216, 30, 91, 0.35);
}

.cat-dropdown-field::after {
	content: "";
	position: absolute;
	top: 50%;
	right: 18px;
	width: 10px;
	height: 10px;
	border-right: 2px solid #fff;
	border-bottom: 2px solid #fff;
	transform: translateY(-70%) rotate(45deg);
	pointer-events: none;
	transition: border-color 180ms ease;
}

.cat-dropdown-field:hover::after {
	border-color: #d81e5b;
}

.cat-dropdown option {
	color: #fff;
	background: #141414;
	font-weight: 400;
	font-size: 14px;
	text-transform: none;
	padding: 8px;
}

.cat-dropdown option.is-child {
	color: #ddd;
}

.cat-dropdown option.is-divider {
	color: #777;
	background: #141414;
	font-style: italic;
}

#topside .cat-dropdown + h1 {
	padding-top: 10rem;
	padding-bottom: 0rem;
}

@media (max-width: 600px) {

	#topside .cat-dropdown + h1 {
		padding-top: 5rem;
		padding-bottom: 0rem;
	}

	.cat-dropdown {
		margin: 1rem auto 1.5rem;
		padding: 0 1rem;
	}

	.cat-dropdown select {
		min-width: 0;
		width: 100%;
		font-size: 16px;
		padding: 11px 40px 11px 16px;
	}
}

/* Section heading inside the grid (spans all columns) */

body.home #content .section-heading,
body.category #content .section-heading {
	grid-column: 1 / -1;
	margin: 2rem 0 0.5rem;
	padding: 0 0 0.75rem;
	border-bottom: 2px solid #d81e5b;
	font-family: 'Kalam', 'Open Sans', sans-serif;
	font-size: 2.6rem;
	color: #141414;
	text-align: left;
}

body.home #content .section-heading,
body.category #content .section-heading a {
	color: inherit;
	text-decoration: none;
	transition: color 180ms ease;
	display: inline-block;
}

body.home #content .section-heading,
body.category #content .section-heading a:hover,
body.home #content .section-heading,
body.category #content .section-heading a:focus {
	color: #d81e5b;
	border-bottom: none;
}

body.home #content .section-heading,
body.category #content .section-heading a::after {
	content: " →";
	opacity: 0.5;
	transition: opacity 180ms ease, transform 180ms ease;
	display: inline-block;
}

body.home #content .section-heading,
body.category #content .section-heading a:hover::after,
body.home #content .section-heading,
body.category #content .section-heading a:focus::after {
	opacity: 1;
	transform: translateX(4px);
}

/* "Ältere Beiträge" link below page-1 custom content */

body.home #content .home-older-nav {
	grid-column: 1 / -1;
	text-align: center;
	margin: 4rem 0 3rem;
	padding: 2rem 0 0;
	position: relative;
	z-index: 5;
	clear: both;
}

.home-older-nav {
	text-align: center;
	margin: 3rem auto 2rem;
}

.home-older-link {
	display: inline-block;
	padding: 12px 28px;
	background: #141414;
	color: #fff;
	font-family: 'Open Sans', sans-serif;
	font-size: 14px;
	font-weight: 700;
	letter-spacing: 0.5px;
	text-transform: uppercase;
	border: 2px solid #141414;
	transition: background 180ms ease, border-color 180ms ease, color 180ms ease;
}

.home-older-link:hover,
.home-older-link:focus {
	background: #d81e5b;
	border-color: #d81e5b;
	color: #fff;
	outline: none;
}

/* Post shade cycle — hue-rotate variants per article so same-category
   posts shift slightly in colour without altering brightness, keeping
   white text contrast fully intact. */

#content article.shade-0 .category { filter: none; }
#content article.shade-1 .category { filter: grayscale(0.4); }
#content article.shade-2 .category { filter: grayscale(0); }
#content article.shade-3 .category { filter: grayscale(0.3); }

/* Mobile category grid fix — mirror homepage behaviour */

@media only screen and (max-width: 1200px) {
	body.category #content {
		grid-template-columns: 46% 46%;
	}
}

@media only screen and (max-width: 940px) {
	body.category #content {
		grid-template-columns: 100%;
	}
}

@media only screen and (max-width: 768px) {
	.category #content {
		margin-left: 1rem;
		margin-right: 1rem;
	}

	body.category #content {
		grid-template-columns: 100%;
	}
}
