/* Ocelos AI — Startseite
   Hell-minimalistisch. Markenfarben laut brand/VERWENDUNG.txt:
   Weiss #FFFFFF, Orange #F3A03E, Schwarz #000000.
   Keine externen Ressourcen (CSP default-src 'self'), Systemschriften. */

:root {
  --grund:        #faf9f7;  /* heller, leicht warmer Grundton */
  --flaeche:      #f2efe9;  /* dezent abgesetzte Flaeche */
  --weiss:        #ffffff;
  --text:         #141414;  /* dunkle, sehr gut lesbare Schrift */
  --text-leise:   #4a463f;
  --linie:        #ddd8cf;
  --akzent:       #f3a03e;  /* Markenorange, sparsam */
  --schwarz:      #000000;
  --breite:       68rem;
  --breite-schmal: 44rem;
}

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

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--grund);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
               "Helvetica Neue", Arial, "Noto Sans", sans-serif;
  font-size: 1.0625rem;
  line-height: 1.65;
  text-rendering: optimizeLegibility;
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}

/* ---------- Grundelemente ---------- */

h1, h2, h3 {
  line-height: 1.2;
  font-weight: 600;
  letter-spacing: -0.01em;
  margin: 0 0 0.6em;
}

h1 { font-size: 2rem; letter-spacing: -0.02em; }
h2 { font-size: 1.5rem; }
h3 { font-size: 1.125rem; }

p { margin: 0 0 1.1em; }
p:last-child { margin-bottom: 0; }

a { color: var(--text); text-decoration: underline; text-underline-offset: 0.18em; }
a:hover { text-decoration-thickness: 2px; }

a:focus-visible,
.cta:focus-visible {
  outline: 3px solid var(--schwarz);
  outline-offset: 3px;
}

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

.wrap {
  width: 100%;
  max-width: var(--breite);
  margin: 0 auto;
  padding: 0 1.25rem;
}

.wrap-narrow { max-width: var(--breite-schmal); }

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--weiss);
  color: var(--text);
  padding: 0.75rem 1rem;
  z-index: 10;
}
.skip-link:focus {
  left: 0;
}

/* ---------- Kopfzeile ---------- */

.site-header {
  background: var(--weiss);
  border-bottom: 1px solid var(--linie);
}

.header-inner {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  align-items: flex-start;
  padding-top: 1rem;
  padding-bottom: 1rem;
}

/* Mobil (Standard, mobile-first): Das Logo fuellt die Inhaltsbreite der Kopfzeile
   aus. Der Rand ist damit automatisch symmetrisch -- links wie rechts genau das
   .wrap-Padding. Seitenverhaeltnis bleibt durch height:auto erhalten (O19). */
.logo {
  display: block;
  line-height: 0;
  width: 100%;
  max-width: 30rem;      /* Deckel fuer die seltene Zone 480-639 px; auf realen
                            Smartphones (<=430 px) greift er nie. */
  margin-inline: auto;   /* bleibt auch mit Deckel exakt mittig. */
}
.logo img { width: 100%; max-width: 100%; height: auto; }

.site-nav ul {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem 1.25rem;
  margin: 0;
  padding: 0;
}

.site-nav a {
  text-decoration: none;
  color: var(--text-leise);
  font-size: 0.9375rem;
  padding: 0.15rem 0;
  border-bottom: 2px solid transparent;
}
.site-nav a:hover { color: var(--text); border-bottom-color: var(--akzent); }

/* ---------- Abschnitte ---------- */

section { padding: 3.25rem 0; }

.band { background: var(--flaeche); }
.band + .band { border-top: 1px solid var(--linie); }

.hero {
  background: var(--weiss);
  padding: 3.5rem 0 3.75rem;
  border-bottom: 1px solid var(--linie);
}

.hero h1 { max-width: 22ch; }

.hero .lead { max-width: 60ch; }

.lead {
  font-size: 1.125rem;
  color: var(--text-leise);
}

.hero h1::after {
  content: "";
  display: block;
  width: 3.5rem;
  height: 3px;
  background: var(--akzent);
  margin-top: 1.1rem;
}

.cta-row { margin-top: 1.75rem; }

.cta {
  display: inline-block;
  background: var(--akzent);
  color: var(--schwarz);
  text-decoration: none;
  font-weight: 600;
  padding: 0.8rem 1.5rem;
  border: 2px solid var(--akzent);
  border-radius: 2px;
}
.cta:hover {
  background: var(--schwarz);
  border-color: var(--schwarz);
  color: var(--weiss);
}

/* ---------- Raster ---------- */

.grid {
  display: grid;
  gap: 1.75rem;
}

.grid article h3 { margin-bottom: 0.35em; }
.grid article p { color: var(--text-leise); }

/* ---------- Vorgehensweise ---------- */

.steps {
  list-style: none;
  counter-reset: schritt;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 1.75rem;
}

.steps > li {
  counter-increment: schritt;
  padding-left: 3rem;
  position: relative;
}

.steps > li::before {
  content: counter(schritt);
  position: absolute;
  left: 0;
  top: 0.1rem;
  width: 2rem;
  height: 2rem;
  border: 2px solid var(--akzent);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text);
}

.steps h3 { margin-bottom: 0.3em; }
.steps p { color: var(--text-leise); }

/* ---------- Kontakt ---------- */

.band-contact .question {
  font-size: 1.25rem;
  font-weight: 600;
  max-width: 34ch;
}

/* Kontakt-Person: kleines rundes Portrait neben Name, Rolle und E-Mail.
   Bewusst klein gehalten (96 px) — es zeigt, wer hinter der Seite steht,
   ohne die Seite von "Unternehmen" auf "Einzelperson" umzustellen. */
.kontakt-person {
  margin-top: 1.75rem;
  display: flex;
  align-items: center;
  gap: 1.125rem;
}

.kontakt-person .portrait {
  width: 96px;
  height: 96px;
  flex: 0 0 auto;
  border-radius: 50%;
  object-fit: cover;
  border: 1px solid var(--linie);
}

.portrait-link {
  display: block;
  border-radius: 50%;
  line-height: 0;
  cursor: zoom-in;   /* macht erkennbar, dass sich das Bild oeffnen laesst */
}
.portrait-link:focus-visible {
  outline: 2px solid var(--akzent);
  outline-offset: 3px;
}

/* Vergroesserte Ansicht. Das native <dialog> bringt Hintergrund, ESC und
   Fokusfalle mit; hier wird nur das Aussehen gesetzt. */
.portrait-dialog {
  border: 0;
  border-radius: 10px;
  padding: 0;
  background: var(--weiss);
  max-width: min(88vw, 480px);
  max-height: 92vh;
  overflow: auto;
}
.portrait-dialog::backdrop {
  background: rgba(0, 0, 0, 0.72);
}
.portrait-dialog figure { margin: 0; }
.portrait-dialog img {
  width: 100%;
  height: auto;
  border-radius: 10px 10px 0 0;
}
.portrait-dialog figcaption {
  padding: 0.875rem 1.125rem 1rem;
  color: var(--text-leise);
  font-size: 0.9375rem;
}
.portrait-schliessen {
  position: absolute;
  top: 0.5rem;
  right: 0.5rem;
  width: 2.25rem;
  height: 2.25rem;
  border: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.86);
  color: var(--text);
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.25);
}
.portrait-schliessen:hover { background: var(--weiss); }
.portrait-schliessen:focus-visible {
  outline: 2px solid var(--akzent);
  outline-offset: 2px;
}

.kontakt-person-text > p { margin: 0; }

.person-name {
  font-weight: 600;
  line-height: 1.3;
}

.person-rolle {
  color: var(--text-leise);
  font-size: 0.9375rem;
  line-height: 1.4;
}

.mail {
  margin-top: 1.5rem;
  font-size: 1.125rem;
}
.kontakt-person .mail { margin-top: 0.375rem; }
.mail a { font-weight: 600; }

/* ---------- Kontaktformular ---------- */

.kontaktformular {
  margin-top: 2.5rem;
  max-width: 38rem;
}

.kontaktformular .form-intro {
  margin: 0 0 1.75rem;
  color: var(--text-leise);
}

.kontaktformular .feld {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  margin-bottom: 1.25rem;
}

.kontaktformular label {
  font-weight: 600;
  font-size: 0.95rem;
}

.kontaktformular .pflicht { color: var(--akzent); }

.kontaktformular input[type="text"],
.kontaktformular input[type="email"],
.kontaktformular textarea {
  font: inherit;
  color: var(--text);
  background: var(--weiss);
  border: 1px solid var(--linie);
  border-radius: 4px;
  padding: 0.7rem 0.85rem;
  width: 100%;
}

.kontaktformular textarea {
  resize: vertical;
  min-height: 9rem;
  line-height: 1.5;
}

.kontaktformular input:focus-visible,
.kontaktformular textarea:focus-visible {
  outline: 3px solid var(--akzent);
  outline-offset: 2px;
  border-color: var(--akzent);
}

/* Zustimmung: Kaestchen und Text nebeneinander, Text umbricht sauber. */
.kontaktformular .feld-zustimmung {
  flex-direction: row;
  align-items: flex-start;
  gap: 0.7rem;
  margin-top: 1.75rem;
}

.kontaktformular .feld-zustimmung input {
  margin-top: 0.25rem;
  width: 1.1rem;
  height: 1.1rem;
  flex: 0 0 auto;
  accent-color: var(--akzent);
}

.kontaktformular .feld-zustimmung label {
  font-weight: 400;
  font-size: 0.95rem;
  line-height: 1.55;
}

.kontaktformular .form-hinweis {
  margin-top: 1.25rem;
  font-size: 0.85rem;
  color: var(--text-leise);
}

.kontaktformular .form-aktion { margin-top: 1.5rem; }

.kontaktformular button.cta {
  border: 0;
  cursor: pointer;
  font: inherit;
}

/* Honigtopf: fuer Menschen unsichtbar, fuer Bots ausfuellbar. Bewusst NICHT
   display:none - manche Bots ueberspringen genau das. */
.honigtopf {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

/* ---------- Fusszeile ---------- */

.site-footer {
  background: var(--weiss);
  border-top: 1px solid var(--linie);
  padding: 2.25rem 0;
  font-size: 0.9375rem;
  color: var(--text-leise);
}

.footer-inner {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.footer-brand strong { color: var(--text); }
.footer-legal { color: var(--text-leise); }

/* ---------- Ab Tablet ---------- */

@media (min-width: 40em) {
  body { font-size: 1.125rem; }
  h1 { font-size: 2.75rem; }
  h2 { font-size: 1.875rem; }
  section { padding: 4.5rem 0; }
  .hero { padding: 5rem 0 5.5rem; }
  .lead { font-size: 1.1875rem; }
  .grid-2 { grid-template-columns: 1fr 1fr; gap: 2.25rem 3rem; }
  .steps { grid-template-columns: 1fr 1fr; gap: 2.25rem 3rem; }

  /* Auftrag Mario 2026-09-10 (Eingangskorb): Die vier Navigationspunkte sollen auf
     Laptop/Desktop fast die Hoehe des Hauptlogos erreichen. Der Logo-Schriftzug ist
     bei 380 px Logobreite ca. 46 px hoch; die Nav-Schrift waechst deshalb fluid bis
     2.875rem (46 px, sichtbare Buchstabenhoehe ca. 35-40 px). In dieser Groesse passt
     die Navigation nicht mehr neben das Logo -- sie steht als eigene Zeile darunter. */
  .header-inner {
    align-items: flex-start;
    gap: 2rem; /* 3.5rem -> 2rem: die Markenanimation steht seit 2026-09-12 im Fluss
                  und bringt ihre Hoehe selbst mit (vorher Reserve fuer ein absolut
                  positioniertes Element) */
  }
  /* Ab Tablet steht das Logo wieder als eigenstaendiges Element,
     deshalb width:auto (sonst wuerde es als Flex-Element die Zeile fuellen).
     340px -> 380px: die von Mario am 2026-09-04 freigegebene minimale
     Vergroesserung fuer Laptop/Desktop (O19). */
  .logo { width: auto; max-width: none; margin-inline: 0; }
  .logo img { width: 380px; }

  .site-nav ul { gap: 0.5rem 1.5rem; }
  .site-nav a {
    font-size: clamp(1.125rem, 1.8vw, 1.5rem);
    font-weight: 600;
    line-height: 1.2;
    padding: 0.1em 0;
    border-bottom-width: 3px;
  }

  .footer-inner {
    flex-direction: row;
    justify-content: space-between;
    align-items: flex-end;
    gap: 2rem;
  }
  .footer-legal { text-align: right; }
}

@media (min-width: 64em) {
  h1 { font-size: 3.25rem; }
  .wrap { padding: 0 2rem; }
  .steps { grid-template-columns: repeat(4, 1fr); gap: 2.5rem 2rem; }
}

@media print {
  .site-nav, .cta-row { display: none; }
  body { background: #fff; }
}

/* ---------- Rechtstexte (Impressum, Datenschutz, 404) ----------
   Der frueher hier vorangestellte TEMP-HINWEIS-Block (.hinweis) wurde am 2026-09-07
   auf Marios Anweisung ersatzlos entfernt — zusammen mit dem <aside class="hinweis">
   in index.html (O15 geschlossen, siehe docs/DECISIONS.md).
   Keine neuen Farben, keine neuen Schriften — nur Rhythmus fuer Fliesstext. */

.legal-head {
  background: var(--weiss);
  border-bottom: 1px solid var(--linie);
  padding: 2.75rem 0 3rem;
}

.legal-head h1::after {
  content: "";
  display: block;
  width: 3.5rem;
  height: 3px;
  background: var(--akzent);
  margin-top: 1.1rem;
}

.legal-head .lead { max-width: 60ch; }

.legal h2 {
  font-size: 1.25rem;
  margin-top: 2.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--linie);
}

.legal h2:first-child {
  margin-top: 0;
  padding-top: 0;
  border-top: 0;
}

.legal p, .legal li { color: var(--text-leise); }
.legal strong { color: var(--text); }

.legal ul {
  margin: 0 0 1.1em;
  padding-left: 1.25rem;
}
.legal li { margin-bottom: 0.4em; }

.anschrift {
  line-height: 1.55;
  color: var(--text) !important;
}

.legal .daten { margin: 0 0 1.1em; }
/* Widerspruchsrecht gesondert hervorgehoben (Art. 21 Abs. 4 DSGVO, 2026-09-24, B7) */
.legal .widerspruch {
  border-left: 3px solid #F3A03E;
  padding: 0.6em 0 0.6em 1em;
  margin: 1.2em 0;
}
.legal .widerspruch strong { display: block; margin-bottom: 0.3em; }
.legal .daten dt { font-weight: 600; color: var(--text); margin-top: 0.9em; }
.legal .daten dd { margin: 0.15em 0 0; color: var(--text-leise); }

@media (min-width: 40em) {
  .legal-head { padding: 4rem 0 4.25rem; }
  .legal h2 { font-size: 1.375rem; }
}

/* ---------- KI-Visualisierungen (Aufgabe 1, 2026-09-04) ----------
   Drei statische, KI-generierte Bilder mit eingebetteter EU-Kennzeichnung.
   Bewusst ohne JavaScript (CSP script-src 'self', keine Abhaengigkeiten).
   Ausgeliefert wird WebP mit PNG-Rueckfall; AVIF liegt zwar unter
   assets/visuals/, ist im HTML aber NICHT verlinkt, weil nginx 1.18 den Typ
   image/avif nicht kennt (siehe docs/OFFENE-PUNKTE.md, O20).
   Austausch gegen WebM/MP4 spaeter: <picture> im <figure class="visual">
   durch <video> ersetzen, Rahmen/Abstaende bleiben unveraendert. */

.visual { margin: 0; }

.visual img {
  width: 100%;
  height: auto;
  object-fit: contain;
  border: 1px solid var(--linie);
  border-radius: 3px;
}

/* Bild 2 und 3 schliessen ihren Abschnitt ab — Luft zum Raster darueber. */
#leistungen .visual,
#grundsaetze .visual { margin-top: 2.75rem; }

/* Die mobile Zusatz-Kennzeichnung (figcaption.ki-hinweis) wurde am 2026-09-04
   auf Marios Anweisung entfernt — sie doppelte auf dem Telefon den bereits in
   das Bild eingebrannten Hinweis. Die Kennzeichnung traegt jetzt allein das
   Bild selbst (EU-Symbol + Text, eingebrannt) sowie der alt-Text fuer
   Screenreader. Begruendung und Rechtsbefund: docs/DECISIONS.md. */

@media (min-width: 40em) {
  #leistungen .visual,
  #grundsaetze .visual { margin-top: 3.25rem; }
}

/* Sehr dezente Einblendung beim Eintritt in den sichtbaren Bereich.
   Rein deklarativ; Browser ohne Scroll-Timeline zeigen das Bild direkt. */
@media (prefers-reduced-motion: no-preference) {
  @supports (animation-timeline: view()) {
    .visual {
      animation: visual-einblenden linear both;
      animation-timeline: view();
      animation-range: entry 10% entry 55%;
    }
  }
}

@keyframes visual-einblenden {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: none; }
}
