/* ==========================================================================
   Tierheilpraxis Ina Zillmer – Stylesheet
   Masterlayout nach "Designvorlage.pdf" (Referenzbreite 1920 px)
   ========================================================================== */

/* ---------- Schriften (lokal gehostet, DSGVO-konform) ----------
   Die drei Roboto-Dateien gehören in assets/fonts/ – siehe assets/fonts/LIESMICH.txt */
@font-face { font-family: "Roboto"; font-style: normal; font-weight: 300; font-display: swap;
  src: local("Roboto Light"), local("Roboto-Light"), url("../fonts/roboto-latin-300-normal.woff2") format("woff2"); }
@font-face { font-family: "Roboto"; font-style: normal; font-weight: 400; font-display: swap;
  src: local("Roboto"), local("Roboto-Regular"), url("../fonts/roboto-latin-400-normal.woff2") format("woff2"); }
@font-face { font-family: "Roboto"; font-style: normal; font-weight: 500; font-display: swap;
  src: local("Roboto Medium"), local("Roboto-Medium"), url("../fonts/roboto-latin-500-normal.woff2") format("woff2"); }

:root {
  /* Akzentfarbe aus dem Logo (ersetzt das Rot der Vorlage) */
  --akzent: #068ca2;
  --akzent-dunkel: #04707f;     /* für kleine Schrift/Links: Kontrast > 4,5 : 1 */
  --grau-hell: #edebec;         /* Flächen-Grau der Vorlage */
  --grau-box: #727272;          /* Kontaktboxen + Fußzeile */
  --text: #333333;
  --weiss: #ffffff;

  --container: 988px;
  --font-head: "Roboto", "Helvetica Neue", Arial, sans-serif;
  --font-body: Tahoma, Verdana, "Segoe UI", "DejaVu Sans", sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--grau-hell);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 14px;              /* Fließtext Desktop */
  line-height: 1.6;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--akzent-dunkel); }
a:focus-visible, button:focus-visible { outline: 3px solid var(--akzent); outline-offset: 3px; }
h1, h2, h3 { font-family: var(--font-head); font-weight: 400; margin: 0; }

.container { width: 100%; max-width: var(--container); margin: 0 auto; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.skip-link { position: absolute; left: 12px; top: -60px; background: var(--akzent-dunkel); color: #fff; padding: 8px 14px; z-index: 10; }
.skip-link:focus { top: 12px; }

/* ---------- Kopf (Vorlage: 188 px weiß) ---------- */
.site-header { background: var(--weiss); height: 188px; }
.site-header .container {
  height: 100%; display: flex; align-items: center; justify-content: center; gap: 22px;
  padding-left: 200px;          /* Logo sitzt in der Vorlage leicht rechts der Mitte */
}
.logo { flex: 0 0 auto; display: block; }
.logo-art { position: relative; display: block; width: 262px; }
.logo-art img { width: 100%; height: auto; }
.logo-ring { position: absolute; inset: 0; }

/* Logo-Kreis: wird langsam im Uhrzeigersinn eingeblendet.
   Start an der offenen Stelle links (270°), Mittelpunkt = Mitte der Ellipse */
@property --ring-winkel { syntax: "<angle>"; inherits: false; initial-value: 360deg; }
.logo-ring {
  -webkit-mask-image: conic-gradient(from 270deg at 60.7% 49.8%, #000 var(--ring-winkel), transparent 0);
          mask-image: conic-gradient(from 270deg at 60.7% 49.8%, #000 var(--ring-winkel), transparent 0);
  animation: ring-zeichnen 3.2s cubic-bezier(.45, .05, .3, 1) .4s both;
}
@keyframes ring-zeichnen { from { --ring-winkel: 0deg; } to { --ring-winkel: 360deg; } }
.slogan { font-family: var(--font-body); font-size: 20px; color: var(--text); margin: 48px 0 0; white-space: nowrap; }

/* ---------- Bühne / Hero (Vorlage: 443 px) ---------- */
.hero { position: relative; height: 443px; overflow: hidden; background: #cfd6d8; }
.hero picture, .hero img { width: 100%; height: 100%; }
.hero img { object-fit: cover; object-position: 50% 42%; }
.hero::after { content: ""; position: absolute; inset: 0;
  background: linear-gradient(to bottom, rgba(0,0,0,0) 45%, rgba(0,0,0,.18) 62%, rgba(0,0,0,.55) 100%); }
.hero-text {
  /* Motiv hat die Tiergesichter in der Bildmitte – Headline daher im unteren Drittel */
  position: absolute; left: 0; right: 0; bottom: 34px; z-index: 1; display: flex; justify-content: center;
  padding: 0 16px; text-align: center;
}
.hero-text p {
  margin: 0; max-width: 700px; color: rgba(255,255,255,.93);
  font-family: var(--font-head); font-size: 40px; line-height: 1.08;
  text-shadow: 0 1px 3px rgba(0,0,0,.45), 0 0 18px rgba(0,0,0,.25);
}
.hero--sub { height: 300px; }
.hero--sub img { object-position: 50% 38%; }

/* ---------- Willkommen (Vorlage: graue Fläche 372 px + Pfeil) ---------- */
.welcome { position: relative; background: var(--grau-hell); padding: 66px 0 64px; min-height: 372px; }
.welcome::after {               /* Dreieck nach unten wie in der Vorlage */
  content: ""; position: absolute; left: 50%; bottom: -26px; transform: translateX(-50%);
  border-left: 40px solid transparent; border-right: 40px solid transparent; border-top: 26px solid var(--grau-hell);
  z-index: 1;
}
.welcome .container { display: flex; justify-content: space-between; align-items: flex-start; gap: 40px; }
.welcome-text { max-width: 700px; }
.welcome h1 { color: var(--akzent); font-size: 36px; line-height: 1.08; margin-bottom: 22px; }
.welcome p { margin: 0 0 10px; }
.welcome .zitat { font-style: italic; }

.badge {                       /* ersetzt den runden Sticker der Vorlage */
  flex: 0 0 auto; margin: 26px 30px 0 0; text-align: center;
}
.badge-ring {
  position: relative; width: 216px; height: 216px; border-radius: 50%;
  background: var(--akzent); padding: 7px;
  box-shadow: 0 6px 14px rgba(0,0,0,.28);
  transform: rotate(-4deg);
}
.badge-ring img { width: 100%; height: 100%; border-radius: 50%; object-fit: cover; transform: rotate(4deg); }
.badge-name { margin-top: 14px; font-family: var(--font-head); font-size: 18px; color: var(--akzent-dunkel); }

/* ---------- Leistungen (Vorlage: weiß) ---------- */
.leistungen { background: var(--weiss); padding: 64px 0 20px; }
.section-title { color: var(--akzent); font-size: 28px; line-height: 1.2; text-align: center; margin-bottom: 36px; }
.checklist {
  list-style: none; margin: 0 auto; padding: 0 0 0 12px;
  display: grid; grid-template-columns: 1fr 1fr; grid-auto-flow: column; grid-template-rows: repeat(4, auto);
  column-gap: 40px; row-gap: 21px;
}
.checklist li { display: flex; align-items: center; gap: 11px; font-size: 14px; }
.checklist svg { flex: 0 0 24px; width: 24px; height: 24px; color: var(--akzent); }

/* Leistungen: Haken zeichnen sich, Text blendet zeitversetzt ein (nur mit JS) */
.js .checklist li { opacity: 0; transform: translateY(10px); }
.js .checklist span { opacity: 0; transform: translateX(-8px); display: inline-block; }
.js .checklist .haken-kreis, .js .checklist .haken-strich { stroke-dasharray: 1; stroke-dashoffset: 1; }
.js .checklist.is-visible li { animation: leistung-ein .5s ease-out both; animation-delay: calc(var(--i) * 170ms); }
.js .checklist.is-visible .haken-kreis { animation: linie-zeichnen .6s ease-out both; animation-delay: calc(var(--i) * 170ms + 80ms); }
.js .checklist.is-visible .haken-strich { animation: linie-zeichnen .35s ease-out both; animation-delay: calc(var(--i) * 170ms + 560ms); }
.js .checklist.is-visible span { animation: text-ein .5s ease-out both; animation-delay: calc(var(--i) * 170ms + 380ms); }
@keyframes leistung-ein { to { opacity: 1; transform: none; } }
@keyframes linie-zeichnen { to { stroke-dashoffset: 0; } }
@keyframes text-ein { to { opacity: 1; transform: none; } }

/* Überschriften: dünne, linksbündige L-Linie */
.l-linie {
  width: fit-content; max-width: 100%;
  padding: 2px 18px 9px 16px;
  border-left: 1px solid var(--akzent);
  border-bottom: 1px solid var(--akzent);
}
.section-title.l-linie { margin-left: auto; margin-right: auto; }
.l-linie { text-wrap: balance; }

/* Langer Text (kein Pendant in der Vorlage – im selben Raster gesetzt) */
.text-block { background: var(--weiss); padding: 56px 0 10px; }
.text-block .section-title { margin-bottom: 26px; }
.text-cols { columns: 2; column-gap: 40px; }
.text-cols p { margin: 0 0 12px; break-inside: avoid; }

/* "Dächer sind unsere Leidenschaft"-Zeile */
.motto { background: var(--weiss); padding: 58px 0 66px; text-align: center; }
.motto p { margin: 0; font-family: var(--font-body); font-size: 36px; line-height: 1.2; color: var(--text); }
.motto .kringel { position: relative; display: inline-block; white-space: nowrap; }
.nowrap { white-space: nowrap; }
.motto .kringel svg { position: absolute; left: -12px; top: -14px; width: calc(100% + 24px); height: calc(100% + 26px); color: var(--akzent); pointer-events: none; overflow: visible; }

/* ---------- Galerie-Band (Vorlage: grau 371 px, 3 Bilder à 593 × 250) ---------- */
.galerie { background: var(--grau-hell); padding: 60px 35px; }
.galerie-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 35px; max-width: 1850px; margin: 0 auto; }
.galerie-item { position: relative; height: 250px; overflow: hidden; background: #dcdadb; }
.galerie-item img { width: 100%; height: 100%; object-fit: cover; }
.galerie-item figcaption {
  position: absolute; left: 0; right: 0; bottom: 0; padding: 10px 16px;
  background: rgba(0,0,0,.55); color: #fff; font-family: var(--font-head); font-size: 18px;
}
/* Platzhalter, bis Zeugnis / Zertifikat / Preisliste geliefert werden */
.galerie-item.platzhalter {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px;
  background: repeating-linear-gradient(135deg, #e3e1e2 0 14px, #dddbdc 14px 28px);
  color: #6a6a6a; text-align: center; font-family: var(--font-head);
}
.galerie-item.platzhalter svg { width: 54px; height: 54px; color: var(--akzent); }
.galerie-item.platzhalter strong { font-weight: 400; font-size: 22px; color: var(--text); }
.galerie-item.platzhalter span { font-size: 14px; }

/* ---------- Kontaktboxen (Vorlage: 3 × 317 × 210, Abstand 18) ---------- */
.kontakt { background: var(--weiss); padding: 70px 0 0; }
.kontakt-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.kontakt-box {
  position: relative; background: var(--grau-box); color: #fff; text-align: center;
  min-height: 210px; padding: 30px 18px 26px;
  font-family: var(--font-head); font-weight: 300;
}
.kontakt-icon {
  position: absolute; left: 50%; top: 0; transform: translate(-50%, -50%);
  width: 48px; height: 48px; border-radius: 50%; background: var(--akzent);
  border: 3px solid #fff; display: grid; place-items: center;
}
.kontakt-icon svg { width: 22px; height: 22px; color: #fff; }
.kontakt-box h2 { font-size: 20px; font-weight: 300; line-height: 32px; margin: 0 0 8px; }
.kontakt-box h2 a { color: #fff; text-decoration: underline; text-underline-offset: 3px; text-decoration-thickness: 1px; }
.kontakt-box p { margin: 0; font-size: 16px; line-height: 21px; }
.kontakt-box p a { color: #fff; text-decoration: none; }
.kontakt-box p a:hover { text-decoration: underline; }

.cta { background: var(--weiss); text-align: center; padding: 64px 0 46px; }
.cta a { font-family: var(--font-head); font-size: 32px; line-height: 1.2; color: var(--akzent); text-underline-offset: 4px; text-decoration-thickness: 2px; }
.cta a:hover { color: var(--akzent-dunkel); }

/* ---------- Karte (Vorlage: volle Breite, 520 px) ---------- */
.karte { position: relative; height: 520px; overflow: hidden; background: #d4f7e1; border-bottom: 2px solid #fff; }
.karte picture, .karte img { width: 100%; height: 100%; }
.karte img { object-fit: cover; object-position: 51% 100%; }  /* Quellenangabe unten bleibt sichtbar */
.karte-quelle { display: none; position: absolute; right: 0; bottom: 0; margin: 0; padding: 2px 6px;
  background: rgba(255,255,255,.85); color: #444; font: 10px/1.3 Arial, sans-serif; }
/* Vorschaubild + Aktionen (Zwei-Klick-Lösung) */
.karte-aktionen {
  position: absolute; left: 27.6%; top: 50%; transform: translateY(-50%); z-index: 1;
  display: flex; flex-direction: column; align-items: flex-start; gap: 10px; width: 460px; max-width: calc(100% - 32px);
}
.karte-link, .karte-laden {
  display: inline-flex; align-items: center; gap: 10px; border: 0; cursor: pointer;
  background: rgba(30,30,30,.86); color: #fff; text-decoration: none;
  font-family: var(--font-body); font-size: 26px; line-height: 1; padding: 6px 10px 6px 8px;
}
.karte-laden { background: var(--akzent-dunkel); }
.karte-link svg, .karte-laden svg { width: 28px; height: 28px; flex: 0 0 auto; }
.karte-link:hover { background: var(--akzent-dunkel); }
.karte-laden:hover { background: #035d6a; }
.karte-laden[disabled] { opacity: .7; cursor: progress; }
.karte-info { margin: 0; padding: 4px 8px; background: rgba(255,255,255,.9); color: #333; font-size: 12px; line-height: 1.4; }
.karte-info a { color: var(--akzent-dunkel); }
.karte-info.is-fehler { background: #fff; border-left: 3px solid var(--akzent); }
.karte-live { position: absolute; inset: 0; z-index: 2; }
.karte.is-live .karte-aktionen, .karte.is-live .karte-quelle { display: none; }

/* ---------- Fußzeile (Vorlage: 48 px #727272) ---------- */
.site-footer { background: var(--grau-box); color: #fff; font-size: 15px; }
.site-footer .container { min-height: 48px; display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 0 10px; }
.site-footer p { margin: 0; }
.site-footer nav { display: flex; gap: 35px; }
.site-footer a { color: #fff; text-decoration: none; }
.site-footer a:hover, .site-footer a[aria-current="page"] { text-decoration: underline; }
.page-end { height: 65px; background: var(--grau-hell); }

/* ---------- Unterseiten (Impressum / Datenschutz) ---------- */
.content { background: var(--weiss); padding: 64px 0 72px; }
.content .container { max-width: 988px; }
.content h1 { color: var(--akzent); font-size: 36px; line-height: 1.1; margin-bottom: 28px; }
.content h2 { color: var(--akzent); font-size: 22px; line-height: 1.3; margin: 34px 0 10px; }
.content h3 { font-size: 17px; font-weight: 500; margin: 22px 0 6px; }
.content p { margin: 0 0 12px; }
.content ul { margin: 0 0 14px; padding-left: 22px; }
.content li { margin-bottom: 4px; }
.content address { font-style: normal; margin-bottom: 14px; }
.content a { word-break: break-word; }

/* ==========================================================================
   Tablet
   ========================================================================== */
@media (max-width: 1100px) {
  .container { padding: 0 24px; }
  .site-header .container { padding-left: 24px; }
  .hero { height: 360px; }
  .welcome .container { gap: 28px; }
  .badge { margin-right: 0; }
  .galerie { padding: 40px 24px; }
  .galerie-grid { gap: 20px; }
  .galerie-item { height: 200px; }
  .kontakt-box h2 { font-size: 18px; line-height: 28px; }
  .karte { height: 420px; }
  .karte-aktionen { left: 6%; }
}

/* ==========================================================================
   Smartphone
   ========================================================================== */
@media (max-width: 700px) {
  body { font-size: 16px; }                 /* Fließtext mobil */
  .container { padding: 0 16px; }
  .site-header { height: auto; padding: 18px 0 14px; }
  .site-header .container { flex-direction: column; gap: 6px; padding: 0 16px; }
  .logo-art { width: 180px; }
  .l-linie { padding: 2px 12px 7px 12px; }
  .br-desk { display: none; }
  .slogan { margin: 0; font-size: 16px; white-space: normal; text-align: center; }

  .hero { height: 240px; }
  .hero img { object-position: 46% 40%; }
  .hero-text p { font-size: 27px; }
  .hero-text { bottom: 18px; }
  .hero--sub { height: 170px; }

  .welcome { padding: 40px 0 48px; min-height: 0; }
  .welcome .container { flex-direction: column-reverse; align-items: center; }
  .welcome h1 { font-size: 26px; margin-bottom: 16px; }
  .badge { margin: 0; }
  .badge-ring { width: 170px; height: 170px; padding: 6px; }

  .leistungen { padding: 48px 0 10px; }
  .section-title { font-size: 23px; margin-bottom: 24px; }
  .checklist { grid-template-columns: 1fr; grid-auto-flow: row; grid-template-rows: none; row-gap: 14px; padding-left: 0; }
  .checklist li { font-size: 16px; }

  .text-block { padding-top: 40px; }
  .text-cols { columns: 1; }

  .motto { padding: 40px 0 46px; }
  .motto p { font-size: 25px; line-height: 1.9; }

  .galerie { padding: 32px 16px; }
  .galerie-grid { grid-template-columns: 1fr; gap: 16px; }
  .galerie-item { height: 170px; }

  .kontakt { padding-top: 48px; }
  .kontakt-grid { grid-template-columns: 1fr; gap: 42px; }
  .kontakt-box { min-height: 0; padding: 34px 16px 24px; }
  .kontakt-box h2 { font-size: 19px; line-height: 27px; }

  .cta { padding: 44px 0 36px; }
  .cta a { font-size: 21px; }

  .karte img { object-position: 56% 50%; }
  .karte-quelle { display: block; }
  .karte { height: 340px; }
  .karte-aktionen { left: 16px; right: 16px; top: auto; bottom: 26px; transform: none; align-items: center; width: auto; max-width: none; gap: 8px; }
  .karte-link, .karte-laden { font-size: 18px; white-space: nowrap; }
  .karte-link svg, .karte-laden svg { width: 20px; height: 20px; }
  .karte-info { text-align: center; }

  .site-footer .container { flex-direction: column; justify-content: center; text-align: center; padding: 14px 16px; gap: 8px; }
  .site-footer { font-size: 14px; }
  .page-end { height: 0; }

  .content { padding: 40px 0 52px; }
  .content h1 { font-size: 27px; }
  .content h2 { font-size: 20px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .logo-ring { animation: none; -webkit-mask-image: none; mask-image: none; }
  .js .checklist li, .js .checklist span { opacity: 1; transform: none; animation: none !important; }
  .js .checklist .haken-kreis, .js .checklist .haken-strich { stroke-dashoffset: 0; animation: none !important; }
}
