/* Layout: linksbündig, Menü oben, Inhalt pro Seite, Impressum und Datenschutz im Fuß jeder Seite */
:root {
  --bg: #F2F4F3;
  --surface: #FFFFFF;
  --fg: #15232A;
  --muted: #55656B;
  --line: #D3DBDA;
  --accent: #0E5E63;
  --accent-ink: #FFFFFF;
  --ok-bg: #D9EFE3; --ok-fg: #14502F;
  --dev-bg: #FBEFC9; --dev-fg: #5A4200;
  --cover-ink: #FFFFFF;
  --font: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", sans-serif;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0F1A1E; --surface: #16252A; --fg: #E6EEEE; --muted: #9AAEB1; --line: #28393E;
    --accent: #5FC1BF; --accent-ink: #0F1A1E;
    --ok-bg: #163A28; --ok-fg: #9FE0BB; --dev-bg: #3A3014; --dev-fg: #F1D58A;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #0F1A1E; --surface: #16252A; --fg: #E6EEEE; --muted: #9AAEB1; --line: #28393E;
  --accent: #5FC1BF; --accent-ink: #0F1A1E;
  --ok-bg: #163A28; --ok-fg: #9FE0BB; --dev-bg: #3A3014; --dev-fg: #F1D58A;
  color-scheme: dark;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--font);
  font-size: 18px;
  line-height: 1.6;
  padding-left: max(16px, env(safe-area-inset-left, 0px));
  padding-right: max(16px, env(safe-area-inset-right, 0px));
}
.wrap { max-width: 1080px; margin: 0 auto; }
h1, h2, h3 { line-height: 1.08; text-wrap: balance; margin: 0; letter-spacing: -.02em; }
p { margin: 0 0 12px; max-width: 65ch; }
a { color: var(--accent); text-underline-offset: 3px; }
a:focus-visible, button:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; border-radius: 3px; }
.sr-only { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.muted { color: var(--muted); }

/* Kopf und Menü */
header.top { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 8px 32px; padding-block: 24px; border-bottom: 1px solid var(--line); }
.brand { font-weight: 800; font-size: 1.2rem; text-decoration: none; color: var(--fg); letter-spacing: -.01em; }
nav { display: flex; flex-wrap: wrap; gap: 8px 24px; font-size: 1rem; }
nav a { color: var(--muted); text-decoration: none; }
nav a:hover { color: var(--accent); text-decoration: underline; }
nav a[aria-current="page"] { color: var(--fg); font-weight: 700; text-decoration: underline; text-decoration-thickness: 3px; text-decoration-color: var(--accent); text-underline-offset: 6px; }

main { padding-bottom: 56px; }
.page-title { font-size: clamp(2rem, 6vw, 3.2rem); font-weight: 800; letter-spacing: -.03em; padding-block: 40px 8px; }

/* Banner für das Intro */
.stage { position: relative; margin-block: 28px 8px; aspect-ratio: 21 / 9; min-height: 220px; max-width: 100%; border-radius: 10px; overflow: hidden; color: var(--cover-ink); display: grid; place-items: center; text-align: center;
  background-color: hsl(190 55% 18%);
  background-image: linear-gradient(rgba(255,255,255,.07) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.07) 1px, transparent 1px), linear-gradient(140deg, hsl(190 60% 28%), hsl(240 55% 14%));
  background-size: 28px 28px, 28px 28px, 100% 100%; }
.stage .soon { display: grid; gap: 6px; padding: 16px; }
.stage .soon small { font-size: .85rem; opacity: .85; }
.stage .soon b { font-size: clamp(2rem, 7vw, 3.4rem); letter-spacing: -.03em; line-height: 1.05; }
.stage .soon small { font-size: 1rem; }
.muted-note { color: var(--muted); margin-top: 20px; }
.stage canvas, .stage video { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }

/* Überschriften der Gruppen */
.group-head { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 20px; margin-top: 40px; padding-top: 24px; border-top: 2px solid var(--fg); }
.group-head h2 { font-size: 1.8rem; font-weight: 800; }
.group-head p { margin: 0; color: var(--muted); font-size: 1rem; }

/* Projekt-Zeile (Seite Projekte) */
.project { display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 2fr); gap: 24px 40px; padding-block: 32px 40px; border-bottom: 1px solid var(--line); align-items: start; scroll-margin-top: 8px; }
.project:last-child { border-bottom: 0; }

.media { position: relative; aspect-ratio: 16 / 9; max-width: 100%; border-radius: 10px; overflow: hidden; color: var(--cover-ink); display: grid; place-items: center; text-align: center;
  background-color: hsl(var(--h, 190) 55% 26%);
  background-image:
    linear-gradient(rgba(255,255,255,.08) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.08) 1px, transparent 1px),
    linear-gradient(140deg, hsl(var(--h, 190) 60% 34%), hsl(calc(var(--h, 190) + 50) 55% 18%));
  background-size: 28px 28px, 28px 28px, 100% 100%; }
.media .soon { display: grid; gap: 6px; padding: 16px; justify-items: center; }
.media .soon b { font-size: 1.15rem; letter-spacing: .02em; }
.media .soon small { font-size: .85rem; opacity: .85; }
.media .play-ico { width: 56px; height: 56px; border-radius: 50%; border: 2px solid var(--cover-ink); display: grid; place-items: center; font-size: 1.2rem; opacity: .9; }
.media iframe, .media video { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; background: #000; }
.media button.play { all: unset; cursor: pointer; display: grid; gap: 8px; justify-items: center; padding: 16px; width: 100%; height: 100%; align-content: center; color: var(--cover-ink); }
.media button.play small { font-size: .8rem; opacity: .85; max-width: 32ch; }

.info { display: grid; gap: 14px; min-width: 0; }
.meta { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.tag { font-size: .78rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.pill { font-size: .78rem; font-weight: 700; padding: 2px 10px; border-radius: 999px; }
.pill.ok { background: var(--ok-bg); color: var(--ok-fg); }
.pill.dev { background: var(--dev-bg); color: var(--dev-fg); }
.pill.example { background: transparent; color: var(--muted); border: 1px dashed var(--muted); }
.info h3 { font-size: clamp(1.6rem, 4vw, 2.2rem); font-weight: 800; }
.info p { color: var(--muted); font-size: 1.02rem; margin: 0; }
.facts { margin: 0; display: grid; gap: 6px; font-size: .98rem; }
.facts div { display: grid; grid-template-columns: 7.5rem minmax(0, 1fr); gap: 12px; }
.facts dt { color: var(--muted); }
.facts dd { margin: 0; }
.buttons { display: flex; flex-wrap: wrap; gap: 10px; padding-top: 4px; }
.btn { display: inline-block; font-size: .98rem; font-weight: 700; text-decoration: none; padding: 9px 16px; border-radius: 6px; border: 2px solid var(--accent); color: var(--accent); background: transparent; }
.btn.primary { background: var(--accent); color: var(--accent-ink); }
.btn:hover { text-decoration: underline; }
.btn.is-off { border: 2px dashed var(--line); color: var(--muted); background: transparent; cursor: default; font-weight: 600; }
.btn.is-off:hover { text-decoration: none; }

/* Projekt-Karten (Startseite) */
.section-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 8px 24px; margin-top: 40px; padding-top: 24px; border-top: 2px solid var(--fg); }
.section-head h2 { font-size: 1.8rem; font-weight: 800; }
.cards { list-style: none; margin: 24px 0 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; }
.card { display: grid; gap: 12px; text-decoration: none; color: var(--fg); align-content: start; }
.card .media { transition: transform .15s ease; }
.card:hover .media { transform: translateY(-3px); }
.card h3 { font-size: 1.3rem; font-weight: 800; }
.card:hover h3 { text-decoration: underline; text-decoration-color: var(--accent); text-decoration-thickness: 3px; text-underline-offset: 4px; }

/* Textseiten */
.text-page { display: grid; gap: 14px; max-width: 65ch; padding-top: 16px; }
.text-page h2 { font-size: 1.15rem; font-weight: 800; margin-top: 14px; letter-spacing: -.01em; }
.text-page p { color: var(--muted); }
.text-page p.fg { color: var(--fg); }

footer { border-top: 1px solid var(--line); padding-block: 28px 44px; display: flex; flex-wrap: wrap; gap: 8px 24px; justify-content: space-between; font-size: .95rem; color: var(--muted); }
footer nav { font-size: .95rem; gap: 8px 20px; }

@media (max-width: 800px) {
  body { font-size: 17px; }
  .stage { aspect-ratio: 4 / 3; margin-block: 20px 4px; }
  .project { grid-template-columns: minmax(0, 1fr); padding-block: 28px 36px; }
  .cards { grid-template-columns: minmax(0, 1fr); }
  .page-title { padding-block: 28px 4px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .card .media { transition: none; }
}

/* App-Vorstellung: Fotofilme im Querformat und kurze Projektbeschreibung. */
.project-demo { margin: 0; min-width: 0; width: 100%; max-width: 680px; justify-self: center; }
.media.portrait { aspect-ratio: 9 / 16; background: #F6F8F0; }
.project-demo figcaption { margin-top: 10px; color: var(--muted); font-size: .82rem; line-height: 1.5; }
.language-switch { display: inline-flex; border: 1px solid var(--line); border-radius: 999px; overflow: hidden; }
.language-switch a { padding: 7px 10px; font-size: .82rem; line-height: 1.2; text-decoration: none; }
.language-switch a[aria-current] { background: var(--accent); color: var(--accent-ink); }
.language-switch a:focus-visible { outline: 3px solid var(--fg); outline-offset: -3px; }
.video-gallery { margin-top: 18px; }
.video-gallery h4 { font-size: 1rem; margin-bottom: 10px; }
.video-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.video-choice { display: block; min-width: 0; border: 1px solid var(--line); border-radius: 8px; padding-bottom: 8px; overflow: hidden; color: var(--fg); text-decoration: none; }
.video-choice[aria-current] { border-color: var(--accent); box-shadow: 0 0 0 2px var(--accent); }
.video-choice:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; }
.video-preview { display: block; position: relative; aspect-ratio: 16 / 9; }
.video-preview img { display: block; width: 100%; height: 100%; object-fit: cover; }
.video-play { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); background: #173e32d9; color: white; border-radius: 50%; width: 38px; height: 38px; display: grid; place-items: center; font-size: 15px; padding-left: 2px; }
.video-duration { position: absolute; bottom: 5px; right: 5px; padding: 1px 4px; border-radius: 3px; background: #102b23e6; color: white; font-size: .7rem; }
.video-title, .video-language { display: block; padding-inline: 8px; }
.video-title { margin-top: 7px; font-size: .82rem; line-height: 1.25; font-weight: 700; }
.video-language { margin-top: 3px; font-size: .7rem; color: var(--muted); }
.project-demo figcaption strong, .project-demo figcaption span, .project-demo figcaption small { display: block; }
.project-demo figcaption small { margin-top: 5px; }
@media (max-width: 540px) { .video-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; } }
.project-cover img { display: block; width: 100%; height: 100%; object-fit: contain; background: #F6F8F0; }
.info .project-lead { color: var(--fg); font-weight: 700; }
.facts small { color: var(--muted); font-size: .82rem; }
@media (max-width: 420px) { .facts div { grid-template-columns: 1fr; gap: 2px; } }

/* Abgehakt: Nutzen zuerst, Details auf Wunsch. */
.feature-link { font-size: .95rem; font-weight: 700; justify-self: start; }
.app-features { padding: 20px 0 36px; scroll-margin-top: 20px; }
.benefits { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; padding-block: 12px 28px; }
.benefits h3 { font-size: 1.15rem; margin-bottom: 10px; }
.benefits p { color: var(--muted); font-size: 1rem; }
.feature-details { border-block: 1px solid var(--line); padding-block: 18px; }
.feature-details summary { cursor: pointer; font-weight: 700; color: var(--accent); }
.feature-details summary:focus-visible { outline: 3px solid var(--accent); outline-offset: 4px; }
.feature-gallery { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; margin-top: 24px; }
.feature-gallery figure { margin: 0; min-width: 0; }
.feature-gallery img { width: 100%; height: auto; display: block; border: 1px solid var(--line); border-radius: 8px; }
.feature-gallery figcaption { margin-top: 10px; font-size: .95rem; font-weight: 600; }
.feature-gallery + p { margin-top: 18px; font-size: .85rem; }
@media (max-width: 640px) {
  .benefits, .feature-gallery { grid-template-columns: minmax(0, 1fr); }
  .benefits { gap: 14px; }
  .feature-gallery figure { width: 100%; max-width: 310px; justify-self: center; }
}

.app-title { display: flex; gap: 12px; align-items: center; }
.app-title img { display: block; width: 48px; height: 48px; border-radius: 10px; flex-shrink: 0; }

.teaser-details, .catalog-details { border-top: 1px solid var(--line); padding-block: 18px; }
.teaser-details summary, .catalog-details summary { cursor: pointer; font-weight: 700; color: var(--accent); }
.teaser-details summary:focus-visible, .catalog-details summary:focus-visible { outline: 3px solid var(--accent); outline-offset: 4px; }
.teaser-demo { max-width: 900px; margin: 24px auto 8px; }
.teaser-demo figcaption { color: var(--muted); font-size: .85rem; margin-top: 12px; }

/* Shared app help: task titles first, numbered steps only when opened. */
.help-intro { margin-block: 16px 20px; }
.help-page { max-width: 780px; }
.help-search { display: grid; gap: 6px; max-width: 32rem; font-size: .95rem; }
.help-search input { width: 100%; font: inherit; padding: 10px 12px; color: var(--fg); background: var(--surface); border: 1px solid var(--line); border-radius: 6px; }
.help-search input:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; }
.help-group { margin-top: 30px; }
.help-group h2 { font-size: 1.3rem; margin-bottom: 12px; }
.help-case { background: var(--surface); border: 1px solid var(--line); border-radius: 8px; margin-bottom: 10px; scroll-margin-top: 20px; }
.help-case summary { cursor: pointer; padding: 14px 16px; }
.help-case summary span { font-weight: 650; }
.help-case summary small { display: block; margin-top: 4px; padding-left: 19px; color: var(--muted); font-size: .8rem; }
.help-case ol { padding: 0 22px 0 42px; margin-bottom: 16px; }
.help-case li + li { margin-top: 8px; }
.help-step-text { margin: 0 0 10px; }
.help-step-images { display: flex; flex-wrap: wrap; gap: 14px; margin: 12px 0 22px; }
.help-shot { display: block; width: min(280px, 100%); color: var(--fg); text-decoration: none; border-radius: 8px; }
.help-shot:focus-visible { outline: 3px solid var(--accent); outline-offset: 4px; }
.help-shot-frame { display: block; position: relative; width: 100%; aspect-ratio: 1 / 2; overflow: hidden; border-radius: 4px; background: #f5f8f2; }
.help-shot-frame img { display: block; width: 100%; height: 100%; object-fit: contain; }
.help-focus { position: absolute; pointer-events: none; box-sizing: border-box; border: 2px solid #ad7400; box-shadow: 0 0 0 1px #fff; border-radius: 3px; }
.help-shot-label { display: flex; justify-content: space-between; gap: 8px; margin-top: 6px; font-size: .82rem; color: var(--muted); }
.help-image-viewer { color: var(--fg); background: var(--surface); border: 1px solid var(--line); border-radius: 10px; padding: 12px; max-width: calc(100vw - 24px); max-height: calc(100dvh - 24px); }
.help-image-viewer[open] { display: flex; flex-direction: column; align-items: center; gap: 10px; }
.help-image-viewer::backdrop { background: rgb(0 0 0 / .78); }
.help-viewer-controls { display: flex; justify-content: space-between; gap: 12px; width: 100%; }
.help-viewer-controls button { font: inherit; color: var(--fg); background: var(--surface); border: 1px solid var(--line); border-radius: 5px; min-width: 44px; min-height: 44px; padding: 5px 10px; cursor: pointer; }
.help-viewer-controls button:disabled { opacity: .4; cursor: default; }
.help-viewer-controls button:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }
#help-image-stage .help-shot-frame { width: min(76vw, calc((100dvh - 155px) / 2)); max-width: 540px; }
#help-image-caption { margin: 0; font-size: .9rem; max-width: 34rem; }
.help-note { padding: 0 16px 16px; font-size: .9rem; color: var(--muted); margin: 0; }
.help-back { margin-top: 28px; }
[hidden] { display: none !important; }

/* Product catalogue and Abgehakt detail: concise sections with direct guide links. */
.breadcrumbs { align-items: center; gap: 8px; padding-top: 24px; font-size: .9rem; color: var(--muted); }
.product-heading .page-title { padding-top: 20px; }
.product-heading .app-title img { width: 56px; height: 56px; }
.product-tagline { margin-top: 14px; font-size: clamp(1.25rem, 3vw, 1.8rem); font-weight: 650; }
.product-links { margin: 20px 0 4px; }
.page-intro { margin-top: 12px; color: var(--muted); }
.app-cards { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.card h2 { font-size: 1.4rem; }
.empty-catalog { padding: 32px 0 64px; }
.empty-catalog h2 { margin-bottom: 16px; font-size: 1.4rem; }
.product-description > h2, .product-section > h2 { font-size: clamp(1.5rem, 4vw, 2rem); margin-bottom: 16px; }
.section-intro { color: var(--muted); margin-bottom: 28px; }
.description-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 28px 40px; }
.description-grid article { border-top: 1px solid var(--line); padding-top: 20px; min-width: 0; }
.description-grid h3 { font-size: 1.2rem; margin-bottom: 12px; }
.description-grid p { font-size: 1rem; }
.description-grid a { font-size: .95rem; }
.product-section { padding: 32px 0; border-top: 1px solid var(--line); }
.product-list { padding-left: 24px; margin: 0 0 20px; }
.product-extras { border-top: 1px solid var(--line); padding: 24px 0; }
.product-extras summary { cursor: pointer; font-weight: 650; }
.product-extras p { margin-top: 18px; }
.product-help { padding-bottom: 0; }
@media (max-width: 800px) {
  .app-cards, .description-grid { grid-template-columns: minmax(0, 1fr); }
}
