/* 0wl – minimal dark interface */
:root {
  color-scheme: dark;
  --background: #050505;
  --surface: #0d0c0e;
  --text: #eae7e9;
  --muted: #969096;
  --accent: #a33e6a;
  --accent-soft: #70405a;
  --stroke: #4b4149;
  --field: min(calc(100vw - 48px), calc(100svh - 168px), 970px);
  --radius: calc(var(--field) * .390);
  --tab: clamp(60px, calc(var(--field) * .137), 126px);
  --icon: clamp(22px, calc(var(--field) * .039), 37px);
  font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
* { box-sizing: border-box; }
html { background: var(--background); }
body { margin: 0; color: var(--text); background: var(--background); min-height: 100vh; min-height: 100dvh; display: flex; flex-direction: column; }
a { color: inherit; }
[hidden] { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; }
.icon-library { position: absolute; width: 0; height: 0; overflow: hidden; pointer-events: none; }
#app { flex: 1 0 auto; display: flex; flex-direction: column; }

/* restrained, locally rendered violet ambient background */
.ambient-backdrop {
  position: fixed; inset: 0; z-index: 0; pointer-events: none; overflow: hidden;
  background:
    radial-gradient(ellipse 40% 42% at 8% 30%, rgba(88, 42, 76, .10), transparent 78%),
    radial-gradient(ellipse 38% 44% at 96% 63%, rgba(92, 40, 77, .11), transparent 77%);
}
.ambient-waves { display: block; width: 100%; height: 100%; }
#app { position: relative; z-index: 1; }
/* Header + legal navigation */
.site-header, .site-footer {
  width: min(100%, 1680px); margin: 0 auto; position: relative; z-index: 5;
  display: flex; align-items: center; justify-content: space-between;
  padding-left: max(34px, env(safe-area-inset-left, 0px));
  padding-right: max(34px, env(safe-area-inset-right, 0px));
}
.site-header { min-height: 72px; padding-top: max(12px, env(safe-area-inset-top, 0px)); gap: 14px; }
.project-mark { display: inline-flex; gap: 13px; align-items: center; text-decoration: none; white-space: nowrap; }
.project-name { font-size: 21px; font-weight: 730; letter-spacing: -.06em; line-height: 1; color: #eee9eb; }
.project-separator { width: 1px; height: 17px; background: #57384a; }
.project-type { font-size: 11px; font-weight: 520; letter-spacing: .075em; color: #ad8195; }
.header-nav { display: flex; align-items: center; justify-content: flex-end; gap: clamp(19px, 2.4vw, 38px); }
.header-nav a { color: #bbb2b9; font-size: 13px; font-weight: 450; text-decoration: none; white-space: nowrap; transition: color .17s ease; }
.header-nav a:hover, .header-nav a[aria-current="page"] { color: #e7bdcf; }
.header-nav a:focus-visible { outline: 2px solid #c67e9d; outline-offset: 5px; border-radius: 2px; }
.site-footer { min-height: 57px; gap: 12px 22px; padding-top: 10px; padding-bottom: max(16px, env(safe-area-inset-bottom, 0px)); }
.footer-copyright { font-size: 11px; letter-spacing: .035em; color: #797379; }
.footer-nav { display: flex; flex-wrap: wrap; align-items: center; gap: clamp(17px, 2.5vw, 32px); }
.footer-nav a { font-size: 11px; color: #999197; text-decoration: none; transition: color .17s ease; }
.footer-nav a:hover { color: #f0e9ed; }
.project-mark:focus-visible, .footer-nav a:focus-visible { outline: 2px solid #c67e9d; outline-offset: 5px; border-radius: 2px; }

/* Radial home navigation */
.home-view {
  flex: 1 0 auto; width: 100%; min-height: 0;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  padding: 10px max(12px, env(safe-area-inset-right, 0px)) 24px max(12px, env(safe-area-inset-left, 0px));
}
.orbit { width: var(--field); height: var(--field); position: relative; flex: none; isolation: isolate; }
.orbit-track {
  position: absolute; inset: 11%; border: 1px solid #493141;
  border-radius: 50%; pointer-events: none;
}
.owl {
  position: absolute; z-index: 1; width: 50%; height: auto;
  top: 50%; left: 50%; transform: translate(-50%,-50%);
  pointer-events: none; user-select: none; -webkit-user-select: none;
}
.orbit-links { position: absolute; inset: 0; z-index: 2; }
.orbit-link {
  position: absolute; left: 50%; top: 50%; width: var(--tab); height: var(--tab);
  transform: translate(-50%,-50%) rotate(var(--angle)) translateY(calc(-1 * var(--radius))) rotate(calc(-1 * var(--angle)));
  border-radius: 50%; text-decoration: none; outline: none; -webkit-tap-highlight-color: transparent;
}
.orbit-button {
  width: 100%; height: 100%; display: flex; flex-direction: column;
  align-items: center; justify-content: center; gap: clamp(3px, calc(var(--field) * .006), 7px);
  border: 1px solid #54434e; border-radius: 50%; background: #100d10;
  transition: transform .2s ease, background-color .2s ease, border-color .2s ease, box-shadow .2s ease;
  user-select: none; -webkit-user-select: none;
}
.orbit-link:hover .orbit-button, .orbit-link:focus-visible .orbit-button {
  transform: scale(1.055); border-color: #b45980; background: #191118;
  box-shadow: 0 0 0 2px rgba(174,76,118,.09), 0 0 14px rgba(163,62,106,.20);
}
.orbit-link:focus-visible .orbit-button { outline: 2px solid #e5b7cc; outline-offset: 4px; }
.orbit-link:active .orbit-button { transform: scale(.97); }
.nav-icon { width: var(--icon); height: var(--icon); flex: none; fill: none; stroke: #e6dde2; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.nav-label {
  max-width: 98%; width: 100%; font-size: clamp(10px, calc(var(--field) * .0123), 12px);
  color: #ddd2d8; font-weight: 540; letter-spacing: -.012em; line-height: 1.1;
  text-align: center; overflow-wrap: anywhere;
}
.nav-label-short { display: none; }
.orbit-link[href="#/dokumentation"] .nav-label-full { font-size: clamp(9px, calc(var(--field) * .0103), 11px); white-space: nowrap; }
.home-caption { max-width: calc(100vw - 36px); text-align: center; min-height: 57px; margin-top: 4px; }
.home-tagline { margin: 0 0 8px; font-size: clamp(12px,1.15vw,14px); letter-spacing: .015em; line-height: 1.45; color: #b1a9ae; }
.orbit-description { margin: 0; min-height: 19px; font-size: 11px; letter-spacing: .055em; line-height: 1.5; color: #8d7784; transition: color .17s ease; }
.orbit-description.is-active { color: #c995ae; }

/* Inner pages */
.page-view { min-height: 100vh; min-height: 100dvh; background: transparent; padding: clamp(24px, 5vw, 64px) max(22px, env(safe-area-inset-right, 0px)) 80px max(22px, env(safe-area-inset-left, 0px)); }
.page-content { width: min(100%, 1040px); margin: 0 auto; }
.back-link { display: inline-flex; align-items: center; gap: 10px; font-size: 13px; text-decoration: none; border: 1px solid #453640; border-radius: 40px; padding: 11px 17px; color: #e0d8dd; transition: border-color .18s, background-color .18s; }
.back-link svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.back-link:hover, .back-link:focus-visible { border-color: #a14f76; background: #151014; }
.back-link:focus-visible, .card-link:focus-visible { outline: 2px solid #bc7f9b; outline-offset: 4px; }
.page-heading { margin: clamp(56px, 9vh, 112px) 0 clamp(30px, 5vw, 56px); max-width: 780px; }
.page-eyebrow { font-size: 11px; color: #a9738d; font-weight: 650; letter-spacing: .16em; }
.page-heading h2 { margin: 16px 0; font-size: clamp(38px,7vw,74px); letter-spacing: -.055em; line-height: 1.05; font-weight: 630; }
.page-heading h2:focus { outline: none; }
.page-description { color: #a9a2a8; line-height: 1.65; font-size: clamp(16px, 2vw, 19px); margin: 0; max-width: 660px; }
.card-grid { display: grid; grid-template-columns: repeat(auto-fit,minmax(min(100%,250px),1fr)); gap: 14px; }
.card { min-height: 158px; background: #0f0d0f; border: 1px solid #343034; border-radius: 13px; padding: 25px; }
.card h3 { margin: 0 0 12px; font-size: 19px; font-weight: 590; }
.card p { font-size: 14px; margin: 0; line-height: 1.65; color: #aaa2a9; }
.card-link { display: block; text-decoration: none; transition: border-color .18s, transform .18s; }
.card-link:hover { border-color: #87516b; transform: translateY(-2px); }
.card-link .card-arrow { display: inline-flex; align-items: center; gap: 8px; margin-top: 22px; color: #bb7d9c; font-size: 12px; }
.card-arrow svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2; }
.page-note { margin-top: 28px; border-left: 2px solid #87516b; padding: 12px 18px; color: #aaa2a9; line-height: 1.55; font-size: 14px; background: #100d0f; max-width: 700px; }

@media (min-width: 601px) and (min-height: 680px) {
  body.is-home #app, body.is-home .home-view { min-height: 100vh; min-height: 100svh; }
  body.is-home .site-header, body.is-home .site-footer { position: absolute; left: 50%; transform: translateX(-50%); }
  body.is-home .site-header { top: 0; }
  body.is-home .site-footer { bottom: 0; }
}
@media (min-width: 601px) and (min-height: 680px) and (max-height: 800px) {
  :root { --field: min(calc(100vw - 48px), calc(100svh - 220px), 970px); }
}
@media (max-width: 600px) {
  :root {
    --field: min(calc(100vw - 34px - env(safe-area-inset-left, 0px) - env(safe-area-inset-right, 0px)), calc(100svh - 240px), 480px);
    --radius: calc(var(--field) * .394);
    --tab: clamp(51px, calc(var(--field) * .172), 76px);
    --icon: clamp(20px, calc(var(--field) * .062), 28px);
  }
  .site-header { min-height: 65px; padding-left: 22px; padding-right: 22px; }
  .header-nav { gap: clamp(8px, 2.4vw, 14px); }
  .header-nav a { font-size: clamp(10px, 2.65vw, 12px); }
  .project-mark { gap: 9px; }
  .project-name { font-size: 21px; }
  .project-type { font-size: 10px; }
  .site-footer { justify-content: center; flex-direction: column; gap: 12px; padding-left: 18px; padding-right: 18px; padding-top: 18px; padding-bottom: max(21px, env(safe-area-inset-bottom, 0px)); }
  .footer-nav { justify-content: center; gap: 12px 22px; }
  .footer-nav a { font-size: 11px; }
  .home-view { padding-top: 12px; padding-bottom: 16px; }
  .owl { width: 49%; }
  .orbit-button { gap: 4px; }
  .nav-label { font-size: clamp(8.8px, calc(var(--field) * .029), 11px); line-height: 1; letter-spacing: -.025em; }
  .orbit-link[href="#/dokumentation"] .nav-label-full { display: none; }
  .orbit-link[href="#/dokumentation"] .nav-label-short { display: block; }
  .orbit-link[href="#/entwickler"] .nav-label { font-size: clamp(8px, calc(var(--field) * .024), 10px); white-space: nowrap; }
  .home-caption { min-height: 60px; margin-top: 14px; }
  .home-tagline { font-size: 12px; max-width: 300px; margin: 0 auto 7px; }
  .orbit-description { font-size: 10px; max-width: 290px; margin: auto; min-height: 24px; }
  .page-view { padding-top: max(24px, env(safe-area-inset-top)); padding-bottom: max(56px, env(safe-area-inset-bottom)); }
  .page-heading { margin-top: 64px; }
}
@media (max-width: 350px) {
  .site-header { padding-left: 13px; padding-right: 13px; }
  .project-type, .project-separator { display: none; }
  .header-nav { gap: 11px; }
  .header-nav a { font-size: 11px; }
  .footer-nav { column-gap: 16px; }
  .orbit-link[href="#/downloads"] .nav-label, .orbit-link[href="#/mitmachen"] .nav-label { font-size: 8.6px; }
}
@media (max-height: 550px) and (orientation: landscape) {
  :root { --field: min(calc(100vw - 36px), calc(100svh - 16px), 560px); }
  .home-view { padding: 8px 10px 16px; }
}
@media (max-width: 600px) {
  .ambient-backdrop {
    background:
      radial-gradient(ellipse 60% 33% at -5% 18%, rgba(106,39,86,.18), transparent 80%),
      radial-gradient(ellipse 65% 38% at 105% 77%, rgba(94,34,72,.20), transparent 80%);
  }
  .ambient-waves { width: 185%; max-width: none; transform: translateX(-23%); }
}
@media (prefers-reduced-motion: reduce) {
  .orbit-button, .back-link, .card-link, .footer-nav a, .header-nav a, .orbit-description { transition: none; }
}


/* v4.2 header refinement */
.header-nav { gap: clamp(18px, 2.2vw, 32px); }
