/* Extras: Menüknöpfe, Status-Badges, Changelog-Typen, Suche (Strg+K), Prüfsummen. */

/* Gleiche Form wie der Sprachknopf (.nav__lang in style.css): Pixelschrift, 13 px, gleiche Abstände und Farben */
.nav__extra {
  appearance: none; display: inline-flex; align-items: center; height: 32px; box-sizing: border-box; margin-left: 4px; padding: 0 12px; border-radius: 999px; cursor: pointer;
  font: 700 13px var(--pixel); color: var(--ink); white-space: nowrap;
  background: rgba(255, 255, 255, 0.08); border: 1px solid rgba(255, 255, 255, 0.18);
  transition: background 0.2s ease, color 0.2s ease;
}
.nav__extra:hover, .nav__extra:focus-visible { background: rgba(255, 255, 255, 0.14); color: #fff; }
.nav__extra:focus-visible, .nav__actions .nav__lang:focus-visible { outline: 2px solid var(--accent, #8ff5c8); outline-offset: 2px; }

/* Rechte Menügruppe (Suche, Bewegung, Sprache, auf der Startseite mobil auch "Menü"), von site-extras.js gebaut */
.nav__actions { display: flex; align-items: center; gap: 4px; margin-left: auto; }
.nav__actions > .nav__extra, .nav__actions > .nav__lang { margin-left: 0; }
.nav__actions > .nav__lang { height: 32px; box-sizing: border-box; align-items: center; }
.nav__menu { display: none; }
@media (max-width: 640px) {
  .nav__pill--actions { flex-wrap: wrap; row-gap: 6px; }
  .nav__pill--actions .nav__brand { order: 1; margin-right: auto; }
  .nav__pill--actions .nav__actions { order: 2; }
  .nav__pill--actions .vp-nav { order: 3; width: 100%; justify-content: safe center; flex-wrap: nowrap; gap: 0; overflow-x: auto; scrollbar-width: none; }
  .nav__pill--actions .vp-nav::-webkit-scrollbar { display: none; }
  .nav__pill--actions .vp-nav a { padding: 6px 8px; font-size: 13px; white-space: nowrap; flex: none; }
  .nav__actions > .nav__extra, .nav__actions > .nav__lang { height: 30px; padding: 0 10px; font-size: 12px; }
  .nav__menu { display: inline-flex; }
  .nav__pill--actions.is-menu-open { border-radius: 24px; background-color: rgba(7, 12, 24, 0.94); }
  .nav__pill--actions.is-menu-open .nav__links { display: flex; flex-direction: column; order: 3; width: 100%; gap: 2px; padding: 4px 0 2px; }
  .nav__pill--actions.is-menu-open .nav__links a { padding: 10px 14px; }
  /* Projektseiten: Inhalt beginnt unter dem zweizeiligen Menü */
  .doc.projekt, .doc.villagers { padding-top: 120px; }
  .projekt .vp-section, .villagers .vp-section { scroll-margin-top: 130px; }
  /* Startseite: Hinweis "Wähle einen Weg" links, damit der Musik-Player rechts ihn nicht verdeckt */
  .scroll-hint { left: 18px; justify-items: start; font-size: 12px; }
  .scroll-hint.hero-in, .is-ready .scroll-hint.hero-in { transform: none; }
}
@media (max-width: 420px) {
  /* Nur das Kopf-Symbol, damit Marke und Knöpfe in eine Zeile passen (Name steht im aria-label) */
  .nav__pill--actions .nav__brand { font-size: 0; gap: 0; }
}
.nav__motion[aria-pressed="true"] { color: var(--muted); }

/* Status-Badge auf den Projektkarten und in der Projektseite */
.sbadge {
  display: inline-block; margin-left: 8px; padding: 3px 8px; border-radius: 999px; font: 700 11px/1 var(--body, system-ui);
  letter-spacing: 0.04em; text-transform: uppercase; color: #0d0d0d; background: var(--acc, #ffd56a);
  vertical-align: middle;
}
.sbadge--play { background: #c79cff; }
.sbadge--dev { background: #ffb347; }
.pj-status {
  display: inline-block; margin: 0 0 10px; padding: 4px 10px; border-radius: 999px; font: 700 12px/1 var(--body, system-ui);
  text-transform: uppercase; letter-spacing: 0.06em; color: #0d0d0d; background: var(--acc, #ffd56a);
}

/* Changelog: Filter nach Art der Änderung */
.timeline__types { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 18px; }
.timeline__types button {
  appearance: none; border: 1px solid rgba(255, 255, 255, 0.16); background: transparent; color: inherit;
  font: 600 12px/1 var(--body, system-ui); padding: 7px 11px; border-radius: 999px; cursor: pointer;
}
.timeline__types button[aria-pressed="true"] { background: var(--acc, #ffd56a); color: #0d0d0d; border-color: transparent; }

/* Suche */
.sx-dialog {
  width: min(560px, calc(100% - 32px)); margin: 12vh auto 0; padding: 0; border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 14px; background: #0d1220; color: #eef4ff; box-shadow: 0 24px 60px rgba(0, 0, 0, 0.5);
}
.sx-dialog::backdrop { background: rgba(0, 0, 0, 0.55); }
.sx-form { padding: 14px; }
.sx-input {
  width: 100%; box-sizing: border-box; padding: 12px 14px; border-radius: 10px; border: 1px solid rgba(255, 255, 255, 0.16);
  background: rgba(255, 255, 255, 0.05); color: inherit; font: 500 16px/1.2 var(--body, system-ui); outline: none;
}
.sx-input:focus { border-color: var(--acc, #ffd56a); }
.sx-list { list-style: none; margin: 10px 0 0; padding: 0; max-height: 52vh; overflow: auto; }
.sx-list a {
  display: flex; justify-content: space-between; gap: 12px; padding: 10px 12px; border-radius: 8px; color: inherit; text-decoration: none;
}
.sx-list a:hover, .sx-list a:focus-visible { background: rgba(255, 255, 255, 0.08); }
.sx-list a:focus-visible { outline: 2px solid var(--acc, var(--accent, #ffd56a)); outline-offset: -2px; }
.sx-list small { opacity: 0.6; font-size: 12px; align-self: center; }
.sx-empty { margin: 12px 4px 4px; opacity: 0.7; }

/* Prüfsummen */
.pj-sums { margin-top: 14px; padding: 16px 18px; }
.pj-sums[hidden] { display: none; }
.sums__head { margin: 0 0 10px; font-weight: 700; }
.sums__list { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.sums__list li { word-break: break-word; }
.sums__list code { display: block; margin: 4px 0; font-size: 12px; opacity: 0.85; }
.sums__copy {
  appearance: none; border: 1px solid rgba(255, 255, 255, 0.2); background: transparent; color: inherit;
  font: 600 12px/1 var(--body, system-ui); padding: 6px 10px; border-radius: 999px; cursor: pointer;
}
.sums__how { margin: 12px 0 0; font-size: 13px; opacity: 0.75; }

/* Graph-Ansichten: Ring (Standard), Balken je Projekt, Raster aus Kacheln */
.progress__views { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 16px; }
.progress__views button {
  appearance: none; border: 1px solid rgba(255, 255, 255, 0.16); background: transparent; color: inherit;
  font: 700 12px/1 var(--pixel, var(--body, system-ui)); padding: 7px 12px; border-radius: 999px; cursor: pointer;
}
.progress__views button[aria-pressed="true"] { background: var(--acc, #8ff5c8); color: #0d0d0d; border-color: transparent; }
.progress__viz { margin: 0 0 18px; }
.progress__viz[hidden] { display: none; }
.progress[data-view="bars"] .donut, .progress[data-view="grid"] .donut { display: none; }
.bar-row {
  appearance: none; width: 100%; display: grid; grid-template-columns: minmax(120px, 210px) 1fr auto; gap: 14px; align-items: center;
  padding: 9px 12px; margin: 0 0 4px; border: 0; border-radius: 10px; background: transparent; color: inherit; text-align: left; cursor: pointer; font: inherit;
}
.bar-row:hover, .bar-row.is-on { background: rgba(255, 255, 255, 0.06); }
.bar-row__name { font-weight: 700; }
.bar-row__track { height: 12px; border-radius: 999px; background: rgba(255, 255, 255, 0.08); overflow: hidden; }
.bar-row__track i { display: block; height: 100%; border-radius: 999px; background: rgb(var(--tc, 214, 232, 255)); box-shadow: 0 0 10px rgba(var(--tc, 214, 232, 255), 0.5); transition: width 0.6s ease; }
.bar-row__n { font-size: 13px; opacity: 0.75; font-variant-numeric: tabular-nums; }
.grid-cells { display: grid; grid-template-columns: repeat(auto-fill, minmax(18px, 1fr)); gap: 5px; }
.grid-cells .cell { aspect-ratio: 1; border-radius: 4px; border: 1px solid rgba(255, 255, 255, 0.22); background: rgba(255, 255, 255, 0.03); }
.grid-cells .cell.is-done { background: rgb(var(--c, 143, 245, 200)); border-color: transparent; box-shadow: 0 0 8px rgba(var(--c, 143, 245, 200), 0.45); }

/* Akku-Schonung und "Bewegung aus": Hintergrund bleibt stehen */
html.motion-eco .theme-bg, html.motion-off .theme-bg { filter: saturate(0.9); }
