/* Hausarztpraxis Höltkemeier – Farben und Schriften nach Logo und Visitenkarte */

/* Schriften lokal eingebunden (variable Schriften, lateinischer Zeichensatz).
   Playfair Display und Work Sans stehen unter der SIL Open Font License. */
@font-face {
  font-family: "Playfair Display";
  font-style: normal;
  font-weight: 400 900;
  font-display: swap;
  src: url("assets/fonts/playfair-display-latin.woff2") format("woff2");
}
@font-face {
  font-family: "Work Sans";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url("assets/fonts/work-sans-latin.woff2") format("woff2");
}

:root {
  --cream: #FFF0BD;      /* Seitenhintergrund wie auf der Karte */
  --earth: #B88E63;      /* erdiges Braun am Seitenende */
  --paper: #FFF9E6;      /* Karten */
  --ink: #15120C;        /* Tuscheschwarz des Baumes */
  --ink-soft: #453E2E;
  --gold: #CCA130;       /* Sonne im Logo */
  --gold-soft: #E9CC73;
  --serif: "Playfair Display", Didot, "Bodoni MT", Georgia, serif;
  --sans: "Work Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --wrap: 1060px;
  --gutter: clamp(16px, 4vw, 32px);
}

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

html { -webkit-text-size-adjust: 100%; scroll-padding-top: 24px; }

body {
  margin: 0;
  background: var(--cream);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 1.0625rem;
  line-height: 1.6;
  overflow-x: hidden;
}

h1, h2, h3, p, dl, dd { margin: 0; }
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-underline-offset: 0.18em; text-decoration-thickness: 1.5px; }
a:hover { text-decoration-color: var(--gold); }
:focus-visible { outline: 3px solid var(--ink); outline-offset: 3px; border-radius: 4px; }

.skip {
  position: absolute; left: 12px; top: -60px; z-index: 10;
  background: var(--ink); color: var(--cream);
  padding: 10px 16px; border-radius: 8px; text-decoration: none;
}
.skip:focus { top: 12px; }

.wrap { max-width: var(--wrap); margin-inline: auto; }

/* ---------- Wurzeln und Blätter ---------- */
#roots, #leaves {
  position: fixed; inset: 0;
  width: 100%; height: 100%;
  z-index: 1;
  pointer-events: none;
}

/* ---------- Hero ---------- */
.hero {
  min-height: 100vh;
  min-height: 100svh;
  display: flex; flex-direction: column; align-items: center;
  padding: 0 var(--gutter) clamp(56px, 13vh, 150px);
  text-align: center;
  /* Das Logobild ist breiter als sein Kasten (durchsichtiger Rand): kein seitliches Scrollen */
  overflow-x: hidden;
  overflow-x: clip;
  /* Nach oben hin hellt der Hintergrund sanft auf – ein helles Creme, kein reines Weiss */
  background: linear-gradient(to bottom, #FFF9E3 0%, #FFF4CE 40%, var(--cream) 80%);
}

.nav {
  position: relative; z-index: 2;
  display: flex; flex-wrap: wrap; justify-content: center;
  gap: 6px clamp(18px, 4vw, 40px);
  padding: 22px 0 0;
  font-weight: 500;
}
.nav a { text-decoration: none; padding: 6px 2px; border-bottom: 1.5px solid transparent; }
.nav a:hover { border-bottom-color: var(--gold); }

.hero__text { position: relative; z-index: 2; margin-top: clamp(14px, 3.5vh, 40px); }

h1 {
  font-family: var(--serif);
  font-weight: 700;
  font-size: clamp(2.2rem, 6.4vw, 4.75rem);
  line-height: 0.98;
  letter-spacing: -0.045em;
  text-transform: uppercase;
}
h1 span { white-space: nowrap; }

.hero__sub {
  margin-top: clamp(12px, 2vh, 18px);
  font-size: clamp(0.95rem, 1.7vw, 1.2rem);
  text-wrap: balance;
}

.hero__actions {
  margin-top: clamp(18px, 3vh, 28px);
  display: flex; flex-wrap: wrap; justify-content: center; gap: 12px;
}

.btn {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 11px 22px;
  border: 1.5px solid var(--ink); border-radius: 999px;
  background: var(--paper); color: var(--ink);
  font-weight: 600; text-decoration: none;
  transition: background-color 0.2s, color 0.2s;
}
.btn:hover { background: var(--gold-soft); }
.btn--solid { background: var(--ink); color: var(--cream); }
.btn--solid:hover { background: var(--gold); color: var(--ink); }
.btn svg { width: 18px; height: 18px; fill: currentColor; }

/* Das Logo ohne Schriftzug (der Name steht als Text darüber). Der Kasten ist
   auf den Ring bemessen; Blätter und Wurzelspitzen, die im Logo über den Ring
   hinausragen, ragen auch hier über den Kasten hinaus und werden nicht
   beschnitten.
   Kasten im Originalbild (1214 x 1275): Quadrat 1026 px ab (93, 129). */
.emblem {
  position: relative; z-index: 0;
  flex: none;
  width: min(60vh, 92vw, 680px);
  width: min(60svh, 92vw, 680px);
  aspect-ratio: 1;
  margin-top: clamp(20px, 4vh, 48px);
}
.emblem__logo {
  position: absolute;
  width: 118.324%; max-width: none;
  left: -9.064%; top: -12.573%;
  /* Aus dem Logo ist der äussere Rand der Sonne ausgestanzt (Radius 277 bis
     334 px um den Sonnenmittelpunkt); die Lücke füllt .emblem__shade. */
  -webkit-mask-image: radial-gradient(ellipse 27.5124% 26.1961% at 49.4234% 45.2941%, #000 82.485%, transparent 83.383%, transparent 99.551%, #000 100.449%);
  mask-image: radial-gradient(ellipse 27.5124% 26.1961% at 49.4234% 45.2941%, #000 82.485%, transparent 83.383%, transparent 99.551%, #000 100.449%);
}
/* Pulsierende Sonne – drei Ebenen deckungsgleich über der Sonne des Logos.
   Lage im Originalbild: Quadrat 764 px ab (218, 195), Sonnenradius 331 px.

   Nach aussen (.emblem__sun): ein Ring aus der Goldtextur der Sonne, samt
   Ästen und Blättern. Er ist kreisförmig beschnitten; in Ruhe endet der
   Schnitt knapp innerhalb der Sonne (nichts sichtbar), beim Pulsieren weitet
   er sich um 13 %.

   Nach innen (.emblem__shade + .emblem__core): Das Bild .emblem__shade füllt
   die im Logo ausgestanzte Lücke und zeigt den äusseren Rand der Sonne so
   hell und durchscheinend wie die Fläche um sie herum – es passt damit zu
   jedem Seitenhintergrund. Darüber liegt eine Kopie des Logos, kreisförmig
   beschnitten: In Ruhe verdeckt sie die Lücke ganz (das Logo ist
   unverändert), beim Pulsieren zieht sich der Schnitt um 15 % zusammen. */
.emblem__sun, .emblem__shade, .emblem__core {
  position: absolute;
  left: 12.183%; top: 6.433%;
  width: 74.464%; height: auto; max-width: none;
}
.emblem__sun { clip-path: circle(42.9% at 49.93% 50%); }
.emblem__core { aspect-ratio: 1; clip-path: circle(44% at 49.93% 50%); }
.emblem__core img {
  position: absolute;
  width: 158.901%; max-width: none;
  left: -28.534%; top: -25.524%;
}

/* ---------- Tiefer in die Erde ---------- */
/* Unterhalb des Hero wird der Hintergrund nach unten sanft dunkler; der Hero
   endet in der Seitenfarbe, hier geht es nahtlos weiter. Der Abstand zum Fuss
   gehört dazu, damit der Verlauf bis dorthin reicht. */
.earth {
  padding-bottom: clamp(96px, 16vh, 170px);
  background: linear-gradient(to bottom, var(--cream) 0%, #F3DFAB 40%, #E0C594 70%, var(--earth) 100%);
}
.earth + .footer { margin-top: 0; }

/* ---------- Abschnitte ---------- */
.section { padding: clamp(72px, 13vh, 140px) var(--gutter) 0; }

.sheet {
  position: relative; z-index: 2;
  background: var(--paper);
  border: 1.5px solid var(--ink);
  border-radius: 18px;
  padding: clamp(24px, 4vw, 46px);
}

.eyebrow {
  font-size: 0.8125rem; font-weight: 600;
  letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--ink-soft);
  margin-bottom: 10px;
}

h2 {
  font-family: var(--serif); font-weight: 700;
  font-size: clamp(1.75rem, 3.6vw, 2.6rem);
  line-height: 1.08; letter-spacing: -0.025em;
  text-wrap: balance;
}

h3 {
  font-family: var(--serif); font-weight: 700;
  font-size: 1.45rem; line-height: 1.15; letter-spacing: -0.015em;
}

.sheet--intro {
  max-width: 620px; margin-inline: auto;
  text-align: center;
}
.sheet--intro h2 + p { margin-top: 14px; }

/* Mitteilung über dem Angebot: etwas breiter als die Einleitung, Text linksbündig wie ein Brief */
.sheet--notice { max-width: 760px; margin-inline: auto; }
.sheet--notice .prose { margin-top: 16px; }

.grid {
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(20px, 3vw, 34px);
  margin-top: clamp(20px, 3vw, 34px);
}
.card h3 { margin-top: 18px; }
.card p { margin-top: 10px; color: var(--ink-soft); }

.leaf {
  display: grid; place-items: center;
  width: 46px; height: 46px; border-radius: 50%;
  /* Goldtextur: ein Ausschnitt aus der Sonne des Logos */
  background: var(--gold) url("assets/sun-texture.webp") center / cover;
}
.leaf svg {
  width: 24px; height: 24px;
  fill: none; stroke: var(--ink); stroke-width: 1.7;
  stroke-linecap: round; stroke-linejoin: round;
}

.sheet--praxis {
  display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: clamp(20px, 5vw, 64px);
  /* Die Sonne aus dem Logo als Akzent in der Ecke: ihre Goldtextur ohne den
     Baum (assets/sun-disc.webp), Mittelpunkt bei 40px / 100% + 10px, Radius 130px */
  background:
    url("assets/sun-disc.webp") left -90px bottom -140px / 260px 260px no-repeat,
    var(--paper);
}
.prose p + p { margin-top: 1em; }
.signature { font-family: var(--serif); font-weight: 600; font-size: 1.3rem; }

.sheet--kontakt {
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(24px, 5vw, 64px);
}
.phone {
  display: inline-block; margin-top: 18px;
  font-family: var(--serif); font-weight: 700;
  font-size: clamp(2rem, 5vw, 3rem); line-height: 1.1; letter-spacing: -0.02em;
  font-variant-numeric: lining-nums;
  text-decoration: underline; text-decoration-color: var(--gold);
  text-decoration-thickness: 3px; text-underline-offset: 0.16em;
  white-space: nowrap;
}
.note { margin-top: 14px; color: var(--ink-soft); max-width: 34ch; }
.note a { font-weight: 600; color: var(--ink); }

.sheet--zeiten {
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(24px, 5vw, 64px);
  margin-top: clamp(20px, 3vw, 34px);
}
.sheet--zeiten dl { margin-top: 18px; }
.sheet--zeiten dd { font-variant-numeric: tabular-nums; }
abbr[title] { text-decoration: none; }

address { font-style: normal; }
dl > div { padding: 14px 0; border-top: 1.5px solid var(--gold-soft); }
dl > div:first-child { border-top: 0; padding-top: 0; }
dt {
  font-size: 0.8125rem; font-weight: 600;
  letter-spacing: 0.14em; text-transform: uppercase; color: var(--ink-soft);
}
dd { margin-top: 4px; overflow-wrap: anywhere; }
address .btn { margin-top: 10px; }

/* ---------- Fuss ---------- */
.footer {
  position: relative; z-index: 2;
  margin-top: clamp(96px, 16vh, 170px);
  background: var(--ink); color: var(--cream);
  padding: 44px var(--gutter) 36px;
  text-align: center;
}
.footer__name {
  font-family: var(--serif); font-weight: 700;
  font-size: 1.5rem; letter-spacing: -0.03em; text-transform: uppercase;
  margin-bottom: 8px;
}
.footer__small { margin-top: 18px; font-size: 0.875rem; opacity: 0.7; }
.footer :focus-visible { outline-color: var(--cream); }

/* ---------- Impressum und Datenschutz ---------- */
.page__head {
  display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between;
  gap: 8px 24px;
  max-width: 820px; margin-inline: auto;
  padding: 26px var(--gutter) 0;
}
.page__home {
  font-family: var(--serif); font-weight: 700;
  font-size: 1.35rem; letter-spacing: -0.03em; text-transform: uppercase;
  text-decoration: none;
}
.page__back { font-weight: 500; }
.page .section { padding-top: clamp(28px, 6vh, 56px); }
.wrap--narrow { max-width: 820px; }

.legal h1 {
  font-size: clamp(2rem, 5vw, 3rem); line-height: 1.05;
  letter-spacing: -0.03em; text-transform: none;
}
.legal h2 { font-size: 1.4rem; letter-spacing: -0.015em; margin-top: 1.8em; }
.legal p, .legal ul { margin-top: 0.7em; }
.legal ul { padding-left: 1.2em; }
.legal li + li { margin-top: 0.3em; }
.legal address { margin-top: 0.7em; }
.legal .stand { margin-top: 2em; color: var(--ink-soft); font-size: 0.9375rem; }
.legal mark { background: var(--gold-soft); padding: 0 0.25em; border-radius: 3px; }

/* ---------- Schmale Bildschirme ---------- */
@media (max-width: 760px) {
  .grid, .sheet--praxis, .sheet--kontakt, .sheet--zeiten { grid-template-columns: minmax(0, 1fr); }
  .sheet--praxis {
    padding-bottom: 72px;
    background:
      url("assets/sun-disc.webp") right -60px bottom -110px / 180px 180px no-repeat,
      var(--paper);
  }
}

/* ---------- Bewegung ---------- */
/* Die Klasse .motion setzt das Skript im Seitenkopf (siehe index.html). */
html.motion { scroll-behavior: smooth; }

.motion .hero__text > * { animation: rise 0.9s cubic-bezier(0.2, 0.7, 0.2, 1) both; }
.motion .hero__text > :nth-child(2) { animation-delay: 0.12s; }
.motion .hero__text > :nth-child(3) { animation-delay: 0.24s; }
.motion .emblem { animation: fade 1.1s ease-out 0.15s both; }
/* Ein Atemzug der Sonne dauert 10 s (5 s hin, 5 s zurück). Beide Ebenen
   folgen demselben Kreis, der gleichmässig zwischen kleinster und grösster
   Sonne schwingt – so gibt es keine Übergabe und kein Stocken. Die negative
   Verzögerung lässt die Bewegung bei der Originalgrösse beginnen. */
.motion .emblem__sun,
.motion .emblem__core {
  animation: sun 5s cubic-bezier(0.37, 0, 0.63, 1) -2.63s infinite alternate;
  will-change: clip-path;
}

.motion .reveal { opacity: 0; transform: translateY(18px); transition: opacity 0.7s ease-out, transform 0.7s cubic-bezier(0.2, 0.7, 0.2, 1); }
.motion .reveal.is-in { opacity: 1; transform: none; }

@keyframes rise { from { opacity: 0; transform: translateY(14px); } }
@keyframes fade { from { opacity: 0; } }
/* Von der kleinsten (−15 %) zur grössten Sonne (+13 %); die Originalgrösse
   liegt bei 43.4 %. Innerhalb davon ist der Goldring leer, ausserhalb zeigt
   die Logo-Kopie nur, was ohnehin dort liegt – deshalb reicht ein Kreis für beide. */
@keyframes sun {
  from { clip-path: circle(36.9% at 49.93% 50%); }
  to { clip-path: circle(48.9% at 49.93% 50%); }
}

@media print {
  #roots, #leaves, .nav, .skip { display: none; }
  .hero { min-height: 0; }
}
