/* Händlerportal haendler.tradidog.ch. Tokens gleich wie cockpit/web/styles.css (Test tests/portal_texte.test.js).
   Gestaltung nach Entwurf Claude Design (https://claude.ai/artifact/QzSGYdmv1UcYPPNL99B3dD, Quelle .design/haendlerportal/), Kim 16.10.2026.
   Ecken: Karten 10px, Knöpfe und Felder 6px, Pillen rund. Hell und dunkel wie das Cockpit. Tippflächen mindestens 44px. */
:root {
  --ground: #f7f8f5;
  --surface: #ffffff;
  --surface-2: #eef3ec;
  --ink: #373b41;
  --muted: #61675f;
  --line: #dfe3de;
  --feld: #8f978d;
  --brand: #638565;
  --accent: #4a674c;
  --accent-ink: #ffffff;
  --ok: #2d7a4a;
  --ok-bg: #e3f2e8;
  --warn: #8a5a0f;
  --warn-bg: #fbf0dc;
  --crit: #b23a2a;
  --crit-bg: #fbe5e1;
  --neutral-bg: #ebeee9;
  --display: "Bebas Neue", "Barlow Semi Condensed", "Arial Narrow", sans-serif;
  --body: "Barlow Semi Condensed", "Segoe UI", system-ui, -apple-system, sans-serif;
  --breite: 1240px;
  accent-color: var(--accent);
}
@media (prefers-color-scheme: dark) {
  :root {
    color-scheme: dark;
    --ground: #121512; --surface: #1a1e1b; --surface-2: #212822; --ink: #e6e9e4; --muted: #a3aba2; --line: #2e352f; --feld: #6b736c;
    --brand: #8fb092; --accent: #9cc29f; --accent-ink: #121512; --ok: #6cc28e; --ok-bg: #173325; --warn: #e2b056; --warn-bg: #3a2c12;
    --crit: #f08a78; --crit-bg: #3d1d18; --neutral-bg: #242b25;
  }
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
main:focus { outline: none; }
body { margin: 0; background: var(--ground); color: var(--ink); font: 400 17px/1.45 var(--body); min-height: 100vh; display: flex; flex-direction: column; }
a { color: var(--accent); }
a:hover { color: var(--ink); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
h1, h2, h3 { font-family: var(--display); font-weight: 400; letter-spacing: .01em; margin: 0; line-height: 1.05; }
h1 { font-size: clamp(2.2rem, 1.6rem + 2vw, 3rem); }
h2 { font-size: 1.75rem; margin-bottom: 10px; }
h3 { font-size: 1.35rem; margin-bottom: 6px; }
.vh { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.klein { color: var(--muted); font-size: .9rem; }
.text { white-space: pre-line; margin: 0; }
.vermerk { font-size: .85rem; color: var(--warn); }
.leer { color: var(--muted); }
.rechts { text-align: right; }

/* Kopf */
.kopf { position: sticky; top: 0; z-index: 3; background: var(--surface); border-bottom: 1px solid var(--line); }
.kopf-innen { max-width: var(--breite); margin: 0 auto; padding: 0 24px; min-height: 68px; display: flex; align-items: center; gap: 28px; }
.logo { width: 118px; height: 30px; flex: 0 0 auto; background: var(--brand); -webkit-mask: url(logo.png) left center / contain no-repeat; mask: url(logo.png) left center / contain no-repeat; }
.nav { display: flex; gap: 2px; flex: 1; }
.nav a { display: flex; align-items: center; gap: 8px; min-height: 48px; padding: 0 14px; color: var(--ink); text-decoration: none; font-weight: 500; white-space: nowrap; }
.nav a svg { display: none; }
.nav a[aria-current="page"] { color: var(--accent); font-weight: 600; box-shadow: inset 0 -3px 0 var(--brand); }
.wer { display: flex; flex-direction: column; text-align: right; line-height: 1.2; }
.wer span { color: var(--muted); font-size: .85rem; }
.abmelden { background: none; border: 0; color: var(--accent); font: 500 1rem var(--body); text-decoration: underline; min-height: 44px; padding: 0 4px; cursor: pointer; }

main { width: 100%; max-width: var(--breite); margin: 0 auto; padding: 32px 24px 64px; flex: 1; }
.fuss { background: var(--surface); border-top: 1px solid var(--line); color: var(--muted); font-size: .95rem; }
.fuss-innen { max-width: var(--breite); margin: 0 auto; padding: 16px 24px; display: flex; flex-wrap: wrap; gap: 8px 24px; align-items: center; }
.fuss-innen #datenschutz { margin-left: auto; display: inline-flex; align-items: center; min-height: 44px; }
.fuss-innen strong { color: var(--ink); }

/* Knöpfe und Felder */
button, .knopf { display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 48px; padding: 0 20px;
  font: 600 1rem var(--body); border: 1px solid var(--accent); background: var(--accent); color: var(--accent-ink); border-radius: 6px; cursor: pointer; text-decoration: none; }
button.zweit, .knopf.zweit { background: var(--surface); color: var(--accent); }
button:disabled { opacity: .6; cursor: progress; }
button:active, .knopf:active { transform: translateY(1px); }
input, select { font: 400 1.0625rem var(--body); width: 100%; min-height: 48px; padding: 0 14px; border: 1px solid var(--feld); border-radius: 6px; background: var(--surface); color: var(--ink); }
label { display: block; font-weight: 500; margin: 14px 0 6px; }

/* Bausteine */
.karte { background: var(--surface); border: 1px solid var(--line); border-radius: 10px; padding: 20px; }
.stapel { display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.zwei { display: flex; flex-wrap: wrap; gap: 32px; align-items: flex-start; margin-top: 24px; }
.zwei > .weit { flex: 999 1 560px; gap: 36px; }
.zwei > aside { flex: 1 1 320px; max-width: 380px; }
.zwei > section.karte { flex: 1 1 360px; }
.zwei-gleich { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 24px; }
.raster { display: grid; gap: 12px; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); }
.meldung { padding: 12px 14px; border-radius: 6px; margin: 12px 0; }
.meldung.ok { background: var(--ok-bg); color: var(--ok); } .meldung.fehler { background: var(--crit-bg); color: var(--crit); }
.pille { display: inline-block; padding: 3px 10px; border-radius: 999px; font-size: .85rem; font-weight: 600; }
.pille.ok { background: var(--ok-bg); color: var(--ok); } .pille.warn { background: var(--warn-bg); color: var(--warn); }
.pille.crit { background: var(--crit-bg); color: var(--crit); } .pille.neutral { background: var(--neutral-bg); color: var(--muted); }
.eintrag { border-top: 1px solid var(--line); padding: 10px 0; }
.eintrag:first-of-type { border-top: 0; }
dl.angaben { display: grid; grid-template-columns: max-content 1fr; gap: 6px 16px; margin: 16px 0 0; font-size: .95rem; }
dl.angaben dt { color: var(--muted); }
dl.angaben dd { margin: 0; }
.hinweis { position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%); z-index: 5; max-width: min(560px, calc(100% - 32px));
  background: var(--crit-bg); color: var(--crit); border: 1px solid var(--crit); border-radius: 10px; padding: 12px 16px; font-weight: 500; }
.tile { width: 52px; height: 52px; border-radius: 8px; background: var(--surface-2); display: flex; align-items: center; justify-content: center; overflow: hidden; }
.tile img { width: 100%; height: 100%; object-fit: contain; }
.tile.gross { width: 100%; height: 220px; }
.initial { font: 400 1.6rem var(--display); color: var(--accent); }
.tile.gross .initial { font-size: 4rem; }

/* Anmeldung */
.anmeldung { max-width: 420px; margin: 8vh auto 0; }
.anmeldung .logo { display: block; margin-bottom: 18px; }
.anmeldung h1 { margin-bottom: 8px; }
.anmeldung a { display: inline-flex; align-items: center; min-height: 44px; }

/* Start */
.gruss { margin: 0 0 4px; }
.aktion { display: flex; gap: 20px; align-items: flex-start; }
.aktion-zahl { font: 400 2.6rem/1 var(--display); color: var(--accent); min-width: 110px; }
.aktion a { display: inline-flex; align-items: center; min-height: 44px; font-weight: 600; }
.weg { display: flex; justify-content: flex-start; width: 100%; min-height: 56px; }
.weg .pfeil { margin-left: auto; }
.zweit.weg { border-color: var(--line); color: var(--ink); background: var(--surface); }

/* Sortiment */
.titelzeile { display: flex; flex-wrap: wrap; gap: 16px 24px; align-items: flex-end; justify-content: space-between; }
.titelzeile p { margin: 6px 0 0; }
.werkzeug { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; margin: 24px 0 8px; }
.werkzeug > input { flex: 1 1 280px; max-width: 420px; }
.werkzeug > div { flex: 1 1 220px; }
.sprung { display: flex; flex-wrap: wrap; gap: 8px; }
.sprung button { min-height: 44px; padding: 0 14px; border-radius: 999px; border-color: var(--line); background: var(--surface); color: var(--ink); font-weight: 500; }
.sprung button span { color: var(--muted); margin-left: 4px; }
.tabelle { background: var(--surface); border: 1px solid var(--line); border-radius: 10px; overflow: hidden; scroll-margin-top: 84px; margin-top: 16px; }
.tabellen-titel { display: flex; align-items: baseline; gap: 12px; padding: 18px 16px 8px; }
.tabellen-titel h2 { margin: 0; }
.zeile { display: grid; grid-template-columns: 52px minmax(0, 1fr) 120px 130px 96px 84px 170px; align-items: center; gap: 16px; padding: 10px 16px; border-top: 1px solid var(--line); }
.kopfzeile { padding-top: 6px; padding-bottom: 6px; font-size: .9rem; font-weight: 600; color: var(--muted); }
.spaltenkopf { min-height: 36px; padding: 0; border: 0; background: none; color: var(--muted); font: 600 .9rem var(--body); justify-content: flex-start; }
.spaltenkopf[aria-pressed="true"] { color: var(--accent); }
.c-preis, .c-uvp, .c-marge, .c-karton { text-align: right; justify-content: flex-end; }
.c-name a { font-weight: 600; color: var(--ink); text-decoration: none; }
.c-name a:hover { color: var(--accent); text-decoration: underline; }
.zeile:not(.kopfzeile) .c-preis { font: 400 1.6rem/1 var(--display); }
.zeile:not(.kopfzeile) .c-uvp, .zeile:not(.kopfzeile) .c-karton { color: var(--muted); font-size: .95rem; }
.zeile:not(.kopfzeile) .c-marge { font: 400 1.35rem/1 var(--display); color: var(--ok); }
.statt { display: block; font: 400 .9rem var(--body); color: var(--muted); }
.nur-handy { display: none; }

/* Produktseite */
.zurueck { display: inline-flex; align-items: center; min-height: 44px; font-weight: 500; text-decoration: none; }
.produktseite { margin-top: 8px; }
.produkttitel { font-size: clamp(2.8rem, 2rem + 3vw, 4rem); margin: 4px 0 14px; }
.einleitung { font-size: 1.15rem; max-width: 62ch; white-space: normal; }
.vorteile { margin: 0; padding-left: 20px; display: grid; gap: 4px; }
.argumente { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 12px; margin: 12px 0; }
.argumente .karte { padding: 16px; }
.argumente p { margin-top: 4px; }
.aufklapp { padding: 0 16px; margin-top: 8px; }
.aufklapp summary { min-height: 48px; display: flex; align-items: center; font-weight: 600; cursor: pointer; }
.aufklapp[open] { padding-bottom: 12px; }
.preisblock { display: flex; justify-content: space-between; align-items: flex-end; gap: 12px; margin-top: 18px; }
.gross-zahl { font: 400 2.8rem/1 var(--display); }
.marge-zahl { font: 400 2rem/1 var(--display); color: var(--ok); }
aside h3 { margin-top: 8px; margin-bottom: 0; font-size: 1.2rem; }
.dl { display: flex; padding: 0 20px; border: 1px solid var(--line); border-radius: 6px; justify-content: space-between; width: 100%; background: var(--surface); color: var(--ink); border-color: var(--line); font-weight: 500; min-height: 48px; text-decoration: none; }
.dl small { color: var(--muted); font-weight: 400; font-size: .85rem; }

/* Handy: Navigation unten, Liste als kompakte Zeilen */
@media (max-width: 760px) {
  body { padding-bottom: 72px; }
  .kopf-innen { min-height: 56px; padding: 0 16px; gap: 12px; justify-content: space-between; }
  .wer strong { font-size: .95rem; }
  .wer span { display: none; }
  .abmelden { display: none; }
  .nav { position: fixed; left: 0; right: 0; bottom: 0; z-index: 4; background: var(--surface); border-top: 1px solid var(--line); gap: 0; padding-bottom: env(safe-area-inset-bottom); }
  .nav a { flex: 1; flex-direction: column; justify-content: center; gap: 2px; min-height: 60px; padding: 4px 0; font-size: .8rem; color: var(--muted); }
  .nav a svg { display: block; }
  .nav a[aria-current="page"] { box-shadow: none; color: var(--accent); }
  main { padding: 20px 16px 40px; }
  .titelzeile button { width: 100%; }
  .sprung { flex-wrap: nowrap; overflow-x: auto; width: 100%; padding-bottom: 4px; }
  .sprung button { white-space: nowrap; }
  .tabelle { border-radius: 0; border-left: 0; border-right: 0; margin-left: -16px; margin-right: -16px; }
  .kopfzeile { display: none; }
  .zeile { grid-template-columns: 44px minmax(0, 1fr) auto; grid-template-areas: "bild name preis" "bild name marge" "bild name uvp"; gap: 2px 12px; padding: 12px 16px; }
  .c-bild { grid-area: bild; align-self: start; } .c-name { grid-area: name; } .c-preis { grid-area: preis; } .c-marge { grid-area: marge; }
  .c-uvp { grid-area: uvp; font-size: .85rem !important; } .c-karton, .c-liefer { display: none; }
  .tile { width: 44px; height: 44px; }
  .zeile:not(.kopfzeile) .c-marge { font: 600 .9rem var(--body); }
  .nur-handy { display: inline; }
  .c-name .nur-handy { display: inline-block; margin-top: 4px; }
  .fuss-innen { padding: 16px; }
  .zwei > aside { max-width: none; }
  .aktion { flex-direction: column; gap: 8px; }
}
