/*
Theme Name: Conen Psychology
Description: A custom block theme scaffolded by Studio Code.
Requires at least: 6.7
Tested up to: 6.9
Requires PHP: 7.2
Version: 0.4.2
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: conen-psychology
Tags: full-site-editing, block-patterns, block-styles, wide-blocks, accessibility-ready, style-variations
*/

/* WordPress inserts a margin-block-start equal to the block gap (24px unless
   theme.json sets styles.spacing.blockGap) between the template's top-level
   sections (header part, main, footer part) — a gap that exists even when no
   markup asks for it. Zero it so sections butt edge-to-edge and own their
   vertical rhythm via padding; this does not affect block gaps inside nested
   layouts. */
.wp-site-blocks > * + * {
	margin-block-start: 0;
}

/* With that gap gone, main carries its own vertical padding so templates this
   theme does not author (WooCommerce shop, product, cart…) still clear the
   header and footer. A descendant selector, not a child one: WooCommerce wraps
   the single-product main in an extra group. Templates built from full-bleed
   sections opt out with is-flush and let the sections own the rhythm. */
.wp-site-blocks main {
	padding-block: var(--wp--preset--spacing--60) var(--wp--preset--spacing--70);
}
.wp-site-blocks main.is-flush {
	padding-block: 0;
}

/* --- typography helpers --- */
/* Headings use Lora (register-block theme.json font family). The heading
   font is set via the lora preset; this rule guards against stale-cached
   theme.json while keeping the ampersand in the same face. */
h1,
h2,
h3,
h4 {
	font-family: var(--wp--preset--font-family--lora), serif;
}

/* Explicit heading sizes driven by the registered presets (theme.json level
   sizes can be stale-cached); display uses the display fluid preset. */
h1 {
	font-size: var(--wp--preset--font-size--display);
}

h2 {
	font-size: clamp(1.38rem, 2.4vw, 1.95rem);
}

h3 {
	font-size: 1.125rem;
}

h4 {
	font-size: 0.9375rem;
}

.site-tagline {
	color: var(--wp--preset--color--muted);
	max-width: 30rem;
}

.hero-eyebrow {
	font-family: var(--wp--preset--font-family--albert-sans);
	font-size: 1rem;
	font-weight: 600;
	letter-spacing: 0.14em;
	text-transform: uppercase;
	color: var(--wp--preset--color--muted);
	margin-block-end: 1rem;
}

/* Section labels that introduce a block of topic cards.
   Larger than the page-top eyebrow and given breathing room
   so the heading doesn't sit flush against the section above. */
.section-eyebrow {
	font-family: var(--wp--preset--font-family--albert-sans);
	font-size: 1.25rem;
	font-weight: 600;
	letter-spacing: 0.12em;
	text-transform: uppercase;
	color: var(--wp--preset--color--accent);
	margin-block-start: 2.5rem;
	margin-block-end: 1.5rem;
}

.hero-title {
	max-width: 16ch;
	padding-block-end: 1.5rem;
	border-bottom: 2px solid var(--wp--preset--color--accent);
	display: inline-block;
}

.hero-lead {
	font-family: var(--wp--preset--font-family--lora), serif;
	font-size: clamp(1.5rem, 3.5vw, 2rem);
	font-weight: 500;
	max-width: 66rem;
	color: var(--wp--preset--color--muted);
	margin-block-start: 2rem;
	line-height: 1.5;
}

/* On dark covers make eyebrow and lead light for legibility. */
.wp-block-cover .hero-eyebrow {
	color: rgb(244 239 228 / 0.85);
}

.wp-block-cover .hero-lead {
	color: rgb(244 239 228 / 0.9);
}

/* Covers sit on a navy overlay photo; force every text block light so
   headings and body copy stay legible whatever the palette classes render. */
/* Dark sections — Covers on a navy overlay photo and navy bands (#1c3556) —
   force every text block light so headings and body copy stay legible
   whatever the palette classes render. */
.wp-block-cover__inner-container h1,
.wp-block-cover__inner-container h2,
.wp-block-cover__inner-container h3,
.wp-block-cover__inner-container p,
.wp-block-group[style*="background-color:#1c3556"] h1,
.wp-block-group[style*="background-color:#1c3556"] h2,
.wp-block-group[style*="background-color:#1c3556"] h3,
.wp-block-group[style*="background-color:#1c3556"] p,
.wp-block-group[style*="background:#1c3556"] h1,
.wp-block-group[style*="background:#1c3556"] h2,
.wp-block-group[style*="background:#1c3556"] h3,
.wp-block-group[style*="background:#1c3556"] p {
	color: #f4efe4 !important;
}

.wp-block-cover__inner-container .hero-eyebrow,
.wp-block-group[style*="background-color:#1c3556"] .hero-eyebrow,
.wp-block-group[style*="background:#1c3556"] .hero-eyebrow {
	color: rgb(244 239 228 / 0.85) !important;
}

/* Footer sits on navy now; keep its links cream instead of the global navy.
   This only matches the bottom footer, which uses background-color:#1c3556. */
.wp-block-group[style*="background-color:#1c3556"] a {
	color: #f4efe4;
}

.wp-block-group[style*="background-color:#1c3556"] a:hover {
	color: rgb(244 239 228 / 0.85);
}

/* Hero block: keep the cover content left-aligned and away from the gutter. */
.wp-block-cover__inner-container > .wp-block-group {
	margin-inline: 0;
}

/* --- buttons --- */
.wp-block-button__link,
.wp-element-button {
	transition: background-color 0.3s ease-out, color 0.3s ease-out, transform 0.3s ease-out;
}

.is-style-booking .wp-element-button:hover {
	background-color: #7a4a12;
	transform: translateY(-2px);
}

.is-style-outline-booking .wp-element-button {
	background-color: transparent;
	color: var(--wp--preset--color--primary);
	border: 1px solid var(--wp--preset--color--stone);
}

.is-style-outline-booking .wp-element-button:hover {
	background-color: var(--wp--preset--color--surface);
	color: var(--wp--preset--color--primary);
	transform: translateY(-2px);
}

/* Cover sections: on dark navy/gold, the primary button is the gold default; outline uses cream. */
.wp-block-cover .is-style-outline-booking .wp-element-button {
	color: #f4efe4;
	border-color: rgba(244, 239, 228, 0.5);
}

/* Visible keyboard focus for accessibility and usability. */
a:focus-visible,
button:focus-visible,
.wp-block-button__link:focus-visible,
.wp-block-navigation-item__content:focus-visible {
	outline: 2px solid var(--wp--preset--color--accent);
	outline-offset: 2px;
}
.is-style-rounded img {
	border-radius: 14px;
	box-shadow: 0 1px 2px rgb(0 0 0 / 0.04);
}

/* --- footer --- */
.footer-label {
	font-family: var(--wp--preset--font-family--albert-sans);
	font-size: var(--wp--preset--font-size--label);
	font-weight: 600;
	letter-spacing: 0.14em;
	text-transform: uppercase;
}

/* --- header --- */
.header-tools {
	gap: 1.5rem;
	flex-wrap: wrap;
	align-items: center;
}

.site-nav .wp-block-navigation__container {
	gap: 2rem;
}

.site-nav .wp-block-navigation-item__content {
	font-size: 1.25rem;
	transition: color 0.2s ease-out;
}

.wp-block-navigation .wp-block-navigation-item__content:hover {
	color: var(--wp--preset--color--accent);
}

/* polylang language switcher as a quiet inline segmented control (DE | EN).
   Polylang puts className "lang-switcher" on each <li>, alongside
   current-lang / lang-item, so selectors target that same element. */
.lang-switcher a {
	display: inline-flex;
	align-items: center;
	min-width: 2.25rem;
	justify-content: center;
	padding: 0.4rem 0.6rem;
	font-size: var(--wp--preset--font-size--label);
	font-weight: 600;
	letter-spacing: 0.08em;
	line-height: 1;
	border: 1px solid transparent;
	text-decoration: none;
	transition: background-color 0.2s ease-out, color 0.2s ease-out, border-color 0.2s ease-out;
}

.lang-switcher.current-lang a {
	background-color: var(--wp--preset--color--primary);
	color: var(--wp--preset--color--background);
	border-radius: var(--wp--preset--custom--rounded--sm);
}

.lang-switcher:not(.current-lang) a {
	color: var(--wp--preset--color--primary);
}

.lang-switcher:not(.current-lang) a:hover {
	border-color: var(--wp--preset--color--stone);
	color: var(--wp--preset--color--primary);
}

/* booking row button alignment */
.booking-row {
	margin-block-end: 0;
}

/* portrait keeps its natural aspect, bottom-aligned to the row's bottom (the
   buttons); never cropped */
.portrait-col {
	display: flex;
	flex-direction: column;
	justify-content: flex-end;
}
.portrait-col .wp-block-image {
	margin: 0;
}

/* portrait as a direct flex item in a nowrap "image + text" group keeps its
   natural width instead of being squeezed by the text column */
.wp-block-group.is-nowrap > .wp-block-image {
	flex-shrink: 0;
}
/* footer legal links */
.footer-legal {
	margin-top: 2.5rem;
	margin-bottom: 0;
	text-align: center;
	font-size: 0.8rem;
	line-height: 1.6;
	color: rgba(236, 228, 213, 0.78);
	border-top: 1px solid rgba(236, 228, 213, 0.18);
	padding-top: 1.5rem;
}
.wp-block-group[style*="background-color:#1c3556"] .footer-legal a {
	color: var(--wp--preset--color--accent);
	text-decoration: none;
}
.wp-block-group[style*="background-color:#1c3556"] .footer-legal a:hover {
	text-decoration: underline;
}

/* contact page – privacy notice under the form (small print) */
.privacy-note {
	margin-top: 2.5rem;
}
.privacy-note h3 {
	font-family: var(--wp--preset--font-family--albert-sans);
	font-size: var(--wp--preset--font-size--label);
	font-weight: 600;
	letter-spacing: 0.12em;
	text-transform: uppercase;
	color: var(--wp--preset--color--primary);
	margin-block-end: 0.75rem;
}
.privacy-note p {
	font-size: 0.85rem;
	line-height: 1.6;
	color: var(--wp--preset--color--muted);
	margin-block-start: 0;
	margin-block-end: 0;
}

/* site brand lockup in the header */
.site-brand {
	gap: 0.55rem;
}
.site-brand-name {
	font-family: var(--wp--preset--font-family--lora);
	font-size: 1.5rem;
	font-weight: 600;
	line-height: 1.1;
	color: var(--wp--preset--color--primary);
	margin: 0;
}
.site-brand-name a {
	color: var(--wp--preset--color--primary);
	text-decoration: none;
}
.site-brand-name a:hover {
	color: var(--wp--preset--color--accent);
}
.site-brand-meta {
	gap: 0;
	margin-top: 0;
}
.site-brand-meta p {
	font-family: var(--wp--preset--font-family--albert-sans);
	font-size: 0.85rem;
	font-weight: 500;
	line-height: 1.45;
	letter-spacing: 0.02em;
	color: var(--wp--preset--color--muted);
	margin: 0;
}
.site-brand-meta p + p {
	padding-left: 0.4rem;
}
.site-brand-meta p + p::before {
	content: "·";
	margin-right: 0.6rem;
	color: var(--wp--preset--color--stone);
}

/* Google Maps embed block: full-width, fixed aspect, rounded corners */
.conen-map {
	width: 100%;
	height: 26rem;
	border: 0;
	border-radius: 4px;
	box-shadow: 0 1px 2px rgb(0 0 0 / 0.04);
	display: block;
}

@media (max-width: 600px) {
	.conen-map {
		height: 18rem;
	}
}

/* Compact map: small card beside the address in the contact column */
.conen-map.is-style-compact {
	height: 15rem;
	margin-top: 1.25rem;
}

@media (max-width: 600px) {
	.conen-map.is-style-compact {
		height: 14rem;
	}
}

/* Map block wrapper + "Open in Google Maps" pill in the bottom-right corner */
.conen-map-wrap {
	position: relative;
}
.conen-map-wrap a.conen-map-open {
	position: absolute;
	right: 0.75rem;
	bottom: 0.75rem;
	z-index: 2;
	display: inline-flex;
	align-items: center;
	gap: 0.4rem;
	padding: 0.5rem 0.8rem;
	font-family: var(--wp--preset--font-family--albert-sans);
	font-size: 0.8rem;
	font-weight: 600;
	line-height: 1;
	letter-spacing: 0.02em;
	color: var(--wp--preset--color--primary);
	background: var(--wp--preset--color--background);
	border-radius: 999px;
	box-shadow: 0 1px 4px rgb(0 0 0 / 0.2);
	text-decoration: none;
	transition: background-color 0.2s ease-out, color 0.2s ease-out;
}
.conen-map-wrap a.conen-map-open:hover {
	color: var(--wp--preset--color--background);
	background: var(--wp--preset--color--primary);
}

/* Jetpack contact form fields */
.wp-block-jetpack-contact-form input,
.wp-block-jetpack-contact-form textarea {
	border-radius: var(--wp--preset--custom--rounded--sm);
	border: 1px solid var(--wp--preset--color--stone);
	padding: 0.75rem;
	background: #fff;
}

/* Practice photo: slightly smaller than full-bleed on large screens, centered */
@media (min-width: 901px) {
	.wp-block-image img.wp-image-56 {
		max-width: 640px;
		margin-inline: auto;
		display: block;
	}
}

/* Profile photo stays compact and centered on small screens (columns stack there) */
@media (max-width: 900px) {
	/* Home "image + text" block: photo above the text on mobile so the text
	   gets full width */
	.wp-block-group.is-nowrap:has(> .wp-block-image) {
		flex-direction: column;
		padding-inline: 20px;
	}
	.wp-block-group.is-nowrap:has(> .wp-block-image) > .wp-block-image {
		flex-shrink: 0;
		align-self: center;
	}
	.wp-block-group.is-nowrap:has(> .wp-block-image) > .wp-block-columns {
		margin-inline: auto;
	}

	.wp-block-image.is-style-rounded img.wp-image-166 {
		max-width: 170px;
		width: 170px;
		height: auto;
		margin-inline: auto;
		display: block;
	}
}

@media (max-width: 600px) {
	.wp-block-image.is-style-rounded img.wp-image-166 {
		max-width: 150px;
		width: 150px;
		height: auto;
		margin-inline: auto;
		display: block;
	}
}

@media (prefers-reduced-motion: reduce) {
	.wp-block-button__link,
	.wp-element-button {
		transition: none;
		transform: none;
	}
}

/* --- topic cards (Anliegen und Themen / Areas of Support) --- */
.is-style-topic-card {
	position: relative;
	background: var(--wp--preset--color--surface);
	border: 1px solid var(--wp--preset--color--stone);
	border-radius: var(--wp--preset--custom--rounded--lg, 1rem);
	padding: 2.5rem 2.25rem;
	box-shadow: 0 1px 2px rgb(0 0 0 / 0.03);
	height: 100%;
}

/* Gold accent bar on the top edge of each card. */
.is-style-topic-card::before {
	content: "";
	display: block;
	position: absolute;
	top: 0;
	left: 2.25rem;
	right: 2.25rem;
	height: 3px;
	background: var(--wp--preset--color--accent);
	border-radius: 0 0 4px 4px;
	opacity: 0.7;
}

/* Gold number pill badge, top-left of the card. */
.is-style-topic-card .topic-number {
	display: inline-block;
	font-family: var(--wp--preset--font-family--albert-sans);
	font-size: 0.72rem;
	font-weight: 700;
	letter-spacing: 0.12em;
	color: var(--wp--preset--color--primary);
	background: rgb(185 138 58 / 0.14);
	border: 1px solid rgb(185 138 58 / 0.35);
	border-radius: 999px;
	padding: 0.28rem 0.8rem;
	margin-block-end: 1.25rem;
}

.is-style-topic-card h3 {
	font-family: var(--wp--preset--font-family--lora), serif;
	font-size: 1.35rem;
	line-height: 1.25;
	margin-block-end: 1rem;
	padding-block-end: 0.9rem;
	border-bottom: 1px solid var(--wp--preset--color--stone);
}

.is-style-topic-card p:not(.topic-number) {
	color: var(--wp--preset--color--muted);
	margin: 0;
}

/* The blockquote inside a card is a highlighted quote, not generic body. */
.is-style-topic-card blockquote {
	border-left: 3px solid var(--wp--preset--color--accent);
	padding: 0 0 0 1rem;
	margin: 0 0 1.25rem;
}

.is-style-topic-card blockquote p {
	font-style: italic;
	color: var(--wp--preset--color--primary);
	margin: 0;
}

/* The fifth, full-width card — a calm navy field for contrast. */
.is-style-topic-card,
.is-style-topic-card-feature {
	border: 1px solid var(--wp--preset--color--stone);
	border-radius: var(--wp--preset--custom--rounded--lg, 1rem);
	padding: 2.5rem 2.25rem;
	box-shadow: 0 1px 2px rgb(0 0 0 / 0.03);
	height: 100%;
}

/* Gold accent bar on the top edge of each card. */
.is-style-topic-card::before,
.is-style-topic-card-feature::before {
	content: "";
	display: block;
	position: absolute;
	top: 0;
	left: 2.25rem;
	right: 2.25rem;
	height: 3px;
	background: var(--wp--preset--color--accent);
	border-radius: 0 0 4px 4px;
	opacity: 0.7;
}

/* Gold number pill badge, top-left of the card. */
.is-style-topic-card .topic-number,
.is-style-topic-card-feature .topic-number {
	display: inline-block;
	font-family: var(--wp--preset--font-family--albert-sans);
	font-size: 0.72rem;
	font-weight: 700;
	letter-spacing: 0.12em;
	color: var(--wp--preset--color--primary);
	background: rgb(185 138 58 / 0.14);
	border: 1px solid rgb(185 138 58 / 0.35);
	border-radius: 999px;
	padding: 0.28rem 0.8rem;
	margin-block-end: 1.25rem;
}

.is-style-topic-card h3,
.is-style-topic-card-feature h3 {
	font-family: var(--wp--preset--font-family--lora), serif;
	font-size: 1.35rem;
	line-height: 1.25;
	margin-block-end: 1rem;
	padding-block-end: 0.9rem;
	border-bottom: 1px solid var(--wp--preset--color--stone);
}

.is-style-topic-card p:not(.topic-number),
.is-style-topic-card-feature p:not(.topic-number) {
	color: var(--wp--preset--color--muted);
	margin: 0;
}

/* The blockquote inside a card is a highlighted quote, not generic body. */
.is-style-topic-card blockquote,
.is-style-topic-card-feature blockquote {
	border-left: 3px solid var(--wp--preset--color--accent);
	padding: 0 0 0 1rem;
	margin: 0 0 1.25rem;
}

.is-style-topic-card blockquote p,
.is-style-topic-card-feature blockquote p {
	font-style: italic;
	color: var(--wp--preset--color--primary);
	margin: 0;
}

/* The fifth, full-width card — a calm navy field for contrast. */
.is-style-topic-card-feature {
	position: relative;
	background: var(--wp--preset--color--primary);
	border-color: var(--wp--preset--color--primary);
}

.is-style-topic-card-feature::before {
	background: var(--wp--preset--color--accent);
}

.is-style-topic-card-feature h3,
.is-style-topic-card-feature .topic-number,
.is-style-topic-card-feature p:not(.topic-number) {
	color: var(--wp--preset--color--background);
}

.is-style-topic-card-feature .topic-number {
	border-color: rgb(244 239 228 / 0.35);
	background: rgb(244 239 228 / 0.12);
}

.is-style-topic-card-feature h3 {
	border-bottom-color: rgb(244 239 228 / 0.2);
}

.is-style-topic-card-feature blockquote p {
	color: var(--wp--preset--color--background);
}

@media (prefers-reduced-motion: reduce) {
	.is-style-topic-card {
		transition: none;
	}
}



