:root {
  --cream: #faf8f4;
  --panel: rgba(250, 248, 244, 0.94);
  --panel-solid: #faf8f4;
  --ink: #2c2620;
  --ink-muted: #7a6f5c;
  --bronze: #8c6a38;
  --bronze-dim: #b39a6d;
  --highlight: #1b5e3f;
  --line: rgba(44, 38, 32, 0.12);
  --dark-bg: #241f1a;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  color: var(--ink);
  font-family: 'IBM Plex Sans', sans-serif;
  font-weight: 300;
  overflow-x: hidden;
  background: var(--cream);
}

/* Parallax BG */
.bg-layer {
  display: none;
}

.bg-veil {
  display: none;
}

/* Section-specific Parallax */
section.hero, section.block, section.team {
  position: relative;
  background-image: url('../assets/img/topo-bg.jpg');
  background-repeat: repeat;
  background-size: 600px 600px;
  background-attachment: fixed;
  background-position: 0 0;
}

section.hero::before, section.block::before, section.team::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(250,248,244,0.15), rgba(250,248,244,0.25) 40%, rgba(250,248,244,0.45));
  pointer-events: none;
  z-index: 1;
}

section.hero > *, section.block > *, section.team > * {
  position: relative;
  z-index: 2;
}

.content { position: relative; z-index: 2; background: var(--cream); }

/* NAV */
nav {
  position: sticky;
  top: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.2rem 5vw;
  background: var(--panel);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}

.nav-brand { display: flex; align-items: center; gap: 0.9rem; }
.nav-brand svg { width: 32px; height: 32px; }
.nav-brand-text .main { font-family: 'Fraunces', serif; font-size: 1rem; font-weight: 500; letter-spacing: 0.01em; }
.nav-brand-text .sub { font-family: 'IBM Plex Mono', monospace; font-size: 0.58rem; letter-spacing: 0.15em; text-transform: uppercase; color: var(--ink-muted); }

.nav-links { display: flex; gap: 2.4rem; list-style: none; }
.nav-links a { font-size: 0.88rem; color: var(--ink); text-decoration: none; opacity: 0.75; transition: opacity 0.25s, color 0.25s; }
.nav-links a:hover { opacity: 1; color: var(--bronze); }

.nav-cta {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.71rem;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: white;
  background: var(--highlight);
  padding: 0.7rem 1.5rem;
  text-decoration: none;
  white-space: nowrap;
  transition: background 0.3s, box-shadow 0.3s;
}
.nav-cta:hover { background: #0f3f2a; box-shadow: 0 8px 24px rgba(27, 94, 63, 0.2); }

@media (max-width: 860px) { .nav-links { display: none; } }

.kicker {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.68rem;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--bronze);
  font-weight: 500;
}

/* HERO */
section.hero {
  padding: 8vh 5vw;
  max-width: 1400px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: center;
  min-height: 700px;
}

.hero-text {
  padding: 0;
}

.hero-text .kicker { margin-bottom: 2rem; }

.hero h1 {
  font-family: 'Fraunces', serif;
  font-optical-sizing: auto;
  font-weight: 400;
  font-size: clamp(2rem, 3.2vw, 2.8rem);
  line-height: 1.25;
  letter-spacing: -0.015em;
  margin-bottom: 2.2rem;
}

.hero h1 em { font-style: italic; font-weight: 300; color: var(--bronze); }

.hero-rule { width: 56px; height: 2px; background: var(--highlight); opacity: 0.85; }

.hero-image {
  width: 100%;
  height: 520px;
  background-image: url('../assets/img/hero.jpg');
  background-size: cover;
  background-position: center;
  border-radius: 4px;
  position: relative;
  overflow: hidden;
  box-shadow: 0 24px 48px rgba(44, 38, 32, 0.12);
  display: flex;
  align-items: center;
  justify-content: center;
}

.hero-image::before {
  content: '«Jedes Vermögen hat sein eigenes Gelände. Wir kennen die Route.»';
  position: absolute;
  font-family: 'Fraunces', serif;
  font-size: clamp(1.15rem, 3vw, 1.7rem);
  font-weight: 300;
  font-style: italic;
  color: white;
  text-align: center;
  max-width: 85%;
  line-height: 1.6;
  text-shadow: 0 2px 12px rgba(44, 38, 32, 0.25);
  z-index: 10;
  padding: 2rem;
  letter-spacing: 0.005em;
}

@media (max-width: 1024px) {
  section.hero { grid-template-columns: 1fr; gap: 2rem; }
  .hero-image { height: 360px; }
}
@media (max-width: 640px) {
  section.hero { padding: 4vh 4vw; }
  .hero h1 { font-size: 1.8rem; }
}

/* SEGMENT CARDS */
section.segments {
  padding: 2.5vh 5vw 3vh;
  max-width: 1400px;
  margin: 0 auto;
}

.segments-intro { margin-bottom: 3.5vh; }
.segments-intro .kicker { margin-bottom: 1.1rem; }

.segments-intro h2 {
  font-family: 'Fraunces', serif;
  font-weight: 400;
  font-size: clamp(1.4rem, 2.5vw, 2rem);
  max-width: 26ch;
  margin-bottom: 1.4rem;
  line-height: 1.3;
}

.segments-intro p {
  max-width: 70ch;
  font-size: 0.98rem;
  line-height: 1.7;
  color: var(--ink-muted);
}

.segment-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.4rem;
  margin-top: 3vh;
}

.segment-item {
  background: var(--panel-solid);
  padding: 2rem 1.8rem 2.2rem;
  border-top: 3px solid var(--highlight);
  box-shadow: 0 4px 12px rgba(44, 38, 32, 0.06);
  transition: box-shadow 0.3s, transform 0.3s;
}

.segment-item:hover { box-shadow: 0 12px 28px rgba(44, 38, 32, 0.12); transform: translateY(-2px); }

.segment-item .label {
  font-family: 'Fraunces', serif;
  font-size: 1.08rem;
  font-weight: 500;
  margin-bottom: 0.7rem;
  color: var(--ink);
}

.segment-item .desc {
  font-size: 0.88rem;
  line-height: 1.6;
  color: var(--ink-muted);
}

@media (max-width: 1024px) { .segment-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 640px) { .segment-grid { grid-template-columns: 1fr; } }

/* VALUE */
section.value {
  padding: 2.5vh 5vw 3.5vh;
  max-width: 1400px;
  margin: 0 auto;
}

.value-intro { margin-bottom: 3.5vh; }
.value-intro .kicker { margin-bottom: 1rem; }

.value-intro h2 {
  font-family: 'Fraunces', serif;
  font-weight: 400;
  font-size: clamp(1.4rem, 2.5vw, 2rem);
  max-width: 24ch;
  margin-bottom: 1.4rem;
  line-height: 1.3;
}

.value-intro p {
  max-width: 68ch;
  font-size: 0.98rem;
  line-height: 1.7;
  color: var(--ink-muted);
}

.value-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.4rem;
  margin-top: 3vh;
}

.value-item {
  background: var(--panel-solid);
  padding: 2.4rem 2.2rem 2.6rem;
  border-top: 2px solid var(--bronze-dim);
  box-shadow: 0 4px 12px rgba(44, 38, 32, 0.06);
  transition: box-shadow 0.3s;
}

.value-item:hover { box-shadow: 0 10px 24px rgba(44, 38, 32, 0.1); }

.value-item .num {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.66rem;
  color: var(--bronze);
  letter-spacing: 0.14em;
  display: block;
  margin-bottom: 1rem;
  font-weight: 500;
}

.value-item .q { font-family: 'Fraunces', serif; font-size: 1.08rem; font-weight: 500; line-height: 1.4; margin-bottom: 0.8rem; }
.value-item .a { font-size: 0.92rem; font-weight: 300; line-height: 1.6; color: var(--ink-muted); }

@media (max-width: 640px) { .value-grid { grid-template-columns: 1fr; } }

/* FACTS STRIPE */
section.facts {
  padding: 1.8vh 5vw 2.2vh;
  max-width: 1400px;
  margin: 0 auto;
  margin-top: 1vh;
}

.facts-card {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0;
  background: var(--panel-solid);
  box-shadow: 0 4px 12px rgba(44, 38, 32, 0.06);
}

.fact {
  padding: 3rem 2.2rem;
  border-right: 1px solid var(--line);
  text-align: center;
}

.fact:last-child { border-right: none; }

.fact .num {
  font-family: 'Fraunces', serif;
  font-size: 2.4rem;
  font-weight: 500;
  color: var(--highlight);
  margin-bottom: 0.5rem;
}

.fact .label {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.8rem;
  color: var(--ink-muted);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

@media (max-width: 700px) {
  .facts-card { grid-template-columns: 1fr; }
  .fact { border-right: none; border-bottom: 1px solid var(--line); }
  .fact:last-child { border-bottom: none; }
}

/* BLOCK */
section.block {
  padding: 8vh 5vw;
  max-width: 1400px;
  margin: 0 auto;
  display: flex;
  gap: 3rem;
  align-items: center;
  min-height: 700px;
}

.block-text { padding: 0; flex: 1; }
.block-text .kicker { margin-bottom: 1.4rem; }
.block-text .kicker { margin-bottom: 2rem; }

.block-text h2 {
  font-family: 'Fraunces', serif;
  font-weight: 400;
  font-size: clamp(1.8rem, 3vw, 2.4rem);
  line-height: 1.25;
  letter-spacing: -0.015em;
  margin-bottom: 2rem;
  color: var(--ink);
}

.block-text p.lead {
  font-family: 'Fraunces', serif;
  font-weight: 400;
  font-size: clamp(1.35rem, 2.3vw, 1.75rem);
  line-height: 1.55;
  color: var(--ink);
}

.block-image {
  flex: 1;
  width: 100%;
  height: 380px;
  background-size: cover;
  background-position: center;
  border-radius: 4px;
  box-shadow: 0 24px 48px rgba(44, 38, 32, 0.12);
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

.block-image::before {
  content: '«Wo andere Umwege gehen, haben wir die Route längst kartiert.»';
  position: absolute;
  font-family: 'Fraunces', serif;
  font-size: clamp(1rem, 2.5vw, 1.3rem);
  font-weight: 300;
  font-style: italic;
  color: white;
  text-align: center;
  max-width: 85%;
  line-height: 1.6;
  text-shadow: 0 2px 12px rgba(44, 38, 32, 0.25);
  z-index: 10;
  padding: 2rem;
  letter-spacing: 0.005em;
}

.block.reverse { direction: rtl; }
.block.reverse .block-text { direction: ltr; }
.block.reverse .block-image { direction: ltr; }

@media (max-width: 1024px) {
  section.block { flex-direction: column; gap: 2rem; }
  .block.reverse { direction: ltr; }
  .block-image { height: 320px; }
}

/* TEAM */
section.team {
  padding: 2.8vh 5vw 4vh;
  max-width: 1400px;
  margin: 0 auto;
}

section.team .kicker { margin-bottom: 1.2rem; }

section.team h2 {
  font-family: 'Fraunces', serif;
  font-weight: 400;
  font-size: clamp(1.4rem, 2.5vw, 2rem);
  margin-bottom: 3.5vh;
  max-width: 30ch;
  line-height: 1.3;
}

.team-group { margin-bottom: 5.5vh; }
.team-group:last-child { margin-bottom: 0; }

.group-label {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.68rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--ink-muted);
  margin-bottom: 2.4rem;
  padding-bottom: 1.2rem;
  border-bottom: 1px solid var(--line);
}

.founder-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  column-gap: 4rem;
  row-gap: 3.5rem;
}

.founder {
  display: flex;
  align-items: center;
  gap: 1.6rem;
}

.founder-photo {
  width: 68px;
  height: 68px;
  border-radius: 50%;
  flex-shrink: 0;
  background: repeating-linear-gradient(135deg, #d4c5a9, #d4c5a9 6px, #c4b090 6px, #c4b090 12px);
  border: 1px solid var(--line);
  box-shadow: 0 4px 12px rgba(44, 38, 32, 0.08);
}

.founder-name {
  font-family: 'Fraunces', serif;
  font-size: 1.08rem;
  font-weight: 500;
  color: var(--ink);
}

.founder-title {
  font-size: 0.84rem;
  color: var(--ink-muted);
  margin-top: 0.3rem;
}

@media (max-width: 640px) {
  .founder-grid { grid-template-columns: 1fr; column-gap: 0; row-gap: 3rem; }
}

/* CONTACT */
section.kontakt {
  padding: 2.8vh 5vw 4vh;
  max-width: 1400px;
  margin: 0 auto;
}

section.kontakt .kicker { margin-bottom: 1rem; }

section.kontakt h2 {
  font-family: 'Fraunces', serif;
  font-weight: 400;
  font-size: clamp(1.4rem, 2.5vw, 2rem);
  max-width: 22ch;
  margin-bottom: 2.8rem;
  line-height: 1.3;
}

.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1.4rem; margin-bottom: 1.4rem; }

.field { display: flex; flex-direction: column; gap: 0.6rem; }
.field.full { grid-column: 1 / -1; }

.field label {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.65rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-muted);
}

.field input, .field select, .field textarea {
  font-family: 'IBM Plex Sans', sans-serif;
  font-size: 0.96rem;
  font-weight: 300;
  color: var(--ink);
  background: transparent;
  border: none;
  border-bottom: 1px solid var(--line);
  padding: 0.65rem 0;
  outline: none;
  transition: border-color 0.25s;
}

.field input:focus, .field select:focus, .field textarea:focus { border-bottom-color: var(--bronze); }

.field textarea { resize: vertical; min-height: 90px; }

.form-submit {
  margin-top: 2rem;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.74rem;
  letter-spacing: 0.11em;
  text-transform: uppercase;
  color: white;
  background: var(--bronze);
  border: none;
  padding: 0.9rem 2rem;
  cursor: pointer;
  transition: background 0.3s, box-shadow 0.3s;
}

.form-submit:hover { background: #6f5029; box-shadow: 0 8px 20px rgba(140, 106, 56, 0.2); }

@media (max-width: 640px) {
  section.kontakt { padding: 2.2vh 4vw 3.5vh; }
  .form-row { grid-template-columns: 1fr; }
}

/* FOOTER */
footer {
  padding: 3.5vh 5vw;
  max-width: 1400px;
  margin: 0 auto;
  border-top: 1px solid var(--line);
  margin-top: 2vh;
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 2rem;
}

.wordmark {
  font-family: 'Fraunces', serif;
  font-weight: 500;
  font-size: 1.3rem;
  letter-spacing: 0.02em;
}

.wordmark span { color: var(--highlight); }

footer .meta {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.65rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--ink-muted);
}

@media (max-width: 640px) {
  .footer-inner { flex-direction: column; align-items: flex-start; gap: 1rem; }
}

/* ============================================================
   RESPONSIVE FIXES — added by dev (23.07.2026).
   Desktop (>1024px) rendering is untouched: these rules only
   override fixed inline sizes stamped by the design tool so the
   layout stops overflowing on tablets and phones.
   ============================================================ */

@media (max-width: 1024px) {
  /* hero photo: restore fluid sizing (inline 511x509 overrides the class) */
  .hero-image[style] { width: 100% !important; height: 360px !important; }

  /* "Für Mandanten" + "Für CFPs": stack image over text */
  section#fuer-wen, section#career { flex-direction: column !important; align-items: stretch !important; }
  section#fuer-wen > div[style*="677px"], section#career > div[style*="677px"] {
    width: 100% !important; max-width: 488px; height: auto !important;
    aspect-ratio: 488 / 677; margin: 0 auto;
  }

  /* founders: 5 columns -> 3 */
  section#uber-uns div[style*="grid-template-columns"] { grid-template-columns: repeat(3, 1fr) !important; }
}

@media (max-width: 900px) {
  /* team heading: let it wrap (inline white-space: nowrap) */
  section#uber-uns h2[style] { white-space: normal !important; }
  section#uber-uns div[style*="grid-template-columns"] { grid-template-columns: repeat(2, 1fr) !important; }
}

@media (max-width: 640px) {
  section#fuer-wen, section#career { gap: 2rem !important; }
}

@media (max-width: 480px) {
  section#uber-uns div[style*="grid-template-columns"] { grid-template-columns: 1fr !important; }

  /* nav: keep brand on one line next to the CTA button */
  nav { padding: 1rem 4vw; gap: 0.8rem; }
  .nav-brand { gap: 0.6rem; }
  .nav-brand-text .main { font-size: 0.88rem; white-space: nowrap; }
  .nav-brand-text .sub { font-size: 0.5rem; }
  .nav-cta { padding: 0.6rem 1rem; font-size: 0.64rem; letter-spacing: 0.06em; }
}

/* ============================================================
   CONTACT FORM STATES — added by dev (23.07.2026).
   Validation highlighting, status note and success card for the
   contact form. Visual language follows the existing design
   (Fraunces headings, IBM Plex Mono labels, bronze/green palette).
   ============================================================ */

.field-invalid input, .field-invalid textarea { border-bottom-color: #a3452e !important; }
.field-invalid label { color: #a3452e !important; }

.form-note {
  margin-top: 1rem;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.78rem;
  letter-spacing: 0.05em;
  color: #a3452e;
}
.form-note:empty { display: none; }

.form-success {
  max-width: 640px;
}

.form-success-title {
  font-family: 'Fraunces', serif;
  font-weight: 400;
  font-size: clamp(1.4rem, 2.5vw, 2rem);
  color: var(--ink);
  margin-bottom: 0.8rem;
}

.form-success-text {
  font-size: 0.98rem;
  line-height: 1.7;
  color: var(--ink-muted);
  margin-bottom: 2rem;
}

.form-success-summary {
  background: var(--panel-solid);
  border-top: 3px solid var(--highlight);
  box-shadow: 0 4px 12px rgba(44, 38, 32, 0.06);
  padding: 1.6rem 1.8rem;
}

.form-success-summary .row {
  display: grid;
  grid-template-columns: 110px 1fr;
  gap: 1.2rem;
  padding: 0.55rem 0;
  border-bottom: 1px solid var(--line);
}
.form-success-summary .row:last-child { border-bottom: none; }

.form-success-summary .k {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.65rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-muted);
  padding-top: 0.2rem;
}

.form-success-summary .v {
  font-size: 0.95rem;
  line-height: 1.6;
  color: var(--ink);
  overflow-wrap: anywhere;
  white-space: pre-line;
}
