/* Lokale Schriften: keine Verbindung zu einem externen Schriftdienst. */
@font-face {
  font-family: "Antic Didone";
  src: url("fonts/Antic Didone/AnticDidone-Regular.ttf") format("truetype");
  font-style: normal;
  font-weight: 400;
  font-display: swap;
}

@font-face {
  font-family: "Montserrat";
  src: url("fonts/Montserrat/Montserrat-VariableFont_wght.ttf")
    format("truetype");
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
}

@font-face {
  font-family: "Montserrat";
  src: url("fonts/Montserrat/Montserrat-Italic-VariableFont_wght.ttf")
    format("truetype");
  font-style: italic;
  font-weight: 100 900;
  font-display: swap;
}

/* Vorläufige Palette – gemeinsam austauschbar. */
:root {
  color-scheme: light;
  --page: #ebe9e5;
  --surface: #d8e3d0;
  --rose: #eacfc5;
  --text: #343c38;
  --line: #c6cdc3;
  --accent: #cad9c1;
  --focus: #54654d;
  --font-heading: "Antic Didone", Georgia, serif;
  --font-body: "Montserrat", Arial, sans-serif;
}

:root[data-theme="dark"] {
  color-scheme: dark;
  --page: #2e3733;
  --surface: #414f46;
  --rose: #584945;
  --text: #f1ece3;
  --line: #66746b;
  --accent: #506354;
  --focus: #c4d8b8;
}

* {
  box-sizing: border-box;
}
body {
  margin: 0;
  background: var(--page);
  color: var(--text);
  font-family: var(--font-body);
  line-height: 1.6;
}
a {
  color: inherit;
  text-decoration-thickness: 1px;
  text-decoration-color: var(--line);
  text-underline-offset: .25em;
  text-decoration-skip-ink: auto;
}
@media (hover: hover) and (pointer: fine) {
  a:hover { text-decoration-color: currentColor; }
}
button {
  font: inherit;
  color: inherit;
  cursor: pointer;
}
[hidden] {
  display: none !important;
}
:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 5px;
}
.skip-link {
  position: absolute;
  left: 1rem;
  top: -6rem;
  padding: 0.75rem;
  background: var(--page);
  z-index: 10;
}
.skip-link:focus {
  top: 1rem;
}

/* Basis: schmale Bildschirme. Navigation öffnet unter der Kopfzeile. */
.site-header {
  border-bottom: 1px solid var(--line);
}
.header-inner {
  max-width: 75rem;
  margin-inline: auto;
  padding: 1rem;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.75rem;
}
.brand {
  font-family: var(--font-heading);
  font-size: clamp(1.35rem, 5vw, 2rem);
  text-decoration: none;
  letter-spacing: 0;
}
.header-actions {
  display: flex;
  gap: 0.25rem;
  margin-left: auto;
}
.theme-toggle,
.menu-toggle {
  width: 44px;
  height: 44px;
  border: 1px solid transparent;
  border-radius: 50%;
  background: transparent;
  display: grid;
  place-items: center;
}
.theme-toggle {
  font-size: 1.65rem;
}
@media (hover: hover) and (pointer: fine) {
  .menu-toggle:hover { background: var(--accent); }
}
.theme-toggle.is-feedback { background: var(--accent); }
.theme-toggle:focus:not(:focus-visible) { outline: none; }
.menu-toggle {
  position: relative;
}
.menu-toggle span {
  position: absolute;
  width: 22px;
  height: 2px;
  border-radius: 2px;
  background: currentColor;
  transition:
    transform 0.25s ease,
    opacity 0.2s ease;
}
.menu-toggle span:nth-child(1) {
  transform: translateY(-7px);
}
.menu-toggle span:nth-child(3) {
  transform: translateY(7px);
}
.menu-toggle[aria-expanded="true"] span:nth-child(1) {
  transform: rotate(45deg);
}
.menu-toggle[aria-expanded="true"] span:nth-child(2) {
  opacity: 0;
}
.menu-toggle[aria-expanded="true"] span:nth-child(3) {
  transform: rotate(-45deg);
}
.site-nav {
  flex-basis: 100%;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  padding: 0.5rem;
  background: var(--surface);
  border-radius: 0.5rem;
}
.site-nav a {
  padding: 0.75rem 1rem;
  text-decoration: none;
  border-radius: 0.35rem;
}
.site-nav a:hover {
  background: var(--accent);
}

/* Nur eine lesbare Grundlage für die noch nicht gestalteten Inhalte. */
main,
footer {
  max-width: 75rem;
  margin-inline: auto;
  padding: 2rem 1rem;
}
h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--font-heading);
  line-height: 1.2;
  font-weight: 400;
}
h1 {
  font-size: clamp(2.25rem, 7vw, 4rem);
}
section {
  margin-top: 4rem;
  scroll-margin-top: 2rem;
}

/* Einstieg: mobil untereinander, auf großen Bildschirmen nebeneinander. */
.hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 2rem;
  margin-top: 0;
  align-items: center;
}
.hero-copy {
  min-width: 0;
  padding-block: 1rem;
}
.hero-eyebrow {
  font-size: 0.9rem;
  letter-spacing: 0.12em;
  margin: 0 0 1.25rem;
}
.hero h1 {
  margin: 0 0 1.5rem;
  font-size: clamp(2.15rem, 5.4vw, 4.25rem);
  line-height: 1.12;
  overflow-wrap: break-word;
}
.hero-description {
  max-width: 42ch;
  margin: 0;
  line-height: 1.8;
}
.hero-link {
  display: inline-flex;
  align-items: center;
  gap: 1rem;
  min-height: 44px;
  padding: 0.7rem 1.2rem;
  margin-top: 1.75rem;
  border-radius: 0.35rem;
  background: var(--surface);
  text-decoration: none;
}
.hero-link:hover {
  background: var(--accent);
}
.hero-image {
  overflow: hidden;
  border-radius: 0.5rem;
  background: var(--surface);
}
.hero-image img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  object-position: 60% 55%;
}
/* Artikelvorschauen: gleich hohe Karten, mobil zuerst untereinander. */
.blog-heading {
  margin-bottom: 2rem;
}
.blog-heading h2 {
  font-size: clamp(1.9rem, 4vw, 2.8rem);
  margin: 0 0 1rem;
}
.blog-heading > p:last-child {
  margin: 0;
}
.article-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  grid-auto-rows: 1fr;
  gap: 1.5rem;
}
.article-card {
  min-width: 0;
  overflow: hidden;
  overflow-wrap: anywhere;
  border-radius: 0.5rem;
  background: var(--surface);
}
.article-card--rose {
  background: var(--rose);
}
.article-image {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  object-position: center top;
}
.article-copy {
  padding: clamp(1.25rem, 3vw, 2rem);
}
.article-category {
  font-size: 0.75rem;
  letter-spacing: 0.06em;
  margin: 0 0 1rem;
}
.article-copy h3 {
  font-size: clamp(1.75rem, 3vw, 2.25rem);
  margin: 0 0 1rem;
}
.article-copy > p:last-child {
  margin: 0;
  line-height: 1.8;
}
#ueber-mich {
  padding: clamp(1.25rem, 4vw, 2.5rem);
  border-radius: 0.5rem;
  border: 1px solid var(--line);
}
#ueber-mich h2 {
  margin-top: 0;
}
#ueber-mich > p:last-child {
  margin-bottom: 0;
}
footer {
  border-top: 1px solid var(--line);
}

/* Erst mit ausreichend Platz erscheinen die Links neben dem Schriftzug. */
@media (min-width: 48rem) {
  .hero {
    grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr);
    gap: clamp(2rem, 5vw, 4rem);
  }
  .hero-image img {
    aspect-ratio: 4 / 5;
    object-position: center;
  }
  .article-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .header-inner {
    padding: 1.25rem 2rem;
    flex-wrap: nowrap;
  }
  .header-actions {
    order: 3;
    margin-left: 0;
  }
  .menu-toggle {
    display: none;
  }
  .site-nav {
    flex-basis: auto;
    flex-direction: row;
    margin-left: auto;
    padding: 0;
    background: transparent;
  }
  main,
  footer {
    padding-inline: 2rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .menu-toggle span {
    transition: none;
  }
}

/* Artikelseite: schmale Textspalte für lange, angenehm lesbare Absätze. */
.article-title-link { text-decoration: none; }
/* Ein echter Link erstreckt sich über die gesamte Karte. */
.article-card--linked { position: relative; transition: transform .2s ease, box-shadow .2s ease; }
.article-title-link::after { content: ""; position: absolute; inset: 0; border-radius: .5rem; }
.article-card--linked:focus-within { outline: 1px solid var(--line); outline-offset: 3px; }
.article-title-link:focus-visible { outline: none; } /* Der Fokusrahmen liegt auf der gesamten Karte. */
.article-read-more { display: inline-block; margin-top: 1.25rem; font-size: .9rem; font-weight: 500; }
@media (hover: hover) and (pointer: fine) {
  .article-card--linked:hover { transform: translateY(-3px); box-shadow: 0 8px 20px rgb(0 0 0 / .14); }
}
@media (prefers-reduced-motion: reduce) {
  .article-card--linked { transition: none; }
  .article-card--linked:hover { transform: none; }
}
.reading-page { max-width: 64rem; }
.back-link { display: inline-flex; align-items: center; min-height: 44px; text-underline-offset: .25em; }
.reading-header { max-width: 48rem; margin: 2rem auto; }
.reading-header h1 { overflow-wrap: anywhere; margin: 0 0 1.5rem; }
.reading-lead { font-size: 1.1rem; line-height: 1.8; }
.reading-image { display: block; width: 100%; height: auto; aspect-ratio: 4 / 3; object-fit: cover; object-position: center top; border-radius: .5rem; }
.reading-body { max-width: 65ch; margin: 2rem auto; line-height: 1.85; }
.reading-body h2 { font-size: clamp(1.8rem, 4vw, 2.5rem); }
.draft-note { padding: 1rem 1.25rem; background: var(--rose); border-radius: .35rem; font-size: .9rem; }
.article-toc {
  width: 100%;
  max-width: 34rem;
  margin: 2rem auto;
  padding: 1.25rem clamp(1.25rem, 3vw, 1.75rem);
  background: var(--surface);
  border-radius: .5rem;
}
.article-toc h2 { margin: 0 0 .75rem; font-size: clamp(1.9rem, 3vw, 2.25rem); }
.article-toc ol {
  margin: 0;
  padding-left: 1.6rem;
  font-size: clamp(1.1rem, 2vw, 1.25rem);
  line-height: 1.5;
}
.article-toc li { padding-left: .25rem; }
.article-toc a {
  display: block;
  padding-block: .55rem;
  min-height: 44px;
  overflow-wrap: anywhere;
  text-decoration-thickness: 1px;
  text-decoration-color: var(--line);
  text-underline-offset: .25em;
}
.article-toc a:hover { text-decoration-color: currentColor; }
.reading-body blockquote { margin: 2rem 0; border-left: 3px solid var(--focus); padding: 1rem 1.25rem; background: var(--surface); }

/* Vorschau-Abschluss und Quellen */
.site-footer { display: grid; gap: 1rem; margin-top: 4rem; padding-block: 2.5rem 1.5rem; }
.site-footer p { margin: .75rem 0 0; }
.footer-intro p { line-height: 1.8; }
.footer-links { flex-wrap: wrap; gap: .25rem 1.75rem; }
.site-footer nav { display: flex; }
.site-footer nav a {
  position: relative;
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  width: fit-content;
  text-decoration: none;
}
.site-footer nav a::after {
  content: "";
  position: absolute;
  bottom: .35rem;
  left: 0;
  right: 0;
  height: 1px;
  background: var(--line);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform .25s ease;
}
@media (hover: hover) and (pointer: fine) {
  .site-footer nav a:hover::after { transform: scaleX(1); }
}
@media (prefers-reduced-motion: reduce) {
  .site-footer nav a::after { transition: none; }
}
.preview-label { font-size: .85rem; line-height: 1.7; }
.health-note { padding: 1.25rem; border-left: 1px solid var(--line); background: var(--surface); border-radius: .35rem; }
.reading-list, .source-list { padding-left: 1.4rem; }
.reading-list li, .source-list li { margin-block: .65rem; }
.reading-body a { overflow-wrap: anywhere; text-decoration-thickness: 1px; text-underline-offset: .25em; }
.review-details { margin-block: 1.5rem; padding: 1rem 1.25rem; border: 1px solid var(--line); border-radius: .5rem; }
.review-details summary { cursor: pointer; padding-block: .35rem; }
.article-copy { display: flex; flex-direction: column; flex: 1; }
.article-copy > p:not(.article-category) { margin: 0; line-height: 1.8; }
.article-card { display: flex; flex-direction: column; }
.article-read-more { margin-top: auto; padding-top: 1.25rem; }
.article-image { flex-shrink: 0; }
.reading-body blockquote { border-left-width: 1px; border-left-color: var(--line); }
@media (min-width: 48rem) {
  .footer-intro { display: flex; align-items: baseline; flex-wrap: wrap; gap: .5rem 1.5rem; }
  .site-footer .footer-intro p { margin: 0; }
}

/* Native blaue Tipp-Markierung auf mobilen Browsern ersetzen. */
a, button, summary {
  -webkit-tap-highlight-color: transparent;
}

/* Mobiler Menüvorhang: rechts hinein, rechts hinaus. */
.menu-backdrop { display: none; }
@media (max-width: 47.999rem) {
  .nav-enhanced .site-header { position: sticky; top: 0; z-index: 30; background: var(--page); }
  .nav-enhanced .header-inner { flex-wrap: nowrap; }
  .nav-enhanced .site-nav {
    position: fixed;
    top: var(--header-height, 77px);
    right: 0;
    bottom: 0;
    width: min(88vw, 24rem);
    background: color-mix(in srgb, var(--surface) 94%, transparent);
    -webkit-backdrop-filter: blur(8px);
    backdrop-filter: blur(8px);
    height: calc(100dvh - var(--header-height, 77px));
    margin: 0;
    padding: 2rem 1.5rem;
    padding-bottom: max(2rem, env(safe-area-inset-bottom));
    border-radius: 0;
    border-left: 1px solid var(--line);
    z-index: 32;
    overflow-y: auto;
    overscroll-behavior: contain;
    transform: translateX(100%);
    visibility: hidden;
    pointer-events: none;
    transition: transform .42s cubic-bezier(.22, .8, .25, 1), visibility 0s linear .42s;
  }
  .nav-enhanced .site-nav a {
    font-family: var(--font-heading);
    font-size: clamp(1.8rem, 7vw, 2.4rem);
    padding: .9rem .5rem;
    border-radius: 0;
    border-bottom: 1px solid var(--line);
  }
  .nav-enhanced .menu-backdrop {
    display: block;
    position: fixed;
    inset: var(--header-height, 77px) 0 0;
    background: rgb(20 29 24 / .3);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    z-index: 31;
    transition: opacity .42s ease, visibility 0s linear .42s;
  }
  .menu-open { overflow: hidden; }
  .menu-open body { overflow: hidden; }
  .menu-open .site-nav { transform: translateX(0); visibility: visible; pointer-events: auto; transition-delay: 0s; }
  .menu-open .menu-backdrop { opacity: 1; visibility: visible; pointer-events: auto; transition-delay: 0s; }
  .nav-enhanced section { scroll-margin-top: calc(var(--header-height, 77px) + 1rem); }
}
@media (prefers-reduced-motion: reduce) {
  .nav-enhanced .site-nav, .nav-enhanced .menu-backdrop { transition: none; }
}

/* Mobil: klar erkennbares Halbkreis-Symbol statt eines kleinen Schriftzeichens. */
@media (max-width: 47.999rem) {
  .theme-toggle { width: 48px; height: 48px; flex-shrink: 0; }
  .theme-toggle span {
    display: block;
    width: 24px;
    height: 24px;
    font-size: 0;
    border: 1.5px solid currentColor;
    border-radius: 50%;
    background: linear-gradient(to right, currentColor 50%, transparent 50%);
  }
}
/* Kontakt: lesbare Adresse und gut erreichbarer E-Mail-Link. */
.contact-content h1 { font-size: clamp(2.4rem, 6vw, 3.8rem); }
.contact-card { padding: clamp(1.25rem, 4vw, 2rem); margin-block: 2rem; background: var(--surface); border-radius: .5rem; }
.contact-card h2 { margin-top: 0; }
.contact-email { display: inline-block; padding-block: .5rem; min-height: 44px; font-size: clamp(1rem, 3vw, 1.3rem); overflow-wrap: anywhere; }
.contact-card p { margin-bottom: 0; font-size: .9rem; }
