/*!
 * Theme — BLVNK theme styles.
 *
 * 01. Base styles and typography
 * 02. Forms and buttons
 * 03. Navigation and mega menu
 * 04. News
 * 05. Blockquotes
 * 06. Accordions
 * 07. Decorative elements
 * 08. Utility classes
 * 09. Expandable content on mobile devices
 * 10. Reduced motion
 */

/*------------------------------------------------------------
	01. Base styles and typography
------------------------------------------------------------*/
*,
*::before,
*::after {
	box-sizing: border-box;
}

html,
body {
	overflow-x: clip;
}

ul,
ol {
	margin: 0;
	padding: 0;
}

a:has(> img) {
	text-decoration: none;
}

b,
strong,
th {
	font-weight: var(--wp--custom--font-weight--semi-bold);
}

sup,
sub {
	position: relative;
	vertical-align: baseline;
	line-height: 0;
	font-size: 50%;
}

sup {
	top: -0.75em;
}

sub {
	top: 0.75em;
}

/*------------------------------------------------------------
	02. Forms and buttons
------------------------------------------------------------*/

/* 02.1. Form fields and labels
--------------------------------------------- */
::placeholder {
	color: var(--wp--preset--color--dark);
	font-size: var(--wp--preset--font-size--small);
	opacity: 0.5;
}

textarea,
select,
input:where(
	:not([type]),
	[type="email"],
	[type="number"],
	[type="password"],
	[type="search"],
	[type="tel"],
	[type="text"],
	[type="url"]
) {
	width: 100%;
	caret-color: var(--wp--preset--color--accent-1);
}

label {
	color: var(--wp--preset--color--contrast);
	font-size: var(--wp--preset--font-size--small);
}

input[type="checkbox"] + label,
input[type="radio"] + label,
label:has(input[type="checkbox"], input[type="radio"]) {
	color: inherit;
	font-size: inherit;
}

textarea:focus-visible,
select:focus-visible,
input:where(
	:not([type]),
	[type="email"],
	[type="number"],
	[type="password"],
	[type="search"],
	[type="tel"],
	[type="text"],
	[type="url"]
):focus-visible {
	background-color: var(--wp--preset--color--light);
	outline: 2px solid var(--wp--preset--color--accent-1);
	outline-offset: 2px;
}

input[type="checkbox"],
input[type="image"],
input[type="radio"] {
	width: auto;
}

input:not([type]),
input[type="button"],
input[type="email"],
input[type="number"],
input[type="password"],
input[type="search"],
input[type="tel"],
input[type="submit"],
input[type="text"],
input[type="url"],
textarea {
	-webkit-appearance: none;
	appearance: none;
}

/* 02.2. Buttons and keyboard focus
--------------------------------------------- */
a:focus-visible,
button:focus-visible,
input[type="submit"]:focus-visible,
input[type="button"]:focus-visible,
.wp-element-button:focus-visible {
	outline: 2px solid var(--wp--preset--color--accent-1);
	outline-offset: 2px;
}

button,
input[type="button"],
input[type="submit"] {
	padding: 0.4rem 1.5rem;
	font-size: var(--wp--preset--font-size--base);
}

/*------------------------------------------------------------
	03. Navigation and mega menu
------------------------------------------------------------*/

/* 03.1. Navigation — mobile devices and tablets
--------------------------------------------- */
@media (max-width: 1023px) {
	.menu {
		justify-content: space-between !important;
	}
	.is-style-navigation {
		padding-right: 0;
	}
}

/* 03.2. Navigation — desktop
--------------------------------------------- */
@media (min-width: 1024px) {
	.menu .navigation {
		gap: 1px;
	}

	.menu .logo {
		padding: 0.5rem 0;
		transition: transform 0.3s ease-in-out;
		transform: scale(1);
	}

	.menu .logo:hover {
		transform: scale(1.2);
	}

	.wp-block-navigation.is-style-navigation .wp-block-navigation__container {
		gap: 0;
	}

	.wp-block-navigation.is-style-navigation .wp-block-navigation-item__content {
		display: flex !important;
		align-items: center;
		height: 85px;
		padding: 0 1.25rem;
		text-decoration: none;
		transition: background-color 0.3s ease-in-out;
	}

	.wp-block-navigation.is-style-navigation .wp-block-navigation-item__content:hover {
		color: var(--wp--preset--color--base);
		background-color: var(--wp--preset--color--accent-1);
	}
}

/* 03.4. Current menu item
--------------------------------------------- */
.current-menu-item {
	color: #fff !important;
	background-color: var(--wp--preset--color--accent-1) !important;
}

/*------------------------------------------------------------
	04. News
------------------------------------------------------------*/

/* 04.1. Categories and list scrolling
--------------------------------------------- */
.news-cat-wrap {
	position: relative;
}

.news-cat {
	display: flex;
	flex-wrap: nowrap;
	overflow-x: auto;
	overscroll-behavior-x: contain;
	scrollbar-width: none;
	-ms-overflow-style: none;
	list-style: none;
	border-bottom: 1px solid var(--wp--preset--color--line);
}

.news-cat::-webkit-scrollbar {
	display: none;
}

/* Equal columns; horizontal scrolling when items no longer fit in a row. */
.news-cat > li {
	position: relative;
	flex: 1 1 0;
	min-width: max-content;
	list-style: none;
	text-align: center;
}

.news-cat > li > a {
	display: block;
	padding-block: 0.75rem 1.25rem;
	padding-inline: 0.5rem;
	color: var(--wp--preset--color--dark);
	font-size: var(--wp--preset--font-size--small);
	font-weight: var(--wp--custom--font-weight--bold);
	letter-spacing: 0.08em;
	text-transform: uppercase;
	text-decoration: none;
	transition: color 0.2s ease-in-out;
}

.news-cat > li > a::after {
	content: "";
	position: absolute;
	inset-inline: 0;
	bottom: -1px;
	height: 4px;
	background-color: var(--wp--preset--color--accent-1);
	opacity: 0;
	transition: opacity 0.2s ease-in-out;
}

.news-cat > li:hover > a,
.news-cat > li.current-cat > a {
	color: var(--wp--preset--color--accent-1);
}

.news-cat > li:hover > a::after,
.news-cat > li.current-cat > a::after {
	opacity: 1;
}

/* JavaScript reveals the arrows when the list overflows. */
.news-cat-prev,
.news-cat-next {
	position: absolute;
	top: 0;
	bottom: 3px;
	display: none;
	align-items: center;
	width: 4.5rem;
	padding: 0;
	border: 0;
	color: var(--wp--preset--color--contrast);
	cursor: pointer;
	transition: color 0.2s ease-in-out, opacity 0.2s ease-in-out;
}

.news-cat-prev {
	left: 0;
	justify-content: flex-start;
	padding-inline: 0.5rem 2rem;
	background: linear-gradient(to left, rgba(255, 255, 255, 0), var(--wp--preset--color--base) 40%);
}

.news-cat-next {
	right: 0;
	justify-content: flex-end;
	padding-inline: 2rem 0.5rem;
	background: linear-gradient(to right, rgba(255, 255, 255, 0), var(--wp--preset--color--base) 40%);
}

.news-cat-prev:hover,
.news-cat-next:hover {
	color: var(--wp--preset--color--accent-1);
}

.news-cat-wrap.is-scrollable .news-cat-prev,
.news-cat-wrap.is-scrollable .news-cat-next {
	display: flex;
}

.news-cat-wrap.is-scroll-start .news-cat-prev,
.news-cat-wrap.is-scroll-end .news-cat-next {
	visibility: hidden;
	opacity: 0;
	pointer-events: none;
}

@media (max-width: 781px) {
	.news-cat > li > a {
		padding-inline: 1.5rem;
	}
}

.news-last-post .wp-block-post-terms__prefix {
	color: var(--wp--preset--color--base);
}

.wp-block-post-terms__prefix {
	color: var(--wp--preset--color--accent-1);
}

/* 04.2. Post grid
--------------------------------------------- */
.news-grid .wp-block-post-template.is-layout-grid {
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 0 !important;
}

.news-grid .wp-block-post-template.is-layout-grid > li {
	padding-top: 1.5rem;
	padding-bottom: 2rem;
	padding-left: 1.5rem;
	padding-right: 1.5rem;
	/* border-bottom: 1px solid #cfcfcf; */
}

/* Three columns — desktop. */
@media (min-width: 1024px) {
	.news-grid .wp-block-post-template.is-layout-grid > li {
		border-right: 1px solid #cfcfcf;
	}

	.news-grid .wp-block-post-template.is-layout-grid > li:nth-child(3n) {
		border-right: 0;
	}
}

/* Two columns — tablets. */
@media (782px <= width < 1024px) {
	.news-grid .wp-block-post-template.is-layout-grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}

	.news-grid .wp-block-post-template.is-layout-grid > li {
		border-right: 1px solid #cfcfcf;
	}

	.news-grid .wp-block-post-template.is-layout-grid > li:nth-child(2n) {
		border-right: 0;
	}
}

/* One column — mobile devices. */
@media (width < 782px) {
	.news-grid .wp-block-post-template.is-layout-grid {
		grid-template-columns: minmax(0, 1fr);
	}

	.news-grid .wp-block-post-template.is-layout-grid > li {
		border-right: 0;
		padding-left: 0;
		padding-right: 0;
	}
}

/* 04.3. Featured post and “Read more” links
--------------------------------------------- */
/* .news-last-post {
	position: relative;
}

.news-last-post .read-more {
	width: 70%;
	margin-block-start: 0;
	margin-inline-start: auto;
}

.news-last-post .wp-block-read-more {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 1.5rem;
	width: 70%;
	margin-left: auto;
	min-height: 70px;
	padding-inline: var(--wp--preset--spacing--medium);
	background-color: var(--wp--preset--color--contrast);
}

.news-last-post .wp-block-read-more::after {
	content: url("../images/list-arrow-white.svg");
	flex-shrink: 0;
	transition: transform 0.15s ease-in-out;
}

.news-last-post .wp-block-read-more:hover::after {
	transform: translateX(0.15rem);
} */

/* Anchor the overlay to its image group, not a distant page ancestor. */
/* .news-grid .wp-block-group:has(> .wp-block-read-more) {
	position: relative;
}

.news-grid .wp-block-read-more {
	position: absolute;
	bottom: 0;
	left: 0;
	display: flex;
	justify-content: flex-start;
	align-items: center;
	width: fit-content;
	min-width: 130px;
	max-width: 100%;
	min-height: 70px;
	margin-block-start: 0;
	padding-inline: var(--wp--preset--spacing--medium);
	color: var(--wp--preset--color--contrast) !important;
	background-color: var(--wp--preset--color--base);
}

.news-grid .wp-block-read-more::after {
	content: url("../images/btn-arrow-accent-1.svg");
	flex-shrink: 0;
	margin-top: 0.75rem;
	margin-inline-start: 1rem;
	transition: transform 0.15s ease-in-out;
}

.news-grid .wp-block-read-more:hover::after {
	transform: translateX(0.35rem);
} */

/* 04.4. Post author
--------------------------------------------- */
.autor-image {
	width: auto;
	height: 60px;
	border-radius: 50%;
}

.autor-name {
	font-weight: var(--wp--custom--font-weight--semi-bold);
}

/*------------------------------------------------------------
	05. Blockquotes
------------------------------------------------------------*/

blockquote {
	border: 0 !important;
	margin: 0;
	padding-right: var(--wp--preset--spacing--large);
	padding-left: 0 !important;
}

blockquote cite {
	font-style: normal;
	color: var(--wp--preset--color--accent-1) !important;
}

@media (max-width: 781px) {
	.quote-img {
		width: 60px;
	}
}

/*------------------------------------------------------------
	06. Accordions
------------------------------------------------------------*/
.wp-block-accordion-heading__toggle:hover,
.wp-block-accordion-heading__toggle:focus,
.wp-block-accordion-heading__toggle:hover .wp-block-accordion-heading__toggle-title,
.wp-block-accordion-heading__toggle:focus .wp-block-accordion-heading__toggle-title {
	text-decoration: none !important;
	box-shadow: none !important;
	border-bottom: none !important;
}

.wp-block-accordion-heading__toggle-icon {
	font-size: 1.75rem !important;
}

/* .wp-block-accordion-heading__toggle-title {
flex-grow: 4;
width: 300px;
} */

.acc-separator-1 .wp-block-accordion-item {
	padding-bottom: 2rem;
	border-bottom: 1px solid var(--wp--preset--color--dark);
}

.acc-separator-1 .wp-block-accordion-heading__toggle-icon {
	color: var(--wp--preset--color--dark) !important;
}

.faq-acc .wp-block-accordion-heading__toggle[aria-expanded="true"],
.faq-acc .wp-block-accordion-heading__toggle[aria-expanded="true"] .wp-block-accordion-heading__toggle-title,
.faq-acc .wp-block-accordion-heading__toggle[aria-expanded="true"] .wp-block-accordion-heading__toggle-icon {
	color: #FB521E !important;
}

.accent-1-acc .wp-block-accordion-heading__toggle[aria-expanded="true"],
.accent-1-acc .wp-block-accordion-heading__toggle[aria-expanded="true"] .wp-block-accordion-heading__toggle-title,
.accent-1-acc .wp-block-accordion-heading__toggle[aria-expanded="true"] .wp-block-accordion-heading__toggle-icon {
	color: #FB521E !important;
}

/*------------------------------------------------------------
	07. Decorative elements
------------------------------------------------------------*/

/* 07.1. Symbols
--------------------------------------------- */
.symbol {
	position: relative;
	transform: translate(-5%,75%);
	margin-right: 2rem;
	z-index: 2;
}

@media (max-width: 781px) {
	.symbol img {
		width: 70px;
	}
}

/* 07.2. Background and sticky "bohrer" element
--------------------------------------------- */
.bohrer-bg {
	background-image: url("../images/schraube-bg.svg");
	background-repeat: repeat-y;
	background-position: 50% 0;
	z-index: 0;
}

@media (max-width: 781px) {
	.bohrer-bg {
		background-image: none;
	}
}

.bohrer {
	position: sticky;
	top: 15vh;
	z-index: 10;
	will-change: transform;
}

/*------------------------------------------------------------
	08. Utility classes
------------------------------------------------------------*/

.counter-size p {
	font-size: 3.6rem !important;
	font-weight: 700;
}

.count-up {
	font-size: 3.6rem !important;
	font-weight: 700;
}

/*------------------------------------------------------------
	09. Expandable content on mobile devices
------------------------------------------------------------*/

.js-mobile-collapse-toggle[hidden] {
	display: none !important;
}

@media (max-width: 781px) {
	.js-mobile-collapse {
		position: relative;
		overflow: hidden;
	}

	.js-mobile-collapse.is-ready {
		transition: max-height 0.35s ease;
	}

	/* Fade-out at the bottom edge of collapsed content. */
	.js-mobile-collapse.is-collapsed::after {
		content: "";
		position: absolute;
		inset-inline: 0;
		bottom: 0;
		height: 2rem;
		pointer-events: none;
	}
}

/*------------------------------------------------------------
	10. Reduced motion
------------------------------------------------------------*/

@media (prefers-reduced-motion: reduce) {
	.js-mobile-collapse.is-ready {
		transition: none;
	}
}

@media (max-width: 781px) and (prefers-reduced-motion: reduce) {
	/* Release the inline height without waiting for JavaScript's transitionend handler. */
	.js-mobile-collapse.is-ready:not(.is-collapsed) {
		max-height: none !important;
	}
}
