/*
Theme Name: Herzblick Blocktheme
Theme URI: https://herzblick.info/
Author: Herzblick
Description: Editierbares, klares One-Pager-Blocktheme für systemische Beratung.
Version: 3.1.0
Requires at least: 6.5
Requires PHP: 7.4
Text Domain: herzblick
*/

:root {
  --hb-main: #f1ecea;
  --hb-secondary: #e2b29d;
  --hb-active: #b59f94;
  --hb-text: #3f3a38;
  --hb-muted: #766d69;
  --hb-white: #fff;
  --hb-line: rgba(63, 58, 56, .14);
  --hb-font: "Avenir Next", Avenir, "Segoe UI Variable Text", "Segoe UI", "Helvetica Neue", Helvetica, Arial, sans-serif;
  --hb-wide: 1240px;
  --hb-header-height: 112px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--hb-main);
  color: var(--hb-text);
  font-family: var(--hb-font);
  font-weight: 300;
  line-height: 1.72;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
body.admin-bar .hb-site-header { top: 32px; }
a { color: inherit; }
img { display: block; max-width: 100%; height: auto; }
::selection { background: var(--hb-secondary); color: var(--hb-text); }
.wp-site-blocks { min-height: 100vh; }
.wp-site-blocks > * { margin-block-start: 0; }

/* Header und Navigation */
.hb-site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  min-height: var(--hb-header-height);
  background: var(--hb-white);
  border-bottom: 1px solid rgba(181, 159, 148, .22);
  box-shadow: 0 8px 30px rgba(63, 58, 56, .035);
}
.hb-header-inner {
  width: min(calc(100% - 48px), 1480px);
  min-height: var(--hb-header-height);
  margin-inline: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 34px;
}
.hb-menu-logo { flex: 0 0 auto; margin: 0; }
.hb-menu-logo img {
  width: 106px;
  height: 93px;
  object-fit: contain;
  object-position: left center;
}
.hb-primary-nav { margin-left: auto; }
.hb-primary-nav .wp-block-navigation__container {
  gap: 5px;
  justify-content: flex-end;
  align-items: stretch;
}
.hb-primary-nav .wp-block-navigation-item { align-items: stretch; }
.hb-primary-nav .wp-block-navigation-item__content {
  display: flex;
  align-items: center;
  min-height: 48px;
  padding: 10px 13px;
  color: var(--hb-text);
  font-size: clamp(.68rem, .86vw, .82rem);
  font-weight: 400;
  line-height: 1.25;
  letter-spacing: .025em;
  text-align: center;
  text-decoration: none;
  transition: color .2s ease, background-color .2s ease;
}
.hb-primary-nav .wp-block-navigation-item__content:hover,
.hb-primary-nav .wp-block-navigation-item__content:focus-visible,
.hb-primary-nav .wp-block-navigation-item__content.hb-active,
.hb-primary-nav .wp-block-navigation-item__content[aria-current="location"] {
  background: var(--hb-active);
  color: var(--hb-white);
  outline: 0;
}

/* Grundlayout */
.hb-section {
  position: relative;
  padding: clamp(82px, 9vw, 138px) 0;
  scroll-margin-top: calc(var(--hb-header-height) + 12px);
  overflow: clip;
}
.hb-wide {
  width: min(calc(100% - 48px), var(--hb-wide));
  margin-inline: auto;
}
.hb-kicker {
  margin: 0 0 16px;
  color: var(--hb-active);
  font-size: .72rem;
  font-weight: 500;
  letter-spacing: .2em;
  line-height: 1.4;
  text-transform: uppercase;
}
.hb-display {
  max-width: 920px;
  margin: 0;
  font-size: clamp(2.8rem, 6.4vw, 6.7rem);
  font-weight: 200;
  letter-spacing: -.048em;
  line-height: .98;
}
.hb-title {
  margin: 0;
  font-size: clamp(2.15rem, 4vw, 4.4rem);
  font-weight: 200;
  letter-spacing: -.038em;
  line-height: 1.04;
}
.hb-lead {
  max-width: 780px;
  color: var(--hb-muted);
  font-size: clamp(1.12rem, 1.55vw, 1.36rem);
  font-weight: 300;
  line-height: 1.64;
}
.hb-button .wp-block-button__link {
  padding: 15px 23px;
  border: 1px solid var(--hb-active);
  border-radius: 0;
  background: var(--hb-active);
  color: var(--hb-white);
  font-size: .88rem;
  font-weight: 400;
  letter-spacing: .045em;
  transition: background-color .2s ease, color .2s ease;
}
.hb-button .wp-block-button__link:hover,
.hb-button .wp-block-button__link:focus-visible {
  background: transparent;
  color: var(--hb-text);
}

/* Hero */
.hb-hero {
  min-height: calc(100svh - var(--hb-header-height));
  display: grid;
  align-items: center;
  background: var(--hb-main);
}
.hb-hero::after {
  content: "";
  position: absolute;
  right: -11vw;
  top: 8%;
  width: clamp(320px, 45vw, 720px);
  aspect-ratio: 1;
  border-radius: 50%;
  background: radial-gradient(circle at 38% 42%, rgba(226, 178, 157, .68), rgba(226, 178, 157, .22) 48%, transparent 70%);
  pointer-events: none;
}
.hb-hero-content { position: relative; z-index: 1; }
.hb-hero-copy { max-width: 1040px; }
.hb-hero .hb-lead { margin-top: 30px; max-width: 680px; }
.hb-hero-actions { margin-top: 34px; }
.hb-hero-mark {
  width: 74px;
  height: 3px;
  margin: 0 0 30px;
  border: 0;
  background: var(--hb-secondary);
}

/* Einleitung */
.hb-intro { background: var(--hb-white); }
.hb-intro-grid {
  display: grid;
  grid-template-columns: .8fr 1.2fr;
  align-items: start;
  gap: clamp(44px, 8vw, 120px);
}
.hb-intro-copy > :first-child { margin-top: 0; }
.hb-intro-copy > :last-child { margin-bottom: 0; }

/* Leistungsabschnitte */
.hb-service { background: var(--hb-main); }
.hb-service--white { background: var(--hb-white); }
.hb-service-grid {
  display: grid;
  grid-template-columns: minmax(280px, .82fr) minmax(360px, 1.18fr);
  align-items: start;
  gap: clamp(48px, 8vw, 120px);
}
.hb-service-heading { position: sticky; top: calc(var(--hb-header-height) + 46px); }
.hb-number {
  margin: 0 0 24px;
  color: var(--hb-secondary);
  font-size: 3.2rem;
  font-weight: 200;
  line-height: 1;
}
.hb-service-copy { color: var(--hb-muted); }
.hb-service-copy > :first-child { margin-top: 0; }
.hb-service-copy h3 {
  margin-top: 40px;
  color: var(--hb-text);
  font-size: 1.1rem;
  font-weight: 400;
  letter-spacing: .02em;
}
.hb-service-copy ul { padding-left: 1.15em; }
.hb-service-copy li { margin-bottom: 8px; padding-left: 7px; }
.hb-service-copy li::marker { color: var(--hb-secondary); }
.hb-note {
  margin-top: 38px;
  padding: 28px 30px;
  border-left: 3px solid var(--hb-secondary);
  background: rgba(226, 178, 157, .13);
  color: var(--hb-text);
}

/* Über Herzblick und Kontakt */
.hb-about { background: var(--hb-secondary); }
.hb-about-grid,
.hb-contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(48px, 8vw, 120px);
  align-items: center;
}
.hb-about .hb-kicker { color: rgba(63, 58, 56, .72); }
.hb-about-photo {
  min-height: 530px;
  margin: 0;
  overflow: hidden;
  background: rgba(255, 255, 255, .34);
}
.hb-about-photo img { width: 100%; height: 100%; object-fit: cover; }
.hb-about-photo:not(:has(img))::after {
  content: "Portrait einsetzen";
  min-height: 530px;
  display: grid;
  place-items: center;
  color: rgba(63, 58, 56, .62);
  font-size: .72rem;
  font-weight: 500;
  letter-spacing: .18em;
  text-transform: uppercase;
}
.hb-contact { background: var(--hb-white); }
.hb-contact-card {
  padding: clamp(30px, 5vw, 58px);
  background: var(--hb-main);
}
.hb-contact-card p { margin: 0; padding: 15px 0; border-bottom: 1px solid var(--hb-line); }
.hb-contact-card p:last-child { border-bottom: 0; }
.hb-contact-card strong {
  display: block;
  margin-bottom: 2px;
  color: var(--hb-active);
  font-size: .7rem;
  font-weight: 500;
  letter-spacing: .17em;
  text-transform: uppercase;
}

/* Footer */
.hb-site-footer { padding: 32px 0; background: var(--hb-text); color: rgba(255,255,255,.72); }
.hb-footer-inner {
  width: min(calc(100% - 48px), var(--hb-wide));
  margin-inline: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}
.hb-site-footer p { margin: 0; font-size: .78rem; }
.hb-footer-nav .wp-block-navigation__container { gap: 20px; }
.hb-footer-nav a { color: rgba(255,255,255,.72); font-size: .78rem; text-decoration: none; }
.hb-footer-nav a:hover { color: var(--hb-secondary); }

/* Inhaltsseiten */
.hb-page { padding: clamp(70px, 9vw, 130px) 0; background: var(--hb-main); }
.hb-page .wp-block-post-title { font-size: clamp(2.4rem, 5vw, 5rem); font-weight: 200; }

@media (max-width: 1180px) {
  :root { --hb-header-height: 100px; }
  .hb-header-inner { width: min(calc(100% - 32px), 1480px); gap: 18px; }
  .hb-menu-logo img { width: 90px; height: 80px; }
  .hb-primary-nav .wp-block-navigation-item__content { padding-inline: 8px; font-size: .68rem; }
}

@media (max-width: 960px) {
  :root { --hb-header-height: 86px; }
  body.admin-bar .hb-site-header { top: 46px; }
  .hb-menu-logo img { width: 76px; height: 68px; }
  .hb-primary-nav .wp-block-navigation__responsive-container-open { display: flex; }
  .hb-primary-nav .wp-block-navigation__responsive-container:not(.is-menu-open) { display: none; }
  .hb-primary-nav .wp-block-navigation__responsive-container.is-menu-open {
    padding: 30px;
    background: var(--hb-white);
  }
  .hb-primary-nav .wp-block-navigation__responsive-container-content,
  .hb-primary-nav .wp-block-navigation__container { align-items: stretch; gap: 8px; }
  .hb-primary-nav .wp-block-navigation-item__content { justify-content: flex-start; padding: 14px; font-size: .9rem; text-align: left; }
  .hb-intro-grid,
  .hb-service-grid,
  .hb-about-grid,
  .hb-contact-grid { grid-template-columns: 1fr; }
  .hb-service-heading { position: static; }
  .hb-about-photo { min-height: 430px; max-width: 620px; }
}

@media (max-width: 600px) {
  .hb-header-inner,
  .hb-wide,
  .hb-footer-inner { width: min(calc(100% - 28px), var(--hb-wide)); }
  .hb-section { padding: 72px 0; }
  .hb-hero { min-height: calc(88svh - var(--hb-header-height)); }
  .hb-display { font-size: clamp(2.65rem, 13vw, 4.2rem); }
  .hb-title { font-size: clamp(2rem, 10vw, 3.2rem); }
  .hb-hero::after { right: -48%; top: 4%; }
  .hb-note { padding: 23px; }
  .hb-footer-inner { align-items: flex-start; flex-direction: column; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; }
}

/* Editor: Layout bleibt nah an der Frontend-Ansicht, ohne klebende Elemente. */
.editor-styles-wrapper { background: var(--hb-main); font-family: var(--hb-font); }
.editor-styles-wrapper .hb-site-header,
.editor-styles-wrapper .hb-service-heading { position: relative; top: auto; }
