/*
Theme Name: Words and Pixel
Theme URI: https://www.wordsandpixel.de
Author: Words&Pixel
Description: Schlankes Block-Theme für Words&Pixel, Neumünster. Dunkles Design, Raleway lokal eingebunden, ohne Page-Builder.
Version: 1.0.7
Requires at least: 6.6
Tested up to: 7.1
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: wordsandpixel
*/

/* ---------- Grundlagen ---------- */

html {
	font-variant-numeric: lining-nums;
	-webkit-text-size-adjust: 100%;
}

body {
	-webkit-font-smoothing: antialiased;
	-moz-osx-font-smoothing: grayscale;
	text-rendering: optimizeLegibility;
}

[id] {
	scroll-margin-top: 6.5rem;
}

a {
	text-underline-offset: 0.24em;
	text-decoration-thickness: 1px;
	text-decoration-color: color-mix(in srgb, currentColor 40%, transparent);
	transition: color 0.2s ease, text-decoration-color 0.2s ease;
}

a:hover,
a:focus {
	text-decoration-color: currentColor;
}

:where(h1, h2, h3, h4, .wp-block-heading) {
	overflow-wrap: break-word;
	hyphens: auto;
	-webkit-hyphens: auto;
}

:focus-visible {
	outline: 3px solid var(--wp--preset--color--gelb);
	outline-offset: 3px;
}

::selection {
	background: var(--wp--preset--color--gelb);
	color: var(--wp--preset--color--dunkel);
}

/* Abschnitte innerhalb der Seite schließen ohne Lücke aneinander an */
.wp-block-post-content > .alignfull {
	margin-block: 0;
}

.wp-block-post-content > .alignfull + .alignfull {
	margin-block-start: 0;
}

/* ---------- Kopfbereich ---------- */

.wp-site-header {
	position: sticky;
	top: 0;
	z-index: 50;
	border-bottom: 1px solid var(--wp--preset--color--dunkel-hell);
}

.admin-bar .wp-site-header {
	top: var(--wp-admin--admin-bar--height, 32px);
}

@media (max-width: 600px) {
	.admin-bar .wp-site-header {
		top: 0;
	}
}

.wp-logo {
	display: block;
	width: clamp(150px, 18vw, 210px);
	line-height: 0;
	color: var(--wp--preset--color--weiss);
}

.wp-logo svg {
	display: block;
	width: 100%;
	height: auto;
}

.wp-logo:hover,
.wp-logo:focus {
	color: var(--wp--preset--color--weiss);
}

.wp-site-header .wp-block-navigation a {
	text-decoration: none;
}

.wp-site-header .wp-block-navigation a:hover,
.wp-site-header .wp-block-navigation a:focus,
.wp-site-header .wp-block-navigation .current-menu-item > a {
	color: var(--wp--preset--color--gelb);
}

.wp-site-header .wp-block-navigation .wp-block-navigation__submenu-container {
	background: var(--wp--preset--color--dunkel-hell);
	border: 0;
	border-top: 2px solid var(--wp--preset--color--pink);
	padding: 0.5rem 0;
	min-width: 17rem;
}

.wp-site-header .wp-block-navigation .wp-block-navigation__submenu-container .wp-block-navigation-item__content {
	padding: 0.55rem 1.25rem;
	text-transform: none;
	letter-spacing: 0;
	font-weight: 600;
}

/* Mobiles Menü (Overlay) */
.wp-block-navigation__responsive-container.is-menu-open {
	padding: var(--wp--preset--spacing--50) clamp(1.25rem, 5vw, 3rem);
}

.wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation__responsive-container-content {
	align-items: flex-start;
	gap: 1.25rem;
	padding-top: 3rem;
}

.wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation-item {
	font-size: var(--wp--preset--font-size--mittel);
}

.wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation__container,
.wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation-item,
.wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation__submenu-container {
	align-items: flex-start !important;
	text-align: left;
}

.wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation__submenu-container {
	border-top: 0;
	padding: 0.5rem 0 0 1rem !important;
	background: transparent;
}

.wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation__submenu-container .wp-block-navigation-item {
	font-size: var(--wp--preset--font-size--normal);
}

.wp-block-navigation__responsive-container-open svg,
.wp-block-navigation__responsive-container-close svg {
	width: 32px;
	height: 32px;
}

/* ---------- Startbereich ---------- */

.wp-hero {
	position: relative;
}

.wp-block-cover.alignfull.wp-hero {
	padding-left: var(--wp--style--root--padding-left);
	padding-right: var(--wp--style--root--padding-right);
}

/* Cover setzt bei eigener Inhaltsposition die Breite auf "auto" – hier volle Breite,
   damit der Inhalt bündig unter dem Logo steht */
.wp-block-cover.wp-hero .wp-block-cover__inner-container {
	width: 100% !important;
}

.wp-block-cover.wp-hero .wp-block-cover__inner-container > .alignwide {
	max-width: var(--wp--style--global--wide-size);
	margin-left: auto !important;
	margin-right: auto !important;
}

.wp-hero h1 {
	font-size: var(--wp--preset--font-size--mittel);
	font-weight: 600;
	text-transform: none;
	letter-spacing: 0;
	line-height: 1.3;
	color: var(--wp--preset--color--gelb);
}

.wp-display {
	font-size: var(--wp--preset--font-size--display);
	font-weight: 800;
	line-height: 0.92;
	text-transform: uppercase;
	letter-spacing: -0.02em;
	hyphens: manual;
	-webkit-hyphens: manual;
}

/* ---------- Laufband ---------- */

.wp-laufband {
	overflow: hidden;
	white-space: nowrap;
	padding-block: var(--wp--preset--spacing--40);
}

.wp-laufband .wp-laufband__text {
	display: inline-block;
	margin: 0;
	padding-right: 0.5em;
	font-size: var(--wp--preset--font-size--display);
	font-weight: 800;
	line-height: 1;
	text-transform: uppercase;
	color: transparent;
	-webkit-text-stroke: 1px rgba(255, 255, 255, 0.35);
	animation: wp-laufband 40s linear infinite;
}

@keyframes wp-laufband {
	from { transform: translateX(0); }
	to { transform: translateX(-50%); }
}

/* ---------- Karten: Leistungen (mattes Glas) ---------- */

.wp-leistungen {
	position: relative;
	overflow: hidden;
	isolation: isolate;
}

.wp-leistungen::before,
.wp-leistungen::after {
	content: "";
	position: absolute;
	z-index: -1;
	width: 48vw;
	height: 48vw;
	max-width: 44rem;
	max-height: 44rem;
	border-radius: 50%;
	filter: blur(100px);
	pointer-events: none;
}

.wp-leistungen::before {
	background: var(--wp--preset--color--pink);
	opacity: 0.5;
	top: 38%;
	left: -10%;
}

.wp-leistungen::after {
	background: var(--wp--preset--color--lila);
	opacity: 0.4;
	bottom: -12%;
	right: -6%;
}

.wp-leistung {
	position: relative;
	background: rgba(255, 255, 255, 0.07);
	border: 1px solid rgba(255, 255, 255, 0.12);
	border-radius: 0 1.5rem 0 0;
	box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08), 0 10px 30px rgba(0, 0, 0, 0.25);
	transition: transform 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}

@supports ((-webkit-backdrop-filter: blur(1px)) or (backdrop-filter: blur(1px))) {
	.wp-leistung {
		background: rgba(255, 255, 255, 0.045);
		-webkit-backdrop-filter: blur(22px) saturate(140%);
		backdrop-filter: blur(22px) saturate(140%);
	}
}

/* feine Körnung für die matte Oberfläche */
.wp-leistung::before {
	content: "";
	position: absolute;
	inset: 0;
	border-radius: inherit;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
	opacity: 0.06;
	pointer-events: none;
}

.wp-leistung h3 {
	font-size: clamp(1.05rem, 0.6rem + 0.8vw, 1.2rem);
	hyphens: manual;
	-webkit-hyphens: manual;
	overflow-wrap: normal;
}

.wp-leistung h3 a {
	text-decoration: none;
}

.wp-leistung h3 a::after {
	content: "";
	position: absolute;
	inset: 0;
	z-index: 1;
}

.wp-leistung:hover,
.wp-leistung:focus-within {
	transform: translateY(-4px);
	border-color: rgba(212, 0, 80, 0.75);
	box-shadow: 0 0 0 1px rgba(212, 0, 80, 0.35), 0 16px 36px rgba(212, 0, 80, 0.22);
}

.wp-leistung:hover h3 a,
.wp-leistung:focus-within h3 a {
	color: var(--wp--preset--color--gelb);
}

.wp-leistung p {
	color: #d2d2d2;
}

/* ---------- Nummerierte Liste (Leistungspunkte, Ablauf) ---------- */

.wp-liste {
	counter-reset: wpl;
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	column-gap: clamp(2rem, 5vw, 4.5rem);
	row-gap: 0;
}

@media (max-width: 781px) {
	.wp-liste {
		grid-template-columns: minmax(0, 1fr);
	}
}

.wp-liste > * {
	counter-increment: wpl;
	position: relative;
	margin: 0 !important;
	padding: 1.75rem 0 1.75rem 4.25rem;
	border-top: 1px solid rgba(255, 255, 255, 0.14);
}

.wp-liste > *::before {
	content: counter(wpl, decimal-leading-zero);
	position: absolute;
	left: 0;
	top: 1.6rem;
	font-size: 1.6rem;
	font-weight: 800;
	line-height: 1;
	color: var(--wp--preset--color--pink);
	transition: color 0.3s ease, transform 0.3s ease;
}

.wp-liste > *::after {
	content: "";
	position: absolute;
	left: 0;
	top: -1px;
	width: 0;
	height: 2px;
	background: var(--wp--preset--color--pink);
	transition: width 0.5s cubic-bezier(0.2, 0.7, 0.2, 1);
}

.wp-liste > *:hover::after,
.wp-liste > *:focus-within::after {
	width: 100%;
}

.wp-liste > *:hover::before {
	color: var(--wp--preset--color--gelb);
	transform: translateX(3px);
}

.wp-liste h3 {
	color: var(--wp--preset--color--weiss) !important;
	margin-top: 0;
	transition: transform 0.3s ease;
}

.wp-liste > *:hover h3 {
	transform: translateX(4px);
}

.wp-liste p {
	color: #cfcfcf;
}

/* ---------- Kacheln: Kompetenz / Projekt ---------- */

.wp-kachel {
	border-radius: 0 2.5rem 0 0;
	overflow: hidden;
	height: 100%;
}

.wp-kachel .wp-block-cover__image-background {
	transition: transform 0.8s ease;
}

.wp-kachel:hover .wp-block-cover__image-background {
	transform: scale(1.05);
}

.wp-kachel .wp-block-cover__inner-container {
	width: 100%;
	text-shadow: 0 1px 12px rgba(0, 0, 0, 0.45);
}

/* ---------- Einblenden beim Scrollen ---------- */

.wp-reveal--armed > * {
	opacity: 0;
	transform: translateY(48px);
	transition: opacity 0.8s ease, transform 0.8s cubic-bezier(0.2, 0.7, 0.2, 1);
}

.wp-reveal--armed > *:nth-child(2) { transition-delay: 0.1s; }
.wp-reveal--armed > *:nth-child(3) { transition-delay: 0.2s; }
.wp-reveal--armed > *:nth-child(4) { transition-delay: 0.3s; }
.wp-reveal--armed > *:nth-child(5) { transition-delay: 0.4s; }
.wp-reveal--armed > *:nth-child(6) { transition-delay: 0.5s; }

.wp-reveal--armed.is-visible > * {
	opacity: 1;
	transform: none;
}

/* ---------- Karten: Portfolio ---------- */

.wp-projekt {
	display: flex;
	flex-direction: column;
	height: 100%;
}

.wp-projekt .wp-projekt__label {
	flex: 1 1 auto;
}

.wp-projekt .wp-block-image {
	margin: 0;
	overflow: hidden;
	background: #ffffff;
}

.wp-projekt .wp-block-image img {
	width: 100%;
	aspect-ratio: 2 / 1;
	object-fit: cover;
	object-position: center;
	background: #ffffff;
	transition: transform 0.5s ease;
}

.wp-projekt:hover .wp-block-image img {
	transform: scale(1.04);
}

.wp-projekt__label h3 {
	text-transform: uppercase;
	font-weight: 800;
	letter-spacing: 0;
}

.wp-projekt__label a {
	text-decoration-thickness: 2px;
}

.wp-projekt__label a:hover,
.wp-projekt__label a:focus {
	color: var(--wp--preset--color--dunkel);
	background: var(--wp--preset--color--gelb);
	text-decoration: none;
}

/* ---------- Buttons ---------- */

.wp-block-button.is-style-outline > .wp-block-button__link {
	border: 2px solid currentColor;
	background: transparent;
	color: var(--wp--preset--color--weiss);
	padding: calc(0.9rem - 2px) calc(1.75rem - 2px);
}

.wp-block-button.is-style-outline > .wp-block-button__link:hover,
.wp-block-button.is-style-outline > .wp-block-button__link:focus {
	background: var(--wp--preset--color--gelb);
	border-color: var(--wp--preset--color--gelb);
	color: var(--wp--preset--color--dunkel);
}

/* ---------- FAQ (Details-Block) ---------- */

.wp-block-details summary {
	cursor: pointer;
	font-weight: 700;
	font-size: var(--wp--preset--font-size--mittel);
	list-style: none;
	position: relative;
	padding-right: 2.5rem;
}

.wp-block-details summary::-webkit-details-marker {
	display: none;
}

.wp-block-details summary::after {
	content: "+";
	position: absolute;
	right: 0;
	top: 50%;
	transform: translateY(-50%);
	font-size: 1.75rem;
	font-weight: 400;
	color: var(--wp--preset--color--pink);
	line-height: 1;
}

.wp-block-details[open] summary::after {
	content: "–";
}

.wp-block-details > :not(summary) {
	color: var(--wp--preset--color--grau);
}

/* ---------- Formulare (für das Formular-Plugin) ---------- */

.wp-kontakt *,
.wp-kontakt *::before,
.wp-kontakt *::after {
	box-sizing: border-box;
}

.wp-kontakt input[type="text"],
.wp-kontakt input[type="email"],
.wp-kontakt input[type="tel"],
.wp-kontakt textarea,
.wp-kontakt select {
	width: 100%;
	font: inherit;
	color: var(--wp--preset--color--weiss);
	background: var(--wp--preset--color--dunkel-hell);
	border: 1px solid #555555;
	border-radius: 0;
	padding: 0.85rem 1rem;
}

.wp-kontakt input:focus,
.wp-kontakt textarea:focus,
.wp-kontakt select:focus {
	outline: 3px solid var(--wp--preset--color--gelb);
	outline-offset: 0;
	border-color: transparent;
}

.wp-kontakt ::placeholder {
	color: #9a9a9a;
	opacity: 1;
}

.wp-kontakt label {
	display: block;
	font-weight: 600;
	margin-bottom: 0.35rem;
}

.wp-kontakt input[type="submit"],
.wp-kontakt button[type="submit"] {
	font: inherit;
	font-weight: 700;
	cursor: pointer;
	border: 0;
	border-radius: 0 1rem 0 0;
	padding: 0.9rem 1.75rem;
	background: var(--wp--preset--color--pink);
	color: var(--wp--preset--color--weiss);
}

.wp-kontakt input[type="submit"]:hover,
.wp-kontakt button[type="submit"]:hover {
	background: var(--wp--preset--color--gelb);
	color: var(--wp--preset--color--dunkel);
}

/* ---------- Fußbereich ---------- */

.wp-site-footer {
	border-top: 1px solid var(--wp--preset--color--dunkel-hell);
}

.wp-site-footer p {
	color: var(--wp--preset--color--grau);
}

.wp-site-footer .wp-logo {
	width: 180px;
}

/* ---------- Bewegung reduzieren ---------- */

@media (prefers-reduced-motion: reduce) {
	*,
	*::before,
	*::after {
		animation: none !important;
		transition: none !important;
		scroll-behavior: auto !important;
	}
}
