/* Farbsystem PartPilot (docs/bauplan-admin-portal.md 6.6, docs/marke.md). Struktur wie im autoparts-agent:
   kuehle Grauskala, die Marke nur als Akzent (Hauptknopf, Fokus, Unterstrich), Statusfarben immer mit Wort.
   Hier stehen nur Schriften und Variablen, keine Regeln. Hell in :root, Dunkel in den beiden gleichen Bloecken
   darunter - einmal "wie das System", einmal fuer den Schalter (data-theme="dark" am <html>).

   Abweichung vom Plan, damit jeder Text 4,5:1 erreicht (tests/test_gestaltung.py rechnet):
   --primaer dunkel #7A92F6 statt #4D6BF0 (Knopftext dunkel auf Blau 4,15:1 waere zu wenig), und je Statusfarbe
   eine eigene Textfarbe (--laeuft-text usw.), weil Gelb, Gruen und Orange hell als Schrift zu blass sind. */

@font-face {
  font-family: "Sora";
  src: url("../schrift/sora.woff2") format("woff2");
  font-weight: 100 800;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Inter";
  src: url("../schrift/inter.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "JetBrains Mono";
  src: url("../schrift/mono.woff2") format("woff2");
  font-weight: 100 800;
  font-style: normal;
  font-display: swap;
}

:root {
  color-scheme: light;
  --grund: #f4f6fb;
  --flaeche: #ffffff;
  --flaeche-2: #f7f8fc;
  --flaeche-3: #eceff6;
  --linie: #e1e5ef;
  --linie-stark: #c8cfde;
  --linie-eingabe: #7d889f;
  --text: #141a2b;
  --text-2: #475267;
  --text-3: #5d6880;
  --tinte: #16257a;
  --primaer: #2346d8;
  --primaer-hover: #1c39b4;
  --primaer-text: #ffffff;
  --marke: #2346d8;
  --marke-schwach: rgb(35 70 216 / 0.1);
  --fokus: #2346d8;

  --laeuft: #b7790f;
  --laeuft-text: #7a5306;
  --laeuft-grund: color-mix(in srgb, var(--laeuft) 11%, var(--flaeche));
  --rueckfrage: #c8303a;
  --rueckfrage-text: #b02631;
  --rueckfrage-grund: color-mix(in srgb, var(--rueckfrage) 8%, var(--flaeche));
  --fertig: #1e8e4e;
  --fertig-text: #16703c;
  --fertig-grund: color-mix(in srgb, var(--fertig) 10%, var(--flaeche));
  --achtung: #c85a1a;
  --achtung-text: #a0450f;
  --achtung-grund: color-mix(in srgb, var(--achtung) 10%, var(--flaeche));
  --grau: #8a93a6;

  /* Nur was schwebt, wirft einen Schatten (Menues, Dialoge, Blaetter); der Kopf erst beim Scrollen. */
  --schatten-schwebt: 0 8px 24px -10px rgb(20 26 43 / 0.28);
  --schatten-kopf: 0 4px 12px -8px rgb(20 26 43 / 0.22);
  --schleier: rgb(8 12 24 / 0.5);

  --radius-karte: 8px;
  --radius-innen: 6px;
  --radius-knopf: 8px;
  --radius-dialog: 12px;
  --schrift-titel: "Sora", "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --schrift: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, "SF Mono", Menlo, Consolas, monospace;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    color-scheme: dark;
    --grund: #0e1220;
    --flaeche: #161b2c;
    --flaeche-2: #1b2134;
    --flaeche-3: #232b41;
    --linie: #293149;
    --linie-stark: #3a4461;
    --linie-eingabe: #6b7694;
    --text: #e7eaf3;
    --text-2: #aeb6c8;
    --text-3: #8c96ac;
    --tinte: #f2f4f3;
    --primaer: #7a92f6;
    --primaer-hover: #96a9f8;
    --primaer-text: #0e1220;
    --marke: #7a92f6;
    --marke-schwach: rgb(122 146 246 / 0.14);
    --fokus: #7a92f6;
    --laeuft: #f0be4a;
    --laeuft-text: #f0be4a;
    --laeuft-grund: color-mix(in srgb, var(--laeuft) 12%, var(--flaeche));
    --rueckfrage: #ff6b7a;
    --rueckfrage-text: #ff6b7a;
    --rueckfrage-grund: color-mix(in srgb, var(--rueckfrage) 12%, var(--flaeche));
    --fertig: #3bcb7e;
    --fertig-text: #3bcb7e;
    --fertig-grund: color-mix(in srgb, var(--fertig) 12%, var(--flaeche));
    --achtung: #ff8f55;
    --achtung-text: #ff8f55;
    --achtung-grund: color-mix(in srgb, var(--achtung) 12%, var(--flaeche));
    --grau: #7f889c;
    --schatten-schwebt: 0 10px 28px -10px rgb(0 0 0 / 0.6);
    --schatten-kopf: 0 4px 12px -8px rgb(0 0 0 / 0.55);
    --schleier: rgb(0 0 0 / 0.6);
  }
}

:root[data-theme="dark"] {
  color-scheme: dark;
  --grund: #0e1220;
  --flaeche: #161b2c;
  --flaeche-2: #1b2134;
  --flaeche-3: #232b41;
  --linie: #293149;
  --linie-stark: #3a4461;
  --linie-eingabe: #6b7694;
  --text: #e7eaf3;
  --text-2: #aeb6c8;
  --text-3: #8c96ac;
  --tinte: #f2f4f3;
  --primaer: #7a92f6;
  --primaer-hover: #96a9f8;
  --primaer-text: #0e1220;
  --marke: #7a92f6;
  --marke-schwach: rgb(122 146 246 / 0.14);
  --fokus: #7a92f6;
  --laeuft: #f0be4a;
  --laeuft-text: #f0be4a;
  --laeuft-grund: color-mix(in srgb, var(--laeuft) 12%, var(--flaeche));
  --rueckfrage: #ff6b7a;
  --rueckfrage-text: #ff6b7a;
  --rueckfrage-grund: color-mix(in srgb, var(--rueckfrage) 12%, var(--flaeche));
  --fertig: #3bcb7e;
  --fertig-text: #3bcb7e;
  --fertig-grund: color-mix(in srgb, var(--fertig) 12%, var(--flaeche));
  --achtung: #ff8f55;
  --achtung-text: #ff8f55;
  --achtung-grund: color-mix(in srgb, var(--achtung) 12%, var(--flaeche));
  --grau: #7f889c;
  --schatten-schwebt: 0 10px 28px -10px rgb(0 0 0 / 0.6);
  --schatten-kopf: 0 4px 12px -8px rgb(0 0 0 / 0.55);
  --schleier: rgb(0 0 0 / 0.6);
}
