/* dielebensmittelhelfer.at - ein Stylesheet für alle Seiten */

@font-face { font-family: "Work Sans"; font-weight: 300 700; font-style: normal; font-display: swap; src: url("/fonts/work-sans-normal.woff2") format("woff2"); }
@font-face { font-family: "Work Sans"; font-weight: 400; font-style: italic; font-display: swap; src: url("/fonts/work-sans-italic.woff2") format("woff2"); }
@font-face { font-family: "Bitter"; font-weight: 400 700; font-style: normal; font-display: swap; src: url("/fonts/bitter-variable.woff2") format("woff2"); }

:root {
  --marke: #4e8c00;        /* Grün aus dem Logo */
  --gruen: #3b6d00;        /* Links, Knöpfe - dunkler, damit Text lesbar bleibt */
  --gruen-dunkel: #284a00;
  --gruen-blass: #eef4e2;
  --creme: #faf7ef;
  --erde: #8a5a2b;
  --text: #1d2116;
  --text-2: #4d5443;
  --linie: #e2e3d8;
  --weiss: #fff;
  --rahmen: 1140px;
  --rand: 24px;
  --schrift: "Work Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --titel: "Bitter", Georgia, "Times New Roman", serif;
}

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

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

body {
  margin: 0;
  background: var(--weiss);
  color: var(--text);
  font: 400 17px/1.7 var(--schrift);
  /* Regel 7.11: nie im Wort trennen */
  hyphens: none;
  overflow-wrap: normal;
}

img { max-width: 100%; height: auto; display: block; }

a { color: var(--gruen); text-underline-offset: 2px; }
a:hover { color: var(--gruen-dunkel); }

h1, h2, h3, h4, h5 {
  font-family: var(--titel);
  font-weight: 600;
  line-height: 1.22;
  color: var(--text);
  hyphens: manual;
  margin: 0 0 .6em;
}
h1 { font-size: clamp(1.75rem, 1.3rem + 2.4vw, 2.9rem); letter-spacing: -.01em; }
h2 { font-size: clamp(1.45rem, 1.2rem + 1vw, 1.9rem); }
h3 { font-size: 1.25rem; }
h4, h5 { font-size: 1.08rem; }

p, ul, ol { margin: 0 0 1.1em; }

/* Nackte Adressen als Linktext dürfen umbrechen - eine URL ist kein Wort (Regel 7.11) */
a.url { overflow-wrap: anywhere; }

.rahmen { max-width: var(--rahmen); margin: 0 auto; padding: 0 var(--rand); }

.skip { position: absolute; left: -9999px; }
.skip:focus { left: 16px; top: 16px; z-index: 10; background: var(--weiss); padding: 8px 12px; }

.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------------------------------------------------------------- Kopf */

.kopf { background: var(--weiss); border-bottom: 1px solid var(--linie); }
.kopf-innen { display: flex; align-items: center; justify-content: space-between; gap: 24px; min-height: 78px; }

.marke { display: flex; align-items: center; gap: 12px; text-decoration: none; color: var(--text); }
.zeichen { color: var(--marke); flex: none; }
.marke-text { display: flex; flex-direction: column; line-height: 1.15; }
.marke-name { font: 700 1.05rem/1.1 var(--schrift); letter-spacing: .06em; text-transform: uppercase; color: var(--marke); }
.marke-claim { font-size: .82rem; color: var(--text-2); margin-top: 2px; }

.nav ul { list-style: none; margin: 0; padding: 0; display: flex; gap: 4px; flex-wrap: wrap; }
.nav a {
  display: block; padding: 8px 12px; border-radius: 6px;
  color: var(--text); text-decoration: none; font-weight: 500; font-size: .97rem;
}
.nav a:hover { background: var(--creme); color: var(--gruen); }
.nav a[aria-current="page"] { color: var(--gruen); background: var(--gruen-blass); }

@media (max-width: 900px) {
  .kopf-innen { flex-direction: column; align-items: flex-start; gap: 6px; padding-top: 14px; padding-bottom: 6px; }
  .nav { width: calc(100% + 2 * var(--rand)); margin: 0 calc(-1 * var(--rand)); overflow-x: auto; -webkit-overflow-scrolling: touch; scrollbar-width: none; }
  .nav::-webkit-scrollbar { display: none; }
  .nav ul { flex-wrap: nowrap; padding: 0 calc(var(--rand) - 12px); }
  .nav a { white-space: nowrap; }
}

/* ---------------------------------------------------------------- Artikel */

.artikel { padding: 32px 0 48px; }

.brotkrumen { font-size: .9rem; color: var(--text-2); margin-bottom: 18px; display: flex; flex-wrap: wrap; gap: 6px; }
.brotkrumen a { color: var(--text-2); text-decoration: none; }
.brotkrumen a:hover { color: var(--gruen); text-decoration: underline; }

.artikel-meta { color: var(--text-2); font-size: .92rem; display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 24px; }

.artikel-bild { margin: 0 0 36px; }
.artikel-bild img { width: 100%; border-radius: 10px; aspect-ratio: 16 / 9; object-fit: cover; }

.text > :first-child { margin-top: 0; }
.text h2 { margin-top: 1.8em; padding-top: .2em; }
.text h3 { margin-top: 1.5em; }
.text h4, .text h5 { margin-top: 1.3em; }
.text li { margin-bottom: .4em; }
.text ul, .text ol { padding-left: 1.3em; }
.text blockquote { margin: 1.5em 0; padding: 4px 0 4px 20px; border-left: 4px solid var(--marke); color: var(--text-2); }
.text strong, .text b { font-weight: 600; }
.text figure { margin: 1.8em 0; }
.text figure img, .text > p img { border-radius: 10px; }
.text figcaption { font-size: .88rem; color: var(--text-2); margin-top: 8px; }

/* Ziffer vor der Überschrift (Regel 7.13: die Ziffer ist eine Marke, kein Text) */
.text .nummeriert { display: flex; align-items: baseline; gap: 14px; margin-top: 1.8em; }
.text .nummeriert > h2, .text .nummeriert > h3, .text .nummeriert > h4 { margin-top: 0; padding-top: 0; }
.nummeriert .nr {
  flex: none; display: inline-grid; place-items: center; min-width: 2.1em; height: 2.1em; padding: 0 .4em;
  border-radius: 999px; background: var(--gruen-blass); color: var(--gruen);
  font: 600 1rem/1 var(--titel); transform: translateY(-.15em);
}

/* Inhaltsverzeichnis */
.inhalt { background: var(--creme); border: 1px solid var(--linie); border-radius: 10px; padding: 18px 24px; margin: 1.6em 0 2em; }
.inhalt-titel { font: 600 1.05rem/1.2 var(--titel); margin: 0 0 .6em; }
.inhalt ol { margin: 0; padding-left: 1.3em; columns: 2 320px; column-gap: 40px; }
.inhalt li { margin-bottom: .35em; break-inside: avoid; }
.inhalt a { text-decoration: none; }
.inhalt a:hover { text-decoration: underline; }

/* Tabellen (Regel 7.12, Tabellen-Teil) */
.tabelle { overflow-x: auto; -webkit-overflow-scrolling: touch; margin: 1.4em 0 .4em; border: 1px solid var(--linie); border-radius: 8px; }
.tabelle table { border-collapse: collapse; width: 100%; font-size: .95rem; line-height: 1.5; }
.tabelle th, .tabelle td { padding: 10px 14px; text-align: left; vertical-align: top; border-bottom: 1px solid var(--linie); }
.tabelle thead th, .tabelle tr:first-child th { background: var(--gruen); color: var(--weiss); font-weight: 600; }
.tabelle tbody tr:nth-child(even) { background: var(--creme); }
.tabelle tr:last-child td { border-bottom: 0; }
.tabelle .zahl { text-align: right; white-space: nowrap; }
.tabelle-quelle { font-size: .85rem; color: var(--text-2); margin-top: 0; }

/* Video erst auf Klick */
.video {
  position: relative; aspect-ratio: 16 / 9; margin: 1.8em 0; border-radius: 10px; overflow: hidden;
  background: linear-gradient(135deg, var(--gruen-dunkel), var(--marke)); color: var(--weiss);
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 14px; padding: 24px; text-align: center;
}
.video-titel { font: 600 1.1rem/1.3 var(--titel); max-width: 34em; }
.video-knopf {
  font: 600 1rem/1 var(--schrift); padding: 12px 22px; border-radius: 999px; border: 0; cursor: pointer;
  background: var(--weiss); color: var(--gruen-dunkel);
}
.video-knopf:hover { background: var(--gruen-blass); }
.video-hinweis { font-size: .82rem; opacity: .85; max-width: 34em; }
.video-laeuft { padding: 0; }
.video iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }

/* Häufige Fragen */
.faq { border-top: 1px solid var(--linie); margin-top: 2.4em; }
.faq h3 { font-size: 1.12rem; }

/* Rechtliches */
.legal .text { max-width: none; }

/* ---------------------------------------------------------------- Karten */

.karten { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 28px; }
@media (max-width: 960px) { .karten { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 620px) { .karten { grid-template-columns: 1fr; } }

.karte a {
  display: flex; flex-direction: column; height: 100%;
  background: var(--weiss); border: 1px solid var(--linie); border-radius: 10px; overflow: hidden;
  color: var(--text); text-decoration: none; transition: box-shadow .15s, transform .15s;
}
.karte a:hover { box-shadow: 0 8px 24px rgba(30, 45, 10, .1); transform: translateY(-2px); }
.karte img, .karte-ohne-bild { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; }
.karte-ohne-bild { display: block; background: var(--gruen-blass) url("/img/favicon-32.png") center / 48px no-repeat; }
.karte-text { display: flex; flex-direction: column; gap: 8px; padding: 18px 20px 22px; }
.karte-rubrik { font-size: .78rem; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--gruen); }
.karte-titel { font: 600 1.13rem/1.3 var(--titel); hyphens: manual; }
.karte-anriss { font-size: .93rem; line-height: 1.55; color: var(--text-2); }
.karte a:hover .karte-titel { color: var(--gruen); }

.weiter { background: var(--creme); padding: 48px 0 56px; border-top: 1px solid var(--linie); }
.weiter h2 { margin-bottom: 24px; }
.mehr { margin: 28px 0 0; font-weight: 600; }

/* ---------------------------------------------------------------- Listen */

.liste-kopf { padding-top: 32px; padding-bottom: 8px; }
.vorspann { font-size: 1.1rem; color: var(--text-2); max-width: 46em; }
.werkzeug { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 24px; margin: 8px 0 28px; }
.suche input {
  font: inherit; font-size: 1rem; width: min(360px, 100%); padding: 10px 14px;
  border: 1px solid var(--linie); border-radius: 8px; background: var(--weiss);
}
.suche { flex: 1 1 260px; max-width: 360px; }
.suche input:focus { outline: 2px solid var(--marke); outline-offset: 1px; }
.anzahl { margin: 0; color: var(--text-2); font-size: .95rem; }
.leer { margin-top: 20px; color: var(--text-2); }
.typ-kategorie main, .typ-seite main { padding-bottom: 56px; }

/* ---------------------------------------------------------------- Startseite */

.held { background: var(--creme); border-bottom: 1px solid var(--linie); }
.held-innen {
  display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); gap: 48px; align-items: center;
  padding-top: clamp(40px, 7vw, 88px); padding-bottom: clamp(40px, 7vw, 88px);
}
.held-titel { font-family: var(--titel); font-weight: 600; font-size: clamp(2.1rem, 1.4rem + 2.8vw, 3.3rem); line-height: 1.12; margin: 0 0 .5em; }
.held-titel > * { font-size: inherit; font-weight: inherit; line-height: inherit; letter-spacing: inherit; margin: 0; }
.held-titel .claim { color: var(--marke); }
.held-text { font-size: clamp(1.05rem, 1rem + .3vw, 1.2rem); max-width: 34em; color: var(--text-2); }
.held-bild img { width: 100%; border-radius: 12px; aspect-ratio: 4 / 3; object-fit: cover; }
@media (max-width: 820px) { .held-innen { grid-template-columns: 1fr; gap: 28px; } }

.knoepfe { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }
.knopf {
  display: inline-block; padding: 12px 20px; border-radius: 8px;
  background: var(--gruen); color: var(--weiss); text-decoration: none; font-weight: 600;
}
.knopf:hover { background: var(--gruen-dunkel); color: var(--weiss); }
.knopf-hell { background: var(--weiss); color: var(--gruen); border: 1px solid var(--gruen); }
.knopf-hell:hover { background: var(--gruen-blass); color: var(--gruen-dunkel); }

.abschnitt { padding: clamp(48px, 7vw, 80px) 0; }
.abschnitt-getoent { background: var(--creme); border-top: 1px solid var(--linie); border-bottom: 1px solid var(--linie); }
.dachzeile { font-size: .85rem; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--erde); margin-bottom: .5em; }
.abschnitt h2 { margin-bottom: .7em; }
.abschnitt-kopf { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: end; gap: 8px 24px; margin-bottom: 28px; }
.abschnitt-kopf h2 { margin: 0; }
.abschnitt-kopf .mehr { margin: 0; }

.zweispaltig { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 48px; align-items: center; }
.zweispaltig img { border-radius: 12px; width: 100%; aspect-ratio: 3 / 2; object-fit: cover; }
@media (max-width: 760px) { .zweispaltig { grid-template-columns: 1fr; gap: 28px; } }

.empfehlung {
  display: flex; flex-wrap: wrap; align-items: center; gap: 16px 28px;
  padding: 22px 26px; border: 1px solid var(--linie); border-radius: 10px; background: var(--weiss);
}
.empfehlung img { width: 180px; height: auto; }
.empfehlung p { margin: 0; }

/* ---------------------------------------------------------------- Fuß */

.fuss { background: #1f2a14; color: #d3d9c8; padding: 44px 0 36px; font-size: .95rem; }
.fuss-innen { display: grid; grid-template-columns: 1.1fr 2.2fr 1fr; gap: 28px; }
.fuss .marke-name { color: #a6d65a; display: block; }
.fuss .marke-claim { color: #a9b29c; }
.fuss ul { list-style: none; margin: 0; padding: 0; }
.fuss-nav ul { columns: 2; column-gap: 28px; }
.fuss li { margin-bottom: 6px; break-inside: avoid; }
.fuss a { color: #d3d9c8; text-decoration: none; }
.fuss a:hover { color: var(--weiss); text-decoration: underline; }
.fuss-zeile { grid-column: 1 / -1; margin: 12px 0 0; padding-top: 20px; border-top: 1px solid #36442a; font-size: .85rem; color: #a9b29c; }
@media (max-width: 760px) { .fuss-innen { grid-template-columns: 1fr; } .fuss-nav ul { columns: 1; } }
