/* ============================================================
   MB-COMPUTERS — Hinweis zur Speicherung
   Eigene Datei, weil index.html ihre Gestaltung inline trägt und keine
   brand.css einbindet. Sichtbarkeit über transform + visibility (nie
   display), Höhe per ResizeObserver in --cookie-h.
   ============================================================ */

/* Der Hinweis schwebt 16 px über dem Rand: Abstand plus 8 px Luft, damit ein Tab-Ziel nie dahinter landet */
html { scroll-padding-bottom: calc(var(--cookie-h, 0px) + 24px); }
/* Platz unter dem Fuß, solange der Hinweis steht: im Fuß selbst, damit er dessen Farbe trägt
   (als padding am body zeigte er die helle Seitenfarbe als Streifen unter dem dunklen Fuß). */
body.has-cookie .site-footer::after { content: ""; display: block; height: calc(16px + var(--cookie-h, 0px)); }

.mb-hinweis {
  position: fixed;
  left: 16px;
  right: 16px;
  bottom: 16px;
  z-index: 9999;
  max-width: 560px;
  margin: 0 auto;
  background: #fff;
  color: #1A1A1A;
  border: 1px solid rgba(79, 110, 14, 0.14);
  border-radius: 18px;
  box-shadow: 0 18px 48px rgba(16, 22, 8, 0.18);
  padding: 22px 24px;
  font-family: Inter, "Inter Fallback", "Helvetica Neue", Arial, sans-serif;
  font-size: 14px;
  line-height: 1.55;
  transform: translateY(calc(100% + 24px));
  visibility: hidden;
}
.mb-hinweis.is-visible { transform: none; visibility: visible; }
.motion .mb-hinweis { transition: transform .35s ease, visibility 0s linear .35s; }
.motion .mb-hinweis.is-visible { transition: transform .35s ease, visibility 0s; }

.mb-hinweis__titel {
  font-size: 16px;
  font-weight: 700;
  letter-spacing: -0.01em;
  margin: 0 0 8px;
}

.mb-hinweis__text {
  margin: 0 0 18px;
  color: #4A4A4A;
}

.mb-hinweis__text a {
  color: #4F6E0E;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.mb-hinweis__text a:hover { color: #2E4A05; }

.mb-hinweis__knoepfe { display: flex; }

.mb-hinweis__knopf {
  flex: 1 1 0;
  min-width: 0;
  min-height: 44px;
  appearance: none;
  border: 0;
  border-radius: 999px;
  padding: 12px 18px;
  font: inherit;
  font-weight: 600;
  cursor: pointer;
  text-align: center;
  background: linear-gradient(135deg, #2E4A05 0%, #4F6E0E 100%);
  color: #fff;
  box-shadow: 0 6px 18px rgba(87, 128, 16, 0.28);
  transition: transform 140ms ease, box-shadow 140ms ease;
}
@media (hover: hover) {
  .mb-hinweis__knopf:hover { transform: translateY(-1px); }
}
.mb-hinweis__knopf:active { transform: translateY(1px); box-shadow: 0 3px 10px rgba(87, 128, 16, 0.28); }
.mb-hinweis__knopf:focus-visible,
.mb-hinweis__text a:focus-visible {
  outline: 2px solid #2E4A05;
  outline-offset: 2px;
}

/* Fußknopf "Hinweis zur Speicherung": sieht aus wie die Links daneben, das Skript blendet ihn ein */
.fuss-speicher {
  font: inherit;
  color: inherit;
  background: none;
  border: 0;
  padding: 0;
  min-height: 24px;
  cursor: pointer;
}
@media (hover: hover) { .fuss-speicher:hover { text-decoration: underline; } }
.fuss-speicher:active { text-decoration: underline; text-decoration-thickness: 2px; }
/* Gleicher Abstand wie die Fußlinks davor (.footer-bottom a: 20px links, bis 768px 0 und rechts 14px) */
.footer-bottom .fuss-speicher { margin-left: 20px; }
@media (max-width: 768px) { .footer-bottom .fuss-speicher { margin-left: 0; } }

@media (max-width: 480px) {
  .mb-hinweis { padding: 18px 18px; border-radius: 16px; }
}

/* Am Rechner rechts am Rand statt mittig: Formulare stehen mittig, Haken und Absende-Knopf links darin */
@media (min-width: 64em) {
  .mb-hinweis { left: auto; width: 400px; margin: 0; }
}

@media (prefers-reduced-motion: reduce) {
  .mb-hinweis, .mb-hinweis * { transition: none !important; }
  .mb-hinweis__knopf:hover { transform: none; }
}

@media (forced-colors: active) {
  .mb-hinweis { border: 1px solid CanvasText; }
  .mb-hinweis__knopf { border: 1px solid ButtonText; }
  .fuss-speicher { color: LinkText; }
}

@media print {
  .mb-hinweis, .fuss-speicher { display: none !important; }
  body.has-cookie .site-footer::after { display: none !important; }
}
